@ibiz-template/runtime 0.6.1-dev.2 → 0.6.2-dev.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (133) hide show
  1. package/dist/index.esm.js +495 -137
  2. package/dist/index.system.min.js +1 -1
  3. package/out/application.js +7 -7
  4. package/out/controller/common/base.controller.d.ts +9 -0
  5. package/out/controller/common/base.controller.d.ts.map +1 -1
  6. package/out/controller/common/base.controller.js +12 -0
  7. package/out/controller/common/control/md-control.controller.d.ts +15 -0
  8. package/out/controller/common/control/md-control.controller.d.ts.map +1 -1
  9. package/out/controller/common/control/md-control.controller.js +22 -3
  10. package/out/controller/common/view/view.controller.d.ts.map +1 -1
  11. package/out/controller/common/view/view.controller.js +2 -1
  12. package/out/controller/control/app-menu/app-menu.controller.js +1 -1
  13. package/out/controller/control/form/edit-form/edit-form.controller.d.ts.map +1 -1
  14. package/out/controller/control/form/edit-form/edit-form.controller.js +3 -1
  15. package/out/controller/control/form/form/form.controller.d.ts +18 -1
  16. package/out/controller/control/form/form/form.controller.d.ts.map +1 -1
  17. package/out/controller/control/form/form/form.controller.js +68 -0
  18. package/out/controller/control/gantt/gantt.controller.d.ts +3 -3
  19. package/out/controller/control/gantt/gantt.controller.d.ts.map +1 -1
  20. package/out/controller/control/gantt/gantt.controller.js +1 -4
  21. package/out/controller/control/grid/grid/grid.controller.d.ts.map +1 -1
  22. package/out/controller/control/grid/grid/grid.controller.js +1 -0
  23. package/out/controller/control/tree/tree.controller.d.ts +8 -0
  24. package/out/controller/control/tree/tree.controller.d.ts.map +1 -1
  25. package/out/controller/control/tree/tree.controller.js +14 -0
  26. package/out/controller/notification/internal-message.controller.d.ts +7 -0
  27. package/out/controller/notification/internal-message.controller.d.ts.map +1 -1
  28. package/out/controller/notification/internal-message.controller.js +13 -0
  29. package/out/de-logic/de-logic-link/de-logic-link-group-cond/de-logic-link-group-cond.d.ts.map +1 -1
  30. package/out/de-logic/de-logic-link/de-logic-link-group-cond/de-logic-link-group-cond.js +3 -1
  31. package/out/de-logic/de-logic-link/de-logic-link-single-cond/de-logic-link-single-cond.d.ts.map +1 -1
  32. package/out/de-logic/de-logic-link/de-logic-link-single-cond/de-logic-link-single-cond.js +12 -3
  33. package/out/de-logic/de-logic-node/append-param-node/append-param-node.d.ts.map +1 -1
  34. package/out/de-logic/de-logic-node/append-param-node/append-param-node.js +1 -0
  35. package/out/de-logic/de-logic-node/bind-param-node/bind-param-node.d.ts.map +1 -1
  36. package/out/de-logic/de-logic-node/bind-param-node/bind-param-node.js +1 -0
  37. package/out/de-logic/de-logic-node/copy-param-node/copy-param-node.d.ts.map +1 -1
  38. package/out/de-logic/de-logic-node/copy-param-node/copy-param-node.js +1 -0
  39. package/out/de-logic/de-logic-node/data-set-node/data-set-node.d.ts.map +1 -1
  40. package/out/de-logic/de-logic-node/data-set-node/data-set-node.js +1 -0
  41. package/out/de-logic/de-logic-node/de-action-node/de-action-node.d.ts.map +1 -1
  42. package/out/de-logic/de-logic-node/de-action-node/de-action-node.js +1 -0
  43. package/out/de-logic/de-logic-node/end-node/end-node.d.ts.map +1 -1
  44. package/out/de-logic/de-logic-node/end-node/end-node.js +1 -0
  45. package/out/de-logic/de-logic-node/prepare-param-node/prepare-param-node.d.ts.map +1 -1
  46. package/out/de-logic/de-logic-node/prepare-param-node/prepare-param-node.js +22 -7
  47. package/out/de-logic/de-logic-node/renew-param-node/renew-param-node.d.ts.map +1 -1
  48. package/out/de-logic/de-logic-node/renew-param-node/renew-param-node.js +1 -0
  49. package/out/de-logic/de-logic-node/reset-param-node/reset-param-node.d.ts.map +1 -1
  50. package/out/de-logic/de-logic-node/reset-param-node/reset-param-node.js +1 -0
  51. package/out/de-logic/de-logic-node/sort-param-node/sort-param-node.d.ts.map +1 -1
  52. package/out/de-logic/de-logic-node/sort-param-node/sort-param-node.js +1 -0
  53. package/out/de-logic/de-logic-node/start-node/start-node.d.ts.map +1 -1
  54. package/out/de-logic/de-logic-node/start-node/start-node.js +1 -0
  55. package/out/de-logic/de-logic-node/throw-exception-node/throw-exception-node.d.ts.map +1 -1
  56. package/out/de-logic/de-logic-node/throw-exception-node/throw-exception-node.js +1 -0
  57. package/out/de-logic/de-logic-param/de-logic-param.d.ts.map +1 -1
  58. package/out/de-logic/de-logic-param/de-logic-param.js +2 -0
  59. package/out/de-logic/index.d.ts.map +1 -1
  60. package/out/de-logic/index.js +4 -1
  61. package/out/engine/md-view.engine.js +1 -1
  62. package/out/hub/config/app-view-config-service.d.ts.map +1 -1
  63. package/out/hub/config/app-view-config-service.js +1 -0
  64. package/out/interface/controller/controller/control/i-gantt.controller.d.ts +31 -2
  65. package/out/interface/controller/controller/control/i-gantt.controller.d.ts.map +1 -1
  66. package/out/interface/controller/controller/notice/i-internal-message.controller.d.ts +7 -0
  67. package/out/interface/controller/controller/notice/i-internal-message.controller.d.ts.map +1 -1
  68. package/out/interface/controller/state/view/i-view.state.d.ts +7 -0
  69. package/out/interface/controller/state/view/i-view.state.d.ts.map +1 -1
  70. package/out/plugin/plugin-static-resource/plugin-static-resource.d.ts +8 -0
  71. package/out/plugin/plugin-static-resource/plugin-static-resource.d.ts.map +1 -1
  72. package/out/plugin/plugin-static-resource/plugin-static-resource.js +12 -1
  73. package/out/service/service/internal-message/internal-message.service.d.ts +8 -0
  74. package/out/service/service/internal-message/internal-message.service.d.ts.map +1 -1
  75. package/out/service/service/internal-message/internal-message.service.js +10 -0
  76. package/out/types.d.ts +1 -1
  77. package/out/types.d.ts.map +1 -1
  78. package/out/ui-action/provider/ui-action-provider-base.d.ts +2 -2
  79. package/out/ui-action/provider/ui-action-provider-base.d.ts.map +1 -1
  80. package/out/ui-action/provider/ui-action-provider-base.js +9 -4
  81. package/out/ui-logic/index.d.ts.map +1 -1
  82. package/out/ui-logic/index.js +4 -1
  83. package/out/ui-logic/ui-logic-link/ui-logic-link-group-cond/ui-logic-link-group-cond.d.ts.map +1 -1
  84. package/out/ui-logic/ui-logic-link/ui-logic-link-group-cond/ui-logic-link-group-cond.js +3 -1
  85. package/out/ui-logic/ui-logic-link/ui-logic-link-single-cond/ui-logic-link-single-cond.d.ts.map +1 -1
  86. package/out/ui-logic/ui-logic-link/ui-logic-link-single-cond/ui-logic-link-single-cond.js +12 -3
  87. package/out/ui-logic/ui-logic-node/append-param-node/append-param-node.d.ts.map +1 -1
  88. package/out/ui-logic/ui-logic-node/append-param-node/append-param-node.js +1 -0
  89. package/out/ui-logic/ui-logic-node/bind-param-node/bind-param-node.d.ts.map +1 -1
  90. package/out/ui-logic/ui-logic-node/bind-param-node/bind-param-node.js +1 -0
  91. package/out/ui-logic/ui-logic-node/copy-param-node/copy-param-node.d.ts.map +1 -1
  92. package/out/ui-logic/ui-logic-node/copy-param-node/copy-param-node.js +1 -0
  93. package/out/ui-logic/ui-logic-node/data-set-node/data-set-node.d.ts.map +1 -1
  94. package/out/ui-logic/ui-logic-node/data-set-node/data-set-node.js +1 -0
  95. package/out/ui-logic/ui-logic-node/de-action-node/de-action-node.d.ts.map +1 -1
  96. package/out/ui-logic/ui-logic-node/de-action-node/de-action-node.js +1 -0
  97. package/out/ui-logic/ui-logic-node/de-ui-action-node/de-ui-action-node.d.ts.map +1 -1
  98. package/out/ui-logic/ui-logic-node/de-ui-action-node/de-ui-action-node.js +2 -1
  99. package/out/ui-logic/ui-logic-node/end-node/end-node.d.ts.map +1 -1
  100. package/out/ui-logic/ui-logic-node/end-node/end-node.js +1 -0
  101. package/out/ui-logic/ui-logic-node/execute-de-logic-node/execute-de-logic-node.d.ts.map +1 -1
  102. package/out/ui-logic/ui-logic-node/execute-de-logic-node/execute-de-logic-node.js +1 -0
  103. package/out/ui-logic/ui-logic-node/msg-box-node/msg-box-node.d.ts.map +1 -1
  104. package/out/ui-logic/ui-logic-node/msg-box-node/msg-box-node.js +1 -0
  105. package/out/ui-logic/ui-logic-node/pf-plugin-node/pf-plugin-node.d.ts.map +1 -1
  106. package/out/ui-logic/ui-logic-node/pf-plugin-node/pf-plugin-node.js +1 -0
  107. package/out/ui-logic/ui-logic-node/prepare-js-param-node/prepare-js-param-node.d.ts.map +1 -1
  108. package/out/ui-logic/ui-logic-node/prepare-js-param-node/prepare-js-param-node.js +6 -0
  109. package/out/ui-logic/ui-logic-node/raw-js-code-node/raw-js-code-node.d.ts.map +1 -1
  110. package/out/ui-logic/ui-logic-node/raw-js-code-node/raw-js-code-node.js +1 -0
  111. package/out/ui-logic/ui-logic-node/renew-param-node/renew-param-node.d.ts.map +1 -1
  112. package/out/ui-logic/ui-logic-node/renew-param-node/renew-param-node.js +1 -0
  113. package/out/ui-logic/ui-logic-node/reset-param-node/reset-param-node.d.ts.map +1 -1
  114. package/out/ui-logic/ui-logic-node/reset-param-node/reset-param-node.js +1 -0
  115. package/out/ui-logic/ui-logic-node/sort-param-node/sort-param-node.d.ts.map +1 -1
  116. package/out/ui-logic/ui-logic-node/sort-param-node/sort-param-node.js +1 -0
  117. package/out/ui-logic/ui-logic-node/start-node/start-node.d.ts.map +1 -1
  118. package/out/ui-logic/ui-logic-node/start-node/start-node.js +1 -0
  119. package/out/ui-logic/ui-logic-node/throw-exception-node/throw-exception-node.d.ts.map +1 -1
  120. package/out/ui-logic/ui-logic-node/throw-exception-node/throw-exception-node.js +1 -0
  121. package/out/ui-logic/ui-logic-node/view-ctrl-fire-event-node/view-ctrl-fire-event-node.d.ts.map +1 -1
  122. package/out/ui-logic/ui-logic-node/view-ctrl-fire-event-node/view-ctrl-fire-event-node.js +1 -0
  123. package/out/ui-logic/ui-logic-node/view-ctrl-invoke-node/view-ctrl-invoke-node.d.ts.map +1 -1
  124. package/out/ui-logic/ui-logic-node/view-ctrl-invoke-node/view-ctrl-invoke-node.js +1 -0
  125. package/out/ui-logic/ui-logic-param/ui-logic-param.d.ts.map +1 -1
  126. package/out/ui-logic/ui-logic-param/ui-logic-param.js +2 -0
  127. package/out/utils/handlebars/helpers/not/not.d.ts.map +1 -1
  128. package/out/utils/handlebars/helpers/not/not.js +2 -1
  129. package/out/utils/open-redirect-view/open-redirect-view.d.ts.map +1 -1
  130. package/out/utils/open-redirect-view/open-redirect-view.js +3 -0
  131. package/out/utils/script/script-function.d.ts.map +1 -1
  132. package/out/utils/script/script-function.js +1 -0
  133. package/package.json +6 -7
package/dist/index.esm.js CHANGED
@@ -233,8 +233,8 @@ var HelperBase = class {
233
233
  * @date 2021-12-29 14:12:47
234
234
  * @param {string} tag 助手标识
235
235
  */
236
- constructor(Handlebars2, tag) {
237
- Handlebars2.registerHelper(tag, this.onExecute);
236
+ constructor(Handlebars, tag) {
237
+ Handlebars.registerHelper(tag, this.onExecute);
238
238
  }
239
239
  };
240
240
 
@@ -408,12 +408,13 @@ var HelperNeq = class extends HelperBase {
408
408
  };
409
409
 
410
410
  // src/utils/handlebars/helpers/not/not.ts
411
+ import { isEmpty, isNil } from "ramda";
411
412
  var HelperNot = class extends HelperBase {
412
413
  constructor(hbs) {
413
414
  super(hbs, "not");
414
415
  }
415
416
  onExecute(param, options) {
416
- const bol = Handlebars.Utils.isEmpty(param);
417
+ const bol = isEmpty(param) || isNil(param);
417
418
  return HelperUtil.handleJudgmentExecute(this, bol, options);
418
419
  }
419
420
  };
@@ -595,7 +596,7 @@ var HandlebarsUtil = class {
595
596
  };
596
597
 
597
598
  // src/utils/nav-params/nav-params.ts
598
- import { isEmpty, isNil } from "lodash-es";
599
+ import { isEmpty as isEmpty2, isNil as isNil2 } from "lodash-es";
599
600
  import { isNilOrEmpty, notNilEmpty } from "qx-util";
600
601
  function convertObjectToNavParams(navParams) {
601
602
  const result = [];
@@ -616,7 +617,7 @@ function convertObjectToNavParams(navParams) {
616
617
  return result;
617
618
  }
618
619
  function convertNavData(navParams, ...origins) {
619
- if (!navParams || isEmpty(navParams)) {
620
+ if (!navParams || isEmpty2(navParams)) {
620
621
  return {};
621
622
  }
622
623
  const navParamsArr = Array.isArray(navParams) ? navParams : convertObjectToNavParams(navParams);
@@ -650,7 +651,7 @@ function convertNavDataByArray(naviDatas, ...origins) {
650
651
  key.slice(2, -1).toLowerCase()
651
652
  );
652
653
  if (find) {
653
- valueStr = valueStr.replace(key, "".concat(isNil(value) ? "" : value));
654
+ valueStr = valueStr.replace(key, "".concat(isNil2(value) ? "" : value));
654
655
  }
655
656
  });
656
657
  result[naviData.key.toLowerCase()] = valueStr;
@@ -1294,6 +1295,9 @@ async function getDERedirectToView(appView, context, params = {}, opts = {}) {
1294
1295
  });
1295
1296
  if (refView) {
1296
1297
  viewId = refView.refAppViewId;
1298
+ if (refView.openMode) {
1299
+ opts.openMode = refView.openMode;
1300
+ }
1297
1301
  if (viewId) {
1298
1302
  return {
1299
1303
  type: "view",
@@ -1405,7 +1409,7 @@ async function calcDERdTag(entity, rdView, params, data) {
1405
1409
  // src/utils/verify/verify.ts
1406
1410
  import { RuntimeError as RuntimeError3 } from "@ibiz-template/core";
1407
1411
  import { isNilOrEmpty as isNilOrEmpty3, notNilEmpty as notNilEmpty4 } from "qx-util";
1408
- import { isNil as isNil2 } from "ramda";
1412
+ import { isNil as isNil3 } from "ramda";
1409
1413
  function testCond(value, op, value2) {
1410
1414
  if (Object.is(op, "IN")) {
1411
1415
  return contains(value, value2);
@@ -1431,7 +1435,7 @@ function testCond(value, op, value2) {
1431
1435
  case "ISNOTNULL":
1432
1436
  return notNilEmpty4(value);
1433
1437
  case "TESTNULL":
1434
- return isNil2(value);
1438
+ return isNil3(value);
1435
1439
  case "IN":
1436
1440
  return contains(value, value2);
1437
1441
  case "NOTIN":
@@ -1504,7 +1508,7 @@ function strContain(value, value2, mode) {
1504
1508
  // src/utils/verify/de-rule-verify.ts
1505
1509
  import { RuntimeError as RuntimeError4 } from "@ibiz-template/core";
1506
1510
  import { isNilOrEmpty as isNilOrEmpty4 } from "qx-util";
1507
- import { isEmpty as isEmpty2, isNil as isNil3 } from "ramda";
1511
+ import { isEmpty as isEmpty3, isNil as isNil4 } from "ramda";
1508
1512
 
1509
1513
  // src/utils/script/script-function.ts
1510
1514
  import { mergeRight } from "ramda";
@@ -1576,7 +1580,8 @@ var ScriptFunction = class {
1576
1580
  "parentView",
1577
1581
  "view",
1578
1582
  "parent",
1579
- "util"
1583
+ "util",
1584
+ "ctrl"
1580
1585
  ];
1581
1586
  keys.push(...presetArgsKeys);
1582
1587
  this.argKeys = Array.from(new Set(keys));
@@ -1858,7 +1863,7 @@ function checkFieldSimpleRule(value, op, value2, errorInfo, paramType, form, pri
1858
1863
  const _value2Field = form[value2] ? form[value2] : value2;
1859
1864
  value2 = _value2Field;
1860
1865
  }
1861
- if (isNil3(errorInfo) || isEmpty2(errorInfo)) {
1866
+ if (isNil4(errorInfo) || isEmpty3(errorInfo)) {
1862
1867
  errorInfo = "\u5185\u5BB9\u5FC5\u987B\u7B26\u5408\u503C\u89C4\u5219";
1863
1868
  }
1864
1869
  const result = testCond(value, op, value2);
@@ -4988,7 +4993,7 @@ import { ModelError as ModelError15, RuntimeError as RuntimeError25 } from "@ibi
4988
4993
  import { clone as clone17 } from "ramda";
4989
4994
 
4990
4995
  // src/service/utils/de-dq-cond/ps-de-dq-cond-engine.ts
4991
- import { isEmpty as isEmpty3 } from "ramda";
4996
+ import { isEmpty as isEmpty4 } from "ramda";
4992
4997
 
4993
4998
  // src/service/utils/de-dq-cond/ps-model-cond-engine-base.ts
4994
4999
  var PSModelCondEngineBase = class {
@@ -5295,7 +5300,7 @@ var _PSDEDQCondEngine = class _PSDEDQCondEngine extends PSModelCondEngineBase {
5295
5300
  testCond(cond, data, filter) {
5296
5301
  if (cond instanceof PSModelGroupCondBase) {
5297
5302
  const list = cond.getChildPSModelCondBases();
5298
- if (list == null || isEmpty3(list)) {
5303
+ if (list == null || isEmpty4(list)) {
5299
5304
  return !cond.isNotMode();
5300
5305
  }
5301
5306
  const bAnd = "AND" /* CONDOP_AND */ === cond.getCondOp();
@@ -5318,15 +5323,15 @@ var _PSDEDQCondEngine = class _PSDEDQCondEngine extends PSModelCondEngineBase {
5318
5323
  return bRet;
5319
5324
  }
5320
5325
  if (cond instanceof PSModelSingleCondBase) {
5321
- if (isEmpty3(cond.getParam())) {
5326
+ if (isEmpty4(cond.getParam())) {
5322
5327
  ibiz.log.warn("\u6CA1\u6709\u6307\u5B9A\u5C5E\u6027\u540D\u79F0", cond);
5323
5328
  }
5324
5329
  const objValue = data[cond.getParam().toLowerCase()];
5325
5330
  let objCondValue = null;
5326
5331
  const valType = cond.getValueType();
5327
5332
  const val = cond.getValue();
5328
- if (valType != null && !isEmpty3(valType)) {
5329
- if (isEmpty3(val)) {
5333
+ if (valType != null && !isEmpty4(valType)) {
5334
+ if (isEmpty4(val)) {
5330
5335
  ibiz.log.warn("\u6CA1\u6709\u6307\u5B9A\u4E0A\u4E0B\u6587\u53C2\u6570\u540D\u79F0");
5331
5336
  }
5332
5337
  if (_PSDEDQCondEngine.PARAMTYPE_WEBCONTEXT === valType) {
@@ -6361,7 +6366,7 @@ DEDQCondUtil.map = /* @__PURE__ */ new WeakMap();
6361
6366
 
6362
6367
  // src/service/utils/dynamic-code-list/dynamic-code-list.ts
6363
6368
  import { ModelError as ModelError5, RuntimeModelError as RuntimeModelError7 } from "@ibiz-template/core";
6364
- import { isNil as isNil4 } from "ramda";
6369
+ import { isNil as isNil5 } from "ramda";
6365
6370
  var DynamicCodeListCache = class {
6366
6371
  constructor(codeList) {
6367
6372
  /**
@@ -6594,7 +6599,7 @@ var DynamicCodeListCache = class {
6594
6599
  }
6595
6600
  const promise = this.load(context, params);
6596
6601
  const { cacheTimeout } = this.codeList;
6597
- const waitTime = cacheTimeout === -1 || isNil4(cacheTimeout) ? ibiz.config.codeList.timeout : this.codeList.cacheTimeout;
6602
+ const waitTime = cacheTimeout === -1 || isNil5(cacheTimeout) ? ibiz.config.codeList.timeout : this.codeList.cacheTimeout;
6598
6603
  const cacheData = {
6599
6604
  expirationTime: (/* @__PURE__ */ new Date()).getTime() + waitTime,
6600
6605
  promise
@@ -6608,17 +6613,17 @@ var DynamicCodeListCache = class {
6608
6613
  };
6609
6614
 
6610
6615
  // src/service/utils/de-cache/de-cache.ts
6611
- import { where, equals, clone as clone4, isNil as isNil6, isEmpty as isEmpty5 } from "ramda";
6616
+ import { where, equals, clone as clone4, isNil as isNil7, isEmpty as isEmpty6 } from "ramda";
6612
6617
  import { createUUID as createUUID2 } from "qx-util";
6613
6618
  import { RuntimeError as RuntimeError16 } from "@ibiz-template/core";
6614
6619
 
6615
6620
  // src/service/utils/service-exist-util/service-exist-util.ts
6616
6621
  import { RuntimeError as RuntimeError15 } from "@ibiz-template/core";
6617
- import { isEmpty as isEmpty4, isNil as isNil5 } from "ramda";
6622
+ import { isEmpty as isEmpty5, isNil as isNil6 } from "ramda";
6618
6623
  function isExistSrfKey(funcName, entity) {
6619
6624
  if (entity != null) {
6620
6625
  const { srfkey } = entity;
6621
- if (!isNil5(srfkey) && !isEmpty4(srfkey)) {
6626
+ if (!isNil6(srfkey) && !isEmpty5(srfkey)) {
6622
6627
  return true;
6623
6628
  }
6624
6629
  }
@@ -6626,7 +6631,7 @@ function isExistSrfKey(funcName, entity) {
6626
6631
  }
6627
6632
  function isExistSessionId(funcName, context) {
6628
6633
  const { srfsessionid } = context;
6629
- if (!isNil5(srfsessionid) && !isEmpty4(srfsessionid)) {
6634
+ if (!isNil6(srfsessionid) && !isEmpty5(srfsessionid)) {
6630
6635
  return true;
6631
6636
  }
6632
6637
  throw new RuntimeError15("\u6267\u884C\u300C".concat(funcName, "\u300D\u4E0D\u5B58\u5728\u300Csrfsessionid\u300D\u65E0\u6CD5\u5904\u7406"));
@@ -6722,7 +6727,7 @@ var DECache = class {
6722
6727
  }
6723
6728
  try {
6724
6729
  isExistSessionId("add", context);
6725
- if (isNil6(entity.srfkey) || isEmpty5(entity.srfkey)) {
6730
+ if (isNil7(entity.srfkey) || isEmpty6(entity.srfkey)) {
6726
6731
  entity.srfkey = createUUID2();
6727
6732
  }
6728
6733
  entity.srftempdate = (/* @__PURE__ */ new Date()).getTime();
@@ -6866,7 +6871,7 @@ var DECache = class {
6866
6871
  const t = this.getTransaction(context);
6867
6872
  for (let i = 0; i < entities.length; i++) {
6868
6873
  const entity = entities[i];
6869
- if (isNil6(entity.srfkey) || isEmpty5(entity.srfkey)) {
6874
+ if (isNil7(entity.srfkey) || isEmpty6(entity.srfkey)) {
6870
6875
  entity.srfkey = createUUID2();
6871
6876
  }
6872
6877
  entity.srftempdate = (/* @__PURE__ */ new Date()).getTime();
@@ -7057,7 +7062,7 @@ var DECache = class {
7057
7062
  }
7058
7063
  );
7059
7064
  const unionValues = unionKeys.map((key) => {
7060
- if (isNil6(data[key])) {
7065
+ if (isNil7(data[key])) {
7061
7066
  return "__empty__";
7062
7067
  }
7063
7068
  return data[key];
@@ -7131,7 +7136,7 @@ function calcResPath(context, entity) {
7131
7136
  }
7132
7137
 
7133
7138
  // src/service/utils/search-filter/search-filter.ts
7134
- import { isEmpty as isEmpty6, isNil as isNil7 } from "ramda";
7139
+ import { isEmpty as isEmpty7, isNil as isNil8 } from "ramda";
7135
7140
  var SearchFilter = class {
7136
7141
  /**
7137
7142
  * Creates an instance of SearchFilter.
@@ -7179,16 +7184,16 @@ var SearchFilter = class {
7179
7184
  this.sortMode = "ASC";
7180
7185
  this.context = context;
7181
7186
  if (data) {
7182
- if (!isNil7(data.page) && !isEmpty6(data.page)) {
7187
+ if (!isNil8(data.page) && !isEmpty7(data.page)) {
7183
7188
  this.page = data.page;
7184
7189
  }
7185
- if (!isNil7(data.size) && !isEmpty6(data.size)) {
7190
+ if (!isNil8(data.size) && !isEmpty7(data.size)) {
7186
7191
  this.size = data.size;
7187
7192
  }
7188
- if (!isNil7(data.query) && !isEmpty6(data.query)) {
7193
+ if (!isNil8(data.query) && !isEmpty7(data.query)) {
7189
7194
  this.query = data.query;
7190
7195
  }
7191
- if (!isNil7(data.sort) && !isEmpty6(data.sort)) {
7196
+ if (!isNil8(data.sort) && !isEmpty7(data.sort)) {
7192
7197
  const arr = data.sort.split(",");
7193
7198
  if (arr.length >= 1) {
7194
7199
  [this.sortField] = arr;
@@ -7910,7 +7915,7 @@ var FileService = class {
7910
7915
  };
7911
7916
 
7912
7917
  // src/service/app-data-entity/app-data-entity.ts
7913
- import { clone as clone5, isNil as isNil8 } from "ramda";
7918
+ import { clone as clone5, isNil as isNil9 } from "ramda";
7914
7919
  import { DataTypes } from "@ibiz-template/core";
7915
7920
  import { createUUID as createUUID3 } from "qx-util";
7916
7921
 
@@ -8003,7 +8008,7 @@ var AppDataEntity = class _AppDataEntity {
8003
8008
  enumerable: false,
8004
8009
  configurable: true,
8005
8010
  writable: true,
8006
- value: isNil8(this.srfkey) ? createUUID3() : this.srfkey
8011
+ value: isNil9(this.srfkey) ? createUUID3() : this.srfkey
8007
8012
  });
8008
8013
  this.defineProperties();
8009
8014
  }
@@ -8093,11 +8098,11 @@ var AppDataEntity = class _AppDataEntity {
8093
8098
  if (value == null) {
8094
8099
  return value;
8095
8100
  }
8096
- if (isNil8(dataType)) {
8101
+ if (isNil9(dataType)) {
8097
8102
  return value;
8098
8103
  }
8099
8104
  if (DataTypes.isNumber(dataType)) {
8100
- const numVal = !isNil8(value) && value !== "" ? Number(value) : value;
8105
+ const numVal = !isNil9(value) && value !== "" ? Number(value) : value;
8101
8106
  if (Number.isNaN(numVal)) {
8102
8107
  ibiz.log.debug("".concat(value, "\u4E0D\u80FD\u8F6C\u6362\u6210\u6570\u5B57"));
8103
8108
  return value;
@@ -8616,7 +8621,7 @@ import { clone as clone8 } from "@ibiz-template/core";
8616
8621
 
8617
8622
  // src/service/vo/control.vo.ts
8618
8623
  import { createUUID as createUUID4 } from "qx-util";
8619
- import { clone as clone7, isNil as isNil9 } from "ramda";
8624
+ import { clone as clone7, isNil as isNil10 } from "ramda";
8620
8625
  var BuildInKeys = [
8621
8626
  "srfkey",
8622
8627
  "srfmajortext",
@@ -8705,7 +8710,7 @@ var ControlVO = class _ControlVO {
8705
8710
  enumerable: false,
8706
8711
  configurable: true,
8707
8712
  writable: true,
8708
- value: isNil9(this.srfkey) ? createUUID4() : this.srfkey
8713
+ value: isNil10(this.srfkey) ? createUUID4() : this.srfkey
8709
8714
  });
8710
8715
  }
8711
8716
  Object.defineProperty(this, "srfuf", {
@@ -9429,7 +9434,7 @@ var V7AuthService = class {
9429
9434
  };
9430
9435
 
9431
9436
  // src/service/service/async-action/async-action.service.ts
9432
- import { isNil as isNil10 } from "ramda";
9437
+ import { isNil as isNil11 } from "ramda";
9433
9438
  var AsyncActionService = class {
9434
9439
  /**
9435
9440
  * 获取异步操作的集合
@@ -9440,7 +9445,7 @@ var AsyncActionService = class {
9440
9445
  */
9441
9446
  async fetch(params = {}) {
9442
9447
  const res = await ibiz.net.post("/portal/asyncaction/all", params);
9443
- if (isNil10(res.data)) {
9448
+ if (isNil11(res.data)) {
9444
9449
  res.data = [];
9445
9450
  }
9446
9451
  return res;
@@ -9465,7 +9470,7 @@ import {
9465
9470
  RuntimeError as RuntimeError23,
9466
9471
  RuntimeModelError as RuntimeModelError22
9467
9472
  } from "@ibiz-template/core";
9468
- import { isArray as isArray6, isNil as isNil11 } from "lodash-es";
9473
+ import { isArray as isArray6, isNil as isNil12 } from "lodash-es";
9469
9474
  import { ascSort } from "qx-util";
9470
9475
  import { clone as clone14 } from "ramda";
9471
9476
 
@@ -9887,6 +9892,8 @@ var DELogicLinkSingleCond = class extends DELogicLinkCond {
9887
9892
  */
9888
9893
  test(ctx, context, data) {
9889
9894
  const dst = ctx.params[this.dstParam];
9895
+ let result;
9896
+ let compareValue;
9890
9897
  switch (this.type) {
9891
9898
  case "ENTITYFIELD": {
9892
9899
  if (!this.value) {
@@ -9896,7 +9903,9 @@ var DELogicLinkSingleCond = class extends DELogicLinkCond {
9896
9903
  );
9897
9904
  }
9898
9905
  const value = data[this.value] != null ? data[this.value] : context[this.value];
9899
- return testCond(dst[this.dstField], this.op, value);
9906
+ compareValue = value;
9907
+ result = testCond(dst[this.dstField], this.op, value);
9908
+ break;
9900
9909
  }
9901
9910
  case "SRCENTITYFIELD": {
9902
9911
  if (!this.value) {
@@ -9906,13 +9915,26 @@ var DELogicLinkSingleCond = class extends DELogicLinkCond {
9906
9915
  );
9907
9916
  }
9908
9917
  const src = ctx.params[this.srcParam];
9909
- return testCond(dst[this.dstField], this.op, src[this.value]);
9918
+ compareValue = src[this.value];
9919
+ result = testCond(dst[this.dstField], this.op, src[this.value]);
9920
+ break;
9910
9921
  }
9911
9922
  case "CURTIME":
9912
9923
  throw new ModelError8(this.model, "\u6682\u672A\u652F\u6301\u6761\u4EF6\u503C\u7C7B\u578B\u4E3A[\u5F53\u524D\u65F6\u95F4]");
9913
9924
  default:
9914
- return testCond(dst[this.dstField], this.op, this.value);
9925
+ compareValue = this.value;
9926
+ result = testCond(dst[this.dstField], this.op, this.value);
9915
9927
  }
9928
+ ibiz.log.debug(
9929
+ "\u5B9E\u4F53\u903B\u8F91\u8FDE\u63A5\u6761\u4EF6\u9879\uFF1A".concat(this.model.name, "-\u6761\u4EF6\u503C\u7C7B\u578B\uFF1A").concat(this.type, "-\u6E90\u5C5E\u6027\u540D\u79F0\uFF1A").concat(this.dstField, "-\u6E90\u5BF9\u8C61\u503C\uFF1A"),
9930
+ dst[this.dstField],
9931
+ "-\u5BF9\u6BD4\u6761\u4EF6\uFF1A".concat(this.op),
9932
+ "-\u5BF9\u6BD4\u503C",
9933
+ compareValue,
9934
+ "-\u5BF9\u6BD4\u7ED3\u679C\uFF1A",
9935
+ result
9936
+ );
9937
+ return result;
9916
9938
  }
9917
9939
  };
9918
9940
 
@@ -9977,7 +9999,12 @@ var DELogicLinkGroupCond = class _DELogicLinkGroupCond extends DELogicLinkCond {
9977
9999
  break;
9978
10000
  }
9979
10001
  }
9980
- return this.notMode ? !bol : bol;
10002
+ const result = this.notMode ? !bol : bol;
10003
+ ibiz.log.debug(
10004
+ "\u5B9E\u4F53\u903B\u8F91\u8FDE\u63A5\u6761\u4EF6\u7EC4\u540D\u79F0\uFF1A".concat(this.model.name, "-\u6761\u4EF6\u7EC4\u6807\u8BC6\uFF1A").concat(this.model.id, "-\u8FD0\u884C\u7ED3\u679C\uFF1A"),
10005
+ result
10006
+ );
10007
+ return result;
9981
10008
  }
9982
10009
  };
9983
10010
 
@@ -10083,12 +10110,17 @@ var DEActionNode = class extends DELogicNode {
10083
10110
  if (res.ok) {
10084
10111
  ctx.params[retDELogicParamId] = res.data;
10085
10112
  }
10113
+ ibiz.log.debug(
10114
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u5B9E\u4F53\u884C\u4E3A\uFF09\uFF1A".concat(this.model.id, "-\u754C\u9762\u884C\u4E3A\u6240\u5C5E\u5B9E\u4F53\uFF1A").concat(dstAppDataEntityId, "-\u5B9E\u4F53\u884C\u4E3A\u6807\u8BC6\uFF1A").concat(dstAppDEActionId, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(retDELogicParamId, "-\u503C\uFF1A"),
10115
+ ctx.params[retDELogicParamId]
10116
+ );
10086
10117
  }
10087
10118
  };
10088
10119
 
10089
10120
  // src/de-logic/de-logic-node/start-node/start-node.ts
10090
10121
  var StartNode = class extends DELogicNode {
10091
10122
  async exec(_ctx) {
10123
+ ibiz.log.debug("\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u542F\u52A8\u8282\u70B9\uFF09\uFF1A".concat(this.model.id));
10092
10124
  }
10093
10125
  };
10094
10126
 
@@ -10122,6 +10154,10 @@ var EndNode = class extends DELogicNode {
10122
10154
  "\u6682\u672A\u652F\u6301\u7684\u7ED3\u675F\u8282\u70B9\u8FD4\u56DE\u503C\u7C7B\u578B: ".concat(returnType)
10123
10155
  );
10124
10156
  }
10157
+ ibiz.log.debug(
10158
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u7ED3\u675F\u8282\u70B9\uFF09\uFF1A".concat(this.model.id, "-\u8FD4\u56DE\u503C\u7C7B\u578B\uFF1A").concat(returnType, "-\u8FD4\u56DE\u503C\uFF1A"),
10159
+ ctx.result
10160
+ );
10125
10161
  }
10126
10162
  };
10127
10163
 
@@ -10204,27 +10240,46 @@ var PrepareParamNode = class extends DELogicNode {
10204
10240
  if (nodeParams == null ? void 0 : nodeParams.length) {
10205
10241
  await Promise.all(
10206
10242
  nodeParams.map((nodeParam) => {
10243
+ let result;
10244
+ let originValue;
10245
+ if (nodeParam.dstDELogicParamId) {
10246
+ originValue = clone10(ctx.params[nodeParam.dstDELogicParamId]);
10247
+ }
10207
10248
  switch (nodeParam.paramAction) {
10208
10249
  case "SETPARAMVALUE":
10209
- return this.setParamValue(nodeParam, ctx);
10250
+ result = this.setParamValue(nodeParam, ctx);
10251
+ break;
10210
10252
  case "RESETPARAM":
10211
- return this.resetParam(nodeParam, ctx);
10253
+ result = this.resetParam(nodeParam, ctx);
10254
+ break;
10212
10255
  case "COPYPARAM":
10213
- return this.copyParam(nodeParam, ctx);
10256
+ result = this.copyParam(nodeParam, ctx);
10257
+ break;
10214
10258
  case "BINDPARAM":
10215
- return this.bindParam(nodeParam, ctx);
10259
+ result = this.bindParam(nodeParam, ctx);
10260
+ break;
10216
10261
  case "RENEWPARAM":
10217
- return this.renewParam(nodeParam, ctx);
10262
+ result = this.renewParam(nodeParam, ctx);
10263
+ break;
10218
10264
  case "APPENDPARAM":
10219
- return this.appendParam(nodeParam, ctx);
10265
+ result = this.appendParam(nodeParam, ctx);
10266
+ break;
10220
10267
  case "SORTPARAM":
10221
- return this.sortParam(nodeParam, ctx);
10268
+ result = this.sortParam(nodeParam, ctx);
10269
+ break;
10222
10270
  default:
10223
10271
  throw new ModelError11(
10224
10272
  nodeParam,
10225
10273
  "\u6682\u672A\u652F\u6301\u903B\u8F91\u5904\u7406\u53C2\u6570\u64CD\u4F5C".concat(nodeParam.paramAction)
10226
10274
  );
10227
10275
  }
10276
+ ibiz.log.debug(
10277
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u51C6\u5907\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u53C2\u6570\u5904\u7406\u64CD\u4F5C\uFF1A").concat(nodeParam.paramAction, "-\u76EE\u6807\u903B\u8F91\u53C2\u6570\uFF1A").concat(nodeParam.dstDELogicParamId, "-\u6E90\u53C2\u6570\uFF08\u503C\uFF09\uFF1A"),
10278
+ originValue,
10279
+ "-\u76EE\u6807\u53C2\u6570\uFF08\u503C\uFF09\uFF1A",
10280
+ ctx.params[nodeParam.dstDELogicParamId]
10281
+ );
10282
+ return result;
10228
10283
  })
10229
10284
  );
10230
10285
  }
@@ -10358,6 +10413,10 @@ var DataSetNode = class extends DELogicNode {
10358
10413
  if (res.ok) {
10359
10414
  ctx.params[retDELogicParamId] = res.data;
10360
10415
  }
10416
+ ibiz.log.debug(
10417
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u6570\u636E\u96C6\u5408\uFF09\uFF1A".concat(this.model.id, "-\u6570\u636E\u96C6\u5B9E\u4F53\u6807\u8BC6\uFF1A").concat(dstAppDataEntityId, "-\u6570\u636E\u96C6\u6807\u8BC6\uFF1A").concat(dstAppDEDataSetId, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(retDELogicParamId, "-\u503C\uFF1A"),
10418
+ ctx.params[retDELogicParamId]
10419
+ );
10361
10420
  }
10362
10421
  };
10363
10422
 
@@ -10374,6 +10433,10 @@ var BindParamNode = class extends DELogicNode {
10374
10433
  }
10375
10434
  const srcVal = handleSrcVal(ctx, this.model);
10376
10435
  ctx.params[dstDELogicParamId] = srcVal;
10436
+ ibiz.log.debug(
10437
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u7ED1\u5B9A\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(dstDELogicParamId, "-\u503C\uFF1A"),
10438
+ srcVal
10439
+ );
10377
10440
  }
10378
10441
  };
10379
10442
 
@@ -10386,6 +10449,9 @@ var ResetParamNode = class extends DELogicNode {
10386
10449
  throw new RuntimeModelError16(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
10387
10450
  }
10388
10451
  ctx.resetParam(dstDELogicParamId);
10452
+ ibiz.log.debug(
10453
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u91CD\u7F6E\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u91CD\u7F6E\u53C2\u6570\uFF1A").concat(dstDELogicParamId)
10454
+ );
10389
10455
  }
10390
10456
  };
10391
10457
 
@@ -10398,6 +10464,9 @@ var RenewParamNode = class extends DELogicNode {
10398
10464
  throw new RuntimeModelError17(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
10399
10465
  }
10400
10466
  ctx.renewParam(dstDELogicParamId);
10467
+ ibiz.log.debug(
10468
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u91CD\u65B0\u5EFA\u7ACB\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u91CD\u5EFA\u53C2\u6570\uFF1A").concat(dstDELogicParamId)
10469
+ );
10401
10470
  }
10402
10471
  };
10403
10472
 
@@ -10415,6 +10484,10 @@ var CopyParamNode = class extends DELogicNode {
10415
10484
  }
10416
10485
  const srcVal = handleSrcVal(ctx, this.model);
10417
10486
  ctx.params[dstDELogicParamId] = clone11(srcVal);
10487
+ ibiz.log.debug(
10488
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u62F7\u8D1D\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(dstDELogicParamId, "-\u503C\uFF1A"),
10489
+ srcVal
10490
+ );
10418
10491
  }
10419
10492
  };
10420
10493
 
@@ -10431,6 +10504,10 @@ var SortParamNode = class extends DELogicNode {
10431
10504
  arr.sort((a, b) => {
10432
10505
  return dstSortDir === "ASC" ? a[key] - b[key] : b[key] - a[key];
10433
10506
  });
10507
+ ibiz.log.debug(
10508
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u6392\u5E8F\u6570\u7EC4\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u6392\u5E8F\u5C5E\u6027\uFF1A").concat(dstFieldName, "-\u6392\u5E8F\u6A21\u5F0F\uFF1A").concat(dstSortDir, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(dstDELogicParamId, "-\u6392\u5E8F\u540E\u6570\u7EC4\uFF1A"),
10509
+ arr
10510
+ );
10434
10511
  }
10435
10512
  };
10436
10513
 
@@ -10460,6 +10537,12 @@ var AppendParamNode = class extends DELogicNode {
10460
10537
  0,
10461
10538
  ...srcVal.slice(_srcIndex, _srcSize)
10462
10539
  );
10540
+ ibiz.log.debug(
10541
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u9644\u52A0\u5230\u6570\u7EC4\uFF09\uFF1A".concat(this.model.id, "-\u9644\u52A0\u53C2\u6570\uFF1A"),
10542
+ ctx.params,
10543
+ "-\u9644\u52A0\u503C\uFF1A",
10544
+ srcVal.slice(_srcIndex, _srcSize)
10545
+ );
10463
10546
  }
10464
10547
  };
10465
10548
 
@@ -10468,6 +10551,9 @@ import { HttpError as HttpError3 } from "@ibiz-template/core";
10468
10551
  var ThrowExceptionNode = class extends DELogicNode {
10469
10552
  async exec(_ctx) {
10470
10553
  const { errorCode, errorInfo } = this.model;
10554
+ ibiz.log.debug(
10555
+ "\u5B9E\u4F53\u903B\u8F91\u8282\u70B9\uFF08\u629B\u51FA\u5F02\u5E38\uFF09\uFF1A".concat(this.model.id, "-\u9519\u8BEF\u4EE3\u7801\uFF1A").concat(errorCode, "-\u9519\u8BEF\u4FE1\u606F\uFF1A").concat(errorInfo)
10556
+ );
10471
10557
  throw new HttpError3({
10472
10558
  response: {
10473
10559
  status: errorCode,
@@ -10544,6 +10630,7 @@ var DELogicParam = class {
10544
10630
  } else if (m.sessionParam) {
10545
10631
  throw new ModelError12(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B: \u64CD\u4F5C\u4F1A\u8BDD\u53D8\u91CF");
10546
10632
  }
10633
+ ibiz.log.debug("\u8BA1\u7B97\u5B9E\u4F53\u903B\u8F91\u53C2\u6570\uFF0C\u6807\u8BC6\uFF1A".concat(tag), "-\u503C\uFF1A", ctx.params[tag]);
10547
10634
  }
10548
10635
  /**
10549
10636
  * 重新建立变量
@@ -10561,6 +10648,11 @@ var DELogicParam = class {
10561
10648
  } else {
10562
10649
  throw new ModelError12(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B\u91CD\u65B0\u5EFA\u7ACB\u53D8\u91CF");
10563
10650
  }
10651
+ ibiz.log.debug(
10652
+ "\u91CD\u65B0\u5EFA\u7ACB\u5B9E\u4F53\u903B\u8F91\u53C2\u6570\uFF0C\u6807\u8BC6\uFF1A".concat(tag),
10653
+ "-\u503C\uFF1A",
10654
+ ctx.params[tag]
10655
+ );
10564
10656
  }
10565
10657
  };
10566
10658
 
@@ -10748,8 +10840,15 @@ async function execDELogic(deDELogic, context, data = {}, params = {}) {
10748
10840
  if (!deLogicMap.has(deDELogic)) {
10749
10841
  deLogicMap.set(deDELogic, new DELogic(deDELogic));
10750
10842
  }
10843
+ ibiz.log.debug(
10844
+ "\u5F00\u59CB\u6267\u884C\u5B9E\u4F53\u903B\u8F91\uFF0C\u903B\u8F91\u6807\u8BC6\uFF1A".concat(deDELogic.id, "-\u903B\u8F91\u540D\u79F0\uFF1A").concat(deDELogic.name)
10845
+ );
10751
10846
  const deLogic = deLogicMap.get(deDELogic);
10752
- return deLogic.exec(context, data, params);
10847
+ const result = await deLogic.exec(context, data, params);
10848
+ ibiz.log.debug(
10849
+ "\u7ED3\u675F\u6267\u884C\u5B9E\u4F53\u903B\u8F91\uFF0C\u903B\u8F91\u6807\u8BC6\uFF1A".concat(deDELogic.id, "-\u903B\u8F91\u540D\u79F0\uFF1A").concat(deDELogic.name)
10850
+ );
10851
+ return result;
10753
10852
  }
10754
10853
  async function execDELogicById(deDELogicId, dataEntityId, context, data, params) {
10755
10854
  const deLogic = await findDeLogic(
@@ -10870,7 +10969,7 @@ var DEActionMethod = class extends Method {
10870
10969
  let path2 = this.calcPath(context);
10871
10970
  if (this.method.needResourceKey) {
10872
10971
  let srfkey = context[this.entity.codeName.toLowerCase()];
10873
- if (isNil11(srfkey)) {
10972
+ if (isNil12(srfkey)) {
10874
10973
  srfkey = isArray6(data) ? null : data == null ? void 0 : data[this.entity.keyAppDEFieldId];
10875
10974
  }
10876
10975
  path2 = "".concat(path2, "/").concat(srfkey);
@@ -11295,7 +11394,7 @@ import {
11295
11394
  RuntimeModelError as RuntimeModelError23
11296
11395
  } from "@ibiz-template/core";
11297
11396
  import { isArray as isArray7 } from "lodash-es";
11298
- import { clone as clone15, isEmpty as isEmpty7, isNil as isNil12 } from "ramda";
11397
+ import { clone as clone15, isEmpty as isEmpty8, isNil as isNil13 } from "ramda";
11299
11398
  import { ascSort as ascSort2, descSort } from "qx-util";
11300
11399
  var FetchMethod = class extends Method {
11301
11400
  async exec(context, params, params2, header) {
@@ -11372,7 +11471,7 @@ var FetchMethod = class extends Method {
11372
11471
  }
11373
11472
  }
11374
11473
  }
11375
- if (!isNil12(filter.sortField) && !isEmpty7(filter.sortField)) {
11474
+ if (!isNil13(filter.sortField) && !isEmpty8(filter.sortField)) {
11376
11475
  if (filter.sortMode === "DESC") {
11377
11476
  list = descSort(list, filter.sortField);
11378
11477
  } else {
@@ -11439,7 +11538,7 @@ function presetDEMethodProvider() {
11439
11538
  }
11440
11539
 
11441
11540
  // src/service/service/internal-message/internal-message.service.ts
11442
- import { isNil as isNil13 } from "ramda";
11541
+ import { isNil as isNil14 } from "ramda";
11443
11542
  var InternalMessageService = class {
11444
11543
  constructor() {
11445
11544
  /**
@@ -11478,7 +11577,7 @@ var InternalMessageService = class {
11478
11577
  res.total = Number(res.headers["x-total"]);
11479
11578
  }
11480
11579
  }
11481
- if (isNil13(res.data)) {
11580
+ if (isNil14(res.data)) {
11482
11581
  res.data = [];
11483
11582
  }
11484
11583
  return res;
@@ -11504,6 +11603,16 @@ var InternalMessageService = class {
11504
11603
  async markRead(messageId) {
11505
11604
  await ibiz.net.post("".concat(this.baseUrl, "/").concat(messageId, "/mark_read"), {});
11506
11605
  }
11606
+ /**
11607
+ * 批量设置已读
11608
+ * @author lxm
11609
+ * @date 2024-02-04 03:59:52
11610
+ * @param {string} messageId
11611
+ * @return {*} {Promise<void>}
11612
+ */
11613
+ async batchMarkRead() {
11614
+ await ibiz.net.post("".concat(this.baseUrl, "/mark_all_read"), {});
11615
+ }
11507
11616
  /**
11508
11617
  * 获取未读数据的总条数
11509
11618
  * @author lxm
@@ -11684,7 +11793,7 @@ var TreeCodeListNodeData = class extends TreeNodeData {
11684
11793
 
11685
11794
  // src/service/vo/tree-node-data/tree-data-set-node-data.ts
11686
11795
  import { updateKeyDefine } from "@ibiz-template/core";
11687
- import { clone as clone16, isNil as isNil14 } from "ramda";
11796
+ import { clone as clone16, isNil as isNil15 } from "ramda";
11688
11797
  var CloneExcludeKeys = [
11689
11798
  "_id",
11690
11799
  "srfnodeid",
@@ -11808,7 +11917,7 @@ var TreeDataSetNodeData = class _TreeDataSetNodeData extends TreeNodeData {
11808
11917
  });
11809
11918
  Object.keys(this).forEach((key) => {
11810
11919
  const deKey = getDeKey(key);
11811
- if (isNil14(deKey) && !CloneExcludeKeys.includes(key)) {
11920
+ if (isNil15(deKey) && !CloneExcludeKeys.includes(key)) {
11812
11921
  cloneNodeData[key] = this[key];
11813
11922
  }
11814
11923
  });
@@ -11817,7 +11926,7 @@ var TreeDataSetNodeData = class _TreeDataSetNodeData extends TreeNodeData {
11817
11926
  return new Proxy(this, {
11818
11927
  set(target, p, value) {
11819
11928
  const deKey = getDeKey(p);
11820
- if (!isNil14(deKey)) {
11929
+ if (!isNil15(deKey)) {
11821
11930
  target._deData[deKey] = value;
11822
11931
  } else {
11823
11932
  target[p] = value;
@@ -11826,8 +11935,8 @@ var TreeDataSetNodeData = class _TreeDataSetNodeData extends TreeNodeData {
11826
11935
  },
11827
11936
  get(target, p, _receiver) {
11828
11937
  const deKey = getDeKey(p);
11829
- if (!isNil14(deKey)) {
11830
- return isNil14(target._deData[deKey]) ? getKeyDefault(p) : target._deData[deKey];
11938
+ if (!isNil15(deKey)) {
11939
+ return isNil15(target._deData[deKey]) ? getKeyDefault(p) : target._deData[deKey];
11831
11940
  }
11832
11941
  return target[p];
11833
11942
  },
@@ -11931,7 +12040,7 @@ var TreeStaticNodeData = class extends TreeNodeData {
11931
12040
 
11932
12041
  // src/service/vo/ui-map-field.ts
11933
12042
  import { DataTypes as DataTypes2 } from "@ibiz-template/core";
11934
- import { isNil as isNil15 } from "ramda";
12043
+ import { isNil as isNil16 } from "ramda";
11935
12044
  var UIMapField = class {
11936
12045
  constructor(uiKey, dataKey, opts = {}) {
11937
12046
  /**
@@ -11952,10 +12061,10 @@ var UIMapField = class {
11952
12061
  this.isRequestNeed = true;
11953
12062
  this.uiKey = uiKey;
11954
12063
  this.dataKey = dataKey;
11955
- if (!isNil15(opts.isOriginField)) {
12064
+ if (!isNil16(opts.isOriginField)) {
11956
12065
  this.isOriginField = opts.isOriginField;
11957
12066
  }
11958
- if (!isNil15(opts.dataType)) {
12067
+ if (!isNil16(opts.dataType)) {
11959
12068
  this.dataType = opts.dataType;
11960
12069
  }
11961
12070
  }
@@ -11970,7 +12079,7 @@ var UIMapField = class {
11970
12079
  return value;
11971
12080
  }
11972
12081
  if (DataTypes2.isNumber(this.dataType)) {
11973
- const numVal = !isNil15(value) && value !== "" ? Number(value) : value;
12082
+ const numVal = !isNil16(value) && value !== "" ? Number(value) : value;
11974
12083
  if (Number.isNaN(numVal)) {
11975
12084
  ibiz.log.debug("".concat(value, "\u4E0D\u80FD\u8F6C\u6362\u6210\u6570\u5B57"));
11976
12085
  return value;
@@ -12965,10 +13074,10 @@ var Application = class {
12965
13074
  */
12966
13075
  this.deName2DeCodeName = /* @__PURE__ */ new Map();
12967
13076
  this.net = new Net({
12968
- baseURL: "".concat(ibiz.env.baseUrl, "/").concat(model.appId)
13077
+ baseURL: "".concat(ibiz.env.baseUrl, "/").concat(this.appId)
12969
13078
  });
12970
13079
  this.configCache = new ConfigService(
12971
- model.appId,
13080
+ this.appId,
12972
13081
  "PSSysApp",
12973
13082
  model.codeName
12974
13083
  );
@@ -12985,7 +13094,7 @@ var Application = class {
12985
13094
  * @type {string}
12986
13095
  */
12987
13096
  get appId() {
12988
- return this.model.appId;
13097
+ return this.model.appId || ibiz.env.appId;
12989
13098
  }
12990
13099
  /**
12991
13100
  * 初始化应用
@@ -13043,7 +13152,7 @@ var Application = class {
13043
13152
  if (appDeId) {
13044
13153
  const appDataEntity = await ibiz.hub.getAppDataEntity(
13045
13154
  appDeId,
13046
- this.model.appId
13155
+ this.appId
13047
13156
  );
13048
13157
  const find = appDataEntity.appDEUIActions.find((action) => {
13049
13158
  return action.id === actionId;
@@ -13070,7 +13179,7 @@ var Application = class {
13070
13179
  if (!result && appDataEntityId) {
13071
13180
  const appDataEntity = await ibiz.hub.getAppDataEntity(
13072
13181
  appDataEntityId,
13073
- this.model.appId
13182
+ this.appId
13074
13183
  );
13075
13184
  result = (_b = appDataEntity.deopprivs) == null ? void 0 : _b.find((item) => item.name === id);
13076
13185
  }
@@ -13087,7 +13196,7 @@ var Application = class {
13087
13196
  async getDEUILogic(deUILogicId, appDataEntityId) {
13088
13197
  const appDataEntity = await ibiz.hub.getAppDataEntity(
13089
13198
  appDataEntityId,
13090
- this.model.appId
13199
+ this.appId
13091
13200
  );
13092
13201
  return appDataEntity.appDEUILogics.find((logic) => {
13093
13202
  return logic.id === deUILogicId;
@@ -13107,7 +13216,7 @@ var Application = class {
13107
13216
  this.mqtt = new MqttService(
13108
13217
  ibiz.appData.mqtttopic,
13109
13218
  getToken(),
13110
- this.model.appId
13219
+ this.appId
13111
13220
  );
13112
13221
  this.mqtt.evt.on("message", (message) => {
13113
13222
  ibiz.mc.command.next(message);
@@ -13281,7 +13390,7 @@ var TreeGridExNotifyState = /* @__PURE__ */ ((TreeGridExNotifyState2) => {
13281
13390
  // src/controller/common/view/view.controller.ts
13282
13391
  import { notNilEmpty as notNilEmpty6 } from "qx-util";
13283
13392
  import { IBizContext as IBizContext2, RuntimeError as RuntimeError34 } from "@ibiz-template/core";
13284
- import { isEmpty as isEmpty8, isNil as isNil21, isNotNil as isNotNil2 } from "ramda";
13393
+ import { isEmpty as isEmpty9, isNil as isNil22, isNotNil as isNotNil2 } from "ramda";
13285
13394
 
13286
13395
  // src/controller/utils/loading/loading.state.ts
13287
13396
  import { NOOP } from "@ibiz-template/core";
@@ -13923,9 +14032,9 @@ function hasSubRoute(routeDepth) {
13923
14032
  }
13924
14033
 
13925
14034
  // src/controller/utils/util/util.ts
13926
- import { isNil as isNil16 } from "ramda";
14035
+ import { isNil as isNil17 } from "ramda";
13927
14036
  function isValueChange(value, value2) {
13928
- if ((isNil16(value) || value === "") && (isNil16(value2) || value2 === "")) {
14037
+ if ((isNil17(value) || value === "") && (isNil17(value2) || value2 === "")) {
13929
14038
  return false;
13930
14039
  }
13931
14040
  return value !== value2;
@@ -13941,7 +14050,7 @@ function getOriginData(data) {
13941
14050
  // src/controller/utils/value-rule/value-rule.ts
13942
14051
  import { RuntimeError as RuntimeError29 } from "@ibiz-template/core";
13943
14052
  import { isNilOrEmpty as isNilOrEmpty6, isNumber } from "qx-util";
13944
- import { isNil as isNil17 } from "ramda";
14053
+ import { isNil as isNil18 } from "ramda";
13945
14054
  function generateRules(itemVRs, name, valueItemName) {
13946
14055
  const rules = [];
13947
14056
  itemVRs.forEach((item) => {
@@ -14006,7 +14115,7 @@ function generateEditorRules(editor) {
14006
14115
  if (maxLength) {
14007
14116
  rules.push({
14008
14117
  validator: (rule, value, callback) => {
14009
- if (!isNil17(value) && value.length > maxLength) {
14118
+ if (!isNil18(value) && value.length > maxLength) {
14010
14119
  callback(
14011
14120
  new Error(
14012
14121
  "\u5185\u5BB9\u957F\u5EA6\u5FC5\u987B\u5C0F\u4E8E\u7B49\u4E8E".concat(maxLength, ",\u5F53\u524D\u957F\u5EA6\u4E3A").concat(value.length)
@@ -14021,7 +14130,7 @@ function generateEditorRules(editor) {
14021
14130
  if (minLength) {
14022
14131
  rules.push({
14023
14132
  validator: (rule, value, callback) => {
14024
- if (!isNil17(value) && value.length < minLength) {
14133
+ if (!isNil18(value) && value.length < minLength) {
14025
14134
  callback(
14026
14135
  new Error(
14027
14136
  "\u5185\u5BB9\u957F\u5EA6\u5FC5\u987B\u5927\u4E8E\u7B49\u4E8E".concat(minLength, ",\u5F53\u524D\u957F\u5EA6\u4E3A").concat(value.length)
@@ -14033,10 +14142,10 @@ function generateEditorRules(editor) {
14033
14142
  }
14034
14143
  });
14035
14144
  }
14036
- if (!isNil17(maxValue)) {
14145
+ if (!isNil18(maxValue)) {
14037
14146
  rules.push({
14038
14147
  validator: (rule, value, callback) => {
14039
- if (!isNil17(value) && isNumber(value) && value > maxValue) {
14148
+ if (!isNil18(value) && isNumber(value) && value > maxValue) {
14040
14149
  callback(new Error("\u503C\u5FC5\u987B\u5C0F\u4E8E\u7B49\u4E8E".concat(maxValue)));
14041
14150
  } else {
14042
14151
  return true;
@@ -14044,10 +14153,10 @@ function generateEditorRules(editor) {
14044
14153
  }
14045
14154
  });
14046
14155
  }
14047
- if (!isNil17(minValue)) {
14156
+ if (!isNil18(minValue)) {
14048
14157
  rules.push({
14049
14158
  validator: (rule, value, callback) => {
14050
- if (!isNil17(value) && isNumber(value) && value < minValue) {
14159
+ if (!isNil18(value) && isNumber(value) && value < minValue) {
14051
14160
  callback(new Error("\u503C\u5FC5\u987B\u5927\u4E8E\u7B49\u4E8E".concat(minValue)));
14052
14161
  } else {
14053
14162
  return true;
@@ -14060,7 +14169,7 @@ function generateEditorRules(editor) {
14060
14169
 
14061
14170
  // src/controller/utils/value-ex/value-ex.ts
14062
14171
  import { RuntimeError as RuntimeError30 } from "@ibiz-template/core";
14063
- import { isNil as isNil18, mergeLeft } from "ramda";
14172
+ import { isNil as isNil19, mergeLeft } from "ramda";
14064
14173
  var ValueExUtil = class {
14065
14174
  /**
14066
14175
  * 合并默认值
@@ -14085,7 +14194,7 @@ var ValueExUtil = class {
14085
14194
  * @return {*} {string}
14086
14195
  */
14087
14196
  static toText(options, value) {
14088
- if (isNil18(value) || value === "") {
14197
+ if (isNil19(value) || value === "") {
14089
14198
  return "";
14090
14199
  }
14091
14200
  const { valueType, objectNameField, textSeparator } = this.mergeDefault(options);
@@ -14110,12 +14219,12 @@ var ValueExUtil = class {
14110
14219
  import { RuntimeError as RuntimeError31, ModelError as ModelError17 } from "@ibiz-template/core";
14111
14220
  import dayjs from "dayjs";
14112
14221
  import { createUUID as createUUID8 } from "qx-util";
14113
- import { isNil as isNil19, isNotNil } from "ramda";
14222
+ import { isNil as isNil20, isNotNil } from "ramda";
14114
14223
  function getDefaultValue(opts, origins) {
14115
14224
  var _a;
14116
14225
  const { name, valueType, defaultValue, valueFormat } = opts;
14117
14226
  const { data, context, params } = origins;
14118
- if (isNil19(valueType) && isNil19(defaultValue)) {
14227
+ if (isNil20(valueType) && isNil20(defaultValue)) {
14119
14228
  return;
14120
14229
  }
14121
14230
  if (valueType === "RESET") {
@@ -14298,6 +14407,7 @@ var BaseController = class {
14298
14407
  */
14299
14408
  this.childNames = [];
14300
14409
  this.name = model.name || model.id;
14410
+ this.preprocessModel(model);
14301
14411
  this.initState();
14302
14412
  this.convertMultipleLanguages();
14303
14413
  }
@@ -14311,6 +14421,16 @@ var BaseController = class {
14311
14421
  get _evt() {
14312
14422
  return this.evt;
14313
14423
  }
14424
+ /**
14425
+ * 根据需求对model进行预处理
14426
+ *
14427
+ * @author chitanda
14428
+ * @date 2024-02-27 11:02:00
14429
+ * @protected
14430
+ * @param {T} _model
14431
+ */
14432
+ preprocessModel(_model) {
14433
+ }
14314
14434
  /**
14315
14435
  * 初始化state的属性放,一般情况下只需要把对应的默认值直接赋值给state
14316
14436
  * 如果需要构造特殊class类型的state,可以重写该方法时,
@@ -14469,7 +14589,7 @@ var BaseController = class {
14469
14589
 
14470
14590
  // src/controller/utils/view-msg/view-msg-controller.ts
14471
14591
  import { RuntimeError as RuntimeError33, RuntimeModelError as RuntimeModelError24 } from "@ibiz-template/core";
14472
- import { isNil as isNil20, mergeRight as mergeRight2 } from "ramda";
14592
+ import { isNil as isNil21, mergeRight as mergeRight2 } from "ramda";
14473
14593
  var ViewMsgController = class _ViewMsgController {
14474
14594
  constructor(msgGroupId) {
14475
14595
  this.msgGroupId = msgGroupId;
@@ -14654,19 +14774,19 @@ var ViewMsgController = class _ViewMsgController {
14654
14774
  const removeModeField = this.getDeFieldName(entity, removeFlagAppDEFieldId);
14655
14775
  const deViewMessages = dataSet.map((item) => {
14656
14776
  const message = {};
14657
- if (positionField && !isNil20(item[positionField])) {
14777
+ if (positionField && !isNil21(item[positionField])) {
14658
14778
  message.position = item[positionField];
14659
14779
  }
14660
- if (titleField && !isNil20(item[titleField])) {
14780
+ if (titleField && !isNil21(item[titleField])) {
14661
14781
  message.title = item[titleField];
14662
14782
  }
14663
- if (messageField && !isNil20(item[messageField])) {
14783
+ if (messageField && !isNil21(item[messageField])) {
14664
14784
  message.message = item[messageField];
14665
14785
  }
14666
- if (typeField && !isNil20(item[typeField])) {
14786
+ if (typeField && !isNil21(item[typeField])) {
14667
14787
  message.messageType = item[typeField];
14668
14788
  }
14669
- if (removeModeField && !isNil20(item[removeModeField])) {
14789
+ if (removeModeField && !isNil21(item[removeModeField])) {
14670
14790
  message.removeMode = item[removeModeField];
14671
14791
  }
14672
14792
  return mergeRight2(basicMsg, message);
@@ -14825,6 +14945,7 @@ var ViewController = class extends BaseController {
14825
14945
  this.state.caption = this.model.caption;
14826
14946
  this.state.srfactiveviewdata = null;
14827
14947
  this.state.viewMessages = {};
14948
+ this.state.isClosing = false;
14828
14949
  }
14829
14950
  async onCreated() {
14830
14951
  await super.onCreated();
@@ -14904,8 +15025,8 @@ var ViewController = class extends BaseController {
14904
15025
  * @protected
14905
15026
  */
14906
15027
  handleContextParams() {
14907
- this.context.srfappid = this.model.appId;
14908
- if (isNil21(this.context.srfsessionid) || isEmpty8(this.context.srfsessionid)) {
15028
+ this.context.srfappid = this.model.appId || ibiz.env.appId;
15029
+ if (isNil22(this.context.srfsessionid) || isEmpty9(this.context.srfsessionid)) {
14909
15030
  const domain = ibiz.uiDomainManager.create(this.id);
14910
15031
  this.context.srfsessionid = domain.id;
14911
15032
  }
@@ -15305,7 +15426,7 @@ var CodeListEditorController = class extends EditorController {
15305
15426
 
15306
15427
  // src/controller/common/control/control.controller.ts
15307
15428
  import { IBizContext as IBizContext3, IBizParams, NoticeError as NoticeError2 } from "@ibiz-template/core";
15308
- import { clone as clone18, isNil as isNil22 } from "ramda";
15429
+ import { clone as clone18, isNil as isNil23 } from "ramda";
15309
15430
  import { notNilEmpty as notNilEmpty7 } from "qx-util";
15310
15431
  var ControlController = class extends BaseController {
15311
15432
  /**
@@ -15593,7 +15714,7 @@ var ControlController = class extends BaseController {
15593
15714
  let message;
15594
15715
  let duration;
15595
15716
  if (msgItem && msgItem.content) {
15596
- duration = isNil22(msgItem.timeout) ? void 0 : msgItem.timeout / 1e3;
15717
+ duration = isNil23(msgItem.timeout) ? void 0 : msgItem.timeout / 1e3;
15597
15718
  const scriptParams = { ...this.getEventArgs() };
15598
15719
  if (opts == null ? void 0 : opts.data) {
15599
15720
  scriptParams.data = opts.data;
@@ -15645,6 +15766,13 @@ var MDControlController = class extends ControlController {
15645
15766
  * @protected
15646
15767
  */
15647
15768
  this.commandDataChange = false;
15769
+ /**
15770
+ * 是否设置过排序条件,比如searchBars默认点击分组时设置了
15771
+ * @return {*}
15772
+ * @author: zhujiamin
15773
+ * @Date: 2024-02-22 16:10:23
15774
+ */
15775
+ this.isSetSort = false;
15648
15776
  /**
15649
15777
  * 实体属性映射,key是id,value是name
15650
15778
  * @author lxm
@@ -15716,7 +15844,9 @@ var MDControlController = class extends ControlController {
15716
15844
  fn(msg);
15717
15845
  }, 300);
15718
15846
  ibiz.mc.command.change.on(this.onDataChange);
15719
- this.setSort();
15847
+ if (!this.isSetSort) {
15848
+ this.setSort();
15849
+ }
15720
15850
  }
15721
15851
  async onMounted() {
15722
15852
  await super.onMounted();
@@ -15930,9 +16060,9 @@ var MDControlController = class extends ControlController {
15930
16060
  await this.startLoading();
15931
16061
  let needRefresh = false;
15932
16062
  try {
15933
- const deName = calcDeCodeNameById(this.model.appDataEntityId);
15934
16063
  await handleAllSettled(
15935
16064
  data.map(async (item) => {
16065
+ const deName = this.getRemoveDeName(item);
15936
16066
  if (item.srfuf !== 0 /* CREATE */) {
15937
16067
  const tempContext = context.clone();
15938
16068
  tempContext[deName] = item.srfkey;
@@ -15964,6 +16094,16 @@ var MDControlController = class extends ControlController {
15964
16094
  this.state.selectedData = [];
15965
16095
  await this._evt.emit("onRemoveSuccess", void 0);
15966
16096
  }
16097
+ /**
16098
+ * 获取删除实体codeName
16099
+ * @param {IData} _item
16100
+ * @return {*}
16101
+ * @author: zhujiamin
16102
+ * @Date: 2024-02-22 16:47:44
16103
+ */
16104
+ getRemoveDeName(_item) {
16105
+ return calcDeCodeNameById(this.model.appDataEntityId);
16106
+ }
15967
16107
  /**
15968
16108
  * 后台删除结束后界面删除逻辑
15969
16109
  *
@@ -16181,7 +16321,7 @@ var AppMenuController = class extends ControlController {
16181
16321
  throw new RuntimeModelError26(menuItem, "\u6CA1\u6709\u914D\u7F6E\u5E94\u7528\u529F\u80FD");
16182
16322
  }
16183
16323
  const tempContext = this.context.clone();
16184
- tempContext.srfappid = menuItem.appId;
16324
+ tempContext.srfappid = menuItem.appId || ibiz.env.appId;
16185
16325
  if (this.routeDepth && useDepth) {
16186
16326
  Object.assign(tempContext, {
16187
16327
  toRouteDepth: this.routeDepth + 1
@@ -16626,7 +16766,7 @@ import isSameOrBefore from "dayjs/plugin/isSameOrBefore";
16626
16766
  import quarterOfYear from "dayjs/plugin/quarterOfYear";
16627
16767
  import weekOfYear from "dayjs/plugin/weekOfYear";
16628
16768
  import isoWeek from "dayjs/plugin/isoWeek";
16629
- import { clone as clone20, isNil as isNil23, mergeDeepRight } from "ramda";
16769
+ import { clone as clone20, isNil as isNil24, mergeDeepRight } from "ramda";
16630
16770
  dayjs4.extend(minMax2);
16631
16771
  dayjs4.extend(isSameOrBefore);
16632
16772
  dayjs4.extend(quarterOfYear);
@@ -16722,10 +16862,10 @@ var BaseSeriesGenerator = class {
16722
16862
  * @return {*} {(string | undefined)}
16723
16863
  */
16724
16864
  translateVal(codeListKey, val, isExclude = false) {
16725
- if (isNil23(val)) {
16865
+ if (isNil24(val)) {
16726
16866
  return void 0;
16727
16867
  }
16728
- if (isNil23(codeListKey)) {
16868
+ if (isNil24(codeListKey)) {
16729
16869
  return val;
16730
16870
  }
16731
16871
  const codeListItems = this.chartGenerator.codeListMap.get(codeListKey);
@@ -16774,7 +16914,7 @@ var BaseSeriesGenerator = class {
16774
16914
  seriesCodeListId,
16775
16915
  item[this.groupField]
16776
16916
  );
16777
- if (isNil23(groupVal)) {
16917
+ if (isNil24(groupVal)) {
16778
16918
  return;
16779
16919
  }
16780
16920
  group = groupVal;
@@ -18044,6 +18184,8 @@ var UILogicLinkSingleCond = class extends UILogicLinkCond {
18044
18184
  srcDEUILogicParamId: this.dstParam,
18045
18185
  srcFieldName: this.dstField
18046
18186
  });
18187
+ let result;
18188
+ let compareValue;
18047
18189
  switch (this.type) {
18048
18190
  case "ENTITYFIELD": {
18049
18191
  if (!this.value) {
@@ -18053,7 +18195,9 @@ var UILogicLinkSingleCond = class extends UILogicLinkCond {
18053
18195
  );
18054
18196
  }
18055
18197
  const value = data[this.value] != null ? data[this.value] : context[this.value];
18056
- return testCond(dstVal, this.op, value);
18198
+ compareValue = value;
18199
+ result = testCond(dstVal, this.op, value);
18200
+ break;
18057
18201
  }
18058
18202
  case "SRCENTITYFIELD": {
18059
18203
  if (!this.value) {
@@ -18066,13 +18210,26 @@ var UILogicLinkSingleCond = class extends UILogicLinkCond {
18066
18210
  srcDEUILogicParamId: this.srcParam,
18067
18211
  srcFieldName: this.value
18068
18212
  });
18069
- return testCond(dstVal, this.op, srcVal);
18213
+ compareValue = srcVal;
18214
+ result = testCond(dstVal, this.op, srcVal);
18215
+ break;
18070
18216
  }
18071
18217
  case "CURTIME":
18072
18218
  throw new ModelError19(this.model, "\u6682\u672A\u652F\u6301\u6761\u4EF6\u503C\u7C7B\u578B\u4E3A[\u5F53\u524D\u65F6\u95F4]");
18073
18219
  default:
18074
- return testCond(dstVal, this.op, this.value);
18220
+ compareValue = this.value;
18221
+ result = testCond(dstVal, this.op, this.value);
18075
18222
  }
18223
+ ibiz.log.debug(
18224
+ "\u754C\u9762\u903B\u8F91\u8FDE\u63A5\u6761\u4EF6\u9879\uFF1A".concat(this.model.name, "-\u6761\u4EF6\u503C\u7C7B\u578B\uFF1A").concat(this.type, "-\u6E90\u5C5E\u6027\u540D\u79F0\uFF1A").concat(this.dstField, "-\u6E90\u5BF9\u8C61\u503C\uFF1A"),
18225
+ dstVal,
18226
+ "-\u5BF9\u6BD4\u6761\u4EF6\uFF1A".concat(this.op),
18227
+ "-\u5BF9\u6BD4\u503C\uFF1A",
18228
+ compareValue,
18229
+ "-\u5BF9\u6BD4\u7ED3\u679C\uFF1A",
18230
+ result
18231
+ );
18232
+ return result;
18076
18233
  }
18077
18234
  };
18078
18235
 
@@ -18137,7 +18294,12 @@ var UILogicLinkGroupCond = class _UILogicLinkGroupCond extends UILogicLinkCond {
18137
18294
  break;
18138
18295
  }
18139
18296
  }
18140
- return this.notMode ? !bol : bol;
18297
+ const result = this.notMode ? !bol : bol;
18298
+ ibiz.log.debug(
18299
+ "\u754C\u9762\u903B\u8F91\u8FDE\u63A5\u6761\u4EF6\u7EC4\u540D\u79F0\uFF1A".concat(this.model.name, "-\u6761\u4EF6\u7EC4\u6807\u8BC6\uFF1A").concat(this.model.id, "-\u8FD0\u884C\u7ED3\u679C\uFF1A"),
18300
+ result
18301
+ );
18302
+ return result;
18141
18303
  }
18142
18304
  };
18143
18305
 
@@ -18266,6 +18428,10 @@ var DEActionNode2 = class extends UILogicNode {
18266
18428
  if (res.ok) {
18267
18429
  ctx.params[retDEUILogicParamId] = res.data;
18268
18430
  }
18431
+ ibiz.log.debug(
18432
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u5B9E\u4F53\u884C\u4E3A\uFF09\uFF1A".concat(this.model.id, "-\u754C\u9762\u884C\u4E3A\u6240\u5C5E\u5B9E\u4F53\uFF1A").concat(dstAppDataEntityId, "-\u5B9E\u4F53\u884C\u4E3A\u6807\u8BC6\uFF1A").concat(dstAppDEActionId, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(retDEUILogicParamId, "-\u503C\uFF1A"),
18433
+ ctx.params[retDEUILogicParamId]
18434
+ );
18269
18435
  }
18270
18436
  };
18271
18437
 
@@ -18273,7 +18439,7 @@ var DEActionNode2 = class extends UILogicNode {
18273
18439
  import { RuntimeModelError as RuntimeModelError35 } from "@ibiz-template/core";
18274
18440
  var DEUIActionNode = class extends UILogicNode {
18275
18441
  async exec(ctx) {
18276
- const { dstAppDEUIActionId, dstDEUILogicParamId } = this.model;
18442
+ const { dstAppDEUIActionId, dstDEUILogicParamId, dstAppDataEntityId } = this.model;
18277
18443
  const { data, parameters } = ctx;
18278
18444
  if (!dstAppDEUIActionId) {
18279
18445
  throw new RuntimeModelError35(this.model, "\u672A\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
@@ -18287,6 +18453,9 @@ var DEUIActionNode = class extends UILogicNode {
18287
18453
  actionData = [param];
18288
18454
  }
18289
18455
  }
18456
+ ibiz.log.debug(
18457
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u5B9E\u4F53\u754C\u9762\u884C\u4E3A\uFF09\uFF1A".concat(this.model.id, "-\u754C\u9762\u884C\u4E3A\u6807\u8BC6\uFF1A").concat(dstAppDEUIActionId, "-\u754C\u9762\u884C\u4E3A\u6240\u5C5E\u5B9E\u4F53\uFF1A").concat(dstAppDataEntityId, "-\u76EE\u6807\u903B\u8F91\u53C2\u6570\u5BF9\u8C61\uFF1A").concat(dstDEUILogicParamId)
18458
+ );
18290
18459
  await UIActionUtil.execAndResolved(
18291
18460
  dstAppDEUIActionId,
18292
18461
  {
@@ -18303,6 +18472,7 @@ var DEUIActionNode = class extends UILogicNode {
18303
18472
  // src/ui-logic/ui-logic-node/start-node/start-node.ts
18304
18473
  var StartNode2 = class extends UILogicNode {
18305
18474
  async exec(_ctx) {
18475
+ ibiz.log.debug("\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u542F\u52A8\u8282\u70B9\uFF09\uFF1A".concat(this.model.id));
18306
18476
  }
18307
18477
  };
18308
18478
 
@@ -18336,6 +18506,10 @@ var EndNode2 = class extends UILogicNode {
18336
18506
  "\u6682\u672A\u652F\u6301\u7684\u7ED3\u675F\u8282\u70B9\u8FD4\u56DE\u503C\u7C7B\u578B: ".concat(returnType)
18337
18507
  );
18338
18508
  }
18509
+ ibiz.log.debug(
18510
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u7ED3\u675F\u8282\u70B9\uFF09\uFF1A".concat(this.model.id, "-\u8FD4\u56DE\u503C\u7C7B\u578B\uFF1A").concat(returnType, "-\u8FD4\u56DE\u503C\uFF1A"),
18511
+ ctx.result
18512
+ );
18339
18513
  }
18340
18514
  };
18341
18515
 
@@ -18349,6 +18523,10 @@ var PrepareJSParamNode = class extends UILogicNode {
18349
18523
  return;
18350
18524
  }
18351
18525
  for (const nodeParam of nodeParams) {
18526
+ let originValue;
18527
+ if (nodeParam.dstDEUILogicParamId) {
18528
+ originValue = clone22(ctx.params[nodeParam.dstDEUILogicParamId]);
18529
+ }
18352
18530
  switch (nodeParam.paramAction) {
18353
18531
  case "SETPARAMVALUE":
18354
18532
  await this.setParamValue(nodeParam, ctx);
@@ -18377,6 +18555,12 @@ var PrepareJSParamNode = class extends UILogicNode {
18377
18555
  "\u6682\u672A\u652F\u6301\u903B\u8F91\u5904\u7406\u53C2\u6570\u64CD\u4F5C".concat(nodeParam.paramAction)
18378
18556
  );
18379
18557
  }
18558
+ ibiz.log.debug(
18559
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u51C6\u5907\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u53C2\u6570\u5904\u7406\u64CD\u4F5C\uFF1A").concat(nodeParam.paramAction, "-\u76EE\u6807\u903B\u8F91\u53C2\u6570\uFF1A").concat(nodeParam.dstDEUILogicParamId, "-\u6E90\u53C2\u6570\uFF08\u503C\uFF09\uFF1A"),
18560
+ originValue,
18561
+ "-\u76EE\u6807\u53C2\u6570\uFF08\u503C\uFF09\uFF1A",
18562
+ ctx.params[nodeParam.dstDEUILogicParamId]
18563
+ );
18380
18564
  }
18381
18565
  }
18382
18566
  /**
@@ -18533,6 +18717,10 @@ var ViewCtrlInvokeNode = class extends UILogicNode {
18533
18717
  if (!invokeCtrl[invokeMethod] || !isFunction(invokeCtrl[invokeMethod])) {
18534
18718
  throw new RuntimeError42("\u6CA1\u6709\u627E\u5230\u8C03\u7528\u65B9\u6CD5".concat(invokeMethod));
18535
18719
  }
18720
+ ibiz.log.debug(
18721
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u89C6\u56FE\u90E8\u4EF6\u8C03\u7528\uFF09\uFF1A".concat(this.model.id, "-\u8C03\u7528\u89C6\u56FE\u90E8\u4EF6\u540D\u79F0\uFF1A").concat(invokeCtrlId, "-\u8C03\u7528\u65B9\u6CD5\u540D\u79F0\uFF1A").concat(invokeMethod, "-\u89E6\u53D1\u53C2\u6570\uFF1A"),
18722
+ invokeParam
18723
+ );
18536
18724
  await invokeCtrl[invokeMethod](invokeParam);
18537
18725
  }
18538
18726
  };
@@ -18550,6 +18738,10 @@ var BindParamNode2 = class extends UILogicNode {
18550
18738
  }
18551
18739
  const srcVal = handleSrcVal2(ctx, this.model);
18552
18740
  ctx.params[dstDEUILogicParamId] = srcVal;
18741
+ ibiz.log.debug(
18742
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u7ED1\u5B9A\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(dstDEUILogicParamId, "-\u503C\uFF1A"),
18743
+ srcVal
18744
+ );
18553
18745
  }
18554
18746
  };
18555
18747
 
@@ -18615,6 +18807,9 @@ var MsgBoxNode = class extends UILogicNode {
18615
18807
  default:
18616
18808
  throw new ModelError23(this.model, "".concat(buttonsType, "\u6682\u672A\u652F\u6301"));
18617
18809
  }
18810
+ ibiz.log.debug(
18811
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u6D88\u606F\u5F39\u7A97\uFF09\uFF1A".concat(this.model.id, "-\u6D88\u606F\u7C7B\u578B\uFF1A").concat(type, "-\u6D88\u606F\uFF1A").concat(message)
18812
+ );
18618
18813
  const result = await ibiz.modal.confirm(modalParams);
18619
18814
  ctx.setLastReturn(resultTags[result ? 0 : 1]);
18620
18815
  }
@@ -18623,6 +18818,9 @@ var MsgBoxNode = class extends UILogicNode {
18623
18818
  // src/ui-logic/ui-logic-node/pf-plugin-node/pf-plugin-node.ts
18624
18819
  var PFPluginNode = class extends UILogicNode {
18625
18820
  async exec(ctx) {
18821
+ ibiz.log.debug(
18822
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u524D\u7AEF\u63D2\u4EF6\uFF09\uFF1A".concat(this.model.id, "-\u63D2\u4EF6\u6807\u8BC6\uFF1A").concat(this.model.sysPFPluginId)
18823
+ );
18626
18824
  const provider = await getUILogicNodeProvider(this.model);
18627
18825
  if (provider) {
18628
18826
  await provider.exec(this.model, ctx);
@@ -18652,6 +18850,9 @@ var ResetParamNode2 = class extends UILogicNode {
18652
18850
  throw new RuntimeModelError40(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
18653
18851
  }
18654
18852
  ctx.resetParam(dstDEUILogicParamId);
18853
+ ibiz.log.debug(
18854
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u91CD\u7F6E\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u91CD\u7F6E\u53C2\u6570\uFF1A").concat(dstDEUILogicParamId)
18855
+ );
18655
18856
  }
18656
18857
  };
18657
18858
 
@@ -18669,6 +18870,10 @@ var CopyParamNode2 = class extends UILogicNode {
18669
18870
  }
18670
18871
  const srcVal = handleSrcVal2(ctx, this.model);
18671
18872
  ctx.params[dstDEUILogicParamId] = clone23(srcVal);
18873
+ ibiz.log.debug(
18874
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u62F7\u8D1D\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(dstDEUILogicParamId, "-\u503C\uFF1A"),
18875
+ srcVal
18876
+ );
18672
18877
  }
18673
18878
  };
18674
18879
 
@@ -18698,6 +18903,12 @@ var AppendParamNode2 = class extends UILogicNode {
18698
18903
  0,
18699
18904
  ...srcVal.slice(_srcIndex, _srcSize)
18700
18905
  );
18906
+ ibiz.log.debug(
18907
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u9644\u52A0\u5230\u6570\u7EC4\uFF09\uFF1A".concat(this.model.id, "-\u9644\u52A0\u53C2\u6570\uFF1A"),
18908
+ ctx.params,
18909
+ "-\u9644\u52A0\u503C\uFF1A",
18910
+ srcVal.slice(_srcIndex, _srcSize)
18911
+ );
18701
18912
  }
18702
18913
  };
18703
18914
 
@@ -18714,6 +18925,10 @@ var SortParamNode2 = class extends UILogicNode {
18714
18925
  arr.sort((a, b) => {
18715
18926
  return dstSortDir === "ASC" ? a[key] - b[key] : b[key] - a[key];
18716
18927
  });
18928
+ ibiz.log.debug(
18929
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u6392\u5E8F\u6570\u7EC4\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u6392\u5E8F\u5C5E\u6027\uFF1A").concat(dstFieldName, "-\u6392\u5E8F\u6A21\u5F0F\uFF1A").concat(dstSortDir, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(dstDEUILogicParamId, "-\u6392\u5E8F\u540E\u6570\u7EC4\uFF1A"),
18930
+ arr
18931
+ );
18717
18932
  }
18718
18933
  };
18719
18934
 
@@ -18726,6 +18941,9 @@ var RenewParamNode2 = class extends UILogicNode {
18726
18941
  throw new RuntimeModelError44(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
18727
18942
  }
18728
18943
  ctx.renewParam(dstDEUILogicParamId);
18944
+ ibiz.log.debug(
18945
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u91CD\u65B0\u5EFA\u7ACB\u53C2\u6570\uFF09\uFF1A".concat(this.model.id, "-\u91CD\u5EFA\u53C2\u6570\uFF1A").concat(dstDEUILogicParamId)
18946
+ );
18729
18947
  }
18730
18948
  };
18731
18949
 
@@ -18753,6 +18971,10 @@ var DataSetNode2 = class extends UILogicNode {
18753
18971
  if (res.ok) {
18754
18972
  ctx.params[retDEUILogicParamId] = res.data;
18755
18973
  }
18974
+ ibiz.log.debug(
18975
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u6570\u636E\u96C6\u5408\uFF09\uFF1A".concat(this.model.id, "-\u6570\u636E\u96C6\u5B9E\u4F53\u6807\u8BC6\uFF1A").concat(dstAppDataEntityId, "-\u6570\u636E\u96C6\u6807\u8BC6\uFF1A").concat(dstAppDEDataSetId, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(retDEUILogicParamId, "-\u503C\uFF1A"),
18976
+ ctx.params[retDEUILogicParamId]
18977
+ );
18756
18978
  }
18757
18979
  };
18758
18980
 
@@ -18761,6 +18983,9 @@ import { RuntimeError as RuntimeError43 } from "@ibiz-template/core";
18761
18983
  var ThrowExceptionNode2 = class extends UILogicNode {
18762
18984
  async exec(_ctx) {
18763
18985
  const { errorInfo } = this.model;
18986
+ ibiz.log.debug(
18987
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u629B\u51FA\u5F02\u5E38\uFF09\uFF1A".concat(this.model.id, "-\u9519\u8BEF\u4FE1\u606F\uFF1A").concat(errorInfo)
18988
+ );
18764
18989
  throw new RuntimeError43(errorInfo);
18765
18990
  }
18766
18991
  };
@@ -18788,6 +19013,10 @@ var ViewCtrlFireEventNode = class extends UILogicNode {
18788
19013
  if (!eventParam) {
18789
19014
  throw new RuntimeError44("\u6CA1\u6709\u627E\u5230\u4E8B\u4EF6\u53C2\u6570\u5BF9\u8C61".concat(eventParamId));
18790
19015
  }
19016
+ ibiz.log.debug(
19017
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u89C6\u56FE\u90E8\u4EF6\u4E8B\u4EF6\u89E6\u53D1\u903B\u8F91\uFF09\uFF1A".concat(this.model.id, "-\u8C03\u7528\u89C6\u56FE\u90E8\u4EF6\u540D\u79F0\uFF1A").concat(fireCtrlId, "-\u89E6\u53D1\u4E8B\u4EF6\u540D\u79F0\uFF1A").concat(eventName, "-\u89E6\u53D1\u53C2\u6570\uFF1A"),
19018
+ eventParam
19019
+ );
18791
19020
  await invokeCtrl.evt.emit(eventName, eventParam);
18792
19021
  }
18793
19022
  };
@@ -18825,12 +19054,20 @@ var ExecuteDELogicNode = class extends UILogicNode {
18825
19054
  if (retDEUILogicParamId) {
18826
19055
  ctx.params[retDEUILogicParamId] = result;
18827
19056
  }
19057
+ ibiz.log.debug(
19058
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u6267\u884C\u5B9E\u4F53\u903B\u8F91\uFF09\uFF1A".concat(this.model.id, "-\u5B9E\u4F53\u903B\u8F91\u6807\u8BC6\uFF1A").concat(dstAppDELogicId, "-\u5B9E\u4F53\u903B\u8F91\u6240\u5C5E\u5B9E\u4F53\uFF1A").concat(dstAppDataEntityId, "-\u53C2\u6570\u540D\u79F0\uFF1A").concat(retDEUILogicParamId, "-\u503C\uFF1A"),
19059
+ result
19060
+ );
18828
19061
  }
18829
19062
  };
18830
19063
 
18831
19064
  // src/ui-logic/ui-logic-node/raw-js-code-node/raw-js-code-node.ts
18832
19065
  var RawJSCodeNode = class extends UILogicNode {
18833
19066
  async exec(ctx) {
19067
+ ibiz.log.debug(
19068
+ "\u754C\u9762\u903B\u8F91\u8282\u70B9\uFF08\u76F4\u63A5\u4EE3\u7801\uFF09\uFF1A".concat(this.model.id, "-\u76F4\u63A5\u4EE3\u7801\uFF1A"),
19069
+ this.model.code
19070
+ );
18834
19071
  ScriptFactory.execScriptFn(
18835
19072
  {
18836
19073
  view: ctx.view,
@@ -18920,6 +19157,7 @@ var UILogicParam = class {
18920
19157
  } else if (m.viewSessionParam) {
18921
19158
  throw new ModelError24(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B: \u5F53\u524D\u89C6\u56FE\u4F1A\u8BDD");
18922
19159
  }
19160
+ ibiz.log.debug("\u8BA1\u7B97\u754C\u9762\u903B\u8F91\u53C2\u6570\uFF0C\u6807\u8BC6\uFF1A".concat(tag), "-\u503C\uFF1A", ctx.params[tag]);
18923
19161
  }
18924
19162
  /**
18925
19163
  * 重新建立变量
@@ -18937,6 +19175,11 @@ var UILogicParam = class {
18937
19175
  } else {
18938
19176
  throw new ModelError24(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B\u91CD\u65B0\u5EFA\u7ACB\u53D8\u91CF");
18939
19177
  }
19178
+ ibiz.log.debug(
19179
+ "\u91CD\u65B0\u5EFA\u7ACB\u754C\u9762\u903B\u8F91\u53C2\u6570\uFF0C\u6807\u8BC6\uFF1A".concat(tag),
19180
+ "-\u503C\uFF1A",
19181
+ ctx.params[tag]
19182
+ );
18940
19183
  }
18941
19184
  };
18942
19185
 
@@ -19143,8 +19386,15 @@ async function execUILogic(deUILogicId, appDataEntityId, parameters) {
19143
19386
  if (!uiLogicMap.has(deUILogic)) {
19144
19387
  uiLogicMap.set(deUILogic, new UILogic(deUILogic));
19145
19388
  }
19389
+ ibiz.log.debug(
19390
+ "\u5F00\u59CB\u6267\u884C\u754C\u9762\u903B\u8F91\uFF0C\u5B9E\u4F53\uFF1A".concat(appDataEntityId, "-\u903B\u8F91\u540D\u79F0\uFF1A").concat(deUILogic.name)
19391
+ );
19146
19392
  const uiLogic = uiLogicMap.get(deUILogic);
19147
- return uiLogic.exec(parameters);
19393
+ const result = await uiLogic.exec(parameters);
19394
+ ibiz.log.debug(
19395
+ "\u7ED3\u675F\u6267\u884C\u754C\u9762\u903B\u8F91\uFF0C\u5B9E\u4F53\uFF1A".concat(appDataEntityId, "-\u903B\u8F91\u540D\u79F0\uFF1A").concat(deUILogic.name)
19396
+ );
19397
+ return result;
19148
19398
  }
19149
19399
 
19150
19400
  // src/ui-action/uiaction-util.ts
@@ -19258,6 +19508,10 @@ var UIActionProviderBase = class {
19258
19508
  refreshMode: action.refreshMode,
19259
19509
  closeView: action.closeEditView
19260
19510
  };
19511
+ const { view } = args;
19512
+ if (action.closeEditView) {
19513
+ view.state.isClosing = true;
19514
+ }
19261
19515
  const { appDEUILogicId, appDataEntityId, uilogicAttachMode } = action;
19262
19516
  if (uilogicAttachMode === "REPLACE") {
19263
19517
  if (!appDEUILogicId) {
@@ -19267,12 +19521,12 @@ var UIActionProviderBase = class {
19267
19521
  return result;
19268
19522
  }
19269
19523
  if (!await this.isConfirm(action, args)) {
19270
- return this.returnError(result);
19524
+ return this.returnError(result, view);
19271
19525
  }
19272
19526
  const _result = await this.execAction(action, args);
19273
19527
  Object.assign(result, _result);
19274
19528
  if (result.cancel === true) {
19275
- return this.returnError(result);
19529
+ return this.returnError(result, view);
19276
19530
  }
19277
19531
  if (action.uilogicAttachMode === "AFTER") {
19278
19532
  if (!appDEUILogicId) {
@@ -19296,7 +19550,7 @@ var UIActionProviderBase = class {
19296
19550
  if (nextResult) {
19297
19551
  Object.assign(result, nextResult);
19298
19552
  if (nextResult.cancel === true) {
19299
- return this.returnError(result);
19553
+ return this.returnError(result, view);
19300
19554
  }
19301
19555
  }
19302
19556
  }
@@ -19328,7 +19582,8 @@ var UIActionProviderBase = class {
19328
19582
  * @returns {*} {IUIActionResult}
19329
19583
  * @memberof UIActionHandler
19330
19584
  */
19331
- returnError(result) {
19585
+ returnError(result, view) {
19586
+ view.state.isClosing = false;
19332
19587
  return Object.assign(result, {
19333
19588
  refresh: false,
19334
19589
  closeView: false
@@ -20586,7 +20841,7 @@ var RawItemPortletController = class extends PortletPartController {
20586
20841
 
20587
20842
  // src/controller/control/data-view/data-view.controller.ts
20588
20843
  import { RuntimeModelError as RuntimeModelError52 } from "@ibiz-template/core";
20589
- import { isNil as isNil24 } from "ramda";
20844
+ import { isNil as isNil25 } from "ramda";
20590
20845
 
20591
20846
  // src/controller/control/data-view/data-view.service.ts
20592
20847
  var DataViewControlService = class extends MDControlService {
@@ -20874,7 +21129,7 @@ var DataViewControlController = class extends MDControlController {
20874
21129
  const groupMap = /* @__PURE__ */ new Map();
20875
21130
  items.forEach((item) => {
20876
21131
  const groupVal = item[groupAppDEFieldId];
20877
- if (isNil24(groupVal)) {
21132
+ if (isNil25(groupVal)) {
20878
21133
  return;
20879
21134
  }
20880
21135
  if (!groupMap.has(groupVal)) {
@@ -21866,6 +22121,70 @@ var FormController = class extends ControlController {
21866
22121
  this.state.processing = false;
21867
22122
  this.state.modified = false;
21868
22123
  }
22124
+ /**
22125
+ * 进行模型预处理
22126
+ *
22127
+ * @author chitanda
22128
+ * @date 2024-02-27 09:02:52
22129
+ * @protected
22130
+ */
22131
+ preprocessModel(model) {
22132
+ if (this.context && this.context.srfreadonly === true) {
22133
+ const pages = model.deformPages;
22134
+ if (pages) {
22135
+ pages.forEach((page) => {
22136
+ page.infoGroupMode = true;
22137
+ if (page.deformDetails) {
22138
+ page.deformDetails.forEach((detail) => {
22139
+ this.deepPreprocessModel(detail);
22140
+ });
22141
+ }
22142
+ });
22143
+ }
22144
+ }
22145
+ }
22146
+ /**
22147
+ * 递归将表单模型修改为信息态
22148
+ *
22149
+ * @author chitanda
22150
+ * @date 2024-02-27 11:02:43
22151
+ * @protected
22152
+ * @param {IDEFormGroupBase} model
22153
+ */
22154
+ deepPreprocessModel(model) {
22155
+ if (model.detailType === "GROUPPANEL") {
22156
+ model.infoGroupMode = true;
22157
+ } else if (model.detailType === "FORMITEM") {
22158
+ const { editor } = model;
22159
+ if (editor) {
22160
+ editor.readOnly = true;
22161
+ }
22162
+ }
22163
+ switch (model.detailType) {
22164
+ case "FORMITEM": {
22165
+ const { editor } = model;
22166
+ if (editor) {
22167
+ editor.readOnly = true;
22168
+ }
22169
+ break;
22170
+ }
22171
+ case "MDCTRL": {
22172
+ const detail = model;
22173
+ detail.buildInActions = 0;
22174
+ break;
22175
+ }
22176
+ case "GROUPPANEL":
22177
+ model.infoGroupMode = true;
22178
+ break;
22179
+ default:
22180
+ break;
22181
+ }
22182
+ if (model.deformDetails) {
22183
+ model.deformDetails.forEach((detail) => {
22184
+ this.deepPreprocessModel(detail);
22185
+ });
22186
+ }
22187
+ }
21869
22188
  /**
21870
22189
  * 通知所有表单成员表单操作过程中的数据变更
21871
22190
  *
@@ -24597,7 +24916,9 @@ var EditFormController = class extends FormController {
24597
24916
  }
24598
24917
  this.state.modified = false;
24599
24918
  await this.evt.emit("onSaveSuccess", void 0);
24600
- this.formStateNotify("SAVE" /* SAVE */);
24919
+ if (!this.view.state.isClosing) {
24920
+ this.formStateNotify("SAVE" /* SAVE */);
24921
+ }
24601
24922
  if (!silent) {
24602
24923
  this.actionNotification("".concat(isCreate ? "CREATE" : "UPDATE", "SUCCESS"), {
24603
24924
  default: "".concat(this.data.srfmajortext || "", "\u4FDD\u5B58\u6210\u529F")
@@ -26279,6 +26600,7 @@ var GridController = class extends MDControlController {
26279
26600
  setGroupParams(data) {
26280
26601
  if (data.sort) {
26281
26602
  this.state.sortQuery = data.sort;
26603
+ this.isSetSort = true;
26282
26604
  } else {
26283
26605
  this.state.sortQuery = "";
26284
26606
  }
@@ -26336,7 +26658,7 @@ var GridController = class extends MDControlController {
26336
26658
  import { DataTypes as DataTypes4, ModelError as ModelError29, plus as plus2 } from "@ibiz-template/core";
26337
26659
  import dayjs5 from "dayjs";
26338
26660
  import { debounce as debounce3 } from "lodash-es";
26339
- import { clone as clone27, isNil as isNil25 } from "ramda";
26661
+ import { clone as clone27, isNil as isNil26 } from "ramda";
26340
26662
  var GridFieldColumnController = class extends GridColumnController {
26341
26663
  constructor() {
26342
26664
  super(...arguments);
@@ -26548,11 +26870,11 @@ var GridFieldColumnController = class extends GridColumnController {
26548
26870
  */
26549
26871
  calcFieldAgg(items) {
26550
26872
  const { aggField, aggMode, aggValueFormat, unitName } = this.model;
26551
- if (isNil25(aggMode) || aggMode === "NONE") {
26873
+ if (isNil26(aggMode) || aggMode === "NONE") {
26552
26874
  return;
26553
26875
  }
26554
26876
  const fieldName = aggField || this.model.id;
26555
- items = items.filter((item) => !isNil25(item[fieldName]));
26877
+ items = items.filter((item) => !isNil26(item[fieldName]));
26556
26878
  let aggValue;
26557
26879
  if (this.grid.model.aggMode === "PAGE") {
26558
26880
  switch (aggMode) {
@@ -27868,7 +28190,7 @@ var PickupViewPanelController = class extends ControlController {
27868
28190
 
27869
28191
  // src/controller/control/search-bar/search-bar.controller.ts
27870
28192
  import { mergeInLeft as mergeInLeft3, recursiveIterate as recursiveIterate10 } from "@ibiz-template/core";
27871
- import { clone as clone28, isNil as isNil27 } from "ramda";
28193
+ import { clone as clone28, isNil as isNil28 } from "ramda";
27872
28194
  import { isString as isString2 } from "lodash-es";
27873
28195
 
27874
28196
  // src/controller/control/search-bar/search-bar-filter.controller.ts
@@ -28310,7 +28632,7 @@ async function calcFilterModelBySchema(json, appDataEntityId, modelAppId) {
28310
28632
 
28311
28633
  // src/controller/control/search-bar/use-searchcond.ts
28312
28634
  import { RuntimeError as RuntimeError58, recursiveIterate as recursiveIterate9 } from "@ibiz-template/core";
28313
- import { isNil as isNil26 } from "ramda";
28635
+ import { isNil as isNil27 } from "ramda";
28314
28636
  function getOriginFilterNodes() {
28315
28637
  return [
28316
28638
  {
@@ -28367,7 +28689,7 @@ function calcSearchConds(filterNodes) {
28367
28689
  let hasError = false;
28368
28690
  recursiveIterate9(filterNodes[0], (node) => {
28369
28691
  if (node.leaf) {
28370
- if (node.field && node.valueOP && !isNil26(node.value)) {
28692
+ if (node.field && node.valueOP && !isNil27(node.value)) {
28371
28693
  hasFilter = true;
28372
28694
  } else {
28373
28695
  hasError = true;
@@ -28666,7 +28988,7 @@ var SearchBarController = class extends ControlController {
28666
28988
  recursiveIterate10(
28667
28989
  searchconds[0],
28668
28990
  (node) => {
28669
- if (node.condtype === "DEFIELD" && !isNil27(node.value)) {
28991
+ if (node.condtype === "DEFIELD" && !isNil28(node.value)) {
28670
28992
  const controller = this.findFilterController(
28671
28993
  node.fieldname,
28672
28994
  node.condop
@@ -30107,6 +30429,20 @@ var TreeController = class extends MDControlController {
30107
30429
  nodeData._text = text;
30108
30430
  await this.updateDeNodeData([nodeData]);
30109
30431
  }
30432
+ /**
30433
+ * 获取删除实体codeName
30434
+ * @param {IData} item
30435
+ * @return {*}
30436
+ * @author: zhujiamin
30437
+ * @Date: 2024-02-22 16:47:44
30438
+ */
30439
+ getRemoveDeName(item) {
30440
+ const treeNode = this.getNodeModel(item._nodeId);
30441
+ if (treeNode) {
30442
+ return calcDeCodeNameById(treeNode.appDataEntityId);
30443
+ }
30444
+ return calcDeCodeNameById(this.model.appDataEntityId);
30445
+ }
30110
30446
  };
30111
30447
 
30112
30448
  // src/controller/control/wizard-panel/wizard-panel.controller.ts
@@ -30463,7 +30799,7 @@ var WizardPanelController = class extends ControlController {
30463
30799
 
30464
30800
  // src/controller/control/md-ctrl/md-ctrl.controller.ts
30465
30801
  import { RuntimeModelError as RuntimeModelError65 } from "@ibiz-template/core";
30466
- import { isNil as isNil28 } from "ramda";
30802
+ import { isNil as isNil29 } from "ramda";
30467
30803
 
30468
30804
  // src/controller/control/md-ctrl/md-ctrl.service.ts
30469
30805
  var MDCtrlService = class extends MDControlService {
@@ -30690,7 +31026,7 @@ var MDCtrlController = class extends MDControlController {
30690
31026
  const groupMap = /* @__PURE__ */ new Map();
30691
31027
  items.forEach((item) => {
30692
31028
  const groupVal = item[groupAppDEFieldId];
30693
- if (isNil28(groupVal)) {
31029
+ if (isNil29(groupVal)) {
30694
31030
  return;
30695
31031
  }
30696
31032
  if (!groupMap.has(groupVal)) {
@@ -30767,7 +31103,7 @@ var MDCtrlController = class extends MDControlController {
30767
31103
 
30768
31104
  // src/controller/control/kanban/kanban.controller.ts
30769
31105
  import { RuntimeError as RuntimeError61, RuntimeModelError as RuntimeModelError66 } from "@ibiz-template/core";
30770
- import { isNil as isNil29 } from "ramda";
31106
+ import { isNil as isNil30 } from "ramda";
30771
31107
 
30772
31108
  // src/controller/control/kanban/kanban.service.ts
30773
31109
  var KanbanService = class extends DataViewControlService {
@@ -30852,7 +31188,7 @@ var KanbanController = class extends DataViewControlController {
30852
31188
  const isAsc = minorSortDir === "ASC";
30853
31189
  items.forEach((item) => {
30854
31190
  const sortValue = item[sortField];
30855
- if (isNil29(sortValue)) {
31191
+ if (isNil30(sortValue)) {
30856
31192
  item[sortField] = 0;
30857
31193
  } else {
30858
31194
  const toNum = Number(sortValue);
@@ -30959,7 +31295,7 @@ var KanbanController = class extends DataViewControlController {
30959
31295
  const groupMap = /* @__PURE__ */ new Map();
30960
31296
  items.forEach((item) => {
30961
31297
  const groupVal = item[groupAppDEFieldId];
30962
- if (isNil29(groupVal)) {
31298
+ if (isNil30(groupVal)) {
30963
31299
  return;
30964
31300
  }
30965
31301
  if (!groupMap.has(groupVal)) {
@@ -33540,7 +33876,7 @@ var GanttController = class extends TreeGridExController {
33540
33876
  /**
33541
33877
  * 保存
33542
33878
  *
33543
- * @param {ITreeNodeData} nodeData
33879
+ * @param {IGanttNodeData} nodeData
33544
33880
  * @return {*} {Promise<void>}
33545
33881
  * @memberof GanttController
33546
33882
  */
@@ -33567,9 +33903,6 @@ var GanttController = class extends TreeGridExController {
33567
33903
  const nodeModel = this.getNodeModel(nodeData._nodeId);
33568
33904
  const { appDataEntityId } = nodeModel;
33569
33905
  const isCreate = nodeData._deData.srfuf === 0 /* CREATE */;
33570
- if (isCreate) {
33571
- return;
33572
- }
33573
33906
  const deName = calcDeCodeNameById(appDataEntityId);
33574
33907
  const tempContext = this.context.clone();
33575
33908
  tempContext[deName] = nodeData._deData.srfkey;
@@ -33806,7 +34139,7 @@ import { QXEvent as QXEvent9 } from "qx-util";
33806
34139
  // src/controller/notification/async-action.controller.ts
33807
34140
  import { QXEvent as QXEvent7 } from "qx-util";
33808
34141
  import { clone as clone31 } from "ramda";
33809
- import { isNil as isNil30, isNumber as isNumber2 } from "lodash-es";
34142
+ import { isNil as isNil31, isNumber as isNumber2 } from "lodash-es";
33810
34143
  import dayjs7 from "dayjs";
33811
34144
  var AsyncActionController = class {
33812
34145
  constructor() {
@@ -33881,14 +34214,14 @@ var AsyncActionController = class {
33881
34214
  data[key] = dayjs7(data[key]).format("YYYY-MM-DD HH:mm:ss");
33882
34215
  }
33883
34216
  });
33884
- if (!isNil30(data.actionresult)) {
34217
+ if (!isNil31(data.actionresult)) {
33885
34218
  try {
33886
34219
  const json = JSON.parse(data.actionresult);
33887
34220
  data.actionresult = json;
33888
34221
  } catch (error) {
33889
34222
  }
33890
34223
  }
33891
- if (!isNil30(data.completionrate)) {
34224
+ if (!isNil31(data.completionrate)) {
33892
34225
  const num = Number(data.completionrate);
33893
34226
  if (Number.isNaN(num)) {
33894
34227
  data.completionrate = void 0;
@@ -34062,6 +34395,7 @@ var InternalMessageController = class {
34062
34395
  position: "bottom-right"
34063
34396
  });
34064
34397
  }
34398
+ this.refreshUnreadCount();
34065
34399
  });
34066
34400
  }
34067
34401
  async markRead(message) {
@@ -34075,6 +34409,18 @@ var InternalMessageController = class {
34075
34409
  this.evt.emit("unreadCountChange", this.unreadCount);
34076
34410
  this.evt.emit("dataChange");
34077
34411
  }
34412
+ /**
34413
+ * 把所有未读消息标记为已读
34414
+ * @return {*}
34415
+ * @author: zhujiamin
34416
+ * @Date: 2024-02-21 15:38:25
34417
+ */
34418
+ async batchMarkRead() {
34419
+ await this.service.batchMarkRead();
34420
+ await this.fetch();
34421
+ this.unreadCount = 0;
34422
+ this.evt.emit("unreadCountChange", this.unreadCount);
34423
+ }
34078
34424
  /**
34079
34425
  * 获取完整信息
34080
34426
  * @author lxm
@@ -34971,7 +35317,7 @@ var MDViewEngine = class extends ViewEngineBase {
34971
35317
  view: this.view
34972
35318
  }));
34973
35319
  if (result === -1) {
34974
- throw new RuntimeModelError70(this.view.model, "\u7F3A\u5C11newdata\u7684\u89C6\u56FE\u903B\u8F91");
35320
+ throw new RuntimeModelError70(this.view.model, "\u7F3A\u5C11opendata\u7684\u89C6\u56FE\u903B\u8F91");
34975
35321
  } else {
34976
35322
  return {
34977
35323
  cancel: !result.ok
@@ -36350,6 +36696,14 @@ var PluginStaticResource = class {
36350
36696
  * @param {string} mateUrl import.mate.url
36351
36697
  */
36352
36698
  constructor(mateUrl) {
36699
+ /**
36700
+ * 是否为 http || https 开头
36701
+ *
36702
+ * @author chitanda
36703
+ * @date 2022-11-07 14:11:28
36704
+ * @protected
36705
+ */
36706
+ this.urlReg = /^http[s]?:\/\/[^\s]*/;
36353
36707
  /**
36354
36708
  * 已经输出过路径的 style 标签
36355
36709
  *
@@ -36371,6 +36725,9 @@ var PluginStaticResource = class {
36371
36725
  * @return {*} {string}
36372
36726
  */
36373
36727
  dir(pathStr) {
36728
+ if (this.urlReg.test(pathStr)) {
36729
+ return pathStr;
36730
+ }
36374
36731
  return this.url.origin + path.resolve(this.baseDir, pathStr);
36375
36732
  }
36376
36733
  /**
@@ -36383,7 +36740,7 @@ var PluginStaticResource = class {
36383
36740
  */
36384
36741
  async loadStyle(urls) {
36385
36742
  const all = urls.map((styleUrl) => {
36386
- const url = this.dir(styleUrl);
36743
+ const url = this.urlReg.test(styleUrl) ? styleUrl : this.dir(styleUrl);
36387
36744
  if (this.styleElementMap.has(url)) {
36388
36745
  return false;
36389
36746
  }
@@ -36767,3 +37124,4 @@ export {
36767
37124
  verifyFormGroupLogic,
36768
37125
  verifyPanelGroupLogic
36769
37126
  };
37127
+ //! 只有动态走这个逻辑,全代码确保所有视图都设置了viewConfig