@ibiz-template/runtime 0.1.16 → 0.1.18
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.
- package/dist/index.esm.js +339 -142
- package/dist/index.system.min.js +1 -1
- package/dist/index.system.min.js.map +1 -1
- package/out/controller/common/control/md-control.controller.d.ts.map +1 -1
- package/out/controller/common/control/md-control.controller.js +4 -2
- package/out/controller/common/index.d.ts +1 -0
- package/out/controller/common/index.d.ts.map +1 -1
- package/out/controller/common/index.js +1 -0
- package/out/controller/common/view/view.controller.d.ts.map +1 -1
- package/out/controller/common/view/view.controller.js +5 -1
- package/out/controller/common/view/wf-step-trace-view.controller.d.ts +8 -0
- package/out/controller/common/view/wf-step-trace-view.controller.d.ts.map +1 -0
- package/out/controller/common/view/wf-step-trace-view.controller.js +20 -0
- package/out/controller/control/exp-bar/exp-bar.controller.d.ts.map +1 -1
- package/out/controller/control/exp-bar/exp-bar.controller.js +2 -0
- package/out/controller/control/form/edit-form/edit-form.service.d.ts +8 -0
- package/out/controller/control/form/edit-form/edit-form.service.d.ts.map +1 -1
- package/out/controller/control/form/edit-form/edit-form.service.js +23 -21
- package/out/controller/control/form/form-detail/form-item/form-item.controller.d.ts +9 -0
- package/out/controller/control/form/form-detail/form-item/form-item.controller.d.ts.map +1 -1
- package/out/controller/control/form/form-detail/form-item/form-item.controller.js +11 -0
- package/out/controller/control/form/form-detail/form-mdctrl/form-mdctrl-repeater/form-mdctrl-repeater-grid/form-mdctrl-repeater-grid.controller.d.ts.map +1 -1
- package/out/controller/control/form/form-detail/form-mdctrl/form-mdctrl-repeater/form-mdctrl-repeater-grid/form-mdctrl-repeater-grid.controller.js +2 -1
- package/out/controller/control/grid/grid/grid.controller.d.ts.map +1 -1
- package/out/controller/control/grid/grid/grid.controller.js +16 -8
- package/out/controller/control/grid/grid/grid.service.d.ts.map +1 -1
- package/out/controller/control/grid/grid/grid.service.js +2 -1
- package/out/controller/control/grid/grid-column/grid-field-column/grid-field-column.controller.js +1 -1
- package/out/controller/control/list/list.controller.d.ts.map +1 -1
- package/out/controller/control/list/list.controller.js +1 -0
- package/out/de-logic/de-logic-context.d.ts +21 -0
- package/out/de-logic/de-logic-context.d.ts.map +1 -1
- package/out/de-logic/de-logic-context.js +22 -0
- package/out/de-logic/de-logic-param/de-logic-param.d.ts.map +1 -1
- package/out/de-logic/de-logic-param/de-logic-param.js +2 -1
- package/out/engine/md-view.engine.d.ts +7 -0
- package/out/engine/md-view.engine.d.ts.map +1 -1
- package/out/engine/md-view.engine.js +11 -2
- package/out/interface/controller/controller/editor/i-editor-container.controller.d.ts +8 -0
- package/out/interface/controller/controller/editor/i-editor-container.controller.d.ts.map +1 -1
- package/out/interface/controller/event/view/i-form-pickup-data-view.event.d.ts +13 -0
- package/out/interface/controller/event/view/i-form-pickup-data-view.event.d.ts.map +1 -0
- package/out/interface/controller/event/view/i-form-pickup-data-view.event.js +1 -0
- package/out/interface/controller/event/view/index.d.ts +1 -0
- package/out/interface/controller/event/view/index.d.ts.map +1 -1
- package/out/interface/controller/event/view/index.js +1 -0
- package/out/interface/controller/state/view/i-form-pickup-data-view.state.d.ts +13 -0
- package/out/interface/controller/state/view/i-form-pickup-data-view.state.d.ts.map +1 -0
- package/out/interface/controller/state/view/i-form-pickup-data-view.state.js +1 -0
- package/out/interface/controller/state/view/i-view.state.d.ts +7 -0
- package/out/interface/controller/state/view/i-view.state.d.ts.map +1 -1
- package/out/interface/controller/state/view/i-wf-step-trace-view.state.d.ts +6 -0
- package/out/interface/controller/state/view/i-wf-step-trace-view.state.d.ts.map +1 -1
- package/out/interface/controller/state/view/index.d.ts +1 -0
- package/out/interface/controller/state/view/index.d.ts.map +1 -1
- package/out/interface/controller/state/view/index.js +1 -0
- package/out/interface/util/i-modal-util/i-modal-util.d.ts +35 -0
- package/out/interface/util/i-modal-util/i-modal-util.d.ts.map +1 -1
- package/out/model/layout/layout.d.ts +1 -1
- package/out/model/layout/layout.d.ts.map +1 -1
- package/out/model/layout/layout.js +2 -2
- package/out/service/dto/method.dto.d.ts +0 -1
- package/out/service/dto/method.dto.d.ts.map +1 -1
- package/out/service/dto/method.dto.js +5 -6
- package/out/service/service/control/control.service.d.ts +0 -9
- package/out/service/service/control/control.service.d.ts.map +1 -1
- package/out/service/service/entity/method/de-action.d.ts +10 -0
- package/out/service/service/entity/method/de-action.d.ts.map +1 -1
- package/out/service/service/entity/method/de-action.js +12 -0
- package/out/service/service/entity/method/fetch.d.ts +1 -0
- package/out/service/service/entity/method/fetch.d.ts.map +1 -1
- package/out/service/service/entity/method/fetch.js +4 -0
- package/out/service/service/entity/method/method.d.ts +0 -10
- package/out/service/service/entity/method/method.d.ts.map +1 -1
- package/out/service/service/entity/method/method.js +0 -12
- package/out/ui-logic/ui-logic-context.d.ts +21 -0
- package/out/ui-logic/ui-logic-context.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-context.js +22 -0
- package/out/ui-logic/ui-logic-node/debug-param-node/debug-param-node.d.ts +17 -0
- package/out/ui-logic/ui-logic-node/debug-param-node/debug-param-node.d.ts.map +1 -0
- package/out/ui-logic/ui-logic-node/debug-param-node/debug-param-node.js +21 -0
- package/out/ui-logic/ui-logic-node/index.d.ts +2 -0
- package/out/ui-logic/ui-logic-node/index.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-node/index.js +2 -0
- package/out/ui-logic/ui-logic-node/msg-box-node/msg-box-node.d.ts +23 -0
- package/out/ui-logic/ui-logic-node/msg-box-node/msg-box-node.d.ts.map +1 -0
- package/out/ui-logic/ui-logic-node/msg-box-node/msg-box-node.js +79 -0
- package/out/ui-logic/ui-logic-param/ui-logic-param.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-param/ui-logic-param.js +2 -1
- package/out/ui-logic/ui-logic.d.ts.map +1 -1
- package/out/ui-logic/ui-logic.js +7 -3
- package/package.json +3 -3
- package/src/controller/common/control/md-control.controller.ts +4 -2
- package/src/controller/common/index.ts +1 -0
- package/src/controller/common/view/view.controller.ts +5 -1
- package/src/controller/common/view/wf-step-trace-view.controller.ts +36 -0
- package/src/controller/control/exp-bar/exp-bar.controller.ts +2 -0
- package/src/controller/control/form/edit-form/edit-form.service.ts +24 -22
- package/src/controller/control/form/form-detail/form-item/form-item.controller.ts +12 -0
- package/src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-repeater/form-mdctrl-repeater-grid/form-mdctrl-repeater-grid.controller.ts +2 -1
- package/src/controller/control/grid/grid/grid.controller.ts +21 -14
- package/src/controller/control/grid/grid/grid.service.ts +4 -1
- package/src/controller/control/grid/grid-column/grid-field-column/grid-field-column.controller.ts +1 -1
- package/src/controller/control/list/list.controller.ts +1 -0
- package/src/de-logic/de-logic-context.ts +32 -0
- package/src/de-logic/de-logic-param/de-logic-param.ts +2 -1
- package/src/engine/md-view.engine.ts +12 -2
- package/src/interface/controller/controller/editor/i-editor-container.controller.ts +9 -0
- package/src/interface/controller/event/view/i-form-pickup-data-view.event.ts +12 -0
- package/src/interface/controller/event/view/index.ts +1 -0
- package/src/interface/controller/state/view/i-form-pickup-data-view.state.ts +12 -0
- package/src/interface/controller/state/view/i-view.state.ts +8 -0
- package/src/interface/controller/state/view/i-wf-step-trace-view.state.ts +8 -1
- package/src/interface/controller/state/view/index.ts +1 -0
- package/src/interface/util/i-modal-util/i-modal-util.ts +41 -0
- package/src/model/layout/layout.ts +5 -3
- package/src/service/dto/method.dto.ts +5 -7
- package/src/service/service/control/control.service.ts +0 -10
- package/src/service/service/entity/method/de-action.ts +13 -0
- package/src/service/service/entity/method/fetch.ts +5 -0
- package/src/service/service/entity/method/method.ts +0 -13
- package/src/ui-logic/ui-logic-context.ts +32 -0
- package/src/ui-logic/ui-logic-node/debug-param-node/debug-param-node.ts +26 -0
- package/src/ui-logic/ui-logic-node/index.ts +2 -0
- package/src/ui-logic/ui-logic-node/msg-box-node/msg-box-node.ts +87 -0
- package/src/ui-logic/ui-logic-param/ui-logic-param.ts +2 -1
- package/src/ui-logic/ui-logic.ts +8 -2
package/dist/index.esm.js
CHANGED
|
@@ -6855,9 +6855,9 @@ function calcLayoutHeightWidth(layoutPos) {
|
|
|
6855
6855
|
}
|
|
6856
6856
|
function calcContentAlignStyle(layoutPos) {
|
|
6857
6857
|
const { valignSelf, halignSelf } = layoutPos;
|
|
6858
|
-
|
|
6858
|
+
let result;
|
|
6859
6859
|
if (valignSelf || halignSelf) {
|
|
6860
|
-
|
|
6860
|
+
result = { display: "flex" };
|
|
6861
6861
|
switch (valignSelf) {
|
|
6862
6862
|
case "TOP":
|
|
6863
6863
|
Object.assign(result, { "align-items": "flex-start" });
|
|
@@ -11090,7 +11090,7 @@ import {
|
|
|
11090
11090
|
|
|
11091
11091
|
// src/service/service/entity/method/method.ts
|
|
11092
11092
|
import { RuntimeModelError as RuntimeModelError7 } from "@ibiz-template/core";
|
|
11093
|
-
import { notNilEmpty as
|
|
11093
|
+
import { notNilEmpty as notNilEmpty6 } from "qx-util";
|
|
11094
11094
|
|
|
11095
11095
|
// src/service/app-data-entity/app-data-entity.ts
|
|
11096
11096
|
import { clone as clone4 } from "ramda";
|
|
@@ -11252,6 +11252,7 @@ var AppDataEntity = class _AppDataEntity {
|
|
|
11252
11252
|
|
|
11253
11253
|
// src/service/dto/method.dto.ts
|
|
11254
11254
|
import { ModelError as ModelError7 } from "@ibiz-template/core";
|
|
11255
|
+
import { notNilEmpty as notNilEmpty5 } from "qx-util";
|
|
11255
11256
|
var MethodDto = class _MethodDto {
|
|
11256
11257
|
constructor(entity, dto) {
|
|
11257
11258
|
this.entity = entity;
|
|
@@ -11264,9 +11265,6 @@ var MethodDto = class _MethodDto {
|
|
|
11264
11265
|
this.fields = [];
|
|
11265
11266
|
}
|
|
11266
11267
|
}
|
|
11267
|
-
get isLocalMode() {
|
|
11268
|
-
return this.entity.storageMode === 1 || this.entity.storageMode === 4;
|
|
11269
|
-
}
|
|
11270
11268
|
/**
|
|
11271
11269
|
* 请求参数组合 DTO
|
|
11272
11270
|
*
|
|
@@ -11286,6 +11284,9 @@ var MethodDto = class _MethodDto {
|
|
|
11286
11284
|
break;
|
|
11287
11285
|
}
|
|
11288
11286
|
case "DTOS": {
|
|
11287
|
+
if (notNilEmpty5(data[key])) {
|
|
11288
|
+
break;
|
|
11289
|
+
}
|
|
11289
11290
|
if (!field.refAppDataEntityId) {
|
|
11290
11291
|
break;
|
|
11291
11292
|
}
|
|
@@ -11343,9 +11344,7 @@ var MethodDto = class _MethodDto {
|
|
|
11343
11344
|
await all[i];
|
|
11344
11345
|
}
|
|
11345
11346
|
const entityData = new AppDataEntity(this.entity, datum);
|
|
11346
|
-
|
|
11347
|
-
await service.local.add(context, entityData);
|
|
11348
|
-
}
|
|
11347
|
+
await service.local.add(context, entityData);
|
|
11349
11348
|
return entityData;
|
|
11350
11349
|
})
|
|
11351
11350
|
);
|
|
@@ -11476,18 +11475,6 @@ var Method = class {
|
|
|
11476
11475
|
this.input = new MethodInput(entity, method.appDEMethodInput);
|
|
11477
11476
|
this.result = new MethodReturn(entity, method.appDEMethodReturn);
|
|
11478
11477
|
}
|
|
11479
|
-
/**
|
|
11480
|
-
* 是否为本地模式
|
|
11481
|
-
*
|
|
11482
|
-
* @author chitanda
|
|
11483
|
-
* @date 2023-04-19 16:04:46
|
|
11484
|
-
* @readonly
|
|
11485
|
-
* @protected
|
|
11486
|
-
* @type {boolean}
|
|
11487
|
-
*/
|
|
11488
|
-
get isLocalMode() {
|
|
11489
|
-
return this.entity.storageMode === 1 || this.entity.storageMode === 4;
|
|
11490
|
-
}
|
|
11491
11478
|
/**
|
|
11492
11479
|
* 发送请求
|
|
11493
11480
|
*
|
|
@@ -11509,7 +11496,7 @@ var Method = class {
|
|
|
11509
11496
|
case "POST":
|
|
11510
11497
|
res = await this.app.net.post(
|
|
11511
11498
|
"".concat(path2, "/").concat(methodName),
|
|
11512
|
-
|
|
11499
|
+
notNilEmpty6(data) ? data : params
|
|
11513
11500
|
);
|
|
11514
11501
|
break;
|
|
11515
11502
|
case "GET":
|
|
@@ -11518,7 +11505,7 @@ var Method = class {
|
|
|
11518
11505
|
case "PUT":
|
|
11519
11506
|
res = await this.app.net.put(
|
|
11520
11507
|
"".concat(path2, "/").concat(methodName),
|
|
11521
|
-
|
|
11508
|
+
notNilEmpty6(data) ? data : params
|
|
11522
11509
|
);
|
|
11523
11510
|
break;
|
|
11524
11511
|
case "DELETE":
|
|
@@ -11657,6 +11644,28 @@ var DELogicContext = class {
|
|
|
11657
11644
|
var _a;
|
|
11658
11645
|
(_a = this.deLogicParams.get(name)) == null ? void 0 : _a.renew(this);
|
|
11659
11646
|
}
|
|
11647
|
+
/**
|
|
11648
|
+
* 设置上一次返回值
|
|
11649
|
+
* @author lxm
|
|
11650
|
+
* @date 2023-09-04 09:23:52
|
|
11651
|
+
* @param {unknown} value
|
|
11652
|
+
*/
|
|
11653
|
+
setLastReturn(value) {
|
|
11654
|
+
this.lastReturn = value;
|
|
11655
|
+
}
|
|
11656
|
+
/**
|
|
11657
|
+
* 初始化上一次返回参数类型的逻辑参数
|
|
11658
|
+
* @author lxm
|
|
11659
|
+
* @date 2023-09-04 09:52:00
|
|
11660
|
+
* @param {string} tag
|
|
11661
|
+
*/
|
|
11662
|
+
initLastReturnParam(tag) {
|
|
11663
|
+
Object.defineProperty(this.params, tag, {
|
|
11664
|
+
enumerable: true,
|
|
11665
|
+
configurable: true,
|
|
11666
|
+
get: () => this.lastReturn
|
|
11667
|
+
});
|
|
11668
|
+
}
|
|
11660
11669
|
};
|
|
11661
11670
|
|
|
11662
11671
|
// src/de-logic/de-logic-node/de-action-node/de-action-node.ts
|
|
@@ -12308,7 +12317,7 @@ var DELogicParam = class {
|
|
|
12308
12317
|
} else if (m.entityParam) {
|
|
12309
12318
|
ctx.params[tag] = {};
|
|
12310
12319
|
} else if (m.lastReturnParam) {
|
|
12311
|
-
|
|
12320
|
+
ctx.initLastReturnParam(tag);
|
|
12312
12321
|
} else if (m.appContextParam) {
|
|
12313
12322
|
ctx.params[tag] = ctx.context;
|
|
12314
12323
|
} else if (m.simpleListParam) {
|
|
@@ -12565,6 +12574,18 @@ async function execFieldLogics(entity, type, context, data, params) {
|
|
|
12565
12574
|
|
|
12566
12575
|
// src/service/service/entity/method/de-action.ts
|
|
12567
12576
|
var DEActionMethod = class extends Method {
|
|
12577
|
+
/**
|
|
12578
|
+
* 是否为本地模式
|
|
12579
|
+
*
|
|
12580
|
+
* @author chitanda
|
|
12581
|
+
* @date 2023-04-19 16:04:46
|
|
12582
|
+
* @readonly
|
|
12583
|
+
* @protected
|
|
12584
|
+
* @type {boolean}
|
|
12585
|
+
*/
|
|
12586
|
+
get isLocalMode() {
|
|
12587
|
+
return this.method.actionType === "BUILTIN";
|
|
12588
|
+
}
|
|
12568
12589
|
async exec(context, data, params) {
|
|
12569
12590
|
if (this.method.actionType === "DELOGIC") {
|
|
12570
12591
|
const deLogic = findDELogic(this.method.appDELogicId, this.entity);
|
|
@@ -12858,6 +12879,9 @@ import {
|
|
|
12858
12879
|
import { ascSort, descSort } from "qx-util";
|
|
12859
12880
|
import { clone as clone9, equals as equals2, isEmpty as isEmpty7, isNil as isNil7, where as where2 } from "ramda";
|
|
12860
12881
|
var FetchMethod = class extends Method {
|
|
12882
|
+
get isLocalMode() {
|
|
12883
|
+
return this.method.dataSetType === "DATAQUERY";
|
|
12884
|
+
}
|
|
12861
12885
|
async exec(context, data, params) {
|
|
12862
12886
|
if (this.isLocalMode) {
|
|
12863
12887
|
const items2 = await this.searchLocal(
|
|
@@ -12870,6 +12894,7 @@ var FetchMethod = class extends Method {
|
|
|
12870
12894
|
switch (this.method.dataSetType) {
|
|
12871
12895
|
case "INDEXDE":
|
|
12872
12896
|
case "CODELIST":
|
|
12897
|
+
case "MULTIFORM":
|
|
12873
12898
|
res = await this.fetchCodeListSet(context, params);
|
|
12874
12899
|
break;
|
|
12875
12900
|
case "REMOTE":
|
|
@@ -14353,9 +14378,9 @@ var PanelNotifyState = /* @__PURE__ */ ((PanelNotifyState2) => {
|
|
|
14353
14378
|
})(PanelNotifyState || {});
|
|
14354
14379
|
|
|
14355
14380
|
// src/controller/common/view/view.controller.ts
|
|
14356
|
-
import { createUUID as createUUID2, notNilEmpty as
|
|
14381
|
+
import { createUUID as createUUID2, notNilEmpty as notNilEmpty7 } from "qx-util";
|
|
14357
14382
|
import { IBizContext as IBizContext2, RuntimeError as RuntimeError22 } from "@ibiz-template/core";
|
|
14358
|
-
import { isEmpty as isEmpty8, isNil as isNil12 } from "ramda";
|
|
14383
|
+
import { isEmpty as isEmpty8, isNil as isNil12, isNotNil as isNotNil2 } from "ramda";
|
|
14359
14384
|
|
|
14360
14385
|
// src/controller/utils/loading/loading.state.ts
|
|
14361
14386
|
import { NOOP } from "@ibiz-template/core";
|
|
@@ -15407,6 +15432,9 @@ var ViewController = class extends BaseController {
|
|
|
15407
15432
|
async onCreated() {
|
|
15408
15433
|
await super.onCreated();
|
|
15409
15434
|
this.modal.hooks.beforeDismiss.tapPromise(async (modalData) => {
|
|
15435
|
+
if (isNotNil2(this.state.closeOK)) {
|
|
15436
|
+
modalData.ok = this.state.closeOK;
|
|
15437
|
+
}
|
|
15410
15438
|
await this._evt.emit("onCloseView", { ...modalData });
|
|
15411
15439
|
});
|
|
15412
15440
|
this._evt.emit("onViewInfoChange", {
|
|
@@ -15479,13 +15507,13 @@ var ViewController = class extends BaseController {
|
|
|
15479
15507
|
}
|
|
15480
15508
|
const navContexts = this.model.appViewNavContexts;
|
|
15481
15509
|
let context = {};
|
|
15482
|
-
if (
|
|
15510
|
+
if (notNilEmpty7(navContexts)) {
|
|
15483
15511
|
context = convertNavData(navContexts, this.context, this.params);
|
|
15484
15512
|
}
|
|
15485
15513
|
Object.assign(this.context, context);
|
|
15486
15514
|
const navParams = this.model.appViewNavParams;
|
|
15487
15515
|
let params = {};
|
|
15488
|
-
if (
|
|
15516
|
+
if (notNilEmpty7(navParams)) {
|
|
15489
15517
|
params = convertNavData(navParams, this.context, this.params);
|
|
15490
15518
|
}
|
|
15491
15519
|
Object.assign(this.params, params);
|
|
@@ -15552,6 +15580,29 @@ var ViewController = class extends BaseController {
|
|
|
15552
15580
|
var MobViewController = class extends ViewController {
|
|
15553
15581
|
};
|
|
15554
15582
|
|
|
15583
|
+
// src/controller/common/view/wf-step-trace-view.controller.ts
|
|
15584
|
+
var WFStepTraceViewController = class extends ViewController {
|
|
15585
|
+
initState() {
|
|
15586
|
+
super.initState();
|
|
15587
|
+
this.state.historyData = null;
|
|
15588
|
+
}
|
|
15589
|
+
async onCreated() {
|
|
15590
|
+
var _a;
|
|
15591
|
+
await super.onCreated();
|
|
15592
|
+
const app = ibiz.hub.getApp(this.context.srfappid);
|
|
15593
|
+
if ((_a = this.ctx.parent) == null ? void 0 : _a.view.model.appDataEntityId) {
|
|
15594
|
+
const entityService = await app.deService.getService(
|
|
15595
|
+
this.ctx.parent.view.model.appDataEntityId
|
|
15596
|
+
);
|
|
15597
|
+
const params = Object.assign(this.context.clone(), this.params);
|
|
15598
|
+
const res = await entityService.wf.getWFHistory(params);
|
|
15599
|
+
if (res.data) {
|
|
15600
|
+
this.state.historyData = res.data;
|
|
15601
|
+
}
|
|
15602
|
+
}
|
|
15603
|
+
}
|
|
15604
|
+
};
|
|
15605
|
+
|
|
15555
15606
|
// src/controller/common/editor/editor.controller.ts
|
|
15556
15607
|
var EditorController = class {
|
|
15557
15608
|
/**
|
|
@@ -16013,7 +16064,7 @@ var MDControlController = class extends ControlController {
|
|
|
16013
16064
|
await this.service.remove(tempContext, params);
|
|
16014
16065
|
needRefresh = true;
|
|
16015
16066
|
}
|
|
16016
|
-
this.afterRemove(
|
|
16067
|
+
this.afterRemove(item);
|
|
16017
16068
|
})
|
|
16018
16069
|
);
|
|
16019
16070
|
if ((args == null ? void 0 : args.silent) !== true) {
|
|
@@ -16044,7 +16095,9 @@ var MDControlController = class extends ControlController {
|
|
|
16044
16095
|
const index = this.state.items.findIndex(
|
|
16045
16096
|
(item) => item.srfkey === data.srfkey
|
|
16046
16097
|
);
|
|
16047
|
-
|
|
16098
|
+
if (index !== -1) {
|
|
16099
|
+
this.state.items.splice(index, 1);
|
|
16100
|
+
}
|
|
16048
16101
|
}
|
|
16049
16102
|
/**
|
|
16050
16103
|
* 获取多数据部件的选中数据集合
|
|
@@ -17641,17 +17694,17 @@ var CaptionBarController = class extends ControlController {
|
|
|
17641
17694
|
import { recursiveIterate } from "@ibiz-template/core";
|
|
17642
17695
|
|
|
17643
17696
|
// src/ui-action/provider/backend-ui-action-provider.ts
|
|
17644
|
-
import { RuntimeModelError as
|
|
17697
|
+
import { RuntimeModelError as RuntimeModelError38 } from "@ibiz-template/core";
|
|
17645
17698
|
import { isArray as isArray3 } from "qx-util";
|
|
17646
17699
|
|
|
17647
17700
|
// src/ui-action/provider/ui-action-provider-base.ts
|
|
17648
|
-
import { RuntimeModelError as
|
|
17701
|
+
import { RuntimeModelError as RuntimeModelError37 } from "@ibiz-template/core";
|
|
17649
17702
|
|
|
17650
17703
|
// src/ui-logic/index.ts
|
|
17651
17704
|
import { RuntimeError as RuntimeError30 } from "@ibiz-template/core";
|
|
17652
17705
|
|
|
17653
17706
|
// src/ui-logic/ui-logic.ts
|
|
17654
|
-
import { ModelError as
|
|
17707
|
+
import { ModelError as ModelError23, RuntimeModelError as RuntimeModelError36 } from "@ibiz-template/core";
|
|
17655
17708
|
|
|
17656
17709
|
// src/ui-logic/ui-logic-context.ts
|
|
17657
17710
|
var UILogicContext = class {
|
|
@@ -17749,6 +17802,28 @@ var UILogicContext = class {
|
|
|
17749
17802
|
var _a;
|
|
17750
17803
|
(_a = this.deLogicParams.get(name)) == null ? void 0 : _a.renew(this);
|
|
17751
17804
|
}
|
|
17805
|
+
/**
|
|
17806
|
+
* 设置上一次返回值
|
|
17807
|
+
* @author lxm
|
|
17808
|
+
* @date 2023-09-04 09:23:52
|
|
17809
|
+
* @param {unknown} value
|
|
17810
|
+
*/
|
|
17811
|
+
setLastReturn(value) {
|
|
17812
|
+
this.lastReturn = value;
|
|
17813
|
+
}
|
|
17814
|
+
/**
|
|
17815
|
+
* 初始化上一次返回参数类型的逻辑参数
|
|
17816
|
+
* @author lxm
|
|
17817
|
+
* @date 2023-09-04 09:52:00
|
|
17818
|
+
* @param {string} tag
|
|
17819
|
+
*/
|
|
17820
|
+
initLastReturnParam(tag) {
|
|
17821
|
+
Object.defineProperty(this.params, tag, {
|
|
17822
|
+
enumerable: true,
|
|
17823
|
+
configurable: true,
|
|
17824
|
+
get: () => this.lastReturn
|
|
17825
|
+
});
|
|
17826
|
+
}
|
|
17752
17827
|
};
|
|
17753
17828
|
|
|
17754
17829
|
// src/ui-logic/ui-logic-node/de-action-node/de-action-node.ts
|
|
@@ -18206,8 +18281,89 @@ var BindParamNode2 = class extends UILogicNode {
|
|
|
18206
18281
|
}
|
|
18207
18282
|
};
|
|
18208
18283
|
|
|
18209
|
-
// src/ui-logic/ui-logic-
|
|
18284
|
+
// src/ui-logic/ui-logic-node/msg-box-node/msg-box-node.ts
|
|
18210
18285
|
import { ModelError as ModelError21, RuntimeModelError as RuntimeModelError33 } from "@ibiz-template/core";
|
|
18286
|
+
var MsgBoxNode = class extends UILogicNode {
|
|
18287
|
+
constructor() {
|
|
18288
|
+
super(...arguments);
|
|
18289
|
+
this.typeMap = {
|
|
18290
|
+
INFO: "info",
|
|
18291
|
+
QUESTION: "success",
|
|
18292
|
+
WARNING: "warning",
|
|
18293
|
+
ERROR: "error"
|
|
18294
|
+
};
|
|
18295
|
+
}
|
|
18296
|
+
async exec(ctx) {
|
|
18297
|
+
const { msgBoxType, buttonsType, msgBoxParamId } = this.model;
|
|
18298
|
+
if (!msgBoxType) {
|
|
18299
|
+
throw new RuntimeModelError33(this.model, "\u7F3A\u5C11\u6D88\u606F\u7C7B\u578B\u7684\u914D\u7F6E");
|
|
18300
|
+
}
|
|
18301
|
+
if (!buttonsType) {
|
|
18302
|
+
throw new RuntimeModelError33(this.model, "\u7F3A\u5C11\u6309\u94AE\u7C7B\u578B\u7684\u914D\u7F6E");
|
|
18303
|
+
}
|
|
18304
|
+
let { title } = this.model;
|
|
18305
|
+
let { message } = this.model;
|
|
18306
|
+
if (msgBoxParamId) {
|
|
18307
|
+
const param = ctx.params[msgBoxParamId];
|
|
18308
|
+
if (param.title) {
|
|
18309
|
+
title = param.title;
|
|
18310
|
+
}
|
|
18311
|
+
if (param.message) {
|
|
18312
|
+
message = param.message;
|
|
18313
|
+
}
|
|
18314
|
+
}
|
|
18315
|
+
const type = this.typeMap[msgBoxType];
|
|
18316
|
+
const modalParams = {
|
|
18317
|
+
type,
|
|
18318
|
+
title: title || "\u6D88\u606F",
|
|
18319
|
+
desc: message
|
|
18320
|
+
};
|
|
18321
|
+
let resultTags = [];
|
|
18322
|
+
switch (buttonsType) {
|
|
18323
|
+
case "YESNO":
|
|
18324
|
+
modalParams.confirmButtonText = "\u662F";
|
|
18325
|
+
modalParams.cancelButtonText = "\u5426";
|
|
18326
|
+
modalParams.showConfirmButton = true;
|
|
18327
|
+
modalParams.showCancelButton = true;
|
|
18328
|
+
resultTags = ["yes", "no"];
|
|
18329
|
+
break;
|
|
18330
|
+
case "OK":
|
|
18331
|
+
modalParams.confirmButtonText = "\u786E\u5B9A";
|
|
18332
|
+
modalParams.showConfirmButton = true;
|
|
18333
|
+
modalParams.showCancelButton = false;
|
|
18334
|
+
resultTags = ["ok"];
|
|
18335
|
+
break;
|
|
18336
|
+
case "OKCANCEL":
|
|
18337
|
+
modalParams.confirmButtonText = "\u786E\u5B9A";
|
|
18338
|
+
modalParams.cancelButtonText = "\u53D6\u6D88";
|
|
18339
|
+
modalParams.showConfirmButton = true;
|
|
18340
|
+
modalParams.showCancelButton = true;
|
|
18341
|
+
resultTags = ["ok", "cancel"];
|
|
18342
|
+
break;
|
|
18343
|
+
default:
|
|
18344
|
+
throw new ModelError21(this.model, "".concat(buttonsType, "\u6682\u672A\u652F\u6301"));
|
|
18345
|
+
}
|
|
18346
|
+
console.log(this.model, modalParams);
|
|
18347
|
+
const result = await ibiz.modal.confirm(modalParams);
|
|
18348
|
+
ctx.setLastReturn(resultTags[result ? 0 : 1]);
|
|
18349
|
+
}
|
|
18350
|
+
};
|
|
18351
|
+
|
|
18352
|
+
// src/ui-logic/ui-logic-node/debug-param-node/debug-param-node.ts
|
|
18353
|
+
import { RuntimeModelError as RuntimeModelError34 } from "@ibiz-template/core";
|
|
18354
|
+
var DebugParamNode = class extends UILogicNode {
|
|
18355
|
+
async exec(ctx) {
|
|
18356
|
+
const { dstDEUILogicParamId, name } = this.model;
|
|
18357
|
+
if (!dstDEUILogicParamId) {
|
|
18358
|
+
throw new RuntimeModelError34(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
|
|
18359
|
+
}
|
|
18360
|
+
const param = ctx.params[dstDEUILogicParamId];
|
|
18361
|
+
console.log("\u903B\u8F91\u8282\u70B9".concat(name, "\u64CD\u4F5C\u53C2\u6570\u503C:"), param);
|
|
18362
|
+
}
|
|
18363
|
+
};
|
|
18364
|
+
|
|
18365
|
+
// src/ui-logic/ui-logic-param/ui-logic-param.ts
|
|
18366
|
+
import { ModelError as ModelError22, RuntimeModelError as RuntimeModelError35 } from "@ibiz-template/core";
|
|
18211
18367
|
var UILogicParam = class {
|
|
18212
18368
|
/**
|
|
18213
18369
|
* Creates an instance of UILogicParam.
|
|
@@ -18242,7 +18398,7 @@ var UILogicParam = class {
|
|
|
18242
18398
|
if (control) {
|
|
18243
18399
|
ctx.params[tag] = control;
|
|
18244
18400
|
} else {
|
|
18245
|
-
throw new
|
|
18401
|
+
throw new RuntimeModelError35(
|
|
18246
18402
|
this.model,
|
|
18247
18403
|
"\u89C6\u56FE\u903B\u8F91\u521D\u59CB\u5316\u53C2\u6570\uFF0C\u672A\u627E\u5230".concat(m.codeName, "\u6307\u5B9A\u90E8\u4EF6\u5BF9\u8C61")
|
|
18248
18404
|
);
|
|
@@ -18256,17 +18412,17 @@ var UILogicParam = class {
|
|
|
18256
18412
|
} else if (m.entityListParam) {
|
|
18257
18413
|
ctx.params[tag] = [];
|
|
18258
18414
|
} else if (m.entityPageParam) {
|
|
18259
|
-
throw new
|
|
18415
|
+
throw new ModelError22(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B: \u5206\u9875\u67E5\u8BE2\u7ED3\u679C");
|
|
18260
18416
|
} else if (m.entityParam) {
|
|
18261
18417
|
ctx.params[tag] = {};
|
|
18262
18418
|
} else if (m.lastReturnParam) {
|
|
18263
|
-
|
|
18419
|
+
ctx.initLastReturnParam(tag);
|
|
18264
18420
|
} else if (m.navContextParam) {
|
|
18265
18421
|
ctx.params[tag] = context;
|
|
18266
18422
|
} else if (m.navViewParamParam) {
|
|
18267
|
-
throw new
|
|
18423
|
+
throw new ModelError22(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B: \u89C6\u56FE\u8DEF\u7531\u53C2\u6570");
|
|
18268
18424
|
} else if (m.routeViewSessionParam) {
|
|
18269
|
-
throw new
|
|
18425
|
+
throw new ModelError22(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B: \u8DEF\u7531\u89C6\u56FE\u4F1A\u8BDD");
|
|
18270
18426
|
} else if (m.simpleListParam) {
|
|
18271
18427
|
ctx.params[tag] = [];
|
|
18272
18428
|
} else if (m.simpleParam) {
|
|
@@ -18274,7 +18430,7 @@ var UILogicParam = class {
|
|
|
18274
18430
|
} else if (m.viewNavDataParam) {
|
|
18275
18431
|
ctx.params[tag] = viewParams;
|
|
18276
18432
|
} else if (m.viewSessionParam) {
|
|
18277
|
-
throw new
|
|
18433
|
+
throw new ModelError22(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B: \u5F53\u524D\u89C6\u56FE\u4F1A\u8BDD");
|
|
18278
18434
|
}
|
|
18279
18435
|
}
|
|
18280
18436
|
/**
|
|
@@ -18291,7 +18447,7 @@ var UILogicParam = class {
|
|
|
18291
18447
|
} else if (m.simpleParam || m.entityParam) {
|
|
18292
18448
|
ctx.params[tag] = {};
|
|
18293
18449
|
} else {
|
|
18294
|
-
throw new
|
|
18450
|
+
throw new ModelError22(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B\u91CD\u65B0\u5EFA\u7ACB\u53D8\u91CF");
|
|
18295
18451
|
}
|
|
18296
18452
|
}
|
|
18297
18453
|
};
|
|
@@ -18326,7 +18482,7 @@ var UILogic = class {
|
|
|
18326
18482
|
this.params = /* @__PURE__ */ new Map();
|
|
18327
18483
|
var _a;
|
|
18328
18484
|
if (!((_a = model.deuilogicNodes) == null ? void 0 : _a.length)) {
|
|
18329
|
-
throw new
|
|
18485
|
+
throw new RuntimeModelError36(model, "\u754C\u9762\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u903B\u8F91\u8282\u70B9");
|
|
18330
18486
|
}
|
|
18331
18487
|
model.deuilogicNodes.forEach((node) => {
|
|
18332
18488
|
const { logicNodeType } = node;
|
|
@@ -18353,6 +18509,12 @@ var UILogic = class {
|
|
|
18353
18509
|
case "VIEWCTRLINVOKE":
|
|
18354
18510
|
logicNode = new ViewCtrlInvokeNode(node);
|
|
18355
18511
|
break;
|
|
18512
|
+
case "MSGBOX":
|
|
18513
|
+
logicNode = new MsgBoxNode(node);
|
|
18514
|
+
break;
|
|
18515
|
+
case "DEBUGPARAM":
|
|
18516
|
+
logicNode = new DebugParamNode(node);
|
|
18517
|
+
break;
|
|
18356
18518
|
case "RESETPARAM":
|
|
18357
18519
|
case "COPYPARAM":
|
|
18358
18520
|
case "VIEWCTRLFIREEVENT":
|
|
@@ -18360,13 +18522,11 @@ var UILogic = class {
|
|
|
18360
18522
|
case "SORTPARAM":
|
|
18361
18523
|
case "RENEWPARAM":
|
|
18362
18524
|
case "PFPLUGIN":
|
|
18363
|
-
case "MSGBOX":
|
|
18364
18525
|
case "DEDATASET":
|
|
18365
18526
|
case "DELOGIC":
|
|
18366
18527
|
case "THROWEXCEPTION":
|
|
18367
|
-
case "DEBUGPARAM":
|
|
18368
18528
|
default:
|
|
18369
|
-
throw new
|
|
18529
|
+
throw new ModelError23(node, "\u672A\u652F\u6301\u7684\u903B\u8F91\u8282\u70B9\u7C7B\u578B: ".concat(logicNodeType));
|
|
18370
18530
|
}
|
|
18371
18531
|
this.nodes.set(node.id, logicNode);
|
|
18372
18532
|
});
|
|
@@ -18419,7 +18579,7 @@ var UILogic = class {
|
|
|
18419
18579
|
const start = this.nodes.get(startDEUILogicNodeId);
|
|
18420
18580
|
await this.deepExec(start, ctx);
|
|
18421
18581
|
} else {
|
|
18422
|
-
throw new
|
|
18582
|
+
throw new RuntimeModelError36(this.model, "\u672A\u8BBE\u7F6E\u8D77\u59CB\u8282\u70B9");
|
|
18423
18583
|
}
|
|
18424
18584
|
if (ctx.isEndNode) {
|
|
18425
18585
|
return ctx.result;
|
|
@@ -18549,7 +18709,7 @@ var UIActionProviderBase = class {
|
|
|
18549
18709
|
const { appDEUILogicId, appDataEntityId, uilogicAttachMode } = action;
|
|
18550
18710
|
if (uilogicAttachMode === "REPLACE") {
|
|
18551
18711
|
if (!appDEUILogicId) {
|
|
18552
|
-
throw new
|
|
18712
|
+
throw new RuntimeModelError37(action, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u754C\u9762\u903B\u8F91");
|
|
18553
18713
|
}
|
|
18554
18714
|
await execUILogic(appDEUILogicId, appDataEntityId, args);
|
|
18555
18715
|
return result;
|
|
@@ -18576,7 +18736,7 @@ var UIActionProviderBase = class {
|
|
|
18576
18736
|
}
|
|
18577
18737
|
if (action.uilogicAttachMode === "AFTER") {
|
|
18578
18738
|
if (!appDEUILogicId) {
|
|
18579
|
-
throw new
|
|
18739
|
+
throw new RuntimeModelError37(action, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u754C\u9762\u903B\u8F91");
|
|
18580
18740
|
}
|
|
18581
18741
|
await execUILogic(appDEUILogicId, appDataEntityId, args);
|
|
18582
18742
|
}
|
|
@@ -18710,7 +18870,7 @@ var BackendUIActionProvider = class extends UIActionProviderBase {
|
|
|
18710
18870
|
const entityName = action.appDataEntityId;
|
|
18711
18871
|
const methodName = action.appDEMethodId;
|
|
18712
18872
|
if (!entityName || !methodName) {
|
|
18713
|
-
throw new
|
|
18873
|
+
throw new RuntimeModelError38(action, "\u672A\u914D\u7F6E\u5B9E\u4F53\u6216\u5B9E\u4F53\u884C\u4E3A");
|
|
18714
18874
|
}
|
|
18715
18875
|
const { resultContext, resultParams, resultData } = await this.handleParams(
|
|
18716
18876
|
action,
|
|
@@ -18822,7 +18982,7 @@ var SysUIActionProvider = class extends UIActionProviderBase {
|
|
|
18822
18982
|
};
|
|
18823
18983
|
|
|
18824
18984
|
// src/ui-action/provider/front-ui-action-provider.ts
|
|
18825
|
-
import { StringUtil, RuntimeModelError as
|
|
18985
|
+
import { StringUtil, RuntimeModelError as RuntimeModelError39, ModelError as ModelError24 } from "@ibiz-template/core";
|
|
18826
18986
|
var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
18827
18987
|
async execAction(action, args) {
|
|
18828
18988
|
const { context, params, data, event, noWaitRoute } = args;
|
|
@@ -18837,7 +18997,7 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
18837
18997
|
case "WIZARD": {
|
|
18838
18998
|
const frontPSAppView = action.frontAppViewId;
|
|
18839
18999
|
if (!frontPSAppView) {
|
|
18840
|
-
throw new
|
|
19000
|
+
throw new RuntimeModelError39(action, "\u672A\u914D\u7F6E\u6253\u5F00\u89C6\u56FE");
|
|
18841
19001
|
}
|
|
18842
19002
|
const { resultContext, resultParams } = await this.handleParams(
|
|
18843
19003
|
action,
|
|
@@ -18866,7 +19026,7 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
18866
19026
|
actionResult = this.doOther(action, args);
|
|
18867
19027
|
break;
|
|
18868
19028
|
default:
|
|
18869
|
-
throw new
|
|
19029
|
+
throw new ModelError24(
|
|
18870
19030
|
action,
|
|
18871
19031
|
"\u672A\u652F\u6301\u7684\u524D\u53F0\u5904\u7406\u6A21\u5F0F[".concat(action.frontProcessType, "]")
|
|
18872
19032
|
);
|
|
@@ -18893,7 +19053,7 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
18893
19053
|
);
|
|
18894
19054
|
return result || {};
|
|
18895
19055
|
}
|
|
18896
|
-
throw new
|
|
19056
|
+
throw new RuntimeModelError39(action, "\u81EA\u5B9A\u4E49\u7C7B\u578B\u7F3A\u5C11\u914D\u7F6E\u811A\u672C\u4EE3\u7801");
|
|
18897
19057
|
}
|
|
18898
19058
|
};
|
|
18899
19059
|
|
|
@@ -19376,7 +19536,7 @@ var ViewPortletController = class extends PortletPartController {
|
|
|
19376
19536
|
};
|
|
19377
19537
|
|
|
19378
19538
|
// src/controller/control/data-view/data-view.controller.ts
|
|
19379
|
-
import { RuntimeModelError as
|
|
19539
|
+
import { RuntimeModelError as RuntimeModelError40 } from "@ibiz-template/core";
|
|
19380
19540
|
|
|
19381
19541
|
// src/controller/control/data-view/data-view.service.ts
|
|
19382
19542
|
var DataViewControlService = class extends MDControlService {
|
|
@@ -19476,7 +19636,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
19476
19636
|
const optItemModel = this.getOptItemModel();
|
|
19477
19637
|
if (optItemModel) {
|
|
19478
19638
|
if (!optItemModel.deuiactionGroup) {
|
|
19479
|
-
throw new
|
|
19639
|
+
throw new RuntimeModelError40(this.model, "\u64CD\u4F5C\u9879\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A\u7EC4");
|
|
19480
19640
|
}
|
|
19481
19641
|
if (!((_a = optItemModel.deuiactionGroup.uiactionGroupDetails) == null ? void 0 : _a.length)) {
|
|
19482
19642
|
ibiz.log.debug("\u64CD\u4F5C\u9879\u754C\u9762\u884C\u4E3A\u7EC4\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
|
|
@@ -19618,10 +19778,10 @@ var DataViewControlController = class extends MDControlController {
|
|
|
19618
19778
|
};
|
|
19619
19779
|
|
|
19620
19780
|
// src/controller/control/exp-bar/calendar-exp-bar.controller.ts
|
|
19621
|
-
import { RuntimeModelError as
|
|
19781
|
+
import { RuntimeModelError as RuntimeModelError42 } from "@ibiz-template/core";
|
|
19622
19782
|
|
|
19623
19783
|
// src/controller/control/exp-bar/exp-bar.controller.ts
|
|
19624
|
-
import { RuntimeError as RuntimeError33, RuntimeModelError as
|
|
19784
|
+
import { RuntimeError as RuntimeError33, RuntimeModelError as RuntimeModelError41 } from "@ibiz-template/core";
|
|
19625
19785
|
var ExpBarControlController = class extends ControlController {
|
|
19626
19786
|
constructor() {
|
|
19627
19787
|
super(...arguments);
|
|
@@ -19676,7 +19836,7 @@ var ExpBarControlController = class extends ControlController {
|
|
|
19676
19836
|
get xDataController() {
|
|
19677
19837
|
const controller = this.view.getController(this.model.xdataControlName);
|
|
19678
19838
|
if (!controller) {
|
|
19679
|
-
throw new
|
|
19839
|
+
throw new RuntimeModelError41(
|
|
19680
19840
|
this.model,
|
|
19681
19841
|
"\u65E0\u6CD5\u83B7\u53D6\u591A\u6570\u636E\u90E8\u4EF6[".concat(this.model.xdataControlName, "]\u63A7\u5236\u5668")
|
|
19682
19842
|
);
|
|
@@ -19830,6 +19990,7 @@ var ExpBarControlController = class extends ControlController {
|
|
|
19830
19990
|
defaultNavByFirstItem() {
|
|
19831
19991
|
const data = this.xDataController.state.items[0];
|
|
19832
19992
|
if (!data) {
|
|
19993
|
+
this._evt.emit("onNavViewChange", { navViewMsg: { key: "" } });
|
|
19833
19994
|
return;
|
|
19834
19995
|
}
|
|
19835
19996
|
this.xDataController.setActive(data);
|
|
@@ -19972,7 +20133,7 @@ var CalendarExpBarController = class extends ExpBarControlController {
|
|
|
19972
20133
|
get xDataController() {
|
|
19973
20134
|
const controller = this.view.getController(this.model.xdataControlName);
|
|
19974
20135
|
if (!controller) {
|
|
19975
|
-
throw new
|
|
20136
|
+
throw new RuntimeModelError42(
|
|
19976
20137
|
this.model,
|
|
19977
20138
|
"\u65E0\u6CD5\u83B7\u53D6\u591A\u6570\u636E\u90E8\u4EF6[".concat(this.model.xdataControlName, "]\u63A7\u5236\u5668")
|
|
19978
20139
|
);
|
|
@@ -20026,7 +20187,7 @@ var CalendarExpBarController = class extends ExpBarControlController {
|
|
|
20026
20187
|
};
|
|
20027
20188
|
|
|
20028
20189
|
// src/controller/control/exp-bar/tree-exp-bar.controller.ts
|
|
20029
|
-
import { RuntimeError as RuntimeError34, RuntimeModelError as
|
|
20190
|
+
import { RuntimeError as RuntimeError34, RuntimeModelError as RuntimeModelError43 } from "@ibiz-template/core";
|
|
20030
20191
|
var TreeExpBarController = class extends ExpBarControlController {
|
|
20031
20192
|
constructor() {
|
|
20032
20193
|
super(...arguments);
|
|
@@ -20049,7 +20210,7 @@ var TreeExpBarController = class extends ExpBarControlController {
|
|
|
20049
20210
|
get xDataController() {
|
|
20050
20211
|
const controller = this.view.getController(this.model.xdataControlName);
|
|
20051
20212
|
if (!controller) {
|
|
20052
|
-
throw new
|
|
20213
|
+
throw new RuntimeModelError43(
|
|
20053
20214
|
this.model,
|
|
20054
20215
|
"\u65E0\u6CD5\u83B7\u53D6\u591A\u6570\u636E\u90E8\u4EF6[".concat(this.model.xdataControlName, "]\u63A7\u5236\u5668")
|
|
20055
20216
|
);
|
|
@@ -20826,7 +20987,7 @@ var FormButtonController = class extends FormDetailController {
|
|
|
20826
20987
|
|
|
20827
20988
|
// src/controller/control/form/form-detail/form-druipart/form-druipart.controller.ts
|
|
20828
20989
|
import { isOverlap as isOverlap2 } from "@ibiz-template/core";
|
|
20829
|
-
import { createUUID as createUUID3, notNilEmpty as
|
|
20990
|
+
import { createUUID as createUUID3, notNilEmpty as notNilEmpty8 } from "qx-util";
|
|
20830
20991
|
|
|
20831
20992
|
// src/controller/control/form/form-detail/form-druipart/form-druipart.state.ts
|
|
20832
20993
|
var FormDruipartState = class extends FormDetailState {
|
|
@@ -20919,7 +21080,7 @@ var FormDRUIPartController = class extends FormDetailController {
|
|
|
20919
21080
|
calcViewParams() {
|
|
20920
21081
|
let newContext = this.form.context.clone();
|
|
20921
21082
|
const navContexts = this.model.navigateContexts;
|
|
20922
|
-
if (
|
|
21083
|
+
if (notNilEmpty8(navContexts)) {
|
|
20923
21084
|
newContext = Object.assign(
|
|
20924
21085
|
newContext,
|
|
20925
21086
|
convertNavData(
|
|
@@ -21089,7 +21250,7 @@ var FormGroupPanelController = class extends FormDetailController {
|
|
|
21089
21250
|
// src/controller/control/form/form-detail/form-item/form-item.controller.ts
|
|
21090
21251
|
import Schema from "async-validator";
|
|
21091
21252
|
import { createUUID as createUUID4, isNilOrEmpty as isNilOrEmpty6 } from "qx-util";
|
|
21092
|
-
import { ModelError as
|
|
21253
|
+
import { ModelError as ModelError25, RuntimeError as RuntimeError36 } from "@ibiz-template/core";
|
|
21093
21254
|
import dayjs3 from "dayjs";
|
|
21094
21255
|
|
|
21095
21256
|
// src/controller/control/form/form-detail/form-item/form-item.state.ts
|
|
@@ -21212,6 +21373,17 @@ var FormItemController = class extends FormDetailController {
|
|
|
21212
21373
|
get valueFormat() {
|
|
21213
21374
|
return this.model.valueFormat;
|
|
21214
21375
|
}
|
|
21376
|
+
/**
|
|
21377
|
+
* 数据类型
|
|
21378
|
+
*
|
|
21379
|
+
* @author zhanghengfeng
|
|
21380
|
+
* @date 2023-09-01 11:09:00
|
|
21381
|
+
* @readonly
|
|
21382
|
+
* @type {(number | undefined)}
|
|
21383
|
+
*/
|
|
21384
|
+
get dataType() {
|
|
21385
|
+
return this.model.dataType;
|
|
21386
|
+
}
|
|
21215
21387
|
/**
|
|
21216
21388
|
* 初始化
|
|
21217
21389
|
*
|
|
@@ -21405,7 +21577,7 @@ var FormItemController = class extends FormDetailController {
|
|
|
21405
21577
|
data[this.name] = createUUID4();
|
|
21406
21578
|
break;
|
|
21407
21579
|
default:
|
|
21408
|
-
throw new
|
|
21580
|
+
throw new ModelError25(this.model, "\u9ED8\u8BA4\u503C\u7C7B\u578B[".concat(valueType, "]\u672A\u652F\u6301"));
|
|
21409
21581
|
}
|
|
21410
21582
|
}
|
|
21411
21583
|
};
|
|
@@ -21652,7 +21824,7 @@ import { debounce } from "lodash-es";
|
|
|
21652
21824
|
// src/controller/control/form/edit-form/edit-form.service.ts
|
|
21653
21825
|
import {
|
|
21654
21826
|
recursiveIterate as recursiveIterate3,
|
|
21655
|
-
RuntimeModelError as
|
|
21827
|
+
RuntimeModelError as RuntimeModelError44
|
|
21656
21828
|
} from "@ibiz-template/core";
|
|
21657
21829
|
var EditFormService = class extends ControlService {
|
|
21658
21830
|
/**
|
|
@@ -21725,10 +21897,12 @@ var EditFormService = class extends ControlService {
|
|
|
21725
21897
|
*/
|
|
21726
21898
|
async create(context, data) {
|
|
21727
21899
|
var _a;
|
|
21900
|
+
const _data = data instanceof ControlVO ? data.getOrigin() : data;
|
|
21901
|
+
const tempData = this.getFilteredData(_data);
|
|
21728
21902
|
let res = await this.exec(
|
|
21729
21903
|
((_a = this.model.createControlAction) == null ? void 0 : _a.appDEMethodId) || "create",
|
|
21730
21904
|
context,
|
|
21731
|
-
|
|
21905
|
+
tempData
|
|
21732
21906
|
);
|
|
21733
21907
|
res = this.handleResponse(res);
|
|
21734
21908
|
return res;
|
|
@@ -21744,10 +21918,12 @@ var EditFormService = class extends ControlService {
|
|
|
21744
21918
|
*/
|
|
21745
21919
|
async update(context, data) {
|
|
21746
21920
|
var _a;
|
|
21921
|
+
const _data = data instanceof ControlVO ? data.getOrigin() : data;
|
|
21922
|
+
const tempData = this.getFilteredData(_data);
|
|
21747
21923
|
let res = await this.exec(
|
|
21748
21924
|
((_a = this.model.updateControlAction) == null ? void 0 : _a.appDEMethodId) || "update",
|
|
21749
21925
|
context,
|
|
21750
|
-
|
|
21926
|
+
tempData
|
|
21751
21927
|
);
|
|
21752
21928
|
res = this.handleResponse(res);
|
|
21753
21929
|
return res;
|
|
@@ -21766,7 +21942,7 @@ var EditFormService = class extends ControlService {
|
|
|
21766
21942
|
const wizardForm = this.model;
|
|
21767
21943
|
const methodName = (_a = wizardForm.goBackControlAction) == null ? void 0 : _a.appDEMethodId;
|
|
21768
21944
|
if (!methodName) {
|
|
21769
|
-
throw new
|
|
21945
|
+
throw new RuntimeModelError44(this.model, "\u7F3A\u5C11\u8FD4\u56DE\u64CD\u4F5C\u5B9E\u4F53\u884C\u4E3A");
|
|
21770
21946
|
}
|
|
21771
21947
|
let res = await this.exec(
|
|
21772
21948
|
methodName,
|
|
@@ -21866,7 +22042,7 @@ var EditFormService = class extends ControlService {
|
|
|
21866
22042
|
recursiveIterate3(
|
|
21867
22043
|
this.model,
|
|
21868
22044
|
(item) => {
|
|
21869
|
-
if (item.detailType === "FORMITEM") {
|
|
22045
|
+
if (item.detailType === "FORMITEM" || item.detailType === "MDCTRL") {
|
|
21870
22046
|
const formItem = item;
|
|
21871
22047
|
const uiKey = formItem.fieldName || formItem.id.toLowerCase();
|
|
21872
22048
|
const deField = formItem.fieldName || item.appDEFieldId;
|
|
@@ -21883,22 +22059,6 @@ var EditFormService = class extends ControlService {
|
|
|
21883
22059
|
}
|
|
21884
22060
|
this.dataUIMap.set(uiKey, mapField);
|
|
21885
22061
|
}
|
|
21886
|
-
if (item.detailType === "MDCTRL") {
|
|
21887
|
-
const formItem = item;
|
|
21888
|
-
const uiKey = formItem.fieldName || formItem.id.toLowerCase();
|
|
21889
|
-
const deField = formItem.fieldName || item.appDEFieldId;
|
|
21890
|
-
let mapField;
|
|
21891
|
-
if (deField) {
|
|
21892
|
-
mapField = new UIMapField(uiKey, deField, {
|
|
21893
|
-
isOriginField: true
|
|
21894
|
-
});
|
|
21895
|
-
} else {
|
|
21896
|
-
mapField = new UIMapField(uiKey, uiKey, {
|
|
21897
|
-
isOriginField: true
|
|
21898
|
-
});
|
|
21899
|
-
}
|
|
21900
|
-
this.dataUIMap.set(uiKey, mapField);
|
|
21901
|
-
}
|
|
21902
22062
|
},
|
|
21903
22063
|
{
|
|
21904
22064
|
childrenFields: ["deformPages", "deformDetails"]
|
|
@@ -21920,6 +22080,22 @@ var EditFormService = class extends ControlService {
|
|
|
21920
22080
|
}
|
|
21921
22081
|
return res;
|
|
21922
22082
|
}
|
|
22083
|
+
/**
|
|
22084
|
+
* 保存时根据表单项过滤出传给后台的数据
|
|
22085
|
+
*
|
|
22086
|
+
* @return {*}
|
|
22087
|
+
* @author: zhujiamin
|
|
22088
|
+
* @Date: 2023-09-01 10:04:25
|
|
22089
|
+
*/
|
|
22090
|
+
getFilteredData(data) {
|
|
22091
|
+
const tempData = {};
|
|
22092
|
+
this.dataUIMap.forEach((dataUI) => {
|
|
22093
|
+
if (data[dataUI.dataKey] !== void 0) {
|
|
22094
|
+
tempData[dataUI.dataKey] = data[dataUI.dataKey];
|
|
22095
|
+
}
|
|
22096
|
+
});
|
|
22097
|
+
return tempData;
|
|
22098
|
+
}
|
|
21923
22099
|
};
|
|
21924
22100
|
|
|
21925
22101
|
// src/controller/control/form/edit-form/edit-form.controller.ts
|
|
@@ -22739,14 +22915,15 @@ var FormMDCtrlRepeaterGridController = class extends FormMDCtrlContentTypeContro
|
|
|
22739
22915
|
initColumns(details) {
|
|
22740
22916
|
details.forEach(async (detail) => {
|
|
22741
22917
|
if (detail.detailType === "FORMITEM") {
|
|
22742
|
-
const { editor } = detail;
|
|
22918
|
+
const { editor, dataType } = detail;
|
|
22743
22919
|
const editorProvider = await getEditorProvider(editor);
|
|
22744
22920
|
if (editorProvider) {
|
|
22745
22921
|
const c = await editorProvider.createController(editor, {
|
|
22746
22922
|
unitName: editor.unitName,
|
|
22747
22923
|
valueFormat: editor.valueFormat,
|
|
22748
22924
|
context: this.parent.form.context,
|
|
22749
|
-
params: this.parent.form.params
|
|
22925
|
+
params: this.parent.form.params,
|
|
22926
|
+
dataType
|
|
22750
22927
|
});
|
|
22751
22928
|
this.editorMap[detail.codeName] = {
|
|
22752
22929
|
provider: editorProvider,
|
|
@@ -23204,7 +23381,7 @@ import {
|
|
|
23204
23381
|
debounceAndAsyncMerge as debounceAndAsyncMerge2,
|
|
23205
23382
|
recursiveIterate as recursiveIterate4,
|
|
23206
23383
|
RuntimeError as RuntimeError40,
|
|
23207
|
-
RuntimeModelError as
|
|
23384
|
+
RuntimeModelError as RuntimeModelError45
|
|
23208
23385
|
} from "@ibiz-template/core";
|
|
23209
23386
|
import { clone as clone13 } from "ramda";
|
|
23210
23387
|
|
|
@@ -23245,7 +23422,10 @@ var GridService = class extends MDControlService {
|
|
|
23245
23422
|
* @returns {*} {Promise<IHttpResponse<ControlVO>>}
|
|
23246
23423
|
*/
|
|
23247
23424
|
async updateGridEditItem(methodName, context, params = {}) {
|
|
23248
|
-
|
|
23425
|
+
const entityService = await this.app.deService.getService(
|
|
23426
|
+
this.model.appDataEntityId
|
|
23427
|
+
);
|
|
23428
|
+
let res = await entityService.exec(methodName, context, params);
|
|
23249
23429
|
res = this.handleResponse(res);
|
|
23250
23430
|
return res;
|
|
23251
23431
|
}
|
|
@@ -23396,11 +23576,11 @@ var GridController = class extends MDControlController {
|
|
|
23396
23576
|
(item) => item.model.appDEFieldId === groupAppDEFieldId
|
|
23397
23577
|
);
|
|
23398
23578
|
if (!this.groupFieldColumn) {
|
|
23399
|
-
throw new
|
|
23579
|
+
throw new RuntimeModelError45(this.model, "\u6CA1\u6709\u914D\u7F6E\u5206\u7EC4\u5C5E\u6027\u7684\u5C5E\u6027\u5217");
|
|
23400
23580
|
}
|
|
23401
23581
|
const groupFieldName = this.groupFieldColumn.model.id;
|
|
23402
23582
|
if (!this.groupFieldColumn.model.appCodeListId) {
|
|
23403
|
-
throw new
|
|
23583
|
+
throw new RuntimeModelError45(
|
|
23404
23584
|
this.groupFieldColumn.model,
|
|
23405
23585
|
"\u5206\u7EC4\u5C5E\u6027\u7684\u5C5E\u6027\u5217".concat(groupFieldName, "\u6CA1\u6709\u914D\u7F6E\u4EE3\u7801\u8868")
|
|
23406
23586
|
);
|
|
@@ -23410,7 +23590,7 @@ var GridController = class extends MDControlController {
|
|
|
23410
23590
|
);
|
|
23411
23591
|
if (index !== -1 && index !== 0) {
|
|
23412
23592
|
if (this.isMultistageHeader) {
|
|
23413
|
-
throw new
|
|
23593
|
+
throw new RuntimeModelError45(
|
|
23414
23594
|
this.model,
|
|
23415
23595
|
"\u8BF7\u5C06\u5206\u7EC4\u5C5E\u6027\u5217".concat(groupFieldName, "\u914D\u7F6E\u4E3A\u7B2C\u4E00\u5217")
|
|
23416
23596
|
);
|
|
@@ -23420,10 +23600,10 @@ var GridController = class extends MDControlController {
|
|
|
23420
23600
|
}
|
|
23421
23601
|
if (groupMode === "CODELIST") {
|
|
23422
23602
|
if (!groupCodeListId) {
|
|
23423
|
-
throw new
|
|
23603
|
+
throw new RuntimeModelError45(this.model, "\u4EE3\u7801\u8868\u5206\u7EC4\u6A21\u5F0F\u9700\u8981\u914D\u7F6E\u4EE3\u7801\u8868");
|
|
23424
23604
|
}
|
|
23425
23605
|
if (this.groupFieldColumn.model.appCodeListId !== groupCodeListId) {
|
|
23426
|
-
throw new
|
|
23606
|
+
throw new RuntimeModelError45(
|
|
23427
23607
|
this.model,
|
|
23428
23608
|
"\u5206\u7EC4\u4EE3\u7801\u8868\u4E0E\u5C5E\u6027\u5217".concat(groupFieldName, "\u7684\u4EE3\u7801\u8868\u4E0D\u4E00\u81F4")
|
|
23429
23609
|
);
|
|
@@ -23503,7 +23683,7 @@ var GridController = class extends MDControlController {
|
|
|
23503
23683
|
return;
|
|
23504
23684
|
}
|
|
23505
23685
|
if (!aggAppDEDataSetId || !aggAppDataEntityId) {
|
|
23506
|
-
throw new
|
|
23686
|
+
throw new RuntimeModelError45(this.model, "\u7F3A\u5C11\u914D\u7F6E\u805A\u5408\u5B9E\u4F53\u6216\u805A\u5408\u6570\u636E\u96C6");
|
|
23507
23687
|
}
|
|
23508
23688
|
const params = await this.getFetchParams();
|
|
23509
23689
|
const app = ibiz.hub.getApp(this.context.srfappid);
|
|
@@ -23887,21 +24067,27 @@ var GridController = class extends MDControlController {
|
|
|
23887
24067
|
if (!findUpdate) {
|
|
23888
24068
|
throw new RuntimeError40("\u6CA1\u627E\u5230".concat(updateId, "\u7F16\u8F91\u5217\u66F4\u65B0"));
|
|
23889
24069
|
}
|
|
23890
|
-
const { appDEMethodId, degeiupdateDetails } = findUpdate;
|
|
24070
|
+
const { appDEMethodId, degeiupdateDetails, customCode, scriptCode } = findUpdate;
|
|
23891
24071
|
const updateItems = degeiupdateDetails.map((item) => item.id);
|
|
23892
|
-
|
|
23893
|
-
|
|
23894
|
-
|
|
23895
|
-
|
|
23896
|
-
|
|
23897
|
-
|
|
23898
|
-
|
|
23899
|
-
|
|
23900
|
-
|
|
23901
|
-
|
|
23902
|
-
return this.setRowValue(row, itemName, result[itemName]);
|
|
23903
|
-
})
|
|
24072
|
+
if (customCode && scriptCode) {
|
|
24073
|
+
ScriptFactory.execScriptFn({ data: row.data }, scriptCode, {
|
|
24074
|
+
isAsync: false
|
|
24075
|
+
});
|
|
24076
|
+
} else {
|
|
24077
|
+
const params = { ...this.params, ...row.data.getOrigin() };
|
|
24078
|
+
const res = await this.service.updateGridEditItem(
|
|
24079
|
+
appDEMethodId,
|
|
24080
|
+
this.context,
|
|
24081
|
+
params
|
|
23904
24082
|
);
|
|
24083
|
+
const result = res.data;
|
|
24084
|
+
if (result && (updateItems == null ? void 0 : updateItems.length)) {
|
|
24085
|
+
await Promise.all(
|
|
24086
|
+
updateItems.map((itemName) => {
|
|
24087
|
+
return this.setRowValue(row, itemName, result[itemName]);
|
|
24088
|
+
})
|
|
24089
|
+
);
|
|
24090
|
+
}
|
|
23905
24091
|
}
|
|
23906
24092
|
}
|
|
23907
24093
|
/**
|
|
@@ -24019,7 +24205,7 @@ var GridController = class extends MDControlController {
|
|
|
24019
24205
|
};
|
|
24020
24206
|
|
|
24021
24207
|
// src/controller/control/grid/grid-column/grid-field-column/grid-field-column.controller.ts
|
|
24022
|
-
import { DataTypes, ModelError as
|
|
24208
|
+
import { DataTypes, ModelError as ModelError26 } from "@ibiz-template/core";
|
|
24023
24209
|
import dayjs4 from "dayjs";
|
|
24024
24210
|
import { clone as clone14 } from "ramda";
|
|
24025
24211
|
var GridFieldColumnController = class extends GridColumnController {
|
|
@@ -24106,7 +24292,7 @@ var GridFieldColumnController = class extends GridColumnController {
|
|
|
24106
24292
|
const valueItem = this.model.linkValueItem || "srfkey";
|
|
24107
24293
|
const value = row.data[valueItem];
|
|
24108
24294
|
if (value == null) {
|
|
24109
|
-
throw new
|
|
24295
|
+
throw new ModelError26(this.model, "\u672A\u5728\u884C\u6570\u636E\u4E2D\u53D6\u5230 ".concat(valueItem, " \u7684\u503C"));
|
|
24110
24296
|
}
|
|
24111
24297
|
const { linkAppViewId } = this.model;
|
|
24112
24298
|
if (!linkAppViewId) {
|
|
@@ -24207,12 +24393,12 @@ var GridFieldColumnController = class extends GridColumnController {
|
|
|
24207
24393
|
aggValue = Math.min(...items.map((item) => item[fieldName]));
|
|
24208
24394
|
break;
|
|
24209
24395
|
default:
|
|
24210
|
-
throw new
|
|
24396
|
+
throw new ModelError26(this.model, "\u6682\u672A\u652F\u6301\u5C5E\u6027\u5217\u805A\u5408\u6A21\u5F0F".concat(aggMode));
|
|
24211
24397
|
}
|
|
24212
24398
|
} else if (this.grid.model.aggMode === "ALL") {
|
|
24213
|
-
throw new
|
|
24399
|
+
throw new ModelError26(this.model, "\u8FDC\u7A0B\u805A\u5408\u6682\u672A\u652F\u6301");
|
|
24214
24400
|
} else {
|
|
24215
|
-
throw new
|
|
24401
|
+
throw new ModelError26(
|
|
24216
24402
|
this.grid.model,
|
|
24217
24403
|
"\u6682\u672A\u652F\u6301\u805A\u5408\u6A21\u5F0F".concat(this.grid.model.aggMode)
|
|
24218
24404
|
);
|
|
@@ -24238,7 +24424,7 @@ var GridFieldColumnController = class extends GridColumnController {
|
|
|
24238
24424
|
* @return {*} {string}
|
|
24239
24425
|
*/
|
|
24240
24426
|
formatValue(value = "") {
|
|
24241
|
-
if (this.model.valueType) {
|
|
24427
|
+
if (this.model.valueType !== "SIMPLE") {
|
|
24242
24428
|
return ValueExUtil.toText(this.model, value);
|
|
24243
24429
|
}
|
|
24244
24430
|
const strVal = "".concat(value);
|
|
@@ -24254,7 +24440,7 @@ var GridFieldColumnController = class extends GridColumnController {
|
|
|
24254
24440
|
};
|
|
24255
24441
|
|
|
24256
24442
|
// src/controller/control/grid/grid-column/grid-ua-column/grid-ua-column.controller.ts
|
|
24257
|
-
import { RuntimeModelError as
|
|
24443
|
+
import { RuntimeModelError as RuntimeModelError46 } from "@ibiz-template/core";
|
|
24258
24444
|
var GridUAColumnController = class extends GridColumnController {
|
|
24259
24445
|
/**
|
|
24260
24446
|
* 给rowController初始化操作列的状态
|
|
@@ -24267,7 +24453,7 @@ var GridUAColumnController = class extends GridColumnController {
|
|
|
24267
24453
|
var _a;
|
|
24268
24454
|
const { deuiactionGroup } = this.model;
|
|
24269
24455
|
if (!deuiactionGroup) {
|
|
24270
|
-
throw new
|
|
24456
|
+
throw new RuntimeModelError46(this.model, "\u64CD\u4F5C\u5217\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A\u7EC4");
|
|
24271
24457
|
}
|
|
24272
24458
|
if (!((_a = deuiactionGroup.uiactionGroupDetails) == null ? void 0 : _a.length)) {
|
|
24273
24459
|
ibiz.log.debug("\u64CD\u4F5C\u5217\u754C\u9762\u884C\u4E3A\u7EC4\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
|
|
@@ -24601,6 +24787,7 @@ var ListController = class extends MDControlController {
|
|
|
24601
24787
|
}
|
|
24602
24788
|
async onCreated() {
|
|
24603
24789
|
await super.onCreated();
|
|
24790
|
+
this.state.size = this.model.pagingSize || 20;
|
|
24604
24791
|
this.service = new ListService(this.model);
|
|
24605
24792
|
await this.service.init(this.context);
|
|
24606
24793
|
}
|
|
@@ -25584,7 +25771,7 @@ var TabExpPanelController = class extends ControlController {
|
|
|
25584
25771
|
import { recursiveIterate as recursiveIterate5 } from "@ibiz-template/core";
|
|
25585
25772
|
|
|
25586
25773
|
// src/controller/control/tree/tree.service.ts
|
|
25587
|
-
import { ModelError as
|
|
25774
|
+
import { ModelError as ModelError27 } from "@ibiz-template/core";
|
|
25588
25775
|
var TreeService = class extends MDControlService {
|
|
25589
25776
|
/**
|
|
25590
25777
|
* 获取子节点数据
|
|
@@ -25684,7 +25871,7 @@ var TreeService = class extends MDControlService {
|
|
|
25684
25871
|
);
|
|
25685
25872
|
break;
|
|
25686
25873
|
default:
|
|
25687
|
-
throw new
|
|
25874
|
+
throw new ModelError27(
|
|
25688
25875
|
nodeModel,
|
|
25689
25876
|
"".concat(nodeModel.treeNodeType, "\u8282\u70B9\u7C7B\u578B\u672A\u652F\u6301")
|
|
25690
25877
|
);
|
|
@@ -27170,7 +27357,7 @@ var ViewEngineBase = class {
|
|
|
27170
27357
|
};
|
|
27171
27358
|
|
|
27172
27359
|
// src/engine/md-view.engine.ts
|
|
27173
|
-
import { RuntimeModelError as
|
|
27360
|
+
import { RuntimeModelError as RuntimeModelError47 } from "@ibiz-template/core";
|
|
27174
27361
|
var MDViewEngine = class extends ViewEngineBase {
|
|
27175
27362
|
/**
|
|
27176
27363
|
* 多数据部件名称
|
|
@@ -27248,12 +27435,12 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
27248
27435
|
}
|
|
27249
27436
|
if (this.searchForm) {
|
|
27250
27437
|
this.searchForm.evt.on("onSearch", () => {
|
|
27251
|
-
this.
|
|
27438
|
+
this.reLoad();
|
|
27252
27439
|
});
|
|
27253
27440
|
}
|
|
27254
27441
|
if (this.searchBar) {
|
|
27255
27442
|
this.searchBar.evt.on("onSearch", () => {
|
|
27256
|
-
this.
|
|
27443
|
+
this.reLoad();
|
|
27257
27444
|
});
|
|
27258
27445
|
}
|
|
27259
27446
|
if (!this.view.state.noLoadDefault && model.loadDefault) {
|
|
@@ -27359,7 +27546,7 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
27359
27546
|
(item) => item.id === "newdata"
|
|
27360
27547
|
);
|
|
27361
27548
|
if (!openAppViewLogic) {
|
|
27362
|
-
throw new
|
|
27549
|
+
throw new RuntimeModelError47(this.view.model, "\u7F3A\u5C11newdata\u7684\u89C6\u56FE\u903B\u8F91");
|
|
27363
27550
|
}
|
|
27364
27551
|
const context = this.view.context.clone();
|
|
27365
27552
|
if (copyMode) {
|
|
@@ -27375,7 +27562,7 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
27375
27562
|
if (result instanceof Object && result.ok) {
|
|
27376
27563
|
this.refresh();
|
|
27377
27564
|
} else if (result === -1) {
|
|
27378
|
-
throw new
|
|
27565
|
+
throw new RuntimeModelError47(this.view.model, "\u7F3A\u5C11newdata\u7684\u89C6\u56FE\u903B\u8F91");
|
|
27379
27566
|
}
|
|
27380
27567
|
}
|
|
27381
27568
|
/**
|
|
@@ -27406,6 +27593,15 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
27406
27593
|
async refresh() {
|
|
27407
27594
|
await this.xdataControl.refresh();
|
|
27408
27595
|
}
|
|
27596
|
+
/**
|
|
27597
|
+
* 视图重新加载
|
|
27598
|
+
* @author lxm
|
|
27599
|
+
* @date 2023-05-22 03:17:33
|
|
27600
|
+
* @return {*} {Promise<void>}
|
|
27601
|
+
*/
|
|
27602
|
+
async reLoad() {
|
|
27603
|
+
await this.xdataControl.load({ isInitialLoad: true });
|
|
27604
|
+
}
|
|
27409
27605
|
/**
|
|
27410
27606
|
* 获取搜索相关的查询参数
|
|
27411
27607
|
* @author lxm
|
|
@@ -27563,7 +27759,7 @@ var LogicExecutor = class {
|
|
|
27563
27759
|
};
|
|
27564
27760
|
|
|
27565
27761
|
// src/logic-scheduler/executor/logic-executor-factory.ts
|
|
27566
|
-
import { ModelError as
|
|
27762
|
+
import { ModelError as ModelError28 } from "@ibiz-template/core";
|
|
27567
27763
|
var LogicExecutorFactory = class {
|
|
27568
27764
|
constructor() {
|
|
27569
27765
|
/**
|
|
@@ -27593,7 +27789,7 @@ var LogicExecutorFactory = class {
|
|
|
27593
27789
|
createExecutor(logic, scheduler) {
|
|
27594
27790
|
const constructor = this.constructorMap.get(logic.logicType);
|
|
27595
27791
|
if (!constructor) {
|
|
27596
|
-
throw new
|
|
27792
|
+
throw new ModelError28(logic, "\u903B\u8F91\u7C7B\u578B ".concat(logic.logicType, " \u6682\u672A\u652F\u6301\uFF01"));
|
|
27597
27793
|
}
|
|
27598
27794
|
return constructor(logic, scheduler);
|
|
27599
27795
|
}
|
|
@@ -27642,13 +27838,13 @@ var ScriptExecutor = class extends LogicExecutor {
|
|
|
27642
27838
|
};
|
|
27643
27839
|
|
|
27644
27840
|
// src/logic-scheduler/executor/app-de-ui-logic-executor.ts
|
|
27645
|
-
import { RuntimeModelError as
|
|
27841
|
+
import { RuntimeModelError as RuntimeModelError48 } from "@ibiz-template/core";
|
|
27646
27842
|
var AppDEUILogicExecutor = class extends LogicExecutor {
|
|
27647
27843
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
27648
27844
|
execute(executeParams) {
|
|
27649
27845
|
const { appDEUILogicId, appDataEntityId } = this.logic;
|
|
27650
27846
|
if (!appDEUILogicId) {
|
|
27651
|
-
throw new
|
|
27847
|
+
throw new RuntimeModelError48(this.logic, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u754C\u9762\u903B\u8F91");
|
|
27652
27848
|
}
|
|
27653
27849
|
execUILogic(appDEUILogicId, appDataEntityId, executeParams);
|
|
27654
27850
|
}
|
|
@@ -27906,7 +28102,7 @@ var ViewLogicScheduler = class extends LogicScheduler {
|
|
|
27906
28102
|
};
|
|
27907
28103
|
|
|
27908
28104
|
// src/logic-scheduler/trigger/logic-trigger-factory.ts
|
|
27909
|
-
import { ModelError as
|
|
28105
|
+
import { ModelError as ModelError29 } from "@ibiz-template/core";
|
|
27910
28106
|
var LogicTriggerFactory = class {
|
|
27911
28107
|
constructor() {
|
|
27912
28108
|
/**
|
|
@@ -27936,7 +28132,7 @@ var LogicTriggerFactory = class {
|
|
|
27936
28132
|
createTrigger(logic, scheduler) {
|
|
27937
28133
|
const constructor = this.constructorMap.get(logic.triggerType);
|
|
27938
28134
|
if (!constructor) {
|
|
27939
|
-
throw new
|
|
28135
|
+
throw new ModelError29(logic, "\u89E6\u53D1\u5668\u7C7B\u578B ".concat(logic.triggerType, " \u6682\u672A\u652F\u6301\uFF01"));
|
|
27940
28136
|
}
|
|
27941
28137
|
return constructor(logic, scheduler);
|
|
27942
28138
|
}
|
|
@@ -28127,11 +28323,11 @@ var TimerTrigger = class extends LogicTrigger {
|
|
|
28127
28323
|
|
|
28128
28324
|
// src/logic-scheduler/executor/app-ui-logic-executor.ts
|
|
28129
28325
|
import {
|
|
28130
|
-
ModelError as
|
|
28326
|
+
ModelError as ModelError30,
|
|
28131
28327
|
RuntimeError as RuntimeError50,
|
|
28132
|
-
RuntimeModelError as
|
|
28328
|
+
RuntimeModelError as RuntimeModelError49
|
|
28133
28329
|
} from "@ibiz-template/core";
|
|
28134
|
-
import { notNilEmpty as
|
|
28330
|
+
import { notNilEmpty as notNilEmpty9 } from "qx-util";
|
|
28135
28331
|
var AppUILogicExecutor = class extends LogicExecutor {
|
|
28136
28332
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
28137
28333
|
execute(executeParams) {
|
|
@@ -28168,14 +28364,14 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
28168
28364
|
}
|
|
28169
28365
|
const openViewRef = appUILogic.openDataAppView;
|
|
28170
28366
|
if (!openViewRef) {
|
|
28171
|
-
throw new
|
|
28367
|
+
throw new RuntimeModelError49(
|
|
28172
28368
|
appUILogic,
|
|
28173
28369
|
"opendata\u89C6\u56FE\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u9ED8\u8BA4\u6253\u5F00\u89C6\u56FE"
|
|
28174
28370
|
);
|
|
28175
28371
|
}
|
|
28176
28372
|
const openView = openViewRef.refAppViewId;
|
|
28177
28373
|
if (!openView) {
|
|
28178
|
-
throw new
|
|
28374
|
+
throw new RuntimeModelError49(
|
|
28179
28375
|
appUILogic,
|
|
28180
28376
|
"opendata\u89C6\u56FE\u903B\u8F91\u7684\u9ED8\u8BA4\u6253\u5F00\u89C6\u56FE\u6CA1\u6709\u5B9E\u9645\u5F15\u7528\u89C6\u56FE"
|
|
28181
28377
|
);
|
|
@@ -28187,7 +28383,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
28187
28383
|
);
|
|
28188
28384
|
let tempParams = {};
|
|
28189
28385
|
const navParams = openViewRef.navigateParams;
|
|
28190
|
-
if (
|
|
28386
|
+
if (notNilEmpty9(navParams)) {
|
|
28191
28387
|
tempParams = convertNavData(navParams, params, context, data[0]);
|
|
28192
28388
|
}
|
|
28193
28389
|
return ibiz.commands.execute(
|
|
@@ -28221,13 +28417,13 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
28221
28417
|
return { ok: false };
|
|
28222
28418
|
}
|
|
28223
28419
|
} else if (enableBatchAdd) {
|
|
28224
|
-
throw new
|
|
28420
|
+
throw new ModelError30(appUILogic, "enableBatchAdd\u6682\u672A\u652F\u6301");
|
|
28225
28421
|
} else if (batchAddOnly) {
|
|
28226
|
-
throw new
|
|
28422
|
+
throw new ModelError30(appUILogic, "batchAddOnly\u6682\u672A\u652F\u6301");
|
|
28227
28423
|
} else {
|
|
28228
28424
|
newViewRef = newDataAppView;
|
|
28229
28425
|
if (!newViewRef || !newViewRef.refAppViewId) {
|
|
28230
|
-
throw new
|
|
28426
|
+
throw new RuntimeModelError49(
|
|
28231
28427
|
appUILogic,
|
|
28232
28428
|
"newdata\u89C6\u56FE\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u9ED8\u8BA4\u65B0\u5EFA\u6570\u636E\u89C6\u56FE"
|
|
28233
28429
|
);
|
|
@@ -28237,12 +28433,12 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
28237
28433
|
let tempParams = {};
|
|
28238
28434
|
const _data = (data == null ? void 0 : data[0]) || {};
|
|
28239
28435
|
const navContexts = newViewRef.navigateContexts;
|
|
28240
|
-
if (
|
|
28436
|
+
if (notNilEmpty9(navContexts)) {
|
|
28241
28437
|
tempContext = convertNavData(navContexts, context, params, _data);
|
|
28242
28438
|
}
|
|
28243
28439
|
tempContext = Object.assign(context, tempContext);
|
|
28244
28440
|
const navParams = newViewRef.navigateParams;
|
|
28245
|
-
if (
|
|
28441
|
+
if (notNilEmpty9(navParams)) {
|
|
28246
28442
|
tempParams = convertNavData(navParams, params, context, _data);
|
|
28247
28443
|
}
|
|
28248
28444
|
if (context.srfcopymode) {
|
|
@@ -28273,7 +28469,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
28273
28469
|
const { wizardAppView, newDataAppViews } = appUILogic;
|
|
28274
28470
|
const { context, params, ...rest } = parameters;
|
|
28275
28471
|
if (!wizardAppView || !wizardAppView.refAppViewId) {
|
|
28276
|
-
throw new
|
|
28472
|
+
throw new RuntimeModelError49(appUILogic, "\u7F3A\u5C11\u9ED8\u8BA4\u7D22\u5F15\u5B9E\u4F53\u9009\u62E9\u89C6\u56FE");
|
|
28277
28473
|
}
|
|
28278
28474
|
const result = await ibiz.commands.execute(
|
|
28279
28475
|
OpenAppViewCommand.TAG,
|
|
@@ -28659,6 +28855,7 @@ export {
|
|
|
28659
28855
|
ViewMode,
|
|
28660
28856
|
ViewPortletController,
|
|
28661
28857
|
ViewType,
|
|
28858
|
+
WFStepTraceViewController,
|
|
28662
28859
|
WFWithdrawUIActionProvider,
|
|
28663
28860
|
WizardPanelController,
|
|
28664
28861
|
WizardPanelService,
|