@ibiz-template/runtime 0.4.15 → 0.4.17-dev.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +527 -362
- package/dist/index.system.min.js +2 -2
- package/out/app-hub.d.ts +8 -0
- package/out/app-hub.d.ts.map +1 -1
- package/out/app-hub.js +14 -1
- package/out/controller/common/base.controller.d.ts +1 -0
- package/out/controller/common/base.controller.d.ts.map +1 -1
- package/out/controller/common/base.controller.js +2 -0
- package/out/controller/common/view/view.controller.d.ts.map +1 -1
- package/out/controller/common/view/view.controller.js +9 -3
- package/out/controller/common/view/wf-step-trace-view.controller.d.ts.map +1 -1
- package/out/controller/common/view/wf-step-trace-view.controller.js +3 -2
- package/out/controller/control/calendar/calendar.service.d.ts +3 -3
- package/out/controller/control/calendar/calendar.service.d.ts.map +1 -1
- package/out/controller/control/calendar/calendar.service.js +2 -2
- package/out/controller/control/form/edit-form/edit-form.service.d.ts +18 -18
- package/out/controller/control/form/edit-form/edit-form.service.d.ts.map +1 -1
- package/out/controller/control/form/edit-form/edit-form.service.js +11 -11
- package/out/controller/control/form/form/form.service.d.ts +2 -2
- package/out/controller/control/form/form/form.service.d.ts.map +1 -1
- package/out/controller/control/form/form/form.service.js +1 -1
- package/out/controller/control/form/search-form/search-form.service.d.ts +2 -2
- package/out/controller/control/form/search-form/search-form.service.d.ts.map +1 -1
- package/out/controller/control/form/search-form/search-form.service.js +1 -1
- package/out/controller/control/gantt/gantt.controller.d.ts.map +1 -1
- package/out/controller/control/gantt/gantt.controller.js +1 -0
- package/out/controller/control/grid/grid/grid.controller.d.ts.map +1 -1
- package/out/controller/control/grid/grid/grid.controller.js +1 -1
- package/out/controller/control/grid/grid/grid.service.d.ts +2 -2
- package/out/controller/control/grid/grid/grid.service.d.ts.map +1 -1
- package/out/controller/control/grid/grid/grid.service.js +2 -2
- package/out/controller/control/kanban/kanban.service.d.ts +2 -2
- package/out/controller/control/kanban/kanban.service.d.ts.map +1 -1
- package/out/controller/control/kanban/kanban.service.js +1 -1
- package/out/controller/control/map/map.service.d.ts +1 -1
- package/out/controller/control/map/map.service.js +1 -1
- package/out/controller/control/report-panel/report-panel.service.d.ts +2 -2
- package/out/controller/control/report-panel/report-panel.service.d.ts.map +1 -1
- package/out/controller/control/report-panel/report-panel.service.js +1 -1
- package/out/controller/control/tree/tree.service.d.ts +2 -2
- package/out/controller/control/tree/tree.service.d.ts.map +1 -1
- package/out/controller/control/tree-grid-ex/tree-grid-ex.controller.d.ts.map +1 -1
- package/out/controller/control/tree-grid-ex/tree-grid-ex.controller.js +1 -0
- package/out/controller/control/wizard-panel/wizard-panel.service.d.ts +4 -4
- package/out/controller/control/wizard-panel/wizard-panel.service.d.ts.map +1 -1
- package/out/controller/control/wizard-panel/wizard-panel.service.js +2 -2
- package/out/controller/utils/value-default/value-default.d.ts +1 -1
- package/out/controller/utils/value-default/value-default.d.ts.map +1 -1
- package/out/de-logic/de-logic-context.d.ts +5 -5
- package/out/de-logic/de-logic-context.d.ts.map +1 -1
- package/out/de-logic/de-logic-context.js +1 -1
- package/out/de-logic/de-logic-link/de-logic-link-group-cond/de-logic-link-group-cond.d.ts +2 -2
- package/out/de-logic/de-logic-link/de-logic-link-group-cond/de-logic-link-group-cond.d.ts.map +1 -1
- package/out/de-logic/de-logic-link/de-logic-link-group-cond/de-logic-link-group-cond.js +1 -1
- package/out/de-logic/de-logic-link/de-logic-link-single-cond/de-logic-link-single-cond.d.ts +2 -2
- package/out/de-logic/de-logic-link/de-logic-link-single-cond/de-logic-link-single-cond.d.ts.map +1 -1
- package/out/de-logic/de-logic-link/de-logic-link-single-cond/de-logic-link-single-cond.js +1 -1
- package/out/de-logic/de-logic-link/de-logic-link.d.ts +1 -1
- package/out/de-logic/de-logic-link/de-logic-link.js +1 -1
- package/out/de-logic/de-logic-node/de-logic-node.d.ts +1 -1
- package/out/de-logic/de-logic-param/de-logic-param.d.ts +1 -1
- package/out/de-logic/de-logic-param/de-logic-param.js +1 -1
- package/out/de-logic/de-logic.d.ts +3 -3
- package/out/de-logic/de-logic.d.ts.map +1 -1
- package/out/de-logic/de-logic.js +2 -2
- package/out/de-logic/index.d.ts +8 -8
- package/out/de-logic/index.d.ts.map +1 -1
- package/out/de-logic/index.js +5 -5
- package/out/hub/config/app-config-service.d.ts +1 -0
- package/out/hub/config/app-config-service.d.ts.map +1 -1
- package/out/hub/config/app-config-service.js +1 -0
- package/out/hub/config/app-view-config-service.d.ts +20 -1
- package/out/hub/config/app-view-config-service.d.ts.map +1 -1
- package/out/hub/config/app-view-config-service.js +39 -6
- package/out/install.d.ts.map +1 -1
- package/out/install.js +3 -0
- package/out/interface/common/i-app-hub-service/i-app-hub-service.d.ts +8 -0
- package/out/interface/common/i-app-hub-service/i-app-hub-service.d.ts.map +1 -1
- package/out/interface/common/i-app-view-config-service/i-app-view-config-service.d.ts +8 -0
- package/out/interface/common/i-app-view-config-service/i-app-view-config-service.d.ts.map +1 -1
- package/out/interface/common/i-data-ability-params/i-data-ability-params.d.ts +1 -1
- package/out/interface/common/i-data-ability-params/i-data-ability-params.d.ts.map +1 -1
- package/out/interface/controller/controller/i.controller.d.ts +8 -0
- package/out/interface/controller/controller/i.controller.d.ts.map +1 -1
- package/out/interface/provider/i-de-method.provider.d.ts +10 -1
- package/out/interface/provider/i-de-method.provider.d.ts.map +1 -1
- package/out/interface/provider/i-grid-column.provider.d.ts +2 -2
- package/out/interface/provider/i-grid-column.provider.d.ts.map +1 -1
- package/out/interface/service/service/i-app-de.service.d.ts +49 -43
- package/out/interface/service/service/i-app-de.service.d.ts.map +1 -1
- package/out/interface/service/service/i-file.service.d.ts +2 -2
- package/out/interface/service/service/i-file.service.d.ts.map +1 -1
- package/out/interface/service/service/i-wf.service.d.ts +12 -12
- package/out/interface/service/service/i-wf.service.d.ts.map +1 -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 +0 -14
- package/out/service/de-service-util.d.ts +26 -13
- package/out/service/de-service-util.d.ts.map +1 -1
- package/out/service/de-service-util.js +45 -16
- package/out/service/dto/method.dto.d.ts +20 -8
- package/out/service/dto/method.dto.d.ts.map +1 -1
- package/out/service/dto/method.dto.js +33 -15
- package/out/service/service/authority/authority.service.d.ts +1 -1
- package/out/service/service/authority/authority.service.js +1 -1
- package/out/service/service/code-list/code-list.service.d.ts +3 -3
- package/out/service/service/code-list/code-list.service.d.ts.map +1 -1
- package/out/service/service/code-list/code-list.service.js +2 -2
- package/out/service/service/control/control.service.d.ts +2 -2
- package/out/service/service/control/control.service.d.ts.map +1 -1
- package/out/service/service/control/control.service.js +1 -1
- package/out/service/service/control/md-control.service.d.ts +23 -13
- package/out/service/service/control/md-control.service.d.ts.map +1 -1
- package/out/service/service/control/md-control.service.js +23 -7
- package/out/service/service/counter/counter.service.d.ts +3 -3
- package/out/service/service/counter/counter.service.d.ts.map +1 -1
- package/out/service/service/counter/counter.service.js +1 -1
- package/out/service/service/entity/de.service.d.ts +46 -28
- package/out/service/service/entity/de.service.d.ts.map +1 -1
- package/out/service/service/entity/de.service.js +35 -71
- package/out/service/service/entity/method/de-action.d.ts +23 -33
- package/out/service/service/entity/method/de-action.d.ts.map +1 -1
- package/out/service/service/entity/method/de-action.js +18 -35
- package/out/service/service/entity/method/fetch.d.ts +3 -4
- package/out/service/service/entity/method/fetch.d.ts.map +1 -1
- package/out/service/service/entity/method/fetch.js +3 -8
- package/out/service/service/entity/method/method-input.d.ts +10 -5
- package/out/service/service/entity/method/method-input.d.ts.map +1 -1
- package/out/service/service/entity/method/method-input.js +9 -8
- package/out/service/service/entity/method/method-renturn.d.ts +10 -7
- package/out/service/service/entity/method/method-renturn.d.ts.map +1 -1
- package/out/service/service/entity/method/method-renturn.js +9 -9
- package/out/service/service/entity/method/method.d.ts +11 -27
- package/out/service/service/entity/method/method.d.ts.map +1 -1
- package/out/service/service/entity/method/method.js +9 -21
- package/out/service/service/entity/method/provider/de-action-de-method.provider.d.ts +2 -2
- package/out/service/service/entity/method/provider/de-action-de-method.provider.d.ts.map +1 -1
- package/out/service/service/entity/method/provider/de-action-de-method.provider.js +2 -2
- package/out/service/service/entity/method/provider/fetch-de-method.provider.d.ts +2 -2
- package/out/service/service/entity/method/provider/fetch-de-method.provider.d.ts.map +1 -1
- package/out/service/service/entity/method/provider/fetch-de-method.provider.js +3 -3
- package/out/service/service/file/file.service.d.ts +2 -2
- package/out/service/service/file/file.service.d.ts.map +1 -1
- package/out/service/service/file/file.service.js +1 -1
- package/out/service/service/work-flow/work-flow.service.d.ts +28 -28
- package/out/service/service/work-flow/work-flow.service.d.ts.map +1 -1
- package/out/service/service/work-flow/work-flow.service.js +15 -15
- package/out/service/utils/app-counter/app-counter.d.ts +7 -7
- package/out/service/utils/app-counter/app-counter.d.ts.map +1 -1
- package/out/service/utils/app-counter/app-counter.js +3 -3
- package/out/service/utils/app-counter/app-de-counter.d.ts +2 -2
- package/out/service/utils/app-counter/app-de-counter.d.ts.map +1 -1
- package/out/service/utils/app-counter/app-de-counter.js +1 -1
- package/out/service/utils/de-cache/de-cache.d.ts +44 -39
- package/out/service/utils/de-cache/de-cache.d.ts.map +1 -1
- package/out/service/utils/de-cache/de-cache.js +115 -75
- package/out/service/utils/dynamic-code-list/dynamic-code-list.d.ts +2 -2
- 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 -2
- package/out/service/utils/res-path/res-path.d.ts +4 -4
- package/out/service/utils/res-path/res-path.d.ts.map +1 -1
- package/out/service/utils/res-path/res-path.js +2 -2
- package/out/service/utils/search-filter/search-filter.d.ts +2 -2
- package/out/service/utils/search-filter/search-filter.d.ts.map +1 -1
- package/out/service/utils/service-exist-util/service-exist-util.d.ts +2 -2
- package/out/service/utils/service-exist-util/service-exist-util.d.ts.map +1 -1
- package/out/service/utils/service-exist-util/service-exist-util.js +1 -1
- package/out/types.d.ts +9 -0
- package/out/types.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-param/ui-logic-param.js +1 -1
- package/out/utils/index.d.ts +2 -0
- package/out/utils/index.d.ts.map +1 -1
- package/out/utils/index.js +2 -0
- package/out/utils/nav-params/calc-nav-params.d.ts +2 -2
- package/out/utils/nav-params/calc-nav-params.d.ts.map +1 -1
- package/out/utils/nav-params/calc-nav-params.js +1 -1
- package/out/utils/open-redirect-view/open-redirect-view.js +1 -1
- package/out/utils/ui-domain/ui-domain.d.ts +35 -0
- package/out/utils/ui-domain/ui-domain.d.ts.map +1 -0
- package/out/utils/ui-domain/ui-domain.js +42 -0
- package/out/utils/ui-domain-manager/ui-domain-manager.d.ts +47 -0
- package/out/utils/ui-domain-manager/ui-domain-manager.d.ts.map +1 -0
- package/out/utils/ui-domain-manager/ui-domain-manager.js +62 -0
- package/package.json +3 -3
- package/src/app-hub.ts +15 -1
- package/src/controller/common/base.controller.ts +3 -0
- package/src/controller/common/view/view.controller.ts +9 -3
- package/src/controller/common/view/wf-step-trace-view.controller.ts +4 -2
- package/src/controller/control/calendar/calendar.service.ts +4 -4
- package/src/controller/control/form/edit-form/edit-form.service.ts +23 -18
- package/src/controller/control/form/form/form.service.ts +2 -2
- package/src/controller/control/form/search-form/search-form.service.ts +2 -2
- package/src/controller/control/gantt/gantt.controller.ts +2 -1
- package/src/controller/control/grid/grid/grid.controller.ts +1 -0
- package/src/controller/control/grid/grid/grid.service.ts +3 -2
- package/src/controller/control/kanban/kanban.service.ts +2 -2
- package/src/controller/control/map/map.service.ts +1 -1
- package/src/controller/control/report-panel/report-panel.service.ts +2 -2
- package/src/controller/control/tree/tree.service.ts +2 -2
- package/src/controller/control/tree-grid-ex/tree-grid-ex.controller.ts +2 -1
- package/src/controller/control/wizard-panel/wizard-panel.service.ts +4 -4
- package/src/controller/utils/value-default/value-default.ts +1 -1
- package/src/de-logic/de-logic-context.ts +5 -5
- package/src/de-logic/de-logic-link/de-logic-link-group-cond/de-logic-link-group-cond.ts +2 -2
- package/src/de-logic/de-logic-link/de-logic-link-single-cond/de-logic-link-single-cond.ts +2 -2
- package/src/de-logic/de-logic-link/de-logic-link.ts +1 -1
- package/src/de-logic/de-logic-node/de-logic-node.ts +1 -1
- package/src/de-logic/de-logic-param/de-logic-param.ts +1 -1
- package/src/de-logic/de-logic.ts +3 -3
- package/src/de-logic/index.ts +10 -10
- package/src/hub/config/app-config-service.ts +1 -0
- package/src/hub/config/app-view-config-service.ts +39 -6
- package/src/install.ts +3 -0
- package/src/interface/common/i-app-hub-service/i-app-hub-service.ts +9 -0
- package/src/interface/common/i-app-view-config-service/i-app-view-config-service.ts +8 -0
- package/src/interface/common/i-data-ability-params/i-data-ability-params.ts +1 -1
- package/src/interface/controller/controller/i.controller.ts +9 -0
- package/src/interface/provider/i-de-method.provider.ts +10 -0
- package/src/interface/provider/i-grid-column.provider.ts +2 -7
- package/src/interface/service/service/i-app-de.service.ts +51 -44
- package/src/interface/service/service/i-file.service.ts +2 -2
- package/src/interface/service/service/i-wf.service.ts +12 -12
- package/src/register/helper/grid-column-register.ts +2 -17
- package/src/service/de-service-util.ts +59 -27
- package/src/service/dto/method.dto.ts +39 -19
- package/src/service/service/authority/authority.service.ts +1 -1
- package/src/service/service/code-list/code-list.service.ts +3 -3
- package/src/service/service/control/control.service.ts +2 -2
- package/src/service/service/control/md-control.service.ts +40 -13
- package/src/service/service/counter/counter.service.ts +3 -3
- package/src/service/service/entity/de.service.ts +57 -89
- package/src/service/service/entity/method/de-action.ts +29 -47
- package/src/service/service/entity/method/fetch.ts +5 -11
- package/src/service/service/entity/method/method-input.ts +10 -9
- package/src/service/service/entity/method/method-renturn.ts +10 -11
- package/src/service/service/entity/method/method.ts +12 -35
- package/src/service/service/entity/method/provider/de-action-de-method.provider.ts +4 -2
- package/src/service/service/entity/method/provider/fetch-de-method.provider.ts +4 -2
- package/src/service/service/file/file.service.ts +2 -2
- package/src/service/service/work-flow/work-flow.service.ts +30 -30
- package/src/service/utils/app-counter/app-counter.ts +7 -7
- package/src/service/utils/app-counter/app-de-counter.ts +2 -2
- package/src/service/utils/de-cache/de-cache.ts +124 -85
- package/src/service/utils/dynamic-code-list/dynamic-code-list.ts +2 -5
- package/src/service/utils/res-path/res-path.ts +4 -4
- package/src/service/utils/search-filter/search-filter.ts +2 -2
- package/src/service/utils/service-exist-util/service-exist-util.ts +2 -2
- package/src/types.ts +10 -0
- package/src/ui-logic/ui-logic-param/ui-logic-param.ts +1 -1
- package/src/utils/index.ts +2 -0
- package/src/utils/nav-params/calc-nav-params.ts +2 -2
- package/src/utils/open-redirect-view/open-redirect-view.ts +1 -1
- package/src/utils/ui-domain/ui-domain.ts +52 -0
- package/src/utils/ui-domain-manager/ui-domain-manager.ts +64 -0
- package/out/service/service/entity/util/util.d.ts +0 -13
- package/out/service/service/entity/util/util.d.ts.map +0 -1
- package/out/service/service/entity/util/util.js +0 -14
- package/src/service/service/entity/util/util.ts +0 -18
package/dist/index.esm.js
CHANGED
|
@@ -1113,7 +1113,7 @@ async function openDERedirectView(appView, context, params = {}, opts = {}) {
|
|
|
1113
1113
|
context[key] = curData[key] || context[key] || params[key];
|
|
1114
1114
|
const actionId = appView.getDataAppDEActionId;
|
|
1115
1115
|
const app = ibiz.hub.getApp(appView.appId);
|
|
1116
|
-
const service = await app.deService.getService(entityId);
|
|
1116
|
+
const service = await app.deService.getService(context, entityId);
|
|
1117
1117
|
ibiz.loading.showRedirect();
|
|
1118
1118
|
try {
|
|
1119
1119
|
const res = await service.exec(actionId || "get", context, params);
|
|
@@ -2697,6 +2697,96 @@ var ThemeUtil = class {
|
|
|
2697
2697
|
}
|
|
2698
2698
|
};
|
|
2699
2699
|
|
|
2700
|
+
// src/utils/ui-domain/ui-domain.ts
|
|
2701
|
+
import { createUUID } from "qx-util";
|
|
2702
|
+
var UIDomain = class {
|
|
2703
|
+
/**
|
|
2704
|
+
* Creates an instance of UIDomain.
|
|
2705
|
+
*
|
|
2706
|
+
* @author chitanda
|
|
2707
|
+
* @date 2023-12-22 16:12:03
|
|
2708
|
+
* @param {string} appId
|
|
2709
|
+
* @param {string} [id]
|
|
2710
|
+
*/
|
|
2711
|
+
constructor(id) {
|
|
2712
|
+
if (id) {
|
|
2713
|
+
this.id = id;
|
|
2714
|
+
} else {
|
|
2715
|
+
this.id = createUUID();
|
|
2716
|
+
}
|
|
2717
|
+
}
|
|
2718
|
+
/**
|
|
2719
|
+
* 界面域销毁
|
|
2720
|
+
*
|
|
2721
|
+
* @author chitanda
|
|
2722
|
+
* @date 2023-12-22 15:12:49
|
|
2723
|
+
*/
|
|
2724
|
+
destroy() {
|
|
2725
|
+
const apps = ibiz.hub.getAllApps();
|
|
2726
|
+
apps.forEach((app) => {
|
|
2727
|
+
app.deService.reset({
|
|
2728
|
+
srfappid: app.appId,
|
|
2729
|
+
srfsessionid: this.id
|
|
2730
|
+
});
|
|
2731
|
+
});
|
|
2732
|
+
}
|
|
2733
|
+
};
|
|
2734
|
+
|
|
2735
|
+
// src/utils/ui-domain-manager/ui-domain-manager.ts
|
|
2736
|
+
var UIDomainManager = class {
|
|
2737
|
+
constructor() {
|
|
2738
|
+
/**
|
|
2739
|
+
* 界面域实例缓存
|
|
2740
|
+
*
|
|
2741
|
+
* @author chitanda
|
|
2742
|
+
* @date 2023-12-22 15:12:53
|
|
2743
|
+
* @protected
|
|
2744
|
+
* @type {Map<string, UIDomain>}
|
|
2745
|
+
*/
|
|
2746
|
+
this.domainMap = /* @__PURE__ */ new Map();
|
|
2747
|
+
}
|
|
2748
|
+
/**
|
|
2749
|
+
* 创建域
|
|
2750
|
+
*
|
|
2751
|
+
* @author chitanda
|
|
2752
|
+
* @date 2023-12-22 16:12:44
|
|
2753
|
+
* @param {string} [id] 可选,不传则自动生成
|
|
2754
|
+
* @return {*} {UIDomain}
|
|
2755
|
+
*/
|
|
2756
|
+
create(id) {
|
|
2757
|
+
const domain = new UIDomain(id);
|
|
2758
|
+
this.domainMap.set(domain.id, domain);
|
|
2759
|
+
return domain;
|
|
2760
|
+
}
|
|
2761
|
+
/**
|
|
2762
|
+
* 获取域
|
|
2763
|
+
*
|
|
2764
|
+
* @author chitanda
|
|
2765
|
+
* @date 2023-12-22 15:12:17
|
|
2766
|
+
* @param {string} id
|
|
2767
|
+
* @return {*} {UIDomain}
|
|
2768
|
+
*/
|
|
2769
|
+
get(id) {
|
|
2770
|
+
if (this.domainMap.has(id)) {
|
|
2771
|
+
return this.domainMap.get(id);
|
|
2772
|
+
}
|
|
2773
|
+
throw new Error("\u65E0\u6548\u7684\u754C\u9762\u57DF\u6807\u8BC6[".concat(id, "]"));
|
|
2774
|
+
}
|
|
2775
|
+
/**
|
|
2776
|
+
* 销毁域
|
|
2777
|
+
*
|
|
2778
|
+
* @author chitanda
|
|
2779
|
+
* @date 2023-12-22 15:12:03
|
|
2780
|
+
* @param {string} id
|
|
2781
|
+
*/
|
|
2782
|
+
destroy(id) {
|
|
2783
|
+
if (this.domainMap.has(id)) {
|
|
2784
|
+
this.domainMap.get(id).destroy();
|
|
2785
|
+
this.domainMap.delete(id);
|
|
2786
|
+
}
|
|
2787
|
+
}
|
|
2788
|
+
};
|
|
2789
|
+
|
|
2700
2790
|
// src/utils/raw-value-util/raw-value-util.ts
|
|
2701
2791
|
var RawValueUtil = class {
|
|
2702
2792
|
/**
|
|
@@ -3340,7 +3430,6 @@ function getProvider5(key) {
|
|
|
3340
3430
|
async function getGridColumnProvider(model) {
|
|
3341
3431
|
let provider;
|
|
3342
3432
|
const { columnType, enableRowEdit, sysPFPluginId, appId } = model;
|
|
3343
|
-
const { renderSysPFPluginId } = model;
|
|
3344
3433
|
if (sysPFPluginId) {
|
|
3345
3434
|
const pluginKey = await getPluginRegisterKey(sysPFPluginId, appId);
|
|
3346
3435
|
if (pluginKey) {
|
|
@@ -3352,17 +3441,6 @@ async function getGridColumnProvider(model) {
|
|
|
3352
3441
|
return provider;
|
|
3353
3442
|
}
|
|
3354
3443
|
}
|
|
3355
|
-
if (renderSysPFPluginId) {
|
|
3356
|
-
const pluginKey = await getPluginRegisterKey(renderSysPFPluginId, appId);
|
|
3357
|
-
if (pluginKey) {
|
|
3358
|
-
provider = getProvider5(pluginKey);
|
|
3359
|
-
}
|
|
3360
|
-
if (!provider) {
|
|
3361
|
-
ibiz.log.error("\u627E\u4E0D\u5230\u6811\u8868\u683C\u5217\u63D2\u4EF6".concat(pluginKey, "\u5BF9\u5E94\u7684\u9002\u914D\u5668"));
|
|
3362
|
-
} else {
|
|
3363
|
-
return provider;
|
|
3364
|
-
}
|
|
3365
|
-
}
|
|
3366
3444
|
const key = enableRowEdit ? "".concat(columnType, "_EDIT") : columnType;
|
|
3367
3445
|
provider = getProvider5(key);
|
|
3368
3446
|
if (!provider) {
|
|
@@ -3770,7 +3848,7 @@ var AppCounter = class {
|
|
|
3770
3848
|
*
|
|
3771
3849
|
* @author chitanda
|
|
3772
3850
|
* @date 2022-10-26 19:10:24
|
|
3773
|
-
* @param {
|
|
3851
|
+
* @param {IContext} [context]
|
|
3774
3852
|
* @param {IParams} [params]
|
|
3775
3853
|
*/
|
|
3776
3854
|
async init(context, params) {
|
|
@@ -3784,7 +3862,7 @@ var AppCounter = class {
|
|
|
3784
3862
|
* @author chitanda
|
|
3785
3863
|
* @date 2022-10-26 19:10:58
|
|
3786
3864
|
* @protected
|
|
3787
|
-
* @param {
|
|
3865
|
+
* @param {IContext} [context]
|
|
3788
3866
|
* @param {IParams} [params]
|
|
3789
3867
|
*/
|
|
3790
3868
|
setParams(context, params) {
|
|
@@ -3839,7 +3917,7 @@ var AppCounter = class {
|
|
|
3839
3917
|
*
|
|
3840
3918
|
* @author chitanda
|
|
3841
3919
|
* @date 2022-10-26 19:10:46
|
|
3842
|
-
* @param {
|
|
3920
|
+
* @param {IContext} [context]
|
|
3843
3921
|
* @param {IParams} [params]
|
|
3844
3922
|
* @return {*} {Promise<IData>}
|
|
3845
3923
|
*/
|
|
@@ -3904,7 +3982,7 @@ var AppDECounter = class extends AppCounter {
|
|
|
3904
3982
|
*
|
|
3905
3983
|
* @author chitanda
|
|
3906
3984
|
* @date 2022-10-26 19:10:24
|
|
3907
|
-
* @param {
|
|
3985
|
+
* @param {IContext} [context]
|
|
3908
3986
|
* @param {IParams} [params]
|
|
3909
3987
|
*/
|
|
3910
3988
|
async init(context, params) {
|
|
@@ -4142,7 +4220,7 @@ var DynamicCodeListCache = class {
|
|
|
4142
4220
|
* @param {IParams} [params={}]
|
|
4143
4221
|
* @returns {*} {Promise<CodeListItem[]>}
|
|
4144
4222
|
*/
|
|
4145
|
-
async load(context
|
|
4223
|
+
async load(context, params = {}) {
|
|
4146
4224
|
const app = ibiz.hub.getApp(context.srfappid);
|
|
4147
4225
|
const {
|
|
4148
4226
|
appDataEntityId,
|
|
@@ -4236,7 +4314,7 @@ var DynamicCodeListCache = class {
|
|
|
4236
4314
|
* @param {IParams} [params={}]
|
|
4237
4315
|
* @returns {*} {Promise<IData[]>}
|
|
4238
4316
|
*/
|
|
4239
|
-
async get(context
|
|
4317
|
+
async get(context, params = {}) {
|
|
4240
4318
|
if (this.initPromise) {
|
|
4241
4319
|
await this.initPromise;
|
|
4242
4320
|
}
|
|
@@ -4268,7 +4346,7 @@ var DynamicCodeListCache = class {
|
|
|
4268
4346
|
|
|
4269
4347
|
// src/service/utils/de-cache/de-cache.ts
|
|
4270
4348
|
import { where, equals, clone as clone4, isNil as isNil5, isEmpty as isEmpty5 } from "ramda";
|
|
4271
|
-
import { createUUID } from "qx-util";
|
|
4349
|
+
import { ascSort, createUUID as createUUID2 } from "qx-util";
|
|
4272
4350
|
import { RuntimeError as RuntimeError13 } from "@ibiz-template/core";
|
|
4273
4351
|
|
|
4274
4352
|
// src/service/utils/service-exist-util/service-exist-util.ts
|
|
@@ -4293,6 +4371,13 @@ function isExistSessionId(funcName, context) {
|
|
|
4293
4371
|
|
|
4294
4372
|
// src/service/utils/de-cache/de-cache.ts
|
|
4295
4373
|
var DECache = class {
|
|
4374
|
+
/**
|
|
4375
|
+
* Creates an instance of DECache.
|
|
4376
|
+
*
|
|
4377
|
+
* @author chitanda
|
|
4378
|
+
* @date 2023-12-22 13:12:40
|
|
4379
|
+
* @param {IAppDataEntity} entity 应用实体模型
|
|
4380
|
+
*/
|
|
4296
4381
|
constructor(entity) {
|
|
4297
4382
|
this.entity = entity;
|
|
4298
4383
|
/**
|
|
@@ -4300,7 +4385,7 @@ var DECache = class {
|
|
|
4300
4385
|
*
|
|
4301
4386
|
* @author chitanda
|
|
4302
4387
|
* @date 2022-08-17 23:08:08
|
|
4303
|
-
* @type {Map<string,
|
|
4388
|
+
* @type {Map<string, IDataEntity>}
|
|
4304
4389
|
*/
|
|
4305
4390
|
this.cacheMap = /* @__PURE__ */ new Map();
|
|
4306
4391
|
}
|
|
@@ -4321,12 +4406,11 @@ var DECache = class {
|
|
|
4321
4406
|
*
|
|
4322
4407
|
* @author chitanda
|
|
4323
4408
|
* @date 2022-05-10 17:05:45
|
|
4324
|
-
* @param {
|
|
4409
|
+
* @param {IContext} context
|
|
4325
4410
|
* @param {IDataEntity} entity
|
|
4326
4411
|
*/
|
|
4327
|
-
forceAdd(
|
|
4328
|
-
const
|
|
4329
|
-
const data = map.get(entity.srfkey);
|
|
4412
|
+
forceAdd(_context, entity) {
|
|
4413
|
+
const data = this.cacheMap.get(entity.srfkey);
|
|
4330
4414
|
if (data) {
|
|
4331
4415
|
data.assign(entity);
|
|
4332
4416
|
ibiz.log.warn("forceAdd", entity.srfkey, entity);
|
|
@@ -4337,12 +4421,11 @@ var DECache = class {
|
|
|
4337
4421
|
*
|
|
4338
4422
|
* @author chitanda
|
|
4339
4423
|
* @date 2022-05-10 17:05:27
|
|
4340
|
-
* @param {
|
|
4424
|
+
* @param {IContext} context
|
|
4341
4425
|
* @param {IDataEntity} entity
|
|
4342
4426
|
*/
|
|
4343
|
-
forceUpdate(
|
|
4344
|
-
|
|
4345
|
-
map.set(entity.srfkey, clone4(entity));
|
|
4427
|
+
forceUpdate(_context, entity) {
|
|
4428
|
+
this.cacheMap.set(entity.srfkey, clone4(entity));
|
|
4346
4429
|
ibiz.log.warn("forceUpdate", entity.srfkey, entity);
|
|
4347
4430
|
}
|
|
4348
4431
|
/**
|
|
@@ -4350,12 +4433,11 @@ var DECache = class {
|
|
|
4350
4433
|
*
|
|
4351
4434
|
* @author chitanda
|
|
4352
4435
|
* @date 2022-05-10 17:05:08
|
|
4353
|
-
* @param {
|
|
4436
|
+
* @param {IContext} context
|
|
4354
4437
|
* @param {string} srfKey
|
|
4355
4438
|
*/
|
|
4356
|
-
forceDelete(
|
|
4357
|
-
|
|
4358
|
-
map.delete(srfKey);
|
|
4439
|
+
forceDelete(_context, srfKey) {
|
|
4440
|
+
this.cacheMap.delete(srfKey);
|
|
4359
4441
|
ibiz.log.warn("forceDelete", srfKey);
|
|
4360
4442
|
}
|
|
4361
4443
|
/**
|
|
@@ -4378,11 +4460,10 @@ var DECache = class {
|
|
|
4378
4460
|
try {
|
|
4379
4461
|
isExistSessionId("add", context);
|
|
4380
4462
|
if (isNil5(entity.srfkey) || isEmpty5(entity.srfkey)) {
|
|
4381
|
-
entity.srfkey =
|
|
4463
|
+
entity.srfkey = createUUID2();
|
|
4382
4464
|
}
|
|
4383
4465
|
entity.srftempdate = (/* @__PURE__ */ new Date()).getTime();
|
|
4384
|
-
|
|
4385
|
-
map.set(entity.srfkey, clone4(entity));
|
|
4466
|
+
this.cacheMap.set(entity.srfkey, clone4(entity));
|
|
4386
4467
|
ibiz.log.warn("add", entity.srfkey, entity);
|
|
4387
4468
|
return entity;
|
|
4388
4469
|
} catch (err) {
|
|
@@ -4401,8 +4482,7 @@ var DECache = class {
|
|
|
4401
4482
|
get(context, srfKey) {
|
|
4402
4483
|
try {
|
|
4403
4484
|
isExistSessionId("get", context);
|
|
4404
|
-
const
|
|
4405
|
-
const data = map.get(srfKey);
|
|
4485
|
+
const data = this.cacheMap.get(srfKey);
|
|
4406
4486
|
ibiz.log.warn("get", srfKey, data);
|
|
4407
4487
|
return clone4(data);
|
|
4408
4488
|
} catch (err) {
|
|
@@ -4413,7 +4493,7 @@ var DECache = class {
|
|
|
4413
4493
|
/**
|
|
4414
4494
|
* 更新数据
|
|
4415
4495
|
*
|
|
4416
|
-
* @param {
|
|
4496
|
+
* @param {IContext} context
|
|
4417
4497
|
* @param {IDataEntity} entity
|
|
4418
4498
|
* @return {*} {IDataEntity}
|
|
4419
4499
|
* @memberof EntityCache
|
|
@@ -4432,11 +4512,10 @@ var DECache = class {
|
|
|
4432
4512
|
isExistSessionId("update", context);
|
|
4433
4513
|
isExistSrfKey("update", entity);
|
|
4434
4514
|
entity.srftempdate = (/* @__PURE__ */ new Date()).getTime();
|
|
4435
|
-
const
|
|
4436
|
-
const data = map.get(oldKey);
|
|
4515
|
+
const data = this.cacheMap.get(oldKey);
|
|
4437
4516
|
if (data) {
|
|
4438
4517
|
data.assign(entity);
|
|
4439
|
-
|
|
4518
|
+
this.cacheMap.set(oldKey, data);
|
|
4440
4519
|
ibiz.log.warn("update", oldKey, entity);
|
|
4441
4520
|
return clone4(data);
|
|
4442
4521
|
}
|
|
@@ -4449,7 +4528,7 @@ var DECache = class {
|
|
|
4449
4528
|
/**
|
|
4450
4529
|
* 删除数据
|
|
4451
4530
|
*
|
|
4452
|
-
* @param {
|
|
4531
|
+
* @param {IContext} context
|
|
4453
4532
|
* @param {string} srfKey
|
|
4454
4533
|
* @return {*} {(IDataEntity | null)}
|
|
4455
4534
|
* @memberof EntityCache
|
|
@@ -4457,12 +4536,11 @@ var DECache = class {
|
|
|
4457
4536
|
delete(context, srfKey) {
|
|
4458
4537
|
try {
|
|
4459
4538
|
isExistSessionId("delete", context);
|
|
4460
|
-
const map = this.getCacheByTag(context);
|
|
4461
4539
|
const key = srfKey;
|
|
4462
|
-
if (
|
|
4463
|
-
const data =
|
|
4540
|
+
if (this.cacheMap.has(key)) {
|
|
4541
|
+
const data = this.cacheMap.get(key);
|
|
4464
4542
|
data.srftempdate = (/* @__PURE__ */ new Date()).getTime();
|
|
4465
|
-
|
|
4543
|
+
this.cacheMap.delete(key);
|
|
4466
4544
|
ibiz.log.warn("delete", key);
|
|
4467
4545
|
return data;
|
|
4468
4546
|
}
|
|
@@ -4477,22 +4555,21 @@ var DECache = class {
|
|
|
4477
4555
|
*
|
|
4478
4556
|
* @author chitanda
|
|
4479
4557
|
* @date 2022-03-23 11:03:52
|
|
4480
|
-
* @param {
|
|
4558
|
+
* @param {IContext} context
|
|
4481
4559
|
* @param {IDataEntity[]} entities
|
|
4482
4560
|
* @return {*} {IDataEntity[]}
|
|
4483
4561
|
*/
|
|
4484
4562
|
createBatch(context, entities) {
|
|
4485
4563
|
try {
|
|
4486
4564
|
isExistSessionId("add", context);
|
|
4487
|
-
const map = this.getCacheByTag(context);
|
|
4488
4565
|
for (let i = 0; i < entities.length; i++) {
|
|
4489
4566
|
const entity = entities[i];
|
|
4490
4567
|
if (isNil5(entity.srfkey) || isEmpty5(entity.srfkey)) {
|
|
4491
|
-
entity.srfkey =
|
|
4568
|
+
entity.srfkey = createUUID2();
|
|
4492
4569
|
}
|
|
4493
4570
|
entity.srftempdate = (/* @__PURE__ */ new Date()).getTime();
|
|
4494
4571
|
const data = clone4(entity);
|
|
4495
|
-
|
|
4572
|
+
this.cacheMap.set(entity.srfkey, data);
|
|
4496
4573
|
entities[i] = data;
|
|
4497
4574
|
ibiz.log.warn("add", entity.srfkey, entity);
|
|
4498
4575
|
}
|
|
@@ -4507,22 +4584,21 @@ var DECache = class {
|
|
|
4507
4584
|
*
|
|
4508
4585
|
* @author chitanda
|
|
4509
4586
|
* @date 2022-03-23 10:03:17
|
|
4510
|
-
* @param {
|
|
4587
|
+
* @param {IContext} context
|
|
4511
4588
|
* @param {IDataEntity[]} entities
|
|
4512
4589
|
* @return {*} {IDataEntity[]}
|
|
4513
4590
|
*/
|
|
4514
4591
|
updateBatch(context, entities) {
|
|
4515
4592
|
try {
|
|
4516
4593
|
isExistSessionId("update", context);
|
|
4517
|
-
const map = this.getCacheByTag(context);
|
|
4518
4594
|
for (let i = 0; i < entities.length; i++) {
|
|
4519
4595
|
const entity = entities[i];
|
|
4520
4596
|
isExistSrfKey("update", entity);
|
|
4521
4597
|
entity.srftempdate = (/* @__PURE__ */ new Date()).getTime();
|
|
4522
|
-
const data =
|
|
4598
|
+
const data = this.cacheMap.get(entity.srfkey);
|
|
4523
4599
|
if (data) {
|
|
4524
4600
|
data.assign(entity);
|
|
4525
|
-
|
|
4601
|
+
this.cacheMap.set(entity.srfkey, data);
|
|
4526
4602
|
ibiz.log.warn("update", entity.srfkey, entity);
|
|
4527
4603
|
entities[i] = clone4(data);
|
|
4528
4604
|
} else {
|
|
@@ -4542,7 +4618,7 @@ var DECache = class {
|
|
|
4542
4618
|
*
|
|
4543
4619
|
* @author chitanda
|
|
4544
4620
|
* @date 2022-03-23 10:03:40
|
|
4545
|
-
* @param {
|
|
4621
|
+
* @param {IContext} context 上下文
|
|
4546
4622
|
* @param {string[]} srfKeys 需要删除的数据主键
|
|
4547
4623
|
* @return {*} {string[]} 未能删除的数据主键
|
|
4548
4624
|
*/
|
|
@@ -4553,11 +4629,10 @@ var DECache = class {
|
|
|
4553
4629
|
ibiz.log.error(err);
|
|
4554
4630
|
return srfKeys;
|
|
4555
4631
|
}
|
|
4556
|
-
const map = this.getCacheByTag(context);
|
|
4557
4632
|
const notRemoveKeys = [];
|
|
4558
4633
|
for (let i = 0; i < srfKeys.length; i++) {
|
|
4559
4634
|
const key = srfKeys[i];
|
|
4560
|
-
if (!
|
|
4635
|
+
if (!this.cacheMap.has(key)) {
|
|
4561
4636
|
notRemoveKeys.push(key);
|
|
4562
4637
|
}
|
|
4563
4638
|
}
|
|
@@ -4568,7 +4643,7 @@ var DECache = class {
|
|
|
4568
4643
|
}
|
|
4569
4644
|
for (let i = 0; i < srfKeys.length; i++) {
|
|
4570
4645
|
const key = srfKeys[i];
|
|
4571
|
-
|
|
4646
|
+
this.cacheMap.delete(key);
|
|
4572
4647
|
ibiz.log.warn("delete", key);
|
|
4573
4648
|
}
|
|
4574
4649
|
return [];
|
|
@@ -4578,32 +4653,77 @@ var DECache = class {
|
|
|
4578
4653
|
*
|
|
4579
4654
|
* @author chitanda
|
|
4580
4655
|
* @date 2022-08-17 23:08:06
|
|
4581
|
-
* @param {
|
|
4656
|
+
* @param {IContext} context
|
|
4582
4657
|
* @param {string} srfkey
|
|
4583
4658
|
* @return {*} {boolean}
|
|
4584
4659
|
*/
|
|
4585
|
-
checkData(
|
|
4586
|
-
|
|
4587
|
-
|
|
4588
|
-
|
|
4660
|
+
checkData(_context, srfkey) {
|
|
4661
|
+
return !!this.cacheMap.get(srfkey);
|
|
4662
|
+
}
|
|
4663
|
+
/**
|
|
4664
|
+
* 获取当前已经缓存的数据
|
|
4665
|
+
*
|
|
4666
|
+
* @author chitanda
|
|
4667
|
+
* @date 2023-12-22 14:12:57
|
|
4668
|
+
* @return {*} {IDataEntity[]}
|
|
4669
|
+
*/
|
|
4670
|
+
getList() {
|
|
4671
|
+
const values = this.cacheMap.values();
|
|
4672
|
+
return Array.from(values);
|
|
4589
4673
|
}
|
|
4590
4674
|
/**
|
|
4591
4675
|
* 根据条件查找数据,未设置条件默认返回全部
|
|
4592
4676
|
*
|
|
4593
4677
|
* @author chitanda
|
|
4594
|
-
* @date
|
|
4595
|
-
* @param {
|
|
4678
|
+
* @date 2023-12-22 13:12:28
|
|
4679
|
+
* @param {IContext} context
|
|
4680
|
+
* @param {IParams} [params={}]
|
|
4596
4681
|
* @return {*} {IDataEntity[]}
|
|
4597
4682
|
*/
|
|
4598
|
-
|
|
4683
|
+
select(context, params = {}) {
|
|
4599
4684
|
try {
|
|
4600
4685
|
isExistSessionId("getList", context);
|
|
4601
|
-
const
|
|
4602
|
-
|
|
4603
|
-
|
|
4686
|
+
const values = this.cacheMap.values();
|
|
4687
|
+
let items = Array.from(values);
|
|
4688
|
+
items = ascSort(items, "srfordervalue");
|
|
4689
|
+
const data = {};
|
|
4690
|
+
const nullData = {};
|
|
4691
|
+
const undefinedData = {};
|
|
4692
|
+
const emptyData = {};
|
|
4693
|
+
if (params.srfkey) {
|
|
4694
|
+
data.srfkey = equals(params.srfkey);
|
|
4695
|
+
delete params.srfkey;
|
|
4696
|
+
}
|
|
4697
|
+
for (const key in params) {
|
|
4698
|
+
if (Object.prototype.hasOwnProperty.call(params, key)) {
|
|
4699
|
+
const val = params[key];
|
|
4700
|
+
if (val == null) {
|
|
4701
|
+
nullData[key] = equals(null);
|
|
4702
|
+
undefinedData[key] = equals(void 0);
|
|
4703
|
+
emptyData[key] = equals("");
|
|
4704
|
+
} else {
|
|
4705
|
+
data[key] = equals(val);
|
|
4706
|
+
}
|
|
4707
|
+
}
|
|
4708
|
+
}
|
|
4709
|
+
if (!isEmpty5(data)) {
|
|
4710
|
+
const pred = where(data);
|
|
4711
|
+
const nullPred = where(nullData);
|
|
4712
|
+
const undefinedPred = where(undefinedData);
|
|
4713
|
+
const emptyPred = where(emptyData);
|
|
4714
|
+
items = items.filter((obj) => {
|
|
4715
|
+
if (isEmpty5(nullData)) {
|
|
4716
|
+
if (pred(obj)) {
|
|
4717
|
+
return true;
|
|
4718
|
+
}
|
|
4719
|
+
} else if (pred(obj) && (nullPred(obj) || undefinedPred(obj) || emptyPred(obj))) {
|
|
4720
|
+
return true;
|
|
4721
|
+
}
|
|
4722
|
+
return false;
|
|
4723
|
+
});
|
|
4604
4724
|
}
|
|
4605
|
-
const
|
|
4606
|
-
return
|
|
4725
|
+
const list = items.map((obj) => obj.clone());
|
|
4726
|
+
return list;
|
|
4607
4727
|
} catch (err) {
|
|
4608
4728
|
ibiz.log.error(err);
|
|
4609
4729
|
return [];
|
|
@@ -4632,33 +4752,13 @@ var DECache = class {
|
|
|
4632
4752
|
return where(data);
|
|
4633
4753
|
}
|
|
4634
4754
|
/**
|
|
4635
|
-
*
|
|
4636
|
-
*
|
|
4637
|
-
* @author chitanda
|
|
4638
|
-
* @date 2022-08-17 23:08:54
|
|
4639
|
-
* @param {IParams} context
|
|
4640
|
-
*/
|
|
4641
|
-
clear(context) {
|
|
4642
|
-
const tag = context.srfsessionid;
|
|
4643
|
-
if (this.cacheMap.size > 0) {
|
|
4644
|
-
this.cacheMap.delete(tag);
|
|
4645
|
-
}
|
|
4646
|
-
}
|
|
4647
|
-
/**
|
|
4648
|
-
* 根据标识获取map组
|
|
4755
|
+
* 清空缓存
|
|
4649
4756
|
*
|
|
4650
4757
|
* @author chitanda
|
|
4651
|
-
* @date
|
|
4652
|
-
* @private
|
|
4653
|
-
* @param {IParams} context
|
|
4654
|
-
* @return {*} {Map<string, IDataEntity>}
|
|
4758
|
+
* @date 2023-12-22 13:12:17
|
|
4655
4759
|
*/
|
|
4656
|
-
|
|
4657
|
-
|
|
4658
|
-
if (!this.cacheMap.has(tag)) {
|
|
4659
|
-
this.cacheMap.set(tag, /* @__PURE__ */ new Map());
|
|
4660
|
-
}
|
|
4661
|
-
return this.cacheMap.get(tag);
|
|
4760
|
+
clear() {
|
|
4761
|
+
this.cacheMap.clear();
|
|
4662
4762
|
}
|
|
4663
4763
|
/**
|
|
4664
4764
|
* 根据联合键值计算主键并赋值
|
|
@@ -4957,7 +5057,7 @@ var CodeListService = class {
|
|
|
4957
5057
|
* @param {IAppCodeList} codeList
|
|
4958
5058
|
* @returns {*} {IData[]}
|
|
4959
5059
|
*/
|
|
4960
|
-
async getDynamicCodeList(codeList, context
|
|
5060
|
+
async getDynamicCodeList(codeList, context, params = {}) {
|
|
4961
5061
|
let dynamicCache;
|
|
4962
5062
|
const codeName = codeList.codeName;
|
|
4963
5063
|
if (this.cache.has(codeName)) {
|
|
@@ -4975,7 +5075,7 @@ var CodeListService = class {
|
|
|
4975
5075
|
* @author chitanda
|
|
4976
5076
|
* @date 2022-08-25 15:08:45
|
|
4977
5077
|
* @param {string} tag
|
|
4978
|
-
* @param {
|
|
5078
|
+
* @param {IContext} [context]
|
|
4979
5079
|
* @param {IParams} [params]
|
|
4980
5080
|
* @return {*} {Promise<CodeListItem[]>}
|
|
4981
5081
|
*/
|
|
@@ -5078,7 +5178,7 @@ var CounterService = class {
|
|
|
5078
5178
|
* @date 2022-10-26 20:10:20
|
|
5079
5179
|
* @static
|
|
5080
5180
|
* @param {IAppCounterRef} model
|
|
5081
|
-
* @param {
|
|
5181
|
+
* @param {IContext} context
|
|
5082
5182
|
* @param {IParams} params
|
|
5083
5183
|
* @return {*} {Promise<AppCounter>}
|
|
5084
5184
|
*/
|
|
@@ -5106,8 +5206,6 @@ import {
|
|
|
5106
5206
|
ModelError as ModelError5,
|
|
5107
5207
|
RuntimeError as RuntimeError16
|
|
5108
5208
|
} from "@ibiz-template/core";
|
|
5109
|
-
import { equals as equals2, isEmpty as isEmpty7, where as where2 } from "ramda";
|
|
5110
|
-
import { ascSort } from "qx-util";
|
|
5111
5209
|
|
|
5112
5210
|
// src/service/service/work-flow/work-flow.service.ts
|
|
5113
5211
|
import { RuntimeError as RuntimeError15 } from "@ibiz-template/core";
|
|
@@ -5149,7 +5247,7 @@ var WorkFlowService = class {
|
|
|
5149
5247
|
*
|
|
5150
5248
|
* @private
|
|
5151
5249
|
* @param {IData} data
|
|
5152
|
-
* @param {
|
|
5250
|
+
* @param {IContext} context
|
|
5153
5251
|
* @returns {*}
|
|
5154
5252
|
* @memberof WorkFlowService
|
|
5155
5253
|
*/
|
|
@@ -5165,7 +5263,7 @@ var WorkFlowService = class {
|
|
|
5165
5263
|
* @author zk
|
|
5166
5264
|
* @date 2023-11-06 06:11:07
|
|
5167
5265
|
* @private
|
|
5168
|
-
* @param {
|
|
5266
|
+
* @param {IContext} context
|
|
5169
5267
|
* @return {*} {string}
|
|
5170
5268
|
* @memberof WorkFlowService
|
|
5171
5269
|
*/
|
|
@@ -5177,7 +5275,7 @@ var WorkFlowService = class {
|
|
|
5177
5275
|
*
|
|
5178
5276
|
* @author lxm
|
|
5179
5277
|
* @date 2022-09-29 14:09:45
|
|
5180
|
-
* @param {
|
|
5278
|
+
* @param {IContext} context
|
|
5181
5279
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
5182
5280
|
*/
|
|
5183
5281
|
async getWFStep(context) {
|
|
@@ -5191,7 +5289,7 @@ var WorkFlowService = class {
|
|
|
5191
5289
|
*
|
|
5192
5290
|
* @author lxm
|
|
5193
5291
|
* @date 2022-09-29 14:09:52
|
|
5194
|
-
* @param {
|
|
5292
|
+
* @param {IContext} context 路径参数
|
|
5195
5293
|
* @param {IData} data 数据
|
|
5196
5294
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
5197
5295
|
*/
|
|
@@ -5208,7 +5306,7 @@ var WorkFlowService = class {
|
|
|
5208
5306
|
*
|
|
5209
5307
|
* @author lxm
|
|
5210
5308
|
* @date 2022-09-29 14:09:45
|
|
5211
|
-
* @param {
|
|
5309
|
+
* @param {IContext} context
|
|
5212
5310
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
5213
5311
|
*/
|
|
5214
5312
|
async getWFHistory(context) {
|
|
@@ -5224,7 +5322,7 @@ var WorkFlowService = class {
|
|
|
5224
5322
|
*
|
|
5225
5323
|
* @author lxm
|
|
5226
5324
|
* @date 2022-10-27 16:10:13
|
|
5227
|
-
* @param {
|
|
5325
|
+
* @param {IContext} context
|
|
5228
5326
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
5229
5327
|
*/
|
|
5230
5328
|
async getWFProcessDiagram(context) {
|
|
@@ -5255,7 +5353,7 @@ var WorkFlowService = class {
|
|
|
5255
5353
|
*
|
|
5256
5354
|
* @author lxm
|
|
5257
5355
|
* @date 2022-09-30 17:09:51
|
|
5258
|
-
* @param {
|
|
5356
|
+
* @param {IContext} context 路径参数
|
|
5259
5357
|
* @param {IParams} params 请求参数
|
|
5260
5358
|
* @param {IData} data 数据
|
|
5261
5359
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
@@ -5274,7 +5372,7 @@ var WorkFlowService = class {
|
|
|
5274
5372
|
*
|
|
5275
5373
|
* @author lxm
|
|
5276
5374
|
* @date 2022-09-30 17:09:51
|
|
5277
|
-
* @param {
|
|
5375
|
+
* @param {IContext} context 路径参数
|
|
5278
5376
|
* @param {IParams} params 请求参数
|
|
5279
5377
|
* @param {IData} data 数据
|
|
5280
5378
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
@@ -5293,7 +5391,7 @@ var WorkFlowService = class {
|
|
|
5293
5391
|
*
|
|
5294
5392
|
* @author lxm
|
|
5295
5393
|
* @date 2022-09-30 17:09:51
|
|
5296
|
-
* @param {
|
|
5394
|
+
* @param {IContext} context 路径参数
|
|
5297
5395
|
* @param {IParams} params 请求参数
|
|
5298
5396
|
* @param {IData} data 数据
|
|
5299
5397
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
@@ -5312,7 +5410,7 @@ var WorkFlowService = class {
|
|
|
5312
5410
|
*
|
|
5313
5411
|
* @author lxm
|
|
5314
5412
|
* @date 2022-09-30 17:09:51
|
|
5315
|
-
* @param {
|
|
5413
|
+
* @param {IContext} context 路径参数
|
|
5316
5414
|
* @param {IParams} params 请求参数
|
|
5317
5415
|
* @param {IData} data 数据
|
|
5318
5416
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
@@ -5331,7 +5429,7 @@ var WorkFlowService = class {
|
|
|
5331
5429
|
*
|
|
5332
5430
|
* @author lxm
|
|
5333
5431
|
* @date 2022-09-30 17:09:51
|
|
5334
|
-
* @param {
|
|
5432
|
+
* @param {IContext} context 路径参数
|
|
5335
5433
|
* @param {IParams} params 请求参数
|
|
5336
5434
|
* @param {IData} data 数据
|
|
5337
5435
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
@@ -5350,7 +5448,7 @@ var WorkFlowService = class {
|
|
|
5350
5448
|
*
|
|
5351
5449
|
* @author lxm
|
|
5352
5450
|
* @date 2022-09-30 17:09:51
|
|
5353
|
-
* @param {
|
|
5451
|
+
* @param {IContext} context 路径参数
|
|
5354
5452
|
* @param {IParams} params 请求参数
|
|
5355
5453
|
* @param {IData} data 数据
|
|
5356
5454
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
@@ -5369,7 +5467,7 @@ var WorkFlowService = class {
|
|
|
5369
5467
|
*
|
|
5370
5468
|
* @author lxm
|
|
5371
5469
|
* @date 2022-09-30 17:09:51
|
|
5372
|
-
* @param {
|
|
5470
|
+
* @param {IContext} context 路径参数
|
|
5373
5471
|
* @param {IParams} params 请求参数
|
|
5374
5472
|
* @param {IData} data 数据
|
|
5375
5473
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
@@ -5388,7 +5486,7 @@ var WorkFlowService = class {
|
|
|
5388
5486
|
*
|
|
5389
5487
|
* @author lxm
|
|
5390
5488
|
* @date 2022-09-30 17:09:51
|
|
5391
|
-
* @param {
|
|
5489
|
+
* @param {IContext} context 路径参数
|
|
5392
5490
|
* @param {IParams} params 请求参数
|
|
5393
5491
|
* @param {IData} data 数据
|
|
5394
5492
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
@@ -5408,7 +5506,7 @@ var WorkFlowService = class {
|
|
|
5408
5506
|
* @author lxm
|
|
5409
5507
|
* @date 2022-09-30 17:09:38
|
|
5410
5508
|
* @param {string} methodName 接口名称
|
|
5411
|
-
* @param {
|
|
5509
|
+
* @param {IContext} context 路径参数
|
|
5412
5510
|
* @param {IParams} [params={}] 查询参数
|
|
5413
5511
|
* @param {IData} [data={}] 主数据数据
|
|
5414
5512
|
* @returns {*} {Promise<IHttpResponse<IData>>}
|
|
@@ -5454,7 +5552,7 @@ var FileService = class {
|
|
|
5454
5552
|
* @date 2022-11-25 14:11:53
|
|
5455
5553
|
* @param {IDEDataExport} dataExport 导出模型
|
|
5456
5554
|
* @param {string} fetchAction 查询方法
|
|
5457
|
-
* @param {
|
|
5555
|
+
* @param {IContext} context 上下文
|
|
5458
5556
|
* @param {IParams} params 请求参数
|
|
5459
5557
|
* @returns {*} {Promise<IHttpResponse<Blob>>}
|
|
5460
5558
|
*/
|
|
@@ -5472,13 +5570,15 @@ var FileService = class {
|
|
|
5472
5570
|
// src/service/service/entity/de.service.ts
|
|
5473
5571
|
var DEService = class {
|
|
5474
5572
|
/**
|
|
5475
|
-
* Creates an instance of
|
|
5573
|
+
* Creates an instance of DEService.
|
|
5476
5574
|
*
|
|
5477
5575
|
* @author chitanda
|
|
5478
|
-
* @date
|
|
5479
|
-
* @param {
|
|
5576
|
+
* @date 2023-12-22 13:12:21
|
|
5577
|
+
* @param {string} srfSessionId 当前实体会话标识
|
|
5578
|
+
* @param {IAppDataEntity} model 实体模型
|
|
5480
5579
|
*/
|
|
5481
|
-
constructor(model) {
|
|
5580
|
+
constructor(srfSessionId, model) {
|
|
5581
|
+
this.srfSessionId = srfSessionId;
|
|
5482
5582
|
this.model = model;
|
|
5483
5583
|
/**
|
|
5484
5584
|
* 请求方法实例
|
|
@@ -5489,6 +5589,14 @@ var DEService = class {
|
|
|
5489
5589
|
* @type {Map<string, Method>}
|
|
5490
5590
|
*/
|
|
5491
5591
|
this.methodMap = /* @__PURE__ */ new Map();
|
|
5592
|
+
/**
|
|
5593
|
+
* 是否为本地模式(临时数据模式)服务
|
|
5594
|
+
*
|
|
5595
|
+
* @author chitanda
|
|
5596
|
+
* @date 2023-12-22 16:12:13
|
|
5597
|
+
* @type {boolean}
|
|
5598
|
+
*/
|
|
5599
|
+
this.isLocalMode = false;
|
|
5492
5600
|
this.local = new DECache(model);
|
|
5493
5601
|
this.configCache = new ConfigService(
|
|
5494
5602
|
model.appId,
|
|
@@ -5518,7 +5626,10 @@ var DEService = class {
|
|
|
5518
5626
|
if (!provider) {
|
|
5519
5627
|
throw new ModelError5(model, "\u672A\u652F\u6301\u7684\u670D\u52A1\u65B9\u6CD5\u7C7B\u578B: ".concat(model.methodType));
|
|
5520
5628
|
}
|
|
5521
|
-
const method = provider.create(this.model, model, {
|
|
5629
|
+
const method = provider.create(this, this.model, model, {
|
|
5630
|
+
acMode,
|
|
5631
|
+
localMode: this.isLocalMode
|
|
5632
|
+
});
|
|
5522
5633
|
this.methodMap.set(cacheId, method);
|
|
5523
5634
|
return method;
|
|
5524
5635
|
}
|
|
@@ -5528,7 +5639,7 @@ var DEService = class {
|
|
|
5528
5639
|
* @author chitanda
|
|
5529
5640
|
* @date 2022-09-13 19:09:55
|
|
5530
5641
|
* @param {string} id 执行服务方法标识
|
|
5531
|
-
* @param {
|
|
5642
|
+
* @param {IContext} context
|
|
5532
5643
|
* @param {IData} [params={}] 请求参数
|
|
5533
5644
|
* @param {IParams} [params2={}] 查询参数
|
|
5534
5645
|
* @return {*} {Promise<IHttpResponse>}
|
|
@@ -5579,51 +5690,12 @@ var DEService = class {
|
|
|
5579
5690
|
/**
|
|
5580
5691
|
* 查询本地数据,根据属性
|
|
5581
5692
|
*
|
|
5582
|
-
* @param {
|
|
5693
|
+
* @param {IContext} context
|
|
5583
5694
|
* @param {IParams} params 根据多实体属性查找,例:{ name: '张三', age: 18, parent: null }
|
|
5584
5695
|
* @return {*} {Promise<IDataEntity[]>}
|
|
5585
5696
|
*/
|
|
5586
5697
|
async selectLocal(context, params = {}) {
|
|
5587
|
-
|
|
5588
|
-
items = ascSort(items, "srfordervalue");
|
|
5589
|
-
const data = {};
|
|
5590
|
-
const nullData = {};
|
|
5591
|
-
const undefinedData = {};
|
|
5592
|
-
const emptyData = {};
|
|
5593
|
-
if (params.srfkey) {
|
|
5594
|
-
data.srfkey = equals2(params.srfkey);
|
|
5595
|
-
delete params.srfkey;
|
|
5596
|
-
}
|
|
5597
|
-
for (const key in params) {
|
|
5598
|
-
if (Object.prototype.hasOwnProperty.call(params, key)) {
|
|
5599
|
-
const val = params[key];
|
|
5600
|
-
if (val == null) {
|
|
5601
|
-
nullData[key] = equals2(null);
|
|
5602
|
-
undefinedData[key] = equals2(void 0);
|
|
5603
|
-
emptyData[key] = equals2("");
|
|
5604
|
-
} else {
|
|
5605
|
-
data[key] = equals2(val);
|
|
5606
|
-
}
|
|
5607
|
-
}
|
|
5608
|
-
}
|
|
5609
|
-
if (!isEmpty7(data)) {
|
|
5610
|
-
const pred = where2(data);
|
|
5611
|
-
const nullPred = where2(nullData);
|
|
5612
|
-
const undefinedPred = where2(undefinedData);
|
|
5613
|
-
const emptyPred = where2(emptyData);
|
|
5614
|
-
items = items.filter((obj) => {
|
|
5615
|
-
if (isEmpty7(nullData)) {
|
|
5616
|
-
if (pred(obj)) {
|
|
5617
|
-
return true;
|
|
5618
|
-
}
|
|
5619
|
-
} else if (pred(obj) && (nullPred(obj) || undefinedPred(obj) || emptyPred(obj))) {
|
|
5620
|
-
return true;
|
|
5621
|
-
}
|
|
5622
|
-
return false;
|
|
5623
|
-
});
|
|
5624
|
-
}
|
|
5625
|
-
const list = items.map((obj) => obj.clone());
|
|
5626
|
-
return list;
|
|
5698
|
+
return this.local.select(context, params);
|
|
5627
5699
|
}
|
|
5628
5700
|
/**
|
|
5629
5701
|
* 执行服务方法 ac 模式
|
|
@@ -5631,7 +5703,7 @@ var DEService = class {
|
|
|
5631
5703
|
* @author chitanda
|
|
5632
5704
|
* @date 2022-09-13 19:09:55
|
|
5633
5705
|
* @param {string} id 执行服务方法标识
|
|
5634
|
-
* @param {
|
|
5706
|
+
* @param {IContext} context
|
|
5635
5707
|
* @param {IData} [params={}] 请求参数
|
|
5636
5708
|
* @param {IParams} [params2={}] 查询参数
|
|
5637
5709
|
* @return {*} {Promise<IHttpResponse>}
|
|
@@ -5649,7 +5721,7 @@ var DEService = class {
|
|
|
5649
5721
|
* @author chitanda
|
|
5650
5722
|
* @date 2023-10-16 16:10:16
|
|
5651
5723
|
* @param {(data: IPortalAsyncAction) => void} onmessage
|
|
5652
|
-
* @param {
|
|
5724
|
+
* @param {IContext} context
|
|
5653
5725
|
* @param {IParams} [params={}]
|
|
5654
5726
|
* @param {IData} [data={}]
|
|
5655
5727
|
* @return {*} {Promise<void>}
|
|
@@ -5687,7 +5759,7 @@ var DEService = class {
|
|
|
5687
5759
|
*
|
|
5688
5760
|
* @author chitanda
|
|
5689
5761
|
* @date 2023-10-26 14:10:58
|
|
5690
|
-
* @param {
|
|
5762
|
+
* @param {IContext} context
|
|
5691
5763
|
* @param {IParams} [params={}]
|
|
5692
5764
|
* @param {IData} [data={}]
|
|
5693
5765
|
* @return {*} {Promise<IHttpResponse>}
|
|
@@ -5703,7 +5775,7 @@ var DEService = class {
|
|
|
5703
5775
|
* @author chitanda
|
|
5704
5776
|
* @date 2023-10-26 14:10:25
|
|
5705
5777
|
* @protected
|
|
5706
|
-
* @param {
|
|
5778
|
+
* @param {IContext} context
|
|
5707
5779
|
* @param {boolean} [isHistories=false]
|
|
5708
5780
|
* @return {*} {string}
|
|
5709
5781
|
*/
|
|
@@ -5713,13 +5785,23 @@ var DEService = class {
|
|
|
5713
5785
|
const resPath = calcResPath(context, this.model);
|
|
5714
5786
|
return resPath + curPath;
|
|
5715
5787
|
}
|
|
5788
|
+
/**
|
|
5789
|
+
* 服务实例销毁
|
|
5790
|
+
*
|
|
5791
|
+
* @author chitanda
|
|
5792
|
+
* @date 2023-12-22 14:12:11
|
|
5793
|
+
* @return {*} {Promise<void>}
|
|
5794
|
+
*/
|
|
5795
|
+
async destroy() {
|
|
5796
|
+
this.local.clear();
|
|
5797
|
+
}
|
|
5716
5798
|
};
|
|
5717
5799
|
|
|
5718
5800
|
// src/service/service/control/control.service.ts
|
|
5719
5801
|
import { clone as clone6 } from "@ibiz-template/core";
|
|
5720
5802
|
|
|
5721
5803
|
// src/service/vo/control.vo.ts
|
|
5722
|
-
import { createUUID as
|
|
5804
|
+
import { createUUID as createUUID3 } from "qx-util";
|
|
5723
5805
|
import { clone as clone5, isNil as isNil7 } from "ramda";
|
|
5724
5806
|
|
|
5725
5807
|
// src/service/constant/srfuf.ts
|
|
@@ -5818,7 +5900,7 @@ var ControlVO = class _ControlVO {
|
|
|
5818
5900
|
enumerable: false,
|
|
5819
5901
|
configurable: true,
|
|
5820
5902
|
writable: true,
|
|
5821
|
-
value: isNil7(this.srfkey) ?
|
|
5903
|
+
value: isNil7(this.srfkey) ? createUUID3() : this.srfkey
|
|
5822
5904
|
});
|
|
5823
5905
|
}
|
|
5824
5906
|
Object.defineProperty(this, "srfuf", {
|
|
@@ -5971,7 +6053,7 @@ var ControlService = class {
|
|
|
5971
6053
|
* @author lxm
|
|
5972
6054
|
* @date 2022-08-31 17:08:41
|
|
5973
6055
|
* @param {string} methodName 方法名
|
|
5974
|
-
* @param {
|
|
6056
|
+
* @param {IContext} context 上下文
|
|
5975
6057
|
* @param {IParams} [params={}] 视图参数或数据
|
|
5976
6058
|
* @returns {*} {Promise<IHttpResponse>}
|
|
5977
6059
|
*/
|
|
@@ -6018,7 +6100,7 @@ var MDControlService = class extends ControlService {
|
|
|
6018
6100
|
*
|
|
6019
6101
|
* @author lxm
|
|
6020
6102
|
* @date 2022-08-31 17:08:41
|
|
6021
|
-
* @param {
|
|
6103
|
+
* @param {IContext} context 上下文
|
|
6022
6104
|
* @param {IParams} [params={}] 视图参数
|
|
6023
6105
|
* @returns {*} {Promise<IHttpResponse>}
|
|
6024
6106
|
*/
|
|
@@ -6034,7 +6116,7 @@ var MDControlService = class extends ControlService {
|
|
|
6034
6116
|
*
|
|
6035
6117
|
* @author lxm
|
|
6036
6118
|
* @date 2022-08-31 17:08:41
|
|
6037
|
-
* @param {
|
|
6119
|
+
* @param {IContext} context 上下文
|
|
6038
6120
|
* @param {IParams} [params={}] 视图参数
|
|
6039
6121
|
* @returns {*} {Promise<IHttpResponse>}
|
|
6040
6122
|
*/
|
|
@@ -6050,7 +6132,7 @@ var MDControlService = class extends ControlService {
|
|
|
6050
6132
|
*
|
|
6051
6133
|
* @author lxm
|
|
6052
6134
|
* @date 2022-08-31 17:08:41
|
|
6053
|
-
* @param {
|
|
6135
|
+
* @param {IContext} context 上下文
|
|
6054
6136
|
* @param {IParams} [params={}] 视图参数
|
|
6055
6137
|
* @returns {*} {Promise<IHttpResponse>}
|
|
6056
6138
|
*/
|
|
@@ -6066,7 +6148,7 @@ var MDControlService = class extends ControlService {
|
|
|
6066
6148
|
*
|
|
6067
6149
|
* @author lxm
|
|
6068
6150
|
* @date 2022-09-07 19:09:48
|
|
6069
|
-
* @param {
|
|
6151
|
+
* @param {IContext} context 上下文
|
|
6070
6152
|
* @param {IParams} [params={}] 视图参数
|
|
6071
6153
|
* @returns {*}
|
|
6072
6154
|
*/
|
|
@@ -6081,7 +6163,7 @@ var MDControlService = class extends ControlService {
|
|
|
6081
6163
|
*
|
|
6082
6164
|
* @author lxm
|
|
6083
6165
|
* @date 2022-09-07 19:09:11
|
|
6084
|
-
* @param {
|
|
6166
|
+
* @param {IContext} context 上下文
|
|
6085
6167
|
* @param {ControlVO} data 数据
|
|
6086
6168
|
* @returns {*}
|
|
6087
6169
|
*/
|
|
@@ -6097,7 +6179,7 @@ var MDControlService = class extends ControlService {
|
|
|
6097
6179
|
*
|
|
6098
6180
|
* @author lxm
|
|
6099
6181
|
* @date 2022-09-07 19:09:11
|
|
6100
|
-
* @param {
|
|
6182
|
+
* @param {IContext} context 上下文
|
|
6101
6183
|
* @param {ControlVO} data 数据
|
|
6102
6184
|
* @returns {*}
|
|
6103
6185
|
*/
|
|
@@ -6108,13 +6190,33 @@ var MDControlService = class extends ControlService {
|
|
|
6108
6190
|
res = this.handleResponse(res);
|
|
6109
6191
|
return res;
|
|
6110
6192
|
}
|
|
6193
|
+
/**
|
|
6194
|
+
* 批量更新数据
|
|
6195
|
+
*
|
|
6196
|
+
* @author chitanda
|
|
6197
|
+
* @date 2023-12-21 10:12:09
|
|
6198
|
+
* @param {IContext} context
|
|
6199
|
+
* @param {ControlVO[]} data
|
|
6200
|
+
* @return {*} {Promise<void>}
|
|
6201
|
+
*/
|
|
6202
|
+
async updateBatch(context, data) {
|
|
6203
|
+
var _a;
|
|
6204
|
+
const updateAction = ((_a = this.model.updateControlAction) == null ? void 0 : _a.appDEMethodId) || "update";
|
|
6205
|
+
let res = await this.exec(
|
|
6206
|
+
updateAction,
|
|
6207
|
+
context,
|
|
6208
|
+
data.map((item) => item.getOrigin())
|
|
6209
|
+
);
|
|
6210
|
+
res = this.handleResponse(res);
|
|
6211
|
+
return res;
|
|
6212
|
+
}
|
|
6111
6213
|
/**
|
|
6112
6214
|
* 导出数据
|
|
6113
6215
|
*
|
|
6114
6216
|
* @author lxm
|
|
6115
6217
|
* @date 2022-11-25 14:11:09
|
|
6116
6218
|
* @param {IPSDEDataExport} dataExport 导出模型
|
|
6117
|
-
* @param {
|
|
6219
|
+
* @param {IContext} context 上下文
|
|
6118
6220
|
* @param {IParams} [params={}] 请求参数
|
|
6119
6221
|
* @returns {*} {Promise<IHttpResponse>}
|
|
6120
6222
|
*/
|
|
@@ -6280,7 +6382,7 @@ var AuthorityService = class {
|
|
|
6280
6382
|
* @author chitanda
|
|
6281
6383
|
* @date 2022-12-23 10:12:24
|
|
6282
6384
|
* @param {string} id 实体标识
|
|
6283
|
-
* @param {
|
|
6385
|
+
* @param {IContext} [context] 上下文,用于计算模型所属沙箱环境
|
|
6284
6386
|
* @return {*} {Promise<IAppDEService>}
|
|
6285
6387
|
*/
|
|
6286
6388
|
async getService(id) {
|
|
@@ -6478,7 +6580,7 @@ import { isArray as isArray4 } from "lodash-es";
|
|
|
6478
6580
|
// src/service/app-data-entity/app-data-entity.ts
|
|
6479
6581
|
import { clone as clone7, isNil as isNil9 } from "ramda";
|
|
6480
6582
|
import { DataTypes } from "@ibiz-template/core";
|
|
6481
|
-
import { createUUID as
|
|
6583
|
+
import { createUUID as createUUID4 } from "qx-util";
|
|
6482
6584
|
var AppDataEntity = class _AppDataEntity {
|
|
6483
6585
|
get srfuf() {
|
|
6484
6586
|
return this.srfkey === this.tempsrfkey ? 1 /* UPDATE */ : 0 /* CREATE */;
|
|
@@ -6560,7 +6662,7 @@ var AppDataEntity = class _AppDataEntity {
|
|
|
6560
6662
|
enumerable: false,
|
|
6561
6663
|
configurable: true,
|
|
6562
6664
|
writable: true,
|
|
6563
|
-
value: isNil9(this.srfkey) ?
|
|
6665
|
+
value: isNil9(this.srfkey) ? createUUID4() : this.srfkey
|
|
6564
6666
|
});
|
|
6565
6667
|
this.defineProperties();
|
|
6566
6668
|
}
|
|
@@ -6668,9 +6770,10 @@ var AppDataEntity = class _AppDataEntity {
|
|
|
6668
6770
|
// src/service/dto/method.dto.ts
|
|
6669
6771
|
import { ModelError as ModelError6 } from "@ibiz-template/core";
|
|
6670
6772
|
var MethodDto = class _MethodDto {
|
|
6671
|
-
constructor(entity,
|
|
6773
|
+
constructor(service, entity, isLocalMode, dto) {
|
|
6774
|
+
this.service = service;
|
|
6672
6775
|
this.entity = entity;
|
|
6673
|
-
this.isLocalMode =
|
|
6776
|
+
this.isLocalMode = isLocalMode;
|
|
6674
6777
|
this.dto = dto;
|
|
6675
6778
|
this.dtoMap = /* @__PURE__ */ new Map();
|
|
6676
6779
|
if (dto) {
|
|
@@ -6680,6 +6783,18 @@ var MethodDto = class _MethodDto {
|
|
|
6680
6783
|
this.fields = [];
|
|
6681
6784
|
}
|
|
6682
6785
|
}
|
|
6786
|
+
/**
|
|
6787
|
+
* 查找本地 DTO 存储数据
|
|
6788
|
+
*
|
|
6789
|
+
* @author chitanda
|
|
6790
|
+
* @date 2023-12-22 14:12:19
|
|
6791
|
+
* @param {IContext} context
|
|
6792
|
+
* @param {IParams} [params]
|
|
6793
|
+
* @return {*} {IDataEntity[]}
|
|
6794
|
+
*/
|
|
6795
|
+
select(context, params) {
|
|
6796
|
+
return this.service.local.select(context, params);
|
|
6797
|
+
}
|
|
6683
6798
|
/**
|
|
6684
6799
|
* 转换数组成ListMap
|
|
6685
6800
|
*
|
|
@@ -6712,7 +6827,7 @@ var MethodDto = class _MethodDto {
|
|
|
6712
6827
|
*
|
|
6713
6828
|
* @author chitanda
|
|
6714
6829
|
* @date 2022-10-10 23:10:33
|
|
6715
|
-
* @param {
|
|
6830
|
+
* @param {IContext} context
|
|
6716
6831
|
* @param {IData} data
|
|
6717
6832
|
* @return {*} {Promise<IData>}
|
|
6718
6833
|
*/
|
|
@@ -6739,13 +6854,12 @@ var MethodDto = class _MethodDto {
|
|
|
6739
6854
|
if (!field.refAppDataEntityId) {
|
|
6740
6855
|
break;
|
|
6741
6856
|
}
|
|
6742
|
-
const dto = await this.getFieldDto(field);
|
|
6743
|
-
const
|
|
6744
|
-
|
|
6745
|
-
|
|
6746
|
-
|
|
6747
|
-
|
|
6748
|
-
});
|
|
6857
|
+
const dto = await this.getFieldDto(context, field);
|
|
6858
|
+
const filterParams = {};
|
|
6859
|
+
if (field.refPickupAppDEFieldId) {
|
|
6860
|
+
filterParams[field.refPickupAppDEFieldId] = data.srfkey;
|
|
6861
|
+
}
|
|
6862
|
+
const items = await dto.select(context, filterParams);
|
|
6749
6863
|
if (items) {
|
|
6750
6864
|
const arr = [];
|
|
6751
6865
|
for (let j = 0; j < items.length; j++) {
|
|
@@ -6770,14 +6884,13 @@ var MethodDto = class _MethodDto {
|
|
|
6770
6884
|
*
|
|
6771
6885
|
* @author chitanda
|
|
6772
6886
|
* @date 2022-10-10 23:10:50
|
|
6773
|
-
* @param {
|
|
6887
|
+
* @param {IContext} context
|
|
6774
6888
|
* @param {IData[]} data
|
|
6775
6889
|
* @return {*} {Promise<AppDataEntity[]>}
|
|
6776
6890
|
*/
|
|
6777
6891
|
async sets(context, data) {
|
|
6778
|
-
const service = await this.app.deService.getService(this.entity.id);
|
|
6779
6892
|
if (this.isLocalMode) {
|
|
6780
|
-
service.local.clear(
|
|
6893
|
+
this.service.local.clear();
|
|
6781
6894
|
}
|
|
6782
6895
|
return Promise.all(
|
|
6783
6896
|
data.map(async (datum) => {
|
|
@@ -6789,12 +6902,13 @@ var MethodDto = class _MethodDto {
|
|
|
6789
6902
|
if (!field.refAppDataEntityId) {
|
|
6790
6903
|
return;
|
|
6791
6904
|
}
|
|
6792
|
-
const dto = await this.getFieldDto(field);
|
|
6905
|
+
const dto = await this.getFieldDto(context, field);
|
|
6793
6906
|
const items = datum[key];
|
|
6794
6907
|
if (items) {
|
|
6795
6908
|
const pKey = datum[this.entity.keyAppDEFieldId];
|
|
6796
6909
|
items.forEach((item) => {
|
|
6797
6910
|
item.srfpkey = pKey;
|
|
6911
|
+
item[field.refPickupAppDEFieldId] = pKey;
|
|
6798
6912
|
});
|
|
6799
6913
|
await dto.sets(context, items);
|
|
6800
6914
|
} else {
|
|
@@ -6807,7 +6921,7 @@ var MethodDto = class _MethodDto {
|
|
|
6807
6921
|
}
|
|
6808
6922
|
const entityData = new AppDataEntity(this.entity, datum);
|
|
6809
6923
|
if (this.isLocalMode) {
|
|
6810
|
-
await service.local.add(context, entityData);
|
|
6924
|
+
await this.service.local.add(context, entityData);
|
|
6811
6925
|
}
|
|
6812
6926
|
return entityData;
|
|
6813
6927
|
})
|
|
@@ -6817,12 +6931,13 @@ var MethodDto = class _MethodDto {
|
|
|
6817
6931
|
* 获取子属性 DTO
|
|
6818
6932
|
*
|
|
6819
6933
|
* @author chitanda
|
|
6820
|
-
* @date
|
|
6934
|
+
* @date 2023-12-22 13:12:06
|
|
6821
6935
|
* @protected
|
|
6936
|
+
* @param {IContext} context
|
|
6822
6937
|
* @param {IAppDEMethodDTOField} field
|
|
6823
6938
|
* @return {*} {Promise<MethodDto>}
|
|
6824
6939
|
*/
|
|
6825
|
-
async getFieldDto(field) {
|
|
6940
|
+
async getFieldDto(context, field) {
|
|
6826
6941
|
if (this.dtoMap.has(field.codeName)) {
|
|
6827
6942
|
return this.dtoMap.get(field.codeName);
|
|
6828
6943
|
}
|
|
@@ -6834,29 +6949,31 @@ var MethodDto = class _MethodDto {
|
|
|
6834
6949
|
entity.appDEMethodDTOs || [],
|
|
6835
6950
|
field.refAppDEMethodDTOId
|
|
6836
6951
|
);
|
|
6837
|
-
const
|
|
6952
|
+
const service = await this.app.deService.getService(context, entity.id);
|
|
6953
|
+
service.isLocalMode = true;
|
|
6954
|
+
const dto = new _MethodDto(service, entity, true, methodDto);
|
|
6838
6955
|
this.dtoMap.set(field.codeName, dto);
|
|
6839
6956
|
return dto;
|
|
6840
6957
|
}
|
|
6841
6958
|
};
|
|
6842
6959
|
|
|
6843
|
-
// src/service/service/entity/util/util.ts
|
|
6844
|
-
function isLocalMode(method) {
|
|
6845
|
-
return method.actionType === "BUILTIN" || method.dataSetType === "DATAQUERY";
|
|
6846
|
-
}
|
|
6847
|
-
|
|
6848
6960
|
// src/service/service/entity/method/method-input.ts
|
|
6849
6961
|
var MethodInput = class {
|
|
6850
6962
|
/**
|
|
6851
6963
|
* Creates an instance of MethodInput.
|
|
6964
|
+
*
|
|
6852
6965
|
* @author chitanda
|
|
6853
|
-
* @date 2023-
|
|
6966
|
+
* @date 2023-12-22 13:12:57
|
|
6967
|
+
* @param {IAppDEService} service
|
|
6854
6968
|
* @param {IAppDataEntity} entity
|
|
6855
6969
|
* @param {IAppDEMethod} method
|
|
6970
|
+
* @param {boolean} [isLocalMode=false]
|
|
6856
6971
|
*/
|
|
6857
|
-
constructor(entity, method) {
|
|
6972
|
+
constructor(service, entity, method, isLocalMode = false) {
|
|
6973
|
+
this.service = service;
|
|
6858
6974
|
this.entity = entity;
|
|
6859
6975
|
this.method = method;
|
|
6976
|
+
this.isLocalMode = isLocalMode;
|
|
6860
6977
|
const input = method.appDEMethodInput;
|
|
6861
6978
|
if (input) {
|
|
6862
6979
|
const methodDto = findModelChild(
|
|
@@ -6864,19 +6981,16 @@ var MethodInput = class {
|
|
|
6864
6981
|
input.appDEMethodDTOId
|
|
6865
6982
|
);
|
|
6866
6983
|
if (methodDto) {
|
|
6867
|
-
this.dto = new MethodDto(entity, this.isLocalMode, methodDto);
|
|
6984
|
+
this.dto = new MethodDto(service, entity, this.isLocalMode, methodDto);
|
|
6868
6985
|
}
|
|
6869
6986
|
}
|
|
6870
6987
|
}
|
|
6871
|
-
get isLocalMode() {
|
|
6872
|
-
return isLocalMode(this.method);
|
|
6873
|
-
}
|
|
6874
6988
|
/**
|
|
6875
6989
|
* 处理请求发送参数
|
|
6876
6990
|
*
|
|
6877
6991
|
* @author chitanda
|
|
6878
6992
|
* @date 2022-10-11 14:10:22
|
|
6879
|
-
* @param {
|
|
6993
|
+
* @param {IContext} context
|
|
6880
6994
|
* @param {IData} data
|
|
6881
6995
|
* @return {*} {Promise<IData>}
|
|
6882
6996
|
*/
|
|
@@ -6893,15 +7007,19 @@ import { isNilOrEmpty as isNilOrEmpty5 } from "qx-util";
|
|
|
6893
7007
|
var MethodReturn = class {
|
|
6894
7008
|
/**
|
|
6895
7009
|
* Creates an instance of MethodReturn.
|
|
7010
|
+
*
|
|
6896
7011
|
* @author chitanda
|
|
6897
|
-
* @date 2023-
|
|
7012
|
+
* @date 2023-12-22 13:12:24
|
|
7013
|
+
* @param {IAppDEService} service
|
|
6898
7014
|
* @param {IAppDataEntity} entity
|
|
6899
7015
|
* @param {IAppDEMethod} method
|
|
6900
|
-
* @param {
|
|
7016
|
+
* @param {boolean} [isLocalMode=false]
|
|
6901
7017
|
*/
|
|
6902
|
-
constructor(entity, method) {
|
|
7018
|
+
constructor(service, entity, method, isLocalMode = false) {
|
|
7019
|
+
this.service = service;
|
|
6903
7020
|
this.entity = entity;
|
|
6904
7021
|
this.method = method;
|
|
7022
|
+
this.isLocalMode = isLocalMode;
|
|
6905
7023
|
const output = method.appDEMethodReturn;
|
|
6906
7024
|
if (output) {
|
|
6907
7025
|
const methodDto = findModelChild(
|
|
@@ -6909,19 +7027,16 @@ var MethodReturn = class {
|
|
|
6909
7027
|
output.appDEMethodDTOId
|
|
6910
7028
|
);
|
|
6911
7029
|
if (methodDto) {
|
|
6912
|
-
this.dto = new MethodDto(entity, this.isLocalMode, methodDto);
|
|
7030
|
+
this.dto = new MethodDto(service, entity, this.isLocalMode, methodDto);
|
|
6913
7031
|
}
|
|
6914
7032
|
}
|
|
6915
7033
|
}
|
|
6916
|
-
get isLocalMode() {
|
|
6917
|
-
return isLocalMode(this.method);
|
|
6918
|
-
}
|
|
6919
7034
|
/**
|
|
6920
7035
|
* 处理请求返回参数
|
|
6921
7036
|
*
|
|
6922
7037
|
* @author chitanda
|
|
6923
7038
|
* @date 2022-10-19 21:10:06
|
|
6924
|
-
* @param {
|
|
7039
|
+
* @param {IContext} context
|
|
6925
7040
|
* @param {IData} data
|
|
6926
7041
|
* @return {*} {Promise<IDataEntity>}
|
|
6927
7042
|
*/
|
|
@@ -6943,17 +7058,19 @@ var Method = class {
|
|
|
6943
7058
|
* Creates an instance of Method.
|
|
6944
7059
|
*
|
|
6945
7060
|
* @author chitanda
|
|
6946
|
-
* @date
|
|
7061
|
+
* @date 2023-12-22 12:12:06
|
|
7062
|
+
* @param {IAppDEService} service 当前服务实例
|
|
6947
7063
|
* @param {IAppDataEntity} entity
|
|
6948
7064
|
* @param {IAppDEMethod} method
|
|
6949
|
-
* @param {ServicePathItem[][]} paths
|
|
6950
7065
|
*/
|
|
6951
|
-
constructor(entity, method) {
|
|
7066
|
+
constructor(service, entity, method, isLocalMode = false) {
|
|
7067
|
+
this.service = service;
|
|
6952
7068
|
this.entity = entity;
|
|
6953
7069
|
this.method = method;
|
|
7070
|
+
this.isLocalMode = isLocalMode;
|
|
6954
7071
|
this.app = ibiz.hub.getApp(entity.appId);
|
|
6955
|
-
this.input = new MethodInput(entity, method);
|
|
6956
|
-
this.result = new MethodReturn(entity, method);
|
|
7072
|
+
this.input = new MethodInput(service, entity, method);
|
|
7073
|
+
this.result = new MethodReturn(service, entity, method);
|
|
6957
7074
|
}
|
|
6958
7075
|
/**
|
|
6959
7076
|
* 发送请求
|
|
@@ -6962,7 +7079,7 @@ var Method = class {
|
|
|
6962
7079
|
* @date 2022-10-10 17:10:44
|
|
6963
7080
|
* @protected
|
|
6964
7081
|
* @param {string} path
|
|
6965
|
-
* @param {
|
|
7082
|
+
* @param {IContext} context
|
|
6966
7083
|
* @param {IData} data
|
|
6967
7084
|
* @param {IParams} params
|
|
6968
7085
|
* @return {*} {Promise<HttpResponse<any>>}
|
|
@@ -7021,7 +7138,7 @@ var Method = class {
|
|
|
7021
7138
|
* @author chitanda
|
|
7022
7139
|
* @date 2022-08-24 18:08:46
|
|
7023
7140
|
* @protected
|
|
7024
|
-
* @param {
|
|
7141
|
+
* @param {IContext} context
|
|
7025
7142
|
* @return {*} {string} 拼接结果说明: /祖父实体/祖父实体主键/爷爷实体/爷爷实体主键/父实体/父实体主键/当前实体
|
|
7026
7143
|
*/
|
|
7027
7144
|
calcPath(context) {
|
|
@@ -7029,20 +7146,6 @@ var Method = class {
|
|
|
7029
7146
|
const resPath = calcResPath(context, this.entity);
|
|
7030
7147
|
return resPath + curPath;
|
|
7031
7148
|
}
|
|
7032
|
-
/**
|
|
7033
|
-
* 获取当前实体服务
|
|
7034
|
-
*
|
|
7035
|
-
* @author chitanda
|
|
7036
|
-
* @date 2022-10-11 21:10:12
|
|
7037
|
-
* @protected
|
|
7038
|
-
* @return {*} {Promise<IAppDEService>}
|
|
7039
|
-
*/
|
|
7040
|
-
async getService() {
|
|
7041
|
-
if (!this.service) {
|
|
7042
|
-
this.service = await this.app.deService.getService(this.entity.id);
|
|
7043
|
-
}
|
|
7044
|
-
return this.service;
|
|
7045
|
-
}
|
|
7046
7149
|
/**
|
|
7047
7150
|
* 创建实体
|
|
7048
7151
|
* @author lxm
|
|
@@ -7081,7 +7184,7 @@ var DELogicContext = class {
|
|
|
7081
7184
|
* @author lxm
|
|
7082
7185
|
* @date 2023-03-24 09:15:14
|
|
7083
7186
|
* @param {Map<string, DELogicParam>} deLogicParams 实体逻辑参数集合
|
|
7084
|
-
* @param {
|
|
7187
|
+
* @param {IContext} context 上下文
|
|
7085
7188
|
* @param {IData} data 数据对象
|
|
7086
7189
|
* @param {IParams} params 视图参数
|
|
7087
7190
|
*/
|
|
@@ -7251,7 +7354,7 @@ var DELogicLinkSingleCond = class extends DELogicLinkCond {
|
|
|
7251
7354
|
* @author lxm
|
|
7252
7355
|
* @date 2023-02-15 18:02:05
|
|
7253
7356
|
* @param {DELogicContext} ctx
|
|
7254
|
-
* @param {
|
|
7357
|
+
* @param {IContext} context
|
|
7255
7358
|
* @param {IData} data
|
|
7256
7359
|
* @return {*} {boolean}
|
|
7257
7360
|
*/
|
|
@@ -7326,7 +7429,7 @@ var DELogicLinkGroupCond = class _DELogicLinkGroupCond extends DELogicLinkCond {
|
|
|
7326
7429
|
* @author lxm
|
|
7327
7430
|
* @date 2023-02-15 17:02:19
|
|
7328
7431
|
* @param {DELogicContext} ctx
|
|
7329
|
-
* @param {
|
|
7432
|
+
* @param {IContext} context
|
|
7330
7433
|
* @param {IData} data
|
|
7331
7434
|
* @return {*} {boolean}
|
|
7332
7435
|
*/
|
|
@@ -7397,7 +7500,7 @@ var DELogicLink = class {
|
|
|
7397
7500
|
* @author lxm
|
|
7398
7501
|
* @date 2023-02-08 22:02:18
|
|
7399
7502
|
* @param {DELogicContext} ctx
|
|
7400
|
-
* @param {
|
|
7503
|
+
* @param {IContext} context
|
|
7401
7504
|
* @param {IData} data
|
|
7402
7505
|
* @return {*} {Promise<boolean>} 是否连接成功
|
|
7403
7506
|
*/
|
|
@@ -7859,7 +7962,7 @@ var DELogicParam = class {
|
|
|
7859
7962
|
* @author lxm
|
|
7860
7963
|
* @date 2023-02-08 20:02:33
|
|
7861
7964
|
* @param {DELogicContext} ctx
|
|
7862
|
-
* @param {
|
|
7965
|
+
* @param {IContext} context
|
|
7863
7966
|
* @param {IData} data
|
|
7864
7967
|
* @param {IParams} [opt]
|
|
7865
7968
|
*/
|
|
@@ -8030,7 +8133,7 @@ var DELogic = class {
|
|
|
8030
8133
|
* @date 2023-02-08 21:02:58
|
|
8031
8134
|
* @protected
|
|
8032
8135
|
* @param {DELogicContext} ctx
|
|
8033
|
-
* @param {
|
|
8136
|
+
* @param {IContext} context
|
|
8034
8137
|
* @param {IData} data
|
|
8035
8138
|
* @param {IParams} [opt]
|
|
8036
8139
|
*/
|
|
@@ -8047,7 +8150,7 @@ var DELogic = class {
|
|
|
8047
8150
|
*
|
|
8048
8151
|
* @author lxm
|
|
8049
8152
|
* @date 2023-02-08 21:02:09
|
|
8050
|
-
* @param {
|
|
8153
|
+
* @param {IContext} context
|
|
8051
8154
|
* @param {IData} data
|
|
8052
8155
|
* @param {IParams} [opt]
|
|
8053
8156
|
* @return {*} {Promise<IData>}
|
|
@@ -8167,23 +8270,11 @@ async function execFieldLogics(entity, type, context, data, params = {}) {
|
|
|
8167
8270
|
|
|
8168
8271
|
// src/service/service/entity/method/de-action.ts
|
|
8169
8272
|
var DEActionMethod = class extends Method {
|
|
8170
|
-
/**
|
|
8171
|
-
* 是否为本地模式
|
|
8172
|
-
*
|
|
8173
|
-
* @author chitanda
|
|
8174
|
-
* @date 2023-04-19 16:04:46
|
|
8175
|
-
* @readonly
|
|
8176
|
-
* @protected
|
|
8177
|
-
* @type {boolean}
|
|
8178
|
-
*/
|
|
8179
|
-
get isLocalMode() {
|
|
8180
|
-
return isLocalMode(this.method);
|
|
8181
|
-
}
|
|
8182
8273
|
/**
|
|
8183
8274
|
* 处理请求发送参数
|
|
8184
8275
|
* @author lxm
|
|
8185
8276
|
* @date 2023-10-19 02:50:36
|
|
8186
|
-
* @param {
|
|
8277
|
+
* @param {IContext} context 上下文
|
|
8187
8278
|
* @param {(IData | IData[])} data 数据对象
|
|
8188
8279
|
* @return {*} {(Promise<IData | IData[]>)}
|
|
8189
8280
|
*/
|
|
@@ -8272,7 +8363,7 @@ var DEActionMethod = class extends Method {
|
|
|
8272
8363
|
*
|
|
8273
8364
|
* @author chitanda
|
|
8274
8365
|
* @date 2022-08-24 20:08:01
|
|
8275
|
-
* @param {
|
|
8366
|
+
* @param {IContext} context
|
|
8276
8367
|
* @param {IData} data
|
|
8277
8368
|
* @return {*} {Promise<IHttpResponse<IData>>}
|
|
8278
8369
|
*/
|
|
@@ -8293,7 +8384,7 @@ var DEActionMethod = class extends Method {
|
|
|
8293
8384
|
*
|
|
8294
8385
|
* @author chitanda
|
|
8295
8386
|
* @date 2022-08-24 20:08:56
|
|
8296
|
-
* @param {
|
|
8387
|
+
* @param {IContext} context
|
|
8297
8388
|
* @param {IParams} [params]
|
|
8298
8389
|
* @return {*} {Promise<IHttpResponse<IDataEntity>>}
|
|
8299
8390
|
*/
|
|
@@ -8313,7 +8404,7 @@ var DEActionMethod = class extends Method {
|
|
|
8313
8404
|
*
|
|
8314
8405
|
* @author chitanda
|
|
8315
8406
|
* @date 2022-09-13 19:09:39
|
|
8316
|
-
* @param {
|
|
8407
|
+
* @param {IContext} context
|
|
8317
8408
|
* @param {(IData | IDataEntity)} data
|
|
8318
8409
|
* @param {IParams} [params={}]
|
|
8319
8410
|
* @return {*} {Promise<IHttpResponse<IDataEntity>>}
|
|
@@ -8339,7 +8430,7 @@ var DEActionMethod = class extends Method {
|
|
|
8339
8430
|
*
|
|
8340
8431
|
* @author chitanda
|
|
8341
8432
|
* @date 2022-08-24 20:08:07
|
|
8342
|
-
* @param {
|
|
8433
|
+
* @param {IContext} context
|
|
8343
8434
|
* @param {IParams} [params]
|
|
8344
8435
|
* @return {*} {Promise<IHttpResponse<IDataEntity>>}
|
|
8345
8436
|
*/
|
|
@@ -8360,7 +8451,7 @@ var DEActionMethod = class extends Method {
|
|
|
8360
8451
|
*
|
|
8361
8452
|
* @author chitanda
|
|
8362
8453
|
* @date 2022-08-24 20:08:26
|
|
8363
|
-
* @param {
|
|
8454
|
+
* @param {IContext} context
|
|
8364
8455
|
* @param {IParams} [params]
|
|
8365
8456
|
* @return {*} {Promise<IHttpResponse<IData>>}
|
|
8366
8457
|
*/
|
|
@@ -8378,21 +8469,20 @@ var DEActionMethod = class extends Method {
|
|
|
8378
8469
|
*
|
|
8379
8470
|
* @author chitanda
|
|
8380
8471
|
* @date 2022-08-21 17:08:45
|
|
8381
|
-
* @param {
|
|
8472
|
+
* @param {IContext} context
|
|
8382
8473
|
* @param {IData} entity
|
|
8383
8474
|
* @return {*} {Promise<IHttpResponse<IDataEntity>>}
|
|
8384
8475
|
*/
|
|
8385
8476
|
async createTemp(context, entity) {
|
|
8386
8477
|
try {
|
|
8387
|
-
const s = await this.getService();
|
|
8388
8478
|
const addData = this.createEntity(entity);
|
|
8389
8479
|
let resultData;
|
|
8390
8480
|
if (isArray7(addData)) {
|
|
8391
8481
|
resultData = await Promise.all(
|
|
8392
|
-
addData.map((item) =>
|
|
8482
|
+
addData.map((item) => this.service.local.add(context, item))
|
|
8393
8483
|
);
|
|
8394
8484
|
} else {
|
|
8395
|
-
resultData = await
|
|
8485
|
+
resultData = await this.service.local.add(context, addData);
|
|
8396
8486
|
}
|
|
8397
8487
|
return new HttpResponse3(resultData);
|
|
8398
8488
|
} catch (err) {
|
|
@@ -8404,7 +8494,7 @@ var DEActionMethod = class extends Method {
|
|
|
8404
8494
|
*
|
|
8405
8495
|
* @author chitanda
|
|
8406
8496
|
* @date 2022-08-21 17:08:56
|
|
8407
|
-
* @param {
|
|
8497
|
+
* @param {IContext} context
|
|
8408
8498
|
* @param {IParams} [params]
|
|
8409
8499
|
* @return {*} {Promise<IHttpResponse<IDataEntity>>}
|
|
8410
8500
|
*/
|
|
@@ -8424,7 +8514,7 @@ var DEActionMethod = class extends Method {
|
|
|
8424
8514
|
*
|
|
8425
8515
|
* @author chitanda
|
|
8426
8516
|
* @date 2022-08-21 17:08:11
|
|
8427
|
-
* @param {
|
|
8517
|
+
* @param {IContext} context
|
|
8428
8518
|
* @param {IParams} [params]
|
|
8429
8519
|
* @return {*} {Promise<IHttpResponse<IDataEntity>>}
|
|
8430
8520
|
*/
|
|
@@ -8436,8 +8526,7 @@ var DEActionMethod = class extends Method {
|
|
|
8436
8526
|
if (!key && context) {
|
|
8437
8527
|
key = context[this.entity.codeName.toLowerCase()];
|
|
8438
8528
|
}
|
|
8439
|
-
const
|
|
8440
|
-
const data = s.local.delete(context, key);
|
|
8529
|
+
const data = this.service.local.delete(context, key);
|
|
8441
8530
|
if (data) {
|
|
8442
8531
|
return new HttpResponse3(data);
|
|
8443
8532
|
}
|
|
@@ -8451,21 +8540,20 @@ var DEActionMethod = class extends Method {
|
|
|
8451
8540
|
*
|
|
8452
8541
|
* @author chitanda
|
|
8453
8542
|
* @date 2022-08-21 17:08:17
|
|
8454
|
-
* @param {
|
|
8543
|
+
* @param {IContext} context
|
|
8455
8544
|
* @param {IData} entity
|
|
8456
8545
|
* @return {*} {Promise<IHttpResponse<IDataEntity>>}
|
|
8457
8546
|
*/
|
|
8458
8547
|
async updateTemp(context, entity) {
|
|
8459
8548
|
try {
|
|
8460
|
-
const s = await this.getService();
|
|
8461
8549
|
const updateData = this.createEntity(entity);
|
|
8462
8550
|
let resultData;
|
|
8463
8551
|
if (isArray7(updateData)) {
|
|
8464
8552
|
resultData = await Promise.all(
|
|
8465
|
-
updateData.map((item) =>
|
|
8553
|
+
updateData.map((item) => this.service.local.update(context, item))
|
|
8466
8554
|
);
|
|
8467
8555
|
} else {
|
|
8468
|
-
resultData = await
|
|
8556
|
+
resultData = await this.service.local.update(context, updateData);
|
|
8469
8557
|
}
|
|
8470
8558
|
if (resultData) {
|
|
8471
8559
|
return new HttpResponse3(resultData);
|
|
@@ -8480,7 +8568,7 @@ var DEActionMethod = class extends Method {
|
|
|
8480
8568
|
*
|
|
8481
8569
|
* @author chitanda
|
|
8482
8570
|
* @date 2022-08-21 17:08:23
|
|
8483
|
-
* @param {
|
|
8571
|
+
* @param {IContext} context
|
|
8484
8572
|
* @param {IParams} [params]
|
|
8485
8573
|
* @return {*} {Promise<IHttpResponse<IDataEntity>>}
|
|
8486
8574
|
*/
|
|
@@ -8492,8 +8580,7 @@ var DEActionMethod = class extends Method {
|
|
|
8492
8580
|
if (!key && context) {
|
|
8493
8581
|
key = context[this.entity.codeName.toLowerCase()];
|
|
8494
8582
|
}
|
|
8495
|
-
const
|
|
8496
|
-
const data = s.local.get(context, key);
|
|
8583
|
+
const data = this.service.local.get(context, key);
|
|
8497
8584
|
if (data) {
|
|
8498
8585
|
return new HttpResponse3(data);
|
|
8499
8586
|
}
|
|
@@ -8505,7 +8592,7 @@ var DEActionMethod = class extends Method {
|
|
|
8505
8592
|
/**
|
|
8506
8593
|
* 批量删除本地数据
|
|
8507
8594
|
*
|
|
8508
|
-
* @param {
|
|
8595
|
+
* @param {IContext} context
|
|
8509
8596
|
* @param {IParams} [params]
|
|
8510
8597
|
* @return {*} {Promise<IHttpResponse>}
|
|
8511
8598
|
*/
|
|
@@ -8516,8 +8603,8 @@ var DEActionMethod = class extends Method {
|
|
|
8516
8603
|
|
|
8517
8604
|
// src/service/service/entity/method/provider/de-action-de-method.provider.ts
|
|
8518
8605
|
var DeActionDeMethodProvider = class {
|
|
8519
|
-
create(entity, method,
|
|
8520
|
-
return new DEActionMethod(entity, method);
|
|
8606
|
+
create(service, entity, method, opts) {
|
|
8607
|
+
return new DEActionMethod(service, entity, method, opts.localMode);
|
|
8521
8608
|
}
|
|
8522
8609
|
};
|
|
8523
8610
|
|
|
@@ -8528,12 +8615,9 @@ import {
|
|
|
8528
8615
|
RuntimeModelError as RuntimeModelError20
|
|
8529
8616
|
} from "@ibiz-template/core";
|
|
8530
8617
|
import { isArray as isArray8 } from "lodash-es";
|
|
8531
|
-
import { clone as clone13, isEmpty as
|
|
8618
|
+
import { clone as clone13, isEmpty as isEmpty7, isNil as isNil11 } from "ramda";
|
|
8532
8619
|
import { ascSort as ascSort2, descSort } from "qx-util";
|
|
8533
8620
|
var FetchMethod = class extends Method {
|
|
8534
|
-
get isLocalMode() {
|
|
8535
|
-
return isLocalMode(this.method);
|
|
8536
|
-
}
|
|
8537
8621
|
async exec(context, params, params2) {
|
|
8538
8622
|
const searchParams = params && !isArray8(params) ? params : params2 || {};
|
|
8539
8623
|
if (this.isLocalMode) {
|
|
@@ -8586,15 +8670,14 @@ var FetchMethod = class extends Method {
|
|
|
8586
8670
|
* @return {*} {Promise<IDataEntity[]>}
|
|
8587
8671
|
*/
|
|
8588
8672
|
async searchLocal(cond, filter, queryParamKeys = this.entity.quickSearchAppDEFieldIds) {
|
|
8589
|
-
const service = await this.getService();
|
|
8590
8673
|
let list = [];
|
|
8591
8674
|
if (cond) {
|
|
8592
|
-
list = service.local.getList(
|
|
8675
|
+
list = this.service.local.getList();
|
|
8593
8676
|
if (list.length > 0) {
|
|
8594
8677
|
list = list.filter((obj) => cond.test(obj, filter));
|
|
8595
8678
|
}
|
|
8596
8679
|
} else {
|
|
8597
|
-
list = await service.
|
|
8680
|
+
list = await this.service.local.select(filter.context, filter.data);
|
|
8598
8681
|
if (list.length > 0) {
|
|
8599
8682
|
if (filter.query && filter.query !== "") {
|
|
8600
8683
|
if (queryParamKeys) {
|
|
@@ -8613,7 +8696,7 @@ var FetchMethod = class extends Method {
|
|
|
8613
8696
|
}
|
|
8614
8697
|
}
|
|
8615
8698
|
}
|
|
8616
|
-
if (!isNil11(filter.sortField) && !
|
|
8699
|
+
if (!isNil11(filter.sortField) && !isEmpty7(filter.sortField)) {
|
|
8617
8700
|
if (filter.sortMode === "DESC") {
|
|
8618
8701
|
list = descSort(list, filter.sortField);
|
|
8619
8702
|
} else {
|
|
@@ -8630,7 +8713,7 @@ var FetchMethod = class extends Method {
|
|
|
8630
8713
|
* 获取代码表数据来源的集合
|
|
8631
8714
|
* @author lxm
|
|
8632
8715
|
* @date 2023-08-03 02:55:00
|
|
8633
|
-
* @param {
|
|
8716
|
+
* @param {IContext} context
|
|
8634
8717
|
* @param {IParams} params
|
|
8635
8718
|
* @return {*} {Promise<HttpResponse<IData[]>>}
|
|
8636
8719
|
*/
|
|
@@ -8662,11 +8745,11 @@ var AcFetchMethod = class extends FetchMethod {
|
|
|
8662
8745
|
|
|
8663
8746
|
// src/service/service/entity/method/provider/fetch-de-method.provider.ts
|
|
8664
8747
|
var FetchDeMethodProvider = class {
|
|
8665
|
-
create(entity, method, opts) {
|
|
8748
|
+
create(service, entity, method, opts) {
|
|
8666
8749
|
if (opts.acMode) {
|
|
8667
|
-
return new AcFetchMethod(entity, method);
|
|
8750
|
+
return new AcFetchMethod(service, entity, method, opts.localMode);
|
|
8668
8751
|
}
|
|
8669
|
-
return new FetchMethod(entity, method);
|
|
8752
|
+
return new FetchMethod(service, entity, method, opts.localMode);
|
|
8670
8753
|
}
|
|
8671
8754
|
};
|
|
8672
8755
|
|
|
@@ -8680,10 +8763,10 @@ function presetDEMethodProvider() {
|
|
|
8680
8763
|
}
|
|
8681
8764
|
|
|
8682
8765
|
// src/service/vo/tree-node-data/tree-node-data.ts
|
|
8683
|
-
import { createUUID as
|
|
8766
|
+
import { createUUID as createUUID5 } from "qx-util";
|
|
8684
8767
|
var TreeNodeData = class {
|
|
8685
8768
|
constructor(model, parentNodeData, opts) {
|
|
8686
|
-
this._uuid =
|
|
8769
|
+
this._uuid = createUUID5();
|
|
8687
8770
|
this.leaf = false;
|
|
8688
8771
|
this.leaf = opts.leaf === true;
|
|
8689
8772
|
this.parent = parentNodeData;
|
|
@@ -9145,7 +9228,7 @@ var PanelData = class {
|
|
|
9145
9228
|
};
|
|
9146
9229
|
|
|
9147
9230
|
// src/service/vo/chart-data/chart-data.ts
|
|
9148
|
-
import { createUUID as
|
|
9231
|
+
import { createUUID as createUUID6 } from "qx-util";
|
|
9149
9232
|
function updateKeyDefine3(target, keys) {
|
|
9150
9233
|
keys.forEach((key) => {
|
|
9151
9234
|
if (!Object.prototype.hasOwnProperty.call(target, key)) {
|
|
@@ -9163,7 +9246,7 @@ var ChartData = class {
|
|
|
9163
9246
|
this._seriesModelId = seriesModel == null ? void 0 : seriesModel.id;
|
|
9164
9247
|
this._catalog = catalog;
|
|
9165
9248
|
this._groupName = groupName;
|
|
9166
|
-
this._uuid =
|
|
9249
|
+
this._uuid = createUUID6();
|
|
9167
9250
|
return new Proxy(this, {
|
|
9168
9251
|
set(target, p, value) {
|
|
9169
9252
|
if (Object.prototype.hasOwnProperty.call(deData, p)) {
|
|
@@ -9322,7 +9405,7 @@ var GanttCodeListNodeData = class extends TreeCodeListNodeData {
|
|
|
9322
9405
|
};
|
|
9323
9406
|
|
|
9324
9407
|
// src/service/mqtt/mqtt.service.ts
|
|
9325
|
-
import { QXEvent as QXEvent3, createUUID as
|
|
9408
|
+
import { QXEvent as QXEvent3, createUUID as createUUID7, isNilOrEmpty as isNilOrEmpty6 } from "qx-util";
|
|
9326
9409
|
var MqttService = class {
|
|
9327
9410
|
/**
|
|
9328
9411
|
* Creates an instance of MqttService.
|
|
@@ -9356,7 +9439,7 @@ var MqttService = class {
|
|
|
9356
9439
|
// 超时时间
|
|
9357
9440
|
connectTimeout: 6e3,
|
|
9358
9441
|
// 认证信息
|
|
9359
|
-
clientId:
|
|
9442
|
+
clientId: createUUID7(),
|
|
9360
9443
|
username: "",
|
|
9361
9444
|
password: "",
|
|
9362
9445
|
// 心跳时间
|
|
@@ -9432,7 +9515,7 @@ var DEServiceUtil = class {
|
|
|
9432
9515
|
* @author chitanda
|
|
9433
9516
|
* @date 2022-08-17 23:08:36
|
|
9434
9517
|
* @protected
|
|
9435
|
-
* @type {Map<string, IAppDEService
|
|
9518
|
+
* @type {Map<string, Map<string, IAppDEService>>} Map<域标识, Map<实体标识, 实体服务>>
|
|
9436
9519
|
*/
|
|
9437
9520
|
this.cache = /* @__PURE__ */ new Map();
|
|
9438
9521
|
/**
|
|
@@ -9448,8 +9531,8 @@ var DEServiceUtil = class {
|
|
|
9448
9531
|
*
|
|
9449
9532
|
* @author chitanda
|
|
9450
9533
|
* @date 2023-06-14 10:06:31
|
|
9451
|
-
* @param {string} id
|
|
9452
|
-
* @param {
|
|
9534
|
+
* @param {string} id 实体标识
|
|
9535
|
+
* @param {DEServiceConstructor} constructor
|
|
9453
9536
|
*/
|
|
9454
9537
|
register(id, constructor) {
|
|
9455
9538
|
this.constructorCache.set(id, constructor);
|
|
@@ -9458,13 +9541,18 @@ var DEServiceUtil = class {
|
|
|
9458
9541
|
* 根据实体标识获取实体服务
|
|
9459
9542
|
*
|
|
9460
9543
|
* @author chitanda
|
|
9461
|
-
* @date
|
|
9544
|
+
* @date 2023-12-22 10:12:47
|
|
9545
|
+
* @param {IContext} context 上下文,用于计算模型所属沙箱环境
|
|
9462
9546
|
* @param {string} id 实体标识
|
|
9463
|
-
* @param {IParams} [context] 上下文,用于计算模型所属沙箱环境
|
|
9464
9547
|
* @return {*} {Promise<IAppDEService>}
|
|
9465
9548
|
*/
|
|
9466
|
-
async getService(id) {
|
|
9467
|
-
|
|
9549
|
+
async getService(context, id) {
|
|
9550
|
+
const sandboxId = context.srfsessionid;
|
|
9551
|
+
if (!this.cache.has(sandboxId)) {
|
|
9552
|
+
this.cache.set(sandboxId, /* @__PURE__ */ new Map());
|
|
9553
|
+
}
|
|
9554
|
+
const map = this.cache.get(sandboxId);
|
|
9555
|
+
if (!map.has(id)) {
|
|
9468
9556
|
const entityModel = await ibiz.hub.getAppDataEntity(
|
|
9469
9557
|
id,
|
|
9470
9558
|
this.appModel.appId
|
|
@@ -9475,13 +9563,32 @@ var DEServiceUtil = class {
|
|
|
9475
9563
|
const constructor = this.constructorCache.get(id);
|
|
9476
9564
|
let service;
|
|
9477
9565
|
if (constructor) {
|
|
9478
|
-
service = await constructor(entityModel);
|
|
9566
|
+
service = await constructor(sandboxId, entityModel);
|
|
9479
9567
|
} else {
|
|
9480
|
-
service = new DEService(entityModel);
|
|
9568
|
+
service = new DEService(sandboxId, entityModel);
|
|
9481
9569
|
}
|
|
9482
|
-
|
|
9570
|
+
map.set(id, service);
|
|
9483
9571
|
}
|
|
9484
|
-
return
|
|
9572
|
+
return map.get(id);
|
|
9573
|
+
}
|
|
9574
|
+
/**
|
|
9575
|
+
* 重置服务, 删除指定域下的所有服务缓存
|
|
9576
|
+
*
|
|
9577
|
+
* @author chitanda
|
|
9578
|
+
* @date 2023-12-22 13:12:47
|
|
9579
|
+
* @param {IContext} context
|
|
9580
|
+
* @return {*} {void}
|
|
9581
|
+
*/
|
|
9582
|
+
reset(context) {
|
|
9583
|
+
const sandboxId = context.srfsessionid;
|
|
9584
|
+
if (!this.cache.has(sandboxId)) {
|
|
9585
|
+
return;
|
|
9586
|
+
}
|
|
9587
|
+
const map = this.cache.get(sandboxId);
|
|
9588
|
+
map.forEach((service) => {
|
|
9589
|
+
service.destroy();
|
|
9590
|
+
});
|
|
9591
|
+
this.cache.delete(sandboxId);
|
|
9485
9592
|
}
|
|
9486
9593
|
/**
|
|
9487
9594
|
* 清理所有服务, 当前临时域下的所有临时数据缓存
|
|
@@ -9489,11 +9596,16 @@ var DEServiceUtil = class {
|
|
|
9489
9596
|
* @description 根据 srfsessionid 作为临时数据域
|
|
9490
9597
|
* @author chitanda
|
|
9491
9598
|
* @date 2022-08-18 14:08:48
|
|
9492
|
-
* @param {
|
|
9599
|
+
* @param {IContext} context
|
|
9493
9600
|
*/
|
|
9494
9601
|
clearTempCache(context) {
|
|
9495
|
-
|
|
9496
|
-
|
|
9602
|
+
const sandboxId = context.srfsessionid;
|
|
9603
|
+
if (!this.cache.has(sandboxId)) {
|
|
9604
|
+
return;
|
|
9605
|
+
}
|
|
9606
|
+
const map = this.cache.get(sandboxId);
|
|
9607
|
+
map.forEach((service) => {
|
|
9608
|
+
service.local.clear();
|
|
9497
9609
|
});
|
|
9498
9610
|
}
|
|
9499
9611
|
/**
|
|
@@ -9502,13 +9614,13 @@ var DEServiceUtil = class {
|
|
|
9502
9614
|
* @date 2023-04-26 02:02:43
|
|
9503
9615
|
* @param {string} appDataEntityId 实体名称
|
|
9504
9616
|
* @param {string} methodName 方法名
|
|
9505
|
-
* @param {
|
|
9617
|
+
* @param {IContext} context 上下文
|
|
9506
9618
|
* @param {(IData | undefined)} [params] 数据
|
|
9507
9619
|
* @param {(IParams | undefined)} [params2] 视图参数
|
|
9508
9620
|
* @return {*} {Promise<IHttpResponse<IData>>}
|
|
9509
9621
|
*/
|
|
9510
9622
|
async exec(appDataEntityId, methodName, context, params, params2) {
|
|
9511
|
-
const service = await this.getService(appDataEntityId);
|
|
9623
|
+
const service = await this.getService(context, appDataEntityId);
|
|
9512
9624
|
return service.exec(methodName, context, params, params2);
|
|
9513
9625
|
}
|
|
9514
9626
|
};
|
|
@@ -9997,20 +10109,43 @@ var AppViewConfigService = class {
|
|
|
9997
10109
|
*/
|
|
9998
10110
|
this.viewConfigs = /* @__PURE__ */ new Map();
|
|
9999
10111
|
}
|
|
10112
|
+
/**
|
|
10113
|
+
* 计算应用视图 标识
|
|
10114
|
+
*
|
|
10115
|
+
* @author chitanda
|
|
10116
|
+
* @date 2023-04-20 18:04:48
|
|
10117
|
+
* @protected
|
|
10118
|
+
* @param {string} tag
|
|
10119
|
+
* @return {*} {string}
|
|
10120
|
+
*/
|
|
10121
|
+
calcAppViewId(tag) {
|
|
10122
|
+
let id = "";
|
|
10123
|
+
if (tag.indexOf(".") !== -1) {
|
|
10124
|
+
const ids = tag.split(".");
|
|
10125
|
+
id = ids[ids.length - 1];
|
|
10126
|
+
} else {
|
|
10127
|
+
id = tag.toLowerCase();
|
|
10128
|
+
}
|
|
10129
|
+
return id;
|
|
10130
|
+
}
|
|
10000
10131
|
has(key) {
|
|
10001
|
-
|
|
10132
|
+
const id = this.calcAppViewId(key);
|
|
10133
|
+
return this.viewConfigs.has(id);
|
|
10002
10134
|
}
|
|
10003
|
-
set(
|
|
10135
|
+
set(key, viewConfig) {
|
|
10136
|
+
const id = this.calcAppViewId(key);
|
|
10004
10137
|
this.viewConfigs.set(id, viewConfig);
|
|
10005
10138
|
}
|
|
10006
10139
|
async get(key) {
|
|
10007
|
-
|
|
10008
|
-
|
|
10140
|
+
const id = this.calcAppViewId(key);
|
|
10141
|
+
if (!this.viewConfigs.has(id)) {
|
|
10142
|
+
const model = await ibiz.hub.getAppView(id);
|
|
10009
10143
|
if (!model) {
|
|
10010
|
-
throw new RuntimeError24("\u89C6\u56FE[".concat(
|
|
10144
|
+
throw new RuntimeError24("\u89C6\u56FE[".concat(id, "]\u4E0D\u5B58\u5728"));
|
|
10011
10145
|
}
|
|
10012
10146
|
this.set(model.id, {
|
|
10013
10147
|
id: model.id,
|
|
10148
|
+
appId: model.appId,
|
|
10014
10149
|
codeName: model.codeName,
|
|
10015
10150
|
openMode: model.openMode,
|
|
10016
10151
|
viewType: model.viewType,
|
|
@@ -10020,7 +10155,7 @@ var AppViewConfigService = class {
|
|
|
10020
10155
|
redirectView: model.redirectView
|
|
10021
10156
|
});
|
|
10022
10157
|
}
|
|
10023
|
-
return this.viewConfigs.get(
|
|
10158
|
+
return this.viewConfigs.get(id);
|
|
10024
10159
|
}
|
|
10025
10160
|
getSync(key) {
|
|
10026
10161
|
if (this.viewConfigs.has(key)) {
|
|
@@ -10062,9 +10197,9 @@ var PanelNotifyState = /* @__PURE__ */ ((PanelNotifyState2) => {
|
|
|
10062
10197
|
})(PanelNotifyState || {});
|
|
10063
10198
|
|
|
10064
10199
|
// src/controller/common/view/view.controller.ts
|
|
10065
|
-
import {
|
|
10200
|
+
import { notNilEmpty as notNilEmpty6 } from "qx-util";
|
|
10066
10201
|
import { IBizContext as IBizContext2, RuntimeError as RuntimeError31 } from "@ibiz-template/core";
|
|
10067
|
-
import { isEmpty as
|
|
10202
|
+
import { isEmpty as isEmpty8, isNil as isNil18, isNotNil as isNotNil2 } from "ramda";
|
|
10068
10203
|
|
|
10069
10204
|
// src/controller/utils/loading/loading.state.ts
|
|
10070
10205
|
import { NOOP } from "@ibiz-template/core";
|
|
@@ -10339,6 +10474,9 @@ var CTX = class {
|
|
|
10339
10474
|
}
|
|
10340
10475
|
};
|
|
10341
10476
|
|
|
10477
|
+
// src/controller/common/base.controller.ts
|
|
10478
|
+
import { createUUID as createUUID9 } from "qx-util";
|
|
10479
|
+
|
|
10342
10480
|
// src/controller/utils/counter/mounted-counter.ts
|
|
10343
10481
|
var ActivityCounter = class extends Counter {
|
|
10344
10482
|
constructor() {
|
|
@@ -10879,7 +11017,7 @@ var ValueExUtil = class {
|
|
|
10879
11017
|
// src/controller/utils/value-default/value-default.ts
|
|
10880
11018
|
import { RuntimeError as RuntimeError28, ModelError as ModelError16 } from "@ibiz-template/core";
|
|
10881
11019
|
import dayjs from "dayjs";
|
|
10882
|
-
import { createUUID as
|
|
11020
|
+
import { createUUID as createUUID8 } from "qx-util";
|
|
10883
11021
|
import { isNil as isNil16, isNotNil } from "ramda";
|
|
10884
11022
|
function getDefaultValue(opts, origins) {
|
|
10885
11023
|
var _a;
|
|
@@ -10924,7 +11062,7 @@ function getDefaultValue(opts, origins) {
|
|
|
10924
11062
|
case "CONTEXT":
|
|
10925
11063
|
return params[defaultValue];
|
|
10926
11064
|
case "UNIQUEID":
|
|
10927
|
-
return
|
|
11065
|
+
return createUUID8();
|
|
10928
11066
|
default:
|
|
10929
11067
|
throw new ModelError16({}, "\u9ED8\u8BA4\u503C\u7C7B\u578B[".concat(valueType, "]\u672A\u652F\u6301"));
|
|
10930
11068
|
}
|
|
@@ -11023,6 +11161,7 @@ var BaseController = class {
|
|
|
11023
11161
|
this.context = context;
|
|
11024
11162
|
this.params = params;
|
|
11025
11163
|
this.ctx = ctx;
|
|
11164
|
+
this.id = createUUID9();
|
|
11026
11165
|
this.state = {};
|
|
11027
11166
|
/**
|
|
11028
11167
|
* 控制器名称,作为检索控制器的唯一标识
|
|
@@ -11641,11 +11780,14 @@ var ViewController = class extends BaseController {
|
|
|
11641
11780
|
await Promise.all(this.engines.map((engine) => engine.onDestroyed()));
|
|
11642
11781
|
}
|
|
11643
11782
|
this.ctx.destroy();
|
|
11644
|
-
this.context.destroy();
|
|
11645
11783
|
this.engines = [];
|
|
11646
11784
|
if (this.scheduler) {
|
|
11647
11785
|
this.scheduler.destroy();
|
|
11648
11786
|
}
|
|
11787
|
+
if (this.id === this.context.srfsessionid) {
|
|
11788
|
+
ibiz.uiDomainManager.destroy(this.context.srfsessionid);
|
|
11789
|
+
}
|
|
11790
|
+
this.context.destroy();
|
|
11649
11791
|
ibiz.log.debug("\u89C6\u56FE[".concat(this.model.name, "](").concat(this.model.id, ")\u9500\u6BC1"));
|
|
11650
11792
|
}
|
|
11651
11793
|
/**
|
|
@@ -11657,8 +11799,9 @@ var ViewController = class extends BaseController {
|
|
|
11657
11799
|
*/
|
|
11658
11800
|
handleContextParams() {
|
|
11659
11801
|
this.context.srfappid = this.model.appId;
|
|
11660
|
-
if (isNil18(this.context.srfsessionid) ||
|
|
11661
|
-
|
|
11802
|
+
if (isNil18(this.context.srfsessionid) || isEmpty8(this.context.srfsessionid)) {
|
|
11803
|
+
const domain = ibiz.uiDomainManager.create(this.id);
|
|
11804
|
+
this.context.srfsessionid = domain.id;
|
|
11662
11805
|
}
|
|
11663
11806
|
const navContexts = this.model.appViewNavContexts;
|
|
11664
11807
|
let context = {};
|
|
@@ -11814,9 +11957,11 @@ var WFStepTraceViewController = class extends ViewController {
|
|
|
11814
11957
|
var _a;
|
|
11815
11958
|
await super.onCreated();
|
|
11816
11959
|
const app = ibiz.hub.getApp(this.context.srfappid);
|
|
11817
|
-
|
|
11960
|
+
const view = (_a = this.ctx.parent) == null ? void 0 : _a.view;
|
|
11961
|
+
if (view && view.model.appDataEntityId) {
|
|
11818
11962
|
const entityService = await app.deService.getService(
|
|
11819
|
-
|
|
11963
|
+
view.context,
|
|
11964
|
+
view.model.appDataEntityId
|
|
11820
11965
|
);
|
|
11821
11966
|
const params = Object.assign(this.context.clone(), this.params);
|
|
11822
11967
|
const res = await entityService.wf.getWFHistory(params);
|
|
@@ -12904,7 +13049,7 @@ var CalendarService = class extends MDControlService {
|
|
|
12904
13049
|
*
|
|
12905
13050
|
* @author zk
|
|
12906
13051
|
* @date 2023-08-08 10:08:47
|
|
12907
|
-
* @param {
|
|
13052
|
+
* @param {IContext} context
|
|
12908
13053
|
* @param {IParams} [params={}]
|
|
12909
13054
|
* @return {*} Promise<ICalendarItemData[]>
|
|
12910
13055
|
* @memberof CalendarService
|
|
@@ -12963,7 +13108,7 @@ var CalendarService = class extends MDControlService {
|
|
|
12963
13108
|
* @author zk
|
|
12964
13109
|
* @date 2023-08-08 06:08:49
|
|
12965
13110
|
* @param {string} methodName
|
|
12966
|
-
* @param {
|
|
13111
|
+
* @param {IContext} context
|
|
12967
13112
|
* @param {IData} [data={}]
|
|
12968
13113
|
* @param {IParams} [params={}]
|
|
12969
13114
|
* @param {string} [appDataEntityId=this.model.appDataEntityId!]
|
|
@@ -15423,7 +15568,7 @@ var UILogicParam = class {
|
|
|
15423
15568
|
const m = this.model;
|
|
15424
15569
|
const { parameters } = ctx;
|
|
15425
15570
|
const { context, params, data } = parameters;
|
|
15426
|
-
const app = ibiz.hub.getApp(
|
|
15571
|
+
const app = ibiz.hub.getApp(m.appId);
|
|
15427
15572
|
if (m.codeName === "layoutPanel") {
|
|
15428
15573
|
ctx.params[tag] = parameters.view.layoutPanel.panelItems;
|
|
15429
15574
|
return;
|
|
@@ -18500,7 +18645,7 @@ var FormService = class extends ControlService {
|
|
|
18500
18645
|
* @author lxm
|
|
18501
18646
|
* @date 2023-12-13 03:16:19
|
|
18502
18647
|
* @param {IData} data 表单数据
|
|
18503
|
-
* @param {
|
|
18648
|
+
* @param {IContext} context 上下文
|
|
18504
18649
|
* @param {IParams} params 视图参数
|
|
18505
18650
|
* @param {('create' | 'update')} type 新建还是更新
|
|
18506
18651
|
*/
|
|
@@ -18541,7 +18686,7 @@ var SearchFormService = class extends FormService {
|
|
|
18541
18686
|
*
|
|
18542
18687
|
* @author lxm
|
|
18543
18688
|
* @date 2022-08-31 17:08:41
|
|
18544
|
-
* @param {
|
|
18689
|
+
* @param {IContext} context 上下文
|
|
18545
18690
|
* @param {IParams} [params={}] 视图参数
|
|
18546
18691
|
* @returns {*} {Promise<IHttpResponse>}
|
|
18547
18692
|
*/
|
|
@@ -19311,7 +19456,7 @@ var FormButtonController = class extends FormDetailController {
|
|
|
19311
19456
|
|
|
19312
19457
|
// src/controller/control/form/form-detail/form-druipart/form-druipart.controller.ts
|
|
19313
19458
|
import { isOverlap as isOverlap2 } from "@ibiz-template/core";
|
|
19314
|
-
import { createUUID as
|
|
19459
|
+
import { createUUID as createUUID10, notNilEmpty as notNilEmpty8 } from "qx-util";
|
|
19315
19460
|
|
|
19316
19461
|
// src/controller/control/form/form-detail/form-druipart/form-druipart.state.ts
|
|
19317
19462
|
var FormDruipartState = class extends FormDetailState {
|
|
@@ -19424,7 +19569,7 @@ var FormDRUIPartController = class extends FormDetailController {
|
|
|
19424
19569
|
this.form.context
|
|
19425
19570
|
);
|
|
19426
19571
|
if (!this.state.viewComponentKey) {
|
|
19427
|
-
this.state.viewComponentKey =
|
|
19572
|
+
this.state.viewComponentKey = createUUID10();
|
|
19428
19573
|
this.navContext = newContext;
|
|
19429
19574
|
this.navParams = newParams;
|
|
19430
19575
|
} else if (JSON.stringify(this.navContext) !== JSON.stringify(newContext) || JSON.stringify(this.navParams) !== JSON.stringify(newParams)) {
|
|
@@ -20151,7 +20296,7 @@ var FormMDCtrlMDController = class extends FormMDCtrlController {
|
|
|
20151
20296
|
|
|
20152
20297
|
// src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-form.controller.ts
|
|
20153
20298
|
import { RuntimeError as RuntimeError50, RuntimeModelError as RuntimeModelError54 } from "@ibiz-template/core";
|
|
20154
|
-
import { createUUID as
|
|
20299
|
+
import { createUUID as createUUID11 } from "qx-util";
|
|
20155
20300
|
|
|
20156
20301
|
// src/controller/control/form/form-detail/form-mdctrl/form-mdctrl-form.state.ts
|
|
20157
20302
|
var FormMDCtrlFormState = class extends FormDetailState {
|
|
@@ -20287,7 +20432,7 @@ var FormMDCtrlFormController = class extends FormMDCtrlController {
|
|
|
20287
20432
|
this.state.items = [];
|
|
20288
20433
|
}
|
|
20289
20434
|
const item = {
|
|
20290
|
-
id:
|
|
20435
|
+
id: createUUID11(),
|
|
20291
20436
|
context,
|
|
20292
20437
|
params
|
|
20293
20438
|
};
|
|
@@ -20538,7 +20683,7 @@ import {
|
|
|
20538
20683
|
RuntimeError as RuntimeError51
|
|
20539
20684
|
} from "@ibiz-template/core";
|
|
20540
20685
|
import { debounce as debounce2 } from "lodash-es";
|
|
20541
|
-
import { createUUID as
|
|
20686
|
+
import { createUUID as createUUID12 } from "qx-util";
|
|
20542
20687
|
import { clone as clone21 } from "ramda";
|
|
20543
20688
|
|
|
20544
20689
|
// src/controller/control/form/edit-form/edit-form.service.ts
|
|
@@ -20552,7 +20697,7 @@ var EditFormService = class extends FormService {
|
|
|
20552
20697
|
*
|
|
20553
20698
|
* @author lxm
|
|
20554
20699
|
* @date 2022-08-31 17:08:41
|
|
20555
|
-
* @param {
|
|
20700
|
+
* @param {IContext} context 上下文
|
|
20556
20701
|
* @param {IParams} [params={}] 视图参数
|
|
20557
20702
|
* @returns {*} {Promise<IHttpResponse>}
|
|
20558
20703
|
*/
|
|
@@ -20575,7 +20720,7 @@ var EditFormService = class extends FormService {
|
|
|
20575
20720
|
*
|
|
20576
20721
|
* @author lxm
|
|
20577
20722
|
* @date 2022-08-31 17:08:41
|
|
20578
|
-
* @param {
|
|
20723
|
+
* @param {IContext} context 上下文
|
|
20579
20724
|
* @param {IParams} [params={}] 视图参数
|
|
20580
20725
|
* @returns {*} {Promise<IHttpResponse>}
|
|
20581
20726
|
*/
|
|
@@ -20598,7 +20743,7 @@ var EditFormService = class extends FormService {
|
|
|
20598
20743
|
*
|
|
20599
20744
|
* @author lxm
|
|
20600
20745
|
* @date 2022-09-07 19:09:48
|
|
20601
|
-
* @param {
|
|
20746
|
+
* @param {IContext} context 上下文
|
|
20602
20747
|
* @param {IParams} [params={}] 视图参数
|
|
20603
20748
|
* @returns {*}
|
|
20604
20749
|
*/
|
|
@@ -20617,7 +20762,7 @@ var EditFormService = class extends FormService {
|
|
|
20617
20762
|
*
|
|
20618
20763
|
* @author lxm
|
|
20619
20764
|
* @date 2022-09-07 19:09:11
|
|
20620
|
-
* @param {
|
|
20765
|
+
* @param {IContext} context 上下文
|
|
20621
20766
|
* @param {IData} data 数据
|
|
20622
20767
|
* @returns {*}
|
|
20623
20768
|
*/
|
|
@@ -20638,7 +20783,7 @@ var EditFormService = class extends FormService {
|
|
|
20638
20783
|
*
|
|
20639
20784
|
* @author lxm
|
|
20640
20785
|
* @date 2022-09-07 19:09:11
|
|
20641
|
-
* @param {
|
|
20786
|
+
* @param {IContext} context 上下文
|
|
20642
20787
|
* @param {IData} data 数据
|
|
20643
20788
|
* @returns {*}
|
|
20644
20789
|
*/
|
|
@@ -20659,7 +20804,7 @@ var EditFormService = class extends FormService {
|
|
|
20659
20804
|
*
|
|
20660
20805
|
* @author lxm
|
|
20661
20806
|
* @date 2022-09-07 19:09:11
|
|
20662
|
-
* @param {
|
|
20807
|
+
* @param {IContext} context 上下文
|
|
20663
20808
|
* @param {IData} data 数据
|
|
20664
20809
|
* @returns {*}
|
|
20665
20810
|
*/
|
|
@@ -20684,7 +20829,7 @@ var EditFormService = class extends FormService {
|
|
|
20684
20829
|
* @author lxm
|
|
20685
20830
|
* @date 2022-09-15 21:09:34
|
|
20686
20831
|
* @param {string} methodName
|
|
20687
|
-
* @param {
|
|
20832
|
+
* @param {IContext} context
|
|
20688
20833
|
* @param {IParams} [params={}]
|
|
20689
20834
|
* @returns {*} {Promise<IHttpResponse<ControlVO>>}
|
|
20690
20835
|
*/
|
|
@@ -20698,7 +20843,7 @@ var EditFormService = class extends FormService {
|
|
|
20698
20843
|
*
|
|
20699
20844
|
* @author lxm
|
|
20700
20845
|
* @date 2022-09-07 19:09:11
|
|
20701
|
-
* @param {
|
|
20846
|
+
* @param {IContext} context 上下文
|
|
20702
20847
|
* @param {IData} data 数据
|
|
20703
20848
|
* @param {IParams} [params={}] 视图参数
|
|
20704
20849
|
* @returns {*}
|
|
@@ -20708,6 +20853,7 @@ var EditFormService = class extends FormService {
|
|
|
20708
20853
|
const wfForm = this.model;
|
|
20709
20854
|
const methodName = ((_a = wfForm.wfstartControlAction) == null ? void 0 : _a.appDEMethodId) || "wfstart";
|
|
20710
20855
|
const entityService = await this.app.deService.getService(
|
|
20856
|
+
context,
|
|
20711
20857
|
this.model.appDataEntityId
|
|
20712
20858
|
);
|
|
20713
20859
|
return entityService.wf.exec(
|
|
@@ -20722,7 +20868,7 @@ var EditFormService = class extends FormService {
|
|
|
20722
20868
|
*
|
|
20723
20869
|
* @author lxm
|
|
20724
20870
|
* @date 2022-09-07 19:09:11
|
|
20725
|
-
* @param {
|
|
20871
|
+
* @param {IContext} context 上下文
|
|
20726
20872
|
* @param {IData} data 数据
|
|
20727
20873
|
* @param {IParams} [params={}] 视图参数
|
|
20728
20874
|
* @returns {*}
|
|
@@ -20737,6 +20883,7 @@ var EditFormService = class extends FormService {
|
|
|
20737
20883
|
methodName = ((_a = wfForm.wfsubmitControlAction) == null ? void 0 : _a.appDEMethodId) || "wfsubmit";
|
|
20738
20884
|
}
|
|
20739
20885
|
const entityService = await this.app.deService.getService(
|
|
20886
|
+
context,
|
|
20740
20887
|
this.model.appDataEntityId
|
|
20741
20888
|
);
|
|
20742
20889
|
return entityService.wf.exec(
|
|
@@ -20919,7 +21066,7 @@ var EditFormController = class extends FormController {
|
|
|
20919
21066
|
await this.endLoading();
|
|
20920
21067
|
}
|
|
20921
21068
|
res.data.srfkey = void 0;
|
|
20922
|
-
res.data.tempsrfkey =
|
|
21069
|
+
res.data.tempsrfkey = createUUID12();
|
|
20923
21070
|
this.state.modified = false;
|
|
20924
21071
|
this.state.data = res.data;
|
|
20925
21072
|
this.formStateNotify("LOAD" /* LOAD */);
|
|
@@ -21536,12 +21683,13 @@ var GridService = class extends MDControlService {
|
|
|
21536
21683
|
* @author lxm
|
|
21537
21684
|
* @date 2022-09-15 21:09:34
|
|
21538
21685
|
* @param {string} methodName
|
|
21539
|
-
* @param {
|
|
21686
|
+
* @param {IContext} context
|
|
21540
21687
|
* @param {IParams} [params={}]
|
|
21541
21688
|
* @returns {*} {Promise<IHttpResponse<ControlVO>>}
|
|
21542
21689
|
*/
|
|
21543
21690
|
async updateGridEditItem(methodName, context, params = {}) {
|
|
21544
21691
|
const entityService = await this.app.deService.getService(
|
|
21692
|
+
context,
|
|
21545
21693
|
this.model.appDataEntityId
|
|
21546
21694
|
);
|
|
21547
21695
|
let res = await entityService.exec(methodName, context, params);
|
|
@@ -22288,7 +22436,8 @@ var GridController = class extends MDControlController {
|
|
|
22288
22436
|
if (item.codeListId) {
|
|
22289
22437
|
tempExportColumn.codeList = app.codeList.getCodeList(item.codeListId);
|
|
22290
22438
|
tempExportColumn.codeListItems = await app.codeList.get(
|
|
22291
|
-
item.codeListId
|
|
22439
|
+
item.codeListId,
|
|
22440
|
+
this.context
|
|
22292
22441
|
);
|
|
22293
22442
|
}
|
|
22294
22443
|
return tempExportColumn;
|
|
@@ -25480,7 +25629,7 @@ var WizardPanelService = class extends ControlService {
|
|
|
25480
25629
|
*
|
|
25481
25630
|
* @author lxm
|
|
25482
25631
|
* @date 2022-08-31 17:08:41
|
|
25483
|
-
* @param {
|
|
25632
|
+
* @param {IContext} context 上下文
|
|
25484
25633
|
* @param {IParams} [params={}] 视图参数
|
|
25485
25634
|
* @returns {*} {Promise<IHttpResponse>}
|
|
25486
25635
|
*/
|
|
@@ -25496,7 +25645,7 @@ var WizardPanelService = class extends ControlService {
|
|
|
25496
25645
|
*
|
|
25497
25646
|
* @author lxm
|
|
25498
25647
|
* @date 2022-08-31 17:08:41
|
|
25499
|
-
* @param {
|
|
25648
|
+
* @param {IContext} context 上下文
|
|
25500
25649
|
* @param {IParams} [params={}] 视图参数
|
|
25501
25650
|
* @returns {*} {Promise<IHttpResponse>}
|
|
25502
25651
|
*/
|
|
@@ -26156,7 +26305,7 @@ var KanbanService = class extends DataViewControlService {
|
|
|
26156
26305
|
*
|
|
26157
26306
|
* @author lxm
|
|
26158
26307
|
* @date 2022-09-07 19:09:11
|
|
26159
|
-
* @param {
|
|
26308
|
+
* @param {IContext} context 上下文
|
|
26160
26309
|
* @param {ControlVO} data 数据
|
|
26161
26310
|
* @returns {*}
|
|
26162
26311
|
*/
|
|
@@ -27036,7 +27185,7 @@ var TreeGridService = class extends GridService {
|
|
|
27036
27185
|
|
|
27037
27186
|
// src/controller/control/medit-view-panel/medit-view-panel.controller.ts
|
|
27038
27187
|
import { RuntimeError as RuntimeError58 } from "@ibiz-template/core";
|
|
27039
|
-
import { createUUID as
|
|
27188
|
+
import { createUUID as createUUID13 } from "qx-util";
|
|
27040
27189
|
|
|
27041
27190
|
// src/controller/control/medit-view-panel/medit-view-panel.service.ts
|
|
27042
27191
|
var MEditViewPanelService = class extends MDControlService {
|
|
@@ -27123,7 +27272,7 @@ var MEditViewPanelController = class extends MDControlController {
|
|
|
27123
27272
|
*/
|
|
27124
27273
|
handlePanelItemParams(arg) {
|
|
27125
27274
|
const [{ parameterName }] = this.parameters;
|
|
27126
|
-
const id = arg[parameterName] ? arg[parameterName] : "mockId:".concat(
|
|
27275
|
+
const id = arg[parameterName] ? arg[parameterName] : "mockId:".concat(createUUID13());
|
|
27127
27276
|
const item = {
|
|
27128
27277
|
id,
|
|
27129
27278
|
context: this.context.clone(),
|
|
@@ -27275,7 +27424,7 @@ var MapService = class extends MDControlService {
|
|
|
27275
27424
|
* 加载所有地图项的数据
|
|
27276
27425
|
* @author lxm
|
|
27277
27426
|
* @date 2023-10-30 06:27:32
|
|
27278
|
-
* @param {
|
|
27427
|
+
* @param {IContext} context
|
|
27279
27428
|
* @param {IParams} [params={}]
|
|
27280
27429
|
* @return {*} {Promise<IHttpResponse<IMapData[]>>}
|
|
27281
27430
|
*/
|
|
@@ -27456,7 +27605,7 @@ var ReportPanelService = class extends ControlService {
|
|
|
27456
27605
|
/**
|
|
27457
27606
|
* 执行查询报表数据的方法
|
|
27458
27607
|
*
|
|
27459
|
-
* @param {
|
|
27608
|
+
* @param {IContext} context 上下文
|
|
27460
27609
|
* @param {IParams} [params={}] 视图参数
|
|
27461
27610
|
* @returns {*} {Promise<IHttpResponse>}
|
|
27462
27611
|
*/
|
|
@@ -28637,7 +28786,7 @@ var AppHub = class {
|
|
|
28637
28786
|
* @param {IAppView} model
|
|
28638
28787
|
*/
|
|
28639
28788
|
registerAppView(model) {
|
|
28640
|
-
this.views.set(model.codeName, model);
|
|
28789
|
+
this.views.set(model.codeName.toLowerCase(), model);
|
|
28641
28790
|
}
|
|
28642
28791
|
/**
|
|
28643
28792
|
* 注册应用实体
|
|
@@ -28808,6 +28957,19 @@ var AppHub = class {
|
|
|
28808
28957
|
}
|
|
28809
28958
|
return this.appMap.get(key);
|
|
28810
28959
|
}
|
|
28960
|
+
/**
|
|
28961
|
+
* 获取所有应用实例
|
|
28962
|
+
*
|
|
28963
|
+
* @author chitanda
|
|
28964
|
+
* @date 2023-12-22 16:12:28
|
|
28965
|
+
* @return {*} {IAppService[]}
|
|
28966
|
+
*/
|
|
28967
|
+
getAllApps() {
|
|
28968
|
+
if (this.appMap.size > 0) {
|
|
28969
|
+
return Array.from(this.appMap.values());
|
|
28970
|
+
}
|
|
28971
|
+
return [];
|
|
28972
|
+
}
|
|
28811
28973
|
};
|
|
28812
28974
|
|
|
28813
28975
|
// src/engine/engine-factory.ts
|
|
@@ -30612,6 +30774,7 @@ function install2() {
|
|
|
30612
30774
|
ibiz2.auth = new V7AuthService();
|
|
30613
30775
|
ibiz2.asyncAction = new AsyncActionService();
|
|
30614
30776
|
ibiz2.engine = new EngineFactory();
|
|
30777
|
+
ibiz2.uiDomainManager = new UIDomainManager();
|
|
30615
30778
|
installCommand();
|
|
30616
30779
|
presetUIActionProvider();
|
|
30617
30780
|
presetDEMethodProvider();
|
|
@@ -30895,6 +31058,8 @@ export {
|
|
|
30895
31058
|
UIActionButtonState,
|
|
30896
31059
|
UIActionProviderBase,
|
|
30897
31060
|
UIActionUtil,
|
|
31061
|
+
UIDomain,
|
|
31062
|
+
UIDomainManager,
|
|
30898
31063
|
UILOGINNODE_PROVIDER_PREFIX,
|
|
30899
31064
|
UIMapField,
|
|
30900
31065
|
V7AuthService,
|