| | |
| | | } |
| | | |
| | | let _dataresource = setting.dataresource |
| | | let regoptions = null |
| | | let regoptions = [] |
| | | if (setting.queryType === 'statistics' || param.custom_script) { |
| | | let allSearch = Utils.getAllSearchOptions(search) |
| | | let userName = sessionStorage.getItem('User_Name') || '' |
| | |
| | | }) |
| | | } |
| | | |
| | | if (config.calendar.refresh === 'true' && regoptions) { |
| | | if (config.calendar.refresh === 'true') { |
| | | regoptions.push({ |
| | | reg: new RegExp('@calendarDate@', 'ig'), |
| | | value: `${calendarYear}-01-01 00:00:00.000` |
| | | value: `'${calendarYear}-01-01 00:00:00.000'` |
| | | }) |
| | | regoptions.push({ |
| | | reg: new RegExp('@calendarDate1@', 'ig'), |
| | | value: `${calendarYear}-12-31 23:59:59.999` |
| | | value: `'${calendarYear}-12-31 23:59:59.999'` |
| | | }) |
| | | } |
| | | |
| | | if (setting.queryType === 'statistics' && setting.execute !== 'false') { // 统计数据源,内容替换 |
| | | if ((setting.queryType === 'statistics' || config.calendar.refresh === 'true') && setting.execute !== 'false') { // 统计数据源,内容替换 |
| | | regoptions.forEach(item => { |
| | | _dataresource = _dataresource.replace(item.reg, item.value) |
| | | }) |