@ibiz-template/runtime 0.7.41-alpha.8 → 0.7.41-alpha.9
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 +109 -70
- package/dist/index.system.min.js +1 -1
- package/out/controller/common/editor/code-list-editor.controller.d.ts.map +1 -1
- package/out/controller/common/editor/code-list-editor.controller.js +6 -0
- package/out/engine/md-view.engine.d.ts +2 -2
- package/out/engine/md-view.engine.d.ts.map +1 -1
- package/out/engine/md-view.engine.js +2 -1
- package/out/engine/view-base.engine.d.ts +2 -2
- package/out/engine/view-base.engine.d.ts.map +1 -1
- package/out/interface/api/call/i-api-index-view.call.d.ts +20 -0
- package/out/interface/api/call/i-api-index-view.call.d.ts.map +1 -0
- package/out/interface/api/call/i-api-index-view.call.js +1 -0
- package/out/interface/api/call/i-api-md-custom-view.call.d.ts +79 -0
- package/out/interface/api/call/i-api-md-custom-view.call.d.ts.map +1 -0
- package/out/interface/api/call/i-api-md-custom-view.call.js +1 -0
- package/out/interface/api/call/i-api-opt-view.call.d.ts +10 -0
- package/out/interface/api/call/i-api-opt-view.call.d.ts.map +1 -1
- package/out/interface/api/call/i-api-portal-view.call.d.ts +20 -0
- package/out/interface/api/call/i-api-portal-view.call.d.ts.map +1 -0
- package/out/interface/api/call/i-api-portal-view.call.js +1 -0
- package/out/interface/api/call/index.d.ts +3 -0
- package/out/interface/api/call/index.d.ts.map +1 -1
- package/out/interface/api/util/i-api-file-util.d.ts +3 -3
- package/out/interface/api/util/i-api-file-util.d.ts.map +1 -1
- package/out/locale/en/index.d.ts +1 -0
- package/out/locale/en/index.d.ts.map +1 -1
- package/out/locale/en/index.js +1 -0
- package/out/locale/zh-CN/index.d.ts +1 -0
- package/out/locale/zh-CN/index.d.ts.map +1 -1
- package/out/locale/zh-CN/index.js +1 -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 +2 -1
- package/out/service/utils/util/util.d.ts +7 -0
- package/out/service/utils/util/util.d.ts.map +1 -1
- package/out/service/utils/util/util.js +26 -0
- package/out/ui-action/provider/front-ui-action-provider.d.ts.map +1 -1
- package/out/ui-action/provider/front-ui-action-provider.js +16 -4
- package/out/ui-action/provider/ui-action-provider-base.d.ts.map +1 -1
- package/out/ui-action/provider/ui-action-provider-base.js +7 -1
- package/out/utils/open-redirect-view/open-redirect-view.js +3 -3
- package/package.json +3 -3
package/dist/index.esm.js
CHANGED
|
@@ -21270,7 +21270,7 @@ async function calcDERdTag(entity, rdView, params, data) {
|
|
|
21270
21270
|
const typeFieldId = rdView.typeAppDEFieldId;
|
|
21271
21271
|
if (typeFieldId) {
|
|
21272
21272
|
const { codeName } = findFieldById(entity, typeFieldId);
|
|
21273
|
-
const value = data[codeName.toLowerCase()];
|
|
21273
|
+
const value = "".concat(data[codeName.toLowerCase()]);
|
|
21274
21274
|
if (notNilEmpty3(value)) {
|
|
21275
21275
|
if (value.startsWith("view://")) {
|
|
21276
21276
|
return value;
|
|
@@ -21296,12 +21296,12 @@ async function calcDERdTag(entity, rdView, params, data) {
|
|
|
21296
21296
|
let typeValue = "";
|
|
21297
21297
|
if (entity.indexTypeAppDEFieldId) {
|
|
21298
21298
|
const { codeName } = findFieldById(entity, entity.indexTypeAppDEFieldId);
|
|
21299
|
-
typeValue = data[codeName.toLowerCase()];
|
|
21299
|
+
typeValue = "".concat(data[codeName.toLowerCase()]);
|
|
21300
21300
|
}
|
|
21301
21301
|
if (isNilOrEmpty2(typeValue)) {
|
|
21302
21302
|
if (entity.formTypeAppDEFieldId) {
|
|
21303
21303
|
const { codeName } = findFieldById(entity, entity.formTypeAppDEFieldId);
|
|
21304
|
-
typeValue = data[codeName.toLowerCase()];
|
|
21304
|
+
typeValue = "".concat(data[codeName.toLowerCase()]);
|
|
21305
21305
|
}
|
|
21306
21306
|
}
|
|
21307
21307
|
if (notNilEmpty3(typeValue)) {
|
|
@@ -25628,6 +25628,80 @@ var CodeListDataItem = class {
|
|
|
25628
25628
|
}
|
|
25629
25629
|
};
|
|
25630
25630
|
|
|
25631
|
+
// src/service/utils/util/util.ts
|
|
25632
|
+
function fieldValueToBoolean(value) {
|
|
25633
|
+
if (typeof value === "boolean") {
|
|
25634
|
+
return value;
|
|
25635
|
+
}
|
|
25636
|
+
if (typeof value === "number") {
|
|
25637
|
+
return value > 0;
|
|
25638
|
+
}
|
|
25639
|
+
if (typeof value === "string") {
|
|
25640
|
+
switch (value) {
|
|
25641
|
+
case "true":
|
|
25642
|
+
return true;
|
|
25643
|
+
case "false":
|
|
25644
|
+
return false;
|
|
25645
|
+
default: {
|
|
25646
|
+
const num = Number(value);
|
|
25647
|
+
return Number.isNaN(num) ? !!value : num > 0;
|
|
25648
|
+
}
|
|
25649
|
+
}
|
|
25650
|
+
} else {
|
|
25651
|
+
return !!value;
|
|
25652
|
+
}
|
|
25653
|
+
}
|
|
25654
|
+
function convertToObject(input) {
|
|
25655
|
+
const result = {};
|
|
25656
|
+
if (!input) {
|
|
25657
|
+
return result;
|
|
25658
|
+
}
|
|
25659
|
+
const pairs = input.split(",");
|
|
25660
|
+
if (pairs && pairs.length > 0) {
|
|
25661
|
+
pairs.forEach((pair) => {
|
|
25662
|
+
const [key, value] = pair.split(":");
|
|
25663
|
+
result[key] = parseInt(value, 10);
|
|
25664
|
+
});
|
|
25665
|
+
}
|
|
25666
|
+
return result;
|
|
25667
|
+
}
|
|
25668
|
+
function convertArrayToListMap(arr) {
|
|
25669
|
+
const result = {};
|
|
25670
|
+
arr.forEach((obj) => {
|
|
25671
|
+
result[obj.srflistmapfield] = obj;
|
|
25672
|
+
delete obj.srflistmapfield;
|
|
25673
|
+
});
|
|
25674
|
+
return result;
|
|
25675
|
+
}
|
|
25676
|
+
function convertListMapToArray(obj) {
|
|
25677
|
+
const result = [];
|
|
25678
|
+
Object.keys(obj).forEach((key) => {
|
|
25679
|
+
const temp = obj[key];
|
|
25680
|
+
temp.srflistmapfield = key;
|
|
25681
|
+
result.push(temp);
|
|
25682
|
+
});
|
|
25683
|
+
return result;
|
|
25684
|
+
}
|
|
25685
|
+
function getTempContext(context) {
|
|
25686
|
+
const result = {};
|
|
25687
|
+
const presetContext = [
|
|
25688
|
+
"srfappid",
|
|
25689
|
+
"srfsimple",
|
|
25690
|
+
"srfviewid",
|
|
25691
|
+
"srfrunmode",
|
|
25692
|
+
"srfreadonly",
|
|
25693
|
+
"srfnavctrlid",
|
|
25694
|
+
"srfsessionid",
|
|
25695
|
+
"srfnavlogicid"
|
|
25696
|
+
];
|
|
25697
|
+
Object.keys(context).forEach((key) => {
|
|
25698
|
+
if (!presetContext.includes(key)) {
|
|
25699
|
+
result[key] = context[key];
|
|
25700
|
+
}
|
|
25701
|
+
});
|
|
25702
|
+
return result;
|
|
25703
|
+
}
|
|
25704
|
+
|
|
25631
25705
|
// src/service/utils/dynamic-code-list/dynamic-code-list.ts
|
|
25632
25706
|
var DynamicCodeListCache = class {
|
|
25633
25707
|
constructor(codeList) {
|
|
@@ -26014,7 +26088,7 @@ var DynamicCodeListCache = class {
|
|
|
26014
26088
|
if (!this.codeList.enableCache) {
|
|
26015
26089
|
return this.load(context, params);
|
|
26016
26090
|
}
|
|
26017
|
-
const key = this.isOperatorType ? this.codeList.codeListTag : JSON.stringify(
|
|
26091
|
+
const key = this.isOperatorType ? this.codeList.codeListTag : JSON.stringify(getTempContext(context)) + JSON.stringify(params);
|
|
26018
26092
|
if (this.cache.has(key)) {
|
|
26019
26093
|
const cacheData2 = this.cache.get(key);
|
|
26020
26094
|
if (cacheData2.expirationTime > (/* @__PURE__ */ new Date()).getTime()) {
|
|
@@ -26736,61 +26810,6 @@ var SearchFilter = class {
|
|
|
26736
26810
|
}
|
|
26737
26811
|
};
|
|
26738
26812
|
|
|
26739
|
-
// src/service/utils/util/util.ts
|
|
26740
|
-
function fieldValueToBoolean(value) {
|
|
26741
|
-
if (typeof value === "boolean") {
|
|
26742
|
-
return value;
|
|
26743
|
-
}
|
|
26744
|
-
if (typeof value === "number") {
|
|
26745
|
-
return value > 0;
|
|
26746
|
-
}
|
|
26747
|
-
if (typeof value === "string") {
|
|
26748
|
-
switch (value) {
|
|
26749
|
-
case "true":
|
|
26750
|
-
return true;
|
|
26751
|
-
case "false":
|
|
26752
|
-
return false;
|
|
26753
|
-
default: {
|
|
26754
|
-
const num = Number(value);
|
|
26755
|
-
return Number.isNaN(num) ? !!value : num > 0;
|
|
26756
|
-
}
|
|
26757
|
-
}
|
|
26758
|
-
} else {
|
|
26759
|
-
return !!value;
|
|
26760
|
-
}
|
|
26761
|
-
}
|
|
26762
|
-
function convertToObject(input) {
|
|
26763
|
-
const result = {};
|
|
26764
|
-
if (!input) {
|
|
26765
|
-
return result;
|
|
26766
|
-
}
|
|
26767
|
-
const pairs = input.split(",");
|
|
26768
|
-
if (pairs && pairs.length > 0) {
|
|
26769
|
-
pairs.forEach((pair) => {
|
|
26770
|
-
const [key, value] = pair.split(":");
|
|
26771
|
-
result[key] = parseInt(value, 10);
|
|
26772
|
-
});
|
|
26773
|
-
}
|
|
26774
|
-
return result;
|
|
26775
|
-
}
|
|
26776
|
-
function convertArrayToListMap(arr) {
|
|
26777
|
-
const result = {};
|
|
26778
|
-
arr.forEach((obj) => {
|
|
26779
|
-
result[obj.srflistmapfield] = obj;
|
|
26780
|
-
delete obj.srflistmapfield;
|
|
26781
|
-
});
|
|
26782
|
-
return result;
|
|
26783
|
-
}
|
|
26784
|
-
function convertListMapToArray(obj) {
|
|
26785
|
-
const result = [];
|
|
26786
|
-
Object.keys(obj).forEach((key) => {
|
|
26787
|
-
const temp = obj[key];
|
|
26788
|
-
temp.srflistmapfield = key;
|
|
26789
|
-
result.push(temp);
|
|
26790
|
-
});
|
|
26791
|
-
return result;
|
|
26792
|
-
}
|
|
26793
|
-
|
|
26794
26813
|
// src/service/utils/dyna-sys-params/dyna-sys-params.ts
|
|
26795
26814
|
async function calcDynaSysParams(appDataEntityId, context, opts = {}) {
|
|
26796
26815
|
const appId2 = opts.appId || context.srfappid;
|
|
@@ -36916,9 +36935,15 @@ var CodeListEditorController = class extends EditorController {
|
|
|
36916
36935
|
if (this.editorParams.allItems) {
|
|
36917
36936
|
this.allItems = this.toBoolean(this.editorParams.allItems);
|
|
36918
36937
|
}
|
|
36938
|
+
if (this.editorParams.allitems) {
|
|
36939
|
+
this.allItems = this.toBoolean(this.editorParams.allitems);
|
|
36940
|
+
}
|
|
36919
36941
|
if (this.editorParams.itemsText) {
|
|
36920
36942
|
this.itemsText = this.editorParams.itemsText;
|
|
36921
36943
|
}
|
|
36944
|
+
if (this.editorParams.itemstext) {
|
|
36945
|
+
this.itemsText = this.editorParams.itemstext;
|
|
36946
|
+
}
|
|
36922
36947
|
}
|
|
36923
36948
|
}
|
|
36924
36949
|
/**
|
|
@@ -41110,6 +41135,10 @@ var UIActionProviderBase = class {
|
|
|
41110
41135
|
presetParams.ignoredirtycheck = resultParams.ignoredirtycheck;
|
|
41111
41136
|
delete resultParams.ignoredirtycheck;
|
|
41112
41137
|
}
|
|
41138
|
+
if (resultParams.hasOwnProperty("srfexportdataset")) {
|
|
41139
|
+
presetParams.srfexportdataset = resultParams.srfexportdataset;
|
|
41140
|
+
delete resultParams.srfexportdataset;
|
|
41141
|
+
}
|
|
41113
41142
|
return { resultContext, resultData, resultParams, presetParams };
|
|
41114
41143
|
}
|
|
41115
41144
|
/**
|
|
@@ -41555,13 +41584,8 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
41555
41584
|
* @return {*}
|
|
41556
41585
|
*/
|
|
41557
41586
|
async executeDataExport(action, args) {
|
|
41558
|
-
var _a3;
|
|
41559
|
-
const { resultContext, resultParams } = await this.handleParams(
|
|
41560
|
-
action,
|
|
41561
|
-
args.context,
|
|
41562
|
-
args.data,
|
|
41563
|
-
args.params
|
|
41564
|
-
);
|
|
41587
|
+
var _a3, _b2;
|
|
41588
|
+
const { resultContext, resultParams, presetParams } = await this.handleParams(action, args.context, args.data, args.params);
|
|
41565
41589
|
const appDataEntity = await ibiz.hub.getAppDataEntity(
|
|
41566
41590
|
action.appDataEntityId,
|
|
41567
41591
|
action.appId
|
|
@@ -41570,8 +41594,22 @@ var FrontUIActionProvider = class extends UIActionProviderBase {
|
|
|
41570
41594
|
return dataExport.id === action.appDEDataExportId;
|
|
41571
41595
|
});
|
|
41572
41596
|
if (appDEDataExport) {
|
|
41597
|
+
let exportDatasetCodeName = presetParams.srfexportdataset;
|
|
41598
|
+
if (!exportDatasetCodeName) {
|
|
41599
|
+
const defaultDataset = (_b2 = appDataEntity.appDEMethods) == null ? void 0 : _b2.find((appDEMethod) => {
|
|
41600
|
+
return appDEMethod.dataSetTag === "Default";
|
|
41601
|
+
});
|
|
41602
|
+
if (defaultDataset) {
|
|
41603
|
+
exportDatasetCodeName = defaultDataset.codeName;
|
|
41604
|
+
}
|
|
41605
|
+
}
|
|
41606
|
+
if (!exportDatasetCodeName) {
|
|
41607
|
+
throw new RuntimeError43(
|
|
41608
|
+
ibiz.i18n.t("runtime.uiAction.exportWithNoDataSet")
|
|
41609
|
+
);
|
|
41610
|
+
}
|
|
41573
41611
|
const resPath = calcResPath(resultContext, appDataEntity);
|
|
41574
|
-
const url = "".concat(resPath, "/").concat(appDataEntity.deapicodeName2, "/exportdata/
|
|
41612
|
+
const url = "".concat(resPath, "/").concat(appDataEntity.deapicodeName2, "/exportdata/").concat(exportDatasetCodeName);
|
|
41575
41613
|
const queryParam = { srfexporttag: appDEDataExport.codeName };
|
|
41576
41614
|
if (resultContext == null ? void 0 : resultContext.srfdatatype) {
|
|
41577
41615
|
Object.assign(queryParam, { srfdatatype: resultContext.srfdatatype });
|
|
@@ -77003,7 +77041,6 @@ var MDViewEngine = class extends ViewEngineBase {
|
|
|
77003
77041
|
this.refresh();
|
|
77004
77042
|
}
|
|
77005
77043
|
}
|
|
77006
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/explicit-module-boundary-types
|
|
77007
77044
|
async call(key, args) {
|
|
77008
77045
|
if (key === "Edit" /* EDIT */ || key === "View" /* VIEW */) {
|
|
77009
77046
|
return this.openData(args);
|
|
@@ -79600,7 +79637,8 @@ var en = {
|
|
|
79600
79637
|
viewParameterModalOption: "View parameter modalOption failed to parse: {error}",
|
|
79601
79638
|
withdrawalConfirmed: "Is the execution of the withdrawal confirmed?",
|
|
79602
79639
|
noFoundBehaviorModel: "No interface behavior model found for {actionId}.",
|
|
79603
|
-
noEnableAI: "AI support not enabled"
|
|
79640
|
+
noEnableAI: "AI support not enabled",
|
|
79641
|
+
exportWithNoDataSet: "Export data without specifying an export dataset"
|
|
79604
79642
|
},
|
|
79605
79643
|
uiLogic: {
|
|
79606
79644
|
interfaceConnectionConditional: "Interface Connection Conditional Logic Group Unconfigured Logic Item",
|
|
@@ -80247,7 +80285,8 @@ var zhCn = {
|
|
|
80247
80285
|
viewParameterModalOption: "\u89C6\u56FE\u53C2\u6570modalOption \u89E3\u6790\u5931\u8D25\uFF1A{error}",
|
|
80248
80286
|
withdrawalConfirmed: "\u662F\u5426\u786E\u8BA4\u6267\u884C\u64A4\u56DE\u64CD\u4F5C\uFF1F",
|
|
80249
80287
|
noFoundBehaviorModel: "\u6CA1\u627E\u5230{actionId}\u7684\u754C\u9762\u884C\u4E3A\u6A21\u578B",
|
|
80250
|
-
noEnableAI: "\u672A\u5F00\u542FAI\u652F\u6301"
|
|
80288
|
+
noEnableAI: "\u672A\u5F00\u542FAI\u652F\u6301",
|
|
80289
|
+
exportWithNoDataSet: "\u5BFC\u51FA\u6570\u636E\u672A\u6307\u5B9A\u5BFC\u51FA\u6570\u636E\u96C6"
|
|
80251
80290
|
},
|
|
80252
80291
|
uiLogic: {
|
|
80253
80292
|
interfaceConnectionConditional: "\u754C\u9762\u8FDE\u63A5\u6761\u4EF6\u903B\u8F91\u7EC4\u672A\u914D\u7F6E\u903B\u8F91\u9879",
|