Skip to content

Commit 0b74338

Browse files
authored
修复工单选择【全部】显示NaN问题 (#2543)
Update sqlworkflow.html 修复工单选择【全部】显示NaN问题
1 parent 2d272f2 commit 0b74338

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sql/templates/sqlworkflow.html

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ <h4 class="modal-title text-danger">工单日志</h4>
8585
let end = moment();
8686

8787
function cb(start, end) {
88-
if (start.isValid() && end.isValid()) {
88+
if (start.isValid() && end.isValid() && start.dayOfYear()!=1) {
8989
$('#reservation span').html(start.format('YYYY-MM-DD') + ' - ' + end.format('YYYY-MM-DD'));
9090
} else {
9191
$('#reservation span').html('全部数据');
@@ -110,7 +110,7 @@ <h4 class="modal-title text-danger">工单日志</h4>
110110
firstDay: 1
111111
},
112112
ranges: {
113-
"全部": [null, null],
113+
"全部": [moment({ year: 1970 }),moment()],
114114
"今日": [moment().startOf('day'), moment()],
115115
"昨日": [moment().subtract('days', 1).startOf('day'), moment().subtract('days', 1).endOf('day')],
116116
"最近7日": [moment().subtract('days', 6), moment()],

0 commit comments

Comments
 (0)