mirror of
https://github.com/dataease/dataease.git
synced 2026-05-18 01:38:11 +08:00
fix: 日期过滤默认值兼容老版本
This commit is contained in:
@@ -227,7 +227,7 @@ class TimeDateRangeServiceImpl extends WidgetService {
|
||||
}
|
||||
getParam(element) {
|
||||
let timeArr = []
|
||||
if (element.options.attrs.default.isDynamic) {
|
||||
if (element.options.attrs.default && element.options.attrs.default.isDynamic) {
|
||||
let value = this.dynamicDateFormNow(element)
|
||||
value = this.formatFilterValue(value)
|
||||
timeArr = this.formatValues(value, element)
|
||||
|
||||
@@ -157,7 +157,7 @@ class TimeDateServiceImpl extends WidgetService {
|
||||
}
|
||||
getParam(element) {
|
||||
let timeArr = []
|
||||
if (element.options.attrs.default.isDynamic) {
|
||||
if (element.options.attrs.default && element.options.attrs.default.isDynamic) {
|
||||
let value = this.dynamicDateFormNow(element)
|
||||
value = this.formatFilterValue(value)
|
||||
timeArr = this.formatValues(value, element)
|
||||
|
||||
@@ -123,7 +123,7 @@ class TimeMonthServiceImpl extends WidgetService {
|
||||
}
|
||||
getParam(element) {
|
||||
let timeArr = []
|
||||
if (element.options.attrs.default.isDynamic) {
|
||||
if (element.options.attrs.default && element.options.attrs.default.isDynamic) {
|
||||
let value = this.dynamicDateFormNow(element)
|
||||
value = this.formatFilterValue(value)
|
||||
timeArr = this.formatValues(value, element)
|
||||
|
||||
@@ -114,7 +114,7 @@ class TimeYearServiceImpl extends WidgetService {
|
||||
}
|
||||
getParam(element) {
|
||||
let timeArr = []
|
||||
if (element.options.attrs.default.isDynamic) {
|
||||
if (element.options.attrs.default && element.options.attrs.default.isDynamic) {
|
||||
let value = this.dynamicDateFormNow(element)
|
||||
value = this.formatFilterValue(value)
|
||||
timeArr = this.formatValues(value, element)
|
||||
|
||||
Reference in New Issue
Block a user