@ibiz-template/runtime 0.7.41-alpha.124 → 0.7.41-alpha.126
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 +45309 -44911
- package/dist/index.system.min.js +1 -1
- package/out/application.d.ts +7 -0
- package/out/application.d.ts.map +1 -1
- package/out/application.js +21 -0
- package/out/controller/control/app-menu/app-menu.controller.js +1 -1
- package/out/controller/control/form/form-detail/form-item/form-item.controller.d.ts.map +1 -1
- package/out/controller/control/form/form-detail/form-item/form-item.controller.js +1 -1
- package/out/controller/control/grid/grid-column/grid-field-column/grid-field-column.controller.d.ts.map +1 -1
- package/out/controller/control/grid/grid-column/grid-field-column/grid-field-column.controller.js +1 -1
- package/out/controller/control/grid/grid-column/grid-field-edit-column/grid-field-edit-column.controller.d.ts.map +1 -1
- package/out/controller/control/grid/grid-column/grid-field-edit-column/grid-field-edit-column.controller.js +1 -1
- package/out/controller/control/toolbar/toolbar.controller.js +1 -1
- package/out/controller/control/tree/tree.service.d.ts.map +1 -1
- package/out/controller/control/tree/tree.service.js +1 -1
- package/out/controller/utils/view-msg/view-msg-controller.d.ts.map +1 -1
- package/out/controller/utils/view-msg/view-msg-controller.js +1 -1
- package/out/de-logic/de-logic-context.d.ts +4 -13
- package/out/de-logic/de-logic-context.d.ts.map +1 -1
- package/out/de-logic/de-logic-context.js +2 -3
- package/out/de-logic/de-logic-link/de-logic-link-cond/de-logic-link-cond.d.ts +15 -5
- package/out/de-logic/de-logic-link/de-logic-link-cond/de-logic-link-cond.d.ts.map +1 -1
- package/out/de-logic/de-logic-link/de-logic-link-cond/de-logic-link-cond.js +3 -4
- package/out/de-logic/de-logic-link/de-logic-link-group-cond/de-logic-link-group-cond.d.ts +2 -1
- 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-single-cond/de-logic-link-single-cond.d.ts +2 -1
- 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.d.ts +6 -7
- package/out/de-logic/de-logic-link/de-logic-link.d.ts.map +1 -1
- package/out/de-logic/de-logic-link/de-logic-link.js +3 -4
- package/out/de-logic/de-logic-node/de-logic-node.d.ts +2 -1
- package/out/de-logic/de-logic-node/de-logic-node.d.ts.map +1 -1
- package/out/de-logic/de-logic-node/index.d.ts +1 -0
- package/out/de-logic/de-logic-node/index.d.ts.map +1 -1
- package/out/de-logic/de-logic-node/index.js +1 -0
- package/out/de-logic/de-logic.d.ts +31 -37
- package/out/de-logic/de-logic.d.ts.map +1 -1
- package/out/de-logic/de-logic.js +49 -98
- package/out/de-logic/index.d.ts +31 -40
- package/out/de-logic/index.d.ts.map +1 -1
- package/out/de-logic/index.js +57 -76
- package/out/de-logic/provider.d.ts +6 -0
- package/out/de-logic/provider.d.ts.map +1 -0
- package/out/de-logic/provider.js +25 -0
- package/out/install.d.ts.map +1 -1
- package/out/install.js +6 -0
- package/out/interface/api/common/i-api-de-logic-params.d.ts +9 -0
- package/out/interface/api/common/i-api-de-logic-params.d.ts.map +1 -0
- package/out/interface/api/common/i-api-logic-context.d.ts +83 -0
- package/out/interface/api/common/i-api-logic-context.d.ts.map +1 -0
- package/out/interface/api/common/i-api-logic-context.js +1 -0
- package/out/interface/api/common/i-api-logic-params.d.ts +27 -0
- package/out/interface/api/common/i-api-logic-params.d.ts.map +1 -0
- package/out/interface/api/common/i-api-logic-params.js +1 -0
- package/out/interface/api/common/i-api-ui-logic-params.d.ts +3 -21
- package/out/interface/api/common/i-api-ui-logic-params.d.ts.map +1 -1
- package/out/interface/api/common/index.d.ts +2 -0
- package/out/interface/api/common/index.d.ts.map +1 -1
- package/out/interface/api/controller/control/form-detail/i-api-form-detail.controller.d.ts +1 -1
- package/out/interface/common/i-logic-context/i-logic-context.d.ts +27 -0
- package/out/interface/common/i-logic-context/i-logic-context.d.ts.map +1 -0
- package/out/interface/common/i-logic-context/i-logic-context.js +1 -0
- package/out/interface/common/i-logic-link-cond/i-logic-link-cond.d.ts +18 -0
- package/out/interface/common/i-logic-link-cond/i-logic-link-cond.d.ts.map +1 -0
- package/out/interface/common/i-logic-link-cond/i-logic-link-cond.js +1 -0
- package/out/interface/common/index.d.ts +2 -1
- package/out/interface/common/index.d.ts.map +1 -1
- package/out/interface/de-logic/i-de-logic-context.d.ts +10 -0
- package/out/interface/de-logic/i-de-logic-context.d.ts.map +1 -0
- package/out/interface/de-logic/i-de-logic-context.js +1 -0
- package/out/interface/de-logic/i-de-logic-link-cond.d.ts +33 -0
- package/out/interface/de-logic/i-de-logic-link-cond.d.ts.map +1 -0
- package/out/interface/de-logic/i-de-logic-link-cond.js +1 -0
- package/out/interface/de-logic/i-de-logic-link.d.ts +43 -0
- package/out/interface/de-logic/i-de-logic-link.d.ts.map +1 -0
- package/out/interface/de-logic/i-de-logic-link.js +1 -0
- package/out/interface/de-logic/i-de-logic-node.d.ts +10 -0
- package/out/interface/de-logic/i-de-logic-node.d.ts.map +1 -0
- package/out/interface/de-logic/i-de-logic-node.js +1 -0
- package/out/interface/de-logic/i-de-logic-params.d.ts +10 -0
- package/out/interface/de-logic/i-de-logic-params.d.ts.map +1 -0
- package/out/interface/de-logic/i-de-logic-params.js +1 -0
- package/out/interface/de-logic/i-de-logic.d.ts +23 -0
- package/out/interface/de-logic/i-de-logic.d.ts.map +1 -0
- package/out/interface/de-logic/i-de-logic.js +1 -0
- package/out/interface/de-logic/index.d.ts +7 -0
- package/out/interface/de-logic/index.d.ts.map +1 -0
- package/out/interface/de-logic/index.js +1 -0
- package/out/interface/index.d.ts +1 -0
- package/out/interface/index.d.ts.map +1 -1
- package/out/interface/index.js +1 -0
- package/out/interface/provider/i-de-logic-node.provider.d.ts +29 -0
- package/out/interface/provider/i-de-logic-node.provider.d.ts.map +1 -0
- package/out/interface/provider/i-de-logic-node.provider.js +1 -0
- package/out/interface/provider/i-de-logic.provider.d.ts +22 -0
- package/out/interface/provider/i-de-logic.provider.d.ts.map +1 -0
- package/out/interface/provider/i-de-logic.provider.js +1 -0
- package/out/interface/provider/i-ui-action.provider.d.ts +2 -1
- package/out/interface/provider/i-ui-action.provider.d.ts.map +1 -1
- package/out/interface/provider/i-ui-logic-node.provider.d.ts +20 -14
- package/out/interface/provider/i-ui-logic-node.provider.d.ts.map +1 -1
- package/out/interface/provider/i-ui-logic.provider.d.ts +22 -0
- package/out/interface/provider/i-ui-logic.provider.d.ts.map +1 -0
- package/out/interface/provider/i-ui-logic.provider.js +1 -0
- package/out/interface/provider/index.d.ts +3 -0
- package/out/interface/provider/index.d.ts.map +1 -1
- package/out/interface/register/i-register-params.d.ts +29 -34
- package/out/interface/register/i-register-params.d.ts.map +1 -1
- package/out/interface/ui-logic/i-ui-logic-context.d.ts +8 -83
- package/out/interface/ui-logic/i-ui-logic-context.d.ts.map +1 -1
- package/out/interface/ui-logic/i-ui-logic-link-cond.d.ts +33 -0
- package/out/interface/ui-logic/i-ui-logic-link-cond.d.ts.map +1 -0
- package/out/interface/ui-logic/i-ui-logic-link-cond.js +1 -0
- package/out/interface/ui-logic/i-ui-logic-link.d.ts +43 -0
- package/out/interface/ui-logic/i-ui-logic-link.d.ts.map +1 -0
- package/out/interface/ui-logic/i-ui-logic-link.js +1 -0
- package/out/interface/ui-logic/i-ui-logic-node.d.ts +10 -0
- package/out/interface/ui-logic/i-ui-logic-node.d.ts.map +1 -0
- package/out/interface/ui-logic/i-ui-logic-node.js +1 -0
- package/out/interface/{common/i-ui-logic-params → ui-logic}/i-ui-logic-params.d.ts +3 -5
- package/out/interface/ui-logic/i-ui-logic-params.d.ts.map +1 -0
- package/out/interface/ui-logic/i-ui-logic-params.js +1 -0
- package/out/interface/ui-logic/i-ui-logic.d.ts +23 -0
- package/out/interface/ui-logic/i-ui-logic.d.ts.map +1 -0
- package/out/interface/ui-logic/i-ui-logic.js +1 -0
- package/out/interface/ui-logic/index.d.ts +5 -0
- package/out/interface/ui-logic/index.d.ts.map +1 -1
- package/out/locale/en/index.d.ts +21 -0
- package/out/locale/en/index.d.ts.map +1 -1
- package/out/locale/en/index.js +21 -0
- package/out/locale/zh-CN/index.d.ts +21 -0
- package/out/locale/zh-CN/index.d.ts.map +1 -1
- package/out/locale/zh-CN/index.js +21 -0
- package/out/register/custom-register.d.ts +54 -22
- package/out/register/custom-register.d.ts.map +1 -1
- package/out/register/custom-register.js +172 -78
- package/out/register/helper/app-menu-item-register.d.ts +2 -2
- package/out/register/helper/app-menu-item-register.d.ts.map +1 -1
- package/out/register/helper/app-menu-item-register.js +18 -10
- package/out/register/helper/control-register.js +2 -2
- package/out/register/helper/de-logic-node-register.d.ts +24 -0
- package/out/register/helper/de-logic-node-register.d.ts.map +1 -0
- package/out/register/helper/de-logic-node-register.js +50 -0
- package/out/register/helper/de-logic-register.d.ts +20 -0
- package/out/register/helper/de-logic-register.d.ts.map +1 -0
- package/out/register/helper/de-logic-register.js +41 -0
- package/out/register/helper/de-method-register.d.ts +1 -1
- package/out/register/helper/de-method-register.d.ts.map +1 -1
- package/out/register/helper/de-method-register.js +4 -4
- package/out/register/helper/editor-register.d.ts +2 -3
- package/out/register/helper/editor-register.d.ts.map +1 -1
- package/out/register/helper/editor-register.js +4 -6
- package/out/register/helper/form-detail-register.js +3 -3
- package/out/register/helper/grid-column-register.d.ts +3 -3
- package/out/register/helper/grid-column-register.d.ts.map +1 -1
- package/out/register/helper/grid-column-register.js +9 -9
- package/out/register/helper/index.d.ts +3 -0
- package/out/register/helper/index.d.ts.map +1 -1
- package/out/register/helper/index.js +3 -0
- package/out/register/helper/panel-item-register.js +4 -4
- package/out/register/helper/portlet-register.d.ts +3 -5
- package/out/register/helper/portlet-register.d.ts.map +1 -1
- package/out/register/helper/portlet-register.js +20 -19
- package/out/register/helper/toolbar-item-register.d.ts +5 -7
- package/out/register/helper/toolbar-item-register.d.ts.map +1 -1
- package/out/register/helper/toolbar-item-register.js +24 -16
- package/out/register/helper/ui-action-register.js +2 -2
- package/out/register/helper/ui-logic-node-register.d.ts +13 -9
- package/out/register/helper/ui-logic-node-register.d.ts.map +1 -1
- package/out/register/helper/ui-logic-node-register.js +51 -17
- package/out/register/helper/ui-logic-register.d.ts +20 -0
- package/out/register/helper/ui-logic-register.d.ts.map +1 -0
- package/out/register/helper/ui-logic-register.js +41 -0
- package/out/register/helper/view-register.d.ts.map +1 -1
- package/out/register/helper/view-register.js +14 -0
- package/out/service/service/entity/method/de-action.d.ts.map +1 -1
- package/out/service/service/entity/method/de-action.js +1 -1
- package/out/ui-logic/index.d.ts +5 -10
- package/out/ui-logic/index.d.ts.map +1 -1
- package/out/ui-logic/index.js +12 -14
- package/out/ui-logic/provider.d.ts +6 -0
- package/out/ui-logic/provider.d.ts.map +1 -0
- package/out/ui-logic/provider.js +32 -0
- package/out/ui-logic/ui-logic-context.d.ts +1 -1
- package/out/ui-logic/ui-logic-context.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-link/ui-logic-link-cond/ui-logic-link-cond.d.ts +16 -5
- package/out/ui-logic/ui-logic-link/ui-logic-link-cond/ui-logic-link-cond.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-link/ui-logic-link-cond/ui-logic-link-cond.js +3 -4
- package/out/ui-logic/ui-logic-link/ui-logic-link-group-cond/ui-logic-link-group-cond.d.ts +2 -1
- package/out/ui-logic/ui-logic-link/ui-logic-link-group-cond/ui-logic-link-group-cond.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-link/ui-logic-link-single-cond/ui-logic-link-single-cond.d.ts +2 -1
- package/out/ui-logic/ui-logic-link/ui-logic-link-single-cond/ui-logic-link-single-cond.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-link/ui-logic-link.d.ts +6 -8
- package/out/ui-logic/ui-logic-link/ui-logic-link.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-link/ui-logic-link.js +3 -5
- package/out/ui-logic/ui-logic-node/pf-plugin-node/pf-plugin-node.js +3 -3
- package/out/ui-logic/ui-logic-node/ui-logic-node.d.ts +9 -14
- package/out/ui-logic/ui-logic-node/ui-logic-node.d.ts.map +1 -1
- package/out/ui-logic/ui-logic-node/ui-logic-node.js +2 -4
- package/out/ui-logic/ui-logic.d.ts +27 -36
- package/out/ui-logic/ui-logic.d.ts.map +1 -1
- package/out/ui-logic/ui-logic.js +35 -108
- package/out/utils/dr-ctrl-util/index.d.ts.map +1 -1
- package/out/utils/dr-ctrl-util/index.js +1 -1
- package/package.json +2 -2
- package/src/application.ts +23 -0
- package/src/controller/control/app-menu/app-menu.controller.ts +1 -1
- package/src/controller/control/form/form-detail/form-item/form-item.controller.ts +0 -1
- package/src/controller/control/grid/grid-column/grid-field-column/grid-field-column.controller.ts +0 -1
- package/src/controller/control/grid/grid-column/grid-field-edit-column/grid-field-edit-column.controller.ts +0 -1
- package/src/controller/control/toolbar/toolbar.controller.ts +1 -1
- package/src/controller/control/tree/tree.service.ts +1 -0
- package/src/controller/utils/view-msg/view-msg-controller.ts +7 -1
- package/src/de-logic/de-logic-context.ts +4 -16
- package/src/de-logic/de-logic-link/de-logic-link-cond/de-logic-link-cond.ts +17 -5
- package/src/de-logic/de-logic-link/de-logic-link-group-cond/de-logic-link-group-cond.ts +5 -1
- package/src/de-logic/de-logic-link/de-logic-link-single-cond/de-logic-link-single-cond.ts +5 -1
- package/src/de-logic/de-logic-link/de-logic-link.ts +6 -6
- package/src/de-logic/de-logic-node/de-logic-node.ts +2 -1
- package/src/de-logic/de-logic-node/index.ts +1 -0
- package/src/de-logic/de-logic.ts +60 -123
- package/src/de-logic/index.ts +66 -85
- package/src/de-logic/provider.ts +83 -0
- package/src/install.ts +6 -0
- package/src/interface/api/common/i-api-de-logic-params.ts +8 -0
- package/src/interface/api/common/i-api-logic-context.ts +83 -0
- package/src/interface/api/common/i-api-logic-params.ts +29 -0
- package/src/interface/api/common/i-api-ui-logic-params.ts +3 -24
- package/src/interface/api/common/index.ts +2 -0
- package/src/interface/api/controller/control/form-detail/i-api-form-detail.controller.ts +1 -1
- package/src/interface/common/i-logic-context/i-logic-context.ts +27 -0
- package/src/interface/common/i-logic-link-cond/i-logic-link-cond.ts +18 -0
- package/src/interface/common/index.ts +2 -1
- package/src/interface/de-logic/i-de-logic-context.ts +9 -0
- package/src/interface/de-logic/i-de-logic-link-cond.ts +33 -0
- package/src/interface/de-logic/i-de-logic-link.ts +47 -0
- package/src/interface/de-logic/i-de-logic-node.ts +9 -0
- package/src/interface/de-logic/i-de-logic-params.ts +9 -0
- package/src/interface/de-logic/i-de-logic.ts +23 -0
- package/src/interface/de-logic/index.ts +10 -0
- package/src/interface/index.ts +1 -0
- package/src/interface/provider/i-de-logic-node.provider.ts +29 -0
- package/src/interface/provider/i-de-logic.provider.ts +22 -0
- package/src/interface/provider/i-ui-action.provider.ts +2 -1
- package/src/interface/provider/i-ui-logic-node.provider.ts +20 -14
- package/src/interface/provider/i-ui-logic.provider.ts +22 -0
- package/src/interface/provider/index.ts +3 -0
- package/src/interface/register/i-register-params.ts +49 -35
- package/src/interface/ui-logic/i-ui-logic-context.ts +9 -95
- package/src/interface/ui-logic/i-ui-logic-link-cond.ts +33 -0
- package/src/interface/ui-logic/i-ui-logic-link.ts +47 -0
- package/src/interface/ui-logic/i-ui-logic-node.ts +9 -0
- package/src/interface/{common/i-ui-logic-params → ui-logic}/i-ui-logic-params.ts +3 -5
- package/src/interface/ui-logic/i-ui-logic.ts +23 -0
- package/src/interface/ui-logic/index.ts +9 -0
- package/src/locale/en/index.ts +38 -0
- package/src/locale/zh-CN/index.ts +36 -0
- package/src/register/custom-register.ts +184 -82
- package/src/register/helper/app-menu-item-register.ts +26 -13
- package/src/register/helper/control-register.ts +2 -2
- package/src/register/helper/de-logic-node-register.ts +76 -0
- package/src/register/helper/de-logic-register.ts +63 -0
- package/src/register/helper/de-method-register.ts +4 -4
- package/src/register/helper/editor-register.ts +4 -7
- package/src/register/helper/form-detail-register.ts +3 -3
- package/src/register/helper/grid-column-register.ts +9 -9
- package/src/register/helper/index.ts +3 -0
- package/src/register/helper/panel-item-register.ts +4 -4
- package/src/register/helper/portlet-register.ts +23 -22
- package/src/register/helper/toolbar-item-register.ts +32 -19
- package/src/register/helper/ui-action-register.ts +2 -2
- package/src/register/helper/ui-logic-node-register.ts +79 -25
- package/src/register/helper/ui-logic-register.ts +63 -0
- package/src/register/helper/view-register.ts +15 -0
- package/src/service/service/entity/method/de-action.ts +7 -1
- package/src/ui-logic/index.ts +17 -16
- package/src/ui-logic/provider.ts +122 -0
- package/src/ui-logic/ui-logic-context.ts +1 -1
- package/src/ui-logic/ui-logic-link/ui-logic-link-cond/ui-logic-link-cond.ts +18 -5
- package/src/ui-logic/ui-logic-link/ui-logic-link-group-cond/ui-logic-link-group-cond.ts +5 -1
- package/src/ui-logic/ui-logic-link/ui-logic-link-single-cond/ui-logic-link-single-cond.ts +5 -1
- package/src/ui-logic/ui-logic-link/ui-logic-link.ts +6 -7
- package/src/ui-logic/ui-logic-node/pf-plugin-node/pf-plugin-node.ts +3 -3
- package/src/ui-logic/ui-logic-node/ui-logic-node.ts +9 -14
- package/src/ui-logic/ui-logic.ts +46 -141
- package/src/utils/dr-ctrl-util/index.ts +7 -1
- package/out/interface/common/i-ui-logic-params/i-ui-logic-params.d.ts.map +0 -1
- /package/out/interface/{common/i-ui-logic-params/i-ui-logic-params.js → api/common/i-api-de-logic-params.js} +0 -0
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import { ILogicLinkCond } from '../common';
|
|
2
|
+
import { IUILogicContext } from './i-ui-logic-context';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* @description 界面逻辑连接条件接口
|
|
6
|
+
* @export
|
|
7
|
+
* @interface IUILogicLinkCond
|
|
8
|
+
*/
|
|
9
|
+
export interface IUILogicLinkCond extends ILogicLinkCond {
|
|
10
|
+
/**
|
|
11
|
+
* @description 条件判断
|
|
12
|
+
* @param {IUILogicContext} ctx 界面逻辑执行上下文
|
|
13
|
+
* @param {IContext} context 上下文
|
|
14
|
+
* @param {IData} data 数据
|
|
15
|
+
* @returns {*} {boolean}
|
|
16
|
+
* @memberof IUILogicLinkCond
|
|
17
|
+
*/
|
|
18
|
+
test(ctx: IUILogicContext, context: IContext, data: IData): boolean;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
/**
|
|
22
|
+
* @description 界面逻辑连接条件项接口
|
|
23
|
+
* @export
|
|
24
|
+
* @interface IUILogicLinkSingleCond
|
|
25
|
+
*/
|
|
26
|
+
export interface IUILogicLinkSingleCond extends IUILogicLinkCond {}
|
|
27
|
+
|
|
28
|
+
/**
|
|
29
|
+
* @description 界面逻辑连接条件组接口
|
|
30
|
+
* @export
|
|
31
|
+
* @interface IUILogicLinkGroupCond
|
|
32
|
+
*/
|
|
33
|
+
export interface IUILogicLinkGroupCond extends IUILogicLinkCond {}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { IDEUILogicLink } from '@ibiz/model-core';
|
|
2
|
+
import { IUILogicLinkGroupCond } from './i-ui-logic-link-cond';
|
|
3
|
+
import { IUILogicNode } from './i-ui-logic-node';
|
|
4
|
+
import { IUILogicContext } from './i-ui-logic-context';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* @description 界面逻辑连线接口
|
|
8
|
+
* @export
|
|
9
|
+
* @interface IUILogicLink
|
|
10
|
+
*/
|
|
11
|
+
export interface IUILogicLink {
|
|
12
|
+
/**
|
|
13
|
+
* @description 源节点
|
|
14
|
+
* @type {(IUILogicNode | null)}
|
|
15
|
+
* @memberof IUILogicLink
|
|
16
|
+
*/
|
|
17
|
+
srcNode: IUILogicNode | null;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* @description 目标节点
|
|
21
|
+
* @type {(IUILogicNode | null)}
|
|
22
|
+
* @memberof IUILogicLink
|
|
23
|
+
*/
|
|
24
|
+
dstNode: IUILogicNode | null;
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* @description 模型
|
|
28
|
+
* @type {IDEUILogicLink}
|
|
29
|
+
* @memberof IUILogicLink
|
|
30
|
+
*/
|
|
31
|
+
model: IDEUILogicLink;
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* @description 连接条件组
|
|
35
|
+
* @type {(IUILogicLinkGroupCond | null)}
|
|
36
|
+
* @memberof IUILogicLink
|
|
37
|
+
*/
|
|
38
|
+
groupCond: IUILogicLinkGroupCond | null;
|
|
39
|
+
|
|
40
|
+
/**
|
|
41
|
+
* @description 执行连接
|
|
42
|
+
* @param {IUILogicContext} ctx 界面逻辑执行上下文
|
|
43
|
+
* @returns {*} {Promise<boolean>}
|
|
44
|
+
* @memberof IUILogicLink
|
|
45
|
+
*/
|
|
46
|
+
exec(ctx: IUILogicContext): Promise<boolean>;
|
|
47
|
+
}
|
|
@@ -1,10 +1,8 @@
|
|
|
1
|
-
import { IApiUILogicParams } from '
|
|
2
|
-
import { IControlController, IViewController } from '
|
|
1
|
+
import { IApiUILogicParams } from '../api';
|
|
2
|
+
import { IControlController, IViewController } from '../controller';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
6
|
-
* @author lxm
|
|
7
|
-
* @date 2023-05-08 09:31:01
|
|
5
|
+
* @description 界面逻辑通用参数接口
|
|
8
6
|
* @export
|
|
9
7
|
* @interface IUILogicParams
|
|
10
8
|
* @extends {IApiUILogicParams}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { IAppDataEntity, IDEUILogic } from '@ibiz/model-core';
|
|
2
|
+
import { IUILogicProvider } from '../provider';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* @description 界面逻辑接口
|
|
6
|
+
* @export
|
|
7
|
+
* @interface IUILogic
|
|
8
|
+
* @extends {IUILogicProvider}
|
|
9
|
+
*/
|
|
10
|
+
export interface IUILogic extends IUILogicProvider {
|
|
11
|
+
/**
|
|
12
|
+
* @description 模型
|
|
13
|
+
* @type {IDEUILogic}
|
|
14
|
+
* @memberof IUILogic
|
|
15
|
+
*/
|
|
16
|
+
model: IDEUILogic;
|
|
17
|
+
/**
|
|
18
|
+
* @description 实体模型
|
|
19
|
+
* @type {IAppDataEntity}
|
|
20
|
+
* @memberof IUILogic
|
|
21
|
+
*/
|
|
22
|
+
entity: IAppDataEntity;
|
|
23
|
+
}
|
|
@@ -1 +1,10 @@
|
|
|
1
1
|
export type { IUILogicContext } from './i-ui-logic-context';
|
|
2
|
+
export type { IUILogicLink } from './i-ui-logic-link';
|
|
3
|
+
export type { IUILogic } from './i-ui-logic';
|
|
4
|
+
export type { IUILogicNode } from './i-ui-logic-node';
|
|
5
|
+
export type {
|
|
6
|
+
IUILogicLinkCond,
|
|
7
|
+
IUILogicLinkGroupCond,
|
|
8
|
+
IUILogicLinkSingleCond,
|
|
9
|
+
} from './i-ui-logic-link-cond';
|
|
10
|
+
export type { IUILogicParams } from './i-ui-logic-params';
|
package/src/locale/en/index.ts
CHANGED
|
@@ -444,6 +444,10 @@ export const en = {
|
|
|
444
444
|
noImplementedRouting:
|
|
445
445
|
'Getting view routing parameter variables is not implemented',
|
|
446
446
|
},
|
|
447
|
+
application: {
|
|
448
|
+
noExtensionPlugin:
|
|
449
|
+
'Attempted to load application [{appId}] extension plugin, but no extension plugin was found',
|
|
450
|
+
},
|
|
447
451
|
hub: {
|
|
448
452
|
failedParse: 'View parameter {paramsName} failed to parse: {error}',
|
|
449
453
|
noExist: 'View [{id}] does not exist',
|
|
@@ -578,6 +582,40 @@ export const en = {
|
|
|
578
582
|
'Cannot find the adapter corresponding to the toolbar item plugin {pluginKey}.',
|
|
579
583
|
acItem:
|
|
580
584
|
'Cannot find the adapter corresponding to the ac item plugin {pluginKey}.',
|
|
585
|
+
viewCustomRegistration:
|
|
586
|
+
'[Custom Extended View] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
587
|
+
ctrlCustomRegistration:
|
|
588
|
+
'[Custom Extended Control] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
589
|
+
panelItemCustomRegistration:
|
|
590
|
+
'[Custom Extended Panel Item] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
591
|
+
formDetailCustomRegistration:
|
|
592
|
+
'[Custom Extended Form Detail] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
593
|
+
gridColumnCustomRegistration:
|
|
594
|
+
'[Custom Extended Grid Column] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
595
|
+
editorCustomRegistration:
|
|
596
|
+
'[Custom Extended Editor] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
597
|
+
uiactionCustomRegistration:
|
|
598
|
+
'[Custom Extended UIAction] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
599
|
+
deMethodCustomRegistration:
|
|
600
|
+
'[Custom Extended DEMethod] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
601
|
+
uiLogic: 'Cannot find an adapter for the corresponding interface logic',
|
|
602
|
+
frontEndTypeNode:
|
|
603
|
+
'Cannot find an adapter for node type {logicNodeType}',
|
|
604
|
+
uiLogicCustomRegistration:
|
|
605
|
+
'[Custom Extended UILogic] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
606
|
+
uiLogicNodeCustomRegistration:
|
|
607
|
+
'[Custom Extended UILogic Node] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
608
|
+
menuItemCustomRegistration:
|
|
609
|
+
'[Custom Extended Menu Item] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
610
|
+
deLogicCustomRegistration:
|
|
611
|
+
'[Custom Extended DELogic] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
612
|
+
deLogic: 'Cannot find an adapter for the corresponding entity logic',
|
|
613
|
+
deLogicNodeCustomRegistration:
|
|
614
|
+
'[Custom Extended DELogic Node] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
615
|
+
portalCustomRegistration:
|
|
616
|
+
'[Custom Extended Portlet] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
617
|
+
toolbarItemCustomRegistration:
|
|
618
|
+
'[Custom Extended Toolbar Item] Cannot find an adapter with a custom registration ID of [{registerKey}].',
|
|
581
619
|
},
|
|
582
620
|
},
|
|
583
621
|
service: {
|
|
@@ -371,6 +371,9 @@ export const zhCn = {
|
|
|
371
371
|
global: {
|
|
372
372
|
noImplemented: '获取应用全局变量没有实现',
|
|
373
373
|
},
|
|
374
|
+
application: {
|
|
375
|
+
noExtensionPlugin: '尝试加载应用[{appId}]扩展插件,暂未找到扩展插件',
|
|
376
|
+
},
|
|
374
377
|
hub: {
|
|
375
378
|
failedParse: '视图参数 {paramsName} 解析失败:{error}',
|
|
376
379
|
noExist: '视图[{id}]不存在',
|
|
@@ -468,6 +471,39 @@ export const zhCn = {
|
|
|
468
471
|
'找不到视图类型:[{viewType}]的视图样式:[{viewStyle}]对应的适配器',
|
|
469
472
|
toolbarItem: '找不到工具栏项插件{pluginKey}对应的适配器',
|
|
470
473
|
acItem: '找不到自填列表项插件{pluginKey}对应的适配器',
|
|
474
|
+
viewCustomRegistration:
|
|
475
|
+
'[自定义扩展视图] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
476
|
+
ctrlCustomRegistration:
|
|
477
|
+
'[自定义扩展部件] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
478
|
+
panelItemCustomRegistration:
|
|
479
|
+
'[自定义扩展面板项] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
480
|
+
formDetailCustomRegistration:
|
|
481
|
+
'[自定义扩展表单成员] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
482
|
+
gridColumnCustomRegistration:
|
|
483
|
+
'[自定义扩展表格列] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
484
|
+
editorCustomRegistration:
|
|
485
|
+
'[自定义扩展编辑器] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
486
|
+
uiactionCustomRegistration:
|
|
487
|
+
'[自定义扩展界面行为] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
488
|
+
deMethodCustomRegistration:
|
|
489
|
+
'[自定义扩展实体方法] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
490
|
+
uiLogic: '找不到界面逻辑对应的适配器',
|
|
491
|
+
frontEndTypeNode: '找不到节点类型{logicNodeType}对应的适配器',
|
|
492
|
+
uiLogicCustomRegistration:
|
|
493
|
+
'[自定义扩展界面逻辑] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
494
|
+
uiLogicNodeCustomRegistration:
|
|
495
|
+
'[自定义扩展界面逻辑节点] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
496
|
+
menuItemCustomRegistration:
|
|
497
|
+
'[自定义扩展菜单项] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
498
|
+
deLogicCustomRegistration:
|
|
499
|
+
'[自定义扩展实体逻辑] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
500
|
+
deLogic: '找不到实体逻辑对应的适配器',
|
|
501
|
+
deLogicNodeCustomRegistration:
|
|
502
|
+
'[自定义扩展实体逻辑节点] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
503
|
+
portalCustomRegistration:
|
|
504
|
+
'[自定义扩展门户部件] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
505
|
+
toolbarItemCustomRegistration:
|
|
506
|
+
'[自定义扩展工具栏项] 找不到自定义注册标识为[{registerKey}]对应的适配器',
|
|
471
507
|
},
|
|
472
508
|
},
|
|
473
509
|
service: {
|
|
@@ -1,88 +1,156 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { IControl, IAppDEMethod, IAppDEUIAction } from '@ibiz/model-core';
|
|
2
2
|
import { IRegisterParams } from '../interface';
|
|
3
3
|
import {
|
|
4
|
+
VIEW_PROVIDER_PREFIX,
|
|
5
|
+
EDITOR_PROVIDER_PREFIX,
|
|
6
|
+
PORTLET_PROVIDER_PREFIX,
|
|
7
|
+
DELOGIC_PROVIDER_PREFIX,
|
|
8
|
+
UILOGIC_PROVIDER_PREFIX,
|
|
4
9
|
CONTROL_PROVIDER_PREFIX,
|
|
5
10
|
DEMETHOD_PROVIDER_PREFIX,
|
|
6
|
-
|
|
11
|
+
UIACTION_PROVIDER_PREFIX,
|
|
12
|
+
PANELITEM_PROVIDER_PREFIX,
|
|
7
13
|
FORMDETAIL_PROVIDER_PREFIX,
|
|
8
14
|
GRIDCOLUMN_PROVIDER_PREFIX,
|
|
9
|
-
|
|
10
|
-
|
|
15
|
+
APPMENUITEM_PROVIDER_PREFIX,
|
|
16
|
+
UILOGICNODE_PROVIDER_PREFIX,
|
|
17
|
+
DELOGICNODE_PROVIDER_PREFIX,
|
|
18
|
+
TOOLBAR_ITEM_PROVIDER_PREFIX,
|
|
11
19
|
} from './helper';
|
|
20
|
+
import { calcDeCodeNameById } from '../model';
|
|
12
21
|
|
|
13
22
|
/**
|
|
14
23
|
* 自定义注册
|
|
15
24
|
*/
|
|
16
25
|
export class CustomRegister {
|
|
17
26
|
/**
|
|
18
|
-
* 获取适配器注册key
|
|
19
|
-
*
|
|
20
|
-
* @author ljx
|
|
21
|
-
* @date 2024-04-16 23:08:08
|
|
27
|
+
* @description 获取适配器注册key
|
|
28
|
+
* @static
|
|
22
29
|
* @param {string} registerType
|
|
23
30
|
* @param {IRegisterParams} opts
|
|
24
|
-
* @
|
|
31
|
+
* @returns {*} {string}
|
|
32
|
+
* @memberof CustomRegister
|
|
25
33
|
*/
|
|
26
34
|
static getRegisterKey(registerType: string, opts: IRegisterParams): string {
|
|
27
35
|
switch (registerType) {
|
|
36
|
+
case VIEW_PROVIDER_PREFIX:
|
|
37
|
+
return this.calcExtensionViewKey(opts);
|
|
38
|
+
case CONTROL_PROVIDER_PREFIX:
|
|
39
|
+
case PORTLET_PROVIDER_PREFIX:
|
|
40
|
+
return this.calcExtensionControlKey(opts);
|
|
28
41
|
case PANELITEM_PROVIDER_PREFIX:
|
|
29
|
-
return this.
|
|
42
|
+
return this.calcExtensionPanelItemKey(opts);
|
|
30
43
|
case FORMDETAIL_PROVIDER_PREFIX:
|
|
31
44
|
case GRIDCOLUMN_PROVIDER_PREFIX:
|
|
32
|
-
case
|
|
33
|
-
|
|
45
|
+
case APPMENUITEM_PROVIDER_PREFIX:
|
|
46
|
+
case TOOLBAR_ITEM_PROVIDER_PREFIX:
|
|
47
|
+
return this.calcExtensionControlItemKey(opts);
|
|
48
|
+
case EDITOR_PROVIDER_PREFIX:
|
|
49
|
+
return this.calcExtensionEditorKey(opts);
|
|
34
50
|
case UIACTION_PROVIDER_PREFIX:
|
|
35
|
-
return this.
|
|
51
|
+
return this.calcExtensionUIActionKey(opts);
|
|
36
52
|
case DEMETHOD_PROVIDER_PREFIX:
|
|
37
|
-
return this.
|
|
38
|
-
case
|
|
39
|
-
|
|
53
|
+
return this.calcExtensionMethodKey(opts);
|
|
54
|
+
case UILOGIC_PROVIDER_PREFIX:
|
|
55
|
+
case DELOGIC_PROVIDER_PREFIX:
|
|
56
|
+
return this.calcExtensionLogicKey(opts);
|
|
57
|
+
case UILOGICNODE_PROVIDER_PREFIX:
|
|
58
|
+
case DELOGICNODE_PROVIDER_PREFIX:
|
|
59
|
+
return this.calcExtensionLogicNodeKey(opts);
|
|
40
60
|
default:
|
|
41
61
|
return '';
|
|
42
62
|
}
|
|
43
63
|
}
|
|
44
64
|
|
|
45
65
|
/**
|
|
46
|
-
*
|
|
47
|
-
*
|
|
48
|
-
* @author ljx
|
|
49
|
-
* @date 2024-04-16 23:08:08
|
|
66
|
+
* @description 计算扩展视图key,(appId@codeName)全大写
|
|
67
|
+
* @static
|
|
50
68
|
* @param {IRegisterParams} opts
|
|
51
|
-
* @
|
|
69
|
+
* @returns {*} {string}
|
|
70
|
+
* @memberof CustomRegister
|
|
52
71
|
*/
|
|
53
|
-
static
|
|
54
|
-
const {
|
|
72
|
+
static calcExtensionViewKey(opts: IRegisterParams): string {
|
|
73
|
+
const { mainModel } = opts;
|
|
55
74
|
let key = '';
|
|
75
|
+
if (mainModel.appId) {
|
|
76
|
+
key += `${mainModel.appId.toUpperCase()}`;
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
if (mainModel.codeName) {
|
|
80
|
+
key += `@${mainModel.codeName.toUpperCase()}`;
|
|
81
|
+
}
|
|
82
|
+
return key;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/**
|
|
86
|
+
* @description 计算扩展部件key,(appId/DEFAULT@实体codeName/APP@部件类型@部件codeName)全大写
|
|
87
|
+
* @static
|
|
88
|
+
* @param {IRegisterParams} opts
|
|
89
|
+
* @returns {*} {string}
|
|
90
|
+
* @memberof CustomRegister
|
|
91
|
+
*/
|
|
92
|
+
static calcExtensionControlKey(opts: IRegisterParams): string {
|
|
93
|
+
let key = '';
|
|
94
|
+
const { mainModel } = opts;
|
|
95
|
+
if (mainModel) {
|
|
96
|
+
key = (mainModel.appId || 'DEFAULT').toUpperCase();
|
|
97
|
+
const { appDataEntityId, controlType, codeName } = mainModel as IControl;
|
|
98
|
+
if (appDataEntityId) {
|
|
99
|
+
key += `@${calcDeCodeNameById(appDataEntityId).toUpperCase()}`;
|
|
100
|
+
} else {
|
|
101
|
+
key += '@APP';
|
|
102
|
+
}
|
|
103
|
+
if (controlType) {
|
|
104
|
+
key += `@${controlType.toUpperCase()}`;
|
|
105
|
+
}
|
|
106
|
+
if (codeName) {
|
|
107
|
+
key += `@${codeName.toUpperCase()}`;
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
return key;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
/**
|
|
114
|
+
* @description 计算扩展面板key,(appId/DEFAULT@视图codeName@部件codeName@面板项标识)全大写
|
|
115
|
+
* @static
|
|
116
|
+
* @param {IRegisterParams} opts
|
|
117
|
+
* @returns {*} {string}
|
|
118
|
+
* @memberof CustomRegister
|
|
119
|
+
*/
|
|
120
|
+
static calcExtensionPanelItemKey(opts: IRegisterParams): string {
|
|
121
|
+
const { mainModel, view, control } = opts;
|
|
122
|
+
let key = `${(mainModel.appId || 'DEFAULT').toUpperCase()}`;
|
|
56
123
|
|
|
57
|
-
if (
|
|
58
|
-
key +=
|
|
124
|
+
if (view?.codeName) {
|
|
125
|
+
key += `@${view.codeName.toUpperCase()}`;
|
|
59
126
|
}
|
|
60
127
|
|
|
61
|
-
if (
|
|
62
|
-
key += `@${
|
|
128
|
+
if (control?.codeName) {
|
|
129
|
+
key += `@${control.codeName.toUpperCase()}`;
|
|
63
130
|
}
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
key += `@${controlItemModel.id.toUpperCase()}`;
|
|
131
|
+
if (mainModel?.id) {
|
|
132
|
+
key += `@${mainModel.id.toUpperCase()}`;
|
|
67
133
|
}
|
|
68
134
|
return key;
|
|
69
135
|
}
|
|
70
136
|
|
|
71
137
|
/**
|
|
72
|
-
*
|
|
73
|
-
*
|
|
74
|
-
* @date 2024-04-16 23:08:08
|
|
138
|
+
* @description 计算扩展部件项key,(appId/DEFAULT@实体codeName/APP@部件类型@部件codeName@部件项codeName/@部件项id)全大写
|
|
139
|
+
* @static
|
|
75
140
|
* @param {IRegisterParams} opts
|
|
76
|
-
* @
|
|
141
|
+
* @returns {*} {string}
|
|
142
|
+
* @memberof CustomRegister
|
|
77
143
|
*/
|
|
78
|
-
static
|
|
79
|
-
const {
|
|
144
|
+
static calcExtensionControlItemKey(opts: IRegisterParams): string {
|
|
145
|
+
const { mainModel, control } = opts;
|
|
80
146
|
let key = '';
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
const { appDataEntityId, controlType, codeName } =
|
|
147
|
+
if (mainModel) {
|
|
148
|
+
key = (mainModel.appId || 'DEFAULT').toUpperCase();
|
|
149
|
+
const { appDataEntityId, controlType, codeName } = control as IControl;
|
|
84
150
|
if (appDataEntityId) {
|
|
85
|
-
|
|
151
|
+
key += `@${calcDeCodeNameById(appDataEntityId).toUpperCase()}`;
|
|
152
|
+
} else {
|
|
153
|
+
key += '@APP';
|
|
86
154
|
}
|
|
87
155
|
if (controlType) {
|
|
88
156
|
key += `@${controlType.toUpperCase()}`;
|
|
@@ -90,32 +158,59 @@ export class CustomRegister {
|
|
|
90
158
|
if (codeName) {
|
|
91
159
|
key += `@${codeName.toUpperCase()}`;
|
|
92
160
|
}
|
|
161
|
+
const _codeName = mainModel.codeName || mainModel.id;
|
|
162
|
+
if (_codeName) {
|
|
163
|
+
key += `@${_codeName.toUpperCase()}`;
|
|
164
|
+
}
|
|
93
165
|
}
|
|
166
|
+
return key;
|
|
167
|
+
}
|
|
94
168
|
|
|
95
|
-
|
|
96
|
-
|
|
169
|
+
/**
|
|
170
|
+
* @description 计算扩展编辑器key,(appId/DEFAULT@实体codeName/APP@部件类型@部件codeName@项标识_EDITOR)全大写
|
|
171
|
+
* @static
|
|
172
|
+
* @param {IRegisterParams} opts
|
|
173
|
+
* @returns {*} {string}
|
|
174
|
+
* @memberof CustomRegister
|
|
175
|
+
*/
|
|
176
|
+
static calcExtensionEditorKey(opts: IRegisterParams): string {
|
|
177
|
+
const { mainModel, control } = opts;
|
|
178
|
+
let key = (mainModel.appId || 'DEFAULT').toUpperCase();
|
|
179
|
+
if (control) {
|
|
180
|
+
const { appDataEntityId, controlType, codeName } = control as IControl;
|
|
181
|
+
if (appDataEntityId) {
|
|
182
|
+
key += `@${calcDeCodeNameById(appDataEntityId).toUpperCase()}`;
|
|
183
|
+
} else {
|
|
184
|
+
key += '@APP';
|
|
185
|
+
}
|
|
186
|
+
key += `@${(controlType || 'DEFAULT').toUpperCase()}`;
|
|
187
|
+
key += `@${(codeName || 'DEFAULT').toUpperCase()}`;
|
|
188
|
+
}
|
|
189
|
+
if (mainModel.id) {
|
|
190
|
+
key += `@${mainModel.id.toUpperCase()}_EDITOR`;
|
|
97
191
|
}
|
|
98
|
-
key = prefix + key;
|
|
99
192
|
return key;
|
|
100
193
|
}
|
|
101
194
|
|
|
102
195
|
/**
|
|
103
|
-
* @description
|
|
196
|
+
* @description 计算扩展界面行为key,(appId/DEFAULT@实体codeName/APP@界面行为标记)全大写
|
|
197
|
+
* @author tony001
|
|
198
|
+
* @date 2026-08-11 17:08:45
|
|
104
199
|
* @static
|
|
105
200
|
* @param {IRegisterParams} opts
|
|
106
201
|
* @returns {*} {string}
|
|
107
202
|
* @memberof CustomRegister
|
|
108
203
|
*/
|
|
109
|
-
static
|
|
110
|
-
const {
|
|
111
|
-
let
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
const { appDataEntityId, uiactionTag } = uiActionModel as IData;
|
|
204
|
+
static calcExtensionUIActionKey(opts: IRegisterParams): string {
|
|
205
|
+
const { mainModel } = opts;
|
|
206
|
+
let key: string = (mainModel.appId || 'DEFAULT').toUpperCase();
|
|
207
|
+
if (mainModel) {
|
|
208
|
+
const { appDataEntityId, uiactionTag } = mainModel as IAppDEUIAction;
|
|
115
209
|
if (appDataEntityId) {
|
|
116
|
-
|
|
210
|
+
key += `@${calcDeCodeNameById(appDataEntityId).toUpperCase()}`;
|
|
211
|
+
} else {
|
|
212
|
+
key += '@APP';
|
|
117
213
|
}
|
|
118
|
-
key += `${prefix}`;
|
|
119
214
|
if (uiactionTag) {
|
|
120
215
|
key += `@${uiactionTag.toUpperCase()}`;
|
|
121
216
|
}
|
|
@@ -124,20 +219,20 @@ export class CustomRegister {
|
|
|
124
219
|
}
|
|
125
220
|
|
|
126
221
|
/**
|
|
127
|
-
* @description
|
|
222
|
+
* @description 计算扩展实体方法key,(appId/DEFAULT@实体codeName/方法类型/方法codeName)全大写
|
|
128
223
|
* @static
|
|
129
224
|
* @param {IRegisterParams} opts
|
|
130
225
|
* @returns {*} {string}
|
|
131
226
|
* @memberof CustomRegister
|
|
132
227
|
*/
|
|
133
|
-
static
|
|
134
|
-
const {
|
|
135
|
-
let key: string = '';
|
|
136
|
-
if (
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
}
|
|
228
|
+
static calcExtensionMethodKey(opts: IRegisterParams): string {
|
|
229
|
+
const { mainModel, entity } = opts;
|
|
230
|
+
let key: string = (mainModel.appId || 'DEFAULT').toUpperCase();
|
|
231
|
+
if (entity?.id) {
|
|
232
|
+
key += `@${calcDeCodeNameById(entity.id).toUpperCase()}`;
|
|
233
|
+
}
|
|
234
|
+
if (mainModel) {
|
|
235
|
+
const { methodType, codeName } = mainModel as IAppDEMethod;
|
|
141
236
|
if (methodType && codeName) {
|
|
142
237
|
key += `@${methodType.toUpperCase()}@${codeName.toUpperCase()}`;
|
|
143
238
|
}
|
|
@@ -146,36 +241,43 @@ export class CustomRegister {
|
|
|
146
241
|
}
|
|
147
242
|
|
|
148
243
|
/**
|
|
149
|
-
* @description
|
|
244
|
+
* @description 计算逻辑key,(appId/DEFAULT@实体codeName@逻辑codeName)全大写
|
|
150
245
|
* @static
|
|
151
246
|
* @param {IRegisterParams} opts
|
|
152
247
|
* @returns {*} {string}
|
|
153
248
|
* @memberof CustomRegister
|
|
154
249
|
*/
|
|
155
|
-
static
|
|
156
|
-
const {
|
|
157
|
-
let key = '';
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
const { appDataEntityId, controlType, codeName } = controlModel;
|
|
161
|
-
if (appDataEntityId) {
|
|
162
|
-
prefix = calcDeCodeNameById(appDataEntityId).toUpperCase();
|
|
163
|
-
}
|
|
164
|
-
if (controlType) {
|
|
165
|
-
key += `@${controlType.toUpperCase()}`;
|
|
166
|
-
}
|
|
167
|
-
if (codeName) {
|
|
168
|
-
key += `@${codeName.toUpperCase()}`;
|
|
169
|
-
}
|
|
250
|
+
static calcExtensionLogicKey(opts: IRegisterParams): string {
|
|
251
|
+
const { mainModel, entity } = opts;
|
|
252
|
+
let key: string = (mainModel.appId || 'DEFAULT').toUpperCase();
|
|
253
|
+
if (entity?.id) {
|
|
254
|
+
key += `@${calcDeCodeNameById(entity.id).toUpperCase()}`;
|
|
170
255
|
}
|
|
256
|
+
if (mainModel.codeName) {
|
|
257
|
+
key += `@${mainModel.codeName.toUpperCase()}`;
|
|
258
|
+
}
|
|
259
|
+
return key;
|
|
260
|
+
}
|
|
171
261
|
|
|
172
|
-
|
|
173
|
-
|
|
262
|
+
/**
|
|
263
|
+
* @description 计算实体界面逻辑节点key,(appId/DEFAULT@实体codeName@逻辑codeName@逻辑节点codeName)全大写
|
|
264
|
+
* @static
|
|
265
|
+
* @param {IRegisterParams} opts
|
|
266
|
+
* @returns {*} {string}
|
|
267
|
+
* @memberof CustomRegister
|
|
268
|
+
*/
|
|
269
|
+
static calcExtensionLogicNodeKey(opts: IRegisterParams): string {
|
|
270
|
+
const { mainModel, entity, logic } = opts;
|
|
271
|
+
let key: string = (mainModel.appId || 'DEFAULT').toUpperCase();
|
|
272
|
+
if (entity?.id) {
|
|
273
|
+
key += `@${calcDeCodeNameById(entity.id).toUpperCase()}`;
|
|
274
|
+
}
|
|
275
|
+
if (logic?.codeName) {
|
|
276
|
+
key += `@${logic.codeName.toUpperCase()}`;
|
|
174
277
|
}
|
|
175
|
-
if (
|
|
176
|
-
key +=
|
|
278
|
+
if (mainModel.codeName) {
|
|
279
|
+
key += `@${mainModel.codeName.toUpperCase()}`;
|
|
177
280
|
}
|
|
178
|
-
key = prefix + key;
|
|
179
281
|
return key;
|
|
180
282
|
}
|
|
181
283
|
}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
import { IAppMenuItem } from '@ibiz/model-core';
|
|
1
|
+
import { IAppMenu, IAppMenuItem } from '@ibiz/model-core';
|
|
2
2
|
import { getPluginRegisterKey } from './common-register';
|
|
3
3
|
import { IAppMenuItemProvider } from '../../interface';
|
|
4
|
+
import { CustomRegister } from '../custom-register';
|
|
4
5
|
|
|
5
6
|
/** 应用菜单项适配器前缀 */
|
|
6
7
|
export const APPMENUITEM_PROVIDER_PREFIX = 'APPMENUITEM';
|
|
@@ -38,25 +39,37 @@ function getProvider(key: string): IAppMenuItemProvider | undefined {
|
|
|
38
39
|
*/
|
|
39
40
|
export async function getAppMenuItemProvider(
|
|
40
41
|
model: IAppMenuItem,
|
|
42
|
+
control: IAppMenu,
|
|
41
43
|
): Promise<IAppMenuItemProvider | undefined> {
|
|
42
44
|
let provider: IAppMenuItemProvider | undefined;
|
|
43
45
|
const { sysPFPluginId, appId, itemType } = model as Required<IAppMenuItem>;
|
|
44
46
|
|
|
47
|
+
// 找自定义注册的适配器
|
|
48
|
+
const registerKey = CustomRegister.getRegisterKey(
|
|
49
|
+
APPMENUITEM_PROVIDER_PREFIX,
|
|
50
|
+
{
|
|
51
|
+
mainModel: model,
|
|
52
|
+
control,
|
|
53
|
+
},
|
|
54
|
+
);
|
|
55
|
+
provider = getProvider(registerKey);
|
|
56
|
+
if (provider) return provider;
|
|
57
|
+
ibiz.log.debug(
|
|
58
|
+
ibiz.i18n.t('runtime.register.helper.menuItemCustomRegistration', {
|
|
59
|
+
registerKey,
|
|
60
|
+
}),
|
|
61
|
+
);
|
|
62
|
+
|
|
45
63
|
// 找插件适配器
|
|
46
64
|
if (sysPFPluginId) {
|
|
47
65
|
const pluginKey = await getPluginRegisterKey(sysPFPluginId, appId);
|
|
48
|
-
if (pluginKey)
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
}),
|
|
56
|
-
);
|
|
57
|
-
} else {
|
|
58
|
-
return provider;
|
|
59
|
-
}
|
|
66
|
+
if (pluginKey) provider = getProvider(pluginKey);
|
|
67
|
+
if (provider) return provider;
|
|
68
|
+
ibiz.log.warn(
|
|
69
|
+
ibiz.i18n.t('runtime.register.helper.applicationMenu', {
|
|
70
|
+
pluginKey,
|
|
71
|
+
}),
|
|
72
|
+
);
|
|
60
73
|
}
|
|
61
74
|
|
|
62
75
|
// 找应用菜单项类型
|