Bladeren bron

Report datetime 默认带时间

luoyifan 3 jaren geleden
bovenliggende
commit
611f7d80c4
2 gewijzigde bestanden met toevoegingen van 14 en 4 verwijderingen
  1. 13 3
      dist/yvan-ext.js
  2. 1 1
      dist/yvan-ext.js.map

+ 13 - 3
dist/yvan-ext.js

@@ -32063,7 +32063,7 @@ define(['exports'], function (exports) { 'use strict';
     })));
     });
 
-    var moment = createCommonjsModule(function (module, exports) {
+    var moment$1 = createCommonjsModule(function (module, exports) {
     (function (global, factory) {
          module.exports = factory() ;
     }(commonjsGlobal, (function () {
@@ -130031,6 +130031,17 @@ define(['exports'], function (exports) { 'use strict';
                 if (item.conditionFieldXtype === 'combo') {
                     vj.fix = ['system.' + getDictFnName + '("' + item.conditionFieldDict + '")'];
                 }
+                if (item.conditionFieldXtype === 'datetimefield') {
+                    //@ts-ignore
+                    lodash.set(model.data.query, item.conditionFieldBind, moment(window.getServerTime()).format('YYYY-MM-DD HH:mm:ss'));
+                }
+                else if (item.conditionFieldXtype === 'datefield') {
+                    //@ts-ignore
+                    lodash.set(model.data.query, item.conditionFieldBind, moment(window.getServerTime()).format('YYYY-MM-DD'));
+                }
+                else {
+                    model.data.query[item.conditionFieldBind] = '';
+                }
             }
             else {
                 // 没有组件类型,是个空占位符
@@ -130040,7 +130051,6 @@ define(['exports'], function (exports) { 'use strict';
                 vj.bind = {
                     value: '{query.' + item.conditionFieldBind + '}'
                 };
-                model.data.query[item.conditionFieldBind] = '';
             }
             if (item.conditionFieldFlex) {
                 vj.flex = item.conditionFieldFlex;
@@ -132818,7 +132828,7 @@ define(['exports'], function (exports) { 'use strict';
     exports.lookupFn = lookupFn;
     exports.lookupScope = lookupScope;
     exports.mergeViewModel = mergeViewModel;
-    exports.moment = moment;
+    exports.moment = moment$1;
     exports.msg = msg$1;
     exports.msgError = msgError;
     exports.normId = normId;

File diff suppressed because it is too large
+ 1 - 1
dist/yvan-ext.js.map