@ibiz-template/vue3-components 0.7.41-alpha.19 → 0.7.41-alpha.20
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-hzGAQk1t.js +11 -0
- package/dist/index.min.css +1 -1
- package/dist/index.system.min.js +1 -1
- package/dist/map-chart-ICyEpflN.js +1 -0
- package/dist/map-chart-user-7zfETImI.js +1 -0
- package/dist/{wang-editor-exnzt_I1.js → wang-editor-qbGW8Rzj.js} +1 -1
- package/dist/{xlsx-util-fuTLwrKA.js → xlsx-util-mN5WSU7v.js} +1 -1
- package/es/common/control-navigation/control-navigation.mjs +8 -9
- package/es/common/control-navigation/provider/calendar-navigation.provider.d.ts +6 -1
- package/es/common/control-navigation/provider/calendar-navigation.provider.mjs +21 -10
- package/es/common/control-navigation/provider/map-navigation.provider.d.ts +1 -1
- package/es/common/control-navigation/provider/map-navigation.provider.mjs +32 -15
- package/es/common/control-navigation/provider/navigation-base.provider.d.ts +13 -0
- package/es/common/control-navigation/provider/navigation-base.provider.mjs +25 -10
- package/es/common/control-navigation/provider/tree-navigation.provider.d.ts +2 -2
- package/es/common/control-navigation/provider/tree-navigation.provider.mjs +5 -8
- package/es/common/custom-filter-condition/custom-filter-condition.d.ts +3 -0
- package/es/common/map-chart/map-chart.d.ts +9 -1
- package/es/common/map-chart/map-chart.mjs +6 -4
- package/es/common/map-chart/map-manager.d.ts +2 -1
- package/es/common/map-chart/map-manager.mjs +3 -4
- package/es/common/map-chart-user/map-chart-user.css +1 -1
- package/es/common/map-chart-user/map-chart-user.mjs +2 -1
- package/es/common/map-chart-user/map-user-manager.mjs +1 -1
- package/es/common/view-message/view-message.d.ts +3 -0
- package/es/control/calendar/calendar.css +1 -1
- package/es/control/calendar/calendar.d.ts +1 -1
- package/es/control/calendar/calendar.mjs +19 -15
- package/es/control/grid/grid/grid-control.util.mjs +29 -29
- package/es/control/grid/grid/grid.mjs +20 -17
- package/es/control/map/map.mjs +24 -22
- package/es/control/tree/tree.mjs +2 -14
- package/es/control/tree-grid/index.d.ts +10 -10
- package/es/control/tree-grid/tree-grid.d.ts +11 -11
- package/es/control/tree-grid/tree-grid.mjs +120 -67
- package/es/editor/data-picker/ibiz-mpicker/ibiz-mpicker.css +1 -1
- package/es/editor/data-picker/ibiz-mpicker/ibiz-mpicker.d.ts +15 -12
- package/es/editor/data-picker/ibiz-mpicker/ibiz-mpicker.mjs +95 -61
- package/es/editor/data-picker/ibiz-picker/ibiz-picker.css +1 -1
- package/es/editor/data-picker/ibiz-picker/ibiz-picker.d.ts +12 -11
- package/es/editor/data-picker/ibiz-picker/ibiz-picker.mjs +36 -43
- package/es/editor/data-picker/ibiz-picker-embed-view/ibiz-picker-embed-view.d.ts +4 -4
- package/es/editor/data-picker/ibiz-picker-embed-view/ibiz-picker-embed-view.mjs +9 -9
- package/es/editor/data-picker/ibiz-picker-select-view/ibiz-picker-select-view.d.ts +27 -23
- package/es/editor/data-picker/ibiz-picker-select-view/ibiz-picker-select-view.mjs +53 -42
- package/es/editor/data-picker/picker-editor.controller.d.ts +2 -2
- package/es/editor/data-picker/picker-editor.controller.mjs +6 -6
- package/es/editor/date-range-select/date-range-select-picker/date-range-select.d.ts +4 -4
- package/es/locale/en/index.d.ts +1 -0
- package/es/locale/zh-CN/index.d.ts +1 -0
- package/es/panel-component/app-extend-menu/bottom-side-menu/bottom-side-menu.d.ts +1 -1
- package/es/panel-component/app-extend-menu/extend-menu-base/extend-button-menu/extend-button-menu.d.ts +12 -0
- package/es/panel-component/app-extend-menu/extend-menu-base/extend-standard-menu/extend-standard-menu.d.ts +6 -0
- package/es/panel-component/app-extend-menu/left-side-menu/left-side-menu.d.ts +1 -1
- package/es/panel-component/app-extend-menu/right-side-menu/right-side-menu.d.ts +1 -1
- package/es/panel-component/app-extend-menu/top-side-menu/top-side-menu.d.ts +1 -1
- package/es/panel-component/app-switch/app-switch.d.ts +1 -1
- package/es/panel-component/auth-sso/auth-sso.css +1 -1
- package/es/panel-component/auth-sso/auth-sso.d.ts +8 -2
- package/es/panel-component/auth-sso/auth-sso.mjs +78 -6
- package/es/panel-component/auth-sso/index.d.ts +7 -1
- package/es/panel-component/coop-pos/coop-pos.d.ts +1 -1
- package/es/panel-component/global-search/global-search.d.ts +1 -1
- package/es/panel-component/index-actions/index-actions.d.ts +1 -0
- package/es/panel-component/nav-breadcrumb/nav-breadcrumb.d.ts +2 -2
- package/es/panel-component/nav-pos-index/nav-pos-index.controller.d.ts +1 -1
- package/es/panel-component/nav-pos-index/nav-pos-index.controller.mjs +1 -1
- package/es/panel-component/panel-app-title/panel-app-title.controller.d.ts +1 -1
- package/es/panel-component/panel-app-title/panel-app-title.controller.mjs +1 -1
- package/es/panel-component/user-action/user-action.d.ts +1 -1
- package/es/panel-component/view-message/view-message.d.ts +1 -1
- package/es/panel-component/view-msg-pos/view-msg-pos.d.ts +1 -1
- package/es/view-engine/mpickup-view-engine.d.ts +4 -6
- package/es/view-engine/mpickup-view-engine.mjs +12 -14
- package/es/view-engine/pickup-data-view.engine.d.ts +12 -0
- package/es/view-engine/pickup-data-view.engine.mjs +31 -0
- package/es/view-engine/pickup-grid-view.engine.d.ts +12 -0
- package/es/view-engine/pickup-grid-view.engine.mjs +31 -0
- package/es/view-engine/pickup-tree-view.engine.d.ts +6 -16
- package/es/view-engine/pickup-tree-view.engine.mjs +15 -60
- package/es/view-engine/pickup-view.engine.d.ts +6 -0
- package/es/view-engine/pickup-view.engine.mjs +11 -0
- package/es/web-app/App.mjs +17 -1
- package/es/web-app/guard/auth-guard/auth-guard.mjs +1 -0
- package/es/web-app/util/unauthorized-handler/unauthorized-handler.d.ts +7 -0
- package/es/web-app/util/unauthorized-handler/unauthorized-handler.mjs +22 -1
- package/lib/common/control-navigation/control-navigation.cjs +8 -9
- package/lib/common/control-navigation/provider/calendar-navigation.provider.cjs +21 -10
- package/lib/common/control-navigation/provider/map-navigation.provider.cjs +32 -15
- package/lib/common/control-navigation/provider/navigation-base.provider.cjs +25 -10
- package/lib/common/control-navigation/provider/tree-navigation.provider.cjs +5 -8
- package/lib/common/map-chart/map-chart.cjs +6 -4
- package/lib/common/map-chart/map-manager.cjs +3 -4
- package/lib/common/map-chart-user/map-chart-user.cjs +1 -0
- package/lib/common/map-chart-user/map-chart-user.css +1 -1
- package/lib/common/map-chart-user/map-user-manager.cjs +1 -1
- package/lib/control/calendar/calendar.cjs +19 -15
- package/lib/control/calendar/calendar.css +1 -1
- package/lib/control/grid/grid/grid-control.util.cjs +29 -29
- package/lib/control/grid/grid/grid.cjs +20 -17
- package/lib/control/map/map.cjs +24 -22
- package/lib/control/tree/tree.cjs +2 -14
- package/lib/control/tree-grid/tree-grid.cjs +119 -66
- package/lib/editor/data-picker/ibiz-mpicker/ibiz-mpicker.cjs +94 -60
- package/lib/editor/data-picker/ibiz-mpicker/ibiz-mpicker.css +1 -1
- package/lib/editor/data-picker/ibiz-picker/ibiz-picker.cjs +36 -43
- package/lib/editor/data-picker/ibiz-picker/ibiz-picker.css +1 -1
- package/lib/editor/data-picker/ibiz-picker-embed-view/ibiz-picker-embed-view.cjs +9 -9
- package/lib/editor/data-picker/ibiz-picker-select-view/ibiz-picker-select-view.cjs +52 -41
- package/lib/editor/data-picker/picker-editor.controller.cjs +6 -6
- package/lib/panel-component/auth-sso/auth-sso.cjs +77 -5
- package/lib/panel-component/auth-sso/auth-sso.css +1 -1
- package/lib/panel-component/nav-pos-index/nav-pos-index.controller.cjs +1 -1
- package/lib/panel-component/panel-app-title/panel-app-title.controller.cjs +1 -1
- package/lib/view-engine/mpickup-view-engine.cjs +12 -14
- package/lib/view-engine/pickup-data-view.engine.cjs +31 -0
- package/lib/view-engine/pickup-grid-view.engine.cjs +31 -0
- package/lib/view-engine/pickup-tree-view.engine.cjs +15 -60
- package/lib/view-engine/pickup-view.engine.cjs +11 -0
- package/lib/web-app/App.cjs +16 -0
- package/lib/web-app/guard/auth-guard/auth-guard.cjs +1 -0
- package/lib/web-app/util/unauthorized-handler/unauthorized-handler.cjs +22 -1
- package/package.json +6 -6
- package/dist/index-BoV5htv9.js +0 -11
- package/dist/map-chart-3dojS1dZ.js +0 -1
- package/dist/map-chart-user-NYROZ-6g.js +0 -1
|
@@ -19,7 +19,7 @@ export declare class PanelAppTitleController extends PanelItemController<IPanelR
|
|
|
19
19
|
*/
|
|
20
20
|
panel: ViewLayoutPanelController;
|
|
21
21
|
/**
|
|
22
|
-
* @description
|
|
22
|
+
* @description 分隔符,将标题以`\|`符分割,分隔符前面为caption,后面为caption2
|
|
23
23
|
* @exposedoc
|
|
24
24
|
* @return {*}
|
|
25
25
|
* @memberof PanelAppTitleController
|
|
@@ -12,7 +12,7 @@ class PanelAppTitleController extends PanelItemController {
|
|
|
12
12
|
constructor() {
|
|
13
13
|
super(...arguments);
|
|
14
14
|
/**
|
|
15
|
-
* @description
|
|
15
|
+
* @description 分隔符,将标题以`\|`符分割,分隔符前面为caption,后面为caption2
|
|
16
16
|
* @exposedoc
|
|
17
17
|
* @return {*}
|
|
18
18
|
* @memberof PanelAppTitleController
|
|
@@ -6,7 +6,7 @@ import './user-action.scss';
|
|
|
6
6
|
* 用户操作
|
|
7
7
|
* @primary
|
|
8
8
|
* @description 首页中用户操作行为按钮,需在菜单上配置标识为设置(setting)、帮助(helper)、自定义(custom)的三种隐藏菜单项,点击按钮将会执行对应的菜单项应用功能。
|
|
9
|
-
* @panelitemparams {name:noprivmode,parameterType:PARENT|SELF,defaultvalue:PARENT,description:无权限模式,为PARENT时会通过父容器进行显示隐藏}
|
|
9
|
+
* @panelitemparams {name:noprivmode,parameterType:'PARENT' | 'SELF',defaultvalue:'PARENT',description:无权限模式,为PARENT时会通过父容器进行显示隐藏}
|
|
10
10
|
* @export
|
|
11
11
|
* @class UserAction
|
|
12
12
|
*/
|
|
@@ -6,7 +6,7 @@ import { ViewMsgPosController } from './view-msg-pos.controller';
|
|
|
6
6
|
* @primary
|
|
7
7
|
* @description 使用el-alert组件,读取视图状态的viewMessages数据,用于在界面布局中给视图消息提供一个显示位置。
|
|
8
8
|
* @panelitemparams {name:scroll,parameterType:boolean,defaultvalue:false,description:是否滚动展示}
|
|
9
|
-
* @panelitemparams {name:position,parameterType:TOP | BOTTOM | BODY,defaultvalue:BODY,description:指定展示哪个位置的视图消息,TOP代表视图上方,BOTTOM代表视图下方,BODY代表视图内容区}
|
|
9
|
+
* @panelitemparams {name:position,parameterType:'TOP' | 'BOTTOM' | 'BODY',defaultvalue:'BODY',description:指定展示哪个位置的视图消息,TOP代表视图上方,BOTTOM代表视图下方,BODY代表视图内容区}
|
|
10
10
|
*/
|
|
11
11
|
export declare const ViewMsgPos: import("vue").DefineComponent<{
|
|
12
12
|
/**
|
|
@@ -48,7 +48,7 @@ export declare class MPickupViewEngine extends PickupViewEngine {
|
|
|
48
48
|
* @param {*} data
|
|
49
49
|
* @memberof PickupViewEngine
|
|
50
50
|
*/
|
|
51
|
-
protected pickupViewPanelDataActive(data: IData[]): void
|
|
51
|
+
protected pickupViewPanelDataActive(data: IData[]): Promise<void>;
|
|
52
52
|
/**
|
|
53
53
|
* 列表激活
|
|
54
54
|
*
|
|
@@ -67,14 +67,12 @@ export declare class MPickupViewEngine extends PickupViewEngine {
|
|
|
67
67
|
*/
|
|
68
68
|
addSelection(): Promise<void>;
|
|
69
69
|
/**
|
|
70
|
-
* 处理添加简单列表数据
|
|
71
|
-
*
|
|
72
|
-
* @author zk
|
|
73
|
-
* @date 2023-05-26 02:05:41
|
|
70
|
+
* @description 处理添加简单列表数据
|
|
71
|
+
* @protected
|
|
74
72
|
* @param {IData[]} data
|
|
75
73
|
* @memberof MPickupViewEngine
|
|
76
74
|
*/
|
|
77
|
-
protected handlePushSimpleListItems(data: IData[]): void
|
|
75
|
+
protected handlePushSimpleListItems(data: IData[]): Promise<void>;
|
|
78
76
|
/**
|
|
79
77
|
* 去重数组
|
|
80
78
|
*
|
|
@@ -94,8 +94,8 @@ class MPickupViewEngine extends PickupViewEngine {
|
|
|
94
94
|
* @param {*} data
|
|
95
95
|
* @memberof PickupViewEngine
|
|
96
96
|
*/
|
|
97
|
-
pickupViewPanelDataActive(data) {
|
|
98
|
-
this.handlePushSimpleListItems(data);
|
|
97
|
+
async pickupViewPanelDataActive(data) {
|
|
98
|
+
await this.handlePushSimpleListItems(data);
|
|
99
99
|
}
|
|
100
100
|
/**
|
|
101
101
|
* 列表激活
|
|
@@ -124,20 +124,19 @@ class MPickupViewEngine extends PickupViewEngine {
|
|
|
124
124
|
*/
|
|
125
125
|
async addSelection() {
|
|
126
126
|
const selectItem = await this.pickupViewPanel.getSelectedData();
|
|
127
|
-
this.handlePushSimpleListItems(selectItem);
|
|
127
|
+
await this.handlePushSimpleListItems(selectItem);
|
|
128
128
|
}
|
|
129
129
|
/**
|
|
130
|
-
* 处理添加简单列表数据
|
|
131
|
-
*
|
|
132
|
-
* @author zk
|
|
133
|
-
* @date 2023-05-26 02:05:41
|
|
130
|
+
* @description 处理添加简单列表数据
|
|
131
|
+
* @protected
|
|
134
132
|
* @param {IData[]} data
|
|
135
133
|
* @memberof MPickupViewEngine
|
|
136
134
|
*/
|
|
137
|
-
handlePushSimpleListItems(data) {
|
|
138
|
-
const
|
|
139
|
-
const
|
|
140
|
-
|
|
135
|
+
async handlePushSimpleListItems(data) {
|
|
136
|
+
const items = await this.pickupViewPanel.getAllData();
|
|
137
|
+
const selectItems = this.simpleList.getAllData().filter((selected) => !items.some((item) => item.srfkey === selected.srfkey));
|
|
138
|
+
selectItems.push(...data);
|
|
139
|
+
const uniqueItems = this.handleUniqueItems(selectItems);
|
|
141
140
|
this.setSelectedData(uniqueItems);
|
|
142
141
|
}
|
|
143
142
|
/**
|
|
@@ -164,7 +163,7 @@ class MPickupViewEngine extends PickupViewEngine {
|
|
|
164
163
|
*/
|
|
165
164
|
async addAll() {
|
|
166
165
|
const allItems = await this.pickupViewPanel.getAllData();
|
|
167
|
-
this.handlePushSimpleListItems(allItems);
|
|
166
|
+
await this.handlePushSimpleListItems(allItems);
|
|
168
167
|
}
|
|
169
168
|
/**
|
|
170
169
|
* 删除所有
|
|
@@ -190,9 +189,8 @@ class MPickupViewEngine extends PickupViewEngine {
|
|
|
190
189
|
const index = items.findIndex(
|
|
191
190
|
(item) => _item.srfkey === item.srfkey
|
|
192
191
|
);
|
|
193
|
-
if (index !== -1)
|
|
192
|
+
if (index !== -1)
|
|
194
193
|
items.splice(index, 1);
|
|
195
|
-
}
|
|
196
194
|
});
|
|
197
195
|
this.setSelectedData(items);
|
|
198
196
|
}
|
|
@@ -3,6 +3,12 @@ import { IAppDEDataView } from '@ibiz/model-core';
|
|
|
3
3
|
import { DataViewEngine } from './data-view.engine';
|
|
4
4
|
export declare class PickupDataViewEngine extends DataViewEngine {
|
|
5
5
|
protected view: ViewController<IAppDEDataView, IPickupDataViewState, IPickupDataViewEvent>;
|
|
6
|
+
/**
|
|
7
|
+
* @description 选中数据
|
|
8
|
+
* @type {IData[]}
|
|
9
|
+
* @memberof PickupDataViewEngine
|
|
10
|
+
*/
|
|
11
|
+
selectData: IData[];
|
|
6
12
|
/**
|
|
7
13
|
* 表格控制器
|
|
8
14
|
*
|
|
@@ -13,6 +19,12 @@ export declare class PickupDataViewEngine extends DataViewEngine {
|
|
|
13
19
|
*/
|
|
14
20
|
get dataview(): IDataViewControlController;
|
|
15
21
|
onCreated(): Promise<void>;
|
|
22
|
+
/**
|
|
23
|
+
* @description 初始化选中数据
|
|
24
|
+
* @protected
|
|
25
|
+
* @memberof PickupDataViewEngine
|
|
26
|
+
*/
|
|
27
|
+
protected initSelectData(): void;
|
|
16
28
|
onMounted(): Promise<void>;
|
|
17
29
|
call(key: keyof IApiPickupDataViewCall, args: any): Promise<IData | null | undefined>;
|
|
18
30
|
}
|
|
@@ -2,7 +2,22 @@ import { ViewCallTag } from '@ibiz-template/runtime';
|
|
|
2
2
|
import { DataViewEngine } from './data-view.engine.mjs';
|
|
3
3
|
|
|
4
4
|
"use strict";
|
|
5
|
+
var __defProp = Object.defineProperty;
|
|
6
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
7
|
+
var __publicField = (obj, key, value) => {
|
|
8
|
+
__defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
9
|
+
return value;
|
|
10
|
+
};
|
|
5
11
|
class PickupDataViewEngine extends DataViewEngine {
|
|
12
|
+
constructor() {
|
|
13
|
+
super(...arguments);
|
|
14
|
+
/**
|
|
15
|
+
* @description 选中数据
|
|
16
|
+
* @type {IData[]}
|
|
17
|
+
* @memberof PickupDataViewEngine
|
|
18
|
+
*/
|
|
19
|
+
__publicField(this, "selectData", []);
|
|
20
|
+
}
|
|
6
21
|
/**
|
|
7
22
|
* 表格控制器
|
|
8
23
|
*
|
|
@@ -17,6 +32,21 @@ class PickupDataViewEngine extends DataViewEngine {
|
|
|
17
32
|
async onCreated() {
|
|
18
33
|
super.onCreated();
|
|
19
34
|
this.view.slotProps.dataview.singleSelect = this.view.state.singleSelect;
|
|
35
|
+
this.initSelectData();
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* @description 初始化选中数据
|
|
39
|
+
* @protected
|
|
40
|
+
* @memberof PickupDataViewEngine
|
|
41
|
+
*/
|
|
42
|
+
initSelectData() {
|
|
43
|
+
if (this.view.params.selecteddata) {
|
|
44
|
+
this.selectData = JSON.parse(this.view.params.selecteddata);
|
|
45
|
+
delete this.view.params.selecteddata;
|
|
46
|
+
}
|
|
47
|
+
if (this.view.state.selectedData) {
|
|
48
|
+
this.selectData = [...this.view.state.selectedData];
|
|
49
|
+
}
|
|
20
50
|
}
|
|
21
51
|
async onMounted() {
|
|
22
52
|
await super.onMounted();
|
|
@@ -26,6 +56,7 @@ class PickupDataViewEngine extends DataViewEngine {
|
|
|
26
56
|
this.xdataControl.evt.on("onActive", async (event) => {
|
|
27
57
|
this.view.evt.emit("onDataActive", { ...event });
|
|
28
58
|
});
|
|
59
|
+
this.setSelectedData(this.selectData);
|
|
29
60
|
}
|
|
30
61
|
async call(key, args) {
|
|
31
62
|
if (key === ViewCallTag.GET_ALL_DATA) {
|
|
@@ -3,6 +3,12 @@ import { IAppDEGridView } from '@ibiz/model-core';
|
|
|
3
3
|
import { GridViewEngine } from './grid-view.engine';
|
|
4
4
|
export declare class PickupGridViewEngine extends GridViewEngine {
|
|
5
5
|
protected view: ViewController<IAppDEGridView, IPickupGridViewState, IPickupGridViewEvent>;
|
|
6
|
+
/**
|
|
7
|
+
* @description 选中数据
|
|
8
|
+
* @type {IData[]}
|
|
9
|
+
* @memberof PickupGridViewEngine
|
|
10
|
+
*/
|
|
11
|
+
selectData: IData[];
|
|
6
12
|
/**
|
|
7
13
|
* 表格控制器
|
|
8
14
|
*
|
|
@@ -13,6 +19,12 @@ export declare class PickupGridViewEngine extends GridViewEngine {
|
|
|
13
19
|
*/
|
|
14
20
|
get grid(): IGridController;
|
|
15
21
|
onCreated(): Promise<void>;
|
|
22
|
+
/**
|
|
23
|
+
* @description 初始化选中数据
|
|
24
|
+
* @protected
|
|
25
|
+
* @memberof PickupGridViewEngine
|
|
26
|
+
*/
|
|
27
|
+
protected initSelectData(): void;
|
|
16
28
|
onMounted(): Promise<void>;
|
|
17
29
|
call(key: keyof IApiPickupGridViewCall, args: any): Promise<IData | null | undefined>;
|
|
18
30
|
}
|
|
@@ -2,7 +2,22 @@ import { ViewCallTag } from '@ibiz-template/runtime';
|
|
|
2
2
|
import { GridViewEngine } from './grid-view.engine.mjs';
|
|
3
3
|
|
|
4
4
|
"use strict";
|
|
5
|
+
var __defProp = Object.defineProperty;
|
|
6
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
7
|
+
var __publicField = (obj, key, value) => {
|
|
8
|
+
__defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
9
|
+
return value;
|
|
10
|
+
};
|
|
5
11
|
class PickupGridViewEngine extends GridViewEngine {
|
|
12
|
+
constructor() {
|
|
13
|
+
super(...arguments);
|
|
14
|
+
/**
|
|
15
|
+
* @description 选中数据
|
|
16
|
+
* @type {IData[]}
|
|
17
|
+
* @memberof PickupGridViewEngine
|
|
18
|
+
*/
|
|
19
|
+
__publicField(this, "selectData", []);
|
|
20
|
+
}
|
|
6
21
|
/**
|
|
7
22
|
* 表格控制器
|
|
8
23
|
*
|
|
@@ -22,6 +37,21 @@ class PickupGridViewEngine extends GridViewEngine {
|
|
|
22
37
|
}
|
|
23
38
|
this.view.slotProps.grid.singleSelect = this.view.state.singleSelect;
|
|
24
39
|
this.view.slotProps.grid.mdctrlActiveMode = model.gridRowActiveMode;
|
|
40
|
+
this.initSelectData();
|
|
41
|
+
}
|
|
42
|
+
/**
|
|
43
|
+
* @description 初始化选中数据
|
|
44
|
+
* @protected
|
|
45
|
+
* @memberof PickupGridViewEngine
|
|
46
|
+
*/
|
|
47
|
+
initSelectData() {
|
|
48
|
+
if (this.view.params.selecteddata) {
|
|
49
|
+
this.selectData = JSON.parse(this.view.params.selecteddata);
|
|
50
|
+
delete this.view.params.selecteddata;
|
|
51
|
+
}
|
|
52
|
+
if (this.view.state.selectedData) {
|
|
53
|
+
this.selectData = [...this.view.state.selectedData];
|
|
54
|
+
}
|
|
25
55
|
}
|
|
26
56
|
async onMounted() {
|
|
27
57
|
await super.onMounted();
|
|
@@ -31,6 +61,7 @@ class PickupGridViewEngine extends GridViewEngine {
|
|
|
31
61
|
this.xdataControl.evt.on("onActive", async (event) => {
|
|
32
62
|
this.view.evt.emit("onDataActive", { ...event });
|
|
33
63
|
});
|
|
64
|
+
this.setSelectedData(this.selectData);
|
|
34
65
|
}
|
|
35
66
|
async call(key, args) {
|
|
36
67
|
if (key === ViewCallTag.GET_ALL_DATA) {
|
|
@@ -4,19 +4,11 @@ import { TreeViewEngine } from './tree-view.engine';
|
|
|
4
4
|
export declare class PickupTreeViewEngine extends TreeViewEngine {
|
|
5
5
|
protected view: ViewController<IAppDETreeView, IPickupTreeViewState, IPickupTreeViewEvent>;
|
|
6
6
|
/**
|
|
7
|
-
* 选中数据
|
|
8
|
-
*
|
|
7
|
+
* @description 选中数据
|
|
9
8
|
* @type {IData[]}
|
|
10
|
-
* @memberof
|
|
9
|
+
* @memberof PickupTreeViewEngine
|
|
11
10
|
*/
|
|
12
11
|
selectData: IData[];
|
|
13
|
-
/**
|
|
14
|
-
* 通过srfkey选中数据
|
|
15
|
-
* @author lxm
|
|
16
|
-
* @date 2024-02-21 09:17:23
|
|
17
|
-
* @type {boolean}
|
|
18
|
-
*/
|
|
19
|
-
selectBySrfkey: boolean;
|
|
20
12
|
/**
|
|
21
13
|
* 创建完成
|
|
22
14
|
*
|
|
@@ -26,13 +18,11 @@ export declare class PickupTreeViewEngine extends TreeViewEngine {
|
|
|
26
18
|
*/
|
|
27
19
|
onCreated(): Promise<void>;
|
|
28
20
|
/**
|
|
29
|
-
*
|
|
30
|
-
* @
|
|
31
|
-
* @
|
|
32
|
-
* @param {string} key
|
|
33
|
-
* @return {*} {string[]}
|
|
21
|
+
* @description 初始化选中数据
|
|
22
|
+
* @protected
|
|
23
|
+
* @memberof PickupTreeViewEngine
|
|
34
24
|
*/
|
|
35
|
-
|
|
25
|
+
protected initSelectData(): void;
|
|
36
26
|
/**
|
|
37
27
|
* 挂载完成
|
|
38
28
|
*
|
|
@@ -12,19 +12,11 @@ class PickupTreeViewEngine extends TreeViewEngine {
|
|
|
12
12
|
constructor() {
|
|
13
13
|
super(...arguments);
|
|
14
14
|
/**
|
|
15
|
-
* 选中数据
|
|
16
|
-
*
|
|
15
|
+
* @description 选中数据
|
|
17
16
|
* @type {IData[]}
|
|
18
|
-
* @memberof
|
|
17
|
+
* @memberof PickupTreeViewEngine
|
|
19
18
|
*/
|
|
20
19
|
__publicField(this, "selectData", []);
|
|
21
|
-
/**
|
|
22
|
-
* 通过srfkey选中数据
|
|
23
|
-
* @author lxm
|
|
24
|
-
* @date 2024-02-21 09:17:23
|
|
25
|
-
* @type {boolean}
|
|
26
|
-
*/
|
|
27
|
-
__publicField(this, "selectBySrfkey", false);
|
|
28
20
|
}
|
|
29
21
|
/**
|
|
30
22
|
* 创建完成
|
|
@@ -40,43 +32,21 @@ class PickupTreeViewEngine extends TreeViewEngine {
|
|
|
40
32
|
}
|
|
41
33
|
this.view.slotProps.tree.singleSelect = this.view.state.singleSelect;
|
|
42
34
|
this.view.slotProps.tree.checkStrictly = this.view.state.checkStrictly;
|
|
43
|
-
|
|
44
|
-
this.selectData = this.view.state.selectedData.map((item) => {
|
|
45
|
-
return {
|
|
46
|
-
...item,
|
|
47
|
-
_id: item.srfnodeid
|
|
48
|
-
};
|
|
49
|
-
});
|
|
50
|
-
const set = /* @__PURE__ */ new Set();
|
|
51
|
-
this.selectData.forEach((item) => {
|
|
52
|
-
if (item.srfnodeid) {
|
|
53
|
-
const keys = this.calcExpandKeys(item.srfnodeid);
|
|
54
|
-
keys.forEach((key) => set.add(key));
|
|
55
|
-
} else {
|
|
56
|
-
this.selectBySrfkey = true;
|
|
57
|
-
}
|
|
58
|
-
});
|
|
59
|
-
this.view.slotProps.tree.defaultExpandedKeys = Array.from(set);
|
|
60
|
-
}
|
|
35
|
+
this.initSelectData();
|
|
61
36
|
}
|
|
62
37
|
/**
|
|
63
|
-
*
|
|
64
|
-
* @
|
|
65
|
-
* @
|
|
66
|
-
* @param {string} key
|
|
67
|
-
* @return {*} {string[]}
|
|
38
|
+
* @description 初始化选中数据
|
|
39
|
+
* @protected
|
|
40
|
+
* @memberof PickupTreeViewEngine
|
|
68
41
|
*/
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
});
|
|
78
|
-
expandedKeys.pop();
|
|
79
|
-
return expandedKeys;
|
|
42
|
+
initSelectData() {
|
|
43
|
+
if (this.view.params.selecteddata) {
|
|
44
|
+
this.selectData = JSON.parse(this.view.params.selecteddata);
|
|
45
|
+
delete this.view.params.selecteddata;
|
|
46
|
+
}
|
|
47
|
+
if (this.view.state.selectedData) {
|
|
48
|
+
this.selectData = [...this.view.state.selectedData];
|
|
49
|
+
}
|
|
80
50
|
}
|
|
81
51
|
/**
|
|
82
52
|
* 挂载完成
|
|
@@ -87,31 +57,16 @@ class PickupTreeViewEngine extends TreeViewEngine {
|
|
|
87
57
|
*/
|
|
88
58
|
async onMounted() {
|
|
89
59
|
const { model } = this.view;
|
|
90
|
-
let forbiddenSelectionChange = false;
|
|
91
60
|
this.xdataControl.evt.on("onSelectionChange", async (event) => {
|
|
92
|
-
if (forbiddenSelectionChange) {
|
|
93
|
-
return;
|
|
94
|
-
}
|
|
95
61
|
this.view.evt.emit("onSelectionChange", { ...event });
|
|
96
62
|
});
|
|
97
63
|
this.xdataControl.evt.on("onActive", async (event) => {
|
|
98
64
|
this.view.evt.emit("onDataActive", { ...event });
|
|
99
65
|
});
|
|
100
|
-
this.xdataControl.evt.on("onLoadSuccess", () => {
|
|
101
|
-
forbiddenSelectionChange = true;
|
|
102
|
-
let selectData = this.selectData;
|
|
103
|
-
if (this.selectBySrfkey) {
|
|
104
|
-
const srfkeys = this.selectData.map((item) => item.srfkey);
|
|
105
|
-
selectData = this.tree.state.items.filter((item) => {
|
|
106
|
-
return srfkeys.includes(item.srfkey);
|
|
107
|
-
});
|
|
108
|
-
}
|
|
109
|
-
this.xdataControl.setSelection(selectData);
|
|
110
|
-
forbiddenSelectionChange = false;
|
|
111
|
-
});
|
|
112
66
|
if (!this.view.state.noLoadDefault && model.loadDefault) {
|
|
113
67
|
this.load();
|
|
114
68
|
}
|
|
69
|
+
this.setSelectedData(this.selectData);
|
|
115
70
|
}
|
|
116
71
|
async call(key, args) {
|
|
117
72
|
if (key === ViewCallTag.GET_ALL_DATA) {
|
|
@@ -30,6 +30,12 @@ export declare class PickupViewEngine extends ViewEngineBase {
|
|
|
30
30
|
* @memberof PickupViewEngine
|
|
31
31
|
*/
|
|
32
32
|
onCreated(): Promise<void>;
|
|
33
|
+
/**
|
|
34
|
+
* @description 初始化选中数据
|
|
35
|
+
* @protected
|
|
36
|
+
* @memberof PickupViewEngine
|
|
37
|
+
*/
|
|
38
|
+
protected initSelectData(): void;
|
|
33
39
|
/**
|
|
34
40
|
* 视图mounted生命周期执行逻辑
|
|
35
41
|
*
|
|
@@ -39,10 +39,21 @@ class PickupViewEngine extends ViewEngineBase {
|
|
|
39
39
|
await super.onCreated();
|
|
40
40
|
const { childNames } = this.view;
|
|
41
41
|
childNames.push("pickupviewpanel");
|
|
42
|
+
this.initSelectData();
|
|
43
|
+
}
|
|
44
|
+
/**
|
|
45
|
+
* @description 初始化选中数据
|
|
46
|
+
* @protected
|
|
47
|
+
* @memberof PickupViewEngine
|
|
48
|
+
*/
|
|
49
|
+
initSelectData() {
|
|
42
50
|
if (this.view.params.selecteddata) {
|
|
43
51
|
this.selectData = JSON.parse(this.view.params.selecteddata);
|
|
44
52
|
delete this.view.params.selecteddata;
|
|
45
53
|
}
|
|
54
|
+
if (this.view.state.selectedData) {
|
|
55
|
+
this.selectData = [...this.view.state.selectedData];
|
|
56
|
+
}
|
|
46
57
|
}
|
|
47
58
|
/**
|
|
48
59
|
* 视图mounted生命周期执行逻辑
|
package/es/web-app/App.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { onUnmounted, resolveComponent, createVNode, defineComponent } from 'vue';
|
|
1
|
+
import { onMounted, onBeforeUnmount, onUnmounted, resolveComponent, createVNode, defineComponent } from 'vue';
|
|
2
2
|
import { ViewMode, Modal } from '@ibiz-template/runtime';
|
|
3
3
|
import { AppHooks } from '@ibiz-template/vue3-util';
|
|
4
4
|
import './App.css';
|
|
@@ -16,6 +16,22 @@ var App = /* @__PURE__ */ defineComponent({
|
|
|
16
16
|
ibiz.hub.destroy();
|
|
17
17
|
};
|
|
18
18
|
window.addEventListener("unload", destroyAppHub);
|
|
19
|
+
let watermarkDestroy;
|
|
20
|
+
onMounted(() => {
|
|
21
|
+
AppHooks.initedApp.tapPromise(async ({
|
|
22
|
+
context
|
|
23
|
+
}) => {
|
|
24
|
+
var _a;
|
|
25
|
+
watermarkDestroy == null ? void 0 : watermarkDestroy();
|
|
26
|
+
watermarkDestroy = ibiz.util.watermark.mount(ibiz.config.watermark, void 0, {
|
|
27
|
+
...context,
|
|
28
|
+
...(_a = ibiz.appData) == null ? void 0 : _a.context
|
|
29
|
+
});
|
|
30
|
+
});
|
|
31
|
+
});
|
|
32
|
+
onBeforeUnmount(() => {
|
|
33
|
+
watermarkDestroy == null ? void 0 : watermarkDestroy();
|
|
34
|
+
});
|
|
19
35
|
onUnmounted(() => {
|
|
20
36
|
destroyAppHub();
|
|
21
37
|
AppHooks.destoryApp.call(null);
|
|
@@ -10,6 +10,13 @@ import { IErrorHandler } from '@ibiz-template/runtime';
|
|
|
10
10
|
*/
|
|
11
11
|
export declare class UnauthorizedHandler implements IErrorHandler {
|
|
12
12
|
match(error: unknown): boolean;
|
|
13
|
+
/**
|
|
14
|
+
* @description 是否存在403错误未处理
|
|
15
|
+
* @protected
|
|
16
|
+
* @type {boolean}
|
|
17
|
+
* @memberof UnauthorizedHandler
|
|
18
|
+
*/
|
|
19
|
+
protected hasPermErrPending: boolean;
|
|
13
20
|
/**
|
|
14
21
|
* oauth登录处理
|
|
15
22
|
*
|
|
@@ -2,7 +2,22 @@ import qs from 'qs';
|
|
|
2
2
|
import { HttpError, RuntimeError, UrlHelper, LoginMode } from '@ibiz-template/core';
|
|
3
3
|
|
|
4
4
|
"use strict";
|
|
5
|
+
var __defProp = Object.defineProperty;
|
|
6
|
+
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
7
|
+
var __publicField = (obj, key, value) => {
|
|
8
|
+
__defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
9
|
+
return value;
|
|
10
|
+
};
|
|
5
11
|
class UnauthorizedHandler {
|
|
12
|
+
constructor() {
|
|
13
|
+
/**
|
|
14
|
+
* @description 是否存在403错误未处理
|
|
15
|
+
* @protected
|
|
16
|
+
* @type {boolean}
|
|
17
|
+
* @memberof UnauthorizedHandler
|
|
18
|
+
*/
|
|
19
|
+
__publicField(this, "hasPermErrPending", false);
|
|
20
|
+
}
|
|
6
21
|
match(error) {
|
|
7
22
|
return error instanceof HttpError && (error.status === 401 || error.status === 403);
|
|
8
23
|
}
|
|
@@ -83,10 +98,15 @@ class UnauthorizedHandler {
|
|
|
83
98
|
*/
|
|
84
99
|
async handle403(error) {
|
|
85
100
|
if (error.tag === "APPINIT") {
|
|
101
|
+
if (this.hasPermErrPending) {
|
|
102
|
+
return;
|
|
103
|
+
}
|
|
104
|
+
this.hasPermErrPending = true;
|
|
86
105
|
const result = await ibiz.confirm.warning({
|
|
87
106
|
title: ibiz.i18n.t("webApp.unauthorizedHandler.forbiddenAccess"),
|
|
88
107
|
desc: ibiz.i18n.t("webApp.unauthorizedHandler.logoutAccount")
|
|
89
108
|
});
|
|
109
|
+
this.hasPermErrPending = false;
|
|
90
110
|
if (result) {
|
|
91
111
|
const bol = await ibiz.hub.controller.logout();
|
|
92
112
|
if (bol) {
|
|
@@ -108,7 +128,8 @@ class UnauthorizedHandler {
|
|
|
108
128
|
if (error instanceof HttpError) {
|
|
109
129
|
if (error.status === 401) {
|
|
110
130
|
const search = qs.parse(window.location.search.replace("?", ""));
|
|
111
|
-
if (search.isAnonymous || ibiz.env.enableAnonymous)
|
|
131
|
+
if ((search.isAnonymous || ibiz.env.enableAnonymous) && // 匿名登录获取视图模型发生异常,走普通登录,防止循环执行
|
|
132
|
+
error.tag !== "APPINIT") {
|
|
112
133
|
ibiz.auth.anonymousLogin().then((bol) => {
|
|
113
134
|
if (bol) {
|
|
114
135
|
window.location.reload();
|
|
@@ -84,15 +84,14 @@ const IBizControlNavigation = /* @__PURE__ */ vue.defineComponent({
|
|
|
84
84
|
}
|
|
85
85
|
});
|
|
86
86
|
const renderNavView = () => {
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
}
|
|
87
|
+
var _a2;
|
|
88
|
+
if (!((_a2 = navViewMsg.value) == null ? void 0 : _a2.viewId))
|
|
89
|
+
return;
|
|
90
|
+
return vue.h(vue.resolveComponent("IBizViewShell"), {
|
|
91
|
+
...navViewMsg.value,
|
|
92
|
+
isEmbedCtrlNav: isEmbedCtrlNav.value,
|
|
93
|
+
class: ns.e("nav-view")
|
|
94
|
+
});
|
|
96
95
|
};
|
|
97
96
|
return {
|
|
98
97
|
ns,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var runtime = require('@ibiz-template/runtime');
|
|
4
4
|
var navigationBase_provider = require('./navigation-base.provider.cjs');
|
|
5
5
|
|
|
6
6
|
"use strict";
|
|
@@ -15,18 +15,29 @@ class CalendarNavigationProvider extends navigationBase_provider.NavgationBasePr
|
|
|
15
15
|
super(...arguments);
|
|
16
16
|
__publicField(this, "keyName", "navId");
|
|
17
17
|
}
|
|
18
|
+
/**
|
|
19
|
+
* @description 通过栈数据导航
|
|
20
|
+
* - 特殊处理仅使用开始时间绘制的日历
|
|
21
|
+
* @memberof CalendarNavigationProvider
|
|
22
|
+
*/
|
|
18
23
|
onNavDataByStack() {
|
|
19
|
-
|
|
20
|
-
const
|
|
24
|
+
var _a;
|
|
25
|
+
const { controlParams, state, model } = this.controller;
|
|
26
|
+
const calendarStyle = (_a = model.calendarStyle) == null ? void 0 : _a.toLowerCase();
|
|
27
|
+
const items = state.items.filter((item) => {
|
|
28
|
+
if (calendarStyle === "month" && controlParams.showmode !== "daterange" || calendarStyle === "user")
|
|
29
|
+
return runtime.compareDateEqualByScale(
|
|
30
|
+
item.beginTime,
|
|
31
|
+
state.selectedDate,
|
|
32
|
+
calendarStyle === "user" ? "week" : "month"
|
|
33
|
+
);
|
|
34
|
+
return true;
|
|
35
|
+
});
|
|
36
|
+
const navData = this.navStack.map((key) => items.find((item) => item[this.keyName] === key)).find((item) => item !== void 0) || items[0];
|
|
21
37
|
if (navData) {
|
|
22
|
-
|
|
23
|
-
if (dayjs(date).isValid())
|
|
24
|
-
this.controller.setSelectDate(date);
|
|
25
|
-
this.controller.setNavData(navData);
|
|
38
|
+
this.setNavData(navData);
|
|
26
39
|
} else {
|
|
27
|
-
this.
|
|
28
|
-
this.controller.setSelectDate(/* @__PURE__ */ new Date());
|
|
29
|
-
this.navViewMsg.value = void 0;
|
|
40
|
+
this.clearNavigation();
|
|
30
41
|
}
|
|
31
42
|
}
|
|
32
43
|
getNavViewMsg(item) {
|