@ibiz-template/vue3-components 0.7.26-alpha.2 → 0.7.26
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-28jZm-aB.js +4 -0
- package/dist/{index-8tGeBxpc.js → index-RwYoggQd.js} +1 -1
- package/dist/{index-CDgQJyai.js → index-s7g1-ymW.js} +1 -1
- package/dist/index.min.css +1 -1
- package/dist/index.system.min.js +1 -1
- package/dist/{xlsx-util-Ux1_tuw5.js → xlsx-util-Rf5FMxyR.js} +1 -1
- package/es/common/emoji-select/components/categories/categories.css +1 -0
- package/es/common/emoji-select/components/categories/categories.d.ts +30 -0
- package/es/common/emoji-select/components/categories/categories.mjs +48 -0
- package/es/common/emoji-select/components/categories/index.d.ts +1 -0
- package/es/common/emoji-select/components/categories/index.mjs +3 -0
- package/es/common/emoji-select/components/category-label/category-label.css +1 -0
- package/es/common/emoji-select/components/category-label/category-label.d.ts +18 -0
- package/es/common/emoji-select/components/category-label/category-label.mjs +28 -0
- package/es/common/emoji-select/components/category-label/index.d.ts +1 -0
- package/es/common/emoji-select/components/category-label/index.mjs +3 -0
- package/es/common/emoji-select/components/emoji-item/emoji-item.css +1 -0
- package/es/common/emoji-select/components/emoji-item/emoji-item.d.ts +44 -0
- package/es/common/emoji-select/components/emoji-item/emoji-item.mjs +56 -0
- package/es/common/emoji-select/components/emoji-item/index.d.ts +1 -0
- package/es/common/emoji-select/components/emoji-item/index.mjs +3 -0
- package/es/common/emoji-select/components/emoji-list/emoji-list.css +1 -0
- package/es/common/emoji-select/components/emoji-list/emoji-list.d.ts +92 -0
- package/es/common/emoji-select/components/emoji-list/emoji-list.mjs +165 -0
- package/es/common/emoji-select/components/emoji-list/index.d.ts +1 -0
- package/es/common/emoji-select/components/emoji-list/index.mjs +3 -0
- package/es/common/emoji-select/components/index.d.ts +5 -0
- package/es/common/emoji-select/components/index.mjs +12 -0
- package/es/common/emoji-select/components/input-search/index.d.ts +1 -0
- package/es/common/emoji-select/components/input-search/index.mjs +3 -0
- package/es/common/emoji-select/components/input-search/input-search.css +1 -0
- package/es/common/emoji-select/components/input-search/input-search.d.ts +9 -0
- package/es/common/emoji-select/components/input-search/input-search.mjs +49 -0
- package/es/common/emoji-select/emoji-select.css +1 -0
- package/es/common/emoji-select/emoji-select.d.ts +142 -0
- package/es/common/emoji-select/emoji-select.mjs +234 -0
- package/es/common/emoji-select/icons/categories.d.ts +2 -0
- package/es/common/emoji-select/icons/categories.mjs +64 -0
- package/es/common/emoji-select/icons/emoji.d.ts +2 -0
- package/es/common/emoji-select/icons/emoji.mjs +1444 -0
- package/es/common/emoji-select/icons/index.d.ts +3 -0
- package/es/common/emoji-select/icons/index.mjs +5 -0
- package/es/common/emoji-select/icons/search.d.ts +1 -0
- package/es/common/emoji-select/icons/search.mjs +16 -0
- package/es/common/emoji-select/interface/category.d.ts +44 -0
- package/es/common/emoji-select/interface/category.mjs +22 -0
- package/es/common/emoji-select/interface/emoji.d.ts +37 -0
- package/es/common/emoji-select/interface/emoji.mjs +19 -0
- package/es/common/emoji-select/interface/index.d.ts +3 -0
- package/es/common/emoji-select/interface/index.mjs +5 -0
- package/es/common/emoji-select/interface/map-emojis.d.ts +17 -0
- package/es/common/emoji-select/interface/map-emojis.mjs +1 -0
- package/es/common/index.mjs +2 -0
- package/es/common/view-message/view-message.d.ts +1 -0
- package/es/control/calendar/calendar.css +1 -1
- package/es/control/calendar/calendar.d.ts +3 -2
- package/es/control/calendar/calendar.mjs +203 -86
- package/es/control/calendar/components/calendar-daily/calendar-daily.d.ts +1 -1
- package/es/control/calendar/components/calendar-daily/index.d.ts +1 -1
- package/es/control/calendar/components/calendar-week/calendar-week.d.ts +1 -1
- package/es/control/calendar/components/calendar-week/calendar-week.mjs +15 -12
- package/es/control/calendar/components/calendar-week/index.d.ts +1 -1
- package/es/control/calendar/components/calendar-week/use-calendar-week.mjs +1 -0
- package/es/control/calendar/components/custom-calendar/custom-calendar.mjs +4 -114
- package/es/control/calendar/components/interface/calendar-daily.mjs +0 -3
- package/es/control/calendar/components/interface/calendar-week.mjs +3 -2
- package/es/control/calendar/components/interface/custom-calendar.mjs +8 -3
- package/es/control/calendar/components/interface/index.d.ts +0 -1
- package/es/control/calendar/components/interface/index.mjs +0 -1
- package/es/control/calendar/index.d.ts +2 -1
- package/es/control/dashboard/custom-dashboard-container/custom-dashboard-container.d.ts +36 -2
- package/es/control/dashboard/custom-dashboard-container/custom-dashboard-container.mjs +17 -7
- package/es/control/dashboard/dashboard-design/dashboard-design.d.ts +10 -32
- package/es/control/dashboard/dashboard-design/dashboard-design.mjs +93 -56
- package/es/control/drtab/drtab-control.util.mjs +1 -1
- package/es/control/form/form-detail/form-mdctrl/form-mdctrl-repeater/repeater-grid/repeater-grid.d.ts +25 -0
- package/es/control/form/form-detail/form-mdctrl/mdctrl-container2/mdctrl-container2.mjs +1 -0
- package/es/control/grid/grid/grid-control.util.d.ts +8 -0
- package/es/control/grid/grid/grid-control.util.mjs +151 -1
- package/es/control/grid/grid/grid.css +1 -1
- package/es/control/grid/grid/grid.d.ts +8 -0
- package/es/control/grid/grid/grid.mjs +12 -2
- package/es/control/grid/grid/index.d.ts +8 -0
- package/es/control/grid/grid-column/grid-field-column/grid-field-column.d.ts +1 -0
- package/es/control/grid/grid-column/grid-field-column/grid-field-column.mjs +21 -1
- package/es/control/grid/grid-column/grid-field-column/index.d.ts +1 -0
- package/es/control/tree/tree.css +1 -1
- package/es/editor/dropdown-list/dropdown-list-editor.provider.d.ts +1 -0
- package/es/editor/dropdown-list/dropdown-list-editor.provider.mjs +10 -1
- package/es/editor/dropdown-list/ibiz-emoji-picker/ibiz-emoji-picker.css +1 -0
- package/es/editor/dropdown-list/ibiz-emoji-picker/ibiz-emoji-picker.d.ts +72 -0
- package/es/editor/dropdown-list/ibiz-emoji-picker/ibiz-emoji-picker.mjs +123 -0
- package/es/editor/dropdown-list/index.d.ts +1 -0
- package/es/editor/dropdown-list/index.mjs +1 -0
- package/es/editor/index.mjs +6 -0
- package/es/editor/text-box/input/input.d.ts +1 -1
- package/es/locale/en/index.d.ts +14 -0
- package/es/locale/en/index.mjs +14 -0
- package/es/locale/zh-CN/index.d.ts +14 -0
- package/es/locale/zh-CN/index.mjs +14 -0
- package/es/panel-component/nav-tabs/nav-tabs.controller.d.ts +7 -0
- package/es/panel-component/nav-tabs/nav-tabs.controller.mjs +19 -0
- package/lib/common/emoji-select/components/categories/categories.cjs +50 -0
- package/lib/common/emoji-select/components/categories/categories.css +1 -0
- package/lib/common/emoji-select/components/categories/index.cjs +7 -0
- package/lib/common/emoji-select/components/category-label/category-label.cjs +30 -0
- package/lib/common/emoji-select/components/category-label/category-label.css +1 -0
- package/lib/common/emoji-select/components/category-label/index.cjs +7 -0
- package/lib/common/emoji-select/components/emoji-item/emoji-item.cjs +58 -0
- package/lib/common/emoji-select/components/emoji-item/emoji-item.css +1 -0
- package/lib/common/emoji-select/components/emoji-item/index.cjs +7 -0
- package/lib/common/emoji-select/components/emoji-list/emoji-list.cjs +167 -0
- package/lib/common/emoji-select/components/emoji-list/emoji-list.css +1 -0
- package/lib/common/emoji-select/components/emoji-list/index.cjs +7 -0
- package/lib/common/emoji-select/components/index.cjs +20 -0
- package/lib/common/emoji-select/components/input-search/index.cjs +7 -0
- package/lib/common/emoji-select/components/input-search/input-search.cjs +51 -0
- package/lib/common/emoji-select/components/input-search/input-search.css +1 -0
- package/lib/common/emoji-select/emoji-select.cjs +236 -0
- package/lib/common/emoji-select/emoji-select.css +1 -0
- package/lib/common/emoji-select/icons/categories.cjs +66 -0
- package/lib/common/emoji-select/icons/emoji.cjs +1446 -0
- package/lib/common/emoji-select/icons/index.cjs +11 -0
- package/lib/common/emoji-select/icons/search.cjs +18 -0
- package/lib/common/emoji-select/interface/category.cjs +24 -0
- package/lib/common/emoji-select/interface/emoji.cjs +21 -0
- package/lib/common/emoji-select/interface/index.cjs +10 -0
- package/lib/common/emoji-select/interface/map-emojis.cjs +3 -0
- package/lib/common/index.cjs +2 -0
- package/lib/control/calendar/calendar.cjs +203 -86
- package/lib/control/calendar/calendar.css +1 -1
- package/lib/control/calendar/components/calendar-week/calendar-week.cjs +15 -12
- package/lib/control/calendar/components/calendar-week/use-calendar-week.cjs +1 -0
- package/lib/control/calendar/components/custom-calendar/custom-calendar.cjs +7 -117
- package/lib/control/calendar/components/interface/calendar-daily.cjs +0 -3
- package/lib/control/calendar/components/interface/calendar-week.cjs +3 -2
- package/lib/control/calendar/components/interface/custom-calendar.cjs +8 -3
- package/lib/control/calendar/components/interface/index.cjs +0 -3
- package/lib/control/dashboard/custom-dashboard-container/custom-dashboard-container.cjs +17 -7
- package/lib/control/dashboard/dashboard-design/dashboard-design.cjs +93 -56
- package/lib/control/drtab/drtab-control.util.cjs +1 -1
- package/lib/control/form/form-detail/form-mdctrl/mdctrl-container2/mdctrl-container2.cjs +1 -0
- package/lib/control/grid/grid/grid-control.util.cjs +151 -1
- package/lib/control/grid/grid/grid.cjs +12 -2
- package/lib/control/grid/grid/grid.css +1 -1
- package/lib/control/grid/grid-column/grid-field-column/grid-field-column.cjs +21 -1
- package/lib/control/tree/tree.css +1 -1
- package/lib/editor/dropdown-list/dropdown-list-editor.provider.cjs +10 -1
- package/lib/editor/dropdown-list/ibiz-emoji-picker/ibiz-emoji-picker.cjs +125 -0
- package/lib/editor/dropdown-list/ibiz-emoji-picker/ibiz-emoji-picker.css +1 -0
- package/lib/editor/dropdown-list/index.cjs +2 -0
- package/lib/editor/index.cjs +6 -0
- package/lib/locale/en/index.cjs +14 -0
- package/lib/locale/zh-CN/index.cjs +14 -0
- package/lib/panel-component/nav-tabs/nav-tabs.controller.cjs +19 -0
- package/package.json +8 -8
- package/dist/index-o58Mv9D4.js +0 -4
- package/es/_virtual/localeData.mjs +0 -3
- package/es/control/calendar/components/calendar-month/calendar-month.css +0 -1
- package/es/control/calendar/components/calendar-month/calendar-month.d.ts +0 -18
- package/es/control/calendar/components/calendar-month/calendar-month.mjs +0 -242
- package/es/control/calendar/components/calendar-month/index.d.ts +0 -18
- package/es/control/calendar/components/calendar-month/index.mjs +0 -9
- package/es/control/calendar/components/calendar-month/use-calendar-month.d.ts +0 -3
- package/es/control/calendar/components/calendar-month/use-calendar-month.mjs +0 -384
- package/es/control/calendar/components/interface/calendar-month.d.ts +0 -20
- package/es/control/calendar/components/interface/calendar-month.mjs +0 -43
- package/es/node_modules/.pnpm/dayjs@1.11.10/node_modules/dayjs/plugin/localeData.mjs +0 -13
- package/lib/_virtual/localeData.cjs +0 -5
- package/lib/control/calendar/components/calendar-month/calendar-month.cjs +0 -244
- package/lib/control/calendar/components/calendar-month/calendar-month.css +0 -1
- package/lib/control/calendar/components/calendar-month/index.cjs +0 -14
- package/lib/control/calendar/components/calendar-month/use-calendar-month.cjs +0 -386
- package/lib/control/calendar/components/interface/calendar-month.cjs +0 -46
- package/lib/node_modules/.pnpm/dayjs@1.11.10/node_modules/dayjs/plugin/localeData.cjs +0 -17
- /package/es/node_modules/.pnpm/{@ibiz-template_core@0.7.25_axios@1.6.8_lodash-es@4.17.21_qs@6.11.2_qx-util@0.4.8_ramda@0.29.1 → @ibiz-template_core@0.7.26_axios@1.6.8_lodash-es@4.17.21_qs@6.11.2_qx-util@0.4.8_ramda@0.29.1}/node_modules/@ibiz-template/core/out/utils/namespace/namespace.mjs +0 -0
- /package/lib/node_modules/.pnpm/{@ibiz-template_core@0.7.25_axios@1.6.8_lodash-es@4.17.21_qs@6.11.2_qx-util@0.4.8_ramda@0.29.1 → @ibiz-template_core@0.7.26_axios@1.6.8_lodash-es@4.17.21_qs@6.11.2_qx-util@0.4.8_ramda@0.29.1}/node_modules/@ibiz-template/core/out/utils/namespace/namespace.cjs +0 -0
|
@@ -30,7 +30,7 @@ const CustomDashboardContainer = /* @__PURE__ */ defineComponent({
|
|
|
30
30
|
const clickCollapse = (type) => {
|
|
31
31
|
showTypeDir.value = type === "left";
|
|
32
32
|
};
|
|
33
|
-
const
|
|
33
|
+
const getPortletModelByCodeName = (codeName) => {
|
|
34
34
|
const app = ibiz.hub.getApp(ibiz.env.appId);
|
|
35
35
|
if (app.model.appPortlets) {
|
|
36
36
|
const appPortlet = app.model.appPortlets.find((portlet) => {
|
|
@@ -42,15 +42,25 @@ const CustomDashboardContainer = /* @__PURE__ */ defineComponent({
|
|
|
42
42
|
}
|
|
43
43
|
}
|
|
44
44
|
};
|
|
45
|
-
const
|
|
45
|
+
const getPortletModel = async (data) => {
|
|
46
|
+
if (data.dynamodelFlag) {
|
|
47
|
+
if (data.portletModel) {
|
|
48
|
+
return data.portletModel;
|
|
49
|
+
}
|
|
50
|
+
const dynaPortlet = await props.dashboard.loadDynaPortletById(data.portletId);
|
|
51
|
+
return dynaPortlet;
|
|
52
|
+
}
|
|
53
|
+
return getPortletModelByCodeName(data.portletCodeName);
|
|
54
|
+
};
|
|
55
|
+
const convertData = async (models) => {
|
|
46
56
|
const tempModelDatas = [];
|
|
47
57
|
if (models.length > 0) {
|
|
48
|
-
models.
|
|
49
|
-
const temModelData =
|
|
58
|
+
for (let i = 0; i < models.length; i++) {
|
|
59
|
+
const temModelData = await getPortletModel(models[i]);
|
|
50
60
|
if (temModelData) {
|
|
51
61
|
tempModelDatas.push(temModelData);
|
|
52
62
|
}
|
|
53
|
-
}
|
|
63
|
+
}
|
|
54
64
|
}
|
|
55
65
|
return tempModelDatas;
|
|
56
66
|
};
|
|
@@ -60,7 +70,7 @@ const CustomDashboardContainer = /* @__PURE__ */ defineComponent({
|
|
|
60
70
|
};
|
|
61
71
|
const onSaved = async (args) => {
|
|
62
72
|
isShowDesign.value = false;
|
|
63
|
-
const tempModelDatas = convertData(args.model);
|
|
73
|
+
const tempModelDatas = await convertData(args.model);
|
|
64
74
|
await handleCustomModelChange({
|
|
65
75
|
model: tempModelDatas,
|
|
66
76
|
config: args.config
|
|
@@ -82,7 +92,7 @@ const CustomDashboardContainer = /* @__PURE__ */ defineComponent({
|
|
|
82
92
|
});
|
|
83
93
|
onMounted(async () => {
|
|
84
94
|
const response = await customC.loadCustomModelData();
|
|
85
|
-
const tempModelDatas = convertData(response.model);
|
|
95
|
+
const tempModelDatas = await convertData(response.model);
|
|
86
96
|
emit("changed", {
|
|
87
97
|
model: tempModelDatas
|
|
88
98
|
});
|
|
@@ -4,6 +4,7 @@ import { PropType, Ref } from 'vue';
|
|
|
4
4
|
import './dashboard-design.scss';
|
|
5
5
|
interface IPortletList {
|
|
6
6
|
type: string;
|
|
7
|
+
portletId?: string;
|
|
7
8
|
portletCodeName: string;
|
|
8
9
|
portletName: string;
|
|
9
10
|
portletImage?: ISysImage;
|
|
@@ -11,6 +12,12 @@ interface IPortletList {
|
|
|
11
12
|
groupName: string;
|
|
12
13
|
appCodeName: string;
|
|
13
14
|
appName: string;
|
|
15
|
+
dynamodelFlag?: number;
|
|
16
|
+
}
|
|
17
|
+
interface IList {
|
|
18
|
+
type: string;
|
|
19
|
+
name: string;
|
|
20
|
+
children: IData[];
|
|
14
21
|
}
|
|
15
22
|
export declare const DashboardDesign: import("vue").DefineComponent<{
|
|
16
23
|
dashboard: {
|
|
@@ -28,37 +35,8 @@ export declare const DashboardDesign: import("vue").DefineComponent<{
|
|
|
28
35
|
}, {
|
|
29
36
|
ns: import("@ibiz-template/core").Namespace;
|
|
30
37
|
customC: CustomDashboardController;
|
|
31
|
-
portlets: Ref<
|
|
32
|
-
|
|
33
|
-
portletCodeName: string;
|
|
34
|
-
portletName: string;
|
|
35
|
-
portletImage?: {
|
|
36
|
-
codeName?: string | undefined;
|
|
37
|
-
cssClass?: string | undefined;
|
|
38
|
-
cssClassX?: string | undefined;
|
|
39
|
-
glyph?: string | undefined;
|
|
40
|
-
height?: number | undefined;
|
|
41
|
-
imagePath?: string | undefined;
|
|
42
|
-
imagePathX?: string | undefined;
|
|
43
|
-
rawContent?: string | undefined;
|
|
44
|
-
width?: number | undefined;
|
|
45
|
-
appId: string;
|
|
46
|
-
id?: string | undefined;
|
|
47
|
-
name?: string | undefined;
|
|
48
|
-
userParam?: Record<string, string> | undefined;
|
|
49
|
-
modelId?: string | undefined;
|
|
50
|
-
modelType?: string | undefined;
|
|
51
|
-
} | undefined;
|
|
52
|
-
groupCodeName: string;
|
|
53
|
-
groupName: string;
|
|
54
|
-
appCodeName: string;
|
|
55
|
-
appName: string;
|
|
56
|
-
}[]>;
|
|
57
|
-
list: Ref<{
|
|
58
|
-
type: string;
|
|
59
|
-
name: string;
|
|
60
|
-
children: IData[];
|
|
61
|
-
}[]>;
|
|
38
|
+
portlets: Ref<IPortletList[]>;
|
|
39
|
+
list: Ref<IList[]>;
|
|
62
40
|
groups: Ref<IData[]>;
|
|
63
41
|
filterVal: Ref<string>;
|
|
64
42
|
defaultOpens: import("vue").ComputedRef<string[]>;
|
|
@@ -76,9 +54,9 @@ export declare const DashboardDesign: import("vue").DefineComponent<{
|
|
|
76
54
|
portletControllers: Ref<{
|
|
77
55
|
[key: string]: IPortletController;
|
|
78
56
|
}>;
|
|
79
|
-
getPortletByCodeName: (codeName: string) => IDBPortletPart | undefined;
|
|
80
57
|
maskSize: import("vue").ComputedRef<string>;
|
|
81
58
|
designPanel: Ref<Element | null>;
|
|
59
|
+
getPortletModelByCodeName: (tag: string) => IDBPortletPart | undefined;
|
|
82
60
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("reset" | "saved")[], "reset" | "saved", import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
83
61
|
dashboard: {
|
|
84
62
|
type: PropType<DashboardController>;
|
|
@@ -29,10 +29,20 @@ const DashboardDesign = /* @__PURE__ */ defineComponent({
|
|
|
29
29
|
emit
|
|
30
30
|
}) {
|
|
31
31
|
const ns = useNamespace("dashboard-design");
|
|
32
|
+
const c = props.dashboard;
|
|
32
33
|
const customC = props.customDashboard;
|
|
33
|
-
const
|
|
34
|
+
const portlets = ref([]);
|
|
35
|
+
const list = ref([]);
|
|
36
|
+
const groups = ref([]);
|
|
37
|
+
const filterVal = ref("");
|
|
38
|
+
const layoutModel = ref(clone(customC.customModelData));
|
|
39
|
+
const layoutConfig = ref(clone(customC.portletConfig));
|
|
40
|
+
const providers = ref({});
|
|
41
|
+
const portletControllers = ref({});
|
|
42
|
+
const designPanel = ref(null);
|
|
43
|
+
const filterData = (list1) => {
|
|
34
44
|
const items = [];
|
|
35
|
-
|
|
45
|
+
list1.forEach((data) => {
|
|
36
46
|
var _a;
|
|
37
47
|
if (Object.is(data.type, "app")) {
|
|
38
48
|
items.push(data);
|
|
@@ -96,10 +106,26 @@ const DashboardDesign = /* @__PURE__ */ defineComponent({
|
|
|
96
106
|
});
|
|
97
107
|
return items;
|
|
98
108
|
};
|
|
99
|
-
const prepareData = () => {
|
|
100
|
-
const
|
|
109
|
+
const prepareData = async () => {
|
|
110
|
+
const list3 = [];
|
|
101
111
|
const app = ibiz.hub.getApp(ibiz.env.appId);
|
|
102
|
-
if (
|
|
112
|
+
if (c.enableDynamic) {
|
|
113
|
+
const dynamicPortlets = await c.loadAllDynaPortlet();
|
|
114
|
+
dynamicPortlets == null ? void 0 : dynamicPortlets.forEach((portlet) => {
|
|
115
|
+
const temp = {
|
|
116
|
+
type: "app",
|
|
117
|
+
dynamodelFlag: 1,
|
|
118
|
+
portletId: portlet.psappportletid,
|
|
119
|
+
portletCodeName: portlet.codename,
|
|
120
|
+
portletName: portlet.psappportletname,
|
|
121
|
+
groupCodeName: "Ungroup",
|
|
122
|
+
groupName: "\u672A\u5206\u7C7B",
|
|
123
|
+
appCodeName: app.model.pkgcodeName,
|
|
124
|
+
appName: app.model.name
|
|
125
|
+
};
|
|
126
|
+
list3.push(temp);
|
|
127
|
+
});
|
|
128
|
+
} else if (app.model.appPortletCats && app.model.appPortlets) {
|
|
103
129
|
const isDEView = customC.model.appDataEntityId;
|
|
104
130
|
const categoryTag = props.dashboard.controlParams.categorytag;
|
|
105
131
|
app.model.appPortlets.forEach((portlet) => {
|
|
@@ -129,28 +155,14 @@ const DashboardDesign = /* @__PURE__ */ defineComponent({
|
|
|
129
155
|
appCodeName: portlet.appDataEntityId || app.model.pkgcodeName,
|
|
130
156
|
appName: app.model.name
|
|
131
157
|
};
|
|
132
|
-
|
|
158
|
+
list3.push(temp);
|
|
133
159
|
});
|
|
134
160
|
}
|
|
135
|
-
const datas = filterData(
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
portlets: datas,
|
|
140
|
-
list: result2.reverse(),
|
|
141
|
-
groups: groups2
|
|
142
|
-
};
|
|
161
|
+
const datas = filterData(list3);
|
|
162
|
+
portlets.value = datas;
|
|
163
|
+
list.value = prepareList(datas).reverse();
|
|
164
|
+
groups.value = prepareGroup(datas);
|
|
143
165
|
};
|
|
144
|
-
const result = prepareData();
|
|
145
|
-
const portlets = ref(result.portlets);
|
|
146
|
-
const list = ref(result.list);
|
|
147
|
-
const groups = ref(result.groups);
|
|
148
|
-
const filterVal = ref("");
|
|
149
|
-
const layoutModel = ref(clone(customC.customModelData));
|
|
150
|
-
const layoutConfig = ref(clone(customC.portletConfig));
|
|
151
|
-
const providers = ref({});
|
|
152
|
-
const portletControllers = ref({});
|
|
153
|
-
const designPanel = ref(null);
|
|
154
166
|
const defaultOpens = computed(() => {
|
|
155
167
|
let tempOpens = [];
|
|
156
168
|
if (filterVal.value) {
|
|
@@ -186,41 +198,59 @@ const DashboardDesign = /* @__PURE__ */ defineComponent({
|
|
|
186
198
|
}
|
|
187
199
|
});
|
|
188
200
|
};
|
|
189
|
-
const
|
|
201
|
+
const getPortletModelByCodeName = (tag) => {
|
|
190
202
|
const app = ibiz.hub.getApp(ibiz.env.appId);
|
|
191
203
|
if (app.model.appPortlets) {
|
|
192
204
|
const appPortlet = app.model.appPortlets.find((portlet) => {
|
|
193
205
|
var _a;
|
|
194
|
-
return ((_a = portlet.control) == null ? void 0 : _a.codeName) ===
|
|
206
|
+
return ((_a = portlet.control) == null ? void 0 : _a.codeName) === tag;
|
|
195
207
|
});
|
|
196
208
|
if (appPortlet) {
|
|
197
209
|
return appPortlet.control;
|
|
198
210
|
}
|
|
199
211
|
}
|
|
200
212
|
};
|
|
201
|
-
const
|
|
213
|
+
const getPortletModel = async (data) => {
|
|
214
|
+
if (data.dynamodelFlag) {
|
|
215
|
+
if (data.portletModel) {
|
|
216
|
+
return data.portletModel;
|
|
217
|
+
}
|
|
218
|
+
const dynaPortlet = await c.loadDynaPortletById(data.portletId);
|
|
219
|
+
return dynaPortlet;
|
|
220
|
+
}
|
|
221
|
+
return getPortletModelByCodeName(data.portletCodeName);
|
|
222
|
+
};
|
|
223
|
+
const convertData = async (models) => {
|
|
202
224
|
const tempModelDatas = [];
|
|
203
225
|
if (models.length > 0) {
|
|
204
|
-
models.
|
|
205
|
-
const temModelData =
|
|
226
|
+
for (let i = 0; i < models.length; i++) {
|
|
227
|
+
const temModelData = await getPortletModel(models[i]);
|
|
206
228
|
if (temModelData) {
|
|
207
229
|
tempModelDatas.push(temModelData);
|
|
208
230
|
}
|
|
209
|
-
}
|
|
231
|
+
}
|
|
210
232
|
}
|
|
211
233
|
return tempModelDatas;
|
|
212
234
|
};
|
|
213
|
-
const preparePortlet = async () => {
|
|
214
|
-
const tempModelDatas = convertData(
|
|
235
|
+
const preparePortlet = async (data) => {
|
|
236
|
+
const tempModelDatas = await convertData(data);
|
|
215
237
|
await initPortlets(tempModelDatas);
|
|
216
238
|
await initPortletsConfig();
|
|
239
|
+
return tempModelDatas;
|
|
217
240
|
};
|
|
218
241
|
watch(() => props.isShowDesign, async (newVal) => {
|
|
219
242
|
if (newVal) {
|
|
243
|
+
await prepareData();
|
|
220
244
|
const res = await customC.loadCustomModelData();
|
|
221
|
-
|
|
245
|
+
const model = clone(res.model);
|
|
246
|
+
const tempModelDatas = await preparePortlet(model);
|
|
247
|
+
layoutModel.value = model;
|
|
248
|
+
layoutModel.value.forEach((item, index) => {
|
|
249
|
+
if (item.dynamodelFlag) {
|
|
250
|
+
item.portletModel = tempModelDatas[index];
|
|
251
|
+
}
|
|
252
|
+
});
|
|
222
253
|
layoutConfig.value = clone(res.config);
|
|
223
|
-
await preparePortlet();
|
|
224
254
|
}
|
|
225
255
|
}, {
|
|
226
256
|
immediate: true
|
|
@@ -246,7 +276,7 @@ const DashboardDesign = /* @__PURE__ */ defineComponent({
|
|
|
246
276
|
const index = layoutModel.value.indexOf(child);
|
|
247
277
|
if (index !== -1) {
|
|
248
278
|
layoutModel.value.splice(index, 1);
|
|
249
|
-
const temModelData =
|
|
279
|
+
const temModelData = await getPortletModel(child);
|
|
250
280
|
if (temModelData) {
|
|
251
281
|
const controller = portletControllers.value[temModelData.id];
|
|
252
282
|
await controller.destroyed();
|
|
@@ -255,6 +285,7 @@ const DashboardDesign = /* @__PURE__ */ defineComponent({
|
|
|
255
285
|
};
|
|
256
286
|
const lastScrollHeight = ref(0);
|
|
257
287
|
const addLayoutItem = async (child) => {
|
|
288
|
+
const tempModelDatas = await preparePortlet([child]);
|
|
258
289
|
const element = designPanel.value;
|
|
259
290
|
if (element) {
|
|
260
291
|
lastScrollHeight.value = element.scrollHeight + 3 * customC.layoutRowH;
|
|
@@ -265,15 +296,20 @@ const DashboardDesign = /* @__PURE__ */ defineComponent({
|
|
|
265
296
|
maxY = obj.y;
|
|
266
297
|
}
|
|
267
298
|
}
|
|
268
|
-
|
|
299
|
+
const tempItemModel = {
|
|
269
300
|
w: 4,
|
|
270
301
|
h: 3,
|
|
271
302
|
x: 0,
|
|
272
303
|
y: maxY + 3,
|
|
273
304
|
i: child.portletCodeName,
|
|
274
305
|
...child
|
|
275
|
-
}
|
|
276
|
-
|
|
306
|
+
};
|
|
307
|
+
if (child.dynamodelFlag) {
|
|
308
|
+
Object.assign(tempItemModel, {
|
|
309
|
+
portletModel: tempModelDatas[0]
|
|
310
|
+
});
|
|
311
|
+
}
|
|
312
|
+
layoutModel.value.push(tempItemModel);
|
|
277
313
|
if (element) {
|
|
278
314
|
const intervalId = setInterval(() => {
|
|
279
315
|
if (element.scrollHeight >= lastScrollHeight.value) {
|
|
@@ -319,9 +355,9 @@ const DashboardDesign = /* @__PURE__ */ defineComponent({
|
|
|
319
355
|
isDisabled,
|
|
320
356
|
providers,
|
|
321
357
|
portletControllers,
|
|
322
|
-
getPortletByCodeName,
|
|
323
358
|
maskSize,
|
|
324
|
-
designPanel
|
|
359
|
+
designPanel,
|
|
360
|
+
getPortletModelByCodeName
|
|
325
361
|
};
|
|
326
362
|
},
|
|
327
363
|
render() {
|
|
@@ -390,23 +426,24 @@ const DashboardDesign = /* @__PURE__ */ defineComponent({
|
|
|
390
426
|
});
|
|
391
427
|
};
|
|
392
428
|
const renderPortlet = (item) => {
|
|
393
|
-
const portletModel = this.
|
|
394
|
-
if (portletModel) {
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
return h(providerComp, {
|
|
406
|
-
...commonProps,
|
|
407
|
-
key: portletModel.id
|
|
408
|
-
});
|
|
429
|
+
const portletModel = item.dynamodelFlag ? item.portletModel : this.getPortletModelByCodeName(item.portletCodeName);
|
|
430
|
+
if (!portletModel) {
|
|
431
|
+
return null;
|
|
432
|
+
}
|
|
433
|
+
const provider = this.providers[portletModel.id];
|
|
434
|
+
const controller = this.portletControllers[portletModel.id];
|
|
435
|
+
const commonProps = {
|
|
436
|
+
modelData: portletModel,
|
|
437
|
+
controller
|
|
438
|
+
};
|
|
439
|
+
if (!provider) {
|
|
440
|
+
return createVNode("div", null, [portletModel.portletType, ibiz.i18n.t("app.noSupport")]);
|
|
409
441
|
}
|
|
442
|
+
const providerComp = resolveComponent(provider.component);
|
|
443
|
+
return h(providerComp, {
|
|
444
|
+
...commonProps,
|
|
445
|
+
key: portletModel.id
|
|
446
|
+
});
|
|
410
447
|
};
|
|
411
448
|
return createVNode("div", {
|
|
412
449
|
"class": this.ns.b()
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ref, watch, watchEffect, onUnmounted } from 'vue';
|
|
2
|
-
import { defaultNamespace } from '../../node_modules/.pnpm/@ibiz-template_core@0.7.
|
|
2
|
+
import { defaultNamespace } from '../../node_modules/.pnpm/@ibiz-template_core@0.7.26_axios@1.6.8_lodash-es@4.17.21_qs@6.11.2_qx-util@0.4.8_ramda@0.29.1/node_modules/@ibiz-template/core/out/utils/namespace/namespace.mjs';
|
|
3
3
|
|
|
4
4
|
"use strict";
|
|
5
5
|
function useAppDRTab(c, controlRef, counterData) {
|
|
@@ -708,6 +708,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
708
708
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
709
709
|
} | undefined;
|
|
710
710
|
tag?: string | undefined;
|
|
711
|
+
uniqueTag?: string | undefined;
|
|
711
712
|
appId: string;
|
|
712
713
|
id?: string | undefined;
|
|
713
714
|
name?: string | undefined;
|
|
@@ -1565,6 +1566,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
1565
1566
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
1566
1567
|
} | undefined;
|
|
1567
1568
|
tag?: string | undefined;
|
|
1569
|
+
uniqueTag?: string | undefined;
|
|
1568
1570
|
appId: string;
|
|
1569
1571
|
id?: string | undefined;
|
|
1570
1572
|
name?: string | undefined;
|
|
@@ -2095,6 +2097,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
2095
2097
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
2096
2098
|
} | undefined;
|
|
2097
2099
|
tag?: string | undefined;
|
|
2100
|
+
uniqueTag?: string | undefined;
|
|
2098
2101
|
appId: string;
|
|
2099
2102
|
id?: string | undefined;
|
|
2100
2103
|
name?: string | undefined;
|
|
@@ -2775,6 +2778,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
2775
2778
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
2776
2779
|
} | undefined;
|
|
2777
2780
|
tag?: string | undefined;
|
|
2781
|
+
uniqueTag?: string | undefined;
|
|
2778
2782
|
appId: string;
|
|
2779
2783
|
id?: string | undefined;
|
|
2780
2784
|
name?: string | undefined;
|
|
@@ -3935,6 +3939,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
3935
3939
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
3936
3940
|
} | undefined;
|
|
3937
3941
|
tag?: string | undefined;
|
|
3942
|
+
uniqueTag?: string | undefined;
|
|
3938
3943
|
appId: string;
|
|
3939
3944
|
id?: string | undefined;
|
|
3940
3945
|
name?: string | undefined;
|
|
@@ -4705,6 +4710,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
4705
4710
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
4706
4711
|
} | undefined;
|
|
4707
4712
|
tag?: string | undefined;
|
|
4713
|
+
uniqueTag?: string | undefined;
|
|
4708
4714
|
appId: string;
|
|
4709
4715
|
id?: string | undefined;
|
|
4710
4716
|
name?: string | undefined;
|
|
@@ -5562,6 +5568,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
5562
5568
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
5563
5569
|
} | undefined;
|
|
5564
5570
|
tag?: string | undefined;
|
|
5571
|
+
uniqueTag?: string | undefined;
|
|
5565
5572
|
appId: string;
|
|
5566
5573
|
id?: string | undefined;
|
|
5567
5574
|
name?: string | undefined;
|
|
@@ -6092,6 +6099,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
6092
6099
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
6093
6100
|
} | undefined;
|
|
6094
6101
|
tag?: string | undefined;
|
|
6102
|
+
uniqueTag?: string | undefined;
|
|
6095
6103
|
appId: string;
|
|
6096
6104
|
id?: string | undefined;
|
|
6097
6105
|
name?: string | undefined;
|
|
@@ -6772,6 +6780,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
6772
6780
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
6773
6781
|
} | undefined;
|
|
6774
6782
|
tag?: string | undefined;
|
|
6783
|
+
uniqueTag?: string | undefined;
|
|
6775
6784
|
appId: string;
|
|
6776
6785
|
id?: string | undefined;
|
|
6777
6786
|
name?: string | undefined;
|
|
@@ -7204,6 +7213,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
7204
7213
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
7205
7214
|
} | undefined;
|
|
7206
7215
|
tag?: string | undefined;
|
|
7216
|
+
uniqueTag?: string | undefined;
|
|
7207
7217
|
appId: string;
|
|
7208
7218
|
id?: string | undefined;
|
|
7209
7219
|
name?: string | undefined;
|
|
@@ -8191,6 +8201,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
8191
8201
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
8192
8202
|
} | undefined;
|
|
8193
8203
|
tag?: string | undefined;
|
|
8204
|
+
uniqueTag?: string | undefined;
|
|
8194
8205
|
appId: string;
|
|
8195
8206
|
id?: string | undefined;
|
|
8196
8207
|
name?: string | undefined;
|
|
@@ -8961,6 +8972,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
8961
8972
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
8962
8973
|
} | undefined;
|
|
8963
8974
|
tag?: string | undefined;
|
|
8975
|
+
uniqueTag?: string | undefined;
|
|
8964
8976
|
appId: string;
|
|
8965
8977
|
id?: string | undefined;
|
|
8966
8978
|
name?: string | undefined;
|
|
@@ -9782,6 +9794,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
9782
9794
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
9783
9795
|
} | undefined;
|
|
9784
9796
|
tag?: string | undefined;
|
|
9797
|
+
uniqueTag?: string | undefined;
|
|
9785
9798
|
appId: string;
|
|
9786
9799
|
id?: string | undefined;
|
|
9787
9800
|
name?: string | undefined;
|
|
@@ -10312,6 +10325,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
10312
10325
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
10313
10326
|
} | undefined;
|
|
10314
10327
|
tag?: string | undefined;
|
|
10328
|
+
uniqueTag?: string | undefined;
|
|
10315
10329
|
appId: string;
|
|
10316
10330
|
id?: string | undefined;
|
|
10317
10331
|
name?: string | undefined;
|
|
@@ -10992,6 +11006,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
10992
11006
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
10993
11007
|
} | undefined;
|
|
10994
11008
|
tag?: string | undefined;
|
|
11009
|
+
uniqueTag?: string | undefined;
|
|
10995
11010
|
appId: string;
|
|
10996
11011
|
id?: string | undefined;
|
|
10997
11012
|
name?: string | undefined;
|
|
@@ -11400,6 +11415,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
11400
11415
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
11401
11416
|
} | undefined;
|
|
11402
11417
|
tag?: string | undefined;
|
|
11418
|
+
uniqueTag?: string | undefined;
|
|
11403
11419
|
appId: string;
|
|
11404
11420
|
id?: string | undefined;
|
|
11405
11421
|
name?: string | undefined;
|
|
@@ -11964,6 +11980,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
11964
11980
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
11965
11981
|
} | undefined;
|
|
11966
11982
|
tag?: string | undefined;
|
|
11983
|
+
uniqueTag?: string | undefined;
|
|
11967
11984
|
appId: string;
|
|
11968
11985
|
id?: string | undefined;
|
|
11969
11986
|
name?: string | undefined;
|
|
@@ -12821,6 +12838,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
12821
12838
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
12822
12839
|
} | undefined;
|
|
12823
12840
|
tag?: string | undefined;
|
|
12841
|
+
uniqueTag?: string | undefined;
|
|
12824
12842
|
appId: string;
|
|
12825
12843
|
id?: string | undefined;
|
|
12826
12844
|
name?: string | undefined;
|
|
@@ -13351,6 +13369,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
13351
13369
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
13352
13370
|
} | undefined;
|
|
13353
13371
|
tag?: string | undefined;
|
|
13372
|
+
uniqueTag?: string | undefined;
|
|
13354
13373
|
appId: string;
|
|
13355
13374
|
id?: string | undefined;
|
|
13356
13375
|
name?: string | undefined;
|
|
@@ -14031,6 +14050,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
14031
14050
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
14032
14051
|
} | undefined;
|
|
14033
14052
|
tag?: string | undefined;
|
|
14053
|
+
uniqueTag?: string | undefined;
|
|
14034
14054
|
appId: string;
|
|
14035
14055
|
id?: string | undefined;
|
|
14036
14056
|
name?: string | undefined;
|
|
@@ -15276,6 +15296,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
15276
15296
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
15277
15297
|
} | undefined;
|
|
15278
15298
|
tag?: string | undefined;
|
|
15299
|
+
uniqueTag?: string | undefined;
|
|
15279
15300
|
appId: string;
|
|
15280
15301
|
id?: string | undefined;
|
|
15281
15302
|
name?: string | undefined;
|
|
@@ -16283,6 +16304,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
16283
16304
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
16284
16305
|
} | undefined;
|
|
16285
16306
|
tag?: string | undefined;
|
|
16307
|
+
uniqueTag?: string | undefined;
|
|
16286
16308
|
appId: string;
|
|
16287
16309
|
id?: string | undefined;
|
|
16288
16310
|
name?: string | undefined;
|
|
@@ -17147,6 +17169,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
17147
17169
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
17148
17170
|
} | undefined;
|
|
17149
17171
|
tag?: string | undefined;
|
|
17172
|
+
uniqueTag?: string | undefined;
|
|
17150
17173
|
appId: string;
|
|
17151
17174
|
id?: string | undefined;
|
|
17152
17175
|
name?: string | undefined;
|
|
@@ -17687,6 +17710,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
17687
17710
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
17688
17711
|
} | undefined;
|
|
17689
17712
|
tag?: string | undefined;
|
|
17713
|
+
uniqueTag?: string | undefined;
|
|
17690
17714
|
appId: string;
|
|
17691
17715
|
id?: string | undefined;
|
|
17692
17716
|
name?: string | undefined;
|
|
@@ -18367,6 +18391,7 @@ export declare const RepeaterGrid: import("vue").DefineComponent<{
|
|
|
18367
18391
|
propertyIsEnumerable: (v: PropertyKey) => boolean;
|
|
18368
18392
|
} | undefined;
|
|
18369
18393
|
tag?: string | undefined;
|
|
18394
|
+
uniqueTag?: string | undefined;
|
|
18370
18395
|
appId: string;
|
|
18371
18396
|
id?: string | undefined;
|
|
18372
18397
|
name?: string | undefined;
|
|
@@ -74,6 +74,14 @@ export declare function useAppGridBase(c: GridController, props: IGridProps): {
|
|
|
74
74
|
columns: TableColumnCtx<IData>[];
|
|
75
75
|
data: IData[];
|
|
76
76
|
}) => string[];
|
|
77
|
+
spanMethod: ({ row, column, rowIndex, columnIndex, }: {
|
|
78
|
+
row: IData;
|
|
79
|
+
column: IData;
|
|
80
|
+
rowIndex: number;
|
|
81
|
+
columnIndex: number;
|
|
82
|
+
}) => IData | void;
|
|
83
|
+
cellMouseEnter: (row: IData, column: IData, cell: HTMLTableCellElement, event: Event) => void;
|
|
84
|
+
cellMouseLeave: (row: IData, column: IData, cell: HTMLTableCellElement, event: Event) => void;
|
|
77
85
|
};
|
|
78
86
|
/**
|
|
79
87
|
* 监听表格头部高度变化,计算css变量
|