@ibiz-template/runtime 0.7.1 → 0.7.3
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 +736 -261
- package/dist/index.system.min.js +1 -1
- package/out/config/global-config.d.ts +2 -1
- package/out/config/global-config.d.ts.map +1 -1
- package/out/config/global-config.js +4 -0
- package/out/controller/common/base.controller.d.ts +9 -1
- package/out/controller/common/base.controller.d.ts.map +1 -1
- package/out/controller/common/base.controller.js +12 -1
- package/out/controller/common/control/md-control.controller.d.ts.map +1 -1
- package/out/controller/common/control/md-control.controller.js +7 -19
- package/out/controller/common/index.d.ts +1 -0
- package/out/controller/common/index.d.ts.map +1 -1
- package/out/controller/common/index.js +1 -0
- package/out/controller/common/view/app-data-upload-view.controller.d.ts +36 -0
- package/out/controller/common/view/app-data-upload-view.controller.d.ts.map +1 -0
- package/out/controller/common/view/app-data-upload-view.controller.js +59 -0
- package/out/controller/common/view/view.controller.d.ts.map +1 -1
- package/out/controller/common/view/view.controller.js +9 -0
- package/out/controller/control/form/edit-form/edit-form.controller.js +12 -12
- package/out/controller/control/form/form/form.controller.js +1 -1
- package/out/controller/control/form/form-detail/form-detail/form-detail.controller.d.ts.map +1 -1
- package/out/controller/control/form/form-detail/form-detail/form-detail.controller.js +1 -4
- package/out/controller/control/form/form-detail/form-detail/form-detail.state.d.ts +8 -0
- package/out/controller/control/form/form-detail/form-detail/form-detail.state.d.ts.map +1 -1
- package/out/controller/control/form/form-detail/form-detail/form-detail.state.js +12 -2
- package/out/controller/control/form/form-detail/form-item/form-item.controller.d.ts.map +1 -1
- package/out/controller/control/form/form-detail/form-item/form-item.controller.js +4 -3
- package/out/controller/control/grid/grid/grid-row.state.d.ts.map +1 -1
- package/out/controller/control/grid/grid/grid-row.state.js +22 -1
- package/out/controller/control/grid/grid/grid.controller.js +1 -1
- package/out/controller/control/grid/grid-column/grid-field-edit-column/grid-field-edit-column.controller.d.ts.map +1 -1
- package/out/controller/control/grid/grid-column/grid-field-edit-column/grid-field-edit-column.controller.js +3 -1
- package/out/controller/control/panel/panel/panel-item.controller.d.ts.map +1 -1
- package/out/controller/control/panel/panel/panel-item.controller.js +1 -4
- package/out/controller/control/panel/panel/panel-item.state.d.ts +10 -2
- package/out/controller/control/panel/panel/panel-item.state.d.ts.map +1 -1
- package/out/controller/control/panel/panel/panel-item.state.js +14 -4
- package/out/controller/control/panel/panel/panel.controller.d.ts.map +1 -1
- package/out/controller/control/panel/panel/panel.controller.js +1 -1
- package/out/controller/utils/data-file-util/data-file-util.d.ts +213 -2
- package/out/controller/utils/data-file-util/data-file-util.d.ts.map +1 -1
- package/out/controller/utils/data-file-util/data-file-util.js +353 -8
- package/out/controller/utils/value-rule/value-rule.js +1 -1
- package/out/hub/config/app-view-config-service.d.ts.map +1 -1
- package/out/hub/config/app-view-config-service.js +7 -2
- package/out/interface/common/i-global-config/i-global-config.d.ts +9 -0
- package/out/interface/common/i-global-config/i-global-config.d.ts.map +1 -1
- package/out/interface/common/i-global-config/i-global-picker-editor-config.d.ts +13 -0
- package/out/interface/common/i-global-config/i-global-picker-editor-config.d.ts.map +1 -0
- package/out/interface/common/i-global-config/i-global-picker-editor-config.js +1 -0
- package/out/interface/common/i-global-config/index.d.ts +1 -0
- package/out/interface/common/i-global-config/index.d.ts.map +1 -1
- package/out/interface/common/i-global-config/index.js +1 -0
- package/out/interface/common/index.d.ts +1 -1
- package/out/interface/common/index.d.ts.map +1 -1
- package/out/interface/controller/event/control/i-edit-form.event.d.ts +16 -9
- package/out/interface/controller/event/control/i-edit-form.event.d.ts.map +1 -1
- package/out/interface/controller/state/common/i-controller.state.d.ts +8 -0
- package/out/interface/controller/state/common/i-controller.state.d.ts.map +1 -1
- package/out/interface/controller/state/control/panel-item/i-panel-item.state.d.ts +8 -0
- package/out/interface/controller/state/control/panel-item/i-panel-item.state.d.ts.map +1 -1
- package/out/interface/controller/state/view/i-app-data-upload-view.state.d.ts +26 -0
- package/out/interface/controller/state/view/i-app-data-upload-view.state.d.ts.map +1 -0
- package/out/interface/controller/state/view/i-app-data-upload-view.state.js +1 -0
- package/out/interface/controller/state/view/index.d.ts +1 -0
- package/out/interface/controller/state/view/index.d.ts.map +1 -1
- package/out/interface/controller/state/view/index.js +1 -0
- package/out/interface/register/i-register-params.d.ts +31 -0
- package/out/interface/register/i-register-params.d.ts.map +1 -0
- package/out/interface/register/i-register-params.js +1 -0
- package/out/interface/register/index.d.ts +1 -0
- package/out/interface/register/index.d.ts.map +1 -1
- package/out/interface/register/index.js +1 -0
- package/out/model/data-entity/data-entity.d.ts +10 -1
- package/out/model/data-entity/data-entity.d.ts.map +1 -1
- package/out/model/data-entity/data-entity.js +14 -0
- package/out/register/custom-register.d.ts +34 -0
- package/out/register/custom-register.d.ts.map +1 -0
- package/out/register/custom-register.js +80 -0
- package/out/register/helper/control-register.d.ts.map +1 -1
- package/out/register/helper/control-register.js +12 -0
- package/out/register/helper/form-detail-register.d.ts +2 -2
- package/out/register/helper/form-detail-register.d.ts.map +1 -1
- package/out/register/helper/form-detail-register.js +14 -1
- package/out/register/helper/grid-column-register.d.ts +2 -2
- package/out/register/helper/grid-column-register.d.ts.map +1 -1
- package/out/register/helper/grid-column-register.js +14 -1
- package/out/register/helper/panel-item-register.d.ts +2 -2
- package/out/register/helper/panel-item-register.d.ts.map +1 -1
- package/out/register/helper/panel-item-register.js +15 -1
- package/out/service/utils/dynamic-code-list/dynamic-code-list.d.ts +8 -0
- package/out/service/utils/dynamic-code-list/dynamic-code-list.d.ts.map +1 -1
- package/out/service/utils/dynamic-code-list/dynamic-code-list.js +16 -5
- package/out/service/vo/tree-node-data/tree-data-set-node-data.d.ts.map +1 -1
- package/out/service/vo/tree-node-data/tree-data-set-node-data.js +7 -1
- package/out/ui-action/provider/front-ui-action-provider.d.ts.map +1 -1
- package/out/ui-action/provider/front-ui-action-provider.js +17 -26
- package/package.json +2 -2
package/dist/index.esm.js
CHANGED
|
@@ -25,6 +25,10 @@ var GlobalConfig = class {
|
|
|
25
25
|
this.form = {
|
|
26
26
|
mdCtrlConfirmBeforeRemove: true
|
|
27
27
|
};
|
|
28
|
+
// 全局下拉选择类编辑器配置
|
|
29
|
+
this.pickerEditor = {
|
|
30
|
+
overflowMode: "auto"
|
|
31
|
+
};
|
|
28
32
|
}
|
|
29
33
|
};
|
|
30
34
|
|
|
@@ -1032,6 +1036,14 @@ function findFieldById(entity, fieldId) {
|
|
|
1032
1036
|
var _a;
|
|
1033
1037
|
return (_a = entity.appDEFields) == null ? void 0 : _a.find((item) => item.id === fieldId);
|
|
1034
1038
|
}
|
|
1039
|
+
function getDefaultDataImport(entity) {
|
|
1040
|
+
var _a;
|
|
1041
|
+
if (entity.defaultAppDEDataImportId) {
|
|
1042
|
+
return (_a = entity.appDEDataImports) == null ? void 0 : _a.find(
|
|
1043
|
+
(item) => item.id === entity.defaultAppDEDataImportId
|
|
1044
|
+
);
|
|
1045
|
+
}
|
|
1046
|
+
}
|
|
1035
1047
|
|
|
1036
1048
|
// src/model/ui-action/ui-action.ts
|
|
1037
1049
|
async function getUIActionById(id, appId2) {
|
|
@@ -5503,6 +5515,82 @@ async function getAppCounterProvider(model) {
|
|
|
5503
5515
|
}
|
|
5504
5516
|
}
|
|
5505
5517
|
|
|
5518
|
+
// src/register/custom-register.ts
|
|
5519
|
+
var CustomRegister = class {
|
|
5520
|
+
/**
|
|
5521
|
+
* 获取适配器注册key
|
|
5522
|
+
*
|
|
5523
|
+
* @author ljx
|
|
5524
|
+
* @date 2024-04-16 23:08:08
|
|
5525
|
+
* @param {string} registerType
|
|
5526
|
+
* @param {IRegisterParams} opts
|
|
5527
|
+
* @return {string}
|
|
5528
|
+
*/
|
|
5529
|
+
static getRegisterKey(registerType, opts) {
|
|
5530
|
+
switch (registerType) {
|
|
5531
|
+
case PANELITEM_PROVIDER_PREFIX:
|
|
5532
|
+
return this.calcKeyByView(opts);
|
|
5533
|
+
case FORMDETAIL_PROVIDER_PREFIX:
|
|
5534
|
+
case GRIDCOLUMN_PROVIDER_PREFIX:
|
|
5535
|
+
case CONTROL_PROVIDER_PREFIX:
|
|
5536
|
+
return this.calcKeyByCtrl(opts);
|
|
5537
|
+
default:
|
|
5538
|
+
return "";
|
|
5539
|
+
}
|
|
5540
|
+
}
|
|
5541
|
+
/**
|
|
5542
|
+
* 通过视图计算key
|
|
5543
|
+
* 目前适用于计算面板项的key
|
|
5544
|
+
* @author ljx
|
|
5545
|
+
* @date 2024-04-16 23:08:08
|
|
5546
|
+
* @param {IRegisterParams} opts
|
|
5547
|
+
* @return {string}
|
|
5548
|
+
*/
|
|
5549
|
+
static calcKeyByView(opts) {
|
|
5550
|
+
const { controlItemModel, controlModel, viewModel } = opts;
|
|
5551
|
+
let key = "";
|
|
5552
|
+
if (viewModel == null ? void 0 : viewModel.codeName) {
|
|
5553
|
+
key += "".concat(viewModel.codeName.toUpperCase());
|
|
5554
|
+
}
|
|
5555
|
+
if (controlModel == null ? void 0 : controlModel.codeName) {
|
|
5556
|
+
key += "@".concat(controlModel.codeName.toUpperCase());
|
|
5557
|
+
}
|
|
5558
|
+
if (controlItemModel == null ? void 0 : controlItemModel.id) {
|
|
5559
|
+
key += "@".concat(controlItemModel.id.toUpperCase());
|
|
5560
|
+
}
|
|
5561
|
+
return key;
|
|
5562
|
+
}
|
|
5563
|
+
/**
|
|
5564
|
+
* 通过部件计算key
|
|
5565
|
+
* 没有实体的部件默认为APP
|
|
5566
|
+
* @date 2024-04-16 23:08:08
|
|
5567
|
+
* @param {IRegisterParams} opts
|
|
5568
|
+
* @return {string}
|
|
5569
|
+
*/
|
|
5570
|
+
static calcKeyByCtrl(opts) {
|
|
5571
|
+
const { controlModel, controlItemModel } = opts;
|
|
5572
|
+
let key = "";
|
|
5573
|
+
let prefix = "APP";
|
|
5574
|
+
if (controlModel) {
|
|
5575
|
+
const { appDataEntityId, controlType, codeName } = controlModel;
|
|
5576
|
+
if (appDataEntityId) {
|
|
5577
|
+
prefix = calcDeCodeNameById(appDataEntityId).toUpperCase();
|
|
5578
|
+
}
|
|
5579
|
+
if (controlType) {
|
|
5580
|
+
key += "@".concat(controlType.toUpperCase());
|
|
5581
|
+
}
|
|
5582
|
+
if (codeName) {
|
|
5583
|
+
key += "@".concat(codeName.toUpperCase());
|
|
5584
|
+
}
|
|
5585
|
+
}
|
|
5586
|
+
if (controlItemModel == null ? void 0 : controlItemModel.codeName) {
|
|
5587
|
+
key += "@".concat(controlItemModel.codeName.toUpperCase());
|
|
5588
|
+
}
|
|
5589
|
+
key = prefix + key;
|
|
5590
|
+
return key;
|
|
5591
|
+
}
|
|
5592
|
+
};
|
|
5593
|
+
|
|
5506
5594
|
// src/register/helper/control-register.ts
|
|
5507
5595
|
var CONTROL_PROVIDER_PREFIX = "CONTROL";
|
|
5508
5596
|
function registerControlProvider(key, callback) {
|
|
@@ -5516,6 +5604,15 @@ function getProvider2(key) {
|
|
|
5516
5604
|
async function getControlProvider(model) {
|
|
5517
5605
|
let provider;
|
|
5518
5606
|
const { controlType, controlStyle, sysPFPluginId, appId: appId2 } = model;
|
|
5607
|
+
const registerKey = CustomRegister.getRegisterKey(CONTROL_PROVIDER_PREFIX, {
|
|
5608
|
+
controlModel: model
|
|
5609
|
+
});
|
|
5610
|
+
provider = getProvider2(registerKey);
|
|
5611
|
+
if (!provider) {
|
|
5612
|
+
ibiz.log.debug("\u627E\u4E0D\u5230\u81EA\u5B9A\u4E49\u6CE8\u518C\u6807\u8BC6\u4E3A[".concat(registerKey, "]\u5BF9\u5E94\u7684\u9002\u914D\u5668"));
|
|
5613
|
+
} else {
|
|
5614
|
+
return provider;
|
|
5615
|
+
}
|
|
5519
5616
|
if (sysPFPluginId) {
|
|
5520
5617
|
const pluginKey = await getPluginRegisterKey(sysPFPluginId, appId2);
|
|
5521
5618
|
if (pluginKey) {
|
|
@@ -5621,9 +5718,22 @@ function getProvider4(key) {
|
|
|
5621
5718
|
"".concat(FORMDETAIL_PROVIDER_PREFIX, "_").concat(key)
|
|
5622
5719
|
);
|
|
5623
5720
|
}
|
|
5624
|
-
async function getFormDetailProvider(model) {
|
|
5721
|
+
async function getFormDetailProvider(model, formModel) {
|
|
5625
5722
|
let provider;
|
|
5626
5723
|
const { detailType, sysPFPluginId, appId: appId2 } = model;
|
|
5724
|
+
const registerKey = CustomRegister.getRegisterKey(
|
|
5725
|
+
FORMDETAIL_PROVIDER_PREFIX,
|
|
5726
|
+
{
|
|
5727
|
+
controlItemModel: model,
|
|
5728
|
+
controlModel: formModel
|
|
5729
|
+
}
|
|
5730
|
+
);
|
|
5731
|
+
provider = getProvider4(registerKey);
|
|
5732
|
+
if (!provider) {
|
|
5733
|
+
ibiz.log.debug("\u627E\u4E0D\u5230\u81EA\u5B9A\u4E49\u6CE8\u518C\u6807\u8BC6\u4E3A[".concat(registerKey, "]\u5BF9\u5E94\u7684\u9002\u914D\u5668"));
|
|
5734
|
+
} else {
|
|
5735
|
+
return provider;
|
|
5736
|
+
}
|
|
5627
5737
|
if (sysPFPluginId) {
|
|
5628
5738
|
const pluginKey = await getPluginRegisterKey(sysPFPluginId, appId2);
|
|
5629
5739
|
if (pluginKey) {
|
|
@@ -5653,9 +5763,22 @@ function getProvider5(key) {
|
|
|
5653
5763
|
"".concat(GRIDCOLUMN_PROVIDER_PREFIX, "_").concat(key)
|
|
5654
5764
|
);
|
|
5655
5765
|
}
|
|
5656
|
-
async function getGridColumnProvider(model) {
|
|
5766
|
+
async function getGridColumnProvider(model, gridModel) {
|
|
5657
5767
|
let provider;
|
|
5658
5768
|
const { columnType, enableRowEdit, sysPFPluginId, appId: appId2 } = model;
|
|
5769
|
+
const registerKey = CustomRegister.getRegisterKey(
|
|
5770
|
+
GRIDCOLUMN_PROVIDER_PREFIX,
|
|
5771
|
+
{
|
|
5772
|
+
controlItemModel: model,
|
|
5773
|
+
controlModel: gridModel
|
|
5774
|
+
}
|
|
5775
|
+
);
|
|
5776
|
+
provider = getProvider5(registerKey);
|
|
5777
|
+
if (!provider) {
|
|
5778
|
+
ibiz.log.debug("\u627E\u4E0D\u5230\u81EA\u5B9A\u4E49\u6CE8\u518C\u6807\u8BC6\u4E3A[".concat(registerKey, "]\u5BF9\u5E94\u7684\u9002\u914D\u5668"));
|
|
5779
|
+
} else {
|
|
5780
|
+
return provider;
|
|
5781
|
+
}
|
|
5659
5782
|
if (sysPFPluginId) {
|
|
5660
5783
|
const pluginKey = await getPluginRegisterKey(sysPFPluginId, appId2);
|
|
5661
5784
|
if (pluginKey) {
|
|
@@ -5689,10 +5812,21 @@ function getProvider6(key) {
|
|
|
5689
5812
|
"".concat(PANELITEM_PROVIDER_PREFIX, "_").concat(key.toUpperCase())
|
|
5690
5813
|
);
|
|
5691
5814
|
}
|
|
5692
|
-
async function getPanelItemProvider(model) {
|
|
5815
|
+
async function getPanelItemProvider(model, panelModel, viewModel) {
|
|
5693
5816
|
var _a;
|
|
5694
5817
|
let provider;
|
|
5695
5818
|
const { itemType, sysPFPluginId, appId: appId2, controlRenders } = model;
|
|
5819
|
+
const registerKey = CustomRegister.getRegisterKey(PANELITEM_PROVIDER_PREFIX, {
|
|
5820
|
+
controlItemModel: model,
|
|
5821
|
+
controlModel: panelModel,
|
|
5822
|
+
viewModel
|
|
5823
|
+
});
|
|
5824
|
+
provider = getProvider6(registerKey);
|
|
5825
|
+
if (!provider) {
|
|
5826
|
+
ibiz.log.debug("\u627E\u4E0D\u5230\u81EA\u5B9A\u4E49\u6CE8\u518C\u6807\u8BC6\u4E3A[".concat(registerKey, "]\u5BF9\u5E94\u7684\u9002\u914D\u5668"));
|
|
5827
|
+
} else {
|
|
5828
|
+
return provider;
|
|
5829
|
+
}
|
|
5696
5830
|
if (sysPFPluginId) {
|
|
5697
5831
|
const pluginKey = await getPluginRegisterKey(sysPFPluginId, appId2);
|
|
5698
5832
|
if (pluginKey) {
|
|
@@ -6532,6 +6666,14 @@ var DynamicCodeListCache = class {
|
|
|
6532
6666
|
* @protected
|
|
6533
6667
|
*/
|
|
6534
6668
|
this.evt = new QXEvent3();
|
|
6669
|
+
/**
|
|
6670
|
+
* 常见关键字
|
|
6671
|
+
*
|
|
6672
|
+
* @author zzq
|
|
6673
|
+
* @date 2024-04-15 17:08:06
|
|
6674
|
+
* @type {Promise<void>}
|
|
6675
|
+
*/
|
|
6676
|
+
this.commonKeys = ["query", "queryconds"];
|
|
6535
6677
|
this.codeList = codeList;
|
|
6536
6678
|
this.codelistChange = this.codelistChange.bind(this);
|
|
6537
6679
|
const { appDataEntityId, appDEDataSetId } = this.codeList;
|
|
@@ -6646,15 +6788,15 @@ var DynamicCodeListCache = class {
|
|
|
6646
6788
|
}
|
|
6647
6789
|
presetconvertData(data) {
|
|
6648
6790
|
const result = {};
|
|
6649
|
-
const { color, bkcolor, disabled, id, text,
|
|
6791
|
+
const { color, bkcolor, disabled, id, text, value, cls } = data;
|
|
6650
6792
|
result.value = value;
|
|
6651
6793
|
result.color = color;
|
|
6652
6794
|
result.bkcolor = bkcolor;
|
|
6653
6795
|
result.text = text;
|
|
6654
6796
|
result.id = id;
|
|
6655
|
-
result.id = label;
|
|
6656
6797
|
result.disableSelect = disabled;
|
|
6657
6798
|
result.cls = cls;
|
|
6799
|
+
result.data = data;
|
|
6658
6800
|
return result;
|
|
6659
6801
|
}
|
|
6660
6802
|
sortShoworder(arr) {
|
|
@@ -6676,7 +6818,11 @@ var DynamicCodeListCache = class {
|
|
|
6676
6818
|
* @returns {*} {Promise<CodeListItem[]>}
|
|
6677
6819
|
*/
|
|
6678
6820
|
async load(context, params = {}) {
|
|
6679
|
-
|
|
6821
|
+
const tempParams = { ...params };
|
|
6822
|
+
this.commonKeys.forEach((key) => {
|
|
6823
|
+
delete tempParams[key];
|
|
6824
|
+
});
|
|
6825
|
+
this.setParams(context, tempParams);
|
|
6680
6826
|
const app = ibiz.hub.getApp(context.srfappid);
|
|
6681
6827
|
const {
|
|
6682
6828
|
appDataEntityId,
|
|
@@ -6686,7 +6832,6 @@ var DynamicCodeListCache = class {
|
|
|
6686
6832
|
pvalueAppDEFieldId,
|
|
6687
6833
|
customCond
|
|
6688
6834
|
} = this.codeList;
|
|
6689
|
-
const tempParams = { ...params };
|
|
6690
6835
|
if (minorSortAppDEFieldId && minorSortDir) {
|
|
6691
6836
|
Object.assign(tempParams, {
|
|
6692
6837
|
sort: "".concat(minorSortAppDEFieldId.toLowerCase(), ",").concat(minorSortDir.toLowerCase())
|
|
@@ -12533,7 +12678,12 @@ var TreeDataSetNodeData = class _TreeDataSetNodeData extends TreeNodeData {
|
|
|
12533
12678
|
const icon = super.calcIcon(model) || {};
|
|
12534
12679
|
const { iconAppDEFieldId, detreeNodeDataItems } = model;
|
|
12535
12680
|
if (iconAppDEFieldId && this._deData[iconAppDEFieldId]) {
|
|
12536
|
-
|
|
12681
|
+
const value = this._deData[iconAppDEFieldId];
|
|
12682
|
+
if (value.indexOf("fa-") !== -1) {
|
|
12683
|
+
icon.cssClass = value;
|
|
12684
|
+
} else {
|
|
12685
|
+
icon.imagePath = value;
|
|
12686
|
+
}
|
|
12537
12687
|
}
|
|
12538
12688
|
if (icon) {
|
|
12539
12689
|
this._icon = icon;
|
|
@@ -13885,10 +14035,13 @@ var AppViewConfigService = class {
|
|
|
13885
14035
|
*/
|
|
13886
14036
|
getCustomOption(model) {
|
|
13887
14037
|
var _a;
|
|
13888
|
-
const { appViewParams } = model;
|
|
13889
|
-
|
|
14038
|
+
const { appViewParams, userParam } = model;
|
|
14039
|
+
let optionProperty = (_a = appViewParams == null ? void 0 : appViewParams.find(
|
|
13890
14040
|
(item) => item.id === "modaloption"
|
|
13891
14041
|
)) == null ? void 0 : _a.value;
|
|
14042
|
+
if (!optionProperty && userParam) {
|
|
14043
|
+
optionProperty = userParam.modalOption;
|
|
14044
|
+
}
|
|
13892
14045
|
let modalOption = {};
|
|
13893
14046
|
if (optionProperty) {
|
|
13894
14047
|
try {
|
|
@@ -14648,7 +14801,7 @@ function generateRules(itemVRs, name, valueItemName) {
|
|
|
14648
14801
|
const sysRule = item.sysValueRule;
|
|
14649
14802
|
const deRule = item.defvalueRule;
|
|
14650
14803
|
if (valueRuleType === "SYSVALUERULE" && sysRule) {
|
|
14651
|
-
if (sysRule.ruleType === "REG") {
|
|
14804
|
+
if (sysRule.ruleType === "REG" || sysRule.ruleType === "REGEX") {
|
|
14652
14805
|
rules.push({
|
|
14653
14806
|
pattern: new RegExp(sysRule.regExCode),
|
|
14654
14807
|
message: sysRule.ruleInfo,
|
|
@@ -14861,8 +15014,10 @@ function getDefaultValue(opts, origins) {
|
|
|
14861
15014
|
|
|
14862
15015
|
// src/controller/utils/data-file-util/data-file-util.ts
|
|
14863
15016
|
import {
|
|
14864
|
-
RuntimeError as RuntimeError32
|
|
15017
|
+
RuntimeError as RuntimeError32,
|
|
15018
|
+
selectFile
|
|
14865
15019
|
} from "@ibiz-template/core";
|
|
15020
|
+
import { mergeRight as mergeRight2 } from "ramda";
|
|
14866
15021
|
var asyncImportUrl = "asyncimportdata2";
|
|
14867
15022
|
var importUrl = "importdata2";
|
|
14868
15023
|
function listenAsyncAction(id) {
|
|
@@ -14882,6 +15037,9 @@ function listenAsyncAction(id) {
|
|
|
14882
15037
|
});
|
|
14883
15038
|
}
|
|
14884
15039
|
async function asyncImportData(file, appDataEntity, dataImport, context) {
|
|
15040
|
+
ibiz.notification.info({
|
|
15041
|
+
desc: ibiz.i18n.t("component.dataImport.startImport")
|
|
15042
|
+
});
|
|
14885
15043
|
const data = new FormData();
|
|
14886
15044
|
data.append("file", file);
|
|
14887
15045
|
let url = "/".concat(appDataEntity.deapicodeName2, "/").concat(asyncImportUrl);
|
|
@@ -14915,12 +15073,49 @@ async function importData(file, appDataEntity, dataImport, context) {
|
|
|
14915
15073
|
const resPath = calcResPath(context, appDataEntity);
|
|
14916
15074
|
url = resPath + url;
|
|
14917
15075
|
}
|
|
14918
|
-
const
|
|
14919
|
-
|
|
14920
|
-
|
|
14921
|
-
|
|
14922
|
-
|
|
14923
|
-
|
|
15076
|
+
const result = {
|
|
15077
|
+
isAsync: false
|
|
15078
|
+
};
|
|
15079
|
+
try {
|
|
15080
|
+
const res = await ibiz.net.request(url, {
|
|
15081
|
+
method: "post",
|
|
15082
|
+
data,
|
|
15083
|
+
headers: { "Content-Type": "multipart/form-data" }
|
|
15084
|
+
});
|
|
15085
|
+
ibiz.mc.command.send(
|
|
15086
|
+
{ srfdecodename: appDataEntity.codeName },
|
|
15087
|
+
"OBJECTCREATED",
|
|
15088
|
+
"DATAIMPORT"
|
|
15089
|
+
);
|
|
15090
|
+
Object.assign(result, res.data);
|
|
15091
|
+
} catch (error) {
|
|
15092
|
+
if (error instanceof Error) {
|
|
15093
|
+
result.errorMessage = error.message;
|
|
15094
|
+
}
|
|
15095
|
+
}
|
|
15096
|
+
return result;
|
|
15097
|
+
}
|
|
15098
|
+
async function importData2(opts) {
|
|
15099
|
+
const result = {
|
|
15100
|
+
isAsync: ibiz.env.enableMqtt
|
|
15101
|
+
};
|
|
15102
|
+
if (ibiz.env.enableMqtt) {
|
|
15103
|
+
asyncImportData(
|
|
15104
|
+
opts.selectedFile,
|
|
15105
|
+
opts.appDataEntity,
|
|
15106
|
+
opts.dataImport,
|
|
15107
|
+
opts.context
|
|
15108
|
+
);
|
|
15109
|
+
} else {
|
|
15110
|
+
const temp = await importData(
|
|
15111
|
+
opts.selectedFile,
|
|
15112
|
+
opts.appDataEntity,
|
|
15113
|
+
opts.dataImport,
|
|
15114
|
+
opts.context
|
|
15115
|
+
);
|
|
15116
|
+
Object.assign(result, temp);
|
|
15117
|
+
}
|
|
15118
|
+
return result;
|
|
14924
15119
|
}
|
|
14925
15120
|
async function exportData(header, data, fileName) {
|
|
14926
15121
|
if (!ibiz.util.getExcelUtil) {
|
|
@@ -14946,6 +15141,195 @@ async function exportData(header, data, fileName) {
|
|
|
14946
15141
|
return { ok: false };
|
|
14947
15142
|
}
|
|
14948
15143
|
}
|
|
15144
|
+
async function getDataImportModels(opts) {
|
|
15145
|
+
var _a;
|
|
15146
|
+
const appDataEntity = await ibiz.hub.getAppDataEntity(
|
|
15147
|
+
opts.appDataEntityId,
|
|
15148
|
+
opts.appId
|
|
15149
|
+
);
|
|
15150
|
+
const deDataImport = (_a = appDataEntity.appDEDataImports) == null ? void 0 : _a.find(
|
|
15151
|
+
(item) => item.id === opts.deDataImportId
|
|
15152
|
+
);
|
|
15153
|
+
if (!deDataImport) {
|
|
15154
|
+
throw new RuntimeError32("\u6CA1\u6709\u627E\u5230\u5BF9\u5E94\u7684\u5BFC\u5165\u6570\u636E\u6A21\u578B");
|
|
15155
|
+
}
|
|
15156
|
+
return { deDataImport, appDataEntity };
|
|
15157
|
+
}
|
|
15158
|
+
async function openDataImport(opts) {
|
|
15159
|
+
const { deDataImportId, appDataEntityId, context, params } = opts;
|
|
15160
|
+
const viewId = opts.dataImportViewId || "AppDataUploadView";
|
|
15161
|
+
let view = null;
|
|
15162
|
+
try {
|
|
15163
|
+
view = await ibiz.hub.config.view.get(viewId);
|
|
15164
|
+
} catch (error) {
|
|
15165
|
+
if (opts.dataImportViewId) {
|
|
15166
|
+
throw error;
|
|
15167
|
+
}
|
|
15168
|
+
}
|
|
15169
|
+
if (view) {
|
|
15170
|
+
context.srfappdataentityid = appDataEntityId;
|
|
15171
|
+
context.srfdedataimportid = deDataImportId;
|
|
15172
|
+
return ibiz.commands.execute(
|
|
15173
|
+
OpenAppViewCommand.TAG,
|
|
15174
|
+
view.id,
|
|
15175
|
+
context,
|
|
15176
|
+
params,
|
|
15177
|
+
{ openMode: "POPUPMODAL" }
|
|
15178
|
+
);
|
|
15179
|
+
}
|
|
15180
|
+
const { deDataImport, appDataEntity } = await getDataImportModels({
|
|
15181
|
+
deDataImportId,
|
|
15182
|
+
appDataEntityId,
|
|
15183
|
+
appId: context.srfappid
|
|
15184
|
+
});
|
|
15185
|
+
const importComponentName = deDataImport.enableCustomized ? "DataImport2" : "DataImport";
|
|
15186
|
+
const modal = ibiz.overlay.createModal(
|
|
15187
|
+
importComponentName,
|
|
15188
|
+
{
|
|
15189
|
+
dismiss: () => modal.dismiss(),
|
|
15190
|
+
dataImport: deDataImport,
|
|
15191
|
+
appDataEntity,
|
|
15192
|
+
context,
|
|
15193
|
+
params
|
|
15194
|
+
},
|
|
15195
|
+
{
|
|
15196
|
+
width: "auto",
|
|
15197
|
+
placement: "center"
|
|
15198
|
+
}
|
|
15199
|
+
);
|
|
15200
|
+
modal.present();
|
|
15201
|
+
await modal.onWillDismiss();
|
|
15202
|
+
}
|
|
15203
|
+
async function downloadImportTemplate(appDataEntity, dataImport) {
|
|
15204
|
+
var _a;
|
|
15205
|
+
let templateUrl = "".concat(appDataEntity.codeName2.toLowerCase(), "/importtemplate");
|
|
15206
|
+
if (dataImport == null ? void 0 : dataImport.codeName) {
|
|
15207
|
+
templateUrl += "?srfimporttag=".concat(dataImport.codeName);
|
|
15208
|
+
}
|
|
15209
|
+
const res = await ibiz.net.request(templateUrl, {
|
|
15210
|
+
responseType: "blob"
|
|
15211
|
+
});
|
|
15212
|
+
if (res.status === 200) {
|
|
15213
|
+
let fileName = ((_a = res.headers["content-disposition"].split(";").find((str) => str.indexOf("filename=") !== -1)) == null ? void 0 : _a.slice(9)) || "";
|
|
15214
|
+
fileName = decodeURIComponent(fileName);
|
|
15215
|
+
const blob = new Blob([res.data], {
|
|
15216
|
+
type: "application/vnd.ms-excel"
|
|
15217
|
+
});
|
|
15218
|
+
const elink = document.createElement("a");
|
|
15219
|
+
elink.download = fileName;
|
|
15220
|
+
elink.style.display = "none";
|
|
15221
|
+
elink.href = URL.createObjectURL(blob);
|
|
15222
|
+
document.body.appendChild(elink);
|
|
15223
|
+
elink.click();
|
|
15224
|
+
URL.revokeObjectURL(elink.href);
|
|
15225
|
+
document.body.removeChild(elink);
|
|
15226
|
+
}
|
|
15227
|
+
}
|
|
15228
|
+
async function selectAndImport(opts) {
|
|
15229
|
+
return new Promise((resolve) => {
|
|
15230
|
+
selectFile({
|
|
15231
|
+
accept: ".xlsx, .xls",
|
|
15232
|
+
multiple: false,
|
|
15233
|
+
onSelected: async (files) => {
|
|
15234
|
+
const result = await importData2({
|
|
15235
|
+
selectedFile: files[0],
|
|
15236
|
+
appDataEntity: opts.appDataEntity,
|
|
15237
|
+
dataImport: opts.dataImport,
|
|
15238
|
+
context: opts.context
|
|
15239
|
+
});
|
|
15240
|
+
resolve(result);
|
|
15241
|
+
},
|
|
15242
|
+
onCancel: () => {
|
|
15243
|
+
resolve({ cancel: true });
|
|
15244
|
+
}
|
|
15245
|
+
});
|
|
15246
|
+
});
|
|
15247
|
+
}
|
|
15248
|
+
async function asyncImportData2(opts) {
|
|
15249
|
+
var _a;
|
|
15250
|
+
let path2 = "/".concat(opts.appDataEntity.codeName2.toLowerCase());
|
|
15251
|
+
if (opts.context) {
|
|
15252
|
+
const resPath = calcResPath(opts.context, opts.appDataEntity);
|
|
15253
|
+
path2 = resPath + path2;
|
|
15254
|
+
}
|
|
15255
|
+
const url = "".concat(path2, "/asyncimportdata2");
|
|
15256
|
+
const queryData = {
|
|
15257
|
+
srfossfileid: opts.fileId,
|
|
15258
|
+
srfimportschemaid: opts.schemaId
|
|
15259
|
+
};
|
|
15260
|
+
const srfimporttag = ((_a = opts.dataImport) == null ? void 0 : _a.id) || opts.appDataEntity.defaultAppDEDataImportId;
|
|
15261
|
+
if (srfimporttag) {
|
|
15262
|
+
Object.assign(queryData, { srfimporttag });
|
|
15263
|
+
}
|
|
15264
|
+
await ibiz.net.request(url, {
|
|
15265
|
+
method: "get",
|
|
15266
|
+
params: queryData
|
|
15267
|
+
});
|
|
15268
|
+
ibiz.notification.info({
|
|
15269
|
+
desc: ibiz.i18n.t("component.dataImport.startImport")
|
|
15270
|
+
});
|
|
15271
|
+
}
|
|
15272
|
+
function calcImportSchemaData(opts) {
|
|
15273
|
+
var _a, _b, _c, _d;
|
|
15274
|
+
let data = {
|
|
15275
|
+
system_tag: (_a = ibiz.appData) == null ? void 0 : _a.context.srfsystemid,
|
|
15276
|
+
// 系统标记
|
|
15277
|
+
data_entity_tag: (_b = opts.appDataEntity) == null ? void 0 : _b.codeName,
|
|
15278
|
+
// 数据实体标记
|
|
15279
|
+
import_tag: ((_c = opts.dataImport) == null ? void 0 : _c.id) || ((_d = opts.appDataEntity) == null ? void 0 : _d.defaultAppDEDataImportId),
|
|
15280
|
+
// 导入标记 导入模型的代码名称
|
|
15281
|
+
owner_type: "PERSONAL"
|
|
15282
|
+
// 所有者类型
|
|
15283
|
+
};
|
|
15284
|
+
data = mergeRight2(data, opts.data);
|
|
15285
|
+
return data;
|
|
15286
|
+
}
|
|
15287
|
+
async function createImportSchema(opts) {
|
|
15288
|
+
const data = calcImportSchemaData(opts);
|
|
15289
|
+
const url = "extension/import_schemas";
|
|
15290
|
+
const res = await ibiz.net.request(url, {
|
|
15291
|
+
method: "post",
|
|
15292
|
+
data
|
|
15293
|
+
});
|
|
15294
|
+
return res;
|
|
15295
|
+
}
|
|
15296
|
+
async function updateImportSchema(opts) {
|
|
15297
|
+
const data = calcImportSchemaData(opts);
|
|
15298
|
+
const url = "extension/import_schemas/".concat(data.id);
|
|
15299
|
+
const res = await ibiz.net.request(url, {
|
|
15300
|
+
method: "put",
|
|
15301
|
+
data
|
|
15302
|
+
});
|
|
15303
|
+
return res;
|
|
15304
|
+
}
|
|
15305
|
+
async function getImportSchema(id) {
|
|
15306
|
+
const url = "extension/import_schemas/".concat(id);
|
|
15307
|
+
const res = await ibiz.net.request(url, {
|
|
15308
|
+
method: "get"
|
|
15309
|
+
});
|
|
15310
|
+
return res;
|
|
15311
|
+
}
|
|
15312
|
+
async function deleteImportSchema(id) {
|
|
15313
|
+
const url = "extension/import_schemas/".concat(id);
|
|
15314
|
+
const res = await ibiz.net.request(url, {
|
|
15315
|
+
method: "delete"
|
|
15316
|
+
});
|
|
15317
|
+
return res;
|
|
15318
|
+
}
|
|
15319
|
+
async function fetchImportSchemas(opts) {
|
|
15320
|
+
var _a;
|
|
15321
|
+
const params = {
|
|
15322
|
+
n_import_tag_eq: opts.appDataEntity.defaultAppDEDataImportId,
|
|
15323
|
+
n_system_tag_eq: (_a = ibiz.appData) == null ? void 0 : _a.context.srfsystemid,
|
|
15324
|
+
n_data_entity_tag_eq: opts.appDataEntity.codeName
|
|
15325
|
+
};
|
|
15326
|
+
const url = "extension/import_schemas/fetch_cur_user";
|
|
15327
|
+
const res = await ibiz.net.request(url, {
|
|
15328
|
+
method: "post",
|
|
15329
|
+
data: params
|
|
15330
|
+
});
|
|
15331
|
+
return res;
|
|
15332
|
+
}
|
|
14949
15333
|
|
|
14950
15334
|
// src/controller/utils/jsonschema/entity.ts
|
|
14951
15335
|
async function getEntitySchema(entityId, context) {
|
|
@@ -14970,7 +15354,6 @@ var BaseController = class {
|
|
|
14970
15354
|
*/
|
|
14971
15355
|
constructor(model, context, params, ctx) {
|
|
14972
15356
|
this.model = model;
|
|
14973
|
-
this.context = context;
|
|
14974
15357
|
this.params = params;
|
|
14975
15358
|
this.ctx = ctx;
|
|
14976
15359
|
this.id = createUUID9();
|
|
@@ -15006,6 +15389,7 @@ var BaseController = class {
|
|
|
15006
15389
|
*/
|
|
15007
15390
|
this.childNames = [];
|
|
15008
15391
|
this.name = model.name || model.id;
|
|
15392
|
+
this.state.context = context;
|
|
15009
15393
|
this.preprocessModel(model);
|
|
15010
15394
|
this.initState();
|
|
15011
15395
|
this.convertMultipleLanguages();
|
|
@@ -15020,6 +15404,17 @@ var BaseController = class {
|
|
|
15020
15404
|
get _evt() {
|
|
15021
15405
|
return this.evt;
|
|
15022
15406
|
}
|
|
15407
|
+
/**
|
|
15408
|
+
* 上下文对象
|
|
15409
|
+
*
|
|
15410
|
+
* @author tony001
|
|
15411
|
+
* @date 2024-04-16 16:04:30
|
|
15412
|
+
* @readonly
|
|
15413
|
+
* @type {IContext}
|
|
15414
|
+
*/
|
|
15415
|
+
get context() {
|
|
15416
|
+
return this.state.context;
|
|
15417
|
+
}
|
|
15023
15418
|
/**
|
|
15024
15419
|
* 根据需求对model进行预处理
|
|
15025
15420
|
*
|
|
@@ -15188,7 +15583,7 @@ var BaseController = class {
|
|
|
15188
15583
|
|
|
15189
15584
|
// src/controller/utils/view-msg/view-msg-controller.ts
|
|
15190
15585
|
import { RuntimeError as RuntimeError33, RuntimeModelError as RuntimeModelError24 } from "@ibiz-template/core";
|
|
15191
|
-
import { isNil as isNil21, mergeRight as
|
|
15586
|
+
import { isNil as isNil21, mergeRight as mergeRight3 } from "ramda";
|
|
15192
15587
|
var ViewMsgController = class _ViewMsgController {
|
|
15193
15588
|
constructor(msgGroupId) {
|
|
15194
15589
|
this.msgGroupId = msgGroupId;
|
|
@@ -15388,7 +15783,7 @@ var ViewMsgController = class _ViewMsgController {
|
|
|
15388
15783
|
if (removeModeField && !isNil21(item[removeModeField])) {
|
|
15389
15784
|
message.removeMode = item[removeModeField];
|
|
15390
15785
|
}
|
|
15391
|
-
return
|
|
15786
|
+
return mergeRight3(basicMsg, message);
|
|
15392
15787
|
});
|
|
15393
15788
|
return deViewMessages;
|
|
15394
15789
|
}
|
|
@@ -15635,6 +16030,9 @@ var ViewController = class extends BaseController {
|
|
|
15635
16030
|
context = convertNavData(navContexts, this.params, this.context);
|
|
15636
16031
|
}
|
|
15637
16032
|
Object.assign(this.context, context);
|
|
16033
|
+
if (!Object.prototype.hasOwnProperty.call(this.context, "srfreadonly")) {
|
|
16034
|
+
Object.assign(this.context, { srfreadonly: false });
|
|
16035
|
+
}
|
|
15638
16036
|
const navParams = this.model.appViewNavParams;
|
|
15639
16037
|
let params = {};
|
|
15640
16038
|
if (notNilEmpty7(navParams)) {
|
|
@@ -15739,6 +16137,11 @@ var ViewController = class extends BaseController {
|
|
|
15739
16137
|
const modalParams = {
|
|
15740
16138
|
title: message.title,
|
|
15741
16139
|
desc: message.message
|
|
16140
|
+
// todo 待模型修复
|
|
16141
|
+
// options: {
|
|
16142
|
+
// showClose: message.removeMode !== 0,
|
|
16143
|
+
// showConfirmButton: message.removeMode !== 0,
|
|
16144
|
+
// },
|
|
15742
16145
|
};
|
|
15743
16146
|
if (message.extraParams.userTag) {
|
|
15744
16147
|
Object.assign(modalParams, {
|
|
@@ -15772,6 +16175,68 @@ var ViewController = class extends BaseController {
|
|
|
15772
16175
|
}
|
|
15773
16176
|
};
|
|
15774
16177
|
|
|
16178
|
+
// src/controller/common/view/app-data-upload-view.controller.ts
|
|
16179
|
+
var AppDataUploadViewController = class extends ViewController {
|
|
16180
|
+
initState() {
|
|
16181
|
+
super.initState();
|
|
16182
|
+
}
|
|
16183
|
+
async onCreated() {
|
|
16184
|
+
await super.onCreated();
|
|
16185
|
+
const { srfappdataentityid, srfdedataimportid, srfappid } = this.context;
|
|
16186
|
+
const { appDataEntity, deDataImport } = await getDataImportModels({
|
|
16187
|
+
appDataEntityId: srfappdataentityid,
|
|
16188
|
+
deDataImportId: srfdedataimportid,
|
|
16189
|
+
appId: srfappid
|
|
16190
|
+
});
|
|
16191
|
+
this.state.appDataEntity = appDataEntity;
|
|
16192
|
+
this.state.deDataImport = deDataImport;
|
|
16193
|
+
}
|
|
16194
|
+
/**
|
|
16195
|
+
* 下载模版文件
|
|
16196
|
+
* @author lxm
|
|
16197
|
+
* @date 2024-04-16 02:15:29
|
|
16198
|
+
*/
|
|
16199
|
+
downloadTemplate() {
|
|
16200
|
+
const { appDataEntity, deDataImport } = this.state;
|
|
16201
|
+
downloadImportTemplate(appDataEntity, deDataImport);
|
|
16202
|
+
}
|
|
16203
|
+
/**
|
|
16204
|
+
* 选中导入文件并导入
|
|
16205
|
+
* @author lxm
|
|
16206
|
+
* @date 2024-04-16 03:54:19
|
|
16207
|
+
* @return {*}
|
|
16208
|
+
*/
|
|
16209
|
+
async selectAndImport() {
|
|
16210
|
+
const result = await selectAndImport({
|
|
16211
|
+
appDataEntity: this.state.appDataEntity,
|
|
16212
|
+
dataImport: this.state.deDataImport,
|
|
16213
|
+
context: this.context
|
|
16214
|
+
});
|
|
16215
|
+
if (result.isAsync === true) {
|
|
16216
|
+
this.closeView();
|
|
16217
|
+
}
|
|
16218
|
+
return result;
|
|
16219
|
+
}
|
|
16220
|
+
/**
|
|
16221
|
+
* 自定义导入数据方法
|
|
16222
|
+
* @author lxm
|
|
16223
|
+
* @date 2024-04-18 05:17:22
|
|
16224
|
+
* @param {{
|
|
16225
|
+
* fileId: string;
|
|
16226
|
+
* schemaId: string;
|
|
16227
|
+
* }} opts
|
|
16228
|
+
* @return {*} {Promise<void>}
|
|
16229
|
+
*/
|
|
16230
|
+
async asyncImportData2(opts) {
|
|
16231
|
+
return asyncImportData2({
|
|
16232
|
+
appDataEntity: this.state.appDataEntity,
|
|
16233
|
+
dataImport: this.state.deDataImport,
|
|
16234
|
+
context: this.context,
|
|
16235
|
+
...opts
|
|
16236
|
+
});
|
|
16237
|
+
}
|
|
16238
|
+
};
|
|
16239
|
+
|
|
15775
16240
|
// src/controller/common/view/mob-view.controller.ts
|
|
15776
16241
|
var MobViewController = class extends ViewController {
|
|
15777
16242
|
};
|
|
@@ -16474,7 +16939,8 @@ var ControlController = class extends BaseController {
|
|
|
16474
16939
|
// src/controller/common/control/md-control.controller.ts
|
|
16475
16940
|
import {
|
|
16476
16941
|
isElementSame,
|
|
16477
|
-
RuntimeError as RuntimeError36
|
|
16942
|
+
RuntimeError as RuntimeError36,
|
|
16943
|
+
RuntimeModelError as RuntimeModelError26
|
|
16478
16944
|
} from "@ibiz-template/core";
|
|
16479
16945
|
import { isNil as isNil24 } from "ramda";
|
|
16480
16946
|
var MDControlController = class extends ControlController {
|
|
@@ -16886,38 +17352,16 @@ var MDControlController = class extends ControlController {
|
|
|
16886
17352
|
* @returns {*} {Promise<void>}
|
|
16887
17353
|
*/
|
|
16888
17354
|
async importData() {
|
|
16889
|
-
var _a;
|
|
16890
17355
|
const { appDataEntityId, dedataImportId } = this.model;
|
|
16891
|
-
|
|
16892
|
-
|
|
16893
|
-
this.model.appId
|
|
16894
|
-
);
|
|
16895
|
-
const dataImport = (_a = appDataEntity.appDEDataImports) == null ? void 0 : _a.find(
|
|
16896
|
-
(importItem) => importItem.id === dedataImportId
|
|
16897
|
-
);
|
|
16898
|
-
if (!dataImport) {
|
|
16899
|
-
throw new RuntimeError36("\u65E0\u5BFC\u5165\u6A21\u578B\uFF01");
|
|
16900
|
-
}
|
|
16901
|
-
let importName = "DataImport";
|
|
16902
|
-
if (dataImport.enableCustomized) {
|
|
16903
|
-
importName = "DataImport2";
|
|
17356
|
+
if (!appDataEntityId || !dedataImportId) {
|
|
17357
|
+
throw new RuntimeModelError26(this.model, "\u6CA1\u6709\u914D\u7F6E\u5BFC\u5165\u6A21\u578B\uFF01");
|
|
16904
17358
|
}
|
|
16905
|
-
|
|
16906
|
-
|
|
16907
|
-
|
|
16908
|
-
|
|
16909
|
-
|
|
16910
|
-
|
|
16911
|
-
context: this.context,
|
|
16912
|
-
params: this.params
|
|
16913
|
-
},
|
|
16914
|
-
{
|
|
16915
|
-
width: "auto",
|
|
16916
|
-
placement: "center"
|
|
16917
|
-
}
|
|
16918
|
-
);
|
|
16919
|
-
modal.present();
|
|
16920
|
-
await modal.onWillDismiss();
|
|
17359
|
+
await openDataImport({
|
|
17360
|
+
appDataEntityId,
|
|
17361
|
+
deDataImportId: dedataImportId,
|
|
17362
|
+
context: this.context,
|
|
17363
|
+
params: this.params
|
|
17364
|
+
});
|
|
16921
17365
|
}
|
|
16922
17366
|
/**
|
|
16923
17367
|
* 数据导出
|
|
@@ -16975,7 +17419,7 @@ var MDControlController = class extends ControlController {
|
|
|
16975
17419
|
import {
|
|
16976
17420
|
findRecursiveChild,
|
|
16977
17421
|
RuntimeError as RuntimeError37,
|
|
16978
|
-
RuntimeModelError as
|
|
17422
|
+
RuntimeModelError as RuntimeModelError27
|
|
16979
17423
|
} from "@ibiz-template/core";
|
|
16980
17424
|
var AppMenuController = class extends ControlController {
|
|
16981
17425
|
constructor(model, context, params, ctx) {
|
|
@@ -17054,7 +17498,7 @@ var AppMenuController = class extends ControlController {
|
|
|
17054
17498
|
return provider.onClick(menuItem, event, this);
|
|
17055
17499
|
}
|
|
17056
17500
|
if (!menuItem.appFuncId) {
|
|
17057
|
-
throw new
|
|
17501
|
+
throw new RuntimeModelError27(menuItem, "\u6CA1\u6709\u914D\u7F6E\u5E94\u7528\u529F\u80FD");
|
|
17058
17502
|
}
|
|
17059
17503
|
const tempContext = this.context.clone();
|
|
17060
17504
|
tempContext.srfappid = menuItem.appId || ibiz.env.appId;
|
|
@@ -17174,7 +17618,7 @@ var AppMenuController = class extends ControlController {
|
|
|
17174
17618
|
import {
|
|
17175
17619
|
findRecursiveChild as findRecursiveChild2,
|
|
17176
17620
|
RuntimeError as RuntimeError38,
|
|
17177
|
-
RuntimeModelError as
|
|
17621
|
+
RuntimeModelError as RuntimeModelError28
|
|
17178
17622
|
} from "@ibiz-template/core";
|
|
17179
17623
|
var AppMenuIconViewController = class extends AppMenuController {
|
|
17180
17624
|
async onClickMenuItem(id, event) {
|
|
@@ -17190,7 +17634,7 @@ var AppMenuIconViewController = class extends AppMenuController {
|
|
|
17190
17634
|
event
|
|
17191
17635
|
});
|
|
17192
17636
|
if (!menuItem.appFuncId) {
|
|
17193
|
-
throw new
|
|
17637
|
+
throw new RuntimeModelError28(menuItem, "\u6CA1\u6709\u914D\u7F6E\u5E94\u7528\u529F\u80FD");
|
|
17194
17638
|
}
|
|
17195
17639
|
const tempContext = this.context.clone();
|
|
17196
17640
|
if (this.routeDepth === 1) {
|
|
@@ -17209,7 +17653,7 @@ var AppMenuIconViewController = class extends AppMenuController {
|
|
|
17209
17653
|
|
|
17210
17654
|
// src/controller/control/calendar/calendar.controller.ts
|
|
17211
17655
|
import dayjs3 from "dayjs";
|
|
17212
|
-
import { RuntimeModelError as
|
|
17656
|
+
import { RuntimeModelError as RuntimeModelError29 } from "@ibiz-template/core";
|
|
17213
17657
|
|
|
17214
17658
|
// src/controller/control/calendar/calendar.service.ts
|
|
17215
17659
|
import { RuntimeError as RuntimeError39 } from "@ibiz-template/core";
|
|
@@ -17389,7 +17833,7 @@ var CalendarController = class extends MDControlController {
|
|
|
17389
17833
|
}
|
|
17390
17834
|
));
|
|
17391
17835
|
if (result === -1) {
|
|
17392
|
-
throw new
|
|
17836
|
+
throw new RuntimeModelError29(
|
|
17393
17837
|
this.model,
|
|
17394
17838
|
"\u7F3A\u5C11".concat(item.itemType.toLowerCase(), "_opendata\u7684\u89C6\u56FE\u903B\u8F91")
|
|
17395
17839
|
);
|
|
@@ -17560,10 +18004,10 @@ import { mergeDeepRight as mergeDeepRight3 } from "ramda";
|
|
|
17560
18004
|
import { RuntimeError as RuntimeError40 } from "@ibiz-template/core";
|
|
17561
18005
|
|
|
17562
18006
|
// src/controller/control/chart/generator/line-series-generator.ts
|
|
17563
|
-
import { RuntimeModelError as
|
|
18007
|
+
import { RuntimeModelError as RuntimeModelError31 } from "@ibiz-template/core";
|
|
17564
18008
|
|
|
17565
18009
|
// src/controller/control/chart/generator/base-series-generator.ts
|
|
17566
|
-
import { plus, RuntimeModelError as
|
|
18010
|
+
import { plus, RuntimeModelError as RuntimeModelError30, toNumberOrNil } from "@ibiz-template/core";
|
|
17567
18011
|
import dayjs4 from "dayjs";
|
|
17568
18012
|
import minMax2 from "dayjs/plugin/minMax";
|
|
17569
18013
|
import isSameOrBefore from "dayjs/plugin/isSameOrBefore";
|
|
@@ -17613,10 +18057,10 @@ var BaseSeriesGenerator = class {
|
|
|
17613
18057
|
this.chartGenerator = chartGenerator;
|
|
17614
18058
|
const { chartSeriesEncode, caption, id, userParam } = model;
|
|
17615
18059
|
if (!model.catalogField) {
|
|
17616
|
-
throw new
|
|
18060
|
+
throw new RuntimeModelError30(model, "\u7F3A\u5C11\u5206\u7C7B\u5C5E\u6027\u914D\u7F6E");
|
|
17617
18061
|
}
|
|
17618
18062
|
if (!model.valueField) {
|
|
17619
|
-
throw new
|
|
18063
|
+
throw new RuntimeModelError30(model, "\u7F3A\u5C11\u503C\u5C5E\u6027\u914D\u7F6E");
|
|
17620
18064
|
}
|
|
17621
18065
|
this.catalogField = chartGenerator.getFieldKey(model.catalogField);
|
|
17622
18066
|
this.valueField = chartGenerator.getFieldKey(model.valueField);
|
|
@@ -18040,10 +18484,10 @@ var BaseSeriesGenerator = class {
|
|
|
18040
18484
|
var LineSeriesGenerator = class extends BaseSeriesGenerator {
|
|
18041
18485
|
calcStaticOptions() {
|
|
18042
18486
|
if (this.xAxisIndex === void 0) {
|
|
18043
|
-
throw new
|
|
18487
|
+
throw new RuntimeModelError31(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EX\u5750\u6807\u8F74");
|
|
18044
18488
|
}
|
|
18045
18489
|
if (this.yAxisIndex === void 0) {
|
|
18046
|
-
throw new
|
|
18490
|
+
throw new RuntimeModelError31(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EY\u5750\u6807\u8F74");
|
|
18047
18491
|
}
|
|
18048
18492
|
const options = super.calcStaticOptions();
|
|
18049
18493
|
options.xAxisIndex = this.xAxisIndex;
|
|
@@ -18059,14 +18503,14 @@ var LineSeriesGenerator = class extends BaseSeriesGenerator {
|
|
|
18059
18503
|
};
|
|
18060
18504
|
|
|
18061
18505
|
// src/controller/control/chart/generator/bar-series-generator.ts
|
|
18062
|
-
import { RuntimeModelError as
|
|
18506
|
+
import { RuntimeModelError as RuntimeModelError32 } from "@ibiz-template/core";
|
|
18063
18507
|
var BarSeriesGenerator = class extends BaseSeriesGenerator {
|
|
18064
18508
|
calcStaticOptions() {
|
|
18065
18509
|
if (this.xAxisIndex === void 0) {
|
|
18066
|
-
throw new
|
|
18510
|
+
throw new RuntimeModelError32(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EX\u5750\u6807\u8F74");
|
|
18067
18511
|
}
|
|
18068
18512
|
if (this.yAxisIndex === void 0) {
|
|
18069
|
-
throw new
|
|
18513
|
+
throw new RuntimeModelError32(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EY\u5750\u6807\u8F74");
|
|
18070
18514
|
}
|
|
18071
18515
|
const options = super.calcStaticOptions();
|
|
18072
18516
|
options.xAxisIndex = this.xAxisIndex;
|
|
@@ -18119,14 +18563,14 @@ var PieSeriesGenerator = class extends BaseSeriesGenerator {
|
|
|
18119
18563
|
};
|
|
18120
18564
|
|
|
18121
18565
|
// src/controller/control/chart/generator/scatter-series-generator.ts
|
|
18122
|
-
import { RuntimeModelError as
|
|
18566
|
+
import { RuntimeModelError as RuntimeModelError33 } from "@ibiz-template/core";
|
|
18123
18567
|
var ScatterSeriesGenerator = class extends BaseSeriesGenerator {
|
|
18124
18568
|
calcStaticOptions() {
|
|
18125
18569
|
if (this.xAxisIndex === void 0) {
|
|
18126
|
-
throw new
|
|
18570
|
+
throw new RuntimeModelError33(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EX\u5750\u6807\u8F74");
|
|
18127
18571
|
}
|
|
18128
18572
|
if (this.yAxisIndex === void 0) {
|
|
18129
|
-
throw new
|
|
18573
|
+
throw new RuntimeModelError33(this.model, "\u5E8F\u5217\u6CA1\u6709\u914D\u7F6EY\u5750\u6807\u8F74");
|
|
18130
18574
|
}
|
|
18131
18575
|
const options = super.calcStaticOptions();
|
|
18132
18576
|
options.xAxisIndex = this.xAxisIndex;
|
|
@@ -18903,17 +19347,17 @@ var CaptionBarController = class extends ControlController {
|
|
|
18903
19347
|
import { recursiveIterate as recursiveIterate2, RuntimeError as RuntimeError50 } from "@ibiz-template/core";
|
|
18904
19348
|
|
|
18905
19349
|
// src/ui-action/provider/backend-ui-action-provider.ts
|
|
18906
|
-
import { RuntimeModelError as
|
|
19350
|
+
import { RuntimeModelError as RuntimeModelError52 } from "@ibiz-template/core";
|
|
18907
19351
|
import { isArray as isArray8 } from "qx-util";
|
|
18908
19352
|
|
|
18909
19353
|
// src/ui-action/provider/ui-action-provider-base.ts
|
|
18910
|
-
import { RuntimeModelError as
|
|
19354
|
+
import { RuntimeModelError as RuntimeModelError51 } from "@ibiz-template/core";
|
|
18911
19355
|
|
|
18912
19356
|
// src/ui-logic/index.ts
|
|
18913
19357
|
import { RuntimeError as RuntimeError47 } from "@ibiz-template/core";
|
|
18914
19358
|
|
|
18915
19359
|
// src/ui-logic/ui-logic.ts
|
|
18916
|
-
import { ModelError as ModelError25, RuntimeModelError as
|
|
19360
|
+
import { ModelError as ModelError25, RuntimeModelError as RuntimeModelError50 } from "@ibiz-template/core";
|
|
18917
19361
|
|
|
18918
19362
|
// src/ui-logic/ui-logic-context.ts
|
|
18919
19363
|
var UILogicContext = class {
|
|
@@ -19066,20 +19510,20 @@ var UILogicContext = class {
|
|
|
19066
19510
|
};
|
|
19067
19511
|
|
|
19068
19512
|
// src/ui-logic/ui-logic-node/de-action-node/de-action-node.ts
|
|
19069
|
-
import { RuntimeModelError as
|
|
19513
|
+
import { RuntimeModelError as RuntimeModelError36 } from "@ibiz-template/core";
|
|
19070
19514
|
|
|
19071
19515
|
// src/ui-logic/ui-logic-link/ui-logic-link.ts
|
|
19072
19516
|
import { ModelError as ModelError20 } from "@ibiz-template/core";
|
|
19073
19517
|
|
|
19074
19518
|
// src/ui-logic/ui-logic-link/ui-logic-link-group-cond/ui-logic-link-group-cond.ts
|
|
19075
|
-
import { RuntimeModelError as
|
|
19519
|
+
import { RuntimeModelError as RuntimeModelError35 } from "@ibiz-template/core";
|
|
19076
19520
|
|
|
19077
19521
|
// src/ui-logic/ui-logic-link/ui-logic-link-cond/ui-logic-link-cond.ts
|
|
19078
19522
|
var UILogicLinkCond = class {
|
|
19079
19523
|
};
|
|
19080
19524
|
|
|
19081
19525
|
// src/ui-logic/ui-logic-link/ui-logic-link-single-cond/ui-logic-link-single-cond.ts
|
|
19082
|
-
import { ModelError as ModelError19, RuntimeModelError as
|
|
19526
|
+
import { ModelError as ModelError19, RuntimeModelError as RuntimeModelError34 } from "@ibiz-template/core";
|
|
19083
19527
|
|
|
19084
19528
|
// src/ui-logic/utils/handle-src-val.ts
|
|
19085
19529
|
import { ModelError as ModelError18 } from "@ibiz-template/core";
|
|
@@ -19177,7 +19621,7 @@ var UILogicLinkSingleCond = class extends UILogicLinkCond {
|
|
|
19177
19621
|
switch (this.type) {
|
|
19178
19622
|
case "ENTITYFIELD": {
|
|
19179
19623
|
if (!this.value) {
|
|
19180
|
-
throw new
|
|
19624
|
+
throw new RuntimeModelError34(
|
|
19181
19625
|
this.model,
|
|
19182
19626
|
"\u5F53\u524D\u6761\u4EF6\u503C\u7C7B\u578B\u4E3A[\u6570\u636E\u5BF9\u8C61\u5C5E\u6027],\u7F3A\u5C11\u914D\u7F6E\u6761\u4EF6\u503C"
|
|
19183
19627
|
);
|
|
@@ -19189,7 +19633,7 @@ var UILogicLinkSingleCond = class extends UILogicLinkCond {
|
|
|
19189
19633
|
}
|
|
19190
19634
|
case "SRCENTITYFIELD": {
|
|
19191
19635
|
if (!this.value) {
|
|
19192
|
-
throw new
|
|
19636
|
+
throw new RuntimeModelError34(
|
|
19193
19637
|
this.model,
|
|
19194
19638
|
"\u5F53\u524D\u6761\u4EF6\u503C\u7C7B\u578B\u4E3A[\u6E90\u6570\u636E\u5BF9\u8C61\u5C5E\u6027],\u7F3A\u5C11\u914D\u7F6E\u6761\u4EF6\u503C"
|
|
19195
19639
|
);
|
|
@@ -19268,7 +19712,7 @@ var UILogicLinkGroupCond = class _UILogicLinkGroupCond extends UILogicLinkCond {
|
|
|
19268
19712
|
test(ctx, context, data) {
|
|
19269
19713
|
let bol = true;
|
|
19270
19714
|
if (this.conds.length === 0) {
|
|
19271
|
-
throw new
|
|
19715
|
+
throw new RuntimeModelError35(this.model, "\u754C\u9762\u8FDE\u63A5\u6761\u4EF6\u903B\u8F91\u7EC4\u672A\u914D\u7F6E\u903B\u8F91\u9879");
|
|
19272
19716
|
}
|
|
19273
19717
|
for (let i = 0; i < this.conds.length; i++) {
|
|
19274
19718
|
const cond = this.conds[i];
|
|
@@ -19399,10 +19843,10 @@ var DEActionNode2 = class extends UILogicNode {
|
|
|
19399
19843
|
retDEUILogicParamId
|
|
19400
19844
|
} = this.model;
|
|
19401
19845
|
if (!dstAppDataEntityId) {
|
|
19402
|
-
throw new
|
|
19846
|
+
throw new RuntimeModelError36(this.model, "\u672A\u6307\u5B9A\u5E94\u7528\u5B9E\u4F53");
|
|
19403
19847
|
}
|
|
19404
19848
|
if (!dstAppDEActionId) {
|
|
19405
|
-
throw new
|
|
19849
|
+
throw new RuntimeModelError36(this.model, "\u672A\u6307\u5B9A\u5B9E\u4F53\u884C\u4E3A");
|
|
19406
19850
|
}
|
|
19407
19851
|
const requestData = ctx.params[dstDEUILogicParamId];
|
|
19408
19852
|
const app = ibiz.hub.getApp(ctx.context.srfappid);
|
|
@@ -19425,13 +19869,13 @@ var DEActionNode2 = class extends UILogicNode {
|
|
|
19425
19869
|
};
|
|
19426
19870
|
|
|
19427
19871
|
// src/ui-logic/ui-logic-node/de-ui-action-node/de-ui-action-node.ts
|
|
19428
|
-
import { RuntimeModelError as
|
|
19872
|
+
import { RuntimeModelError as RuntimeModelError37 } from "@ibiz-template/core";
|
|
19429
19873
|
var DEUIActionNode = class extends UILogicNode {
|
|
19430
19874
|
async exec(ctx) {
|
|
19431
19875
|
const { dstAppDEUIActionId, dstDEUILogicParamId, dstAppDataEntityId } = this.model;
|
|
19432
19876
|
const { data, parameters } = ctx;
|
|
19433
19877
|
if (!dstAppDEUIActionId) {
|
|
19434
|
-
throw new
|
|
19878
|
+
throw new RuntimeModelError37(this.model, "\u672A\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
|
|
19435
19879
|
}
|
|
19436
19880
|
let actionData = [data];
|
|
19437
19881
|
if (dstDEUILogicParamId) {
|
|
@@ -19680,20 +20124,20 @@ var PrepareJSParamNode = class extends UILogicNode {
|
|
|
19680
20124
|
};
|
|
19681
20125
|
|
|
19682
20126
|
// src/ui-logic/ui-logic-node/view-ctrl-invoke-node/view-ctrl-invoke-node.ts
|
|
19683
|
-
import { RuntimeError as RuntimeError43, RuntimeModelError as
|
|
20127
|
+
import { RuntimeError as RuntimeError43, RuntimeModelError as RuntimeModelError38 } from "@ibiz-template/core";
|
|
19684
20128
|
import { isFunction } from "lodash-es";
|
|
19685
20129
|
var ViewCtrlInvokeNode = class extends UILogicNode {
|
|
19686
20130
|
async exec(ctx) {
|
|
19687
20131
|
ctx.isEndNode = true;
|
|
19688
20132
|
const { invokeMethod, invokeCtrlId, invokeParamId } = this.model;
|
|
19689
20133
|
if (!invokeCtrlId) {
|
|
19690
|
-
throw new
|
|
20134
|
+
throw new RuntimeModelError38(this.model, "\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u5BF9\u8C61");
|
|
19691
20135
|
}
|
|
19692
20136
|
if (!invokeParamId) {
|
|
19693
|
-
throw new
|
|
20137
|
+
throw new RuntimeModelError38(this.model, "\u6CA1\u6709\u914D\u7F6E\u64CD\u4F5C\u53C2\u6570");
|
|
19694
20138
|
}
|
|
19695
20139
|
if (!invokeMethod) {
|
|
19696
|
-
throw new
|
|
20140
|
+
throw new RuntimeModelError38(this.model, "\u6CA1\u6709\u914D\u7F6E\u8C03\u7528\u65B9\u6CD5");
|
|
19697
20141
|
}
|
|
19698
20142
|
const invokeParam = ctx.params[invokeParamId];
|
|
19699
20143
|
if (!invokeParam) {
|
|
@@ -19715,12 +20159,12 @@ var ViewCtrlInvokeNode = class extends UILogicNode {
|
|
|
19715
20159
|
};
|
|
19716
20160
|
|
|
19717
20161
|
// src/ui-logic/ui-logic-node/bind-param-node/bind-param-node.ts
|
|
19718
|
-
import { RuntimeModelError as
|
|
20162
|
+
import { RuntimeModelError as RuntimeModelError39 } from "@ibiz-template/core";
|
|
19719
20163
|
var BindParamNode2 = class extends UILogicNode {
|
|
19720
20164
|
async exec(ctx) {
|
|
19721
20165
|
const { dstDEUILogicParamId, srcDEUILogicParamId } = this.model;
|
|
19722
20166
|
if (!dstDEUILogicParamId || !srcDEUILogicParamId) {
|
|
19723
|
-
throw new
|
|
20167
|
+
throw new RuntimeModelError39(
|
|
19724
20168
|
this.model,
|
|
19725
20169
|
"\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u8005\u6E90\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E"
|
|
19726
20170
|
);
|
|
@@ -19736,7 +20180,7 @@ var BindParamNode2 = class extends UILogicNode {
|
|
|
19736
20180
|
};
|
|
19737
20181
|
|
|
19738
20182
|
// src/ui-logic/ui-logic-node/msg-box-node/msg-box-node.ts
|
|
19739
|
-
import { ModelError as ModelError23, RuntimeModelError as
|
|
20183
|
+
import { ModelError as ModelError23, RuntimeModelError as RuntimeModelError40 } from "@ibiz-template/core";
|
|
19740
20184
|
var MsgBoxNode = class extends UILogicNode {
|
|
19741
20185
|
constructor() {
|
|
19742
20186
|
super(...arguments);
|
|
@@ -19750,10 +20194,10 @@ var MsgBoxNode = class extends UILogicNode {
|
|
|
19750
20194
|
async exec(ctx) {
|
|
19751
20195
|
const { msgBoxType, buttonsType, msgBoxParamId } = this.model;
|
|
19752
20196
|
if (!msgBoxType) {
|
|
19753
|
-
throw new
|
|
20197
|
+
throw new RuntimeModelError40(this.model, "\u7F3A\u5C11\u6D88\u606F\u7C7B\u578B\u7684\u914D\u7F6E");
|
|
19754
20198
|
}
|
|
19755
20199
|
if (!buttonsType) {
|
|
19756
|
-
throw new
|
|
20200
|
+
throw new RuntimeModelError40(this.model, "\u7F3A\u5C11\u6309\u94AE\u7C7B\u578B\u7684\u914D\u7F6E");
|
|
19757
20201
|
}
|
|
19758
20202
|
let { title, message } = this.model;
|
|
19759
20203
|
if (msgBoxParamId) {
|
|
@@ -19818,12 +20262,12 @@ var PFPluginNode = class extends UILogicNode {
|
|
|
19818
20262
|
};
|
|
19819
20263
|
|
|
19820
20264
|
// src/ui-logic/ui-logic-node/debug-param-node/debug-param-node.ts
|
|
19821
|
-
import { RuntimeModelError as
|
|
20265
|
+
import { RuntimeModelError as RuntimeModelError41 } from "@ibiz-template/core";
|
|
19822
20266
|
var DebugParamNode = class extends UILogicNode {
|
|
19823
20267
|
async exec(ctx) {
|
|
19824
20268
|
const { dstDEUILogicParamId, name } = this.model;
|
|
19825
20269
|
if (!dstDEUILogicParamId) {
|
|
19826
|
-
throw new
|
|
20270
|
+
throw new RuntimeModelError41(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
|
|
19827
20271
|
}
|
|
19828
20272
|
const param = ctx.params[dstDEUILogicParamId];
|
|
19829
20273
|
ibiz.log.info("\u903B\u8F91\u8282\u70B9".concat(name, "\u64CD\u4F5C\u53C2\u6570\u503C:"), param);
|
|
@@ -19831,12 +20275,12 @@ var DebugParamNode = class extends UILogicNode {
|
|
|
19831
20275
|
};
|
|
19832
20276
|
|
|
19833
20277
|
// src/ui-logic/ui-logic-node/reset-param-node/reset-param-node.ts
|
|
19834
|
-
import { RuntimeModelError as
|
|
20278
|
+
import { RuntimeModelError as RuntimeModelError42 } from "@ibiz-template/core";
|
|
19835
20279
|
var ResetParamNode2 = class extends UILogicNode {
|
|
19836
20280
|
async exec(ctx) {
|
|
19837
20281
|
const { dstDEUILogicParamId } = this.model;
|
|
19838
20282
|
if (!dstDEUILogicParamId) {
|
|
19839
|
-
throw new
|
|
20283
|
+
throw new RuntimeModelError42(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
|
|
19840
20284
|
}
|
|
19841
20285
|
ctx.resetParam(dstDEUILogicParamId);
|
|
19842
20286
|
ctx.setLastReturn(ctx.params[dstDEUILogicParamId]);
|
|
@@ -19847,13 +20291,13 @@ var ResetParamNode2 = class extends UILogicNode {
|
|
|
19847
20291
|
};
|
|
19848
20292
|
|
|
19849
20293
|
// src/ui-logic/ui-logic-node/copy-param-node/copy-param-node.ts
|
|
19850
|
-
import { RuntimeModelError as
|
|
20294
|
+
import { RuntimeModelError as RuntimeModelError43 } from "@ibiz-template/core";
|
|
19851
20295
|
import { clone as clone24 } from "ramda";
|
|
19852
20296
|
var CopyParamNode2 = class extends UILogicNode {
|
|
19853
20297
|
async exec(ctx) {
|
|
19854
20298
|
const { dstDEUILogicParamId, srcDEUILogicParamId } = this.model;
|
|
19855
20299
|
if (!dstDEUILogicParamId || !srcDEUILogicParamId) {
|
|
19856
|
-
throw new
|
|
20300
|
+
throw new RuntimeModelError43(
|
|
19857
20301
|
this.model,
|
|
19858
20302
|
"\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u8005\u6E90\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E"
|
|
19859
20303
|
);
|
|
@@ -19869,7 +20313,7 @@ var CopyParamNode2 = class extends UILogicNode {
|
|
|
19869
20313
|
};
|
|
19870
20314
|
|
|
19871
20315
|
// src/ui-logic/ui-logic-node/append-param-node/append-param-node.ts
|
|
19872
|
-
import { RuntimeModelError as
|
|
20316
|
+
import { RuntimeModelError as RuntimeModelError44 } from "@ibiz-template/core";
|
|
19873
20317
|
var AppendParamNode2 = class extends UILogicNode {
|
|
19874
20318
|
async exec(ctx) {
|
|
19875
20319
|
const {
|
|
@@ -19880,7 +20324,7 @@ var AppendParamNode2 = class extends UILogicNode {
|
|
|
19880
20324
|
srcSize
|
|
19881
20325
|
} = this.model;
|
|
19882
20326
|
if (!dstDEUILogicParamId || !srcDEUILogicParamId) {
|
|
19883
|
-
throw new
|
|
20327
|
+
throw new RuntimeModelError44(
|
|
19884
20328
|
this.model,
|
|
19885
20329
|
"\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u8005\u6E90\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E"
|
|
19886
20330
|
);
|
|
@@ -19905,12 +20349,12 @@ var AppendParamNode2 = class extends UILogicNode {
|
|
|
19905
20349
|
};
|
|
19906
20350
|
|
|
19907
20351
|
// src/ui-logic/ui-logic-node/sort-param-node/sort-param-node.ts
|
|
19908
|
-
import { RuntimeModelError as
|
|
20352
|
+
import { RuntimeModelError as RuntimeModelError45 } from "@ibiz-template/core";
|
|
19909
20353
|
var SortParamNode2 = class extends UILogicNode {
|
|
19910
20354
|
async exec(ctx) {
|
|
19911
20355
|
const { dstDEUILogicParamId, dstSortDir, dstFieldName } = this.model;
|
|
19912
20356
|
if (!dstDEUILogicParamId || !dstFieldName) {
|
|
19913
|
-
throw new
|
|
20357
|
+
throw new RuntimeModelError45(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u6216\u76EE\u6807\u5C5E\u6027\u914D\u7F6E");
|
|
19914
20358
|
}
|
|
19915
20359
|
const key = dstFieldName;
|
|
19916
20360
|
const arr = ctx.params[dstDEUILogicParamId];
|
|
@@ -19926,12 +20370,12 @@ var SortParamNode2 = class extends UILogicNode {
|
|
|
19926
20370
|
};
|
|
19927
20371
|
|
|
19928
20372
|
// src/ui-logic/ui-logic-node/renew-param-node/renew-param-node.ts
|
|
19929
|
-
import { RuntimeModelError as
|
|
20373
|
+
import { RuntimeModelError as RuntimeModelError46 } from "@ibiz-template/core";
|
|
19930
20374
|
var RenewParamNode2 = class extends UILogicNode {
|
|
19931
20375
|
async exec(ctx) {
|
|
19932
20376
|
const { dstDEUILogicParamId } = this.model;
|
|
19933
20377
|
if (!dstDEUILogicParamId) {
|
|
19934
|
-
throw new
|
|
20378
|
+
throw new RuntimeModelError46(this.model, "\u7F3A\u5C11\u76EE\u6807\u53C2\u6570\u5BF9\u8C61\u914D\u7F6E");
|
|
19935
20379
|
}
|
|
19936
20380
|
ctx.renewParam(dstDEUILogicParamId);
|
|
19937
20381
|
ctx.setLastReturn(ctx.params[dstDEUILogicParamId]);
|
|
@@ -19942,7 +20386,7 @@ var RenewParamNode2 = class extends UILogicNode {
|
|
|
19942
20386
|
};
|
|
19943
20387
|
|
|
19944
20388
|
// src/ui-logic/ui-logic-node/data-set-node/data-set-node.ts
|
|
19945
|
-
import { RuntimeModelError as
|
|
20389
|
+
import { RuntimeModelError as RuntimeModelError47 } from "@ibiz-template/core";
|
|
19946
20390
|
var DataSetNode2 = class extends UILogicNode {
|
|
19947
20391
|
async exec(ctx) {
|
|
19948
20392
|
const {
|
|
@@ -19952,7 +20396,7 @@ var DataSetNode2 = class extends UILogicNode {
|
|
|
19952
20396
|
retDEUILogicParamId
|
|
19953
20397
|
} = this.model;
|
|
19954
20398
|
if (!dstDEUILogicParamId) {
|
|
19955
|
-
throw new
|
|
20399
|
+
throw new RuntimeModelError47(this.model, "\u7F3A\u5C11\u914D\u7F6E\u8FC7\u6EE4\u53C2\u6570");
|
|
19956
20400
|
}
|
|
19957
20401
|
const queryParams = ctx.params[dstDEUILogicParamId];
|
|
19958
20402
|
const app = ibiz.hub.getApp(ctx.context.srfappid);
|
|
@@ -19986,19 +20430,19 @@ var ThrowExceptionNode2 = class extends UILogicNode {
|
|
|
19986
20430
|
};
|
|
19987
20431
|
|
|
19988
20432
|
// src/ui-logic/ui-logic-node/view-ctrl-fire-event-node/view-ctrl-fire-event-node.ts
|
|
19989
|
-
import { RuntimeError as RuntimeError45, RuntimeModelError as
|
|
20433
|
+
import { RuntimeError as RuntimeError45, RuntimeModelError as RuntimeModelError48 } from "@ibiz-template/core";
|
|
19990
20434
|
var ViewCtrlFireEventNode = class extends UILogicNode {
|
|
19991
20435
|
async exec(ctx) {
|
|
19992
20436
|
ctx.isEndNode = true;
|
|
19993
20437
|
const { eventName, eventParamId, fireCtrlId } = this.model;
|
|
19994
20438
|
if (!fireCtrlId) {
|
|
19995
|
-
throw new
|
|
20439
|
+
throw new RuntimeModelError48(this.model, "\u6CA1\u6709\u914D\u7F6E\u89E6\u53D1\u5BF9\u8C61");
|
|
19996
20440
|
}
|
|
19997
20441
|
if (!eventName) {
|
|
19998
|
-
throw new
|
|
20442
|
+
throw new RuntimeModelError48(this.model, "\u6CA1\u6709\u914D\u7F6E\u4E8B\u4EF6\u540D\u79F0\u53C2\u6570");
|
|
19999
20443
|
}
|
|
20000
20444
|
if (!eventParamId) {
|
|
20001
|
-
throw new
|
|
20445
|
+
throw new RuntimeModelError48(this.model, "\u6CA1\u6709\u914D\u7F6E\u4E8B\u4EF6\u53C2\u6570");
|
|
20002
20446
|
}
|
|
20003
20447
|
const invokeCtrl = ctx.params[fireCtrlId];
|
|
20004
20448
|
if (!invokeCtrl) {
|
|
@@ -20017,7 +20461,7 @@ var ViewCtrlFireEventNode = class extends UILogicNode {
|
|
|
20017
20461
|
};
|
|
20018
20462
|
|
|
20019
20463
|
// src/ui-logic/ui-logic-node/execute-de-logic-node/execute-de-logic-node.ts
|
|
20020
|
-
import { RuntimeError as RuntimeError46, RuntimeModelError as
|
|
20464
|
+
import { RuntimeError as RuntimeError46, RuntimeModelError as RuntimeModelError49 } from "@ibiz-template/core";
|
|
20021
20465
|
var ExecuteDELogicNode = class extends UILogicNode {
|
|
20022
20466
|
async exec(ctx) {
|
|
20023
20467
|
const {
|
|
@@ -20027,13 +20471,13 @@ var ExecuteDELogicNode = class extends UILogicNode {
|
|
|
20027
20471
|
retDEUILogicParamId
|
|
20028
20472
|
} = this.model;
|
|
20029
20473
|
if (!dstAppDataEntityId) {
|
|
20030
|
-
throw new
|
|
20474
|
+
throw new RuntimeModelError49(this.model, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53");
|
|
20031
20475
|
}
|
|
20032
20476
|
if (!dstAppDELogicId) {
|
|
20033
|
-
throw new
|
|
20477
|
+
throw new RuntimeModelError49(this.model, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u903B\u8F91");
|
|
20034
20478
|
}
|
|
20035
20479
|
if (!dstDEUILogicParamId) {
|
|
20036
|
-
throw new
|
|
20480
|
+
throw new RuntimeModelError49(this.model, "\u6CA1\u6709\u914D\u7F6E\u4F20\u5165\u903B\u8F91\u53C2\u6570");
|
|
20037
20481
|
}
|
|
20038
20482
|
const dstParam = ctx.params[dstDEUILogicParamId];
|
|
20039
20483
|
if (!dstParam) {
|
|
@@ -20227,7 +20671,7 @@ var UILogic = class {
|
|
|
20227
20671
|
this.params = /* @__PURE__ */ new Map();
|
|
20228
20672
|
var _a;
|
|
20229
20673
|
if (!((_a = model.deuilogicNodes) == null ? void 0 : _a.length)) {
|
|
20230
|
-
throw new
|
|
20674
|
+
throw new RuntimeModelError50(model, "\u754C\u9762\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u903B\u8F91\u8282\u70B9");
|
|
20231
20675
|
}
|
|
20232
20676
|
model.deuilogicNodes.forEach((node) => {
|
|
20233
20677
|
const { logicNodeType } = node;
|
|
@@ -20347,7 +20791,7 @@ var UILogic = class {
|
|
|
20347
20791
|
const start = this.nodes.get(startDEUILogicNodeId);
|
|
20348
20792
|
await this.deepExec(start, ctx);
|
|
20349
20793
|
} else {
|
|
20350
|
-
throw new
|
|
20794
|
+
throw new RuntimeModelError50(this.model, "\u672A\u8BBE\u7F6E\u8D77\u59CB\u8282\u70B9");
|
|
20351
20795
|
}
|
|
20352
20796
|
if (ctx.isEndNode) {
|
|
20353
20797
|
return ctx.result;
|
|
@@ -20529,7 +20973,7 @@ var UIActionProviderBase = class {
|
|
|
20529
20973
|
const { appDEUILogicId, appDataEntityId, uilogicAttachMode } = action;
|
|
20530
20974
|
if (uilogicAttachMode === "REPLACE") {
|
|
20531
20975
|
if (!appDEUILogicId) {
|
|
20532
|
-
throw new
|
|
20976
|
+
throw new RuntimeModelError51(action, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u754C\u9762\u903B\u8F91");
|
|
20533
20977
|
}
|
|
20534
20978
|
await execUILogic(appDEUILogicId, appDataEntityId, args);
|
|
20535
20979
|
return result;
|
|
@@ -20544,7 +20988,7 @@ var UIActionProviderBase = class {
|
|
|
20544
20988
|
}
|
|
20545
20989
|
if (action.uilogicAttachMode === "AFTER") {
|
|
20546
20990
|
if (!appDEUILogicId) {
|
|
20547
|
-
throw new
|
|
20991
|
+
throw new RuntimeModelError51(action, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u754C\u9762\u903B\u8F91");
|
|
20548
20992
|
}
|
|
20549
20993
|
await execUILogic(
|
|
20550
20994
|
appDEUILogicId,
|
|
@@ -20791,7 +21235,7 @@ var BackendUIActionProvider = class extends UIActionProviderBase {
|
|
|
20791
21235
|
const entityName = action.appDataEntityId;
|
|
20792
21236
|
const methodName = action.appDEMethodId;
|
|
20793
21237
|
if (!entityName || !methodName) {
|
|
20794
|
-
throw new
|
|
21238
|
+
throw new RuntimeModelError52(action, "\u672A\u914D\u7F6E\u5B9E\u4F53\u6216\u5B9E\u4F53\u884C\u4E3A");
|
|
20795
21239
|
}
|
|
20796
21240
|
const { resultContext, resultParams, resultData } = await this.handleParams(
|
|
20797
21241
|
action,
|
|
@@ -20917,11 +21361,11 @@ var SysUIActionProvider = class extends UIActionProviderBase {
|
|
|
20917
21361
|
// src/ui-action/provider/front-ui-action-provider.ts
|
|
20918
21362
|
import {
|
|
20919
21363
|
StringUtil,
|
|
20920
|
-
RuntimeModelError as
|
|
21364
|
+
RuntimeModelError as RuntimeModelError53,
|
|
20921
21365
|
ModelError as ModelError26,
|
|
20922
21366
|
RuntimeError as RuntimeError49
|
|
20923
21367
|
} from "@ibiz-template/core";
|
|
20924
|
-
import { mergeRight as
|
|
21368
|
+
import { mergeRight as mergeRight4 } from "ramda";
|
|
20925
21369
|
var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
20926
21370
|
async execAction(action, args) {
|
|
20927
21371
|
const { context, params, data, event, noWaitRoute } = args;
|
|
@@ -20936,7 +21380,7 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
20936
21380
|
case "WIZARD": {
|
|
20937
21381
|
const frontPSAppView = action.frontAppViewId;
|
|
20938
21382
|
if (!frontPSAppView) {
|
|
20939
|
-
throw new
|
|
21383
|
+
throw new RuntimeModelError53(action, "\u672A\u914D\u7F6E\u6253\u5F00\u89C6\u56FE");
|
|
20940
21384
|
}
|
|
20941
21385
|
const { resultContext, resultParams } = await this.handleParams(
|
|
20942
21386
|
action,
|
|
@@ -21004,7 +21448,7 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
21004
21448
|
);
|
|
21005
21449
|
return result || {};
|
|
21006
21450
|
}
|
|
21007
|
-
throw new
|
|
21451
|
+
throw new RuntimeModelError53(action, "\u81EA\u5B9A\u4E49\u7C7B\u578B\u7F3A\u5C11\u914D\u7F6E\u811A\u672C\u4EE3\u7801");
|
|
21008
21452
|
}
|
|
21009
21453
|
/**
|
|
21010
21454
|
* 执行打印行为
|
|
@@ -21074,47 +21518,27 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
21074
21518
|
* @return {*}
|
|
21075
21519
|
*/
|
|
21076
21520
|
async executeDataImport(action, args) {
|
|
21077
|
-
var _a;
|
|
21078
21521
|
const { resultContext, resultParams } = await this.handleParams(
|
|
21079
21522
|
action,
|
|
21080
21523
|
args.context,
|
|
21081
21524
|
args.data,
|
|
21082
21525
|
args.params
|
|
21083
21526
|
);
|
|
21084
|
-
const
|
|
21085
|
-
|
|
21086
|
-
action
|
|
21087
|
-
);
|
|
21088
|
-
const appDEDataImport = (_a = appDataEntity.appDEDataImports) == null ? void 0 : _a.find(
|
|
21089
|
-
(dataImport) => dataImport.id === action.appDEDataImportId
|
|
21090
|
-
);
|
|
21091
|
-
let importName = "DataImport";
|
|
21092
|
-
if (appDEDataImport && appDEDataImport.enableCustomized) {
|
|
21093
|
-
importName = "DataImport2";
|
|
21527
|
+
const { appDataEntityId, appDEDataImportId, frontAppViewId } = action;
|
|
21528
|
+
if (!appDataEntityId || !appDEDataImportId) {
|
|
21529
|
+
throw new RuntimeModelError53(action, "\u6CA1\u6709\u914D\u7F6E\u5BFC\u5165\u6A21\u578B\uFF01");
|
|
21094
21530
|
}
|
|
21095
|
-
|
|
21096
|
-
|
|
21097
|
-
|
|
21098
|
-
|
|
21099
|
-
|
|
21100
|
-
|
|
21101
|
-
|
|
21102
|
-
|
|
21103
|
-
|
|
21104
|
-
|
|
21105
|
-
|
|
21106
|
-
width: "auto",
|
|
21107
|
-
placement: "center"
|
|
21108
|
-
}
|
|
21109
|
-
);
|
|
21110
|
-
modal.present();
|
|
21111
|
-
await modal.onWillDismiss();
|
|
21112
|
-
return {
|
|
21113
|
-
refresh: true,
|
|
21114
|
-
refreshMode: 1
|
|
21115
|
-
};
|
|
21116
|
-
}
|
|
21117
|
-
throw new RuntimeError49("\u6CA1\u6709\u627E\u5230\u5B9E\u4F53\u5BFC\u5165\u9879");
|
|
21531
|
+
await openDataImport({
|
|
21532
|
+
appDataEntityId,
|
|
21533
|
+
deDataImportId: appDEDataImportId,
|
|
21534
|
+
dataImportViewId: frontAppViewId,
|
|
21535
|
+
context: resultContext,
|
|
21536
|
+
params: resultParams
|
|
21537
|
+
});
|
|
21538
|
+
return {
|
|
21539
|
+
refresh: true,
|
|
21540
|
+
refreshMode: 1
|
|
21541
|
+
};
|
|
21118
21542
|
}
|
|
21119
21543
|
/**
|
|
21120
21544
|
* 执行导出行为
|
|
@@ -21193,7 +21617,7 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
21193
21617
|
params
|
|
21194
21618
|
);
|
|
21195
21619
|
const options = this.handleViewOptionParams(resultParams).modalOption || {};
|
|
21196
|
-
const popoverOpts =
|
|
21620
|
+
const popoverOpts = mergeRight4(
|
|
21197
21621
|
{
|
|
21198
21622
|
autoClose: true
|
|
21199
21623
|
},
|
|
@@ -21206,7 +21630,8 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
21206
21630
|
context: resultContext,
|
|
21207
21631
|
params: resultParams,
|
|
21208
21632
|
modelData: action.deeditForm,
|
|
21209
|
-
onSaveSuccess: () => {
|
|
21633
|
+
onSaveSuccess: (eventArgs) => {
|
|
21634
|
+
actionResult.data = [eventArgs.args];
|
|
21210
21635
|
if (overlay) {
|
|
21211
21636
|
overlay.dismiss();
|
|
21212
21637
|
}
|
|
@@ -21919,7 +22344,7 @@ var RawItemPortletController = class extends PortletPartController {
|
|
|
21919
22344
|
};
|
|
21920
22345
|
|
|
21921
22346
|
// src/controller/control/data-view/data-view.controller.ts
|
|
21922
|
-
import { RuntimeModelError as
|
|
22347
|
+
import { RuntimeModelError as RuntimeModelError54 } from "@ibiz-template/core";
|
|
21923
22348
|
import { isNil as isNil26 } from "ramda";
|
|
21924
22349
|
|
|
21925
22350
|
// src/controller/control/data-view/data-view.service.ts
|
|
@@ -22137,7 +22562,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
22137
22562
|
const optItemModel = this.getOptItemModel();
|
|
22138
22563
|
if (optItemModel) {
|
|
22139
22564
|
if (!optItemModel.deuiactionGroup) {
|
|
22140
|
-
throw new
|
|
22565
|
+
throw new RuntimeModelError54(this.model, "\u64CD\u4F5C\u9879\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A\u7EC4");
|
|
22141
22566
|
}
|
|
22142
22567
|
if (!((_a = optItemModel.deuiactionGroup.uiactionGroupDetails) == null ? void 0 : _a.length)) {
|
|
22143
22568
|
ibiz.log.debug("\u64CD\u4F5C\u9879\u754C\u9762\u884C\u4E3A\u7EC4\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
|
|
@@ -22190,7 +22615,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
22190
22615
|
const { enableGroup, groupMode, groupAppDEFieldId } = this.model;
|
|
22191
22616
|
if (enableGroup && groupMode) {
|
|
22192
22617
|
if (!groupAppDEFieldId) {
|
|
22193
|
-
throw new
|
|
22618
|
+
throw new RuntimeModelError54(this.model, "\u5206\u7EC4\u5C5E\u6027\u6CA1\u6709\u914D\u7F6E");
|
|
22194
22619
|
}
|
|
22195
22620
|
if (groupMode === "AUTO") {
|
|
22196
22621
|
this.handleAutoGroup();
|
|
@@ -22257,7 +22682,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
22257
22682
|
async handleCodeListGroup() {
|
|
22258
22683
|
const { groupAppDEFieldId, groupCodeListId } = this.model;
|
|
22259
22684
|
if (!groupCodeListId) {
|
|
22260
|
-
throw new
|
|
22685
|
+
throw new RuntimeModelError54(this.model, "\u5206\u7EC4\u4EE3\u7801\u8868\u6CA1\u6709\u914D\u7F6E");
|
|
22261
22686
|
}
|
|
22262
22687
|
const { items } = this.state;
|
|
22263
22688
|
const groupMap = /* @__PURE__ */ new Map();
|
|
@@ -22363,7 +22788,7 @@ var DataViewControlController = class extends MDControlController {
|
|
|
22363
22788
|
caption = ibiz.i18n.t(item.capLanguageRes.lanResTag, item.caption);
|
|
22364
22789
|
}
|
|
22365
22790
|
if (!item.appDEFieldId) {
|
|
22366
|
-
throw new
|
|
22791
|
+
throw new RuntimeModelError54(item, "\u542F\u7528\u6392\u5E8F\u7684\u9879\u5FC5\u987B\u5173\u8054\u5B9E\u4F53\u5C5E\u6027");
|
|
22367
22792
|
}
|
|
22368
22793
|
const tempItem = {
|
|
22369
22794
|
caption,
|
|
@@ -22381,10 +22806,10 @@ var DataViewControlController = class extends MDControlController {
|
|
|
22381
22806
|
};
|
|
22382
22807
|
|
|
22383
22808
|
// src/controller/control/exp-bar/calendar-exp-bar.controller.ts
|
|
22384
|
-
import { RuntimeModelError as
|
|
22809
|
+
import { RuntimeModelError as RuntimeModelError56 } from "@ibiz-template/core";
|
|
22385
22810
|
|
|
22386
22811
|
// src/controller/control/exp-bar/exp-bar.controller.ts
|
|
22387
|
-
import { RuntimeError as RuntimeError51, RuntimeModelError as
|
|
22812
|
+
import { RuntimeError as RuntimeError51, RuntimeModelError as RuntimeModelError55 } from "@ibiz-template/core";
|
|
22388
22813
|
var ExpBarControlController = class extends ControlController {
|
|
22389
22814
|
constructor() {
|
|
22390
22815
|
super(...arguments);
|
|
@@ -22439,7 +22864,7 @@ var ExpBarControlController = class extends ControlController {
|
|
|
22439
22864
|
get xDataController() {
|
|
22440
22865
|
const controller = this.view.getController(this.model.xdataControlName);
|
|
22441
22866
|
if (!controller) {
|
|
22442
|
-
throw new
|
|
22867
|
+
throw new RuntimeModelError55(
|
|
22443
22868
|
this.model,
|
|
22444
22869
|
"\u65E0\u6CD5\u83B7\u53D6\u591A\u6570\u636E\u90E8\u4EF6[".concat(this.model.xdataControlName, "]\u63A7\u5236\u5668")
|
|
22445
22870
|
);
|
|
@@ -22803,7 +23228,7 @@ var CalendarExpBarController = class extends ExpBarControlController {
|
|
|
22803
23228
|
get xDataController() {
|
|
22804
23229
|
const controller = this.view.getController(this.model.xdataControlName);
|
|
22805
23230
|
if (!controller) {
|
|
22806
|
-
throw new
|
|
23231
|
+
throw new RuntimeModelError56(
|
|
22807
23232
|
this.model,
|
|
22808
23233
|
"\u65E0\u6CD5\u83B7\u53D6\u591A\u6570\u636E\u90E8\u4EF6[".concat(this.model.xdataControlName, "]\u63A7\u5236\u5668")
|
|
22809
23234
|
);
|
|
@@ -22858,7 +23283,7 @@ var CalendarExpBarController = class extends ExpBarControlController {
|
|
|
22858
23283
|
};
|
|
22859
23284
|
|
|
22860
23285
|
// src/controller/control/exp-bar/tree-exp-bar.controller.ts
|
|
22861
|
-
import { RuntimeError as RuntimeError52, RuntimeModelError as
|
|
23286
|
+
import { RuntimeError as RuntimeError52, RuntimeModelError as RuntimeModelError57 } from "@ibiz-template/core";
|
|
22862
23287
|
var TreeExpBarController = class extends ExpBarControlController {
|
|
22863
23288
|
constructor() {
|
|
22864
23289
|
super(...arguments);
|
|
@@ -22881,7 +23306,7 @@ var TreeExpBarController = class extends ExpBarControlController {
|
|
|
22881
23306
|
get xDataController() {
|
|
22882
23307
|
const controller = this.view.getController(this.model.xdataControlName);
|
|
22883
23308
|
if (!controller) {
|
|
22884
|
-
throw new
|
|
23309
|
+
throw new RuntimeModelError57(
|
|
22885
23310
|
this.model,
|
|
22886
23311
|
"\u65E0\u6CD5\u83B7\u53D6\u591A\u6570\u636E\u90E8\u4EF6[".concat(this.model.xdataControlName, "]\u63A7\u5236\u5668")
|
|
22887
23312
|
);
|
|
@@ -23142,7 +23567,7 @@ import { RuntimeError as RuntimeError53 } from "@ibiz-template/core";
|
|
|
23142
23567
|
|
|
23143
23568
|
// src/controller/control/form/form/form.controller.ts
|
|
23144
23569
|
import {
|
|
23145
|
-
RuntimeModelError as
|
|
23570
|
+
RuntimeModelError as RuntimeModelError58,
|
|
23146
23571
|
debounceAndAsyncMerge,
|
|
23147
23572
|
recursiveIterate as recursiveIterate3,
|
|
23148
23573
|
EntityError
|
|
@@ -23274,12 +23699,12 @@ var FormController = class extends ControlController {
|
|
|
23274
23699
|
async initDetailControllers(details = this.model.deformPages, form = this, parent = void 0) {
|
|
23275
23700
|
await Promise.all(
|
|
23276
23701
|
details.map(async (detail) => {
|
|
23277
|
-
const detailProvider = await getFormDetailProvider(detail);
|
|
23702
|
+
const detailProvider = await getFormDetailProvider(detail, this.model);
|
|
23278
23703
|
if (!detailProvider) {
|
|
23279
23704
|
return;
|
|
23280
23705
|
}
|
|
23281
23706
|
if (form.details[detail.id]) {
|
|
23282
|
-
throw new
|
|
23707
|
+
throw new RuntimeModelError58(
|
|
23283
23708
|
detail,
|
|
23284
23709
|
"\u521D\u59CB\u5316\u5F02\u5E38: \u8868\u5355\u6210\u5458[".concat(detail.id, "](").concat(detail.detailType, ")\u5DF2\u5B58\u5728\uFF0C\u8868\u5355\u9879\u6807\u8BC6\u91CD\u590D\u8BF7\u68C0\u67E5\u914D\u7F6E")
|
|
23285
23710
|
);
|
|
@@ -23880,12 +24305,18 @@ var FormDetailState = class {
|
|
|
23880
24305
|
return true;
|
|
23881
24306
|
}
|
|
23882
24307
|
});
|
|
23883
|
-
let $readonly
|
|
24308
|
+
let $readonly;
|
|
23884
24309
|
Object.defineProperty(this, "readonly", {
|
|
23885
24310
|
enumerable: true,
|
|
23886
24311
|
configurable: true,
|
|
23887
24312
|
get() {
|
|
23888
|
-
|
|
24313
|
+
if ($readonly !== void 0) {
|
|
24314
|
+
return $readonly;
|
|
24315
|
+
}
|
|
24316
|
+
if (this.context) {
|
|
24317
|
+
return !!(this.context.srfreadonly === true || this.context.srfreadonly === "true");
|
|
24318
|
+
}
|
|
24319
|
+
return false;
|
|
23889
24320
|
},
|
|
23890
24321
|
set(val) {
|
|
23891
24322
|
$readonly = val;
|
|
@@ -23942,6 +24373,7 @@ var FormDetailController = class {
|
|
|
23942
24373
|
this.form = form;
|
|
23943
24374
|
this.parent = parent;
|
|
23944
24375
|
this.state = this.createState();
|
|
24376
|
+
this.state.context = this.context;
|
|
23945
24377
|
}
|
|
23946
24378
|
/**
|
|
23947
24379
|
* 表单数据
|
|
@@ -24024,9 +24456,6 @@ var FormDetailController = class {
|
|
|
24024
24456
|
this.model.caption
|
|
24025
24457
|
);
|
|
24026
24458
|
}
|
|
24027
|
-
if (this.context.srfreadonly === true || this.context.srfreadonly === "true") {
|
|
24028
|
-
this.state.readonly = true;
|
|
24029
|
-
}
|
|
24030
24459
|
}
|
|
24031
24460
|
/**
|
|
24032
24461
|
* 创建表单状态对象
|
|
@@ -24779,15 +25208,15 @@ var FormItemController = class extends FormDetailController {
|
|
|
24779
25208
|
* @returns {*} {Promise<void>}
|
|
24780
25209
|
*/
|
|
24781
25210
|
async onInit() {
|
|
24782
|
-
var _a;
|
|
25211
|
+
var _a, _b;
|
|
24783
25212
|
await super.onInit();
|
|
24784
25213
|
this.state.required = !this.model.allowEmpty;
|
|
24785
25214
|
const { enableCond } = this.model;
|
|
24786
25215
|
if (!enableCond) {
|
|
24787
25216
|
this.state.enableCondDisabled = true;
|
|
24788
25217
|
}
|
|
24789
|
-
if (this.context.srfreadonly !== true && this.context.srfreadonly !== "true") {
|
|
24790
|
-
this.state.readonly = ((
|
|
25218
|
+
if (this.context.srfreadonly !== true && this.context.srfreadonly !== "true" && ((_a = this.model.editor) == null ? void 0 : _a.readOnly)) {
|
|
25219
|
+
this.state.readonly = ((_b = this.model.editor) == null ? void 0 : _b.readOnly) || false;
|
|
24791
25220
|
}
|
|
24792
25221
|
if (this.model.editor && this.model.editor.editorType !== "HIDDEN") {
|
|
24793
25222
|
this.editorProvider = await getEditorProvider(this.model.editor);
|
|
@@ -25134,7 +25563,7 @@ var FormMDCtrlController = class extends FormDetailController {
|
|
|
25134
25563
|
import {
|
|
25135
25564
|
mergeInLeft,
|
|
25136
25565
|
ModelError as ModelError27,
|
|
25137
|
-
RuntimeModelError as
|
|
25566
|
+
RuntimeModelError as RuntimeModelError59
|
|
25138
25567
|
} from "@ibiz-template/core";
|
|
25139
25568
|
var FormMDCtrlMDController = class extends FormMDCtrlController {
|
|
25140
25569
|
constructor() {
|
|
@@ -25160,7 +25589,7 @@ var FormMDCtrlMDController = class extends FormMDCtrlController {
|
|
|
25160
25589
|
await super.onInit();
|
|
25161
25590
|
const { contentControl } = this.model;
|
|
25162
25591
|
if (!contentControl) {
|
|
25163
|
-
throw new
|
|
25592
|
+
throw new RuntimeModelError59(this.model, "\u591A\u6570\u636E\u90E8\u4EF6\u672A\u914D\u7F6E\u5185\u5BB9\u90E8\u4EF6");
|
|
25164
25593
|
}
|
|
25165
25594
|
if (contentControl.controlType === "GRID") {
|
|
25166
25595
|
mergeInLeft(contentControl, {
|
|
@@ -25257,7 +25686,7 @@ var FormMDCtrlMDController = class extends FormMDCtrlController {
|
|
|
25257
25686
|
};
|
|
25258
25687
|
|
|
25259
25688
|
// src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-form.controller.ts
|
|
25260
|
-
import { RuntimeError as RuntimeError54, RuntimeModelError as
|
|
25689
|
+
import { RuntimeError as RuntimeError54, RuntimeModelError as RuntimeModelError60 } from "@ibiz-template/core";
|
|
25261
25690
|
import { createUUID as createUUID11 } from "qx-util";
|
|
25262
25691
|
|
|
25263
25692
|
// src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-form.state.ts
|
|
@@ -25298,7 +25727,7 @@ var FormMDCtrlFormController = class extends FormMDCtrlController {
|
|
|
25298
25727
|
super.onInit();
|
|
25299
25728
|
const { contentControl } = this.model;
|
|
25300
25729
|
if (!contentControl) {
|
|
25301
|
-
throw new
|
|
25730
|
+
throw new RuntimeModelError60(this.model, "\u591A\u6570\u636E\u90E8\u4EF6\u672A\u914D\u7F6E\u5185\u5BB9\u90E8\u4EF6");
|
|
25302
25731
|
}
|
|
25303
25732
|
contentControl.enableAutoSave = this.enableCreate || this.enableUpdate;
|
|
25304
25733
|
const controlProvider = await getControlProvider(contentControl);
|
|
@@ -25700,7 +26129,7 @@ import { clone as clone26, isNil as isNil27 } from "ramda";
|
|
|
25700
26129
|
// src/controller/control/form/edit-form/edit-form.service.ts
|
|
25701
26130
|
import {
|
|
25702
26131
|
recursiveIterate as recursiveIterate6,
|
|
25703
|
-
RuntimeModelError as
|
|
26132
|
+
RuntimeModelError as RuntimeModelError61
|
|
25704
26133
|
} from "@ibiz-template/core";
|
|
25705
26134
|
var EditFormService = class extends FormService {
|
|
25706
26135
|
/**
|
|
@@ -25824,7 +26253,7 @@ var EditFormService = class extends FormService {
|
|
|
25824
26253
|
const wizardForm = this.model;
|
|
25825
26254
|
const methodName = (_a = wizardForm.goBackControlAction) == null ? void 0 : _a.appDEMethodId;
|
|
25826
26255
|
if (!methodName) {
|
|
25827
|
-
throw new
|
|
26256
|
+
throw new RuntimeModelError61(this.model, "\u7F3A\u5C11\u8FD4\u56DE\u64CD\u4F5C\u5B9E\u4F53\u884C\u4E3A");
|
|
25828
26257
|
}
|
|
25829
26258
|
let res = await this.exec(
|
|
25830
26259
|
methodName,
|
|
@@ -26078,10 +26507,10 @@ var EditFormController = class extends FormController {
|
|
|
26078
26507
|
let res;
|
|
26079
26508
|
try {
|
|
26080
26509
|
await this.startLoading();
|
|
26081
|
-
await this.evt.emit("onBeforeLoad",
|
|
26510
|
+
await this.evt.emit("onBeforeLoad", { args: queryParams });
|
|
26082
26511
|
res = await this.service.get(context, queryParams);
|
|
26083
26512
|
} catch (error) {
|
|
26084
|
-
await this.evt.emit("onLoadError",
|
|
26513
|
+
await this.evt.emit("onLoadError", { args: error });
|
|
26085
26514
|
this.actionNotification("GETERROR", {
|
|
26086
26515
|
error
|
|
26087
26516
|
});
|
|
@@ -26094,7 +26523,7 @@ var EditFormController = class extends FormController {
|
|
|
26094
26523
|
this.state.modified = false;
|
|
26095
26524
|
this.state.data = res.data;
|
|
26096
26525
|
this.formStateNotify("LOAD" /* LOAD */);
|
|
26097
|
-
await this.evt.emit("onLoadSuccess",
|
|
26526
|
+
await this.evt.emit("onLoadSuccess", { args: res.data });
|
|
26098
26527
|
this.actionNotification("GETSUCCESS");
|
|
26099
26528
|
this.state.isLoaded = true;
|
|
26100
26529
|
return this.data;
|
|
@@ -26122,10 +26551,10 @@ var EditFormController = class extends FormController {
|
|
|
26122
26551
|
let res;
|
|
26123
26552
|
try {
|
|
26124
26553
|
await this.startLoading();
|
|
26125
|
-
await this.evt.emit("onBeforeLoad",
|
|
26554
|
+
await this.evt.emit("onBeforeLoad", { args: queryParams });
|
|
26126
26555
|
res = await this.service.get(context, queryParams);
|
|
26127
26556
|
} catch (error) {
|
|
26128
|
-
await this.evt.emit("onLoadError",
|
|
26557
|
+
await this.evt.emit("onLoadError", { args: error });
|
|
26129
26558
|
this.actionNotification("GETERROR", {
|
|
26130
26559
|
error
|
|
26131
26560
|
});
|
|
@@ -26137,7 +26566,7 @@ var EditFormController = class extends FormController {
|
|
|
26137
26566
|
this.state.data = res.data;
|
|
26138
26567
|
this.oldData = this.data.clone();
|
|
26139
26568
|
this.formStateNotify("LOAD" /* LOAD */);
|
|
26140
|
-
await this.evt.emit("onLoadSuccess",
|
|
26569
|
+
await this.evt.emit("onLoadSuccess", { args: res.data });
|
|
26141
26570
|
this.actionNotification("GETSUCCESS");
|
|
26142
26571
|
this.state.isLoaded = true;
|
|
26143
26572
|
return this.data;
|
|
@@ -26161,15 +26590,15 @@ var EditFormController = class extends FormController {
|
|
|
26161
26590
|
if (!silent) {
|
|
26162
26591
|
await this.startLoading();
|
|
26163
26592
|
}
|
|
26164
|
-
await this.evt.emit("onBeforeSave", void 0);
|
|
26165
26593
|
const { context, data } = this.handlerAbilityParams(args);
|
|
26166
26594
|
const saveData = data[0];
|
|
26167
26595
|
const isCreate = saveData.srfuf === 0 /* CREATE */;
|
|
26168
26596
|
let res;
|
|
26169
26597
|
try {
|
|
26598
|
+
await this.evt.emit("onBeforeSave", { args: saveData });
|
|
26170
26599
|
res = isCreate ? await this.service.create(context, saveData) : await this.service.update(context, saveData);
|
|
26171
26600
|
} catch (error) {
|
|
26172
|
-
await this.evt.emit("onSaveError",
|
|
26601
|
+
await this.evt.emit("onSaveError", { args: error });
|
|
26173
26602
|
this.actionNotification("".concat(isCreate ? "CREATE" : "UPDATE", "ERROR"), {
|
|
26174
26603
|
error
|
|
26175
26604
|
});
|
|
@@ -26191,7 +26620,7 @@ var EditFormController = class extends FormController {
|
|
|
26191
26620
|
this.data.tempsrfkey = this.data.srfkey;
|
|
26192
26621
|
}
|
|
26193
26622
|
this.state.modified = false;
|
|
26194
|
-
await this.evt.emit("onSaveSuccess",
|
|
26623
|
+
await this.evt.emit("onSaveSuccess", { args: res.data });
|
|
26195
26624
|
if (!this.view.state.isClosing) {
|
|
26196
26625
|
this.formStateNotify("SAVE" /* SAVE */);
|
|
26197
26626
|
}
|
|
@@ -26214,7 +26643,7 @@ var EditFormController = class extends FormController {
|
|
|
26214
26643
|
const { context, params } = this.handlerAbilityParams(args);
|
|
26215
26644
|
let res;
|
|
26216
26645
|
let ok = false;
|
|
26217
|
-
await this.evt.emit("onBeforeRemove",
|
|
26646
|
+
await this.evt.emit("onBeforeRemove", { args: this.data });
|
|
26218
26647
|
if (this.data.srfuf === 1 /* UPDATE */) {
|
|
26219
26648
|
ok = await ibiz.modal.confirm({
|
|
26220
26649
|
title: "\u63D0\u793A",
|
|
@@ -26227,7 +26656,7 @@ var EditFormController = class extends FormController {
|
|
|
26227
26656
|
try {
|
|
26228
26657
|
res = await this.service.remove(context, params);
|
|
26229
26658
|
} catch (error) {
|
|
26230
|
-
await this.evt.emit("onRemoveError",
|
|
26659
|
+
await this.evt.emit("onRemoveError", { args: error });
|
|
26231
26660
|
this.actionNotification("REMOVEERROR", {
|
|
26232
26661
|
error
|
|
26233
26662
|
});
|
|
@@ -26240,7 +26669,7 @@ var EditFormController = class extends FormController {
|
|
|
26240
26669
|
this.emitDEDataChange("remove", this.data);
|
|
26241
26670
|
this.state.data = new ControlVO();
|
|
26242
26671
|
this.state.modified = false;
|
|
26243
|
-
await this.evt.emit("onRemoveSuccess",
|
|
26672
|
+
await this.evt.emit("onRemoveSuccess", { args: this.data });
|
|
26244
26673
|
this.actionNotification("REMOVESUCCESS");
|
|
26245
26674
|
return ok;
|
|
26246
26675
|
}
|
|
@@ -26706,6 +27135,28 @@ var GridRowState = class {
|
|
|
26706
27135
|
editable: ibiz.config.grid.editShowMode === "all",
|
|
26707
27136
|
required: false
|
|
26708
27137
|
};
|
|
27138
|
+
let $readonly;
|
|
27139
|
+
Object.defineProperty(
|
|
27140
|
+
this.editColStates[editColumn.fieldName],
|
|
27141
|
+
"readonly",
|
|
27142
|
+
{
|
|
27143
|
+
enumerable: true,
|
|
27144
|
+
configurable: true,
|
|
27145
|
+
get() {
|
|
27146
|
+
if ($readonly !== void 0) {
|
|
27147
|
+
return $readonly;
|
|
27148
|
+
}
|
|
27149
|
+
if (grid.context) {
|
|
27150
|
+
return !!(grid.context.srfreadonly === true || grid.context.srfreadonly === "true");
|
|
27151
|
+
}
|
|
27152
|
+
return false;
|
|
27153
|
+
},
|
|
27154
|
+
set(val) {
|
|
27155
|
+
$readonly = val;
|
|
27156
|
+
return true;
|
|
27157
|
+
}
|
|
27158
|
+
}
|
|
27159
|
+
);
|
|
26709
27160
|
});
|
|
26710
27161
|
}
|
|
26711
27162
|
getDiffData() {
|
|
@@ -26729,13 +27180,13 @@ import {
|
|
|
26729
27180
|
mergeDefaultInLeft,
|
|
26730
27181
|
recursiveIterate as recursiveIterate7,
|
|
26731
27182
|
RuntimeError as RuntimeError56,
|
|
26732
|
-
RuntimeModelError as
|
|
27183
|
+
RuntimeModelError as RuntimeModelError63
|
|
26733
27184
|
} from "@ibiz-template/core";
|
|
26734
27185
|
import { clone as clone27 } from "ramda";
|
|
26735
27186
|
import dayjs5 from "dayjs";
|
|
26736
27187
|
|
|
26737
27188
|
// src/controller/control/grid/grid/grid.service.ts
|
|
26738
|
-
import { RuntimeModelError as
|
|
27189
|
+
import { RuntimeModelError as RuntimeModelError62 } from "@ibiz-template/core";
|
|
26739
27190
|
var GridService = class extends MDControlService {
|
|
26740
27191
|
/**
|
|
26741
27192
|
* 初始化属性映射
|
|
@@ -26763,7 +27214,7 @@ var GridService = class extends MDControlService {
|
|
|
26763
27214
|
dataType: dataItem.dataType
|
|
26764
27215
|
});
|
|
26765
27216
|
} else {
|
|
26766
|
-
throw new
|
|
27217
|
+
throw new RuntimeModelError62(
|
|
26767
27218
|
column,
|
|
26768
27219
|
"\u672A\u627E\u5230\u5BF9\u5E94\u7684\u8868\u683C\u6570\u636E\u9879[".concat(deField, "]")
|
|
26769
27220
|
);
|
|
@@ -27158,11 +27609,11 @@ var GridController = class extends MDControlController {
|
|
|
27158
27609
|
(item) => item.model.appDEFieldId === groupAppDEFieldId
|
|
27159
27610
|
);
|
|
27160
27611
|
if (!this.groupFieldColumn) {
|
|
27161
|
-
throw new
|
|
27612
|
+
throw new RuntimeModelError63(this.model, "\u6CA1\u6709\u914D\u7F6E\u5206\u7EC4\u5C5E\u6027\u7684\u5C5E\u6027\u5217");
|
|
27162
27613
|
}
|
|
27163
27614
|
const groupFieldName = this.groupFieldColumn.model.id;
|
|
27164
27615
|
if (!this.groupFieldColumn.model.appCodeListId) {
|
|
27165
|
-
throw new
|
|
27616
|
+
throw new RuntimeModelError63(
|
|
27166
27617
|
this.groupFieldColumn.model,
|
|
27167
27618
|
"\u5206\u7EC4\u5C5E\u6027\u7684\u5C5E\u6027\u5217".concat(groupFieldName, "\u6CA1\u6709\u914D\u7F6E\u4EE3\u7801\u8868")
|
|
27168
27619
|
);
|
|
@@ -27172,7 +27623,7 @@ var GridController = class extends MDControlController {
|
|
|
27172
27623
|
);
|
|
27173
27624
|
if (index !== -1 && index !== 0) {
|
|
27174
27625
|
if (this.isMultistageHeader) {
|
|
27175
|
-
throw new
|
|
27626
|
+
throw new RuntimeModelError63(
|
|
27176
27627
|
this.model,
|
|
27177
27628
|
"\u8BF7\u5C06\u5206\u7EC4\u5C5E\u6027\u5217".concat(groupFieldName, "\u914D\u7F6E\u4E3A\u7B2C\u4E00\u5217")
|
|
27178
27629
|
);
|
|
@@ -27182,10 +27633,10 @@ var GridController = class extends MDControlController {
|
|
|
27182
27633
|
}
|
|
27183
27634
|
if (groupMode === "CODELIST") {
|
|
27184
27635
|
if (!groupCodeListId) {
|
|
27185
|
-
throw new
|
|
27636
|
+
throw new RuntimeModelError63(this.model, "\u4EE3\u7801\u8868\u5206\u7EC4\u6A21\u5F0F\u9700\u8981\u914D\u7F6E\u4EE3\u7801\u8868");
|
|
27186
27637
|
}
|
|
27187
27638
|
if (this.groupFieldColumn.model.appCodeListId !== groupCodeListId) {
|
|
27188
|
-
throw new
|
|
27639
|
+
throw new RuntimeModelError63(
|
|
27189
27640
|
this.model,
|
|
27190
27641
|
"\u5206\u7EC4\u4EE3\u7801\u8868\u4E0E\u5C5E\u6027\u5217".concat(groupFieldName, "\u7684\u4EE3\u7801\u8868\u4E0D\u4E00\u81F4")
|
|
27191
27642
|
);
|
|
@@ -27288,7 +27739,7 @@ var GridController = class extends MDControlController {
|
|
|
27288
27739
|
return;
|
|
27289
27740
|
}
|
|
27290
27741
|
if (!aggAppDEDataSetId || !aggAppDataEntityId) {
|
|
27291
|
-
throw new
|
|
27742
|
+
throw new RuntimeModelError63(this.model, "\u7F3A\u5C11\u914D\u7F6E\u805A\u5408\u5B9E\u4F53\u6216\u805A\u5408\u6570\u636E\u96C6");
|
|
27292
27743
|
}
|
|
27293
27744
|
const params = await this.getFetchParams();
|
|
27294
27745
|
const app = ibiz.hub.getApp(this.context.srfappid);
|
|
@@ -27464,7 +27915,7 @@ var GridController = class extends MDControlController {
|
|
|
27464
27915
|
*/
|
|
27465
27916
|
async initColumnsController(column) {
|
|
27466
27917
|
var _a;
|
|
27467
|
-
const provider = await getGridColumnProvider(column);
|
|
27918
|
+
const provider = await getGridColumnProvider(column, this.model);
|
|
27468
27919
|
if (!provider) {
|
|
27469
27920
|
return;
|
|
27470
27921
|
}
|
|
@@ -28387,7 +28838,7 @@ var GridFieldColumnController = class extends GridColumnController {
|
|
|
28387
28838
|
};
|
|
28388
28839
|
|
|
28389
28840
|
// src/controller/control/grid/grid-column/grid-ua-column/grid-ua-column.controller.ts
|
|
28390
|
-
import { RuntimeModelError as
|
|
28841
|
+
import { RuntimeModelError as RuntimeModelError64 } from "@ibiz-template/core";
|
|
28391
28842
|
var GridUAColumnController = class extends GridColumnController {
|
|
28392
28843
|
/**
|
|
28393
28844
|
* 给rowController初始化操作列的状态
|
|
@@ -28400,7 +28851,7 @@ var GridUAColumnController = class extends GridColumnController {
|
|
|
28400
28851
|
var _a;
|
|
28401
28852
|
const { deuiactionGroup } = this.model;
|
|
28402
28853
|
if (!deuiactionGroup) {
|
|
28403
|
-
throw new
|
|
28854
|
+
throw new RuntimeModelError64(this.model, "\u64CD\u4F5C\u5217\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A\u7EC4");
|
|
28404
28855
|
}
|
|
28405
28856
|
if (!((_a = deuiactionGroup.uiactionGroupDetails) == null ? void 0 : _a.length)) {
|
|
28406
28857
|
ibiz.log.debug("\u64CD\u4F5C\u5217\u754C\u9762\u884C\u4E3A\u7EC4\u6CA1\u6709\u914D\u7F6E\u754C\u9762\u884C\u4E3A");
|
|
@@ -28653,7 +29104,9 @@ var GridFieldEditColumnController = class extends GridFieldColumnController {
|
|
|
28653
29104
|
calcColumnReadonly(row) {
|
|
28654
29105
|
var _a;
|
|
28655
29106
|
const isReadOnly = !!((_a = this.editItem.editor) == null ? void 0 : _a.readOnly);
|
|
28656
|
-
|
|
29107
|
+
if (isReadOnly) {
|
|
29108
|
+
row.editColStates[this.fieldName].readonly = isReadOnly;
|
|
29109
|
+
}
|
|
28657
29110
|
}
|
|
28658
29111
|
/**
|
|
28659
29112
|
* 计算启用项的禁用
|
|
@@ -28968,7 +29421,11 @@ var PanelController = class extends ControlController {
|
|
|
28968
29421
|
await Promise.all(
|
|
28969
29422
|
panelItems.map(async (panelItem) => {
|
|
28970
29423
|
var _a, _b;
|
|
28971
|
-
const panelItemProvider = await getPanelItemProvider(
|
|
29424
|
+
const panelItemProvider = await getPanelItemProvider(
|
|
29425
|
+
panelItem,
|
|
29426
|
+
panel.model,
|
|
29427
|
+
panel.view.model
|
|
29428
|
+
);
|
|
28972
29429
|
if (!panelItemProvider) {
|
|
28973
29430
|
return;
|
|
28974
29431
|
}
|
|
@@ -29189,8 +29646,8 @@ var PanelItemState = class {
|
|
|
29189
29646
|
/**
|
|
29190
29647
|
* 是否只读
|
|
29191
29648
|
*
|
|
29192
|
-
* @author
|
|
29193
|
-
* @date 2024-
|
|
29649
|
+
* @author tony001
|
|
29650
|
+
* @date 2024-04-16 16:04:49
|
|
29194
29651
|
* @type {boolean}
|
|
29195
29652
|
*/
|
|
29196
29653
|
this.readonly = false;
|
|
@@ -29225,12 +29682,18 @@ var PanelItemState = class {
|
|
|
29225
29682
|
return true;
|
|
29226
29683
|
}
|
|
29227
29684
|
});
|
|
29228
|
-
let $readonly
|
|
29685
|
+
let $readonly;
|
|
29229
29686
|
Object.defineProperty(this, "readonly", {
|
|
29230
29687
|
enumerable: true,
|
|
29231
29688
|
configurable: true,
|
|
29232
29689
|
get() {
|
|
29233
|
-
|
|
29690
|
+
if ($readonly !== void 0) {
|
|
29691
|
+
return $readonly;
|
|
29692
|
+
}
|
|
29693
|
+
if (this.context) {
|
|
29694
|
+
return !!(this.context.srfreadonly === true || this.context.srfreadonly === "true");
|
|
29695
|
+
}
|
|
29696
|
+
return false;
|
|
29234
29697
|
},
|
|
29235
29698
|
set(val) {
|
|
29236
29699
|
$readonly = val;
|
|
@@ -29266,6 +29729,7 @@ var PanelItemController = class {
|
|
|
29266
29729
|
required: void 0
|
|
29267
29730
|
};
|
|
29268
29731
|
this.state = this.createState();
|
|
29732
|
+
this.state.context = this.panel.context;
|
|
29269
29733
|
}
|
|
29270
29734
|
/**
|
|
29271
29735
|
* 数据父容器
|
|
@@ -29337,9 +29801,6 @@ var PanelItemController = class {
|
|
|
29337
29801
|
if (labelSysCss == null ? void 0 : labelSysCss.cssName) {
|
|
29338
29802
|
this.state.class.label.push(labelSysCss.cssName);
|
|
29339
29803
|
}
|
|
29340
|
-
if (this.panel.context.srfreadonly === true || this.panel.context.srfreadonly === "true") {
|
|
29341
|
-
this.state.readonly = true;
|
|
29342
|
-
}
|
|
29343
29804
|
}
|
|
29344
29805
|
destroy() {
|
|
29345
29806
|
}
|
|
@@ -29637,7 +30098,7 @@ import { clone as clone30 } from "ramda";
|
|
|
29637
30098
|
import { isString as isString2 } from "lodash-es";
|
|
29638
30099
|
|
|
29639
30100
|
// src/controller/control/search-bar/search-bar-filter.controller.ts
|
|
29640
|
-
import { RuntimeModelError as
|
|
30101
|
+
import { RuntimeModelError as RuntimeModelError65 } from "@ibiz-template/core";
|
|
29641
30102
|
|
|
29642
30103
|
// src/controller/control/search-bar/util.ts
|
|
29643
30104
|
var ItemsValueOPs = [
|
|
@@ -29718,7 +30179,7 @@ var SearchBarFilterController = class {
|
|
|
29718
30179
|
async init() {
|
|
29719
30180
|
if (!this.noEditor) {
|
|
29720
30181
|
if (!this.model.editor) {
|
|
29721
|
-
throw new
|
|
30182
|
+
throw new RuntimeModelError65(this.model, "\u7F3A\u5C11\u7F16\u8F91\u5668\u6A21\u578B");
|
|
29722
30183
|
}
|
|
29723
30184
|
this.editorProvider = await getEditorProvider(this.model.editor);
|
|
29724
30185
|
if (this.editorProvider) {
|
|
@@ -31289,7 +31750,7 @@ var TabExpPanelController = class extends ControlController {
|
|
|
31289
31750
|
// src/controller/control/tree/tree.controller.ts
|
|
31290
31751
|
import {
|
|
31291
31752
|
RuntimeError as RuntimeError60,
|
|
31292
|
-
RuntimeModelError as
|
|
31753
|
+
RuntimeModelError as RuntimeModelError66,
|
|
31293
31754
|
recursiveIterate as recursiveIterate11
|
|
31294
31755
|
} from "@ibiz-template/core";
|
|
31295
31756
|
import { isNil as isNil30 } from "ramda";
|
|
@@ -32242,7 +32703,7 @@ var TreeController = class extends MDControlController {
|
|
|
32242
32703
|
const { sortAppDEFieldId, sortDir, allowOrder } = orderNodeModel;
|
|
32243
32704
|
if (allowOrder === true) {
|
|
32244
32705
|
if (!sortAppDEFieldId) {
|
|
32245
|
-
throw new
|
|
32706
|
+
throw new RuntimeModelError66(orderNodeModel, "\u7F3A\u5C11\u914D\u7F6E\u6392\u5E8F\u5C5E\u6027");
|
|
32246
32707
|
}
|
|
32247
32708
|
const sortField = sortAppDEFieldId.toLowerCase();
|
|
32248
32709
|
const isAsc = sortDir === "ASC";
|
|
@@ -32327,7 +32788,7 @@ var TreeController = class extends MDControlController {
|
|
|
32327
32788
|
async modifyNodeText(nodeData, text) {
|
|
32328
32789
|
const model = this.getNodeModel(nodeData._nodeId);
|
|
32329
32790
|
if (!model.allowEditText) {
|
|
32330
|
-
throw new
|
|
32791
|
+
throw new RuntimeModelError66(model, "\u6811\u8282\u70B9\u6CA1\u6709\u914D\u7F6E\u7F16\u8F91\u6A21\u5F0F\uFF1A\u540D\u79F0");
|
|
32331
32792
|
}
|
|
32332
32793
|
if (nodeData._nodeType !== "DE") {
|
|
32333
32794
|
throw new RuntimeError60("\u4E0D\u662F\u5B9E\u4F53\u6811\u8282\u70B9\u6570\u636E");
|
|
@@ -32742,7 +33203,7 @@ var WizardPanelController = class extends ControlController {
|
|
|
32742
33203
|
};
|
|
32743
33204
|
|
|
32744
33205
|
// src/controller/control/md-ctrl/md-ctrl.controller.ts
|
|
32745
|
-
import { RuntimeModelError as
|
|
33206
|
+
import { RuntimeModelError as RuntimeModelError67 } from "@ibiz-template/core";
|
|
32746
33207
|
import { isNil as isNil31 } from "ramda";
|
|
32747
33208
|
|
|
32748
33209
|
// src/controller/control/md-ctrl/md-ctrl.service.ts
|
|
@@ -32951,7 +33412,7 @@ var MDCtrlController = class extends MDControlController {
|
|
|
32951
33412
|
const { enableGroup, groupMode, groupAppDEFieldId } = this.model;
|
|
32952
33413
|
if (enableGroup && groupMode) {
|
|
32953
33414
|
if (!groupAppDEFieldId) {
|
|
32954
|
-
throw new
|
|
33415
|
+
throw new RuntimeModelError67(this.model, "\u5206\u7EC4\u5C5E\u6027\u6CA1\u6709\u914D\u7F6E");
|
|
32955
33416
|
}
|
|
32956
33417
|
if (groupMode === "AUTO") {
|
|
32957
33418
|
this.handleAutoGroup();
|
|
@@ -33018,7 +33479,7 @@ var MDCtrlController = class extends MDControlController {
|
|
|
33018
33479
|
async handleCodeListGroup() {
|
|
33019
33480
|
const { groupAppDEFieldId, groupCodeListId } = this.model;
|
|
33020
33481
|
if (!groupCodeListId) {
|
|
33021
|
-
throw new
|
|
33482
|
+
throw new RuntimeModelError67(this.model, "\u5206\u7EC4\u4EE3\u7801\u8868\u6CA1\u6709\u914D\u7F6E");
|
|
33022
33483
|
}
|
|
33023
33484
|
const { items } = this.state;
|
|
33024
33485
|
const groupMap = /* @__PURE__ */ new Map();
|
|
@@ -33048,7 +33509,7 @@ var MDCtrlController = class extends MDControlController {
|
|
|
33048
33509
|
};
|
|
33049
33510
|
|
|
33050
33511
|
// src/controller/control/kanban/kanban.controller.ts
|
|
33051
|
-
import { RuntimeError as RuntimeError62, RuntimeModelError as
|
|
33512
|
+
import { RuntimeError as RuntimeError62, RuntimeModelError as RuntimeModelError68 } from "@ibiz-template/core";
|
|
33052
33513
|
import { isNil as isNil32 } from "ramda";
|
|
33053
33514
|
|
|
33054
33515
|
// src/controller/control/kanban/kanban.service.ts
|
|
@@ -33127,10 +33588,10 @@ var KanbanController = class extends DataViewControlController {
|
|
|
33127
33588
|
const sortField = this.model.minorSortAppDEFieldId;
|
|
33128
33589
|
const { minorSortDir } = this.model;
|
|
33129
33590
|
if (!sortField) {
|
|
33130
|
-
throw new
|
|
33591
|
+
throw new RuntimeModelError68(this.model, "\u6392\u5E8F\u5C5E\u6027\u6CA1\u914D\u7F6E");
|
|
33131
33592
|
}
|
|
33132
33593
|
if (!minorSortDir) {
|
|
33133
|
-
throw new
|
|
33594
|
+
throw new RuntimeModelError68(this.model, "\u6392\u5E8F\u65B9\u5411\u6CA1\u914D\u7F6E");
|
|
33134
33595
|
}
|
|
33135
33596
|
const isAsc = minorSortDir === "ASC";
|
|
33136
33597
|
items.forEach((item) => {
|
|
@@ -33310,7 +33771,7 @@ var KanbanController = class extends DataViewControlController {
|
|
|
33310
33771
|
async handleCodeListGroup() {
|
|
33311
33772
|
const { groupAppDEFieldId, groupCodeListId } = this.model;
|
|
33312
33773
|
if (!groupCodeListId) {
|
|
33313
|
-
throw new
|
|
33774
|
+
throw new RuntimeModelError68(this.model, "\u5206\u7EC4\u4EE3\u7801\u8868\u6CA1\u6709\u914D\u7F6E");
|
|
33314
33775
|
}
|
|
33315
33776
|
const { items } = this.state;
|
|
33316
33777
|
const groupMap = /* @__PURE__ */ new Map();
|
|
@@ -33606,7 +34067,7 @@ var KanbanController = class extends DataViewControlController {
|
|
|
33606
34067
|
// src/controller/control/tree-grid-ex/tree-grid-ex.controller.ts
|
|
33607
34068
|
import {
|
|
33608
34069
|
RuntimeError as RuntimeError63,
|
|
33609
|
-
RuntimeModelError as
|
|
34070
|
+
RuntimeModelError as RuntimeModelError69,
|
|
33610
34071
|
awaitTimeout as awaitTimeout3,
|
|
33611
34072
|
recursiveIterate as recursiveIterate12
|
|
33612
34073
|
} from "@ibiz-template/core";
|
|
@@ -33886,7 +34347,7 @@ var TreeGridExController = class extends TreeController {
|
|
|
33886
34347
|
throw new RuntimeError63("\u6682\u4E0D\u652F\u6301\u65B0\u5EFA");
|
|
33887
34348
|
}
|
|
33888
34349
|
if (!updateAppDEActionId) {
|
|
33889
|
-
throw new
|
|
34350
|
+
throw new RuntimeModelError69(nodeModel, "\u6811\u8282\u70B9\u6CA1\u6709\u914D\u7F6E\u66F4\u65B0\u5B9E\u4F53\u884C\u4E3A");
|
|
33890
34351
|
}
|
|
33891
34352
|
const deName = calcDeCodeNameById(appDataEntityId);
|
|
33892
34353
|
const tempContext = this.context.clone();
|
|
@@ -34157,7 +34618,7 @@ var TreeGridExColumnController = class {
|
|
|
34157
34618
|
import {
|
|
34158
34619
|
DataTypes as DataTypes5,
|
|
34159
34620
|
RuntimeError as RuntimeError64,
|
|
34160
|
-
RuntimeModelError as
|
|
34621
|
+
RuntimeModelError as RuntimeModelError70
|
|
34161
34622
|
} from "@ibiz-template/core";
|
|
34162
34623
|
import { clone as clone32 } from "ramda";
|
|
34163
34624
|
import dayjs7 from "dayjs";
|
|
@@ -34188,7 +34649,7 @@ var TreeGridExNodeColumnController = class {
|
|
|
34188
34649
|
}
|
|
34189
34650
|
);
|
|
34190
34651
|
if (!nodeColumn || !nodeDataItem) {
|
|
34191
|
-
throw new
|
|
34652
|
+
throw new RuntimeModelError70(
|
|
34192
34653
|
nodeModel,
|
|
34193
34654
|
"\u8282\u70B9\u6CA1\u6709\u914D\u7F6E\u5BF9\u5E94\u8868\u683C\u5217".concat(this.fieldColumn.name, "\u7684\u6570\u636E\u9879")
|
|
34194
34655
|
);
|
|
@@ -34202,7 +34663,7 @@ var TreeGridExNodeColumnController = class {
|
|
|
34202
34663
|
}
|
|
34203
34664
|
);
|
|
34204
34665
|
if (!nodeEditItem) {
|
|
34205
|
-
throw new
|
|
34666
|
+
throw new RuntimeModelError70(
|
|
34206
34667
|
nodeModel,
|
|
34207
34668
|
"\u6CA1\u6709\u627E\u5230\u5BF9\u5E94\u8868\u683C\u5217".concat(this.fieldColumn.name, "\u7684\u7F16\u8F91\u9879\u6A21\u578B")
|
|
34208
34669
|
);
|
|
@@ -34702,7 +35163,7 @@ var TreeGridExUAColumnController = class extends TreeGridExColumnController {
|
|
|
34702
35163
|
};
|
|
34703
35164
|
|
|
34704
35165
|
// src/controller/control/tree-grid/tree-grid.controller.ts
|
|
34705
|
-
import { RuntimeModelError as
|
|
35166
|
+
import { RuntimeModelError as RuntimeModelError71 } from "@ibiz-template/core";
|
|
34706
35167
|
var TreeGridController = class extends GridController {
|
|
34707
35168
|
constructor() {
|
|
34708
35169
|
super(...arguments);
|
|
@@ -34747,10 +35208,10 @@ var TreeGridController = class extends GridController {
|
|
|
34747
35208
|
return item.treeColumnMode === 2 || item.treeColumnMode === 3;
|
|
34748
35209
|
});
|
|
34749
35210
|
if (!treeGridParent) {
|
|
34750
|
-
throw new
|
|
35211
|
+
throw new RuntimeModelError71(this.model, "\u6811\u8868\u683C\u65E0\u503C\u5217\u6A21\u5F0F");
|
|
34751
35212
|
}
|
|
34752
35213
|
if (!treeGridValue) {
|
|
34753
|
-
throw new
|
|
35214
|
+
throw new RuntimeModelError71(this.model, "\u6811\u8868\u683C\u65E0\u7236\u503C\u5217\u6A21\u5F0F");
|
|
34754
35215
|
}
|
|
34755
35216
|
this.treeGridValueField = treeGridValue.appDEFieldId.toLowerCase();
|
|
34756
35217
|
this.treeGridParentField = treeGridParent.appDEFieldId.toLowerCase();
|
|
@@ -35497,7 +35958,7 @@ var ReportPanelController = class extends ControlController {
|
|
|
35497
35958
|
import {
|
|
35498
35959
|
awaitTimeout as awaitTimeout4,
|
|
35499
35960
|
RuntimeError as RuntimeError66,
|
|
35500
|
-
RuntimeModelError as
|
|
35961
|
+
RuntimeModelError as RuntimeModelError72
|
|
35501
35962
|
} from "@ibiz-template/core";
|
|
35502
35963
|
|
|
35503
35964
|
// src/controller/control/gantt/gantt.service.ts
|
|
@@ -35894,7 +36355,7 @@ var GanttController = class extends TreeGridExController {
|
|
|
35894
36355
|
}
|
|
35895
36356
|
));
|
|
35896
36357
|
if (result === -1) {
|
|
35897
|
-
throw new
|
|
36358
|
+
throw new RuntimeModelError72(
|
|
35898
36359
|
nodeModel,
|
|
35899
36360
|
"\u7F3A\u5C11".concat(nodeModel.id.toLowerCase(), "_opendata\u7684\u89C6\u56FE\u903B\u8F91")
|
|
35900
36361
|
);
|
|
@@ -37248,7 +37709,7 @@ var ViewEngineBase = class {
|
|
|
37248
37709
|
};
|
|
37249
37710
|
|
|
37250
37711
|
// src/engine/md-view.engine.ts
|
|
37251
|
-
import { RuntimeModelError as
|
|
37712
|
+
import { RuntimeModelError as RuntimeModelError73 } from "@ibiz-template/core";
|
|
37252
37713
|
import { clone as clone34 } from "ramda";
|
|
37253
37714
|
var MDViewEngine = class extends ViewEngineBase {
|
|
37254
37715
|
/**
|
|
@@ -37505,7 +37966,7 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
37505
37966
|
view: this.view
|
|
37506
37967
|
}));
|
|
37507
37968
|
if (result === -1) {
|
|
37508
|
-
throw new
|
|
37969
|
+
throw new RuntimeModelError73(this.view.model, "\u7F3A\u5C11opendata\u7684\u89C6\u56FE\u903B\u8F91");
|
|
37509
37970
|
} else {
|
|
37510
37971
|
return {
|
|
37511
37972
|
cancel: !result.ok
|
|
@@ -37528,7 +37989,7 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
37528
37989
|
(item) => item.id === "newdata"
|
|
37529
37990
|
);
|
|
37530
37991
|
if (!openAppViewLogic) {
|
|
37531
|
-
throw new
|
|
37992
|
+
throw new RuntimeModelError73(this.view.model, "\u7F3A\u5C11newdata\u7684\u89C6\u56FE\u903B\u8F91");
|
|
37532
37993
|
}
|
|
37533
37994
|
const params = clone34(this.view.params);
|
|
37534
37995
|
if (copyMode) {
|
|
@@ -37542,7 +38003,7 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
37542
38003
|
view: this.view
|
|
37543
38004
|
}));
|
|
37544
38005
|
if (result === -1) {
|
|
37545
|
-
throw new
|
|
38006
|
+
throw new RuntimeModelError73(this.view.model, "\u7F3A\u5C11newdata\u7684\u89C6\u56FE\u903B\u8F91");
|
|
37546
38007
|
} else {
|
|
37547
38008
|
return {
|
|
37548
38009
|
cancel: !result.ok
|
|
@@ -37965,13 +38426,13 @@ var ScriptExecutor = class extends LogicExecutor {
|
|
|
37965
38426
|
};
|
|
37966
38427
|
|
|
37967
38428
|
// src/logic-scheduler/executor/app-de-ui-logic-executor.ts
|
|
37968
|
-
import { RuntimeModelError as
|
|
38429
|
+
import { RuntimeModelError as RuntimeModelError74 } from "@ibiz-template/core";
|
|
37969
38430
|
var AppDEUILogicExecutor = class extends LogicExecutor {
|
|
37970
38431
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
37971
38432
|
execute(executeParams) {
|
|
37972
38433
|
const { appDEUILogicId, appDataEntityId } = this.logic;
|
|
37973
38434
|
if (!appDEUILogicId) {
|
|
37974
|
-
throw new
|
|
38435
|
+
throw new RuntimeModelError74(this.logic, "\u6CA1\u6709\u914D\u7F6E\u5B9E\u4F53\u754C\u9762\u903B\u8F91");
|
|
37975
38436
|
}
|
|
37976
38437
|
return execUILogic(appDEUILogicId, appDataEntityId, executeParams);
|
|
37977
38438
|
}
|
|
@@ -38430,7 +38891,7 @@ var ItemDynaLogicTrigger = class extends LogicTrigger {
|
|
|
38430
38891
|
};
|
|
38431
38892
|
|
|
38432
38893
|
// src/logic-scheduler/trigger/timer-trigger.ts
|
|
38433
|
-
import { RuntimeError as RuntimeError73, RuntimeModelError as
|
|
38894
|
+
import { RuntimeError as RuntimeError73, RuntimeModelError as RuntimeModelError75 } from "@ibiz-template/core";
|
|
38434
38895
|
var TimerTrigger = class extends LogicTrigger {
|
|
38435
38896
|
constructor() {
|
|
38436
38897
|
super(...arguments);
|
|
@@ -38438,7 +38899,7 @@ var TimerTrigger = class extends LogicTrigger {
|
|
|
38438
38899
|
}
|
|
38439
38900
|
start() {
|
|
38440
38901
|
if (!this.logic.timer) {
|
|
38441
|
-
throw new
|
|
38902
|
+
throw new RuntimeModelError75(this.logic, "\u5B9A\u65F6\u5668\u7F3A\u5C11\u5B9A\u65F6\u95F4\u9694");
|
|
38442
38903
|
}
|
|
38443
38904
|
this.timer = setInterval(() => {
|
|
38444
38905
|
if (!this.scheduler.defaultParamsCb) {
|
|
@@ -38460,7 +38921,7 @@ var TimerTrigger = class extends LogicTrigger {
|
|
|
38460
38921
|
import {
|
|
38461
38922
|
ModelError as ModelError34,
|
|
38462
38923
|
RuntimeError as RuntimeError74,
|
|
38463
|
-
RuntimeModelError as
|
|
38924
|
+
RuntimeModelError as RuntimeModelError76
|
|
38464
38925
|
} from "@ibiz-template/core";
|
|
38465
38926
|
import { notNilEmpty as notNilEmpty10 } from "qx-util";
|
|
38466
38927
|
var AppUILogicExecutor = class extends LogicExecutor {
|
|
@@ -38506,7 +38967,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
38506
38967
|
} else {
|
|
38507
38968
|
openViewRef = appUILogic.openDataAppView;
|
|
38508
38969
|
if (!openViewRef) {
|
|
38509
|
-
throw new
|
|
38970
|
+
throw new RuntimeModelError76(
|
|
38510
38971
|
appUILogic,
|
|
38511
38972
|
"opendata\u89C6\u56FE\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u9ED8\u8BA4\u6253\u5F00\u89C6\u56FE"
|
|
38512
38973
|
);
|
|
@@ -38514,7 +38975,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
38514
38975
|
}
|
|
38515
38976
|
const openView = openViewRef.refAppViewId;
|
|
38516
38977
|
if (!openView) {
|
|
38517
|
-
throw new
|
|
38978
|
+
throw new RuntimeModelError76(
|
|
38518
38979
|
appUILogic,
|
|
38519
38980
|
"opendata\u89C6\u56FE\u903B\u8F91\u7684\u9ED8\u8BA4\u6253\u5F00\u89C6\u56FE\u6CA1\u6709\u5B9E\u9645\u5F15\u7528\u89C6\u56FE"
|
|
38520
38981
|
);
|
|
@@ -38544,7 +39005,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
38544
39005
|
);
|
|
38545
39006
|
const typeFileName = appDataEntity.formTypeAppDEFieldId || appDataEntity.dataTypeAppDEFieldId;
|
|
38546
39007
|
if (!typeFileName) {
|
|
38547
|
-
throw new
|
|
39008
|
+
throw new RuntimeModelError76(
|
|
38548
39009
|
appUILogic,
|
|
38549
39010
|
"".concat(appDataEntity.codeName, "[\u591A\u8868\u5355\u5B9E\u4F53] or [\u7D22\u5F15\u5B9E\u4F53]\u7F3A\u5C11\u7C7B\u578B\u5C5E\u6027\u914D\u7F6E")
|
|
38550
39011
|
);
|
|
@@ -38552,7 +39013,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
38552
39013
|
const { data } = parameters;
|
|
38553
39014
|
const formTypeValue = data[0][typeFileName];
|
|
38554
39015
|
if (!formTypeValue) {
|
|
38555
|
-
throw new
|
|
39016
|
+
throw new RuntimeModelError76(appUILogic, "\u6570\u636E\u6E90\u65E0\u8868\u5355\u7C7B\u578B\u5E94\u7528\u5B9E\u4F53\u5C5E\u6027\u503C");
|
|
38556
39017
|
}
|
|
38557
39018
|
const openViewRefs = appUILogic.openDataAppViews;
|
|
38558
39019
|
const findView = openViewRefs == null ? void 0 : openViewRefs.find((item) => item.refMode === formTypeValue);
|
|
@@ -38594,7 +39055,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
38594
39055
|
return viewRef.refMode.toLowerCase() !== parentDeName;
|
|
38595
39056
|
});
|
|
38596
39057
|
if (!newViewRef) {
|
|
38597
|
-
throw new
|
|
39058
|
+
throw new RuntimeModelError76(
|
|
38598
39059
|
appUILogic,
|
|
38599
39060
|
"\u6CA1\u6709\u627E\u5230\u6279\u6DFB\u52A0\u9700\u8981\u6253\u5F00\u7684\u9009\u62E9\u89C6\u56FE"
|
|
38600
39061
|
);
|
|
@@ -38604,7 +39065,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
38604
39065
|
} else {
|
|
38605
39066
|
newViewRef = newDataAppView;
|
|
38606
39067
|
if (!newViewRef || !newViewRef.refAppViewId) {
|
|
38607
|
-
throw new
|
|
39068
|
+
throw new RuntimeModelError76(
|
|
38608
39069
|
appUILogic,
|
|
38609
39070
|
"newdata\u89C6\u56FE\u903B\u8F91\u6CA1\u6709\u914D\u7F6E\u9ED8\u8BA4\u65B0\u5EFA\u6570\u636E\u89C6\u56FE"
|
|
38610
39071
|
);
|
|
@@ -38668,7 +39129,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
38668
39129
|
const { wizardAppView, newDataAppViews } = appUILogic;
|
|
38669
39130
|
const { context, params, ...rest } = parameters;
|
|
38670
39131
|
if (!wizardAppView || !wizardAppView.refAppViewId) {
|
|
38671
|
-
throw new
|
|
39132
|
+
throw new RuntimeModelError76(appUILogic, "\u7F3A\u5C11\u9ED8\u8BA4\u7D22\u5F15\u5B9E\u4F53\u9009\u62E9\u89C6\u56FE");
|
|
38672
39133
|
}
|
|
38673
39134
|
const result = await ibiz.commands.execute(
|
|
38674
39135
|
OpenAppViewCommand.TAG,
|
|
@@ -38719,7 +39180,7 @@ var AppUILogicExecutor = class extends LogicExecutor {
|
|
|
38719
39180
|
const minorDERs = selfDe.minorAppDERSs;
|
|
38720
39181
|
const pickParentDeName = newViewRef.refMode.toLowerCase();
|
|
38721
39182
|
if (!minorDERs) {
|
|
38722
|
-
throw new
|
|
39183
|
+
throw new RuntimeModelError76(selfDe, "\u5B9E\u4F53\u6CA1\u6709\u4ECE\u5173\u7CFB\u96C6\u5408\uFF01");
|
|
38723
39184
|
}
|
|
38724
39185
|
let pickParentFieldName = "";
|
|
38725
39186
|
minorDERs == null ? void 0 : minorDERs.forEach((item) => {
|
|
@@ -38816,12 +39277,12 @@ var ControlEventTrigger = class extends LogicTrigger {
|
|
|
38816
39277
|
};
|
|
38817
39278
|
|
|
38818
39279
|
// src/logic-scheduler/executor/app-ui-action-executor.ts
|
|
38819
|
-
import { RuntimeModelError as
|
|
39280
|
+
import { RuntimeModelError as RuntimeModelError77 } from "@ibiz-template/core";
|
|
38820
39281
|
var AppDEUIActionExecutor = class extends LogicExecutor {
|
|
38821
39282
|
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
38822
39283
|
execute(executeParams) {
|
|
38823
39284
|
if (!this.logic.appDEUIActionId) {
|
|
38824
|
-
throw new
|
|
39285
|
+
throw new RuntimeModelError77(
|
|
38825
39286
|
this.logic,
|
|
38826
39287
|
"\u903B\u8F91\u4E2D\u7F3A\u5C11\u89E6\u53D1\u5E94\u7528\u5B9E\u4F53\u754C\u9762\u884C\u4E3Aid"
|
|
38827
39288
|
);
|
|
@@ -39014,6 +39475,7 @@ export {
|
|
|
39014
39475
|
AppDECounter,
|
|
39015
39476
|
AppDECounterProvider,
|
|
39016
39477
|
AppDataEntity,
|
|
39478
|
+
AppDataUploadViewController,
|
|
39017
39479
|
AppFuncCommand,
|
|
39018
39480
|
AppMenuController,
|
|
39019
39481
|
AppMenuIconViewController,
|
|
@@ -39237,12 +39699,14 @@ export {
|
|
|
39237
39699
|
WizardPanelService,
|
|
39238
39700
|
WorkFlowService,
|
|
39239
39701
|
asyncImportData,
|
|
39702
|
+
asyncImportData2,
|
|
39240
39703
|
calcContentAlignStyle,
|
|
39241
39704
|
calcDeCodeNameById,
|
|
39242
39705
|
calcDynaClass,
|
|
39243
39706
|
calcDynaSysParams,
|
|
39244
39707
|
calcFilterModelBySchema,
|
|
39245
39708
|
calcGridLayoutPos,
|
|
39709
|
+
calcImportSchemaData,
|
|
39246
39710
|
calcLayoutHeightWidth,
|
|
39247
39711
|
calcMainStateOPPrivsStrs,
|
|
39248
39712
|
calcNavParams,
|
|
@@ -39255,12 +39719,16 @@ export {
|
|
|
39255
39719
|
convertNavData,
|
|
39256
39720
|
convertNavDataByArray,
|
|
39257
39721
|
convertObjectToNavParams,
|
|
39722
|
+
createImportSchema,
|
|
39723
|
+
deleteImportSchema,
|
|
39724
|
+
downloadImportTemplate,
|
|
39258
39725
|
execDELogic,
|
|
39259
39726
|
execDELogicAction,
|
|
39260
39727
|
execDELogicById,
|
|
39261
39728
|
execFieldLogics,
|
|
39262
39729
|
execUILogic,
|
|
39263
39730
|
exportData,
|
|
39731
|
+
fetchImportSchemas,
|
|
39264
39732
|
fieldValueToBoolean,
|
|
39265
39733
|
filterFieldLogics,
|
|
39266
39734
|
filterNode2SearchCond,
|
|
@@ -39288,13 +39756,16 @@ export {
|
|
|
39288
39756
|
getCtrlTeleportParams,
|
|
39289
39757
|
getDEMethodProvider,
|
|
39290
39758
|
getDERedirectToView,
|
|
39759
|
+
getDataImportModels,
|
|
39291
39760
|
getDeACMode,
|
|
39761
|
+
getDefaultDataImport,
|
|
39292
39762
|
getDefaultValue,
|
|
39293
39763
|
getEditorProvider,
|
|
39294
39764
|
getEntitySchema,
|
|
39295
39765
|
getErrorViewProvider,
|
|
39296
39766
|
getFormDetailProvider,
|
|
39297
39767
|
getGridColumnProvider,
|
|
39768
|
+
getImportSchema,
|
|
39298
39769
|
getInternalMessageProvider,
|
|
39299
39770
|
getMatchResPath,
|
|
39300
39771
|
getOriginData,
|
|
@@ -39320,6 +39791,7 @@ export {
|
|
|
39320
39791
|
hasDeCodeName,
|
|
39321
39792
|
hasSubRoute,
|
|
39322
39793
|
importData,
|
|
39794
|
+
importData2,
|
|
39323
39795
|
install2 as install,
|
|
39324
39796
|
installCommand,
|
|
39325
39797
|
isDataContainer,
|
|
@@ -39328,6 +39800,7 @@ export {
|
|
|
39328
39800
|
isSimpleItems,
|
|
39329
39801
|
isValueChange,
|
|
39330
39802
|
matchMainState,
|
|
39803
|
+
openDataImport,
|
|
39331
39804
|
openRedirectView,
|
|
39332
39805
|
parseSubFieldInfo,
|
|
39333
39806
|
parseUserParams,
|
|
@@ -39352,9 +39825,11 @@ export {
|
|
|
39352
39825
|
registerUIActionProvider,
|
|
39353
39826
|
registerUILogicNodeProvider,
|
|
39354
39827
|
registerViewProvider,
|
|
39828
|
+
selectAndImport,
|
|
39355
39829
|
strContain,
|
|
39356
39830
|
testCond,
|
|
39357
39831
|
toLocalOpenWFRedirectView,
|
|
39832
|
+
updateImportSchema,
|
|
39358
39833
|
validateFilterNodes,
|
|
39359
39834
|
verifyDeRules,
|
|
39360
39835
|
verifyFormGroupLogic,
|