@ibiz-template/runtime 0.4.8 → 0.4.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.esm.js +44 -6
- package/dist/index.system.min.js +2 -2
- package/out/controller/control/gantt/gantt.controller.d.ts +19 -0
- package/out/controller/control/gantt/gantt.controller.d.ts.map +1 -0
- package/out/controller/control/gantt/gantt.controller.js +19 -0
- package/out/controller/control/gantt/gantt.service.d.ts +14 -0
- package/out/controller/control/gantt/gantt.service.d.ts.map +1 -0
- package/out/controller/control/gantt/gantt.service.js +12 -0
- package/out/controller/control/gantt/index.d.ts +3 -0
- package/out/controller/control/gantt/index.d.ts.map +1 -0
- package/out/controller/control/gantt/index.js +2 -0
- package/out/controller/control/index.d.ts +1 -0
- package/out/controller/control/index.d.ts.map +1 -1
- package/out/controller/control/index.js +1 -0
- package/out/controller/control/report-panel/generator/user-generator.js +1 -1
- package/out/interface/controller/controller/control/i-gantt.controller.d.ts +19 -0
- package/out/interface/controller/controller/control/i-gantt.controller.d.ts.map +1 -0
- package/out/interface/controller/controller/control/index.d.ts +1 -0
- package/out/interface/controller/controller/control/index.d.ts.map +1 -1
- package/out/interface/controller/controller/control/index.js +1 -0
- package/out/interface/controller/event/control/i-gantt.event.d.ts +13 -0
- package/out/interface/controller/event/control/i-gantt.event.d.ts.map +1 -0
- package/out/interface/controller/event/control/index.d.ts +1 -0
- package/out/interface/controller/event/control/index.d.ts.map +1 -1
- package/out/interface/controller/event/control/index.js +1 -0
- package/out/interface/controller/event/view/i-gantt-view.event.d.ts +13 -0
- package/out/interface/controller/event/view/i-gantt-view.event.d.ts.map +1 -0
- package/out/interface/controller/event/view/index.d.ts +1 -0
- package/out/interface/controller/event/view/index.d.ts.map +1 -1
- package/out/interface/controller/event/view/index.js +1 -0
- package/out/interface/controller/state/control/i-gantt.state.d.ts +13 -0
- package/out/interface/controller/state/control/i-gantt.state.d.ts.map +1 -0
- package/out/interface/controller/state/control/i-gantt.state.js +1 -0
- package/out/interface/controller/state/control/index.d.ts +1 -0
- package/out/interface/controller/state/control/index.d.ts.map +1 -1
- package/out/interface/controller/state/control/index.js +1 -0
- package/out/interface/controller/state/view/i-gantt-view.state.d.ts +13 -0
- package/out/interface/controller/state/view/i-gantt-view.state.d.ts.map +1 -0
- package/out/interface/controller/state/view/i-gantt-view.state.js +1 -0
- package/out/interface/controller/state/view/index.d.ts +1 -0
- package/out/interface/controller/state/view/index.d.ts.map +1 -1
- package/out/interface/controller/state/view/index.js +1 -0
- package/out/interface/index.d.ts +1 -1
- package/out/interface/index.js +1 -1
- package/out/interface/provider/{i-ui-login-node.provider.d.ts → i-ui-logic-node.provider.d.ts} +2 -2
- package/out/interface/provider/{i-ui-login-node.provider.d.ts.map → i-ui-logic-node.provider.d.ts.map} +1 -1
- package/out/interface/provider/i-ui-logic-node.provider.js +1 -0
- package/out/interface/provider/index.d.ts +1 -1
- package/out/interface/service/service/i-app-de.service.d.ts +66 -0
- package/out/interface/service/service/i-app-de.service.d.ts.map +1 -1
- package/out/interface/{ui-login → ui-logic}/i-ui-logic-context.d.ts.map +1 -1
- package/out/interface/ui-logic/i-ui-logic-context.js +1 -0
- package/out/interface/ui-logic/index.d.ts.map +1 -0
- package/out/interface/ui-logic/index.js +1 -0
- package/out/service/service/entity/de.service.d.ts +6 -0
- package/out/service/service/entity/de.service.d.ts.map +1 -1
- package/out/service/service/entity/de.service.js +18 -0
- package/out/service/service/entity/method/fetch.js +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 -1
- package/out/service/utils/index.d.ts +1 -0
- package/out/service/utils/index.d.ts.map +1 -1
- package/out/service/utils/index.js +1 -0
- package/out/service/utils/util/util.d.ts +14 -0
- package/out/service/utils/util/util.d.ts.map +1 -0
- package/out/service/utils/util/util.js +16 -0
- package/out/service/vo/tree-node-data/tree-data-set-node-data.d.ts.map +1 -1
- package/out/service/vo/tree-node-data/tree-data-set-node-data.js +2 -2
- package/package.json +3 -3
- package/src/controller/control/gantt/gantt.controller.ts +27 -0
- package/src/controller/control/gantt/gantt.service.ts +13 -0
- package/src/controller/control/gantt/index.ts +2 -0
- package/src/controller/control/index.ts +1 -0
- package/src/controller/control/report-panel/generator/user-generator.ts +1 -1
- package/src/interface/controller/controller/control/i-gantt.controller.ts +22 -0
- package/src/interface/controller/controller/control/index.ts +1 -0
- package/src/interface/controller/event/control/i-gantt.event.ts +12 -0
- package/src/interface/controller/event/control/index.ts +1 -0
- package/src/interface/controller/event/view/i-gantt-view.event.ts +12 -0
- package/src/interface/controller/event/view/index.ts +1 -0
- package/src/interface/controller/state/control/i-gantt.state.ts +12 -0
- package/src/interface/controller/state/control/index.ts +1 -0
- package/src/interface/controller/state/view/i-gantt-view.state.ts +12 -0
- package/src/interface/controller/state/view/index.ts +1 -0
- package/src/interface/index.ts +1 -1
- package/src/interface/provider/{i-ui-login-node.provider.ts → i-ui-logic-node.provider.ts} +1 -1
- package/src/interface/provider/index.ts +1 -1
- package/src/interface/service/service/i-app-de.service.ts +96 -0
- package/src/service/service/entity/de.service.ts +48 -0
- package/src/service/service/entity/method/fetch.ts +2 -2
- package/src/service/utils/dynamic-code-list/dynamic-code-list.ts +2 -1
- package/src/service/utils/index.ts +1 -0
- package/src/service/utils/util/util.ts +16 -0
- package/src/service/vo/tree-node-data/tree-data-set-node-data.ts +2 -2
- package/out/interface/ui-login/index.d.ts.map +0 -1
- /package/out/interface/{provider/i-ui-login-node.provider.js → controller/controller/control/i-gantt.controller.js} +0 -0
- /package/out/interface/{ui-login/i-ui-logic-context.js → controller/event/control/i-gantt.event.js} +0 -0
- /package/out/interface/{ui-login/index.js → controller/event/view/i-gantt-view.event.js} +0 -0
- /package/out/interface/{ui-login → ui-logic}/i-ui-logic-context.d.ts +0 -0
- /package/out/interface/{ui-login → ui-logic}/index.d.ts +0 -0
- /package/src/interface/{ui-login → ui-logic}/i-ui-logic-context.ts +0 -0
- /package/src/interface/{ui-login → ui-logic}/index.ts +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dynamic-code-list.d.ts","sourceRoot":"","sources":["../../../../src/service/utils/dynamic-code-list/dynamic-code-list.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAGhD,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;
|
|
1
|
+
{"version":3,"file":"dynamic-code-list.d.ts","sourceRoot":"","sources":["../../../../src/service/utils/dynamic-code-list/dynamic-code-list.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAGhD,OAAO,EAAE,WAAW,EAAE,MAAM,sBAAsB,CAAC;AACnD,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAIlD;;;;;;GAMG;AACH,KAAK,SAAS,GAAG;IACf;;;;;;OAMG;IACH,cAAc,EAAE,MAAM,CAAC;IAEvB;;;;;;OAMG;IACH,KAAK,CAAC,EAAE,YAAY,EAAE,CAAC;IAEvB;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC,YAAY,EAAE,CAAC,CAAC;CACnC,CAAC;AAEF;;;;;;;GAOG;AACH,qBAAa,oBAAoB;IAC/B,SAAS,CAAC,GAAG,EAAG,WAAW,CAAC;IAE5B;;;;;;;OAOG;IACH,SAAS,CAAC,QAAQ,EAAE,YAAY,CAAC;IAEjC;;;;;;OAMG;IACH,SAAS,CAAC,KAAK,yBAAgC;IAE/C;;;;;;;OAOG;IACH,SAAS,CAAC,YAAY,EAAE,OAAO,CAAS;IAExC;;;;;;OAMG;IACH,SAAS,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC,IAAI,CAAC,CAAC;gBAE1B,QAAQ,EAAE,YAAY;IAIlC;;;;;;OAMG;IACG,IAAI,IAAI,OAAO,CAAC,IAAI,CAAC;IAqB3B;;;;;;;OAOG;IACH,SAAS,CAAC,WAAW,CAAC,IAAI,EAAE,KAAK,GAAG,YAAY;IA6DhD;;;;;;;;;OASG;cACa,IAAI,CAClB,OAAO,GAAE,OAAY,EACrB,MAAM,GAAE,OAAY,GACnB,OAAO,CAAC,YAAY,EAAE,CAAC;IAuE1B;;;;OAIG;IACH,SAAS,CAAC,eAAe,CACvB,KAAK,EAAE,KAAK,EAAE,EACd,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,GACvB,YAAY,EAAE,GAAG,SAAS;IAwB7B;;;;;;;;OAQG;IACG,GAAG,CACP,OAAO,GAAE,OAAY,EACrB,MAAM,GAAE,OAAY,GACnB,OAAO,CAAC,YAAY,EAAE,CAAC;CAyC3B"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ModelError, RuntimeModelError } from '@ibiz-template/core';
|
|
2
2
|
import { isNil } from 'ramda';
|
|
3
3
|
import { convertNavData, ScriptFactory } from '../../../utils';
|
|
4
|
+
import { fieldValueToBoolean } from '../../utils';
|
|
4
5
|
/**
|
|
5
6
|
* 动态代码表缓存对象
|
|
6
7
|
*
|
|
@@ -94,7 +95,7 @@ export class DynamicCodeListCache {
|
|
|
94
95
|
}
|
|
95
96
|
// 禁止选择属性
|
|
96
97
|
if (disableAppDEFieldId) {
|
|
97
|
-
result.disableSelect = data[disableAppDEFieldId];
|
|
98
|
+
result.disableSelect = fieldValueToBoolean(data[disableAppDEFieldId]);
|
|
98
99
|
}
|
|
99
100
|
// 数据属性
|
|
100
101
|
if (dataAppDEFieldId && data[dataAppDEFieldId]) {
|
|
@@ -5,4 +5,5 @@ export { DynamicCodeListCache } from './dynamic-code-list/dynamic-code-list';
|
|
|
5
5
|
export { DECache } from './de-cache/de-cache';
|
|
6
6
|
export { getMatchResPath, calcResPath } from './res-path/res-path';
|
|
7
7
|
export { SearchFilter } from './search-filter/search-filter';
|
|
8
|
+
export { fieldValueToBoolean } from './util/util';
|
|
8
9
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/service/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AACjE,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAC7E,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/service/utils/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,eAAe,CAAC;AAC9B,OAAO,EAAE,YAAY,EAAE,MAAM,mCAAmC,CAAC;AACjE,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAC7E,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAC9C,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AACnE,OAAO,EAAE,YAAY,EAAE,MAAM,+BAA+B,CAAC;AAC7D,OAAO,EAAE,mBAAmB,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -5,3 +5,4 @@ export { DynamicCodeListCache } from './dynamic-code-list/dynamic-code-list';
|
|
|
5
5
|
export { DECache } from './de-cache/de-cache';
|
|
6
6
|
export { getMatchResPath, calcResPath } from './res-path/res-path';
|
|
7
7
|
export { SearchFilter } from './search-filter/search-filter';
|
|
8
|
+
export { fieldValueToBoolean } from './util/util';
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 把实体属性的值转换成布尔值
|
|
3
|
+
* 以下值会转成true,其他都为false
|
|
4
|
+
* - 字符串:'1','true',
|
|
5
|
+
* - 数字:1
|
|
6
|
+
* - 布尔值:true
|
|
7
|
+
* @author lxm
|
|
8
|
+
* @date 2023-12-07 05:07:28
|
|
9
|
+
* @export
|
|
10
|
+
* @param {unknown} value
|
|
11
|
+
* @return {*} {boolean}
|
|
12
|
+
*/
|
|
13
|
+
export declare function fieldValueToBoolean(value: unknown): boolean;
|
|
14
|
+
//# sourceMappingURL=util.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"util.d.ts","sourceRoot":"","sources":["../../../../src/service/utils/util/util.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,OAAO,GAAG,OAAO,CAG3D"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 把实体属性的值转换成布尔值
|
|
3
|
+
* 以下值会转成true,其他都为false
|
|
4
|
+
* - 字符串:'1','true',
|
|
5
|
+
* - 数字:1
|
|
6
|
+
* - 布尔值:true
|
|
7
|
+
* @author lxm
|
|
8
|
+
* @date 2023-12-07 05:07:28
|
|
9
|
+
* @export
|
|
10
|
+
* @param {unknown} value
|
|
11
|
+
* @return {*} {boolean}
|
|
12
|
+
*/
|
|
13
|
+
export function fieldValueToBoolean(value) {
|
|
14
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
15
|
+
return [1, '1', true, 'true'].includes(value);
|
|
16
|
+
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tree-data-set-node-data.d.ts","sourceRoot":"","sources":["../../../../src/service/vo/tree-node-data/tree-data-set-node-data.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAC3E,OAAO,EAAE,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAG1D,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"tree-data-set-node-data.d.ts","sourceRoot":"","sources":["../../../../src/service/vo/tree-node-data/tree-data-set-node-data.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAC3E,OAAO,EAAE,KAAK,EAAE,aAAa,EAAE,MAAM,oBAAoB,CAAC;AAG1D,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAGhD;;;;;;;GAOG;AACH,qBAAa,mBAAoB,SAAQ,YAAa,YAAW,aAAa;IAC5E,IAAI,EAAE,MAAM,CAAC;IAEb,EAAE,EAAE,MAAM,CAAC;IAEX,KAAK,EAAE,MAAM,CAAC;IAEd,MAAM,EAAE,KAAK,CAAC;gBAGZ,KAAK,EAAE,kBAAkB,EACzB,cAAc,EAAE,aAAa,GAAG,SAAS,EACzC,IAAI,EAAE;QACJ,IAAI,EAAE,KAAK,CAAC;QACZ,IAAI,EAAE,OAAO,CAAC;QACd,UAAU,CAAC,EAAE,OAAO,CAAC;QACrB,SAAS,CAAC,EAAE,OAAO,CAAC;KACrB;IAqCH,SAAS,CAAC,QAAQ,CAAC,KAAK,EAAE,kBAAkB,GAAG,KAAK,GAAG,SAAS;IAiBhE;;;;;;;OAOG;IACH,SAAS,CAAC,kBAAkB,CAC1B,QAAQ,EAAE,mBAAmB,GAC5B,MAAM,GAAG,SAAS;IAYrB;;;;;;;OAOG;IACH,SAAS,CAAC,YAAY,CAAC,KAAK,EAAE,kBAAkB,GAAG,MAAM,GAAG,SAAS;CAStE"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { calcDeCodeNameById } from '../../../model';
|
|
2
2
|
import { ScriptFactory } from '../../../utils';
|
|
3
3
|
import { TreeNodeData } from './tree-node-data';
|
|
4
|
+
import { fieldValueToBoolean } from '../../utils';
|
|
4
5
|
/**
|
|
5
6
|
* 实体数据集树节点数据
|
|
6
7
|
*
|
|
@@ -38,8 +39,7 @@ export class TreeDataSetNodeData extends TreeNodeData {
|
|
|
38
39
|
this.textHtml = this.calcTextHtml(model);
|
|
39
40
|
// 识别叶子节点标识属性,根据后台数据赋值leaf
|
|
40
41
|
if (model.leafFlagAppDEFieldId) {
|
|
41
|
-
|
|
42
|
-
this.leaf = [1, '1', true, 'true'].includes(value);
|
|
42
|
+
this.leaf = fieldValueToBoolean(data[model.leafFlagAppDEFieldId]);
|
|
43
43
|
}
|
|
44
44
|
}
|
|
45
45
|
calcIcon(model) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ibiz-template/runtime",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.9",
|
|
4
4
|
"description": "控制器包",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "out/index.js",
|
|
@@ -29,7 +29,7 @@
|
|
|
29
29
|
"author": "chitanda",
|
|
30
30
|
"license": "MIT",
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@ibiz-template/core": "^0.4.
|
|
32
|
+
"@ibiz-template/core": "^0.4.9",
|
|
33
33
|
"@ibiz/model-core": "^0.0.26",
|
|
34
34
|
"@types/path-browserify": "^1.0.2",
|
|
35
35
|
"@types/qs": "^6.9.10",
|
|
@@ -59,5 +59,5 @@
|
|
|
59
59
|
"qx-util": "^0.4.8",
|
|
60
60
|
"ramda": "^0.29.0"
|
|
61
61
|
},
|
|
62
|
-
"gitHead": "
|
|
62
|
+
"gitHead": "aed61e1dc8d1cf0f56bbed55cfe70d6ea0f5cc58"
|
|
63
63
|
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { IDEGantt } from '@ibiz/model-core';
|
|
2
|
+
import { IGanttController, IGanttEvent, IGanttState } from '../../../interface';
|
|
3
|
+
import { MDControlController } from '../../common';
|
|
4
|
+
import { GanttService } from './gantt.service';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* 甘特图控制器
|
|
8
|
+
*
|
|
9
|
+
* @author zhanghengfeng
|
|
10
|
+
* @date 2023-12-08 15:12:54
|
|
11
|
+
* @export
|
|
12
|
+
* @class GanttController
|
|
13
|
+
* @extends {MDControlController<IDEGantt, IGanttState, IGanttEvent>}
|
|
14
|
+
* @implements {IGanttController}
|
|
15
|
+
*/
|
|
16
|
+
export class GanttController
|
|
17
|
+
extends MDControlController<IDEGantt, IGanttState, IGanttEvent>
|
|
18
|
+
implements IGanttController
|
|
19
|
+
{
|
|
20
|
+
declare service: GanttService;
|
|
21
|
+
|
|
22
|
+
protected async onCreated(): Promise<void> {
|
|
23
|
+
await super.onCreated();
|
|
24
|
+
this.service = new GanttService(this.model);
|
|
25
|
+
await this.service.init(this.context);
|
|
26
|
+
}
|
|
27
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { IDEGantt } from '@ibiz/model-core';
|
|
2
|
+
import { MDControlService } from '../../../service';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* 甘特图服务
|
|
6
|
+
*
|
|
7
|
+
* @author zhanghengfeng
|
|
8
|
+
* @date 2023-12-08 15:12:34
|
|
9
|
+
* @export
|
|
10
|
+
* @class GanttService
|
|
11
|
+
* @extends {MDControlService<IDEGantt>}
|
|
12
|
+
*/
|
|
13
|
+
export class GanttService extends MDControlService<IDEGantt> {}
|
|
@@ -50,7 +50,7 @@ export class UserReportPanelGenerator extends ReportPanelBaseGenerator {
|
|
|
50
50
|
},
|
|
51
51
|
],
|
|
52
52
|
nodeDataHook:
|
|
53
|
-
"{{ data.forEach(node => { const type = node.data.source_lables || node.data.target_lables; Object.assign(node, { label: node.data.name, size: 66, style: { fill: node.color },donutAttrs: { prop1: 10000, prop2: 10 },donutColorMap: { prop1: node.color, prop2: node.color },icon: {show: true,img: type === 'NEO4J_ZT' ? '
|
|
53
|
+
"{{ data.forEach(node => { const type = node.data.source_lables || node.data.target_lables; Object.assign(node, { label: node.data.name, size: 66, style: { fill: node.color },donutAttrs: { prop1: 10000, prop2: 10 },donutColorMap: { prop1: node.color, prop2: node.color },icon: {show: true,img: type === 'NEO4J_ZT' ? resource.dir('/assets/images/user-avatar.png') : resource.dir('/assets/images/phone.png'),width: 40,height: 40}})})}}",
|
|
54
54
|
edgeDataHook:
|
|
55
55
|
'{{ data.forEach(edge => {Object.assign(edge, { label: edge.name })}) }}',
|
|
56
56
|
},
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { IDEGantt } from '@ibiz/model-core';
|
|
2
|
+
import { IGanttEvent } from '../../event';
|
|
3
|
+
import { IGanttState } from '../../state';
|
|
4
|
+
import { IMDControlController } from './i-md-control.controller';
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* 甘特图控制器
|
|
8
|
+
*
|
|
9
|
+
* @author zhanghengfeng
|
|
10
|
+
* @date 2023-12-08 15:12:06
|
|
11
|
+
* @export
|
|
12
|
+
* @interface IGanttController
|
|
13
|
+
* @extends {IMDControlController<T, S, E>}
|
|
14
|
+
* @template T
|
|
15
|
+
* @template S
|
|
16
|
+
* @template E
|
|
17
|
+
*/
|
|
18
|
+
export interface IGanttController<
|
|
19
|
+
T extends IDEGantt = IDEGantt,
|
|
20
|
+
S extends IGanttState = IGanttState,
|
|
21
|
+
E extends IGanttEvent = IGanttEvent,
|
|
22
|
+
> extends IMDControlController<T, S, E> {}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { IMDControlEvent } from './i-md-control.event';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* 甘特图事件
|
|
5
|
+
*
|
|
6
|
+
* @author zhanghengfeng
|
|
7
|
+
* @date 2023-12-08 15:12:56
|
|
8
|
+
* @export
|
|
9
|
+
* @interface IGanttEvent
|
|
10
|
+
* @extends {IMDControlEvent}
|
|
11
|
+
*/
|
|
12
|
+
export interface IGanttEvent extends IMDControlEvent {}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { IMDViewEvent } from './i-md-view.event';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* 甘特图视图事件
|
|
5
|
+
*
|
|
6
|
+
* @author zhanghengfeng
|
|
7
|
+
* @date 2023-12-08 15:12:55
|
|
8
|
+
* @export
|
|
9
|
+
* @interface IGanttViewEvent
|
|
10
|
+
* @extends {IMDViewEvent}
|
|
11
|
+
*/
|
|
12
|
+
export interface IGanttViewEvent extends IMDViewEvent {}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { IMDControlState } from './i-md-control.state';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* 甘特图状态
|
|
5
|
+
*
|
|
6
|
+
* @author zhanghengfeng
|
|
7
|
+
* @date 2023-12-08 15:12:40
|
|
8
|
+
* @export
|
|
9
|
+
* @interface IGanttState
|
|
10
|
+
* @extends {IMDControlState}
|
|
11
|
+
*/
|
|
12
|
+
export interface IGanttState extends IMDControlState {}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { IMDViewState } from './i-md-view.state';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* 甘特图视图UI状态
|
|
5
|
+
*
|
|
6
|
+
* @author zhanghengfeng
|
|
7
|
+
* @date 2023-12-08 15:12:43
|
|
8
|
+
* @export
|
|
9
|
+
* @interface IGanttViewState
|
|
10
|
+
* @extends {IMDViewState}
|
|
11
|
+
*/
|
|
12
|
+
export interface IGanttViewState extends IMDViewState {}
|
package/src/interface/index.ts
CHANGED
|
@@ -9,7 +9,7 @@ export type * from './i-form-detail.provider';
|
|
|
9
9
|
export type * from './i-editor.provider';
|
|
10
10
|
export type * from './i-portlet.provider';
|
|
11
11
|
export type { IAppCounterProvider } from './i-app-counter.provider';
|
|
12
|
-
export type { IUILogicNodeProvider } from './i-ui-
|
|
12
|
+
export type { IUILogicNodeProvider } from './i-ui-logic-node.provider';
|
|
13
13
|
export type { IAsyncActionProvider } from './i-async-action.provider';
|
|
14
14
|
export type { IPlatformProvider } from './i-platform-provider';
|
|
15
15
|
export type {
|
|
@@ -83,6 +83,22 @@ export interface IAppDEService {
|
|
|
83
83
|
params2?: IParams,
|
|
84
84
|
): Promise<IHttpResponse>;
|
|
85
85
|
|
|
86
|
+
/**
|
|
87
|
+
* 获取草稿数据[系统预置](临时数据)
|
|
88
|
+
*
|
|
89
|
+
* @author chitanda
|
|
90
|
+
* @date 2023-11-21 16:11:34
|
|
91
|
+
* @param {IParams} context
|
|
92
|
+
* @param {(IData | IData[])} [params]
|
|
93
|
+
* @param {IParams} [params2]
|
|
94
|
+
* @return {*} {Promise<IHttpResponse>}
|
|
95
|
+
*/
|
|
96
|
+
getDraftTemp(
|
|
97
|
+
context: IParams,
|
|
98
|
+
params?: IData | IData[],
|
|
99
|
+
params2?: IParams,
|
|
100
|
+
): Promise<IHttpResponse>;
|
|
101
|
+
|
|
86
102
|
/**
|
|
87
103
|
* 创建数据[系统预置]
|
|
88
104
|
*
|
|
@@ -99,6 +115,22 @@ export interface IAppDEService {
|
|
|
99
115
|
params2?: IParams,
|
|
100
116
|
): Promise<IHttpResponse>;
|
|
101
117
|
|
|
118
|
+
/**
|
|
119
|
+
* 创建数据[系统预置](临时数据)
|
|
120
|
+
*
|
|
121
|
+
* @author chitanda
|
|
122
|
+
* @date 2023-11-21 16:11:50
|
|
123
|
+
* @param {IParams} context
|
|
124
|
+
* @param {(IData | IData[])} [params]
|
|
125
|
+
* @param {IParams} [params2]
|
|
126
|
+
* @return {*} {Promise<IHttpResponse>}
|
|
127
|
+
*/
|
|
128
|
+
createTemp(
|
|
129
|
+
context: IParams,
|
|
130
|
+
params?: IData | IData[],
|
|
131
|
+
params2?: IParams,
|
|
132
|
+
): Promise<IHttpResponse>;
|
|
133
|
+
|
|
102
134
|
/**
|
|
103
135
|
* 获取数据[系统预置]
|
|
104
136
|
*
|
|
@@ -115,6 +147,22 @@ export interface IAppDEService {
|
|
|
115
147
|
params2?: IParams,
|
|
116
148
|
): Promise<IHttpResponse>;
|
|
117
149
|
|
|
150
|
+
/**
|
|
151
|
+
* 获取数据[系统预置](临时数据)
|
|
152
|
+
*
|
|
153
|
+
* @author chitanda
|
|
154
|
+
* @date 2023-11-21 16:11:00
|
|
155
|
+
* @param {IParams} context
|
|
156
|
+
* @param {(IData | IData[])} [params]
|
|
157
|
+
* @param {IParams} [params2]
|
|
158
|
+
* @return {*} {Promise<IHttpResponse>}
|
|
159
|
+
*/
|
|
160
|
+
getTemp(
|
|
161
|
+
context: IParams,
|
|
162
|
+
params?: IData | IData[],
|
|
163
|
+
params2?: IParams,
|
|
164
|
+
): Promise<IHttpResponse>;
|
|
165
|
+
|
|
118
166
|
/**
|
|
119
167
|
* 更新数据[系统预置]
|
|
120
168
|
*
|
|
@@ -131,6 +179,22 @@ export interface IAppDEService {
|
|
|
131
179
|
params2?: IParams,
|
|
132
180
|
): Promise<IHttpResponse>;
|
|
133
181
|
|
|
182
|
+
/**
|
|
183
|
+
* 更新数据[系统预置](临时数据)
|
|
184
|
+
*
|
|
185
|
+
* @author chitanda
|
|
186
|
+
* @date 2023-11-21 16:11:09
|
|
187
|
+
* @param {IParams} context
|
|
188
|
+
* @param {(IData | IData[])} [params]
|
|
189
|
+
* @param {IParams} [params2]
|
|
190
|
+
* @return {*} {Promise<IHttpResponse>}
|
|
191
|
+
*/
|
|
192
|
+
updateTemp(
|
|
193
|
+
context: IParams,
|
|
194
|
+
params?: IData | IData[],
|
|
195
|
+
params2?: IParams,
|
|
196
|
+
): Promise<IHttpResponse>;
|
|
197
|
+
|
|
134
198
|
/**
|
|
135
199
|
* 删除数据[系统预置]
|
|
136
200
|
*
|
|
@@ -147,6 +211,22 @@ export interface IAppDEService {
|
|
|
147
211
|
params2?: IParams,
|
|
148
212
|
): Promise<IHttpResponse>;
|
|
149
213
|
|
|
214
|
+
/**
|
|
215
|
+
* 删除数据[系统预置](临时数据)
|
|
216
|
+
*
|
|
217
|
+
* @author chitanda
|
|
218
|
+
* @date 2023-11-21 16:11:12
|
|
219
|
+
* @param {IParams} context
|
|
220
|
+
* @param {(IData | IData[])} [params]
|
|
221
|
+
* @param {IParams} [params2]
|
|
222
|
+
* @return {*} {Promise<IHttpResponse>}
|
|
223
|
+
*/
|
|
224
|
+
removeTemp(
|
|
225
|
+
context: IParams,
|
|
226
|
+
params?: IData | IData[],
|
|
227
|
+
params2?: IParams,
|
|
228
|
+
): Promise<IHttpResponse>;
|
|
229
|
+
|
|
150
230
|
/**
|
|
151
231
|
* 获取默认数据集[系统预置]
|
|
152
232
|
*
|
|
@@ -163,6 +243,22 @@ export interface IAppDEService {
|
|
|
163
243
|
params2?: IParams,
|
|
164
244
|
): Promise<IHttpResponse>;
|
|
165
245
|
|
|
246
|
+
/**
|
|
247
|
+
* 获取默认数据集[系统预置](临时数据)
|
|
248
|
+
*
|
|
249
|
+
* @author chitanda
|
|
250
|
+
* @date 2023-11-21 16:11:06
|
|
251
|
+
* @param {IParams} context
|
|
252
|
+
* @param {(IData | IData[])} [params]
|
|
253
|
+
* @param {IParams} [params2]
|
|
254
|
+
* @return {*} {Promise<IHttpResponse>}
|
|
255
|
+
*/
|
|
256
|
+
fetchTempDefault(
|
|
257
|
+
context: IParams,
|
|
258
|
+
params?: IData | IData[],
|
|
259
|
+
params2?: IParams,
|
|
260
|
+
): Promise<IHttpResponse>;
|
|
261
|
+
|
|
166
262
|
/**
|
|
167
263
|
* 触发实体服务方法 ac 模式
|
|
168
264
|
*
|
|
@@ -188,6 +188,54 @@ export class DEService implements IAppDEService {
|
|
|
188
188
|
return this.exec('FetchDefault', context, params, params2);
|
|
189
189
|
}
|
|
190
190
|
|
|
191
|
+
getDraftTemp(
|
|
192
|
+
context: IParams,
|
|
193
|
+
params?: IData | IData[],
|
|
194
|
+
params2?: IParams,
|
|
195
|
+
): Promise<IHttpResponse<IData>> {
|
|
196
|
+
return this.exec('GetDraftTemp', context, params, params2);
|
|
197
|
+
}
|
|
198
|
+
|
|
199
|
+
createTemp(
|
|
200
|
+
context: IParams,
|
|
201
|
+
params?: IData | IData[],
|
|
202
|
+
params2?: IParams,
|
|
203
|
+
): Promise<IHttpResponse<IData>> {
|
|
204
|
+
return this.exec('CreateTemp', context, params, params2);
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
getTemp(
|
|
208
|
+
context: IParams,
|
|
209
|
+
params?: IData | IData[],
|
|
210
|
+
params2?: IParams,
|
|
211
|
+
): Promise<IHttpResponse<IData>> {
|
|
212
|
+
return this.exec('GetTemp', context, params, params2);
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
updateTemp(
|
|
216
|
+
context: IParams,
|
|
217
|
+
params?: IData | IData[],
|
|
218
|
+
params2?: IParams,
|
|
219
|
+
): Promise<IHttpResponse<IData>> {
|
|
220
|
+
return this.exec('UpdateTemp', context, params, params2);
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
removeTemp(
|
|
224
|
+
context: IParams,
|
|
225
|
+
params?: IData | IData[],
|
|
226
|
+
params2?: IParams,
|
|
227
|
+
): Promise<IHttpResponse<IData>> {
|
|
228
|
+
return this.exec('RemoveTemp', context, params, params2);
|
|
229
|
+
}
|
|
230
|
+
|
|
231
|
+
fetchTempDefault(
|
|
232
|
+
context: IParams,
|
|
233
|
+
params?: IData | IData[],
|
|
234
|
+
params2?: IParams,
|
|
235
|
+
): Promise<IHttpResponse<IData>> {
|
|
236
|
+
return this.exec('FetchTempDefault', context, params, params2);
|
|
237
|
+
}
|
|
238
|
+
|
|
191
239
|
/**
|
|
192
240
|
* 执行服务方法 ac 模式
|
|
193
241
|
*
|
|
@@ -35,7 +35,7 @@ export class FetchMethod extends Method {
|
|
|
35
35
|
params2?: IParams,
|
|
36
36
|
): Promise<HttpResponse<IDataEntity[]>> {
|
|
37
37
|
// 过滤参数,必须是对象
|
|
38
|
-
const searchParams = params && isArray(params) ? params : params2 || {};
|
|
38
|
+
const searchParams = params && !isArray(params) ? params : params2 || {};
|
|
39
39
|
|
|
40
40
|
if (this.isLocalMode) {
|
|
41
41
|
// 临时数据
|
|
@@ -180,7 +180,7 @@ export class FetchMethod extends Method {
|
|
|
180
180
|
list = list.filter(obj => cond.test(obj, filter));
|
|
181
181
|
}
|
|
182
182
|
} else {
|
|
183
|
-
list = await this.selectLocal(filter.context);
|
|
183
|
+
list = await this.selectLocal(filter.context, filter.data);
|
|
184
184
|
if (list.length > 0) {
|
|
185
185
|
if (filter.query && filter.query !== '') {
|
|
186
186
|
if (queryParamKeys) {
|
|
@@ -4,6 +4,7 @@ import { isNil } from 'ramda';
|
|
|
4
4
|
import { Application } from '../../../application';
|
|
5
5
|
import { CodeListItem } from '../../../interface';
|
|
6
6
|
import { convertNavData, ScriptFactory } from '../../../utils';
|
|
7
|
+
import { fieldValueToBoolean } from '../../utils';
|
|
7
8
|
|
|
8
9
|
/**
|
|
9
10
|
* 实际缓存对象
|
|
@@ -174,7 +175,7 @@ export class DynamicCodeListCache {
|
|
|
174
175
|
}
|
|
175
176
|
// 禁止选择属性
|
|
176
177
|
if (disableAppDEFieldId) {
|
|
177
|
-
result.disableSelect = data[disableAppDEFieldId];
|
|
178
|
+
result.disableSelect = fieldValueToBoolean(data[disableAppDEFieldId]);
|
|
178
179
|
}
|
|
179
180
|
// 数据属性
|
|
180
181
|
if (dataAppDEFieldId && data[dataAppDEFieldId]) {
|
|
@@ -5,3 +5,4 @@ export { DynamicCodeListCache } from './dynamic-code-list/dynamic-code-list';
|
|
|
5
5
|
export { DECache } from './de-cache/de-cache';
|
|
6
6
|
export { getMatchResPath, calcResPath } from './res-path/res-path';
|
|
7
7
|
export { SearchFilter } from './search-filter/search-filter';
|
|
8
|
+
export { fieldValueToBoolean } from './util/util';
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* 把实体属性的值转换成布尔值
|
|
3
|
+
* 以下值会转成true,其他都为false
|
|
4
|
+
* - 字符串:'1','true',
|
|
5
|
+
* - 数字:1
|
|
6
|
+
* - 布尔值:true
|
|
7
|
+
* @author lxm
|
|
8
|
+
* @date 2023-12-07 05:07:28
|
|
9
|
+
* @export
|
|
10
|
+
* @param {unknown} value
|
|
11
|
+
* @return {*} {boolean}
|
|
12
|
+
*/
|
|
13
|
+
export function fieldValueToBoolean(value: unknown): boolean {
|
|
14
|
+
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
|
15
|
+
return [1, '1', true, 'true'].includes(value as any);
|
|
16
|
+
}
|
|
@@ -3,6 +3,7 @@ import { IIcon, ITreeNodeData } from '../../../interface';
|
|
|
3
3
|
import { calcDeCodeNameById } from '../../../model';
|
|
4
4
|
import { ScriptFactory } from '../../../utils';
|
|
5
5
|
import { TreeNodeData } from './tree-node-data';
|
|
6
|
+
import { fieldValueToBoolean } from '../../utils';
|
|
6
7
|
|
|
7
8
|
/**
|
|
8
9
|
* 实体数据集树节点数据
|
|
@@ -62,8 +63,7 @@ export class TreeDataSetNodeData extends TreeNodeData implements ITreeNodeData {
|
|
|
62
63
|
|
|
63
64
|
// 识别叶子节点标识属性,根据后台数据赋值leaf
|
|
64
65
|
if (model.leafFlagAppDEFieldId) {
|
|
65
|
-
|
|
66
|
-
this.leaf = [1, '1', true, 'true'].includes(value);
|
|
66
|
+
this.leaf = fieldValueToBoolean(data[model.leafFlagAppDEFieldId]);
|
|
67
67
|
}
|
|
68
68
|
}
|
|
69
69
|
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/interface/ui-login/index.ts"],"names":[],"mappings":"AAAA,YAAY,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC"}
|
|
File without changes
|
/package/out/interface/{ui-login/i-ui-logic-context.js → controller/event/control/i-gantt.event.js}
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|