@ibiz-template/runtime 0.5.3-beta.0 → 0.5.3-beta.2
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 +774 -809
- package/dist/index.system.min.js +1 -1
- package/out/app-hub.d.ts +12 -1
- package/out/app-hub.d.ts.map +1 -1
- package/out/app-hub.js +14 -0
- package/out/constant/control-type.d.ts +5 -1
- package/out/constant/control-type.d.ts.map +1 -1
- package/out/constant/control-type.js +4 -0
- package/out/controller/control/grid/grid/grid.controller.js +1 -1
- package/out/interface/common/i-app-hub-service/i-app-hub-service.d.ts +12 -1
- package/out/interface/common/i-app-hub-service/i-app-hub-service.d.ts.map +1 -1
- package/out/interface/service/index.d.ts +0 -1
- package/out/interface/service/index.d.ts.map +1 -1
- package/out/interface/service/service/i-app-de.service.d.ts +17 -0
- package/out/interface/service/service/i-app-de.service.d.ts.map +1 -1
- package/out/interface/service/service/i-wf.service.d.ts +5 -4
- package/out/interface/service/service/i-wf.service.d.ts.map +1 -1
- package/out/service/dto/method.dto.d.ts +0 -10
- package/out/service/dto/method.dto.d.ts.map +1 -1
- package/out/service/dto/method.dto.js +36 -40
- package/out/service/service/entity/de.service.d.ts +6 -9
- package/out/service/service/entity/de.service.d.ts.map +1 -1
- package/out/service/service/entity/de.service.js +4 -10
- package/out/service/service/entity/method/de-action.d.ts.map +1 -1
- package/out/service/service/entity/method/de-action.js +6 -5
- package/out/service/service/entity/method/fetch.d.ts.map +1 -1
- package/out/service/service/entity/method/fetch.js +17 -21
- package/out/service/service/entity/method/method-input.d.ts.map +1 -1
- package/out/service/service/entity/method/method-input.js +3 -2
- package/out/service/service/entity/method/method-renturn.d.ts.map +1 -1
- package/out/service/service/entity/method/method-renturn.js +3 -2
- package/out/service/service/work-flow/work-flow.service.d.ts +1 -1
- package/out/service/service/work-flow/work-flow.service.d.ts.map +1 -1
- package/out/service/service/work-flow/work-flow.service.js +2 -2
- package/out/service/utils/de-cache/de-cache.d.ts +0 -10
- package/out/service/utils/de-cache/de-cache.d.ts.map +1 -1
- package/out/service/utils/de-cache/de-cache.js +1 -78
- package/out/service/utils/de-dq-cond-util/de-dq-cond-util.d.ts.map +1 -1
- package/out/service/utils/de-dq-cond-util/de-dq-cond-util.js +16 -9
- package/out/service/utils/search-filter/search-filter.d.ts +0 -14
- package/out/service/utils/search-filter/search-filter.d.ts.map +1 -1
- package/out/service/utils/search-filter/search-filter.js +0 -8
- package/out/utils/ui-domain/ui-domain.d.ts +7 -7
- package/out/utils/ui-domain/ui-domain.d.ts.map +1 -1
- package/out/utils/ui-domain/ui-domain.js +5 -9
- package/package.json +2 -2
- package/src/app-hub.ts +25 -1
- package/src/constant/control-type.ts +5 -0
- package/src/controller/control/grid/grid/grid.controller.ts +1 -1
- package/src/interface/common/i-app-hub-service/i-app-hub-service.ts +17 -1
- package/src/interface/service/index.ts +0 -1
- package/src/interface/service/service/i-app-de.service.ts +21 -0
- package/src/interface/service/service/i-wf.service.ts +5 -4
- package/src/service/dto/method.dto.ts +49 -46
- package/src/service/service/entity/de.service.ts +22 -15
- package/src/service/service/entity/method/de-action.ts +6 -5
- package/src/service/service/entity/method/fetch.ts +17 -21
- package/src/service/service/entity/method/method-input.ts +3 -1
- package/src/service/service/entity/method/method-renturn.ts +3 -1
- package/src/service/service/work-flow/work-flow.service.ts +8 -2
- package/src/service/utils/de-cache/de-cache.ts +1 -78
- package/src/service/utils/de-dq-cond-util/de-dq-cond-util.ts +14 -9
- package/src/service/utils/search-filter/search-filter.ts +0 -24
- package/src/utils/ui-domain/ui-domain.ts +8 -12
- package/out/interface/service/i-parent-config/i-parent-config.d.ts +0 -67
- package/out/interface/service/i-parent-config/i-parent-config.d.ts.map +0 -1
- package/out/interface/service/i-parent-config/i-parent-config.js +0 -1
- package/src/interface/service/i-parent-config/i-parent-config.ts +0 -66
package/dist/index.esm.js
CHANGED
|
@@ -2280,6 +2280,7 @@ var ControlType = /* @__PURE__ */ ((ControlType2) => {
|
|
|
2280
2280
|
ControlType2["TAB_EXP_PANEL"] = "TABEXPPANEL";
|
|
2281
2281
|
ControlType2["CUSTOM"] = "CUSTOM";
|
|
2282
2282
|
ControlType2["CAPTIONBAR"] = "CAPTIONBAR";
|
|
2283
|
+
ControlType2["CONTEXT_MENU"] = "CONTEXTMENU";
|
|
2283
2284
|
return ControlType2;
|
|
2284
2285
|
})(ControlType || {});
|
|
2285
2286
|
|
|
@@ -2865,7 +2866,7 @@ var UIDomain = class {
|
|
|
2865
2866
|
* @author chitanda
|
|
2866
2867
|
* @date 2023-12-26 15:12:13
|
|
2867
2868
|
* @protected
|
|
2868
|
-
* @type {Map<string,
|
|
2869
|
+
* @type {Map<string, IAppDERS[]>}
|
|
2869
2870
|
*/
|
|
2870
2871
|
this.rsMap = /* @__PURE__ */ new Map();
|
|
2871
2872
|
if (id) {
|
|
@@ -2880,14 +2881,10 @@ var UIDomain = class {
|
|
|
2880
2881
|
* @author chitanda
|
|
2881
2882
|
* @date 2023-12-26 15:12:31
|
|
2882
2883
|
* @param {string} entity
|
|
2883
|
-
* @param {
|
|
2884
|
+
* @param {IAppDERS} configs
|
|
2884
2885
|
*/
|
|
2885
|
-
setDERConfig(deCodeName,
|
|
2886
|
-
|
|
2887
|
-
this.rsMap.set(deCodeName, []);
|
|
2888
|
-
}
|
|
2889
|
-
const arr = this.rsMap.get(deCodeName);
|
|
2890
|
-
arr.push(config);
|
|
2886
|
+
setDERConfig(deCodeName, configs) {
|
|
2887
|
+
this.rsMap.set(deCodeName, configs);
|
|
2891
2888
|
}
|
|
2892
2889
|
/**
|
|
2893
2890
|
* 获取当前界面域下,具体实体的关系(在数据加载完成之后才有值)
|
|
@@ -2895,7 +2892,7 @@ var UIDomain = class {
|
|
|
2895
2892
|
* @author chitanda
|
|
2896
2893
|
* @date 2023-12-26 16:12:07
|
|
2897
2894
|
* @param {string} deCodeName
|
|
2898
|
-
* @return {*} {
|
|
2895
|
+
* @return {*} {IAppDERS[]}
|
|
2899
2896
|
*/
|
|
2900
2897
|
getDERConfig(deCodeName) {
|
|
2901
2898
|
if (this.rsMap.has(deCodeName)) {
|
|
@@ -3031,7 +3028,7 @@ async function handleAllSettled(values, isThrow = true) {
|
|
|
3031
3028
|
|
|
3032
3029
|
// src/command/app/open-app-view/open-app-view.ts
|
|
3033
3030
|
import { ModelError as ModelError15, RuntimeError as RuntimeError23 } from "@ibiz-template/core";
|
|
3034
|
-
import { clone as
|
|
3031
|
+
import { clone as clone15 } from "ramda";
|
|
3035
3032
|
|
|
3036
3033
|
// src/service/utils/de-dq-cond/ps-de-dq-cond-engine.ts
|
|
3037
3034
|
import { isEmpty as isEmpty3 } from "ramda";
|
|
@@ -4305,7 +4302,11 @@ var DEDQCondUtil = class {
|
|
|
4305
4302
|
const groups = dataSet.dedqgroupConditions;
|
|
4306
4303
|
if (groups) {
|
|
4307
4304
|
const cond = new PSDEDQCondEngine();
|
|
4308
|
-
|
|
4305
|
+
if (groups.length === 1) {
|
|
4306
|
+
cond.parse(this.calcCond(groups)[0]);
|
|
4307
|
+
} else if (groups.length > 1) {
|
|
4308
|
+
cond.parse(["AND", this.calcCond(groups)][0]);
|
|
4309
|
+
}
|
|
4309
4310
|
this.map.set(dataSet, cond);
|
|
4310
4311
|
return cond;
|
|
4311
4312
|
}
|
|
@@ -4338,8 +4339,17 @@ var DEDQCondUtil = class {
|
|
|
4338
4339
|
}
|
|
4339
4340
|
} else if (item.condType === "SINGLE") {
|
|
4340
4341
|
const cond = item;
|
|
4342
|
+
condArr.push(cond.condOp);
|
|
4341
4343
|
condArr.push(cond.fieldName);
|
|
4342
4344
|
if (cond.condValue) {
|
|
4345
|
+
if (cond.vartypeId) {
|
|
4346
|
+
condArr.push({
|
|
4347
|
+
type: cond.vartypeId,
|
|
4348
|
+
value: cond.condValue
|
|
4349
|
+
});
|
|
4350
|
+
} else {
|
|
4351
|
+
condArr.push(cond.condValue);
|
|
4352
|
+
}
|
|
4343
4353
|
} else {
|
|
4344
4354
|
condArr.push("");
|
|
4345
4355
|
}
|
|
@@ -4602,7 +4612,7 @@ var DynamicCodeListCache = class {
|
|
|
4602
4612
|
|
|
4603
4613
|
// src/service/utils/de-cache/de-cache.ts
|
|
4604
4614
|
import { where, equals, clone as clone4, isNil as isNil5, isEmpty as isEmpty5 } from "ramda";
|
|
4605
|
-
import {
|
|
4615
|
+
import { createUUID as createUUID2 } from "qx-util";
|
|
4606
4616
|
import { RuntimeError as RuntimeError14 } from "@ibiz-template/core";
|
|
4607
4617
|
|
|
4608
4618
|
// src/service/utils/service-exist-util/service-exist-util.ts
|
|
@@ -4927,64 +4937,6 @@ var DECache = class {
|
|
|
4927
4937
|
const values = this.cacheMap.values();
|
|
4928
4938
|
return Array.from(values);
|
|
4929
4939
|
}
|
|
4930
|
-
/**
|
|
4931
|
-
* 根据条件查找数据,未设置条件默认返回全部
|
|
4932
|
-
*
|
|
4933
|
-
* @author chitanda
|
|
4934
|
-
* @date 2023-12-22 13:12:28
|
|
4935
|
-
* @param {IContext} context
|
|
4936
|
-
* @param {IParams} [params={}]
|
|
4937
|
-
* @return {*} {IDataEntity[]}
|
|
4938
|
-
*/
|
|
4939
|
-
select(context, params = {}) {
|
|
4940
|
-
try {
|
|
4941
|
-
isExistSessionId("getList", context);
|
|
4942
|
-
const values = this.cacheMap.values();
|
|
4943
|
-
let items = Array.from(values);
|
|
4944
|
-
items = ascSort(items, "srfordervalue");
|
|
4945
|
-
const data = {};
|
|
4946
|
-
const nullData = {};
|
|
4947
|
-
const undefinedData = {};
|
|
4948
|
-
const emptyData = {};
|
|
4949
|
-
if (params.srfkey) {
|
|
4950
|
-
data.srfkey = equals(params.srfkey);
|
|
4951
|
-
delete params.srfkey;
|
|
4952
|
-
}
|
|
4953
|
-
for (const key in params) {
|
|
4954
|
-
if (Object.prototype.hasOwnProperty.call(params, key)) {
|
|
4955
|
-
const val = params[key];
|
|
4956
|
-
if (val == null) {
|
|
4957
|
-
nullData[key] = equals(null);
|
|
4958
|
-
undefinedData[key] = equals(void 0);
|
|
4959
|
-
emptyData[key] = equals("");
|
|
4960
|
-
} else {
|
|
4961
|
-
data[key] = equals(val);
|
|
4962
|
-
}
|
|
4963
|
-
}
|
|
4964
|
-
}
|
|
4965
|
-
if (!isEmpty5(data)) {
|
|
4966
|
-
const pred = where(data);
|
|
4967
|
-
const nullPred = where(nullData);
|
|
4968
|
-
const undefinedPred = where(undefinedData);
|
|
4969
|
-
const emptyPred = where(emptyData);
|
|
4970
|
-
items = items.filter((obj) => {
|
|
4971
|
-
if (isEmpty5(nullData)) {
|
|
4972
|
-
if (pred(obj)) {
|
|
4973
|
-
return true;
|
|
4974
|
-
}
|
|
4975
|
-
} else if (pred(obj) && (nullPred(obj) || undefinedPred(obj) || emptyPred(obj))) {
|
|
4976
|
-
return true;
|
|
4977
|
-
}
|
|
4978
|
-
return false;
|
|
4979
|
-
});
|
|
4980
|
-
}
|
|
4981
|
-
const list = items.map((obj) => obj.clone());
|
|
4982
|
-
return list;
|
|
4983
|
-
} catch (err) {
|
|
4984
|
-
ibiz.log.error(err);
|
|
4985
|
-
return [];
|
|
4986
|
-
}
|
|
4987
|
-
}
|
|
4988
4940
|
/**
|
|
4989
4941
|
* 根据条件生成查询
|
|
4990
4942
|
*
|
|
@@ -5154,19 +5106,11 @@ var SearchFilter = class {
|
|
|
5154
5106
|
this.sortMode = arr[1].toUpperCase();
|
|
5155
5107
|
}
|
|
5156
5108
|
}
|
|
5157
|
-
if (!isNil6(data.srfparentkey) && !isEmpty6(data.srfparentkey)) {
|
|
5158
|
-
this.srfparentkey = data.srfparentkey;
|
|
5159
|
-
}
|
|
5160
|
-
if (!isNil6(data.srfparentdename) && !isEmpty6(data.srfparentdename)) {
|
|
5161
|
-
this.srfparentdename = data.srfparentdename;
|
|
5162
|
-
}
|
|
5163
5109
|
this.data = { ...data };
|
|
5164
5110
|
delete this.data.page;
|
|
5165
5111
|
delete this.data.size;
|
|
5166
5112
|
delete this.data.query;
|
|
5167
5113
|
delete this.data.sort;
|
|
5168
|
-
delete this.data.srfparentkey;
|
|
5169
|
-
delete this.data.srfparentdename;
|
|
5170
5114
|
}
|
|
5171
5115
|
}
|
|
5172
5116
|
/**
|
|
@@ -5459,7 +5403,7 @@ CounterService.counterMap = /* @__PURE__ */ new Map();
|
|
|
5459
5403
|
|
|
5460
5404
|
// src/service/service/entity/de.service.ts
|
|
5461
5405
|
import {
|
|
5462
|
-
ModelError as
|
|
5406
|
+
ModelError as ModelError7,
|
|
5463
5407
|
RuntimeError as RuntimeError17
|
|
5464
5408
|
} from "@ibiz-template/core";
|
|
5465
5409
|
|
|
@@ -5601,8 +5545,10 @@ var WorkFlowService = class {
|
|
|
5601
5545
|
* @date 2022-09-29 14:09:45
|
|
5602
5546
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
5603
5547
|
*/
|
|
5604
|
-
async getWFVersion() {
|
|
5605
|
-
return this.app.net.get(
|
|
5548
|
+
async getWFVersion(srfWFTag) {
|
|
5549
|
+
return this.app.net.get(
|
|
5550
|
+
"/wfcore/".concat(ibiz.appData.context.srfsystemid, "-app-").concat(this.app.model.codeName.toLowerCase(), "/").concat(this.model.name.toLowerCase()).concat(srfWFTag ? "-".concat(srfWFTag) : "", "/process-definitions2")
|
|
5551
|
+
);
|
|
5606
5552
|
}
|
|
5607
5553
|
/**
|
|
5608
5554
|
* 启动工作流
|
|
@@ -6022,165 +5968,423 @@ var AppDataEntity = class _AppDataEntity {
|
|
|
6022
5968
|
}
|
|
6023
5969
|
};
|
|
6024
5970
|
|
|
6025
|
-
// src/service/
|
|
6026
|
-
|
|
5971
|
+
// src/service/dto/method.dto.ts
|
|
5972
|
+
import { ModelError as ModelError6, RuntimeModelError as RuntimeModelError9 } from "@ibiz-template/core";
|
|
5973
|
+
import { clone as clone6 } from "ramda";
|
|
5974
|
+
var MethodDto = class {
|
|
6027
5975
|
/**
|
|
6028
|
-
* Creates an instance of
|
|
6029
|
-
*
|
|
6030
|
-
* @
|
|
6031
|
-
* @
|
|
6032
|
-
* @param {
|
|
6033
|
-
* @param {
|
|
5976
|
+
* Creates an instance of MethodDto.
|
|
5977
|
+
* @author lxm
|
|
5978
|
+
* @date 2024-01-04 05:39:07
|
|
5979
|
+
* @param {IAppDEService} service
|
|
5980
|
+
* @param {IAppDataEntity} entity
|
|
5981
|
+
* @param {boolean} [isLocalMode]
|
|
5982
|
+
* @param {IAppDEMethodDTO} [dto]
|
|
5983
|
+
* @param {boolean} [inSelfLoop] 是否在自关系循环中
|
|
6034
5984
|
*/
|
|
6035
|
-
constructor(
|
|
6036
|
-
this.
|
|
6037
|
-
this.
|
|
5985
|
+
constructor(service, entity, isLocalMode, dto, inSelfLoop) {
|
|
5986
|
+
this.service = service;
|
|
5987
|
+
this.entity = entity;
|
|
5988
|
+
this.isLocalMode = isLocalMode;
|
|
5989
|
+
this.dto = dto;
|
|
5990
|
+
this.inSelfLoop = inSelfLoop;
|
|
5991
|
+
this.dtoMap = /* @__PURE__ */ new Map();
|
|
6038
5992
|
/**
|
|
6039
|
-
*
|
|
5993
|
+
* 当前 DTO 是否已经计算过关系相关逻辑
|
|
6040
5994
|
*
|
|
5995
|
+
* @link this.calcRs
|
|
6041
5996
|
* @author chitanda
|
|
6042
|
-
* @date
|
|
5997
|
+
* @date 2023-12-26 16:12:18
|
|
6043
5998
|
* @protected
|
|
6044
|
-
* @type {Map<string, Method>}
|
|
6045
|
-
*/
|
|
6046
|
-
this.methodMap = /* @__PURE__ */ new Map();
|
|
6047
|
-
/**
|
|
6048
|
-
* 是否为本地模式(临时数据模式)服务
|
|
6049
|
-
*
|
|
6050
|
-
* @author chitanda
|
|
6051
|
-
* @date 2023-12-22 16:12:13
|
|
6052
|
-
* @type {boolean}
|
|
6053
5999
|
*/
|
|
6054
|
-
this.
|
|
6055
|
-
|
|
6056
|
-
|
|
6057
|
-
|
|
6058
|
-
|
|
6059
|
-
|
|
6060
|
-
);
|
|
6061
|
-
this.wf = new WorkFlowService(model);
|
|
6062
|
-
this.file = new FileService(model);
|
|
6063
|
-
}
|
|
6064
|
-
/**
|
|
6065
|
-
* 获取实体服务方法实例
|
|
6066
|
-
*
|
|
6067
|
-
* @author chitanda
|
|
6068
|
-
* @date 2023-10-12 17:10:10
|
|
6069
|
-
* @protected
|
|
6070
|
-
* @param {string} id
|
|
6071
|
-
* @param {boolean} [acMode=false]
|
|
6072
|
-
* @return {*} {Method}
|
|
6073
|
-
*/
|
|
6074
|
-
async getMethod(id, acMode = false) {
|
|
6075
|
-
const cacheId = acMode ? "ac-".concat(id) : id;
|
|
6076
|
-
if (this.methodMap.has(cacheId)) {
|
|
6077
|
-
return this.methodMap.get(cacheId);
|
|
6078
|
-
}
|
|
6079
|
-
const model = findModelChild(this.model.appDEMethods, id);
|
|
6080
|
-
const provider = await getDEMethodProvider(model);
|
|
6081
|
-
if (!provider) {
|
|
6082
|
-
throw new ModelError6(model, "\u672A\u652F\u6301\u7684\u670D\u52A1\u65B9\u6CD5\u7C7B\u578B: ".concat(model.methodType));
|
|
6000
|
+
this.isCalcRs = false;
|
|
6001
|
+
if (dto) {
|
|
6002
|
+
this.app = ibiz.hub.getApp(entity.appId);
|
|
6003
|
+
this.fields = dto.appDEMethodDTOFields || [];
|
|
6004
|
+
} else {
|
|
6005
|
+
this.fields = [];
|
|
6083
6006
|
}
|
|
6084
|
-
const method = provider.create(this, this.model, model, {
|
|
6085
|
-
acMode,
|
|
6086
|
-
localMode: this.isLocalMode
|
|
6087
|
-
});
|
|
6088
|
-
this.methodMap.set(cacheId, method);
|
|
6089
|
-
return method;
|
|
6090
6007
|
}
|
|
6091
6008
|
/**
|
|
6092
|
-
*
|
|
6009
|
+
* 转换数组成ListMap
|
|
6093
6010
|
*
|
|
6094
|
-
* @
|
|
6095
|
-
* @
|
|
6096
|
-
* @param {string} id 执行服务方法标识
|
|
6097
|
-
* @param {IContext} context
|
|
6098
|
-
* @param {IData} [params={}] 请求参数
|
|
6099
|
-
* @param {IParams} [params2={}] 查询参数
|
|
6100
|
-
* @return {*} {Promise<IHttpResponse>}
|
|
6011
|
+
* @param {IData[]} arr
|
|
6012
|
+
* @return {*} listMap
|
|
6101
6013
|
*/
|
|
6102
|
-
|
|
6103
|
-
const
|
|
6104
|
-
|
|
6105
|
-
|
|
6106
|
-
}
|
|
6107
|
-
|
|
6108
|
-
}
|
|
6109
|
-
getDraft(context, params, params2) {
|
|
6110
|
-
return this.exec("GetDraft", context, params, params2);
|
|
6111
|
-
}
|
|
6112
|
-
create(context, params, params2) {
|
|
6113
|
-
return this.exec("Create", context, params, params2);
|
|
6114
|
-
}
|
|
6115
|
-
get(context, params, params2) {
|
|
6116
|
-
return this.exec("Get", context, params, params2);
|
|
6117
|
-
}
|
|
6118
|
-
update(context, params, params2) {
|
|
6119
|
-
return this.exec("Update", context, params, params2);
|
|
6120
|
-
}
|
|
6121
|
-
remove(context, params, params2) {
|
|
6122
|
-
return this.exec("Remove", context, params, params2);
|
|
6123
|
-
}
|
|
6124
|
-
fetchDefault(context, params, params2) {
|
|
6125
|
-
return this.exec("FetchDefault", context, params, params2);
|
|
6126
|
-
}
|
|
6127
|
-
getDraftTemp(context, params, params2) {
|
|
6128
|
-
return this.exec("GetDraftTemp", context, params, params2);
|
|
6129
|
-
}
|
|
6130
|
-
createTemp(context, params, params2) {
|
|
6131
|
-
return this.exec("CreateTemp", context, params, params2);
|
|
6132
|
-
}
|
|
6133
|
-
getTemp(context, params, params2) {
|
|
6134
|
-
return this.exec("GetTemp", context, params, params2);
|
|
6135
|
-
}
|
|
6136
|
-
updateTemp(context, params, params2) {
|
|
6137
|
-
return this.exec("UpdateTemp", context, params, params2);
|
|
6138
|
-
}
|
|
6139
|
-
removeTemp(context, params, params2) {
|
|
6140
|
-
return this.exec("RemoveTemp", context, params, params2);
|
|
6141
|
-
}
|
|
6142
|
-
fetchTempDefault(context, params, params2) {
|
|
6143
|
-
return this.exec("FetchTempDefault", context, params, params2);
|
|
6014
|
+
convertArrayToListMap(arr) {
|
|
6015
|
+
const result = {};
|
|
6016
|
+
arr.forEach((obj, index) => {
|
|
6017
|
+
result[index + 1] = obj;
|
|
6018
|
+
});
|
|
6019
|
+
return result;
|
|
6144
6020
|
}
|
|
6145
6021
|
/**
|
|
6146
|
-
*
|
|
6022
|
+
* 转换ListMap成数组
|
|
6147
6023
|
*
|
|
6148
|
-
* @param {
|
|
6149
|
-
* @
|
|
6150
|
-
* @return {*} {Promise<IDataEntity[]>}
|
|
6024
|
+
* @param {listMap} obj
|
|
6025
|
+
* @return {*} IData[]
|
|
6151
6026
|
*/
|
|
6152
|
-
|
|
6153
|
-
|
|
6027
|
+
convertListMapToArray(obj) {
|
|
6028
|
+
const result = [];
|
|
6029
|
+
Object.keys(obj).forEach((key) => {
|
|
6030
|
+
const index = parseInt(key, 10);
|
|
6031
|
+
result[index - 1] = obj[index];
|
|
6032
|
+
});
|
|
6033
|
+
return result;
|
|
6154
6034
|
}
|
|
6155
6035
|
/**
|
|
6156
|
-
*
|
|
6036
|
+
* 请求参数组合 DTO
|
|
6157
6037
|
*
|
|
6158
6038
|
* @author chitanda
|
|
6159
|
-
* @date 2022-
|
|
6160
|
-
* @param {string} id 执行服务方法标识
|
|
6039
|
+
* @date 2022-10-10 23:10:33
|
|
6161
6040
|
* @param {IContext} context
|
|
6162
|
-
* @param {IData}
|
|
6163
|
-
* @
|
|
6164
|
-
* @return {*} {Promise<IHttpResponse>}
|
|
6041
|
+
* @param {IData} data
|
|
6042
|
+
* @return {*} {Promise<IData>}
|
|
6165
6043
|
*/
|
|
6166
|
-
async
|
|
6167
|
-
const
|
|
6168
|
-
|
|
6169
|
-
|
|
6044
|
+
async get(context, data, ignore = false) {
|
|
6045
|
+
const params = {};
|
|
6046
|
+
const uiDomain = ibiz.uiDomainManager.get(context.srfsessionid);
|
|
6047
|
+
for (let i = 0; i < this.fields.length; i++) {
|
|
6048
|
+
const field = this.fields[i];
|
|
6049
|
+
const key = field.codeName.toLowerCase();
|
|
6050
|
+
switch (field.type) {
|
|
6051
|
+
case "SIMPLE":
|
|
6052
|
+
case "SIMPLES":
|
|
6053
|
+
case "DTO": {
|
|
6054
|
+
break;
|
|
6055
|
+
}
|
|
6056
|
+
case "DTOS": {
|
|
6057
|
+
if (field.listMap) {
|
|
6058
|
+
if (data[key]) {
|
|
6059
|
+
params[key] = data[key].length === 0 ? null : this.convertArrayToListMap(data[key]);
|
|
6060
|
+
}
|
|
6061
|
+
} else {
|
|
6062
|
+
if (data[key] !== void 0 && ignore === false) {
|
|
6063
|
+
break;
|
|
6064
|
+
}
|
|
6065
|
+
if (!field.refAppDataEntityId) {
|
|
6066
|
+
break;
|
|
6067
|
+
}
|
|
6068
|
+
const configs = uiDomain.getDERConfig(field.refAppDataEntityId);
|
|
6069
|
+
const dto = await this.getFieldDto(context, field);
|
|
6070
|
+
const service = await ibiz.hub.getAppDEService(
|
|
6071
|
+
dto.entity.appId,
|
|
6072
|
+
field.refAppDataEntityId,
|
|
6073
|
+
context
|
|
6074
|
+
);
|
|
6075
|
+
const deRs = configs.find((rs) => {
|
|
6076
|
+
return rs.majorAppDataEntityId === this.entity.id;
|
|
6077
|
+
});
|
|
6078
|
+
let res;
|
|
6079
|
+
if (deRs && deRs.nestedAppDEDataSetId) {
|
|
6080
|
+
const _context = clone6(context);
|
|
6081
|
+
_context[this.entity.codeName.toLowerCase()] = data.srfkey;
|
|
6082
|
+
const _params = {};
|
|
6083
|
+
if (deRs.parentAppDEFieldId) {
|
|
6084
|
+
_params[deRs.parentAppDEFieldId] = data.srfkey;
|
|
6085
|
+
}
|
|
6086
|
+
res = await service.exec(
|
|
6087
|
+
deRs.nestedAppDEDataSetId,
|
|
6088
|
+
_context,
|
|
6089
|
+
_params
|
|
6090
|
+
);
|
|
6091
|
+
} else if (dto.entity.id !== this.entity.id) {
|
|
6092
|
+
res = await service.exec("FetchDefault", context);
|
|
6093
|
+
} else {
|
|
6094
|
+
throw new RuntimeModelError9(
|
|
6095
|
+
field,
|
|
6096
|
+
"\u5B50\u5173\u7CFB\u672A\u914D\u7F6E\u5D4C\u5957\u5173\u7CFB\u6570\u636E\u96C6, \u4F1A\u5BFC\u81F4\u9012\u5F52\u67E5\u8BE2\u6B7B\u5FAA\u73AF\uFF0C\u8BF7\u914D\u7F6E!"
|
|
6097
|
+
);
|
|
6098
|
+
}
|
|
6099
|
+
if (res.ok) {
|
|
6100
|
+
const items = res.data;
|
|
6101
|
+
const arr = [];
|
|
6102
|
+
for (let j = 0; j < items.length; j++) {
|
|
6103
|
+
arr.push(await dto.get(context, items[j], true));
|
|
6104
|
+
}
|
|
6105
|
+
params[key] = arr;
|
|
6106
|
+
}
|
|
6107
|
+
}
|
|
6108
|
+
break;
|
|
6109
|
+
}
|
|
6110
|
+
default:
|
|
6111
|
+
throw new ModelError6(
|
|
6112
|
+
field,
|
|
6113
|
+
"\u672A\u652F\u6301\u7684\u5E94\u7528\u5B9E\u4F53\u65B9\u6CD5\u8F93\u5165\u5C5E\u6027\u7C7B\u578B: ".concat(field.type)
|
|
6114
|
+
);
|
|
6115
|
+
}
|
|
6170
6116
|
}
|
|
6171
|
-
|
|
6117
|
+
return { ...data, ...params };
|
|
6172
6118
|
}
|
|
6173
6119
|
/**
|
|
6174
|
-
*
|
|
6120
|
+
* 设置本地 DTO 存储
|
|
6175
6121
|
*
|
|
6176
6122
|
* @author chitanda
|
|
6177
|
-
* @date
|
|
6178
|
-
* @param {(data: IPortalAsyncAction) => void} onmessage
|
|
6123
|
+
* @date 2022-10-10 23:10:50
|
|
6179
6124
|
* @param {IContext} context
|
|
6180
|
-
* @param {
|
|
6181
|
-
* @
|
|
6182
|
-
|
|
6183
|
-
|
|
6125
|
+
* @param {IData[]} data
|
|
6126
|
+
* @return {*} {Promise<IDataEntity[]>}
|
|
6127
|
+
*/
|
|
6128
|
+
async sets(context, data) {
|
|
6129
|
+
if (this.isLocalMode && !this.inSelfLoop) {
|
|
6130
|
+
this.service.local.clear();
|
|
6131
|
+
}
|
|
6132
|
+
await this.calcRs(context);
|
|
6133
|
+
return Promise.all(
|
|
6134
|
+
data.map(async (datum) => {
|
|
6135
|
+
const all = this.fields.filter((field) => field.type === "DTOS").map(async (field) => {
|
|
6136
|
+
const key = field.codeName.toLowerCase();
|
|
6137
|
+
if (field.listMap && typeof datum[key] === "object") {
|
|
6138
|
+
datum[key] = this.convertListMapToArray(datum[key]);
|
|
6139
|
+
} else {
|
|
6140
|
+
if (!field.refAppDataEntityId) {
|
|
6141
|
+
return;
|
|
6142
|
+
}
|
|
6143
|
+
const dto = await this.getFieldDto(context, field);
|
|
6144
|
+
const items = datum[key];
|
|
6145
|
+
if (items) {
|
|
6146
|
+
const pKey = datum[this.entity.keyAppDEFieldId];
|
|
6147
|
+
if (field.refPickupAppDEFieldId) {
|
|
6148
|
+
items.forEach((item) => {
|
|
6149
|
+
item[field.refPickupAppDEFieldId] = pKey;
|
|
6150
|
+
});
|
|
6151
|
+
}
|
|
6152
|
+
await dto.sets(context, items);
|
|
6153
|
+
} else {
|
|
6154
|
+
await dto.sets(context, []);
|
|
6155
|
+
}
|
|
6156
|
+
}
|
|
6157
|
+
});
|
|
6158
|
+
for (let i = 0; i < all.length; i++) {
|
|
6159
|
+
await all[i];
|
|
6160
|
+
}
|
|
6161
|
+
const entityData = this.service.createEntity(datum);
|
|
6162
|
+
if (this.isLocalMode) {
|
|
6163
|
+
await this.service.local.add(context, entityData);
|
|
6164
|
+
}
|
|
6165
|
+
return entityData;
|
|
6166
|
+
})
|
|
6167
|
+
);
|
|
6168
|
+
}
|
|
6169
|
+
/**
|
|
6170
|
+
* 递归计算当前 DTO 相关实体的父关系配置
|
|
6171
|
+
*
|
|
6172
|
+
* @author chitanda
|
|
6173
|
+
* @date 2023-12-26 16:12:13
|
|
6174
|
+
* @protected
|
|
6175
|
+
* @param {IContext} context
|
|
6176
|
+
* @param {number} [depth=0] 递归层级,避免进入死循环。最大递归层级为 10
|
|
6177
|
+
* @return {*} {Promise<void>}
|
|
6178
|
+
*/
|
|
6179
|
+
async calcRs(context, depth = 0) {
|
|
6180
|
+
if (this.isCalcRs || depth > 10) {
|
|
6181
|
+
return;
|
|
6182
|
+
}
|
|
6183
|
+
this.isCalcRs = true;
|
|
6184
|
+
depth += 1;
|
|
6185
|
+
const uiDomain = ibiz.uiDomainManager.get(context.srfsessionid);
|
|
6186
|
+
const dtoFields = this.fields.filter((field) => field.type === "DTOS");
|
|
6187
|
+
for (let i = 0; i < dtoFields.length; i++) {
|
|
6188
|
+
const field = dtoFields[i];
|
|
6189
|
+
if (!field.refAppDataEntityId) {
|
|
6190
|
+
continue;
|
|
6191
|
+
}
|
|
6192
|
+
const configs = uiDomain.getDERConfig(field.refAppDataEntityId);
|
|
6193
|
+
if (configs.length === 0) {
|
|
6194
|
+
const dto = await this.getFieldDto(context, field);
|
|
6195
|
+
if (dto.entity.minorAppDERSs) {
|
|
6196
|
+
uiDomain.setDERConfig(
|
|
6197
|
+
field.refAppDataEntityId,
|
|
6198
|
+
dto.entity.minorAppDERSs.filter((rs) => rs.rsmode === 1)
|
|
6199
|
+
);
|
|
6200
|
+
}
|
|
6201
|
+
await dto.calcRs(context, depth);
|
|
6202
|
+
}
|
|
6203
|
+
}
|
|
6204
|
+
}
|
|
6205
|
+
/**
|
|
6206
|
+
* 获取子属性 DTO
|
|
6207
|
+
*
|
|
6208
|
+
* @author chitanda
|
|
6209
|
+
* @date 2023-12-22 13:12:06
|
|
6210
|
+
* @protected
|
|
6211
|
+
* @param {IContext} context
|
|
6212
|
+
* @param {IAppDEMethodDTOField} field
|
|
6213
|
+
* @return {*} {Promise<MethodDto>}
|
|
6214
|
+
*/
|
|
6215
|
+
async getFieldDto(context, field) {
|
|
6216
|
+
if (this.dtoMap.has(field.codeName)) {
|
|
6217
|
+
return this.dtoMap.get(field.codeName);
|
|
6218
|
+
}
|
|
6219
|
+
const entity = await ibiz.hub.getAppDataEntity(
|
|
6220
|
+
field.refAppDataEntityId,
|
|
6221
|
+
this.entity.appId
|
|
6222
|
+
);
|
|
6223
|
+
const methodDto = findModelChild(
|
|
6224
|
+
entity.appDEMethodDTOs || [],
|
|
6225
|
+
field.refAppDEMethodDTOId
|
|
6226
|
+
);
|
|
6227
|
+
const inSelfLoop = this.entity.codeName === entity.codeName;
|
|
6228
|
+
const service = await this.app.deService.getService(context, entity.id);
|
|
6229
|
+
service.isLocalMode = true;
|
|
6230
|
+
const dto = service.createMethodDto(methodDto, {
|
|
6231
|
+
isLocalMode: true,
|
|
6232
|
+
inSelfLoop
|
|
6233
|
+
});
|
|
6234
|
+
this.dtoMap.set(field.codeName, dto);
|
|
6235
|
+
return dto;
|
|
6236
|
+
}
|
|
6237
|
+
};
|
|
6238
|
+
|
|
6239
|
+
// src/service/service/entity/de.service.ts
|
|
6240
|
+
var DEService = class {
|
|
6241
|
+
/**
|
|
6242
|
+
* Creates an instance of DEService.
|
|
6243
|
+
*
|
|
6244
|
+
* @author chitanda
|
|
6245
|
+
* @date 2023-12-22 13:12:21
|
|
6246
|
+
* @param {string} srfSessionId 当前实体会话标识
|
|
6247
|
+
* @param {IAppDataEntity} model 实体模型
|
|
6248
|
+
*/
|
|
6249
|
+
constructor(srfSessionId, model) {
|
|
6250
|
+
this.srfSessionId = srfSessionId;
|
|
6251
|
+
this.model = model;
|
|
6252
|
+
/**
|
|
6253
|
+
* 请求方法实例
|
|
6254
|
+
*
|
|
6255
|
+
* @author chitanda
|
|
6256
|
+
* @date 2022-10-10 12:10:13
|
|
6257
|
+
* @protected
|
|
6258
|
+
* @type {Map<string, Method>}
|
|
6259
|
+
*/
|
|
6260
|
+
this.methodMap = /* @__PURE__ */ new Map();
|
|
6261
|
+
/**
|
|
6262
|
+
* 是否为本地模式(临时数据模式)服务
|
|
6263
|
+
*
|
|
6264
|
+
* @author chitanda
|
|
6265
|
+
* @date 2023-12-22 16:12:13
|
|
6266
|
+
* @type {boolean}
|
|
6267
|
+
*/
|
|
6268
|
+
this.isLocalMode = false;
|
|
6269
|
+
this.local = new DECache(model);
|
|
6270
|
+
this.configCache = new ConfigService(
|
|
6271
|
+
model.appId,
|
|
6272
|
+
"PSAppDataEntity",
|
|
6273
|
+
model.codeName
|
|
6274
|
+
);
|
|
6275
|
+
this.wf = new WorkFlowService(model);
|
|
6276
|
+
this.file = new FileService(model);
|
|
6277
|
+
}
|
|
6278
|
+
/**
|
|
6279
|
+
* 获取实体服务方法实例
|
|
6280
|
+
*
|
|
6281
|
+
* @author chitanda
|
|
6282
|
+
* @date 2023-10-12 17:10:10
|
|
6283
|
+
* @protected
|
|
6284
|
+
* @param {string} id
|
|
6285
|
+
* @param {boolean} [acMode=false]
|
|
6286
|
+
* @return {*} {Method}
|
|
6287
|
+
*/
|
|
6288
|
+
async getMethod(id, acMode = false) {
|
|
6289
|
+
const cacheId = acMode ? "ac-".concat(id) : id;
|
|
6290
|
+
if (this.methodMap.has(cacheId)) {
|
|
6291
|
+
return this.methodMap.get(cacheId);
|
|
6292
|
+
}
|
|
6293
|
+
const model = findModelChild(this.model.appDEMethods, id);
|
|
6294
|
+
const provider = await getDEMethodProvider(model);
|
|
6295
|
+
if (!provider) {
|
|
6296
|
+
throw new ModelError7(model, "\u672A\u652F\u6301\u7684\u670D\u52A1\u65B9\u6CD5\u7C7B\u578B: ".concat(model.methodType));
|
|
6297
|
+
}
|
|
6298
|
+
const method = provider.create(this, this.model, model, {
|
|
6299
|
+
acMode,
|
|
6300
|
+
localMode: this.isLocalMode
|
|
6301
|
+
});
|
|
6302
|
+
this.methodMap.set(cacheId, method);
|
|
6303
|
+
return method;
|
|
6304
|
+
}
|
|
6305
|
+
/**
|
|
6306
|
+
* 执行服务方法
|
|
6307
|
+
*
|
|
6308
|
+
* @author chitanda
|
|
6309
|
+
* @date 2022-09-13 19:09:55
|
|
6310
|
+
* @param {string} id 执行服务方法标识
|
|
6311
|
+
* @param {IContext} context
|
|
6312
|
+
* @param {IData} [params={}] 请求参数
|
|
6313
|
+
* @param {IParams} [params2={}] 查询参数
|
|
6314
|
+
* @return {*} {Promise<IHttpResponse>}
|
|
6315
|
+
*/
|
|
6316
|
+
async exec(id, context, params, params2) {
|
|
6317
|
+
const method = await this.getMethod(id);
|
|
6318
|
+
if (method) {
|
|
6319
|
+
return method.exec(context, params, params2);
|
|
6320
|
+
}
|
|
6321
|
+
throw new RuntimeError17("".concat(this.model.codeName, "\u672A\u652F\u6301\u300C").concat(id, "\u300D\u65B9\u6CD5"));
|
|
6322
|
+
}
|
|
6323
|
+
getDraft(context, params, params2) {
|
|
6324
|
+
return this.exec("GetDraft", context, params, params2);
|
|
6325
|
+
}
|
|
6326
|
+
create(context, params, params2) {
|
|
6327
|
+
return this.exec("Create", context, params, params2);
|
|
6328
|
+
}
|
|
6329
|
+
get(context, params, params2) {
|
|
6330
|
+
return this.exec("Get", context, params, params2);
|
|
6331
|
+
}
|
|
6332
|
+
update(context, params, params2) {
|
|
6333
|
+
return this.exec("Update", context, params, params2);
|
|
6334
|
+
}
|
|
6335
|
+
remove(context, params, params2) {
|
|
6336
|
+
return this.exec("Remove", context, params, params2);
|
|
6337
|
+
}
|
|
6338
|
+
fetchDefault(context, params, params2) {
|
|
6339
|
+
return this.exec("FetchDefault", context, params, params2);
|
|
6340
|
+
}
|
|
6341
|
+
getDraftTemp(context, params, params2) {
|
|
6342
|
+
return this.exec("GetDraftTemp", context, params, params2);
|
|
6343
|
+
}
|
|
6344
|
+
createTemp(context, params, params2) {
|
|
6345
|
+
return this.exec("CreateTemp", context, params, params2);
|
|
6346
|
+
}
|
|
6347
|
+
getTemp(context, params, params2) {
|
|
6348
|
+
return this.exec("GetTemp", context, params, params2);
|
|
6349
|
+
}
|
|
6350
|
+
updateTemp(context, params, params2) {
|
|
6351
|
+
return this.exec("UpdateTemp", context, params, params2);
|
|
6352
|
+
}
|
|
6353
|
+
removeTemp(context, params, params2) {
|
|
6354
|
+
return this.exec("RemoveTemp", context, params, params2);
|
|
6355
|
+
}
|
|
6356
|
+
fetchTempDefault(context, params, params2) {
|
|
6357
|
+
return this.exec("FetchTempDefault", context, params, params2);
|
|
6358
|
+
}
|
|
6359
|
+
/**
|
|
6360
|
+
* 执行服务方法 ac 模式
|
|
6361
|
+
*
|
|
6362
|
+
* @author chitanda
|
|
6363
|
+
* @date 2022-09-13 19:09:55
|
|
6364
|
+
* @param {string} id 执行服务方法标识
|
|
6365
|
+
* @param {IContext} context
|
|
6366
|
+
* @param {IData} [params={}] 请求参数
|
|
6367
|
+
* @param {IParams} [params2={}] 查询参数
|
|
6368
|
+
* @return {*} {Promise<IHttpResponse>}
|
|
6369
|
+
*/
|
|
6370
|
+
async execAc(id, context, params, params2 = {}) {
|
|
6371
|
+
const method = await this.getMethod(id, true);
|
|
6372
|
+
if (method) {
|
|
6373
|
+
return method.exec(context, params, params2);
|
|
6374
|
+
}
|
|
6375
|
+
throw new RuntimeError17("".concat(this.model.codeName, "\u672A\u652F\u6301\u300C").concat(id, "\u300D\u65B9\u6CD5"));
|
|
6376
|
+
}
|
|
6377
|
+
/**
|
|
6378
|
+
* 实体级别 AI 聊天会话
|
|
6379
|
+
*
|
|
6380
|
+
* @author chitanda
|
|
6381
|
+
* @date 2023-10-16 16:10:16
|
|
6382
|
+
* @param {(data: IPortalAsyncAction) => void} onmessage
|
|
6383
|
+
* @param {IContext} context
|
|
6384
|
+
* @param {IParams} [params={}]
|
|
6385
|
+
* @param {IData} [data={}]
|
|
6386
|
+
* @return {*} {Promise<void>}
|
|
6387
|
+
*/
|
|
6184
6388
|
aiChatSse(onmessage, context, params = {}, data = {}) {
|
|
6185
6389
|
const app = ibiz.hub.getApp(this.model.appId);
|
|
6186
6390
|
const path2 = this.calcSsePath(context);
|
|
@@ -6270,14 +6474,23 @@ var DEService = class {
|
|
|
6270
6474
|
async destroy() {
|
|
6271
6475
|
this.local.clear();
|
|
6272
6476
|
}
|
|
6273
|
-
|
|
6274
|
-
|
|
6477
|
+
createMethodDto(dto, opts) {
|
|
6478
|
+
return new MethodDto(
|
|
6479
|
+
this,
|
|
6480
|
+
this.model,
|
|
6481
|
+
opts == null ? void 0 : opts.isLocalMode,
|
|
6482
|
+
dto,
|
|
6483
|
+
opts == null ? void 0 : opts.inSelfLoop
|
|
6484
|
+
);
|
|
6485
|
+
}
|
|
6486
|
+
};
|
|
6487
|
+
|
|
6275
6488
|
// src/service/service/control/control.service.ts
|
|
6276
|
-
import { clone as
|
|
6489
|
+
import { clone as clone8 } from "@ibiz-template/core";
|
|
6277
6490
|
|
|
6278
6491
|
// src/service/vo/control.vo.ts
|
|
6279
6492
|
import { createUUID as createUUID4 } from "qx-util";
|
|
6280
|
-
import { clone as
|
|
6493
|
+
import { clone as clone7, isNil as isNil8 } from "ramda";
|
|
6281
6494
|
var BuildInKeys = [
|
|
6282
6495
|
"srfkey",
|
|
6283
6496
|
"srfmajortext",
|
|
@@ -6465,7 +6678,7 @@ var ControlVO = class _ControlVO {
|
|
|
6465
6678
|
* @return {*} {ControlVO}
|
|
6466
6679
|
*/
|
|
6467
6680
|
clone() {
|
|
6468
|
-
const cloneOrigin =
|
|
6681
|
+
const cloneOrigin = clone7(this.$origin);
|
|
6469
6682
|
const newVal = new _ControlVO(cloneOrigin, this.$dataUIMap);
|
|
6470
6683
|
Object.keys(this).forEach((key) => {
|
|
6471
6684
|
newVal[key] = this[key];
|
|
@@ -6542,7 +6755,7 @@ var ControlService = class {
|
|
|
6542
6755
|
* @returns {*} {IHttpResponse}
|
|
6543
6756
|
*/
|
|
6544
6757
|
handleResponse(res) {
|
|
6545
|
-
return
|
|
6758
|
+
return clone8(res);
|
|
6546
6759
|
}
|
|
6547
6760
|
/**
|
|
6548
6761
|
* 实体数据转ui数据
|
|
@@ -6975,371 +7188,107 @@ var V7AuthService = class {
|
|
|
6975
7188
|
return true;
|
|
6976
7189
|
} catch (err) {
|
|
6977
7190
|
ibiz.notification.error({
|
|
6978
|
-
title: "\u767B\u5F55\u5931\u8D25",
|
|
6979
|
-
desc: err.message || ""
|
|
6980
|
-
});
|
|
6981
|
-
}
|
|
6982
|
-
return false;
|
|
6983
|
-
}
|
|
6984
|
-
async logout() {
|
|
6985
|
-
try {
|
|
6986
|
-
await ibiz.net.get("/v7/logout");
|
|
6987
|
-
clearCookie(CoreConst.TOKEN);
|
|
6988
|
-
clearCookie(CoreConst.TOKEN_EXPIRES);
|
|
6989
|
-
clearCookie(CoreConst.TOKEN_REMEMBER);
|
|
6990
|
-
clearCookie(CoreConst.IS_ANONYMOUS);
|
|
6991
|
-
return true;
|
|
6992
|
-
} catch (err) {
|
|
6993
|
-
ibiz.notification.error({
|
|
6994
|
-
title: "\u767B\u51FA\u5931\u8D25",
|
|
6995
|
-
desc: err.message || ""
|
|
6996
|
-
});
|
|
6997
|
-
}
|
|
6998
|
-
return false;
|
|
6999
|
-
}
|
|
7000
|
-
async extendLogin() {
|
|
7001
|
-
if (this.isAnonymous) {
|
|
7002
|
-
return;
|
|
7003
|
-
}
|
|
7004
|
-
const token = getCookie(CoreConst.TOKEN);
|
|
7005
|
-
const expirein = getCookie(CoreConst.TOKEN_EXPIRES);
|
|
7006
|
-
const remember = getCookie(CoreConst.TOKEN_REMEMBER);
|
|
7007
|
-
if (token && expirein) {
|
|
7008
|
-
let wait = Number(expirein) - (/* @__PURE__ */ new Date()).getTime();
|
|
7009
|
-
const early = 5 * 60 * 1e3;
|
|
7010
|
-
wait = wait > early ? wait - early : 0;
|
|
7011
|
-
setTimeout(async () => {
|
|
7012
|
-
const res = await ibiz.net.get("/uaa/refreshtoken2");
|
|
7013
|
-
if (res.ok) {
|
|
7014
|
-
setCookie(CoreConst.TOKEN, res.data.token, remember ? 7 : 0, true);
|
|
7015
|
-
const expiredDate = (/* @__PURE__ */ new Date()).getTime() + (res.data.expirein || 7199) * 1e3;
|
|
7016
|
-
setCookie(
|
|
7017
|
-
CoreConst.TOKEN_EXPIRES,
|
|
7018
|
-
"".concat(expiredDate),
|
|
7019
|
-
remember ? 7 : 0,
|
|
7020
|
-
true
|
|
7021
|
-
);
|
|
7022
|
-
}
|
|
7023
|
-
this.extendLogin();
|
|
7024
|
-
}, wait);
|
|
7025
|
-
}
|
|
7026
|
-
}
|
|
7027
|
-
getAuthInfo() {
|
|
7028
|
-
const token = getCookie(CoreConst.TOKEN);
|
|
7029
|
-
const isAnonymous = !!getCookie(CoreConst.IS_ANONYMOUS);
|
|
7030
|
-
return token ? {
|
|
7031
|
-
token,
|
|
7032
|
-
isAnonymous
|
|
7033
|
-
} : void 0;
|
|
7034
|
-
}
|
|
7035
|
-
};
|
|
7036
|
-
|
|
7037
|
-
// src/service/service/async-action/async-action.service.ts
|
|
7038
|
-
import { isNil as isNil9 } from "ramda";
|
|
7039
|
-
var AsyncActionService = class {
|
|
7040
|
-
/**
|
|
7041
|
-
* 获取异步操作的集合
|
|
7042
|
-
* @author lxm
|
|
7043
|
-
* @date 2023-11-15 10:55:25
|
|
7044
|
-
* @param {IParams} [params={}]
|
|
7045
|
-
* @return {*} {Promise<IHttpResponse<IPortalAsyncAction[]>>}
|
|
7046
|
-
*/
|
|
7047
|
-
async fetch(params = {}) {
|
|
7048
|
-
const res = await ibiz.net.post("/portal/asyncaction/all", params);
|
|
7049
|
-
if (isNil9(res.data)) {
|
|
7050
|
-
res.data = [];
|
|
7051
|
-
}
|
|
7052
|
-
return res;
|
|
7053
|
-
}
|
|
7054
|
-
/**
|
|
7055
|
-
* 获取单条异步操作
|
|
7056
|
-
* @author lxm
|
|
7057
|
-
* @date 2023-11-15 10:57:08
|
|
7058
|
-
* @param {string} actionID
|
|
7059
|
-
* @return {*} {Promise<IHttpResponse<IPortalAsyncAction[]>>}
|
|
7060
|
-
*/
|
|
7061
|
-
async get(actionID) {
|
|
7062
|
-
const res = await ibiz.net.get("/portal/asyncaction/".concat(actionID));
|
|
7063
|
-
return res;
|
|
7064
|
-
}
|
|
7065
|
-
};
|
|
7066
|
-
|
|
7067
|
-
// src/service/service/entity/method/de-action.ts
|
|
7068
|
-
import {
|
|
7069
|
-
HttpError as HttpError5,
|
|
7070
|
-
HttpResponse as HttpResponse3,
|
|
7071
|
-
RuntimeError as RuntimeError21,
|
|
7072
|
-
RuntimeModelError as RuntimeModelError20
|
|
7073
|
-
} from "@ibiz-template/core";
|
|
7074
|
-
import { isArray as isArray6, isNil as isNil10 } from "lodash-es";
|
|
7075
|
-
|
|
7076
|
-
// src/service/service/entity/method/method.ts
|
|
7077
|
-
import { RuntimeModelError as RuntimeModelError9 } from "@ibiz-template/core";
|
|
7078
|
-
|
|
7079
|
-
// src/service/dto/method.dto.ts
|
|
7080
|
-
import { ModelError as ModelError7 } from "@ibiz-template/core";
|
|
7081
|
-
var MethodDto = class _MethodDto {
|
|
7082
|
-
/**
|
|
7083
|
-
* Creates an instance of MethodDto.
|
|
7084
|
-
* @author lxm
|
|
7085
|
-
* @date 2024-01-04 05:39:07
|
|
7086
|
-
* @param {IAppDEService} service
|
|
7087
|
-
* @param {IAppDataEntity} entity
|
|
7088
|
-
* @param {boolean} [isLocalMode]
|
|
7089
|
-
* @param {IAppDEMethodDTO} [dto]
|
|
7090
|
-
* @param {boolean} [inSelfLoop] 是否在自关系循环中
|
|
7091
|
-
*/
|
|
7092
|
-
constructor(service, entity, isLocalMode, dto, inSelfLoop) {
|
|
7093
|
-
this.service = service;
|
|
7094
|
-
this.entity = entity;
|
|
7095
|
-
this.isLocalMode = isLocalMode;
|
|
7096
|
-
this.dto = dto;
|
|
7097
|
-
this.inSelfLoop = inSelfLoop;
|
|
7098
|
-
this.dtoMap = /* @__PURE__ */ new Map();
|
|
7099
|
-
/**
|
|
7100
|
-
* 当前 DTO 是否已经计算过关系相关逻辑
|
|
7101
|
-
*
|
|
7102
|
-
* @link this.calcRs
|
|
7103
|
-
* @author chitanda
|
|
7104
|
-
* @date 2023-12-26 16:12:18
|
|
7105
|
-
* @protected
|
|
7106
|
-
*/
|
|
7107
|
-
this.isCalcRs = false;
|
|
7108
|
-
if (dto) {
|
|
7109
|
-
this.app = ibiz.hub.getApp(entity.appId);
|
|
7110
|
-
this.fields = dto.appDEMethodDTOFields || [];
|
|
7111
|
-
} else {
|
|
7112
|
-
this.fields = [];
|
|
7113
|
-
}
|
|
7114
|
-
}
|
|
7115
|
-
/**
|
|
7116
|
-
* 查找本地 DTO 存储数据
|
|
7117
|
-
*
|
|
7118
|
-
* @author chitanda
|
|
7119
|
-
* @date 2023-12-22 14:12:19
|
|
7120
|
-
* @param {IContext} context
|
|
7121
|
-
* @param {IParams} [params]
|
|
7122
|
-
* @return {*} {IDataEntity[]}
|
|
7123
|
-
*/
|
|
7124
|
-
select(context, params) {
|
|
7125
|
-
return this.service.local.select(context, params);
|
|
7126
|
-
}
|
|
7127
|
-
/**
|
|
7128
|
-
* 转换数组成ListMap
|
|
7129
|
-
*
|
|
7130
|
-
* @param {IData[]} arr
|
|
7131
|
-
* @return {*} listMap
|
|
7132
|
-
*/
|
|
7133
|
-
convertArrayToListMap(arr) {
|
|
7134
|
-
const result = {};
|
|
7135
|
-
arr.forEach((obj, index) => {
|
|
7136
|
-
result[index + 1] = obj;
|
|
7137
|
-
});
|
|
7138
|
-
return result;
|
|
7139
|
-
}
|
|
7140
|
-
/**
|
|
7141
|
-
* 转换ListMap成数组
|
|
7142
|
-
*
|
|
7143
|
-
* @param {listMap} obj
|
|
7144
|
-
* @return {*} IData[]
|
|
7145
|
-
*/
|
|
7146
|
-
convertListMapToArray(obj) {
|
|
7147
|
-
const result = [];
|
|
7148
|
-
Object.keys(obj).forEach((key) => {
|
|
7149
|
-
const index = parseInt(key, 10);
|
|
7150
|
-
result[index - 1] = obj[index];
|
|
7151
|
-
});
|
|
7152
|
-
return result;
|
|
7153
|
-
}
|
|
7154
|
-
/**
|
|
7155
|
-
* 请求参数组合 DTO
|
|
7156
|
-
*
|
|
7157
|
-
* @author chitanda
|
|
7158
|
-
* @date 2022-10-10 23:10:33
|
|
7159
|
-
* @param {IContext} context
|
|
7160
|
-
* @param {IData} data
|
|
7161
|
-
* @return {*} {Promise<IData>}
|
|
7162
|
-
*/
|
|
7163
|
-
async get(context, data, ignore = false) {
|
|
7164
|
-
const params = {};
|
|
7165
|
-
const uiDomain = ibiz.uiDomainManager.get(context.srfsessionid);
|
|
7166
|
-
for (let i = 0; i < this.fields.length; i++) {
|
|
7167
|
-
const field = this.fields[i];
|
|
7168
|
-
const key = field.codeName.toLowerCase();
|
|
7169
|
-
switch (field.type) {
|
|
7170
|
-
case "SIMPLE":
|
|
7171
|
-
case "SIMPLES":
|
|
7172
|
-
case "DTO": {
|
|
7173
|
-
break;
|
|
7174
|
-
}
|
|
7175
|
-
case "DTOS": {
|
|
7176
|
-
if (field.listMap) {
|
|
7177
|
-
if (data[key]) {
|
|
7178
|
-
params[key] = data[key].length === 0 ? null : this.convertArrayToListMap(data[key]);
|
|
7179
|
-
}
|
|
7180
|
-
} else {
|
|
7181
|
-
if (data[key] !== void 0 && ignore === false) {
|
|
7182
|
-
break;
|
|
7183
|
-
}
|
|
7184
|
-
if (!field.refAppDataEntityId) {
|
|
7185
|
-
break;
|
|
7186
|
-
}
|
|
7187
|
-
let configs = uiDomain.getDERConfig(field.refAppDataEntityId);
|
|
7188
|
-
const index = configs.findIndex(
|
|
7189
|
-
(config) => config.majorDECodeName === this.entity.codeName
|
|
7190
|
-
);
|
|
7191
|
-
configs = configs.slice(index + 1);
|
|
7192
|
-
const dto = await this.getFieldDto(context, field);
|
|
7193
|
-
const filterParams = {};
|
|
7194
|
-
if (field.refPickupAppDEFieldId) {
|
|
7195
|
-
filterParams[field.refPickupAppDEFieldId] = data.srfkey;
|
|
7196
|
-
}
|
|
7197
|
-
configs.forEach((config) => {
|
|
7198
|
-
filterParams[config.pickupDEFName.toLowerCase()] = null;
|
|
7199
|
-
});
|
|
7200
|
-
const items = await dto.select(context, filterParams);
|
|
7201
|
-
if (items) {
|
|
7202
|
-
const arr = [];
|
|
7203
|
-
for (let j = 0; j < items.length; j++) {
|
|
7204
|
-
arr.push(await dto.get(context, items[j], true));
|
|
7205
|
-
}
|
|
7206
|
-
params[key] = arr;
|
|
7207
|
-
}
|
|
7208
|
-
}
|
|
7209
|
-
break;
|
|
7210
|
-
}
|
|
7211
|
-
default:
|
|
7212
|
-
throw new ModelError7(
|
|
7213
|
-
field,
|
|
7214
|
-
"\u672A\u652F\u6301\u7684\u5E94\u7528\u5B9E\u4F53\u65B9\u6CD5\u8F93\u5165\u5C5E\u6027\u7C7B\u578B: ".concat(field.type)
|
|
7215
|
-
);
|
|
7216
|
-
}
|
|
7217
|
-
}
|
|
7218
|
-
return { ...data, ...params };
|
|
7219
|
-
}
|
|
7220
|
-
/**
|
|
7221
|
-
* 设置本地 DTO 存储
|
|
7222
|
-
*
|
|
7223
|
-
* @author chitanda
|
|
7224
|
-
* @date 2022-10-10 23:10:50
|
|
7225
|
-
* @param {IContext} context
|
|
7226
|
-
* @param {IData[]} data
|
|
7227
|
-
* @return {*} {Promise<IDataEntity[]>}
|
|
7228
|
-
*/
|
|
7229
|
-
async sets(context, data) {
|
|
7230
|
-
if (this.isLocalMode && !this.inSelfLoop) {
|
|
7231
|
-
this.service.local.clear();
|
|
7232
|
-
}
|
|
7233
|
-
await this.calcRs(context);
|
|
7234
|
-
return Promise.all(
|
|
7235
|
-
data.map(async (datum) => {
|
|
7236
|
-
const all = this.fields.filter((field) => field.type === "DTOS").map(async (field) => {
|
|
7237
|
-
const key = field.codeName.toLowerCase();
|
|
7238
|
-
if (field.listMap && typeof datum[key] === "object") {
|
|
7239
|
-
datum[key] = this.convertListMapToArray(datum[key]);
|
|
7240
|
-
} else {
|
|
7241
|
-
if (!field.refAppDataEntityId) {
|
|
7242
|
-
return;
|
|
7243
|
-
}
|
|
7244
|
-
const dto = await this.getFieldDto(context, field);
|
|
7245
|
-
const items = datum[key];
|
|
7246
|
-
if (items) {
|
|
7247
|
-
const pKey = datum[this.entity.keyAppDEFieldId];
|
|
7248
|
-
if (field.refPickupAppDEFieldId) {
|
|
7249
|
-
items.forEach((item) => {
|
|
7250
|
-
item[field.refPickupAppDEFieldId] = pKey;
|
|
7251
|
-
});
|
|
7252
|
-
}
|
|
7253
|
-
await dto.sets(context, items);
|
|
7254
|
-
} else {
|
|
7255
|
-
await dto.sets(context, []);
|
|
7256
|
-
}
|
|
7257
|
-
}
|
|
7258
|
-
});
|
|
7259
|
-
for (let i = 0; i < all.length; i++) {
|
|
7260
|
-
await all[i];
|
|
7261
|
-
}
|
|
7262
|
-
const entityData = this.service.createEntity(datum);
|
|
7263
|
-
if (this.isLocalMode) {
|
|
7264
|
-
await this.service.local.add(context, entityData);
|
|
7265
|
-
}
|
|
7266
|
-
return entityData;
|
|
7267
|
-
})
|
|
7268
|
-
);
|
|
7191
|
+
title: "\u767B\u5F55\u5931\u8D25",
|
|
7192
|
+
desc: err.message || ""
|
|
7193
|
+
});
|
|
7194
|
+
}
|
|
7195
|
+
return false;
|
|
7269
7196
|
}
|
|
7270
|
-
|
|
7271
|
-
|
|
7272
|
-
|
|
7273
|
-
|
|
7274
|
-
|
|
7275
|
-
|
|
7276
|
-
|
|
7277
|
-
|
|
7278
|
-
|
|
7279
|
-
|
|
7280
|
-
|
|
7281
|
-
|
|
7197
|
+
async logout() {
|
|
7198
|
+
try {
|
|
7199
|
+
await ibiz.net.get("/v7/logout");
|
|
7200
|
+
clearCookie(CoreConst.TOKEN);
|
|
7201
|
+
clearCookie(CoreConst.TOKEN_EXPIRES);
|
|
7202
|
+
clearCookie(CoreConst.TOKEN_REMEMBER);
|
|
7203
|
+
clearCookie(CoreConst.IS_ANONYMOUS);
|
|
7204
|
+
return true;
|
|
7205
|
+
} catch (err) {
|
|
7206
|
+
ibiz.notification.error({
|
|
7207
|
+
title: "\u767B\u51FA\u5931\u8D25",
|
|
7208
|
+
desc: err.message || ""
|
|
7209
|
+
});
|
|
7210
|
+
}
|
|
7211
|
+
return false;
|
|
7212
|
+
}
|
|
7213
|
+
async extendLogin() {
|
|
7214
|
+
if (this.isAnonymous) {
|
|
7282
7215
|
return;
|
|
7283
7216
|
}
|
|
7284
|
-
|
|
7285
|
-
|
|
7286
|
-
const
|
|
7287
|
-
|
|
7288
|
-
|
|
7289
|
-
const
|
|
7290
|
-
|
|
7291
|
-
|
|
7292
|
-
|
|
7293
|
-
|
|
7294
|
-
|
|
7295
|
-
|
|
7296
|
-
|
|
7297
|
-
|
|
7298
|
-
|
|
7299
|
-
|
|
7300
|
-
|
|
7301
|
-
|
|
7302
|
-
|
|
7303
|
-
|
|
7304
|
-
|
|
7305
|
-
minorDECodeName2: dto.entity.codeName2,
|
|
7306
|
-
pickupDEFName: field.refPickupAppDEFieldId
|
|
7307
|
-
});
|
|
7308
|
-
await dto.calcRs(context, depth);
|
|
7309
|
-
}
|
|
7217
|
+
const token = getCookie(CoreConst.TOKEN);
|
|
7218
|
+
const expirein = getCookie(CoreConst.TOKEN_EXPIRES);
|
|
7219
|
+
const remember = getCookie(CoreConst.TOKEN_REMEMBER);
|
|
7220
|
+
if (token && expirein) {
|
|
7221
|
+
let wait = Number(expirein) - (/* @__PURE__ */ new Date()).getTime();
|
|
7222
|
+
const early = 5 * 60 * 1e3;
|
|
7223
|
+
wait = wait > early ? wait - early : 0;
|
|
7224
|
+
setTimeout(async () => {
|
|
7225
|
+
const res = await ibiz.net.get("/uaa/refreshtoken2");
|
|
7226
|
+
if (res.ok) {
|
|
7227
|
+
setCookie(CoreConst.TOKEN, res.data.token, remember ? 7 : 0, true);
|
|
7228
|
+
const expiredDate = (/* @__PURE__ */ new Date()).getTime() + (res.data.expirein || 7199) * 1e3;
|
|
7229
|
+
setCookie(
|
|
7230
|
+
CoreConst.TOKEN_EXPIRES,
|
|
7231
|
+
"".concat(expiredDate),
|
|
7232
|
+
remember ? 7 : 0,
|
|
7233
|
+
true
|
|
7234
|
+
);
|
|
7235
|
+
}
|
|
7236
|
+
this.extendLogin();
|
|
7237
|
+
}, wait);
|
|
7310
7238
|
}
|
|
7311
7239
|
}
|
|
7240
|
+
getAuthInfo() {
|
|
7241
|
+
const token = getCookie(CoreConst.TOKEN);
|
|
7242
|
+
const isAnonymous = !!getCookie(CoreConst.IS_ANONYMOUS);
|
|
7243
|
+
return token ? {
|
|
7244
|
+
token,
|
|
7245
|
+
isAnonymous
|
|
7246
|
+
} : void 0;
|
|
7247
|
+
}
|
|
7248
|
+
};
|
|
7249
|
+
|
|
7250
|
+
// src/service/service/async-action/async-action.service.ts
|
|
7251
|
+
import { isNil as isNil9 } from "ramda";
|
|
7252
|
+
var AsyncActionService = class {
|
|
7312
7253
|
/**
|
|
7313
|
-
*
|
|
7314
|
-
*
|
|
7315
|
-
* @
|
|
7316
|
-
* @
|
|
7317
|
-
* @
|
|
7318
|
-
* @param {IContext} context
|
|
7319
|
-
* @param {IAppDEMethodDTOField} field
|
|
7320
|
-
* @return {*} {Promise<MethodDto>}
|
|
7254
|
+
* 获取异步操作的集合
|
|
7255
|
+
* @author lxm
|
|
7256
|
+
* @date 2023-11-15 10:55:25
|
|
7257
|
+
* @param {IParams} [params={}]
|
|
7258
|
+
* @return {*} {Promise<IHttpResponse<IPortalAsyncAction[]>>}
|
|
7321
7259
|
*/
|
|
7322
|
-
async
|
|
7323
|
-
|
|
7324
|
-
|
|
7260
|
+
async fetch(params = {}) {
|
|
7261
|
+
const res = await ibiz.net.post("/portal/asyncaction/all", params);
|
|
7262
|
+
if (isNil9(res.data)) {
|
|
7263
|
+
res.data = [];
|
|
7325
7264
|
}
|
|
7326
|
-
|
|
7327
|
-
|
|
7328
|
-
|
|
7329
|
-
|
|
7330
|
-
|
|
7331
|
-
|
|
7332
|
-
|
|
7333
|
-
|
|
7334
|
-
|
|
7335
|
-
|
|
7336
|
-
|
|
7337
|
-
|
|
7338
|
-
this.dtoMap.set(field.codeName, dto);
|
|
7339
|
-
return dto;
|
|
7265
|
+
return res;
|
|
7266
|
+
}
|
|
7267
|
+
/**
|
|
7268
|
+
* 获取单条异步操作
|
|
7269
|
+
* @author lxm
|
|
7270
|
+
* @date 2023-11-15 10:57:08
|
|
7271
|
+
* @param {string} actionID
|
|
7272
|
+
* @return {*} {Promise<IHttpResponse<IPortalAsyncAction[]>>}
|
|
7273
|
+
*/
|
|
7274
|
+
async get(actionID) {
|
|
7275
|
+
const res = await ibiz.net.get("/portal/asyncaction/".concat(actionID));
|
|
7276
|
+
return res;
|
|
7340
7277
|
}
|
|
7341
7278
|
};
|
|
7342
7279
|
|
|
7280
|
+
// src/service/service/entity/method/de-action.ts
|
|
7281
|
+
import {
|
|
7282
|
+
HttpError as HttpError5,
|
|
7283
|
+
HttpResponse as HttpResponse3,
|
|
7284
|
+
RuntimeError as RuntimeError21,
|
|
7285
|
+
RuntimeModelError as RuntimeModelError21
|
|
7286
|
+
} from "@ibiz-template/core";
|
|
7287
|
+
import { isArray as isArray6, isNil as isNil10 } from "lodash-es";
|
|
7288
|
+
|
|
7289
|
+
// src/service/service/entity/method/method.ts
|
|
7290
|
+
import { RuntimeModelError as RuntimeModelError10 } from "@ibiz-template/core";
|
|
7291
|
+
|
|
7343
7292
|
// src/service/service/entity/method/method-input.ts
|
|
7344
7293
|
var MethodInput = class {
|
|
7345
7294
|
/**
|
|
@@ -7364,7 +7313,9 @@ var MethodInput = class {
|
|
|
7364
7313
|
input.appDEMethodDTOId
|
|
7365
7314
|
);
|
|
7366
7315
|
if (methodDto) {
|
|
7367
|
-
this.dto =
|
|
7316
|
+
this.dto = service.createMethodDto(methodDto, {
|
|
7317
|
+
isLocalMode: this.isLocalMode
|
|
7318
|
+
});
|
|
7368
7319
|
}
|
|
7369
7320
|
}
|
|
7370
7321
|
}
|
|
@@ -7410,7 +7361,9 @@ var MethodReturn = class {
|
|
|
7410
7361
|
output.appDEMethodDTOId
|
|
7411
7362
|
);
|
|
7412
7363
|
if (methodDto) {
|
|
7413
|
-
this.dto =
|
|
7364
|
+
this.dto = service.createMethodDto(methodDto, {
|
|
7365
|
+
isLocalMode: this.isLocalMode
|
|
7366
|
+
});
|
|
7414
7367
|
}
|
|
7415
7368
|
}
|
|
7416
7369
|
}
|
|
@@ -7500,17 +7453,17 @@ var Method = class {
|
|
|
7500
7453
|
break;
|
|
7501
7454
|
default:
|
|
7502
7455
|
if (requestMethod) {
|
|
7503
|
-
throw new
|
|
7456
|
+
throw new RuntimeModelError10(
|
|
7504
7457
|
this.method,
|
|
7505
7458
|
"\u672A\u652F\u6301\u7684\u8BF7\u6C42\u65B9\u5F0F: ".concat(requestMethod)
|
|
7506
7459
|
);
|
|
7507
7460
|
} else {
|
|
7508
|
-
throw new
|
|
7461
|
+
throw new RuntimeModelError10(this.method, "\u672A\u914D\u7F6E\u8BF7\u6C42\u65B9\u5F0F");
|
|
7509
7462
|
}
|
|
7510
7463
|
}
|
|
7511
7464
|
return res;
|
|
7512
7465
|
}
|
|
7513
|
-
throw new
|
|
7466
|
+
throw new RuntimeModelError10(this.method, "\u672A\u652F\u6301\u7684\u884C\u4E3A\u7C7B\u578B[".concat(actionType, "]"));
|
|
7514
7467
|
}
|
|
7515
7468
|
mergeRequestPath(path2, methodName) {
|
|
7516
7469
|
return "".concat(path2, "/").concat(methodName);
|
|
@@ -7545,10 +7498,10 @@ var Method = class {
|
|
|
7545
7498
|
// src/de-logic/index.ts
|
|
7546
7499
|
import { HttpError as HttpError4, HttpResponse as HttpResponse2, RuntimeError as RuntimeError20 } from "@ibiz-template/core";
|
|
7547
7500
|
import { isArray as isArray5 } from "lodash-es";
|
|
7548
|
-
import { clone as
|
|
7501
|
+
import { clone as clone13 } from "ramda";
|
|
7549
7502
|
|
|
7550
7503
|
// src/de-logic/de-logic.ts
|
|
7551
|
-
import { ModelError as ModelError13, RuntimeModelError as
|
|
7504
|
+
import { ModelError as ModelError13, RuntimeModelError as RuntimeModelError20 } from "@ibiz-template/core";
|
|
7552
7505
|
|
|
7553
7506
|
// src/de-logic/de-logic-context.ts
|
|
7554
7507
|
import { isArray as isArray4 } from "lodash-es";
|
|
@@ -7680,17 +7633,17 @@ var DELogicContext = class {
|
|
|
7680
7633
|
};
|
|
7681
7634
|
|
|
7682
7635
|
// src/de-logic/de-logic-node/de-action-node/de-action-node.ts
|
|
7683
|
-
import { RuntimeModelError as
|
|
7636
|
+
import { RuntimeModelError as RuntimeModelError13 } from "@ibiz-template/core";
|
|
7684
7637
|
|
|
7685
7638
|
// src/de-logic/de-logic-link/de-logic-link-group-cond/de-logic-link-group-cond.ts
|
|
7686
|
-
import { RuntimeModelError as
|
|
7639
|
+
import { RuntimeModelError as RuntimeModelError12 } from "@ibiz-template/core";
|
|
7687
7640
|
|
|
7688
7641
|
// src/de-logic/de-logic-link/de-logic-link-cond/de-logic-link-cond.ts
|
|
7689
7642
|
var DELogicLinkCond = class {
|
|
7690
7643
|
};
|
|
7691
7644
|
|
|
7692
7645
|
// src/de-logic/de-logic-link/de-logic-link-single-cond/de-logic-link-single-cond.ts
|
|
7693
|
-
import { ModelError as ModelError8, RuntimeModelError as
|
|
7646
|
+
import { ModelError as ModelError8, RuntimeModelError as RuntimeModelError11 } from "@ibiz-template/core";
|
|
7694
7647
|
var DELogicLinkSingleCond = class extends DELogicLinkCond {
|
|
7695
7648
|
constructor(model) {
|
|
7696
7649
|
super();
|
|
@@ -7737,7 +7690,7 @@ var DELogicLinkSingleCond = class extends DELogicLinkCond {
|
|
|
7737
7690
|
switch (this.type) {
|
|
7738
7691
|
case "ENTITYFIELD": {
|
|
7739
7692
|
if (!this.value) {
|
|
7740
|
-
throw new
|
|
7693
|
+
throw new RuntimeModelError11(
|
|
7741
7694
|
this.model,
|
|
7742
7695
|
"\u5F53\u524D\u6761\u4EF6\u503C\u7C7B\u578B\u4E3A[\u6570\u636E\u5BF9\u8C61\u5C5E\u6027],\u7F3A\u5C11\u914D\u7F6E\u6761\u4EF6\u503C"
|
|
7743
7696
|
);
|
|
@@ -7747,7 +7700,7 @@ var DELogicLinkSingleCond = class extends DELogicLinkCond {
|
|
|
7747
7700
|
}
|
|
7748
7701
|
case "SRCENTITYFIELD": {
|
|
7749
7702
|
if (!this.value) {
|
|
7750
|
-
throw new
|
|
7703
|
+
throw new RuntimeModelError11(
|
|
7751
7704
|
this.model,
|
|
7752
7705
|
"\u5F53\u524D\u6761\u4EF6\u503C\u7C7B\u578B\u4E3A[\u6E90\u6570\u636E\u5BF9\u8C61\u5C5E\u6027],\u7F3A\u5C11\u914D\u7F6E\u6761\u4EF6\u503C"
|
|
7753
7706
|
);
|
|
@@ -7810,7 +7763,7 @@ var DELogicLinkGroupCond = class _DELogicLinkGroupCond extends DELogicLinkCond {
|
|
|
7810
7763
|
test(ctx, context, data) {
|
|
7811
7764
|
let bol = true;
|
|
7812
7765
|
if (this.conds.length === 0) {
|
|
7813
|
-
throw new
|
|
7766
|
+
throw new RuntimeModelError12(this.model, "\u754C\u9762\u8FDE\u63A5\u6761\u4EF6\u903B\u8F91\u7EC4\u672A\u914D\u7F6E\u903B\u8F91\u9879");
|
|
7814
7767
|
}
|
|
7815
7768
|
for (let i = 0; i < this.conds.length; i++) {
|
|
7816
7769
|
const cond = this.conds[i];
|
|
@@ -7913,10 +7866,10 @@ var DEActionNode = class extends DELogicNode {
|
|
|
7913
7866
|
retDELogicParamId
|
|
7914
7867
|
} = this.model;
|
|
7915
7868
|
if (!dstAppDataEntityId) {
|
|
7916
|
-
throw new
|
|
7869
|
+
throw new RuntimeModelError13(this.model, "\u672A\u6307\u5B9A\u5E94\u7528\u5B9E\u4F53");
|
|
7917
7870
|
}
|
|
7918
7871
|
if (!dstAppDEActionId) {
|
|
7919
|
-
throw new
|
|
7872
|
+
throw new RuntimeModelError13(this.model, "\u672A\u6307\u5B9A\u5B9E\u4F53\u884C\u4E3A");
|
|
7920
7873
|
}
|
|
7921
7874
|
const requestData = ctx.params[dstDELogicParamId];
|
|
7922
7875
|
const app = ibiz.hub.getApp(ctx.context.srfappid);
|
|
@@ -7974,11 +7927,11 @@ var EndNode = class extends DELogicNode {
|
|
|
7974
7927
|
|
|
7975
7928
|
// src/de-logic/de-logic-node/prepare-param-node/prepare-param-node.ts
|
|
7976
7929
|
import { ModelError as ModelError11 } from "@ibiz-template/core";
|
|
7977
|
-
import { clone as
|
|
7930
|
+
import { clone as clone10 } from "ramda";
|
|
7978
7931
|
|
|
7979
7932
|
// src/de-logic/utils/handle-src-val.ts
|
|
7980
7933
|
import { ModelError as ModelError10 } from "@ibiz-template/core";
|
|
7981
|
-
import { clone as
|
|
7934
|
+
import { clone as clone9 } from "ramda";
|
|
7982
7935
|
function handleSrcVal(ctx, srcValParams) {
|
|
7983
7936
|
const { srcDELogicParamId, srcFieldName, srcValue } = srcValParams;
|
|
7984
7937
|
const srcValueType = srcValParams.srcValueType || "SRCDLPARAM";
|
|
@@ -8008,7 +7961,7 @@ function handleSrcVal(ctx, srcValParams) {
|
|
|
8008
7961
|
value = ctx.parameters.context;
|
|
8009
7962
|
break;
|
|
8010
7963
|
case "ENVPARAM":
|
|
8011
|
-
value =
|
|
7964
|
+
value = clone9(ibiz.env);
|
|
8012
7965
|
break;
|
|
8013
7966
|
default:
|
|
8014
7967
|
throw new ModelError10(srcValParams, "\u6682\u672A\u652F\u6301\u6E90\u503C\u7C7B\u578B".concat(srcValueType));
|
|
@@ -8079,7 +8032,7 @@ var PrepareParamNode = class extends DELogicNode {
|
|
|
8079
8032
|
copyParam(nodeParam, ctx) {
|
|
8080
8033
|
const { dstDELogicParamId } = nodeParam;
|
|
8081
8034
|
const srcVal = handleSrcVal(ctx, nodeParam);
|
|
8082
|
-
ctx.params[dstDELogicParamId] =
|
|
8035
|
+
ctx.params[dstDELogicParamId] = clone10(srcVal);
|
|
8083
8036
|
}
|
|
8084
8037
|
/**
|
|
8085
8038
|
* 绑定参数
|
|
@@ -8200,12 +8153,12 @@ var DataSetNode = class extends DELogicNode {
|
|
|
8200
8153
|
};
|
|
8201
8154
|
|
|
8202
8155
|
// src/de-logic/de-logic-node/bind-param-node/bind-param-node.ts
|
|
8203
|
-
import { RuntimeModelError as
|
|
8156
|
+
import { RuntimeModelError as RuntimeModelError14 } from "@ibiz-template/core";
|
|
8204
8157
|
var BindParamNode = class extends DELogicNode {
|
|
8205
8158
|
async exec(ctx) {
|
|
8206
8159
|
const { dstDELogicParamId, srcDELogicParamId } = this.model;
|
|
8207
8160
|
if (!dstDELogicParamId || !srcDELogicParamId) {
|
|
8208
|
-
throw new
|
|
8161
|
+
throw new RuntimeModelError14(
|
|
8209
8162
|
this.model,
|
|
8210
8163
|
"\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u8005\u6E90\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E"
|
|
8211
8164
|
);
|
|
@@ -8216,53 +8169,53 @@ var BindParamNode = class extends DELogicNode {
|
|
|
8216
8169
|
};
|
|
8217
8170
|
|
|
8218
8171
|
// src/de-logic/de-logic-node/reset-param-node/reset-param-node.ts
|
|
8219
|
-
import { RuntimeModelError as
|
|
8172
|
+
import { RuntimeModelError as RuntimeModelError15 } from "@ibiz-template/core";
|
|
8220
8173
|
var ResetParamNode = class extends DELogicNode {
|
|
8221
8174
|
async exec(ctx) {
|
|
8222
8175
|
const { dstDELogicParamId } = this.model;
|
|
8223
8176
|
if (!dstDELogicParamId) {
|
|
8224
|
-
throw new
|
|
8177
|
+
throw new RuntimeModelError15(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
|
|
8225
8178
|
}
|
|
8226
8179
|
ctx.resetParam(dstDELogicParamId);
|
|
8227
8180
|
}
|
|
8228
8181
|
};
|
|
8229
8182
|
|
|
8230
8183
|
// src/de-logic/de-logic-node/renew-param-node/renew-param-node.ts
|
|
8231
|
-
import { RuntimeModelError as
|
|
8184
|
+
import { RuntimeModelError as RuntimeModelError16 } from "@ibiz-template/core";
|
|
8232
8185
|
var RenewParamNode = class extends DELogicNode {
|
|
8233
8186
|
async exec(ctx) {
|
|
8234
8187
|
const { dstDELogicParamId } = this.model;
|
|
8235
8188
|
if (!dstDELogicParamId) {
|
|
8236
|
-
throw new
|
|
8189
|
+
throw new RuntimeModelError16(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
|
|
8237
8190
|
}
|
|
8238
8191
|
ctx.renewParam(dstDELogicParamId);
|
|
8239
8192
|
}
|
|
8240
8193
|
};
|
|
8241
8194
|
|
|
8242
8195
|
// src/de-logic/de-logic-node/copy-param-node/copy-param-node.ts
|
|
8243
|
-
import { RuntimeModelError as
|
|
8244
|
-
import { clone as
|
|
8196
|
+
import { RuntimeModelError as RuntimeModelError17 } from "@ibiz-template/core";
|
|
8197
|
+
import { clone as clone11 } from "ramda";
|
|
8245
8198
|
var CopyParamNode = class extends DELogicNode {
|
|
8246
8199
|
async exec(ctx) {
|
|
8247
8200
|
const { dstDELogicParamId, srcDELogicParamId } = this.model;
|
|
8248
8201
|
if (!dstDELogicParamId || !srcDELogicParamId) {
|
|
8249
|
-
throw new
|
|
8202
|
+
throw new RuntimeModelError17(
|
|
8250
8203
|
this.model,
|
|
8251
8204
|
"\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u8005\u6E90\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E"
|
|
8252
8205
|
);
|
|
8253
8206
|
}
|
|
8254
8207
|
const srcVal = handleSrcVal(ctx, this.model);
|
|
8255
|
-
ctx.params[dstDELogicParamId] =
|
|
8208
|
+
ctx.params[dstDELogicParamId] = clone11(srcVal);
|
|
8256
8209
|
}
|
|
8257
8210
|
};
|
|
8258
8211
|
|
|
8259
8212
|
// src/de-logic/de-logic-node/sort-param-node/sort-param-node.ts
|
|
8260
|
-
import { RuntimeModelError as
|
|
8213
|
+
import { RuntimeModelError as RuntimeModelError18 } from "@ibiz-template/core";
|
|
8261
8214
|
var SortParamNode = class extends DELogicNode {
|
|
8262
8215
|
async exec(ctx) {
|
|
8263
8216
|
const { dstDELogicParamId, dstSortDir, dstFieldName } = this.model;
|
|
8264
8217
|
if (!dstDELogicParamId || !dstFieldName) {
|
|
8265
|
-
throw new
|
|
8218
|
+
throw new RuntimeModelError18(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u76EE\u6807\u5C5E\u6027\u914D\u7F6E");
|
|
8266
8219
|
}
|
|
8267
8220
|
const key = dstFieldName.toLowerCase();
|
|
8268
8221
|
const arr = ctx.params[dstDELogicParamId];
|
|
@@ -8273,7 +8226,7 @@ var SortParamNode = class extends DELogicNode {
|
|
|
8273
8226
|
};
|
|
8274
8227
|
|
|
8275
8228
|
// src/de-logic/de-logic-node/append-param-node/append-param-node.ts
|
|
8276
|
-
import { RuntimeModelError as
|
|
8229
|
+
import { RuntimeModelError as RuntimeModelError19 } from "@ibiz-template/core";
|
|
8277
8230
|
var AppendParamNode = class extends DELogicNode {
|
|
8278
8231
|
async exec(ctx) {
|
|
8279
8232
|
const {
|
|
@@ -8284,7 +8237,7 @@ var AppendParamNode = class extends DELogicNode {
|
|
|
8284
8237
|
srcSize
|
|
8285
8238
|
} = this.model;
|
|
8286
8239
|
if (!dstDELogicParamId || !srcDELogicParamId) {
|
|
8287
|
-
throw new
|
|
8240
|
+
throw new RuntimeModelError19(
|
|
8288
8241
|
this.model,
|
|
8289
8242
|
"\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u8005\u6E90\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E"
|
|
8290
8243
|
);
|
|
@@ -8318,7 +8271,7 @@ var ThrowExceptionNode = class extends DELogicNode {
|
|
|
8318
8271
|
|
|
8319
8272
|
// src/de-logic/de-logic-param/de-logic-param.ts
|
|
8320
8273
|
import { ModelError as ModelError12 } from "@ibiz-template/core";
|
|
8321
|
-
import { clone as
|
|
8274
|
+
import { clone as clone12 } from "ramda";
|
|
8322
8275
|
var DELogicParam = class {
|
|
8323
8276
|
/**
|
|
8324
8277
|
* Creates an instance of DELogicParam.
|
|
@@ -8350,7 +8303,7 @@ var DELogicParam = class {
|
|
|
8350
8303
|
ctx.params[tag] = ctx.data[0] || {};
|
|
8351
8304
|
}
|
|
8352
8305
|
} else if (m.appGlobalParam) {
|
|
8353
|
-
ctx.params[tag] =
|
|
8306
|
+
ctx.params[tag] = clone12(ibiz.env);
|
|
8354
8307
|
} else if (m.entityListParam) {
|
|
8355
8308
|
ctx.params[tag] = [];
|
|
8356
8309
|
} else if (m.entityPageParam) {
|
|
@@ -8366,7 +8319,7 @@ var DELogicParam = class {
|
|
|
8366
8319
|
} else if (m.simpleParam) {
|
|
8367
8320
|
ctx.params[tag] = {};
|
|
8368
8321
|
} else if (m.cloneParam) {
|
|
8369
|
-
ctx.params[tag] =
|
|
8322
|
+
ctx.params[tag] = clone12(ctx.data || {});
|
|
8370
8323
|
} else if (m.envParam) {
|
|
8371
8324
|
throw new ModelError12(m, "\u672A\u652F\u6301\u7684\u903B\u8F91\u53C2\u6570\u7C7B\u578B: \u7CFB\u7EDF\u73AF\u5883\u53D8\u91CF");
|
|
8372
8325
|
} else if (m.fileListParam) {
|
|
@@ -8433,7 +8386,7 @@ var DELogic = class {
|
|
|
8433
8386
|
var _a, _b;
|
|
8434
8387
|
if (model.customCode) {
|
|
8435
8388
|
if (!model.scriptCode) {
|
|
8436
|
-
throw new
|
|
8389
|
+
throw new RuntimeModelError20(model, "\u811A\u672C\u4EE3\u7801\u6A21\u5F0F\u6CA1\u6709\u914D\u7F6E\u811A\u672C\u4EE3\u7801");
|
|
8437
8390
|
}
|
|
8438
8391
|
this.scriptFn = ScriptFactory.createScriptFn([], model.scriptCode, {
|
|
8439
8392
|
isAsync: true
|
|
@@ -8441,7 +8394,7 @@ var DELogic = class {
|
|
|
8441
8394
|
return;
|
|
8442
8395
|
}
|
|
8443
8396
|
if (!((_a = model.delogicNodes) == null ? void 0 : _a.length)) {
|
|
8444
|
-
throw new
|
|
8397
|
+
throw new RuntimeModelError20(model, "\u5B9E\u4F53\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u903B\u8F91\u8282\u70B9");
|
|
8445
8398
|
}
|
|
8446
8399
|
model.delogicNodes.forEach((node) => {
|
|
8447
8400
|
const { logicNodeType } = node;
|
|
@@ -8540,7 +8493,7 @@ var DELogic = class {
|
|
|
8540
8493
|
const start = this.nodes.get(startDELogicNodeId);
|
|
8541
8494
|
await this.deepExec(start, ctx);
|
|
8542
8495
|
} else {
|
|
8543
|
-
throw new
|
|
8496
|
+
throw new RuntimeModelError20(this.model, "\u672A\u8BBE\u7F6E\u8D77\u59CB\u8282\u70B9");
|
|
8544
8497
|
}
|
|
8545
8498
|
if (ctx.isEndNode) {
|
|
8546
8499
|
return ctx.result;
|
|
@@ -8601,9 +8554,9 @@ async function execDELogicById(deDELogicId, dataEntityId, context, data, params)
|
|
|
8601
8554
|
return execDELogic(deLogic, context, data, params);
|
|
8602
8555
|
}
|
|
8603
8556
|
async function execDELogicAction(deDELogic, context, data, params) {
|
|
8604
|
-
const _context =
|
|
8605
|
-
const _data = data ?
|
|
8606
|
-
const _params = params ?
|
|
8557
|
+
const _context = clone13(context);
|
|
8558
|
+
const _data = data ? clone13(data) : data;
|
|
8559
|
+
const _params = params ? clone13(params) : params;
|
|
8607
8560
|
try {
|
|
8608
8561
|
const result = await execDELogic(deDELogic, _context, _data, _params);
|
|
8609
8562
|
return new HttpResponse2(result);
|
|
@@ -8665,7 +8618,7 @@ var DEActionMethod = class extends Method {
|
|
|
8665
8618
|
if (this.method.actionType === "DELOGIC") {
|
|
8666
8619
|
const deLogic = findDELogic(this.method.appDELogicId, this.entity);
|
|
8667
8620
|
if (!deLogic) {
|
|
8668
|
-
throw new
|
|
8621
|
+
throw new RuntimeModelError21(this.method, "\u7F3A\u5C11\u5B9E\u4F53\u5904\u7406\u903B\u8F91");
|
|
8669
8622
|
}
|
|
8670
8623
|
return execDELogicAction(deLogic, context, data, params);
|
|
8671
8624
|
}
|
|
@@ -9001,10 +8954,11 @@ var DEActionMethod = class extends Method {
|
|
|
9001
8954
|
const configs = uiDomain.getDERConfig(this.entity.id);
|
|
9002
8955
|
if (configs.length > 0) {
|
|
9003
8956
|
configs.forEach((config) => {
|
|
9004
|
-
if (config.
|
|
9005
|
-
const {
|
|
9006
|
-
const
|
|
9007
|
-
const
|
|
8957
|
+
if (config.parentAppDEFieldId) {
|
|
8958
|
+
const { majorAppDataEntityId, parentAppDEFieldId } = config;
|
|
8959
|
+
const majorDECodeName = calcDeCodeNameById(majorAppDataEntityId);
|
|
8960
|
+
const majorLowerCodeName = majorDECodeName;
|
|
8961
|
+
const pickupLowerDEFName = parentAppDEFieldId.toLowerCase();
|
|
9008
8962
|
const majorkey = context[majorLowerCodeName];
|
|
9009
8963
|
if (majorkey && majorkey !== data.srfkey) {
|
|
9010
8964
|
data[pickupLowerDEFName] = majorkey;
|
|
@@ -9027,17 +8981,18 @@ var DeActionDeMethodProvider = class {
|
|
|
9027
8981
|
import {
|
|
9028
8982
|
HttpResponse as HttpResponse4,
|
|
9029
8983
|
ModelError as ModelError14,
|
|
9030
|
-
RuntimeModelError as
|
|
8984
|
+
RuntimeModelError as RuntimeModelError22
|
|
9031
8985
|
} from "@ibiz-template/core";
|
|
9032
8986
|
import { isArray as isArray7 } from "lodash-es";
|
|
9033
|
-
import { clone as
|
|
9034
|
-
import { ascSort
|
|
8987
|
+
import { clone as clone14, isEmpty as isEmpty7, isNil as isNil11 } from "ramda";
|
|
8988
|
+
import { ascSort, descSort } from "qx-util";
|
|
9035
8989
|
var FetchMethod = class extends Method {
|
|
9036
8990
|
async exec(context, params, params2) {
|
|
9037
8991
|
const searchParams = params && !isArray7(params) ? params : params2 || {};
|
|
9038
8992
|
if (this.isLocalMode) {
|
|
8993
|
+
const cond = DEDQCondUtil.getCond(this.method);
|
|
9039
8994
|
const items2 = await this.searchLocal(
|
|
9040
|
-
|
|
8995
|
+
cond,
|
|
9041
8996
|
new SearchFilter(context, searchParams)
|
|
9042
8997
|
);
|
|
9043
8998
|
return new HttpResponse4(items2, 200);
|
|
@@ -9085,29 +9040,25 @@ var FetchMethod = class extends Method {
|
|
|
9085
9040
|
* @return {*} {Promise<IDataEntity[]>}
|
|
9086
9041
|
*/
|
|
9087
9042
|
async searchLocal(cond, filter, queryParamKeys = this.entity.quickSearchAppDEFieldIds) {
|
|
9088
|
-
let list =
|
|
9043
|
+
let list = this.service.local.getList();
|
|
9089
9044
|
if (cond) {
|
|
9090
|
-
list = this.service.local.getList();
|
|
9091
9045
|
if (list.length > 0) {
|
|
9092
9046
|
list = list.filter((obj) => cond.test(obj, filter));
|
|
9093
9047
|
}
|
|
9094
|
-
} else {
|
|
9095
|
-
|
|
9096
|
-
|
|
9097
|
-
|
|
9098
|
-
|
|
9099
|
-
|
|
9100
|
-
const
|
|
9101
|
-
|
|
9102
|
-
|
|
9103
|
-
|
|
9104
|
-
if (reg2.test(val)) {
|
|
9105
|
-
return true;
|
|
9106
|
-
}
|
|
9048
|
+
} else if (list.length > 0) {
|
|
9049
|
+
if (filter.query && filter.query !== "") {
|
|
9050
|
+
if (queryParamKeys) {
|
|
9051
|
+
list = list.filter((obj) => {
|
|
9052
|
+
const reg2 = new RegExp(filter.query);
|
|
9053
|
+
for (let i = 0; i < queryParamKeys.length; i += 1) {
|
|
9054
|
+
const key = queryParamKeys[i];
|
|
9055
|
+
const val = obj[key];
|
|
9056
|
+
if (reg2.test(val)) {
|
|
9057
|
+
return true;
|
|
9107
9058
|
}
|
|
9108
|
-
|
|
9109
|
-
|
|
9110
|
-
}
|
|
9059
|
+
}
|
|
9060
|
+
return false;
|
|
9061
|
+
});
|
|
9111
9062
|
}
|
|
9112
9063
|
}
|
|
9113
9064
|
}
|
|
@@ -9115,13 +9066,13 @@ var FetchMethod = class extends Method {
|
|
|
9115
9066
|
if (filter.sortMode === "DESC") {
|
|
9116
9067
|
list = descSort(list, filter.sortField);
|
|
9117
9068
|
} else {
|
|
9118
|
-
list =
|
|
9069
|
+
list = ascSort(list, filter.sortField);
|
|
9119
9070
|
}
|
|
9120
9071
|
}
|
|
9121
9072
|
const { page, size } = filter;
|
|
9122
9073
|
const start = page * size;
|
|
9123
9074
|
const end = (page + 1) * size - 1;
|
|
9124
|
-
const items = list.slice(start, end).map((item) =>
|
|
9075
|
+
const items = list.slice(start, end).map((item) => clone14(item));
|
|
9125
9076
|
return items;
|
|
9126
9077
|
}
|
|
9127
9078
|
/**
|
|
@@ -9135,7 +9086,7 @@ var FetchMethod = class extends Method {
|
|
|
9135
9086
|
async fetchCodeListSet(context, params) {
|
|
9136
9087
|
const { appCodeListId } = this.method;
|
|
9137
9088
|
if (!appCodeListId) {
|
|
9138
|
-
throw new
|
|
9089
|
+
throw new RuntimeModelError22(this.method, "\u6CA1\u6709\u6307\u5B9A\u6570\u636E\u6765\u6E90\u4EE3\u7801\u8868");
|
|
9139
9090
|
}
|
|
9140
9091
|
const codeItems = await this.app.codeList.get(
|
|
9141
9092
|
appCodeListId,
|
|
@@ -10111,7 +10062,7 @@ var _OpenAppViewCommand = class _OpenAppViewCommand {
|
|
|
10111
10062
|
* @return {*} {(Promise<IModalData | void>)}
|
|
10112
10063
|
*/
|
|
10113
10064
|
async exec(appViewId, _context, params = {}, opts = {}) {
|
|
10114
|
-
const context =
|
|
10065
|
+
const context = clone15(_context);
|
|
10115
10066
|
const appView = await ibiz.hub.config.view.get(appViewId);
|
|
10116
10067
|
if (!appView) {
|
|
10117
10068
|
throw new RuntimeError23("\u5E94\u7528\u89C6\u56FE[".concat(appViewId, "]\u4E0D\u5B58\u5728"));
|
|
@@ -11842,7 +11793,7 @@ var BaseController = class {
|
|
|
11842
11793
|
};
|
|
11843
11794
|
|
|
11844
11795
|
// src/controller/utils/view-msg/view-msg-controller.ts
|
|
11845
|
-
import { RuntimeError as RuntimeError31, RuntimeModelError as
|
|
11796
|
+
import { RuntimeError as RuntimeError31, RuntimeModelError as RuntimeModelError23 } from "@ibiz-template/core";
|
|
11846
11797
|
import { isNil as isNil18, mergeRight as mergeRight2 } from "ramda";
|
|
11847
11798
|
var ViewMsgController = class _ViewMsgController {
|
|
11848
11799
|
constructor(msgGroupId) {
|
|
@@ -11907,7 +11858,7 @@ var ViewMsgController = class _ViewMsgController {
|
|
|
11907
11858
|
static async fetchDataSet(msgModel, context, params) {
|
|
11908
11859
|
const { appDataEntityId, appDEDataSetId } = msgModel;
|
|
11909
11860
|
if (!appDEDataSetId) {
|
|
11910
|
-
throw new
|
|
11861
|
+
throw new RuntimeModelError23(msgModel, "\u672A\u914D\u7F6E\u5B9E\u4F53\u6570\u636E\u96C6");
|
|
11911
11862
|
}
|
|
11912
11863
|
const res = await ibiz.hub.getApp(context.srfappid).deService.exec(appDataEntityId, appDEDataSetId, context, params);
|
|
11913
11864
|
if (res.data.length) {
|
|
@@ -12001,7 +11952,7 @@ var ViewMsgController = class _ViewMsgController {
|
|
|
12001
11952
|
msgPosAppDEFieldId
|
|
12002
11953
|
} = msgModel;
|
|
12003
11954
|
if (!appDataEntityId) {
|
|
12004
|
-
throw new
|
|
11955
|
+
throw new RuntimeModelError23(msgModel, "\u672A\u914D\u7F6E\u5E94\u7528\u5B9E\u4F53");
|
|
12005
11956
|
}
|
|
12006
11957
|
const entity = await ibiz.hub.getAppDataEntity(
|
|
12007
11958
|
appDataEntityId,
|
|
@@ -12581,7 +12532,7 @@ var EditorController = class {
|
|
|
12581
12532
|
};
|
|
12582
12533
|
|
|
12583
12534
|
// src/controller/common/editor/code-list-editor.controller.ts
|
|
12584
|
-
import { RuntimeModelError as
|
|
12535
|
+
import { RuntimeModelError as RuntimeModelError24 } from "@ibiz-template/core";
|
|
12585
12536
|
var CodeListEditorController = class extends EditorController {
|
|
12586
12537
|
/**
|
|
12587
12538
|
* 加载代码表数据
|
|
@@ -12605,7 +12556,7 @@ var CodeListEditorController = class extends EditorController {
|
|
|
12605
12556
|
);
|
|
12606
12557
|
return dataItems;
|
|
12607
12558
|
}
|
|
12608
|
-
throw new
|
|
12559
|
+
throw new RuntimeModelError24(
|
|
12609
12560
|
this.model,
|
|
12610
12561
|
"\u7F16\u8F91\u5668\u7C7B\u578B[".concat(this.model.editorType, "]\uFF0C\u672A\u914D\u7F6E\u4EE3\u7801\u8868")
|
|
12611
12562
|
);
|
|
@@ -12614,7 +12565,7 @@ var CodeListEditorController = class extends EditorController {
|
|
|
12614
12565
|
|
|
12615
12566
|
// src/controller/common/control/control.controller.ts
|
|
12616
12567
|
import { IBizContext as IBizContext3, IBizParams, NoticeError as NoticeError2 } from "@ibiz-template/core";
|
|
12617
|
-
import { clone as
|
|
12568
|
+
import { clone as clone16, isNil as isNil20 } from "ramda";
|
|
12618
12569
|
import { notNilEmpty as notNilEmpty7 } from "qx-util";
|
|
12619
12570
|
var ControlController = class extends BaseController {
|
|
12620
12571
|
/**
|
|
@@ -12656,7 +12607,7 @@ var ControlController = class extends BaseController {
|
|
|
12656
12607
|
"".concat(model.controlType, "_DEFAULT")
|
|
12657
12608
|
);
|
|
12658
12609
|
if (panelModel) {
|
|
12659
|
-
this.controlPanel =
|
|
12610
|
+
this.controlPanel = clone16(panelModel);
|
|
12660
12611
|
}
|
|
12661
12612
|
}
|
|
12662
12613
|
this.updateContextParams({});
|
|
@@ -13408,7 +13359,7 @@ var MDControlController = class extends ControlController {
|
|
|
13408
13359
|
import {
|
|
13409
13360
|
findRecursiveChild,
|
|
13410
13361
|
RuntimeError as RuntimeError34,
|
|
13411
|
-
RuntimeModelError as
|
|
13362
|
+
RuntimeModelError as RuntimeModelError25
|
|
13412
13363
|
} from "@ibiz-template/core";
|
|
13413
13364
|
var AppMenuController = class extends ControlController {
|
|
13414
13365
|
constructor(model, context, params, ctx) {
|
|
@@ -13487,7 +13438,7 @@ var AppMenuController = class extends ControlController {
|
|
|
13487
13438
|
return provider.onClick(menuItem, event, this);
|
|
13488
13439
|
}
|
|
13489
13440
|
if (!menuItem.appFuncId) {
|
|
13490
|
-
throw new
|
|
13441
|
+
throw new RuntimeModelError25(menuItem, "\u6CA1\u6709\u914D\u7F6E\u5E94\u7528\u529F\u80FD");
|
|
13491
13442
|
}
|
|
13492
13443
|
const tempContext = this.context.clone();
|
|
13493
13444
|
tempContext.srfappid = menuItem.appId;
|
|
@@ -13606,7 +13557,7 @@ var AppMenuController = class extends ControlController {
|
|
|
13606
13557
|
import {
|
|
13607
13558
|
findRecursiveChild as findRecursiveChild2,
|
|
13608
13559
|
RuntimeError as RuntimeError35,
|
|
13609
|
-
RuntimeModelError as
|
|
13560
|
+
RuntimeModelError as RuntimeModelError26
|
|
13610
13561
|
} from "@ibiz-template/core";
|
|
13611
13562
|
var AppMenuIconViewController = class extends AppMenuController {
|
|
13612
13563
|
async onClickMenuItem(id, event) {
|
|
@@ -13622,7 +13573,7 @@ var AppMenuIconViewController = class extends AppMenuController {
|
|
|
13622
13573
|
event
|
|
13623
13574
|
});
|
|
13624
13575
|
if (!menuItem.appFuncId) {
|
|
13625
|
-
throw new
|
|
13576
|
+
throw new RuntimeModelError26(menuItem, "\u6CA1\u6709\u914D\u7F6E\u5E94\u7528\u529F\u80FD");
|
|
13626
13577
|
}
|
|
13627
13578
|
const tempContext = this.context.clone();
|
|
13628
13579
|
if (this.routeDepth === 1) {
|
|
@@ -13918,17 +13869,17 @@ import { mergeDeepRight as mergeDeepRight3 } from "ramda";
|
|
|
13918
13869
|
import { RuntimeError as RuntimeError37 } from "@ibiz-template/core";
|
|
13919
13870
|
|
|
13920
13871
|
// src/controller/control/chart/generator/line-series-generator.ts
|
|
13921
|
-
import { RuntimeModelError as
|
|
13872
|
+
import { RuntimeModelError as RuntimeModelError28 } from "@ibiz-template/core";
|
|
13922
13873
|
|
|
13923
13874
|
// src/controller/control/chart/generator/base-series-generator.ts
|
|
13924
|
-
import { plus, RuntimeModelError as
|
|
13875
|
+
import { plus, RuntimeModelError as RuntimeModelError27, toNumberOrNil } from "@ibiz-template/core";
|
|
13925
13876
|
import dayjs3 from "dayjs";
|
|
13926
13877
|
import minMax from "dayjs/plugin/minMax";
|
|
13927
13878
|
import isSameOrBefore from "dayjs/plugin/isSameOrBefore";
|
|
13928
13879
|
import quarterOfYear from "dayjs/plugin/quarterOfYear";
|
|
13929
13880
|
import weekOfYear from "dayjs/plugin/weekOfYear";
|
|
13930
13881
|
import isoWeek from "dayjs/plugin/isoWeek";
|
|
13931
|
-
import { clone as
|
|
13882
|
+
import { clone as clone17, isNil as isNil21, mergeDeepRight } from "ramda";
|
|
13932
13883
|
dayjs3.extend(minMax);
|
|
13933
13884
|
dayjs3.extend(isSameOrBefore);
|
|
13934
13885
|
dayjs3.extend(quarterOfYear);
|
|
@@ -13971,10 +13922,10 @@ var BaseSeriesGenerator = class {
|
|
|
13971
13922
|
this.chartGenerator = chartGenerator;
|
|
13972
13923
|
const { chartSeriesEncode, caption, id, userParam } = model;
|
|
13973
13924
|
if (!model.catalogField) {
|
|
13974
|
-
throw new
|
|
13925
|
+
throw new RuntimeModelError27(model, "\u7F3A\u5C11\u5206\u7C7B\u5C5E\u6027\u914D\u7F6E");
|
|
13975
13926
|
}
|
|
13976
13927
|
if (!model.valueField) {
|
|
13977
|
-
throw new
|
|
13928
|
+
throw new RuntimeModelError27(model, "\u7F3A\u5C11\u503C\u5C5E\u6027\u914D\u7F6E");
|
|
13978
13929
|
}
|
|
13979
13930
|
this.catalogField = chartGenerator.getFieldKey(model.catalogField);
|
|
13980
13931
|
this.valueField = chartGenerator.getFieldKey(model.valueField);
|
|
@@ -14203,7 +14154,7 @@ var BaseSeriesGenerator = class {
|
|
|
14203
14154
|
dataPreprocess(data) {
|
|
14204
14155
|
const tempData = [];
|
|
14205
14156
|
data.forEach((singleData) => {
|
|
14206
|
-
tempData.push(
|
|
14157
|
+
tempData.push(clone17(singleData));
|
|
14207
14158
|
});
|
|
14208
14159
|
const { groupMode } = this.model;
|
|
14209
14160
|
if (groupMode) {
|
|
@@ -14397,10 +14348,10 @@ var BaseSeriesGenerator = class {
|
|
|
14397
14348
|
var LineSeriesGenerator = class extends BaseSeriesGenerator {
|
|
14398
14349
|
calcStaticOptions() {
|
|
14399
14350
|
if (this.xAxisIndex === void 0) {
|
|
14400
|
-
throw new
|
|
14351
|
+
throw new RuntimeModelError28(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EX\u5750\u6807\u8F74");
|
|
14401
14352
|
}
|
|
14402
14353
|
if (this.yAxisIndex === void 0) {
|
|
14403
|
-
throw new
|
|
14354
|
+
throw new RuntimeModelError28(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EY\u5750\u6807\u8F74");
|
|
14404
14355
|
}
|
|
14405
14356
|
const options = super.calcStaticOptions();
|
|
14406
14357
|
options.xAxisIndex = this.xAxisIndex;
|
|
@@ -14416,14 +14367,14 @@ var LineSeriesGenerator = class extends BaseSeriesGenerator {
|
|
|
14416
14367
|
};
|
|
14417
14368
|
|
|
14418
14369
|
// src/controller/control/chart/generator/bar-series-generator.ts
|
|
14419
|
-
import { RuntimeModelError as
|
|
14370
|
+
import { RuntimeModelError as RuntimeModelError29 } from "@ibiz-template/core";
|
|
14420
14371
|
var BarSeriesGenerator = class extends BaseSeriesGenerator {
|
|
14421
14372
|
calcStaticOptions() {
|
|
14422
14373
|
if (this.xAxisIndex === void 0) {
|
|
14423
|
-
throw new
|
|
14374
|
+
throw new RuntimeModelError29(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EX\u5750\u6807\u8F74");
|
|
14424
14375
|
}
|
|
14425
14376
|
if (this.yAxisIndex === void 0) {
|
|
14426
|
-
throw new
|
|
14377
|
+
throw new RuntimeModelError29(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EY\u5750\u6807\u8F74");
|
|
14427
14378
|
}
|
|
14428
14379
|
const options = super.calcStaticOptions();
|
|
14429
14380
|
options.xAxisIndex = this.xAxisIndex;
|
|
@@ -14476,14 +14427,14 @@ var PieSeriesGenerator = class extends BaseSeriesGenerator {
|
|
|
14476
14427
|
};
|
|
14477
14428
|
|
|
14478
14429
|
// src/controller/control/chart/generator/scatter-series-generator.ts
|
|
14479
|
-
import { RuntimeModelError as
|
|
14430
|
+
import { RuntimeModelError as RuntimeModelError30 } from "@ibiz-template/core";
|
|
14480
14431
|
var ScatterSeriesGenerator = class extends BaseSeriesGenerator {
|
|
14481
14432
|
calcStaticOptions() {
|
|
14482
14433
|
if (this.xAxisIndex === void 0) {
|
|
14483
|
-
throw new
|
|
14434
|
+
throw new RuntimeModelError30(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EX\u5750\u6807\u8F74");
|
|
14484
14435
|
}
|
|
14485
14436
|
if (this.yAxisIndex === void 0) {
|
|
14486
|
-
throw new
|
|
14437
|
+
throw new RuntimeModelError30(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EY\u5750\u6807\u8F74");
|
|
14487
14438
|
}
|
|
14488
14439
|
const options = super.calcStaticOptions();
|
|
14489
14440
|
options.xAxisIndex = this.xAxisIndex;
|
|
@@ -15081,17 +15032,17 @@ var CaptionBarController = class extends ControlController {
|
|
|
15081
15032
|
import { recursiveIterate as recursiveIterate2, RuntimeError as RuntimeError47 } from "@ibiz-template/core";
|
|
15082
15033
|
|
|
15083
15034
|
// src/ui-action/provider/backend-ui-action-provider.ts
|
|
15084
|
-
import { RuntimeModelError as
|
|
15035
|
+
import { RuntimeModelError as RuntimeModelError49 } from "@ibiz-template/core";
|
|
15085
15036
|
import { isArray as isArray8 } from "qx-util";
|
|
15086
15037
|
|
|
15087
15038
|
// src/ui-action/provider/ui-action-provider-base.ts
|
|
15088
|
-
import { RuntimeModelError as
|
|
15039
|
+
import { RuntimeModelError as RuntimeModelError48 } from "@ibiz-template/core";
|
|
15089
15040
|
|
|
15090
15041
|
// src/ui-logic/index.ts
|
|
15091
15042
|
import { RuntimeError as RuntimeError44 } from "@ibiz-template/core";
|
|
15092
15043
|
|
|
15093
15044
|
// src/ui-logic/ui-logic.ts
|
|
15094
|
-
import { ModelError as ModelError25, RuntimeModelError as
|
|
15045
|
+
import { ModelError as ModelError25, RuntimeModelError as RuntimeModelError47 } from "@ibiz-template/core";
|
|
15095
15046
|
|
|
15096
15047
|
// src/ui-logic/ui-logic-context.ts
|
|
15097
15048
|
var UILogicContext = class {
|
|
@@ -15237,24 +15188,24 @@ var UILogicContext = class {
|
|
|
15237
15188
|
};
|
|
15238
15189
|
|
|
15239
15190
|
// src/ui-logic/ui-logic-node/de-action-node/de-action-node.ts
|
|
15240
|
-
import { RuntimeModelError as
|
|
15191
|
+
import { RuntimeModelError as RuntimeModelError33 } from "@ibiz-template/core";
|
|
15241
15192
|
|
|
15242
15193
|
// src/ui-logic/ui-logic-link/ui-logic-link.ts
|
|
15243
15194
|
import { ModelError as ModelError20 } from "@ibiz-template/core";
|
|
15244
15195
|
|
|
15245
15196
|
// src/ui-logic/ui-logic-link/ui-logic-link-group-cond/ui-logic-link-group-cond.ts
|
|
15246
|
-
import { RuntimeModelError as
|
|
15197
|
+
import { RuntimeModelError as RuntimeModelError32 } from "@ibiz-template/core";
|
|
15247
15198
|
|
|
15248
15199
|
// src/ui-logic/ui-logic-link/ui-logic-link-cond/ui-logic-link-cond.ts
|
|
15249
15200
|
var UILogicLinkCond = class {
|
|
15250
15201
|
};
|
|
15251
15202
|
|
|
15252
15203
|
// src/ui-logic/ui-logic-link/ui-logic-link-single-cond/ui-logic-link-single-cond.ts
|
|
15253
|
-
import { ModelError as ModelError19, RuntimeModelError as
|
|
15204
|
+
import { ModelError as ModelError19, RuntimeModelError as RuntimeModelError31 } from "@ibiz-template/core";
|
|
15254
15205
|
|
|
15255
15206
|
// src/ui-logic/utils/handle-src-val.ts
|
|
15256
15207
|
import { ModelError as ModelError18 } from "@ibiz-template/core";
|
|
15257
|
-
import { clone as
|
|
15208
|
+
import { clone as clone18 } from "ramda";
|
|
15258
15209
|
function handleSrcVal2(ctx, srcValParams) {
|
|
15259
15210
|
const { srcDEUILogicParamId, srcFieldName, srcValue } = srcValParams;
|
|
15260
15211
|
const srcValueType = srcValParams.srcValueType || "SRCDLPARAM";
|
|
@@ -15281,7 +15232,7 @@ function handleSrcVal2(ctx, srcValParams) {
|
|
|
15281
15232
|
value = ctx.parameters.context;
|
|
15282
15233
|
break;
|
|
15283
15234
|
case "ENVPARAM":
|
|
15284
|
-
value =
|
|
15235
|
+
value = clone18(ibiz.env);
|
|
15285
15236
|
break;
|
|
15286
15237
|
default:
|
|
15287
15238
|
throw new ModelError18(srcValParams, "\u6682\u672A\u652F\u6301\u6E90\u503C\u7C7B\u578B".concat(srcValueType));
|
|
@@ -15346,7 +15297,7 @@ var UILogicLinkSingleCond = class extends UILogicLinkCond {
|
|
|
15346
15297
|
switch (this.type) {
|
|
15347
15298
|
case "ENTITYFIELD": {
|
|
15348
15299
|
if (!this.value) {
|
|
15349
|
-
throw new
|
|
15300
|
+
throw new RuntimeModelError31(
|
|
15350
15301
|
this.model,
|
|
15351
15302
|
"\u5F53\u524D\u6761\u4EF6\u503C\u7C7B\u578B\u4E3A[\u6570\u636E\u5BF9\u8C61\u5C5E\u6027],\u7F3A\u5C11\u914D\u7F6E\u6761\u4EF6\u503C"
|
|
15352
15303
|
);
|
|
@@ -15356,7 +15307,7 @@ var UILogicLinkSingleCond = class extends UILogicLinkCond {
|
|
|
15356
15307
|
}
|
|
15357
15308
|
case "SRCENTITYFIELD": {
|
|
15358
15309
|
if (!this.value) {
|
|
15359
|
-
throw new
|
|
15310
|
+
throw new RuntimeModelError31(
|
|
15360
15311
|
this.model,
|
|
15361
15312
|
"\u5F53\u524D\u6761\u4EF6\u503C\u7C7B\u578B\u4E3A[\u6E90\u6570\u636E\u5BF9\u8C61\u5C5E\u6027],\u7F3A\u5C11\u914D\u7F6E\u6761\u4EF6\u503C"
|
|
15362
15313
|
);
|
|
@@ -15422,7 +15373,7 @@ var UILogicLinkGroupCond = class _UILogicLinkGroupCond extends UILogicLinkCond {
|
|
|
15422
15373
|
test(ctx, context, data) {
|
|
15423
15374
|
let bol = true;
|
|
15424
15375
|
if (this.conds.length === 0) {
|
|
15425
|
-
throw new
|
|
15376
|
+
throw new RuntimeModelError32(this.model, "\u754C\u9762\u8FDE\u63A5\u6761\u4EF6\u903B\u8F91\u7EC4\u672A\u914D\u7F6E\u903B\u8F91\u9879");
|
|
15426
15377
|
}
|
|
15427
15378
|
for (let i = 0; i < this.conds.length; i++) {
|
|
15428
15379
|
const cond = this.conds[i];
|
|
@@ -15548,10 +15499,10 @@ var DEActionNode2 = class extends UILogicNode {
|
|
|
15548
15499
|
retDEUILogicParamId
|
|
15549
15500
|
} = this.model;
|
|
15550
15501
|
if (!dstAppDataEntityId) {
|
|
15551
|
-
throw new
|
|
15502
|
+
throw new RuntimeModelError33(this.model, "\u672A\u6307\u5B9A\u5E94\u7528\u5B9E\u4F53");
|
|
15552
15503
|
}
|
|
15553
15504
|
if (!dstAppDEActionId) {
|
|
15554
|
-
throw new
|
|
15505
|
+
throw new RuntimeModelError33(this.model, "\u672A\u6307\u5B9A\u5B9E\u4F53\u884C\u4E3A");
|
|
15555
15506
|
}
|
|
15556
15507
|
const requestData = ctx.params[dstDEUILogicParamId];
|
|
15557
15508
|
const app = ibiz.hub.getApp(ctx.context.srfappid);
|
|
@@ -15569,13 +15520,13 @@ var DEActionNode2 = class extends UILogicNode {
|
|
|
15569
15520
|
};
|
|
15570
15521
|
|
|
15571
15522
|
// src/ui-logic/ui-logic-node/de-ui-action-node/de-ui-action-node.ts
|
|
15572
|
-
import { RuntimeModelError as
|
|
15523
|
+
import { RuntimeModelError as RuntimeModelError34 } from "@ibiz-template/core";
|
|
15573
15524
|
var DEUIActionNode = class extends UILogicNode {
|
|
15574
15525
|
async exec(ctx) {
|
|
15575
15526
|
const { dstAppDEUIActionId, dstDEUILogicParamId } = this.model;
|
|
15576
15527
|
const { data, parameters } = ctx;
|
|
15577
15528
|
if (!dstAppDEUIActionId) {
|
|
15578
|
-
throw new
|
|
15529
|
+
throw new RuntimeModelError34(this.model, "\u672A\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
|
|
15579
15530
|
}
|
|
15580
15531
|
let actionData = [data];
|
|
15581
15532
|
if (dstDEUILogicParamId) {
|
|
@@ -15640,7 +15591,7 @@ var EndNode2 = class extends UILogicNode {
|
|
|
15640
15591
|
|
|
15641
15592
|
// src/ui-logic/ui-logic-node/prepare-js-param-node/prepare-js-param-node.ts
|
|
15642
15593
|
import { ModelError as ModelError22, RuntimeError as RuntimeError39 } from "@ibiz-template/core";
|
|
15643
|
-
import { clone as
|
|
15594
|
+
import { clone as clone19 } from "ramda";
|
|
15644
15595
|
var PrepareJSParamNode = class extends UILogicNode {
|
|
15645
15596
|
async exec(ctx) {
|
|
15646
15597
|
const nodeParams = this.model.deuilogicNodeParams;
|
|
@@ -15729,7 +15680,7 @@ var PrepareJSParamNode = class extends UILogicNode {
|
|
|
15729
15680
|
copyParam(nodeParam, ctx) {
|
|
15730
15681
|
const { dstDEUILogicParamId } = nodeParam;
|
|
15731
15682
|
const srcVal = handleSrcVal2(ctx, nodeParam);
|
|
15732
|
-
ctx.params[dstDEUILogicParamId] =
|
|
15683
|
+
ctx.params[dstDEUILogicParamId] = clone19(srcVal);
|
|
15733
15684
|
}
|
|
15734
15685
|
/**
|
|
15735
15686
|
* 绑定参数
|
|
@@ -15806,20 +15757,20 @@ var PrepareJSParamNode = class extends UILogicNode {
|
|
|
15806
15757
|
};
|
|
15807
15758
|
|
|
15808
15759
|
// src/ui-logic/ui-logic-node/view-ctrl-invoke-node/view-ctrl-invoke-node.ts
|
|
15809
|
-
import { RuntimeError as RuntimeError40, RuntimeModelError as
|
|
15760
|
+
import { RuntimeError as RuntimeError40, RuntimeModelError as RuntimeModelError35 } from "@ibiz-template/core";
|
|
15810
15761
|
import { isFunction } from "lodash-es";
|
|
15811
15762
|
var ViewCtrlInvokeNode = class extends UILogicNode {
|
|
15812
15763
|
async exec(ctx) {
|
|
15813
15764
|
ctx.isEndNode = true;
|
|
15814
15765
|
const { invokeMethod, invokeCtrlId, invokeParamId } = this.model;
|
|
15815
15766
|
if (!invokeCtrlId) {
|
|
15816
|
-
throw new
|
|
15767
|
+
throw new RuntimeModelError35(this.model, "\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u5BF9\u8C61");
|
|
15817
15768
|
}
|
|
15818
15769
|
if (!invokeParamId) {
|
|
15819
|
-
throw new
|
|
15770
|
+
throw new RuntimeModelError35(this.model, "\u6CA1\u6709\u914D\u7F6E\u64CD\u4F5C\u53C2\u6570");
|
|
15820
15771
|
}
|
|
15821
15772
|
if (!invokeMethod) {
|
|
15822
|
-
throw new
|
|
15773
|
+
throw new RuntimeModelError35(this.model, "\u6CA1\u6709\u914D\u7F6E\u8C03\u7528\u65B9\u6CD5");
|
|
15823
15774
|
}
|
|
15824
15775
|
const invokeParam = ctx.params[invokeParamId];
|
|
15825
15776
|
if (!invokeParam) {
|
|
@@ -15837,12 +15788,12 @@ var ViewCtrlInvokeNode = class extends UILogicNode {
|
|
|
15837
15788
|
};
|
|
15838
15789
|
|
|
15839
15790
|
// src/ui-logic/ui-logic-node/bind-param-node/bind-param-node.ts
|
|
15840
|
-
import { RuntimeModelError as
|
|
15791
|
+
import { RuntimeModelError as RuntimeModelError36 } from "@ibiz-template/core";
|
|
15841
15792
|
var BindParamNode2 = class extends UILogicNode {
|
|
15842
15793
|
async exec(ctx) {
|
|
15843
15794
|
const { dstDEUILogicParamId, srcDEUILogicParamId } = this.model;
|
|
15844
15795
|
if (!dstDEUILogicParamId || !srcDEUILogicParamId) {
|
|
15845
|
-
throw new
|
|
15796
|
+
throw new RuntimeModelError36(
|
|
15846
15797
|
this.model,
|
|
15847
15798
|
"\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u8005\u6E90\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E"
|
|
15848
15799
|
);
|
|
@@ -15853,7 +15804,7 @@ var BindParamNode2 = class extends UILogicNode {
|
|
|
15853
15804
|
};
|
|
15854
15805
|
|
|
15855
15806
|
// src/ui-logic/ui-logic-node/msg-box-node/msg-box-node.ts
|
|
15856
|
-
import { ModelError as ModelError23, RuntimeModelError as
|
|
15807
|
+
import { ModelError as ModelError23, RuntimeModelError as RuntimeModelError37 } from "@ibiz-template/core";
|
|
15857
15808
|
var MsgBoxNode = class extends UILogicNode {
|
|
15858
15809
|
constructor() {
|
|
15859
15810
|
super(...arguments);
|
|
@@ -15867,10 +15818,10 @@ var MsgBoxNode = class extends UILogicNode {
|
|
|
15867
15818
|
async exec(ctx) {
|
|
15868
15819
|
const { msgBoxType, buttonsType, msgBoxParamId } = this.model;
|
|
15869
15820
|
if (!msgBoxType) {
|
|
15870
|
-
throw new
|
|
15821
|
+
throw new RuntimeModelError37(this.model, "\u7F3A\u5C11\u6D88\u606F\u7C7B\u578B\u7684\u914D\u7F6E");
|
|
15871
15822
|
}
|
|
15872
15823
|
if (!buttonsType) {
|
|
15873
|
-
throw new
|
|
15824
|
+
throw new RuntimeModelError37(this.model, "\u7F3A\u5C11\u6309\u94AE\u7C7B\u578B\u7684\u914D\u7F6E");
|
|
15874
15825
|
}
|
|
15875
15826
|
let { title } = this.model;
|
|
15876
15827
|
let { message } = this.model;
|
|
@@ -15930,12 +15881,12 @@ var PFPluginNode = class extends UILogicNode {
|
|
|
15930
15881
|
};
|
|
15931
15882
|
|
|
15932
15883
|
// src/ui-logic/ui-logic-node/debug-param-node/debug-param-node.ts
|
|
15933
|
-
import { RuntimeModelError as
|
|
15884
|
+
import { RuntimeModelError as RuntimeModelError38 } from "@ibiz-template/core";
|
|
15934
15885
|
var DebugParamNode = class extends UILogicNode {
|
|
15935
15886
|
async exec(ctx) {
|
|
15936
15887
|
const { dstDEUILogicParamId, name } = this.model;
|
|
15937
15888
|
if (!dstDEUILogicParamId) {
|
|
15938
|
-
throw new
|
|
15889
|
+
throw new RuntimeModelError38(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
|
|
15939
15890
|
}
|
|
15940
15891
|
const param = ctx.params[dstDEUILogicParamId];
|
|
15941
15892
|
console.log("\u903B\u8F91\u8282\u70B9".concat(name, "\u64CD\u4F5C\u53C2\u6570\u503C:"), param);
|
|
@@ -15943,36 +15894,36 @@ var DebugParamNode = class extends UILogicNode {
|
|
|
15943
15894
|
};
|
|
15944
15895
|
|
|
15945
15896
|
// src/ui-logic/ui-logic-node/reset-param-node/reset-param-node.ts
|
|
15946
|
-
import { RuntimeModelError as
|
|
15897
|
+
import { RuntimeModelError as RuntimeModelError39 } from "@ibiz-template/core";
|
|
15947
15898
|
var ResetParamNode2 = class extends UILogicNode {
|
|
15948
15899
|
async exec(ctx) {
|
|
15949
15900
|
const { dstDEUILogicParamId } = this.model;
|
|
15950
15901
|
if (!dstDEUILogicParamId) {
|
|
15951
|
-
throw new
|
|
15902
|
+
throw new RuntimeModelError39(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
|
|
15952
15903
|
}
|
|
15953
15904
|
ctx.resetParam(dstDEUILogicParamId);
|
|
15954
15905
|
}
|
|
15955
15906
|
};
|
|
15956
15907
|
|
|
15957
15908
|
// src/ui-logic/ui-logic-node/copy-param-node/copy-param-node.ts
|
|
15958
|
-
import { RuntimeModelError as
|
|
15959
|
-
import { clone as
|
|
15909
|
+
import { RuntimeModelError as RuntimeModelError40 } from "@ibiz-template/core";
|
|
15910
|
+
import { clone as clone20 } from "ramda";
|
|
15960
15911
|
var CopyParamNode2 = class extends UILogicNode {
|
|
15961
15912
|
async exec(ctx) {
|
|
15962
15913
|
const { dstDEUILogicParamId, srcDEUILogicParamId } = this.model;
|
|
15963
15914
|
if (!dstDEUILogicParamId || !srcDEUILogicParamId) {
|
|
15964
|
-
throw new
|
|
15915
|
+
throw new RuntimeModelError40(
|
|
15965
15916
|
this.model,
|
|
15966
15917
|
"\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u8005\u6E90\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E"
|
|
15967
15918
|
);
|
|
15968
15919
|
}
|
|
15969
15920
|
const srcVal = handleSrcVal2(ctx, this.model);
|
|
15970
|
-
ctx.params[dstDEUILogicParamId] =
|
|
15921
|
+
ctx.params[dstDEUILogicParamId] = clone20(srcVal);
|
|
15971
15922
|
}
|
|
15972
15923
|
};
|
|
15973
15924
|
|
|
15974
15925
|
// src/ui-logic/ui-logic-node/append-param-node/append-param-node.ts
|
|
15975
|
-
import { RuntimeModelError as
|
|
15926
|
+
import { RuntimeModelError as RuntimeModelError41 } from "@ibiz-template/core";
|
|
15976
15927
|
var AppendParamNode2 = class extends UILogicNode {
|
|
15977
15928
|
async exec(ctx) {
|
|
15978
15929
|
const {
|
|
@@ -15983,7 +15934,7 @@ var AppendParamNode2 = class extends UILogicNode {
|
|
|
15983
15934
|
srcSize
|
|
15984
15935
|
} = this.model;
|
|
15985
15936
|
if (!dstDEUILogicParamId || !srcDEUILogicParamId) {
|
|
15986
|
-
throw new
|
|
15937
|
+
throw new RuntimeModelError41(
|
|
15987
15938
|
this.model,
|
|
15988
15939
|
"\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u8005\u6E90\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E"
|
|
15989
15940
|
);
|
|
@@ -16001,12 +15952,12 @@ var AppendParamNode2 = class extends UILogicNode {
|
|
|
16001
15952
|
};
|
|
16002
15953
|
|
|
16003
15954
|
// src/ui-logic/ui-logic-node/sort-param-node/sort-param-node.ts
|
|
16004
|
-
import { RuntimeModelError as
|
|
15955
|
+
import { RuntimeModelError as RuntimeModelError42 } from "@ibiz-template/core";
|
|
16005
15956
|
var SortParamNode2 = class extends UILogicNode {
|
|
16006
15957
|
async exec(ctx) {
|
|
16007
15958
|
const { dstDEUILogicParamId, dstSortDir, dstFieldName } = this.model;
|
|
16008
15959
|
if (!dstDEUILogicParamId || !dstFieldName) {
|
|
16009
|
-
throw new
|
|
15960
|
+
throw new RuntimeModelError42(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u76EE\u6807\u5C5E\u6027\u914D\u7F6E");
|
|
16010
15961
|
}
|
|
16011
15962
|
const key = dstFieldName;
|
|
16012
15963
|
const arr = ctx.params[dstDEUILogicParamId];
|
|
@@ -16017,19 +15968,19 @@ var SortParamNode2 = class extends UILogicNode {
|
|
|
16017
15968
|
};
|
|
16018
15969
|
|
|
16019
15970
|
// src/ui-logic/ui-logic-node/renew-param-node/renew-param-node.ts
|
|
16020
|
-
import { RuntimeModelError as
|
|
15971
|
+
import { RuntimeModelError as RuntimeModelError43 } from "@ibiz-template/core";
|
|
16021
15972
|
var RenewParamNode2 = class extends UILogicNode {
|
|
16022
15973
|
async exec(ctx) {
|
|
16023
15974
|
const { dstDEUILogicParamId } = this.model;
|
|
16024
15975
|
if (!dstDEUILogicParamId) {
|
|
16025
|
-
throw new
|
|
15976
|
+
throw new RuntimeModelError43(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
|
|
16026
15977
|
}
|
|
16027
15978
|
ctx.renewParam(dstDEUILogicParamId);
|
|
16028
15979
|
}
|
|
16029
15980
|
};
|
|
16030
15981
|
|
|
16031
15982
|
// src/ui-logic/ui-logic-node/data-set-node/data-set-node.ts
|
|
16032
|
-
import { RuntimeModelError as
|
|
15983
|
+
import { RuntimeModelError as RuntimeModelError44 } from "@ibiz-template/core";
|
|
16033
15984
|
var DataSetNode2 = class extends UILogicNode {
|
|
16034
15985
|
async exec(ctx) {
|
|
16035
15986
|
const {
|
|
@@ -16039,7 +15990,7 @@ var DataSetNode2 = class extends UILogicNode {
|
|
|
16039
15990
|
retDEUILogicParamId
|
|
16040
15991
|
} = this.model;
|
|
16041
15992
|
if (!dstDEUILogicParamId) {
|
|
16042
|
-
throw new
|
|
15993
|
+
throw new RuntimeModelError44(this.model, "\u7F3A\u5C11\u914D\u7F6E\u8FC7\u6EE4\u53C2\u6570");
|
|
16043
15994
|
}
|
|
16044
15995
|
const queryParams = ctx.params[dstDEUILogicParamId];
|
|
16045
15996
|
const app = ibiz.hub.getApp(ctx.context.srfappid);
|
|
@@ -16065,19 +16016,19 @@ var ThrowExceptionNode2 = class extends UILogicNode {
|
|
|
16065
16016
|
};
|
|
16066
16017
|
|
|
16067
16018
|
// src/ui-logic/ui-logic-node/view-ctrl-fire-event-node/view-ctrl-fire-event-node.ts
|
|
16068
|
-
import { RuntimeError as RuntimeError42, RuntimeModelError as
|
|
16019
|
+
import { RuntimeError as RuntimeError42, RuntimeModelError as RuntimeModelError45 } from "@ibiz-template/core";
|
|
16069
16020
|
var ViewCtrlFireEventNode = class extends UILogicNode {
|
|
16070
16021
|
async exec(ctx) {
|
|
16071
16022
|
ctx.isEndNode = true;
|
|
16072
16023
|
const { eventName, eventParamId, fireCtrlId } = this.model;
|
|
16073
16024
|
if (!fireCtrlId) {
|
|
16074
|
-
throw new
|
|
16025
|
+
throw new RuntimeModelError45(this.model, "\u6CA1\u6709\u914D\u7F6E\u89E6\u53D1\u5BF9\u8C61");
|
|
16075
16026
|
}
|
|
16076
16027
|
if (!eventName) {
|
|
16077
|
-
throw new
|
|
16028
|
+
throw new RuntimeModelError45(this.model, "\u6CA1\u6709\u914D\u7F6E\u4E8B\u4EF6\u540D\u79F0\u53C2\u6570");
|
|
16078
16029
|
}
|
|
16079
16030
|
if (!eventParamId) {
|
|
16080
|
-
throw new
|
|
16031
|
+
throw new RuntimeModelError45(this.model, "\u6CA1\u6709\u914D\u7F6E\u4E8B\u4EF6\u53C2\u6570");
|
|
16081
16032
|
}
|
|
16082
16033
|
const invokeCtrl = ctx.params[fireCtrlId];
|
|
16083
16034
|
if (!invokeCtrl) {
|
|
@@ -16092,7 +16043,7 @@ var ViewCtrlFireEventNode = class extends UILogicNode {
|
|
|
16092
16043
|
};
|
|
16093
16044
|
|
|
16094
16045
|
// src/ui-logic/ui-logic-node/execute-de-logic-node/execute-de-logic-node.ts
|
|
16095
|
-
import { RuntimeError as RuntimeError43, RuntimeModelError as
|
|
16046
|
+
import { RuntimeError as RuntimeError43, RuntimeModelError as RuntimeModelError46 } from "@ibiz-template/core";
|
|
16096
16047
|
var ExecuteDELogicNode = class extends UILogicNode {
|
|
16097
16048
|
async exec(ctx) {
|
|
16098
16049
|
const {
|
|
@@ -16102,13 +16053,13 @@ var ExecuteDELogicNode = class extends UILogicNode {
|
|
|
16102
16053
|
retDEUILogicParamId
|
|
16103
16054
|
} = this.model;
|
|
16104
16055
|
if (!dstAppDataEntityId) {
|
|
16105
|
-
throw new
|
|
16056
|
+
throw new RuntimeModelError46(this.model, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53");
|
|
16106
16057
|
}
|
|
16107
16058
|
if (!dstAppDELogicId) {
|
|
16108
|
-
throw new
|
|
16059
|
+
throw new RuntimeModelError46(this.model, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u903B\u8F91");
|
|
16109
16060
|
}
|
|
16110
16061
|
if (!dstDEUILogicParamId) {
|
|
16111
|
-
throw new
|
|
16062
|
+
throw new RuntimeModelError46(this.model, "\u6CA1\u6709\u914D\u7F6E\u4F20\u5165\u903B\u8F91\u53C2\u6570");
|
|
16112
16063
|
}
|
|
16113
16064
|
const dstParam = ctx.params[dstDEUILogicParamId];
|
|
16114
16065
|
if (!dstParam) {
|
|
@@ -16270,7 +16221,7 @@ var UILogic = class {
|
|
|
16270
16221
|
this.params = /* @__PURE__ */ new Map();
|
|
16271
16222
|
var _a;
|
|
16272
16223
|
if (!((_a = model.deuilogicNodes) == null ? void 0 : _a.length)) {
|
|
16273
|
-
throw new
|
|
16224
|
+
throw new RuntimeModelError47(model, "\u754C\u9762\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u903B\u8F91\u8282\u70B9");
|
|
16274
16225
|
}
|
|
16275
16226
|
model.deuilogicNodes.forEach((node) => {
|
|
16276
16227
|
const { logicNodeType } = node;
|
|
@@ -16390,7 +16341,7 @@ var UILogic = class {
|
|
|
16390
16341
|
const start = this.nodes.get(startDEUILogicNodeId);
|
|
16391
16342
|
await this.deepExec(start, ctx);
|
|
16392
16343
|
} else {
|
|
16393
|
-
throw new
|
|
16344
|
+
throw new RuntimeModelError47(this.model, "\u672A\u8BBE\u7F6E\u8D77\u59CB\u8282\u70B9");
|
|
16394
16345
|
}
|
|
16395
16346
|
if (ctx.isEndNode) {
|
|
16396
16347
|
return ctx.result;
|
|
@@ -16525,7 +16476,7 @@ var UIActionProviderBase = class {
|
|
|
16525
16476
|
const { appDEUILogicId, appDataEntityId, uilogicAttachMode } = action;
|
|
16526
16477
|
if (uilogicAttachMode === "REPLACE") {
|
|
16527
16478
|
if (!appDEUILogicId) {
|
|
16528
|
-
throw new
|
|
16479
|
+
throw new RuntimeModelError48(action, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u754C\u9762\u903B\u8F91");
|
|
16529
16480
|
}
|
|
16530
16481
|
await execUILogic(appDEUILogicId, appDataEntityId, args);
|
|
16531
16482
|
return result;
|
|
@@ -16540,7 +16491,7 @@ var UIActionProviderBase = class {
|
|
|
16540
16491
|
}
|
|
16541
16492
|
if (action.uilogicAttachMode === "AFTER") {
|
|
16542
16493
|
if (!appDEUILogicId) {
|
|
16543
|
-
throw new
|
|
16494
|
+
throw new RuntimeModelError48(action, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u754C\u9762\u903B\u8F91");
|
|
16544
16495
|
}
|
|
16545
16496
|
await execUILogic(
|
|
16546
16497
|
appDEUILogicId,
|
|
@@ -16765,7 +16716,7 @@ var BackendUIActionProvider = class extends UIActionProviderBase {
|
|
|
16765
16716
|
const entityName = action.appDataEntityId;
|
|
16766
16717
|
const methodName = action.appDEMethodId;
|
|
16767
16718
|
if (!entityName || !methodName) {
|
|
16768
|
-
throw new
|
|
16719
|
+
throw new RuntimeModelError49(action, "\u672A\u914D\u7F6E\u5B9E\u4F53\u6216\u5B9E\u4F53\u884C\u4E3A");
|
|
16769
16720
|
}
|
|
16770
16721
|
const { resultContext, resultParams, resultData } = await this.handleParams(
|
|
16771
16722
|
action,
|
|
@@ -16890,7 +16841,7 @@ var SysUIActionProvider = class extends UIActionProviderBase {
|
|
|
16890
16841
|
// src/ui-action/provider/front-ui-action-provider.ts
|
|
16891
16842
|
import {
|
|
16892
16843
|
StringUtil,
|
|
16893
|
-
RuntimeModelError as
|
|
16844
|
+
RuntimeModelError as RuntimeModelError50,
|
|
16894
16845
|
ModelError as ModelError26,
|
|
16895
16846
|
RuntimeError as RuntimeError46
|
|
16896
16847
|
} from "@ibiz-template/core";
|
|
@@ -16908,7 +16859,7 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
16908
16859
|
case "WIZARD": {
|
|
16909
16860
|
const frontPSAppView = action.frontAppViewId;
|
|
16910
16861
|
if (!frontPSAppView) {
|
|
16911
|
-
throw new
|
|
16862
|
+
throw new RuntimeModelError50(action, "\u672A\u914D\u7F6E\u6253\u5F00\u89C6\u56FE");
|
|
16912
16863
|
}
|
|
16913
16864
|
const { resultContext, resultParams } = await this.handleParams(
|
|
16914
16865
|
action,
|
|
@@ -16973,7 +16924,7 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
16973
16924
|
);
|
|
16974
16925
|
return result || {};
|
|
16975
16926
|
}
|
|
16976
|
-
throw new
|
|
16927
|
+
throw new RuntimeModelError50(action, "\u81EA\u5B9A\u4E49\u7C7B\u578B\u7F3A\u5C11\u914D\u7F6E\u811A\u672C\u4EE3\u7801");
|
|
16977
16928
|
}
|
|
16978
16929
|
/**
|
|
16979
16930
|
* 执行打印行为
|
|
@@ -17814,7 +17765,7 @@ var RawItemPortletController = class extends PortletPartController {
|
|
|
17814
17765
|
};
|
|
17815
17766
|
|
|
17816
17767
|
// src/controller/control/data-view/data-view.controller.ts
|
|
17817
|
-
import { RuntimeModelError as
|
|
17768
|
+
import { RuntimeModelError as RuntimeModelError51 } from "@ibiz-template/core";
|
|
17818
17769
|
import { isNil as isNil22 } from "ramda";
|
|
17819
17770
|
|
|
17820
17771
|
// src/controller/control/data-view/data-view.service.ts
|
|
@@ -18029,7 +17980,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
18029
17980
|
const optItemModel = this.getOptItemModel();
|
|
18030
17981
|
if (optItemModel) {
|
|
18031
17982
|
if (!optItemModel.deuiactionGroup) {
|
|
18032
|
-
throw new
|
|
17983
|
+
throw new RuntimeModelError51(this.model, "\u64CD\u4F5C\u9879\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A\u7EC4");
|
|
18033
17984
|
}
|
|
18034
17985
|
if (!((_a = optItemModel.deuiactionGroup.uiactionGroupDetails) == null ? void 0 : _a.length)) {
|
|
18035
17986
|
ibiz.log.debug("\u64CD\u4F5C\u9879\u754C\u9762\u884C\u4E3A\u7EC4\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
|
|
@@ -18082,7 +18033,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
18082
18033
|
const { enableGroup, groupMode, groupAppDEFieldId } = this.model;
|
|
18083
18034
|
if (enableGroup && groupMode) {
|
|
18084
18035
|
if (!groupAppDEFieldId) {
|
|
18085
|
-
throw new
|
|
18036
|
+
throw new RuntimeModelError51(this.model, "\u5206\u7EC4\u5C5E\u6027\u6CA1\u6709\u914D\u7F6E");
|
|
18086
18037
|
}
|
|
18087
18038
|
if (groupMode === "AUTO") {
|
|
18088
18039
|
this.handleAutoGroup();
|
|
@@ -18149,7 +18100,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
18149
18100
|
async handleCodeListGroup() {
|
|
18150
18101
|
const { groupAppDEFieldId, groupCodeListId } = this.model;
|
|
18151
18102
|
if (!groupCodeListId) {
|
|
18152
|
-
throw new
|
|
18103
|
+
throw new RuntimeModelError51(this.model, "\u5206\u7EC4\u4EE3\u7801\u8868\u6CA1\u6709\u914D\u7F6E");
|
|
18153
18104
|
}
|
|
18154
18105
|
const { items } = this.state;
|
|
18155
18106
|
const groupMap = /* @__PURE__ */ new Map();
|
|
@@ -18255,7 +18206,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
18255
18206
|
caption = ibiz.i18n.t(item.capLanguageRes.lanResTag, item.caption);
|
|
18256
18207
|
}
|
|
18257
18208
|
if (!item.appDEFieldId) {
|
|
18258
|
-
throw new
|
|
18209
|
+
throw new RuntimeModelError51(item, "\u542F\u7528\u6392\u5E8F\u7684\u9879\u5FC5\u987B\u5173\u8054\u5B9E\u4F53\u5C5E\u6027");
|
|
18259
18210
|
}
|
|
18260
18211
|
const tempItem = {
|
|
18261
18212
|
caption,
|
|
@@ -18273,10 +18224,10 @@ var DataViewControlController = class extends MDControlController {
|
|
|
18273
18224
|
};
|
|
18274
18225
|
|
|
18275
18226
|
// src/controller/control/exp-bar/calendar-exp-bar.controller.ts
|
|
18276
|
-
import { RuntimeModelError as
|
|
18227
|
+
import { RuntimeModelError as RuntimeModelError53 } from "@ibiz-template/core";
|
|
18277
18228
|
|
|
18278
18229
|
// src/controller/control/exp-bar/exp-bar.controller.ts
|
|
18279
|
-
import { RuntimeError as RuntimeError48, RuntimeModelError as
|
|
18230
|
+
import { RuntimeError as RuntimeError48, RuntimeModelError as RuntimeModelError52 } from "@ibiz-template/core";
|
|
18280
18231
|
var ExpBarControlController = class extends ControlController {
|
|
18281
18232
|
constructor() {
|
|
18282
18233
|
super(...arguments);
|
|
@@ -18331,7 +18282,7 @@ var ExpBarControlController = class extends ControlController {
|
|
|
18331
18282
|
get xDataController() {
|
|
18332
18283
|
const controller = this.view.getController(this.model.xdataControlName);
|
|
18333
18284
|
if (!controller) {
|
|
18334
|
-
throw new
|
|
18285
|
+
throw new RuntimeModelError52(
|
|
18335
18286
|
this.model,
|
|
18336
18287
|
"\u65E0\u6CD5\u83B7\u53D6\u591A\u6570\u636E\u90E8\u4EF6[".concat(this.model.xdataControlName, "]\u63A7\u5236\u5668")
|
|
18337
18288
|
);
|
|
@@ -18690,7 +18641,7 @@ var CalendarExpBarController = class extends ExpBarControlController {
|
|
|
18690
18641
|
get xDataController() {
|
|
18691
18642
|
const controller = this.view.getController(this.model.xdataControlName);
|
|
18692
18643
|
if (!controller) {
|
|
18693
|
-
throw new
|
|
18644
|
+
throw new RuntimeModelError53(
|
|
18694
18645
|
this.model,
|
|
18695
18646
|
"\u65E0\u6CD5\u83B7\u53D6\u591A\u6570\u636E\u90E8\u4EF6[".concat(this.model.xdataControlName, "]\u63A7\u5236\u5668")
|
|
18696
18647
|
);
|
|
@@ -18745,7 +18696,7 @@ var CalendarExpBarController = class extends ExpBarControlController {
|
|
|
18745
18696
|
};
|
|
18746
18697
|
|
|
18747
18698
|
// src/controller/control/exp-bar/tree-exp-bar.controller.ts
|
|
18748
|
-
import { RuntimeError as RuntimeError49, RuntimeModelError as
|
|
18699
|
+
import { RuntimeError as RuntimeError49, RuntimeModelError as RuntimeModelError54 } from "@ibiz-template/core";
|
|
18749
18700
|
var TreeExpBarController = class extends ExpBarControlController {
|
|
18750
18701
|
constructor() {
|
|
18751
18702
|
super(...arguments);
|
|
@@ -18768,7 +18719,7 @@ var TreeExpBarController = class extends ExpBarControlController {
|
|
|
18768
18719
|
get xDataController() {
|
|
18769
18720
|
const controller = this.view.getController(this.model.xdataControlName);
|
|
18770
18721
|
if (!controller) {
|
|
18771
|
-
throw new
|
|
18722
|
+
throw new RuntimeModelError54(
|
|
18772
18723
|
this.model,
|
|
18773
18724
|
"\u65E0\u6CD5\u83B7\u53D6\u591A\u6570\u636E\u90E8\u4EF6[".concat(this.model.xdataControlName, "]\u63A7\u5236\u5668")
|
|
18774
18725
|
);
|
|
@@ -20774,7 +20725,7 @@ var FormMDCtrlController = class extends FormDetailController {
|
|
|
20774
20725
|
import {
|
|
20775
20726
|
mergeInLeft,
|
|
20776
20727
|
ModelError as ModelError27,
|
|
20777
|
-
RuntimeModelError as
|
|
20728
|
+
RuntimeModelError as RuntimeModelError55
|
|
20778
20729
|
} from "@ibiz-template/core";
|
|
20779
20730
|
var FormMDCtrlMDController = class extends FormMDCtrlController {
|
|
20780
20731
|
constructor() {
|
|
@@ -20800,7 +20751,7 @@ var FormMDCtrlMDController = class extends FormMDCtrlController {
|
|
|
20800
20751
|
await super.onInit();
|
|
20801
20752
|
const { contentControl } = this.model;
|
|
20802
20753
|
if (!contentControl) {
|
|
20803
|
-
throw new
|
|
20754
|
+
throw new RuntimeModelError55(this.model, "\u591A\u6570\u636E\u90E8\u4EF6\u672A\u914D\u7F6E\u5185\u5BB9\u90E8\u4EF6");
|
|
20804
20755
|
}
|
|
20805
20756
|
if (contentControl.controlType === "GRID") {
|
|
20806
20757
|
mergeInLeft(contentControl, {
|
|
@@ -20897,7 +20848,7 @@ var FormMDCtrlMDController = class extends FormMDCtrlController {
|
|
|
20897
20848
|
};
|
|
20898
20849
|
|
|
20899
20850
|
// src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-form.controller.ts
|
|
20900
|
-
import { RuntimeError as RuntimeError51, RuntimeModelError as
|
|
20851
|
+
import { RuntimeError as RuntimeError51, RuntimeModelError as RuntimeModelError56 } from "@ibiz-template/core";
|
|
20901
20852
|
import { createUUID as createUUID11 } from "qx-util";
|
|
20902
20853
|
|
|
20903
20854
|
// src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-form.state.ts
|
|
@@ -20938,7 +20889,7 @@ var FormMDCtrlFormController = class extends FormMDCtrlController {
|
|
|
20938
20889
|
super.onInit();
|
|
20939
20890
|
const { contentControl } = this.model;
|
|
20940
20891
|
if (!contentControl) {
|
|
20941
|
-
throw new
|
|
20892
|
+
throw new RuntimeModelError56(this.model, "\u591A\u6570\u636E\u90E8\u4EF6\u672A\u914D\u7F6E\u5185\u5BB9\u90E8\u4EF6");
|
|
20942
20893
|
}
|
|
20943
20894
|
contentControl.enableAutoSave = this.enableCreate || this.enableUpdate;
|
|
20944
20895
|
const controlProvider = await getControlProvider(contentControl);
|
|
@@ -21072,7 +21023,7 @@ var FormMDCtrlFormController = class extends FormMDCtrlController {
|
|
|
21072
21023
|
|
|
21073
21024
|
// src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-repeater.controller.ts
|
|
21074
21025
|
import { ModelError as ModelError28 } from "@ibiz-template/core";
|
|
21075
|
-
import { clone as
|
|
21026
|
+
import { clone as clone21 } from "ramda";
|
|
21076
21027
|
var FormMDCtrlRepeaterController = class extends FormMDCtrlController {
|
|
21077
21028
|
constructor() {
|
|
21078
21029
|
super(...arguments);
|
|
@@ -21156,7 +21107,7 @@ var FormMDCtrlRepeaterController = class extends FormMDCtrlController {
|
|
|
21156
21107
|
copyFields.forEach((key) => {
|
|
21157
21108
|
tempForm[key] = this.form.model[key];
|
|
21158
21109
|
});
|
|
21159
|
-
this.repeatedForm =
|
|
21110
|
+
this.repeatedForm = clone21(tempForm);
|
|
21160
21111
|
}
|
|
21161
21112
|
/**
|
|
21162
21113
|
* 设置重复器数据(修改主表单里重复器对应属性)
|
|
@@ -21286,12 +21237,12 @@ import {
|
|
|
21286
21237
|
} from "@ibiz-template/core";
|
|
21287
21238
|
import { debounce as debounce2 } from "lodash-es";
|
|
21288
21239
|
import { createUUID as createUUID12 } from "qx-util";
|
|
21289
|
-
import { clone as
|
|
21240
|
+
import { clone as clone22 } from "ramda";
|
|
21290
21241
|
|
|
21291
21242
|
// src/controller/control/form/edit-form/edit-form.service.ts
|
|
21292
21243
|
import {
|
|
21293
21244
|
recursiveIterate as recursiveIterate6,
|
|
21294
|
-
RuntimeModelError as
|
|
21245
|
+
RuntimeModelError as RuntimeModelError57
|
|
21295
21246
|
} from "@ibiz-template/core";
|
|
21296
21247
|
var EditFormService = class extends FormService {
|
|
21297
21248
|
/**
|
|
@@ -21415,7 +21366,7 @@ var EditFormService = class extends FormService {
|
|
|
21415
21366
|
const wizardForm = this.model;
|
|
21416
21367
|
const methodName = (_a = wizardForm.goBackControlAction) == null ? void 0 : _a.appDEMethodId;
|
|
21417
21368
|
if (!methodName) {
|
|
21418
|
-
throw new
|
|
21369
|
+
throw new RuntimeModelError57(this.model, "\u7F3A\u5C11\u8FD4\u56DE\u64CD\u4F5C\u5B9E\u4F53\u884C\u4E3A");
|
|
21419
21370
|
}
|
|
21420
21371
|
let res = await this.exec(
|
|
21421
21372
|
methodName,
|
|
@@ -21651,8 +21602,8 @@ var EditFormController = class extends FormController {
|
|
|
21651
21602
|
* @return {*} {Promise<IData>}
|
|
21652
21603
|
*/
|
|
21653
21604
|
async copy() {
|
|
21654
|
-
const context =
|
|
21655
|
-
const queryParams =
|
|
21605
|
+
const context = clone22(this.context);
|
|
21606
|
+
const queryParams = clone22(this.params);
|
|
21656
21607
|
const appDataEntity = await ibiz.hub.getAppDataEntity(
|
|
21657
21608
|
this.model.appDataEntityId,
|
|
21658
21609
|
this.model.appId
|
|
@@ -21709,7 +21660,7 @@ var EditFormController = class extends FormController {
|
|
|
21709
21660
|
return this.loadDraft();
|
|
21710
21661
|
}
|
|
21711
21662
|
const { context, params } = this.handlerAbilityParams(args);
|
|
21712
|
-
const queryParams =
|
|
21663
|
+
const queryParams = clone22(params);
|
|
21713
21664
|
let res;
|
|
21714
21665
|
try {
|
|
21715
21666
|
await this.startLoading();
|
|
@@ -22275,12 +22226,12 @@ import {
|
|
|
22275
22226
|
mergeDefaultInLeft,
|
|
22276
22227
|
recursiveIterate as recursiveIterate7,
|
|
22277
22228
|
RuntimeError as RuntimeError53,
|
|
22278
|
-
RuntimeModelError as
|
|
22229
|
+
RuntimeModelError as RuntimeModelError59
|
|
22279
22230
|
} from "@ibiz-template/core";
|
|
22280
|
-
import { clone as
|
|
22231
|
+
import { clone as clone23 } from "ramda";
|
|
22281
22232
|
|
|
22282
22233
|
// src/controller/control/grid/grid/grid.service.ts
|
|
22283
|
-
import { RuntimeModelError as
|
|
22234
|
+
import { RuntimeModelError as RuntimeModelError58 } from "@ibiz-template/core";
|
|
22284
22235
|
var GridService = class extends MDControlService {
|
|
22285
22236
|
/**
|
|
22286
22237
|
* 初始化属性映射
|
|
@@ -22308,7 +22259,7 @@ var GridService = class extends MDControlService {
|
|
|
22308
22259
|
dataType: dataItem.dataType
|
|
22309
22260
|
});
|
|
22310
22261
|
} else {
|
|
22311
|
-
throw new
|
|
22262
|
+
throw new RuntimeModelError58(
|
|
22312
22263
|
column,
|
|
22313
22264
|
"\u672A\u627E\u5230\u5BF9\u5E94\u7684\u8868\u683C\u6570\u636E\u9879[".concat(deField, "]")
|
|
22314
22265
|
);
|
|
@@ -22587,7 +22538,7 @@ var GridController = class extends MDControlController {
|
|
|
22587
22538
|
const result = await calcColumnModelBySchema(json, this);
|
|
22588
22539
|
if (result && result.degridColumns.length > 0) {
|
|
22589
22540
|
const { degridColumns, degridDataItems } = result;
|
|
22590
|
-
this.model =
|
|
22541
|
+
this.model = clone23(this.model);
|
|
22591
22542
|
this.model.degridColumns = [
|
|
22592
22543
|
...(this.model.degridColumns || []).filter((item) => {
|
|
22593
22544
|
return degridColumns.findIndex((x) => x.id === item.id) === -1;
|
|
@@ -22618,11 +22569,11 @@ var GridController = class extends MDControlController {
|
|
|
22618
22569
|
(item) => item.model.appDEFieldId === groupAppDEFieldId
|
|
22619
22570
|
);
|
|
22620
22571
|
if (!this.groupFieldColumn) {
|
|
22621
|
-
throw new
|
|
22572
|
+
throw new RuntimeModelError59(this.model, "\u6CA1\u6709\u914D\u7F6E\u5206\u7EC4\u5C5E\u6027\u7684\u5C5E\u6027\u5217");
|
|
22622
22573
|
}
|
|
22623
22574
|
const groupFieldName = this.groupFieldColumn.model.id;
|
|
22624
22575
|
if (!this.groupFieldColumn.model.appCodeListId) {
|
|
22625
|
-
throw new
|
|
22576
|
+
throw new RuntimeModelError59(
|
|
22626
22577
|
this.groupFieldColumn.model,
|
|
22627
22578
|
"\u5206\u7EC4\u5C5E\u6027\u7684\u5C5E\u6027\u5217".concat(groupFieldName, "\u6CA1\u6709\u914D\u7F6E\u4EE3\u7801\u8868")
|
|
22628
22579
|
);
|
|
@@ -22632,7 +22583,7 @@ var GridController = class extends MDControlController {
|
|
|
22632
22583
|
);
|
|
22633
22584
|
if (index !== -1 && index !== 0) {
|
|
22634
22585
|
if (this.isMultistageHeader) {
|
|
22635
|
-
throw new
|
|
22586
|
+
throw new RuntimeModelError59(
|
|
22636
22587
|
this.model,
|
|
22637
22588
|
"\u8BF7\u5C06\u5206\u7EC4\u5C5E\u6027\u5217".concat(groupFieldName, "\u914D\u7F6E\u4E3A\u7B2C\u4E00\u5217")
|
|
22638
22589
|
);
|
|
@@ -22642,10 +22593,10 @@ var GridController = class extends MDControlController {
|
|
|
22642
22593
|
}
|
|
22643
22594
|
if (groupMode === "CODELIST") {
|
|
22644
22595
|
if (!groupCodeListId) {
|
|
22645
|
-
throw new
|
|
22596
|
+
throw new RuntimeModelError59(this.model, "\u4EE3\u7801\u8868\u5206\u7EC4\u6A21\u5F0F\u9700\u8981\u914D\u7F6E\u4EE3\u7801\u8868");
|
|
22646
22597
|
}
|
|
22647
22598
|
if (this.groupFieldColumn.model.appCodeListId !== groupCodeListId) {
|
|
22648
|
-
throw new
|
|
22599
|
+
throw new RuntimeModelError59(
|
|
22649
22600
|
this.model,
|
|
22650
22601
|
"\u5206\u7EC4\u4EE3\u7801\u8868\u4E0E\u5C5E\u6027\u5217".concat(groupFieldName, "\u7684\u4EE3\u7801\u8868\u4E0D\u4E00\u81F4")
|
|
22651
22602
|
);
|
|
@@ -22732,7 +22683,7 @@ var GridController = class extends MDControlController {
|
|
|
22732
22683
|
return;
|
|
22733
22684
|
}
|
|
22734
22685
|
if (!aggAppDEDataSetId || !aggAppDataEntityId) {
|
|
22735
|
-
throw new
|
|
22686
|
+
throw new RuntimeModelError59(this.model, "\u7F3A\u5C11\u914D\u7F6E\u805A\u5408\u5B9E\u4F53\u6216\u805A\u5408\u6570\u636E\u96C6");
|
|
22736
22687
|
}
|
|
22737
22688
|
const params = await this.getFetchParams();
|
|
22738
22689
|
const app = ibiz.hub.getApp(this.context.srfappid);
|
|
@@ -22949,7 +22900,7 @@ var GridController = class extends MDControlController {
|
|
|
22949
22900
|
this.state.columnStates.push({
|
|
22950
22901
|
key: column.codeName,
|
|
22951
22902
|
caption: column.caption,
|
|
22952
|
-
hidden: !!column.hideDefault,
|
|
22903
|
+
hidden: !!column.hideDefault || !!column.hiddenDataItem,
|
|
22953
22904
|
uaColumn: column.columnType === "UAGRIDCOLUMN"
|
|
22954
22905
|
});
|
|
22955
22906
|
}
|
|
@@ -23102,7 +23053,7 @@ var GridController = class extends MDControlController {
|
|
|
23102
23053
|
throw new RuntimeError53("\u540C\u65F6\u53EA\u80FD\u6709\u4E00\u884C\u5F00\u542F\u884C\u7F16\u8F91");
|
|
23103
23054
|
}
|
|
23104
23055
|
if (row.data.srfuf === 1 /* UPDATE */) {
|
|
23105
|
-
row.cacheData =
|
|
23056
|
+
row.cacheData = clone23(row.data);
|
|
23106
23057
|
const defaultVal = this.calcDefaultValue(row.data, false);
|
|
23107
23058
|
Object.assign(row.data, defaultVal);
|
|
23108
23059
|
}
|
|
@@ -23271,7 +23222,7 @@ var GridController = class extends MDControlController {
|
|
|
23271
23222
|
}
|
|
23272
23223
|
});
|
|
23273
23224
|
}
|
|
23274
|
-
const cloneData =
|
|
23225
|
+
const cloneData = clone23(
|
|
23275
23226
|
data2.map((item) => {
|
|
23276
23227
|
return item.getOrigin();
|
|
23277
23228
|
})
|
|
@@ -23509,7 +23460,7 @@ var GridController = class extends MDControlController {
|
|
|
23509
23460
|
import { DataTypes as DataTypes3, ModelError as ModelError29, plus as plus2 } from "@ibiz-template/core";
|
|
23510
23461
|
import dayjs4 from "dayjs";
|
|
23511
23462
|
import { debounce as debounce3 } from "lodash-es";
|
|
23512
|
-
import { clone as
|
|
23463
|
+
import { clone as clone24, isNil as isNil23 } from "ramda";
|
|
23513
23464
|
var GridFieldColumnController = class extends GridColumnController {
|
|
23514
23465
|
constructor() {
|
|
23515
23466
|
super(...arguments);
|
|
@@ -23638,7 +23589,7 @@ var GridFieldColumnController = class extends GridColumnController {
|
|
|
23638
23589
|
srfkey: value,
|
|
23639
23590
|
...wfContext
|
|
23640
23591
|
});
|
|
23641
|
-
const tempParams =
|
|
23592
|
+
const tempParams = clone24(this.params);
|
|
23642
23593
|
const { context: newContext, params: newParams } = this.handlePublicParams(
|
|
23643
23594
|
row.data,
|
|
23644
23595
|
tempContext,
|
|
@@ -23809,7 +23760,7 @@ var GridFieldColumnController = class extends GridColumnController {
|
|
|
23809
23760
|
};
|
|
23810
23761
|
|
|
23811
23762
|
// src/controller/control/grid/grid-column/grid-ua-column/grid-ua-column.controller.ts
|
|
23812
|
-
import { RuntimeModelError as
|
|
23763
|
+
import { RuntimeModelError as RuntimeModelError60 } from "@ibiz-template/core";
|
|
23813
23764
|
var GridUAColumnController = class extends GridColumnController {
|
|
23814
23765
|
/**
|
|
23815
23766
|
* 给rowController初始化操作列的状态
|
|
@@ -23822,7 +23773,7 @@ var GridUAColumnController = class extends GridColumnController {
|
|
|
23822
23773
|
var _a;
|
|
23823
23774
|
const { deuiactionGroup } = this.model;
|
|
23824
23775
|
if (!deuiactionGroup) {
|
|
23825
|
-
throw new
|
|
23776
|
+
throw new RuntimeModelError60(this.model, "\u64CD\u4F5C\u5217\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A\u7EC4");
|
|
23826
23777
|
}
|
|
23827
23778
|
if (!((_a = deuiactionGroup.uiactionGroupDetails) == null ? void 0 : _a.length)) {
|
|
23828
23779
|
ibiz.log.debug("\u64CD\u4F5C\u5217\u754C\u9762\u884C\u4E3A\u7EC4\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
|
|
@@ -25038,10 +24989,10 @@ import {
|
|
|
25038
24989
|
mergeInLeft as mergeInLeft3,
|
|
25039
24990
|
recursiveIterate as recursiveIterate9
|
|
25040
24991
|
} from "@ibiz-template/core";
|
|
25041
|
-
import { clone as
|
|
24992
|
+
import { clone as clone25, isNil as isNil24 } from "ramda";
|
|
25042
24993
|
|
|
25043
24994
|
// src/controller/control/search-bar/search-bar-filter.controller.ts
|
|
25044
|
-
import { RuntimeModelError as
|
|
24995
|
+
import { RuntimeModelError as RuntimeModelError61 } from "@ibiz-template/core";
|
|
25045
24996
|
var ExcludeOPs = [
|
|
25046
24997
|
"ISNULL" /* IS_NULL */,
|
|
25047
24998
|
"ISNOTNULL" /* IS_NOT_NULL */
|
|
@@ -25082,7 +25033,7 @@ var SearchBarFilterController = class {
|
|
|
25082
25033
|
async init() {
|
|
25083
25034
|
if (!this.noEditor) {
|
|
25084
25035
|
if (!this.model.editor) {
|
|
25085
|
-
throw new
|
|
25036
|
+
throw new RuntimeModelError61(this.model, "\u7F3A\u5C11\u7F16\u8F91\u5668\u6A21\u578B");
|
|
25086
25037
|
}
|
|
25087
25038
|
this.editorProvider = await getEditorProvider(this.model.editor);
|
|
25088
25039
|
if (this.editorProvider) {
|
|
@@ -25542,7 +25493,7 @@ var SearchBarController = class extends ControlController {
|
|
|
25542
25493
|
}
|
|
25543
25494
|
});
|
|
25544
25495
|
if (addSearchBarFilters.length > 0) {
|
|
25545
|
-
this.model =
|
|
25496
|
+
this.model = clone25(this.model);
|
|
25546
25497
|
this.model.searchBarFilters = addSearchBarFilters.concat(...mergeFilters);
|
|
25547
25498
|
this.model.enableFilter = true;
|
|
25548
25499
|
}
|
|
@@ -26126,7 +26077,7 @@ var TabExpPanelController = class extends ControlController {
|
|
|
26126
26077
|
// src/controller/control/tree/tree.controller.ts
|
|
26127
26078
|
import {
|
|
26128
26079
|
RuntimeError as RuntimeError57,
|
|
26129
|
-
RuntimeModelError as
|
|
26080
|
+
RuntimeModelError as RuntimeModelError62,
|
|
26130
26081
|
recursiveIterate as recursiveIterate10
|
|
26131
26082
|
} from "@ibiz-template/core";
|
|
26132
26083
|
|
|
@@ -26997,7 +26948,7 @@ var TreeController = class extends MDControlController {
|
|
|
26997
26948
|
const { sortAppDEFieldId, sortDir, allowOrder } = orderNodeModel;
|
|
26998
26949
|
if (allowOrder === true) {
|
|
26999
26950
|
if (!sortAppDEFieldId) {
|
|
27000
|
-
throw new
|
|
26951
|
+
throw new RuntimeModelError62(orderNodeModel, "\u7F3A\u5C11\u914D\u7F6E\u6392\u5E8F\u5C5E\u6027");
|
|
27001
26952
|
}
|
|
27002
26953
|
const sortField = sortAppDEFieldId.toLowerCase();
|
|
27003
26954
|
const isAsc = sortDir === "ASC";
|
|
@@ -27078,7 +27029,7 @@ var TreeController = class extends MDControlController {
|
|
|
27078
27029
|
async modifyNodeText(nodeData, text) {
|
|
27079
27030
|
const model = this.getNodeModel(nodeData._nodeId);
|
|
27080
27031
|
if (!model.allowEditText) {
|
|
27081
|
-
throw new
|
|
27032
|
+
throw new RuntimeModelError62(model, "\u6811\u8282\u70B9\u6CA1\u6709\u914D\u7F6E\u7F16\u8F91\u6A21\u5F0F\uFF1A\u540D\u79F0");
|
|
27082
27033
|
}
|
|
27083
27034
|
if (!nodeData._deData) {
|
|
27084
27035
|
throw new RuntimeError57("\u4E0D\u662F\u5B9E\u4F53\u6811\u8282\u70B9\u6570\u636E");
|
|
@@ -27442,7 +27393,7 @@ var WizardPanelController = class extends ControlController {
|
|
|
27442
27393
|
};
|
|
27443
27394
|
|
|
27444
27395
|
// src/controller/control/md-ctrl/md-ctrl.controller.ts
|
|
27445
|
-
import { RuntimeModelError as
|
|
27396
|
+
import { RuntimeModelError as RuntimeModelError63 } from "@ibiz-template/core";
|
|
27446
27397
|
import { isNil as isNil25 } from "ramda";
|
|
27447
27398
|
|
|
27448
27399
|
// src/controller/control/md-ctrl/md-ctrl.service.ts
|
|
@@ -27649,7 +27600,7 @@ var MDCtrlController = class extends MDControlController {
|
|
|
27649
27600
|
const { enableGroup, groupMode, groupAppDEFieldId } = this.model;
|
|
27650
27601
|
if (enableGroup && groupMode) {
|
|
27651
27602
|
if (!groupAppDEFieldId) {
|
|
27652
|
-
throw new
|
|
27603
|
+
throw new RuntimeModelError63(this.model, "\u5206\u7EC4\u5C5E\u6027\u6CA1\u6709\u914D\u7F6E");
|
|
27653
27604
|
}
|
|
27654
27605
|
if (groupMode === "AUTO") {
|
|
27655
27606
|
this.handleAutoGroup();
|
|
@@ -27716,7 +27667,7 @@ var MDCtrlController = class extends MDControlController {
|
|
|
27716
27667
|
async handleCodeListGroup() {
|
|
27717
27668
|
const { groupAppDEFieldId, groupCodeListId } = this.model;
|
|
27718
27669
|
if (!groupCodeListId) {
|
|
27719
|
-
throw new
|
|
27670
|
+
throw new RuntimeModelError63(this.model, "\u5206\u7EC4\u4EE3\u7801\u8868\u6CA1\u6709\u914D\u7F6E");
|
|
27720
27671
|
}
|
|
27721
27672
|
const { items } = this.state;
|
|
27722
27673
|
const groupMap = /* @__PURE__ */ new Map();
|
|
@@ -27746,7 +27697,7 @@ var MDCtrlController = class extends MDControlController {
|
|
|
27746
27697
|
};
|
|
27747
27698
|
|
|
27748
27699
|
// src/controller/control/kanban/kanban.controller.ts
|
|
27749
|
-
import { RuntimeError as RuntimeError59, RuntimeModelError as
|
|
27700
|
+
import { RuntimeError as RuntimeError59, RuntimeModelError as RuntimeModelError64 } from "@ibiz-template/core";
|
|
27750
27701
|
import { isNil as isNil26 } from "ramda";
|
|
27751
27702
|
|
|
27752
27703
|
// src/controller/control/kanban/kanban.service.ts
|
|
@@ -27824,10 +27775,10 @@ var KanbanController = class extends DataViewControlController {
|
|
|
27824
27775
|
const sortField = this.model.minorSortAppDEFieldId;
|
|
27825
27776
|
const { minorSortDir } = this.model;
|
|
27826
27777
|
if (!sortField) {
|
|
27827
|
-
throw new
|
|
27778
|
+
throw new RuntimeModelError64(this.model, "\u6392\u5E8F\u5C5E\u6027\u6CA1\u914D\u7F6E");
|
|
27828
27779
|
}
|
|
27829
27780
|
if (!minorSortDir) {
|
|
27830
|
-
throw new
|
|
27781
|
+
throw new RuntimeModelError64(this.model, "\u6392\u5E8F\u65B9\u5411\u6CA1\u914D\u7F6E");
|
|
27831
27782
|
}
|
|
27832
27783
|
const isAsc = minorSortDir === "ASC";
|
|
27833
27784
|
items.forEach((item) => {
|
|
@@ -27971,7 +27922,7 @@ var KanbanController = class extends DataViewControlController {
|
|
|
27971
27922
|
async handleCodeListGroup() {
|
|
27972
27923
|
const { groupAppDEFieldId, groupCodeListId } = this.model;
|
|
27973
27924
|
if (!groupCodeListId) {
|
|
27974
|
-
throw new
|
|
27925
|
+
throw new RuntimeModelError64(this.model, "\u5206\u7EC4\u4EE3\u7801\u8868\u6CA1\u6709\u914D\u7F6E");
|
|
27975
27926
|
}
|
|
27976
27927
|
const { items } = this.state;
|
|
27977
27928
|
const groupMap = /* @__PURE__ */ new Map();
|
|
@@ -28580,7 +28531,7 @@ var TreeGridExFieldColumnController = class extends TreeGridExColumnController {
|
|
|
28580
28531
|
};
|
|
28581
28532
|
|
|
28582
28533
|
// src/controller/control/tree-grid-ex/tree-grid-ex-column/tree-grid-ex-ua-column/tree-grid-ex-ua-column.controller.ts
|
|
28583
|
-
import { RuntimeModelError as
|
|
28534
|
+
import { RuntimeModelError as RuntimeModelError65 } from "@ibiz-template/core";
|
|
28584
28535
|
var TreeGridExUAColumnController = class extends TreeGridExColumnController {
|
|
28585
28536
|
/**
|
|
28586
28537
|
* 给rowController初始化操作列的状态
|
|
@@ -28593,7 +28544,7 @@ var TreeGridExUAColumnController = class extends TreeGridExColumnController {
|
|
|
28593
28544
|
var _a;
|
|
28594
28545
|
const { deuiactionGroup } = this.model;
|
|
28595
28546
|
if (!deuiactionGroup) {
|
|
28596
|
-
throw new
|
|
28547
|
+
throw new RuntimeModelError65(this.model, "\u64CD\u4F5C\u5217\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A\u7EC4");
|
|
28597
28548
|
}
|
|
28598
28549
|
if (!((_a = deuiactionGroup.uiactionGroupDetails) == null ? void 0 : _a.length)) {
|
|
28599
28550
|
ibiz.log.debug("\u64CD\u4F5C\u5217\u754C\u9762\u884C\u4E3A\u7EC4\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
|
|
@@ -28638,7 +28589,7 @@ var TreeGridExUAColumnController = class extends TreeGridExColumnController {
|
|
|
28638
28589
|
};
|
|
28639
28590
|
|
|
28640
28591
|
// src/controller/control/tree-grid/tree-grid.controller.ts
|
|
28641
|
-
import { RuntimeModelError as
|
|
28592
|
+
import { RuntimeModelError as RuntimeModelError66 } from "@ibiz-template/core";
|
|
28642
28593
|
var TreeGridController = class extends GridController {
|
|
28643
28594
|
constructor() {
|
|
28644
28595
|
super(...arguments);
|
|
@@ -28683,10 +28634,10 @@ var TreeGridController = class extends GridController {
|
|
|
28683
28634
|
return item.treeColumnMode === 2 || item.treeColumnMode === 3;
|
|
28684
28635
|
});
|
|
28685
28636
|
if (!treeGridParent) {
|
|
28686
|
-
throw new
|
|
28637
|
+
throw new RuntimeModelError66(this.model, "\u6811\u8868\u683C\u65E0\u503C\u5217\u6A21\u5F0F");
|
|
28687
28638
|
}
|
|
28688
28639
|
if (!treeGridValue) {
|
|
28689
|
-
throw new
|
|
28640
|
+
throw new RuntimeModelError66(this.model, "\u6811\u8868\u683C\u65E0\u7236\u503C\u5217\u6A21\u5F0F");
|
|
28690
28641
|
}
|
|
28691
28642
|
this.treeGridValueField = treeGridValue.appDEFieldId.toLowerCase();
|
|
28692
28643
|
this.treeGridParentField = treeGridParent.appDEFieldId.toLowerCase();
|
|
@@ -30113,6 +30064,20 @@ var AppHub = class {
|
|
|
30113
30064
|
}
|
|
30114
30065
|
return [];
|
|
30115
30066
|
}
|
|
30067
|
+
/**
|
|
30068
|
+
* 获取应用实体服务
|
|
30069
|
+
*
|
|
30070
|
+
* @author chitanda
|
|
30071
|
+
* @date 2024-01-10 13:01:01
|
|
30072
|
+
* @param {string} appId
|
|
30073
|
+
* @param {string} entityId
|
|
30074
|
+
* @param {IContext} context
|
|
30075
|
+
* @return {*} {Promise<IAppDEService>}
|
|
30076
|
+
*/
|
|
30077
|
+
async getAppDEService(appId2, entityId, context) {
|
|
30078
|
+
const app = await this.getAppAsync(appId2);
|
|
30079
|
+
return app.deService.getService(context, entityId);
|
|
30080
|
+
}
|
|
30116
30081
|
reset() {
|
|
30117
30082
|
this.appMap.clear();
|
|
30118
30083
|
this.configCache = void 0;
|
|
@@ -30378,8 +30343,8 @@ var ViewEngineBase = class {
|
|
|
30378
30343
|
};
|
|
30379
30344
|
|
|
30380
30345
|
// src/engine/md-view.engine.ts
|
|
30381
|
-
import { RuntimeModelError as
|
|
30382
|
-
import { clone as
|
|
30346
|
+
import { RuntimeModelError as RuntimeModelError67 } from "@ibiz-template/core";
|
|
30347
|
+
import { clone as clone26 } from "ramda";
|
|
30383
30348
|
var MDViewEngine = class extends ViewEngineBase {
|
|
30384
30349
|
/**
|
|
30385
30350
|
* 多数据部件名称
|
|
@@ -30562,7 +30527,7 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
30562
30527
|
view: this.view
|
|
30563
30528
|
}));
|
|
30564
30529
|
if (result === -1) {
|
|
30565
|
-
throw new
|
|
30530
|
+
throw new RuntimeModelError67(this.view.model, "\u7F3A\u5C11newdata\u7684\u89C6\u56FE\u903B\u8F91");
|
|
30566
30531
|
} else {
|
|
30567
30532
|
return {
|
|
30568
30533
|
cancel: !result.ok
|
|
@@ -30585,9 +30550,9 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
30585
30550
|
(item) => item.id === "newdata"
|
|
30586
30551
|
);
|
|
30587
30552
|
if (!openAppViewLogic) {
|
|
30588
|
-
throw new
|
|
30553
|
+
throw new RuntimeModelError67(this.view.model, "\u7F3A\u5C11newdata\u7684\u89C6\u56FE\u903B\u8F91");
|
|
30589
30554
|
}
|
|
30590
|
-
const params =
|
|
30555
|
+
const params = clone26(this.view.params);
|
|
30591
30556
|
if (copyMode) {
|
|
30592
30557
|
params.srfcopymode = copyMode;
|
|
30593
30558
|
}
|
|
@@ -30599,7 +30564,7 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
30599
30564
|
view: this.view
|
|
30600
30565
|
}));
|
|
30601
30566
|
if (result === -1) {
|
|
30602
|
-
throw new
|
|
30567
|
+
throw new RuntimeModelError67(this.view.model, "\u7F3A\u5C11newdata\u7684\u89C6\u56FE\u903B\u8F91");
|
|
30603
30568
|
} else {
|
|
30604
30569
|
return {
|
|
30605
30570
|
cancel: !result.ok
|
|
@@ -30910,13 +30875,13 @@ var ScriptExecutor = class extends LogicExecutor {
|
|
|
30910
30875
|
};
|
|
30911
30876
|
|
|
30912
30877
|
// src/logic-scheduler/executor/app-de-ui-logic-executor.ts
|
|
30913
|
-
import { RuntimeModelError as
|
|
30878
|
+
import { RuntimeModelError as RuntimeModelError68 } from "@ibiz-template/core";
|
|
30914
30879
|
var AppDEUILogicExecutor = class extends LogicExecutor {
|
|
30915
30880
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
30916
30881
|
execute(executeParams) {
|
|
30917
30882
|
const { appDEUILogicId, appDataEntityId } = this.logic;
|
|
30918
30883
|
if (!appDEUILogicId) {
|
|
30919
|
-
throw new
|
|
30884
|
+
throw new RuntimeModelError68(this.logic, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u754C\u9762\u903B\u8F91");
|
|
30920
30885
|
}
|
|
30921
30886
|
execUILogic(appDEUILogicId, appDataEntityId, executeParams);
|
|
30922
30887
|
}
|
|
@@ -31374,7 +31339,7 @@ var ItemDynaLogicTrigger = class extends LogicTrigger {
|
|
|
31374
31339
|
};
|
|
31375
31340
|
|
|
31376
31341
|
// src/logic-scheduler/trigger/timer-trigger.ts
|
|
31377
|
-
import { RuntimeError as RuntimeError66, RuntimeModelError as
|
|
31342
|
+
import { RuntimeError as RuntimeError66, RuntimeModelError as RuntimeModelError69 } from "@ibiz-template/core";
|
|
31378
31343
|
var TimerTrigger = class extends LogicTrigger {
|
|
31379
31344
|
constructor() {
|
|
31380
31345
|
super(...arguments);
|
|
@@ -31382,7 +31347,7 @@ var TimerTrigger = class extends LogicTrigger {
|
|
|
31382
31347
|
}
|
|
31383
31348
|
start() {
|
|
31384
31349
|
if (!this.logic.timer) {
|
|
31385
|
-
throw new
|
|
31350
|
+
throw new RuntimeModelError69(this.logic, "\u5B9A\u65F6\u5668\u7F3A\u5C11\u5B9A\u65F6\u95F4\u9694");
|
|
31386
31351
|
}
|
|
31387
31352
|
this.timer = setInterval(() => {
|
|
31388
31353
|
if (!this.scheduler.defaultParamsCb) {
|
|
@@ -31404,7 +31369,7 @@ var TimerTrigger = class extends LogicTrigger {
|
|
|
31404
31369
|
import {
|
|
31405
31370
|
ModelError as ModelError34,
|
|
31406
31371
|
RuntimeError as RuntimeError67,
|
|
31407
|
-
RuntimeModelError as
|
|
31372
|
+
RuntimeModelError as RuntimeModelError70
|
|
31408
31373
|
} from "@ibiz-template/core";
|
|
31409
31374
|
import { notNilEmpty as notNilEmpty9 } from "qx-util";
|
|
31410
31375
|
var AppUILogicExecutor = class extends LogicExecutor {
|
|
@@ -31450,7 +31415,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
31450
31415
|
} else {
|
|
31451
31416
|
openViewRef = appUILogic.openDataAppView;
|
|
31452
31417
|
if (!openViewRef) {
|
|
31453
|
-
throw new
|
|
31418
|
+
throw new RuntimeModelError70(
|
|
31454
31419
|
appUILogic,
|
|
31455
31420
|
"opendata\u89C6\u56FE\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u9ED8\u8BA4\u6253\u5F00\u89C6\u56FE"
|
|
31456
31421
|
);
|
|
@@ -31458,7 +31423,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
31458
31423
|
}
|
|
31459
31424
|
const openView = openViewRef.refAppViewId;
|
|
31460
31425
|
if (!openView) {
|
|
31461
|
-
throw new
|
|
31426
|
+
throw new RuntimeModelError70(
|
|
31462
31427
|
appUILogic,
|
|
31463
31428
|
"opendata\u89C6\u56FE\u903B\u8F91\u7684\u9ED8\u8BA4\u6253\u5F00\u89C6\u56FE\u6CA1\u6709\u5B9E\u9645\u5F15\u7528\u89C6\u56FE"
|
|
31464
31429
|
);
|
|
@@ -31488,7 +31453,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
31488
31453
|
);
|
|
31489
31454
|
const typeFileName = appDataEntity.formTypeAppDEFieldId || appDataEntity.dataTypeAppDEFieldId;
|
|
31490
31455
|
if (!typeFileName) {
|
|
31491
|
-
throw new
|
|
31456
|
+
throw new RuntimeModelError70(
|
|
31492
31457
|
appUILogic,
|
|
31493
31458
|
"".concat(appDataEntity.codeName, "[\u591A\u8868\u5355\u5B9E\u4F53] or [\u7D22\u5F15\u5B9E\u4F53]\u7F3A\u5C11\u7C7B\u578B\u5C5E\u6027\u914D\u7F6E")
|
|
31494
31459
|
);
|
|
@@ -31496,7 +31461,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
31496
31461
|
const { data } = parameters;
|
|
31497
31462
|
const formTypeValue = data[0][typeFileName];
|
|
31498
31463
|
if (!formTypeValue) {
|
|
31499
|
-
throw new
|
|
31464
|
+
throw new RuntimeModelError70(appUILogic, "\u6570\u636E\u6E90\u65E0\u8868\u5355\u7C7B\u578B\u5E94\u7528\u5B9E\u4F53\u5C5E\u6027\u503C");
|
|
31500
31465
|
}
|
|
31501
31466
|
const openViewRefs = appUILogic.openDataAppViews;
|
|
31502
31467
|
const findView = openViewRefs == null ? void 0 : openViewRefs.find((item) => item.refMode === formTypeValue);
|
|
@@ -31538,7 +31503,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
31538
31503
|
return viewRef.refMode.toLowerCase() !== parentDeName;
|
|
31539
31504
|
});
|
|
31540
31505
|
if (!newViewRef) {
|
|
31541
|
-
throw new
|
|
31506
|
+
throw new RuntimeModelError70(
|
|
31542
31507
|
appUILogic,
|
|
31543
31508
|
"\u6CA1\u6709\u627E\u5230\u6279\u6DFB\u52A0\u9700\u8981\u6253\u5F00\u7684\u9009\u62E9\u89C6\u56FE"
|
|
31544
31509
|
);
|
|
@@ -31548,7 +31513,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
31548
31513
|
} else {
|
|
31549
31514
|
newViewRef = newDataAppView;
|
|
31550
31515
|
if (!newViewRef || !newViewRef.refAppViewId) {
|
|
31551
|
-
throw new
|
|
31516
|
+
throw new RuntimeModelError70(
|
|
31552
31517
|
appUILogic,
|
|
31553
31518
|
"newdata\u89C6\u56FE\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u9ED8\u8BA4\u65B0\u5EFA\u6570\u636E\u89C6\u56FE"
|
|
31554
31519
|
);
|
|
@@ -31612,7 +31577,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
31612
31577
|
const { wizardAppView, newDataAppViews } = appUILogic;
|
|
31613
31578
|
const { context, params, ...rest } = parameters;
|
|
31614
31579
|
if (!wizardAppView || !wizardAppView.refAppViewId) {
|
|
31615
|
-
throw new
|
|
31580
|
+
throw new RuntimeModelError70(appUILogic, "\u7F3A\u5C11\u9ED8\u8BA4\u7D22\u5F15\u5B9E\u4F53\u9009\u62E9\u89C6\u56FE");
|
|
31616
31581
|
}
|
|
31617
31582
|
const result = await ibiz.commands.execute(
|
|
31618
31583
|
OpenAppViewCommand.TAG,
|
|
@@ -31663,7 +31628,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
31663
31628
|
const minorDERs = selfDe.minorAppDERSs;
|
|
31664
31629
|
const pickParentDeName = newViewRef.refMode.toLowerCase();
|
|
31665
31630
|
if (!minorDERs) {
|
|
31666
|
-
throw new
|
|
31631
|
+
throw new RuntimeModelError70(selfDe, "\u5B9E\u4F53\u6CA1\u6709\u4ECE\u5173\u7CFB\u96C6\u5408\uFF01");
|
|
31667
31632
|
}
|
|
31668
31633
|
let pickParentFieldName = "";
|
|
31669
31634
|
minorDERs == null ? void 0 : minorDERs.forEach((item) => {
|
|
@@ -31760,12 +31725,12 @@ var ControlEventTrigger = class extends LogicTrigger {
|
|
|
31760
31725
|
};
|
|
31761
31726
|
|
|
31762
31727
|
// src/logic-scheduler/executor/app-ui-action-executor.ts
|
|
31763
|
-
import { RuntimeModelError as
|
|
31728
|
+
import { RuntimeModelError as RuntimeModelError71 } from "@ibiz-template/core";
|
|
31764
31729
|
var AppDEUIActionExecutor = class extends LogicExecutor {
|
|
31765
31730
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
31766
31731
|
execute(executeParams) {
|
|
31767
31732
|
if (!this.logic.appDEUIActionId) {
|
|
31768
|
-
throw new
|
|
31733
|
+
throw new RuntimeModelError71(
|
|
31769
31734
|
this.logic,
|
|
31770
31735
|
"\u903B\u8F91\u4E2D\u7F3A\u5C11\u89E6\u53D1\u5E94\u7528\u5B9E\u4F53\u754C\u9762\u884C\u4E3Aid"
|
|
31771
31736
|
);
|