@fecp/designer 5.5.65 → 5.5.66
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/es/designer/package.json.mjs +1 -1
- package/es/designer/src/packages/dialog/useDialogDialog.mjs +1 -1
- package/es/designer/src/packages/dialogGlobal/index.vue.mjs +1 -1
- package/es/designer/src/packages/dialogGlobal/useDialogGlobalDialog.mjs +1 -1
- package/es/designer/src/packages/form/property/widgets.vue.mjs +2 -2
- package/es/designer.css +496 -37
- package/es/packages/mobile/index.mjs +6 -0
- package/es/packages/mobile/src/api/index.mjs +8 -0
- package/es/packages/mobile/src/components/all.mjs +4 -0
- package/es/packages/mobile/src/components/base/card/Card.vue.mjs +2 -2
- package/es/packages/mobile/src/components/dataDisplay/dataStat/DataStat.vue.mjs +14 -0
- package/es/packages/mobile/src/components/dataDisplay/dataStat/index.mjs +10 -0
- package/es/packages/mobile/src/components/dataDisplay/menuGrid/MenuGrid.vue.mjs +123 -0
- package/es/packages/mobile/src/components/dataDisplay/menuGrid/index.mjs +7 -0
- package/es/packages/mobile/src/components/dataDisplay/noticeBar/NoticeBar.vue.mjs +98 -16
- package/es/packages/mobile/src/components/dataDisplay/table/Table.vue.mjs +2 -4
- package/es/packages/mobile/src/components/feedback/quickFilter/QuickFilter.vue.mjs +14 -15
- package/es/packages/mobile/src/components/form/search/Search.vue.mjs +4 -4
- package/es/packages/mobile/src/components/navigation/actionBar/ActionBar.vue.mjs +1 -1
- package/es/packages/mobile/src/components/navigation/navBar/NavBar.vue.mjs +13 -3
- package/es/packages/mobile/src/components/navigation/navBar/index.mjs +2 -2
- package/es/packages/mobile/src/components/navigation/tabbar/Tabbar.vue.mjs +8 -4
- package/es/packages/mobile/src/components/navigation/tabbar/index.mjs +2 -2
- package/es/packages/mobile/src/index.vue.mjs +138 -0
- package/es/packages/mobile/src/page.vue.mjs +117 -0
- package/es/packages/mobile/src/utils/eventBus.mjs +5 -0
- package/es/packages/mobile/src/utils/pageHistory.mjs +111 -0
- package/es/packages/vue/src/components/forms/form/validation.mjs +1 -1
- package/es/packages/vue/src/utils/parseFilterConfig.mjs +25 -0
- package/lib/designer/package.json.js +1 -1
- package/lib/designer/src/packages/dialog/useDialogDialog.js +1 -1
- package/lib/designer/src/packages/dialogGlobal/index.vue.js +1 -1
- package/lib/designer/src/packages/dialogGlobal/useDialogGlobalDialog.js +1 -1
- package/lib/designer/src/packages/form/property/widgets.vue.js +2 -2
- package/lib/designer.css +496 -37
- package/lib/packages/mobile/index.js +94 -88
- package/lib/packages/mobile/src/api/index.js +8 -0
- package/lib/packages/mobile/src/components/all.js +92 -88
- package/lib/packages/mobile/src/components/base/card/Card.vue.js +2 -2
- package/lib/packages/mobile/src/components/dataDisplay/dataStat/DataStat.vue.js +14 -0
- package/lib/packages/mobile/src/components/dataDisplay/dataStat/index.js +10 -0
- package/lib/packages/mobile/src/components/dataDisplay/menuGrid/MenuGrid.vue.js +123 -0
- package/lib/packages/mobile/src/components/dataDisplay/menuGrid/index.js +7 -0
- package/lib/packages/mobile/src/components/dataDisplay/noticeBar/NoticeBar.vue.js +97 -15
- package/lib/packages/mobile/src/components/dataDisplay/table/Table.vue.js +2 -4
- package/lib/packages/mobile/src/components/feedback/quickFilter/QuickFilter.vue.js +13 -14
- package/lib/packages/mobile/src/components/form/search/Search.vue.js +4 -4
- package/lib/packages/mobile/src/components/navigation/actionBar/ActionBar.vue.js +1 -1
- package/lib/packages/mobile/src/components/navigation/navBar/NavBar.vue.js +13 -3
- package/lib/packages/mobile/src/components/navigation/tabbar/Tabbar.vue.js +8 -4
- package/lib/packages/mobile/src/index.vue.js +138 -0
- package/lib/packages/mobile/src/page.vue.js +117 -0
- package/lib/packages/mobile/src/utils/eventBus.js +5 -0
- package/lib/packages/mobile/src/utils/pageHistory.js +111 -0
- package/lib/packages/vue/src/components/forms/form/validation.js +1 -1
- package/lib/packages/vue/src/utils/parseFilterConfig.js +25 -0
- package/package.json +1 -1
|
@@ -4,22 +4,104 @@ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toString
|
|
|
4
4
|
;/* empty css */
|
|
5
5
|
;/* empty css */
|
|
6
6
|
;/* empty css */
|
|
7
|
+
;/* empty css */
|
|
8
|
+
;/* empty css */
|
|
7
9
|
const Vue = require("vue");
|
|
10
|
+
;/* empty css */
|
|
8
11
|
const _pluginVue_exportHelper = require("../../../../../../_virtual/_plugin-vue_export-helper.js");
|
|
9
12
|
const index = require("../../../../node_modules/vant/es/notice-bar/index.js");
|
|
10
|
-
const
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
13
|
+
const index$1 = require("../../../../node_modules/vant/es/swipe/index.js");
|
|
14
|
+
const index$2 = require("../../../../node_modules/vant/es/swipe-item/index.js");
|
|
15
|
+
const _hoisted_1 = { class: "notice-wrap" };
|
|
16
|
+
const _hoisted_2 = { class: "notice-label" };
|
|
17
|
+
const _hoisted_3 = ["src"];
|
|
18
|
+
const _hoisted_4 = {
|
|
19
|
+
key: 1,
|
|
20
|
+
class: "label-text"
|
|
21
|
+
};
|
|
22
|
+
const _hoisted_5 = { class: "notice-title" };
|
|
23
|
+
const _hoisted_6 = { class: "title-text" };
|
|
24
|
+
const _hoisted_7 = { class: "notice-time" };
|
|
25
|
+
const _sfc_main = {
|
|
26
|
+
__name: "NoticeBar",
|
|
27
|
+
props: {
|
|
28
|
+
labelImage: {
|
|
29
|
+
type: String,
|
|
30
|
+
default: ""
|
|
31
|
+
},
|
|
32
|
+
noticeList: {
|
|
33
|
+
type: Array,
|
|
34
|
+
default: () => [
|
|
35
|
+
{
|
|
36
|
+
title: "集团公告 客研体系和品牌升级项目定义会...",
|
|
37
|
+
time: "2020-09-02 11:31"
|
|
38
|
+
},
|
|
39
|
+
{
|
|
40
|
+
title: "关于中秋节放假安排的通知...",
|
|
41
|
+
time: "2020-09-01 09:00"
|
|
42
|
+
}
|
|
43
|
+
]
|
|
44
|
+
}
|
|
45
|
+
},
|
|
46
|
+
setup(__props) {
|
|
47
|
+
return (_ctx, _cache) => {
|
|
48
|
+
const _component_van_swipe_item = index$2.SwipeItem;
|
|
49
|
+
const _component_van_swipe = index$1.Swipe;
|
|
50
|
+
const _component_van_notice_bar = index.NoticeBar;
|
|
51
|
+
return Vue.openBlock(), Vue.createElementBlock("div", _hoisted_1, [
|
|
52
|
+
Vue.createVNode(_component_van_notice_bar, {
|
|
53
|
+
scrollable: false,
|
|
54
|
+
class: "notice-bar",
|
|
55
|
+
background: "#FFF"
|
|
56
|
+
}, {
|
|
57
|
+
"left-icon": Vue.withCtx(() => [
|
|
58
|
+
Vue.createElementVNode("div", _hoisted_2, [
|
|
59
|
+
Vue.renderSlot(_ctx.$slots, "label-image", {}, () => [
|
|
60
|
+
__props.labelImage ? (Vue.openBlock(), Vue.createElementBlock("img", {
|
|
61
|
+
key: 0,
|
|
62
|
+
src: __props.labelImage,
|
|
63
|
+
class: "label-img"
|
|
64
|
+
}, null, 8, _hoisted_3)) : (Vue.openBlock(), Vue.createElementBlock("div", _hoisted_4, _cache[0] || (_cache[0] = [
|
|
65
|
+
Vue.createElementVNode("span", { class: "text-top" }, "公告", -1),
|
|
66
|
+
Vue.createElementVNode("span", { class: "text-bottom" }, "事项", -1)
|
|
67
|
+
])))
|
|
68
|
+
], true)
|
|
69
|
+
]),
|
|
70
|
+
_cache[1] || (_cache[1] = Vue.createElementVNode("div", { class: "divider" }, null, -1))
|
|
71
|
+
]),
|
|
72
|
+
default: Vue.withCtx(() => [
|
|
73
|
+
Vue.createVNode(_component_van_swipe, {
|
|
74
|
+
vertical: "",
|
|
75
|
+
class: "notice-swipe",
|
|
76
|
+
autoplay: 3e3,
|
|
77
|
+
touchable: false,
|
|
78
|
+
"show-indicators": false
|
|
79
|
+
}, {
|
|
80
|
+
default: Vue.withCtx(() => [
|
|
81
|
+
(Vue.openBlock(true), Vue.createElementBlock(Vue.Fragment, null, Vue.renderList(__props.noticeList, (item, index2) => {
|
|
82
|
+
return Vue.openBlock(), Vue.createBlock(_component_van_swipe_item, {
|
|
83
|
+
key: index2,
|
|
84
|
+
class: "notice-item"
|
|
85
|
+
}, {
|
|
86
|
+
default: Vue.withCtx(() => [
|
|
87
|
+
Vue.createElementVNode("div", _hoisted_5, [
|
|
88
|
+
_cache[2] || (_cache[2] = Vue.createElementVNode("span", { class: "dot" }, null, -1)),
|
|
89
|
+
Vue.createElementVNode("span", _hoisted_6, Vue.toDisplayString(item.title), 1)
|
|
90
|
+
]),
|
|
91
|
+
Vue.createElementVNode("div", _hoisted_7, Vue.toDisplayString(item.time), 1)
|
|
92
|
+
]),
|
|
93
|
+
_: 2
|
|
94
|
+
}, 1024);
|
|
95
|
+
}), 128))
|
|
96
|
+
]),
|
|
97
|
+
_: 1
|
|
98
|
+
})
|
|
99
|
+
]),
|
|
100
|
+
_: 3
|
|
101
|
+
})
|
|
102
|
+
]);
|
|
103
|
+
};
|
|
104
|
+
}
|
|
105
|
+
};
|
|
106
|
+
const _NoticeBar = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-2b72b4f6"]]);
|
|
25
107
|
exports.default = _NoticeBar;
|
|
@@ -438,9 +438,7 @@ const _sfc_main = {
|
|
|
438
438
|
}
|
|
439
439
|
}
|
|
440
440
|
const quickFilterConfig = Vue.computed(() => {
|
|
441
|
-
const list = props.columns.
|
|
442
|
-
return props.quickFilter.includes(item.fieldName);
|
|
443
|
-
});
|
|
441
|
+
const list = props.quickFilter.map((fieldName) => props.columns.find((col) => col.fieldName == fieldName)).filter(Boolean);
|
|
444
442
|
return list;
|
|
445
443
|
});
|
|
446
444
|
return (_ctx, _cache) => {
|
|
@@ -578,5 +576,5 @@ const _sfc_main = {
|
|
|
578
576
|
};
|
|
579
577
|
}
|
|
580
578
|
};
|
|
581
|
-
const _Table = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
579
|
+
const _Table = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-ee91bb34"]]);
|
|
582
580
|
exports.default = _Table;
|
|
@@ -42,7 +42,6 @@ const _sfc_main = {
|
|
|
42
42
|
setup(__props, { emit: __emit }) {
|
|
43
43
|
const props = __props;
|
|
44
44
|
const emit = __emit;
|
|
45
|
-
const filterDataComputed = Vue.computed(() => props.filterData);
|
|
46
45
|
const activeSelections = Vue.ref({});
|
|
47
46
|
const confirmedSelections = Vue.ref({});
|
|
48
47
|
const itemRefs = Vue.ref({});
|
|
@@ -58,7 +57,7 @@ const _sfc_main = {
|
|
|
58
57
|
if (!activeSelections.value[fieldName]) {
|
|
59
58
|
activeSelections.value[fieldName] = [];
|
|
60
59
|
}
|
|
61
|
-
const filter =
|
|
60
|
+
const filter = props.filterData.find((f) => f.fieldName === fieldName);
|
|
62
61
|
const isMultiple = (filter == null ? void 0 : filter.dataType) === "multiple";
|
|
63
62
|
if (isMultiple) {
|
|
64
63
|
const idx = activeSelections.value[fieldName].indexOf(value);
|
|
@@ -93,13 +92,13 @@ const _sfc_main = {
|
|
|
93
92
|
};
|
|
94
93
|
const allFilterRef = Vue.ref(null);
|
|
95
94
|
const resetAllFilters = () => {
|
|
96
|
-
|
|
95
|
+
props.filterData.forEach((filter) => {
|
|
97
96
|
activeSelections.value[filter.fieldName] = [];
|
|
98
97
|
});
|
|
99
98
|
};
|
|
100
99
|
const confirmAllFilters = () => {
|
|
101
100
|
var _a;
|
|
102
|
-
|
|
101
|
+
props.filterData.forEach((filter) => {
|
|
103
102
|
confirmedSelections.value[filter.fieldName] = [
|
|
104
103
|
...activeSelections.value[filter.fieldName] || []
|
|
105
104
|
];
|
|
@@ -114,7 +113,7 @@ const _sfc_main = {
|
|
|
114
113
|
};
|
|
115
114
|
const emitChange = () => {
|
|
116
115
|
const result = [];
|
|
117
|
-
|
|
116
|
+
props.filterData.forEach((filter) => {
|
|
118
117
|
const values = confirmedSelections.value[filter.fieldName] || [];
|
|
119
118
|
if (values.length > 0) {
|
|
120
119
|
result.push({
|
|
@@ -131,15 +130,15 @@ const _sfc_main = {
|
|
|
131
130
|
const _component_van_button = index$2.Button;
|
|
132
131
|
const _component_van_dropdown_item = index$1.DropdownItem;
|
|
133
132
|
const _component_van_dropdown_menu = index.DropdownMenu;
|
|
134
|
-
return
|
|
133
|
+
return __props.filterData.length > 0 ? (Vue.openBlock(), Vue.createBlock(_component_van_dropdown_menu, {
|
|
135
134
|
key: 0,
|
|
136
135
|
"auto-locate": "",
|
|
137
136
|
class: "fec-quick-filter"
|
|
138
137
|
}, {
|
|
139
138
|
default: Vue.withCtx(() => [
|
|
140
|
-
(Vue.openBlock(true), Vue.createElementBlock(Vue.Fragment, null, Vue.renderList(
|
|
139
|
+
(Vue.openBlock(true), Vue.createElementBlock(Vue.Fragment, null, Vue.renderList(__props.filterData, (filter, index2) => {
|
|
141
140
|
return Vue.openBlock(), Vue.createBlock(_component_van_dropdown_item, {
|
|
142
|
-
key: filter.
|
|
141
|
+
key: `${filter.label}-${index2}`,
|
|
143
142
|
ref_for: true,
|
|
144
143
|
ref: (el) => Vue.unref(itemRefs)[filter.fieldName] = el,
|
|
145
144
|
onOpen: ($event) => dropdownItemOpen(filter.fieldName)
|
|
@@ -187,7 +186,7 @@ const _sfc_main = {
|
|
|
187
186
|
_: 2
|
|
188
187
|
}, 1032, ["onOpen"]);
|
|
189
188
|
}), 128)),
|
|
190
|
-
|
|
189
|
+
__props.filterData.length > 0 ? (Vue.openBlock(), Vue.createBlock(_component_van_dropdown_item, {
|
|
191
190
|
key: 0,
|
|
192
191
|
ref_key: "allFilterRef",
|
|
193
192
|
ref: allFilterRef,
|
|
@@ -195,16 +194,16 @@ const _sfc_main = {
|
|
|
195
194
|
}, {
|
|
196
195
|
default: Vue.withCtx(() => [
|
|
197
196
|
Vue.createElementVNode("div", _hoisted_7, [
|
|
198
|
-
(Vue.openBlock(true), Vue.createElementBlock(Vue.Fragment, null, Vue.renderList(
|
|
197
|
+
(Vue.openBlock(true), Vue.createElementBlock(Vue.Fragment, null, Vue.renderList(__props.filterData, (filter, index2) => {
|
|
199
198
|
return Vue.openBlock(), Vue.createElementBlock("div", {
|
|
200
|
-
key: filter.
|
|
199
|
+
key: `all-${filter.label}-${index2}`,
|
|
201
200
|
class: "filter-group"
|
|
202
201
|
}, [
|
|
203
202
|
Vue.createElementVNode("h3", _hoisted_8, Vue.toDisplayString(filter.label), 1),
|
|
204
203
|
Vue.createElementVNode("div", _hoisted_9, [
|
|
205
|
-
(Vue.openBlock(true), Vue.createElementBlock(Vue.Fragment, null, Vue.renderList(filter.options, (item) => {
|
|
204
|
+
(Vue.openBlock(true), Vue.createElementBlock(Vue.Fragment, null, Vue.renderList(filter.options, (item, optIndex) => {
|
|
206
205
|
return Vue.openBlock(), Vue.createElementBlock("div", {
|
|
207
|
-
key:
|
|
206
|
+
key: `${filter.label}-${item.value}-${optIndex}`,
|
|
208
207
|
class: Vue.normalizeClass(["tag-item", {
|
|
209
208
|
active: isOptionSelected(filter.fieldName, item.value)
|
|
210
209
|
}]),
|
|
@@ -245,5 +244,5 @@ const _sfc_main = {
|
|
|
245
244
|
};
|
|
246
245
|
}
|
|
247
246
|
};
|
|
248
|
-
const QuickFilter = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
247
|
+
const QuickFilter = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-3e7ddf36"]]);
|
|
249
248
|
exports.default = QuickFilter;
|
|
@@ -49,14 +49,14 @@ const _sfc_main = {
|
|
|
49
49
|
emit("filterChange", result);
|
|
50
50
|
}
|
|
51
51
|
const filterData = Vue.ref([]);
|
|
52
|
+
const fieldDataSources = /* @__PURE__ */ new Set();
|
|
53
|
+
const dictionaryKeys = /* @__PURE__ */ new Set();
|
|
54
|
+
const dataSourceOptions = Vue.ref({});
|
|
55
|
+
const dictionaryOptions = Vue.ref({});
|
|
52
56
|
const loadFieldDataSources = async () => {
|
|
53
57
|
var _a, _b;
|
|
54
58
|
const optionsDatas = [];
|
|
55
59
|
const fields = props.filterConfig;
|
|
56
|
-
const fieldDataSources = /* @__PURE__ */ new Set();
|
|
57
|
-
const dictionaryKeys = /* @__PURE__ */ new Set();
|
|
58
|
-
const dataSourceOptions = Vue.ref({});
|
|
59
|
-
const dictionaryOptions = Vue.ref({});
|
|
60
60
|
for (const component of fields) {
|
|
61
61
|
const { optionSource, dataSourceValue, dictionaryValue } = component.optionConfig;
|
|
62
62
|
if (optionSource === "dataSource" && dataSourceValue) {
|
|
@@ -38,5 +38,5 @@ const _sfc_main = {
|
|
|
38
38
|
};
|
|
39
39
|
}
|
|
40
40
|
};
|
|
41
|
-
const _ActionBar = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
41
|
+
const _ActionBar = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-ac26522e"]]);
|
|
42
42
|
exports.default = _ActionBar;
|
|
@@ -5,6 +5,10 @@ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toString
|
|
|
5
5
|
;/* empty css */
|
|
6
6
|
;/* empty css */
|
|
7
7
|
const Vue = require("vue");
|
|
8
|
+
const pageHistory = require("../../../utils/pageHistory.js");
|
|
9
|
+
const eventBus = require("../../../utils/eventBus.js");
|
|
10
|
+
;/* empty css */
|
|
11
|
+
const _pluginVue_exportHelper = require("../../../../../../_virtual/_plugin-vue_export-helper.js");
|
|
8
12
|
const index = require("../../../../node_modules/vant/es/nav-bar/index.js");
|
|
9
13
|
const _sfc_main = {
|
|
10
14
|
__name: "NavBar",
|
|
@@ -27,7 +31,12 @@ const _sfc_main = {
|
|
|
27
31
|
}
|
|
28
32
|
},
|
|
29
33
|
setup(__props) {
|
|
30
|
-
const onClickLeft = () =>
|
|
34
|
+
const onClickLeft = () => {
|
|
35
|
+
const prevPage = pageHistory.pageHistory.back();
|
|
36
|
+
if (prevPage) {
|
|
37
|
+
eventBus.default.emit("loadPage", prevPage.id);
|
|
38
|
+
}
|
|
39
|
+
};
|
|
31
40
|
return (_ctx, _cache) => {
|
|
32
41
|
const _component_van_nav_bar = index.NavBar;
|
|
33
42
|
return Vue.openBlock(), Vue.createBlock(_component_van_nav_bar, Vue.mergeProps(_ctx.$attrs, {
|
|
@@ -43,7 +52,7 @@ const _sfc_main = {
|
|
|
43
52
|
return {
|
|
44
53
|
name: key,
|
|
45
54
|
fn: Vue.withCtx(() => [
|
|
46
|
-
Vue.renderSlot(_ctx.$slots, key)
|
|
55
|
+
Vue.renderSlot(_ctx.$slots, key, {}, void 0, true)
|
|
47
56
|
])
|
|
48
57
|
};
|
|
49
58
|
})
|
|
@@ -51,4 +60,5 @@ const _sfc_main = {
|
|
|
51
60
|
};
|
|
52
61
|
}
|
|
53
62
|
};
|
|
54
|
-
|
|
63
|
+
const _NavBar = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-f6340561"]]);
|
|
64
|
+
exports.default = _NavBar;
|
|
@@ -6,6 +6,8 @@ Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toString
|
|
|
6
6
|
;/* empty css */
|
|
7
7
|
;/* empty css */
|
|
8
8
|
const Vue = require("vue");
|
|
9
|
+
;/* empty css */
|
|
10
|
+
const _pluginVue_exportHelper = require("../../../../../../_virtual/_plugin-vue_export-helper.js");
|
|
9
11
|
const index = require("../../../../node_modules/vant/es/tabbar/index.js");
|
|
10
12
|
const index$1 = require("../../../../node_modules/vant/es/tabbar-item/index.js");
|
|
11
13
|
const _sfc_main = {
|
|
@@ -44,19 +46,21 @@ const _sfc_main = {
|
|
|
44
46
|
default: Vue.withCtx(() => [
|
|
45
47
|
(Vue.openBlock(true), Vue.createElementBlock(Vue.Fragment, null, Vue.renderList(__props.tabbarOptions, (item) => {
|
|
46
48
|
return Vue.openBlock(), Vue.createBlock(_component_van_tabbar_item, {
|
|
47
|
-
icon: item.icon
|
|
49
|
+
icon: item.icon,
|
|
50
|
+
name: item.pageId
|
|
48
51
|
}, {
|
|
49
52
|
default: Vue.withCtx(() => [
|
|
50
53
|
Vue.createTextVNode(Vue.toDisplayString(item.title), 1)
|
|
51
54
|
]),
|
|
52
55
|
_: 2
|
|
53
|
-
}, 1032, ["icon"]);
|
|
56
|
+
}, 1032, ["icon", "name"]);
|
|
54
57
|
}), 256)),
|
|
55
|
-
Vue.renderSlot(_ctx.$slots, "default")
|
|
58
|
+
Vue.renderSlot(_ctx.$slots, "default", {}, void 0, true)
|
|
56
59
|
]),
|
|
57
60
|
_: 3
|
|
58
61
|
}, 16, ["modelValue"]);
|
|
59
62
|
};
|
|
60
63
|
}
|
|
61
64
|
};
|
|
62
|
-
|
|
65
|
+
const _Tabbar = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-04abcf62"]]);
|
|
66
|
+
exports.default = _Tabbar;
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
+
require("../../../node_modules/element-plus/es/index.js");
|
|
4
|
+
;/* empty css */
|
|
5
|
+
;/* empty css */
|
|
6
|
+
;/* empty css */
|
|
7
|
+
;/* empty css */
|
|
8
|
+
;/* empty css */
|
|
9
|
+
;/* empty css */
|
|
10
|
+
;/* empty css */
|
|
11
|
+
;/* empty css */
|
|
12
|
+
const Vue = require("vue");
|
|
13
|
+
const page = require("./page.vue.js");
|
|
14
|
+
const index$2 = require("./api/index.js");
|
|
15
|
+
const eventBus = require("./utils/eventBus.js");
|
|
16
|
+
const pageHistory = require("./utils/pageHistory.js");
|
|
17
|
+
;/* empty css */
|
|
18
|
+
;/* empty css */
|
|
19
|
+
;/* empty css */
|
|
20
|
+
const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
|
|
21
|
+
const index = require("../../../node_modules/element-plus/es/components/container/index.js");
|
|
22
|
+
const index$3 = require("../../../node_modules/element-plus/es/components/message/index.js");
|
|
23
|
+
const index$1 = require("../node_modules/vant/es/empty/index.js");
|
|
24
|
+
const _sfc_main = {
|
|
25
|
+
__name: "index",
|
|
26
|
+
props: {
|
|
27
|
+
appId: {
|
|
28
|
+
type: String,
|
|
29
|
+
default: ""
|
|
30
|
+
}
|
|
31
|
+
},
|
|
32
|
+
setup(__props) {
|
|
33
|
+
const props = __props;
|
|
34
|
+
const currentInstance = Vue.getCurrentInstance();
|
|
35
|
+
const ctx = currentInstance.proxy;
|
|
36
|
+
const pageList = Vue.ref({});
|
|
37
|
+
const layoutData = Vue.ref([]);
|
|
38
|
+
const configLoading = Vue.ref(true);
|
|
39
|
+
const loadConfig = async () => {
|
|
40
|
+
var _a, _b;
|
|
41
|
+
if (!props.appId) {
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
configLoading.value = true;
|
|
45
|
+
try {
|
|
46
|
+
let option = await index$2.default.getAppById(ctx.$http, props.appId);
|
|
47
|
+
pageList.value = ((_a = JSON.parse(option.pageConfig)) == null ? void 0 : _a.pageConfig) || [];
|
|
48
|
+
let homePage = pageList.value.find((page2) => page2.isHome);
|
|
49
|
+
if (!homePage) {
|
|
50
|
+
homePage = (_b = pageList.value) == null ? void 0 : _b[0];
|
|
51
|
+
}
|
|
52
|
+
console.log("🚀 ~ pageList ~ pageList.value:", pageList.value);
|
|
53
|
+
loadPage(homePage);
|
|
54
|
+
pageHistory.pageHistory.init(homePage);
|
|
55
|
+
} catch (error) {
|
|
56
|
+
console.error("加载配置失败:", error);
|
|
57
|
+
index$3.ElMessage.error("加载配置失败");
|
|
58
|
+
} finally {
|
|
59
|
+
configLoading.value = false;
|
|
60
|
+
}
|
|
61
|
+
};
|
|
62
|
+
const currentPage = Vue.ref({});
|
|
63
|
+
function loadPage(page2) {
|
|
64
|
+
currentPage.value = { ...page2 };
|
|
65
|
+
layoutData.value = [...page2.layoutData].sort((a, b) => {
|
|
66
|
+
if (a.y !== b.y) {
|
|
67
|
+
return a.y - b.y;
|
|
68
|
+
}
|
|
69
|
+
return a.x - b.x;
|
|
70
|
+
});
|
|
71
|
+
layoutData.value.forEach((item) => item.isResizable = false);
|
|
72
|
+
}
|
|
73
|
+
function findPageById(pageList2, pageId) {
|
|
74
|
+
for (const item of pageList2) {
|
|
75
|
+
if (item.id == pageId) {
|
|
76
|
+
return item;
|
|
77
|
+
}
|
|
78
|
+
if (item.children && item.children.length > 0) {
|
|
79
|
+
const found = findPageById(item.children, pageId);
|
|
80
|
+
if (found) {
|
|
81
|
+
found.parentPage = item;
|
|
82
|
+
return found;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
return null;
|
|
87
|
+
}
|
|
88
|
+
const routePage = Vue.ref(null);
|
|
89
|
+
eventBus.default.on("loadPage", (pageId) => {
|
|
90
|
+
var _a;
|
|
91
|
+
if (((_a = currentPage.value) == null ? void 0 : _a.id) == pageId) {
|
|
92
|
+
return;
|
|
93
|
+
}
|
|
94
|
+
const targetPage = findPageById(pageList.value, pageId);
|
|
95
|
+
if (targetPage) {
|
|
96
|
+
if (targetPage.parentPage) {
|
|
97
|
+
currentPage.value = targetPage.parentPage;
|
|
98
|
+
routePage.value = targetPage;
|
|
99
|
+
} else {
|
|
100
|
+
currentPage.value = targetPage;
|
|
101
|
+
routePage.value = null;
|
|
102
|
+
}
|
|
103
|
+
pageHistory.pageHistory.push(targetPage);
|
|
104
|
+
} else {
|
|
105
|
+
currentPage.value = null;
|
|
106
|
+
routePage.value = null;
|
|
107
|
+
}
|
|
108
|
+
});
|
|
109
|
+
Vue.onMounted(() => {
|
|
110
|
+
loadConfig();
|
|
111
|
+
});
|
|
112
|
+
return (_ctx, _cache) => {
|
|
113
|
+
const _component_van_empty = index$1.Empty;
|
|
114
|
+
const _component_el_container = index.ElContainer;
|
|
115
|
+
return !Vue.unref(configLoading) ? (Vue.openBlock(), Vue.createBlock(_component_el_container, {
|
|
116
|
+
key: 0,
|
|
117
|
+
direction: "vertical",
|
|
118
|
+
class: "fec-mobile-app",
|
|
119
|
+
ref: "fecMobileAppRef"
|
|
120
|
+
}, {
|
|
121
|
+
default: Vue.withCtx(() => [
|
|
122
|
+
Vue.unref(currentPage) ? (Vue.openBlock(), Vue.createBlock(Vue.unref(page.default), {
|
|
123
|
+
key: 0,
|
|
124
|
+
currentPage: Vue.unref(currentPage),
|
|
125
|
+
routePage: Vue.unref(routePage)
|
|
126
|
+
}, null, 8, ["currentPage", "routePage"])) : (Vue.openBlock(), Vue.createBlock(_component_van_empty, {
|
|
127
|
+
key: 1,
|
|
128
|
+
image: "search",
|
|
129
|
+
description: "页面找不到了"
|
|
130
|
+
}))
|
|
131
|
+
]),
|
|
132
|
+
_: 1
|
|
133
|
+
}, 512)) : Vue.createCommentVNode("", true);
|
|
134
|
+
};
|
|
135
|
+
}
|
|
136
|
+
};
|
|
137
|
+
const MobileApp = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-78e0cbef"]]);
|
|
138
|
+
exports.default = MobileApp;
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
+
const Vue = require("vue");
|
|
4
|
+
require("../../../node_modules/grid-layout-plus/es/index.js");
|
|
5
|
+
const all = require("./components/all.js");
|
|
6
|
+
;/* empty css */
|
|
7
|
+
const _pluginVue_exportHelper = require("../../../_virtual/_plugin-vue_export-helper.js");
|
|
8
|
+
const gridLayout_vue = require("../../../node_modules/grid-layout-plus/es/components/grid-layout.vue.js");
|
|
9
|
+
const _hoisted_1 = { class: "grid-wrapper no-scrollbar" };
|
|
10
|
+
const _hoisted_2 = { class: "component-content" };
|
|
11
|
+
const colNum = 24;
|
|
12
|
+
const rowHeight = 10;
|
|
13
|
+
const _sfc_main = {
|
|
14
|
+
__name: "page",
|
|
15
|
+
props: {
|
|
16
|
+
currentPage: {
|
|
17
|
+
type: Object,
|
|
18
|
+
required: true
|
|
19
|
+
},
|
|
20
|
+
routePage: {
|
|
21
|
+
type: Object
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
setup(__props) {
|
|
25
|
+
const props = __props;
|
|
26
|
+
const formData = Vue.ref({});
|
|
27
|
+
function getComp(type) {
|
|
28
|
+
return all[type];
|
|
29
|
+
}
|
|
30
|
+
const layoutData = Vue.computed(() => {
|
|
31
|
+
var _a;
|
|
32
|
+
if (Array.isArray(props.currentPage.layoutData)) {
|
|
33
|
+
return ((_a = props.currentPage.layoutData) == null ? void 0 : _a.map((item) => {
|
|
34
|
+
item.isResizable = false;
|
|
35
|
+
return item;
|
|
36
|
+
})) || [];
|
|
37
|
+
}
|
|
38
|
+
return props.currentPage.layoutData;
|
|
39
|
+
});
|
|
40
|
+
const tabbarActive = Vue.ref(0);
|
|
41
|
+
const childPage = Vue.ref(null);
|
|
42
|
+
function onTabbarChange(pageId) {
|
|
43
|
+
if (!pageId) {
|
|
44
|
+
return;
|
|
45
|
+
}
|
|
46
|
+
const page = props.currentPage.children.find((item) => item.id == pageId);
|
|
47
|
+
if (!page) ;
|
|
48
|
+
else {
|
|
49
|
+
childPage.value = page;
|
|
50
|
+
}
|
|
51
|
+
console.log("🚀 ~ onTabbarChange ~ page:", page);
|
|
52
|
+
}
|
|
53
|
+
Vue.onMounted(() => {
|
|
54
|
+
if (props.currentPage.footerType == "tabbar") {
|
|
55
|
+
tabbarActive.value = props.currentPage.tabbarConfig.tabbarOptions[0].pageId;
|
|
56
|
+
onTabbarChange(tabbarActive.value);
|
|
57
|
+
}
|
|
58
|
+
});
|
|
59
|
+
return (_ctx, _cache) => {
|
|
60
|
+
const _component_FecMobileNavBar = Vue.resolveComponent("FecMobileNavBar");
|
|
61
|
+
const _component_page = Vue.resolveComponent("page", true);
|
|
62
|
+
const _component_FecMobileMenuGrid = Vue.resolveComponent("FecMobileMenuGrid");
|
|
63
|
+
const _component_FecMobileNoticeBar = Vue.resolveComponent("FecMobileNoticeBar");
|
|
64
|
+
const _component_FecMobileDataStat = Vue.resolveComponent("FecMobileDataStat");
|
|
65
|
+
const _component_FecMobileTabbar = Vue.resolveComponent("FecMobileTabbar");
|
|
66
|
+
const _component_FecMobileActionBar = Vue.resolveComponent("FecMobileActionBar");
|
|
67
|
+
return Vue.openBlock(), Vue.createElementBlock(Vue.Fragment, null, [
|
|
68
|
+
__props.currentPage.isNavBar ? (Vue.openBlock(), Vue.createBlock(_component_FecMobileNavBar, Vue.normalizeProps(Vue.mergeProps({ key: 0 }, __props.currentPage.navBarConfig)), null, 16)) : Vue.createCommentVNode("", true),
|
|
69
|
+
Vue.createElementVNode("div", _hoisted_1, [
|
|
70
|
+
__props.currentPage.footerType == "tabbar" ? (Vue.openBlock(), Vue.createElementBlock(Vue.Fragment, { key: 0 }, [
|
|
71
|
+
__props.routePage || Vue.unref(childPage) ? (Vue.openBlock(), Vue.createBlock(_component_page, {
|
|
72
|
+
key: 0,
|
|
73
|
+
currentPage: __props.routePage || Vue.unref(childPage)
|
|
74
|
+
}, null, 8, ["currentPage"])) : Vue.createCommentVNode("", true)
|
|
75
|
+
], 64)) : (Vue.openBlock(), Vue.createElementBlock(Vue.Fragment, { key: 1 }, [
|
|
76
|
+
__props.currentPage.type == "home" ? (Vue.openBlock(), Vue.createElementBlock(Vue.Fragment, { key: 0 }, [
|
|
77
|
+
Vue.createVNode(_component_FecMobileMenuGrid, Vue.normalizeProps(Vue.guardReactiveProps(__props.currentPage.layoutData.menuGridProps)), null, 16),
|
|
78
|
+
Vue.createVNode(_component_FecMobileNoticeBar),
|
|
79
|
+
Vue.createVNode(_component_FecMobileDataStat)
|
|
80
|
+
], 64)) : __props.currentPage.type == "approval" ? (Vue.openBlock(), Vue.createElementBlock(Vue.Fragment, { key: 1 }, [], 64)) : (Vue.openBlock(), Vue.createBlock(Vue.unref(gridLayout_vue.default), {
|
|
81
|
+
key: 2,
|
|
82
|
+
ref: "gridLayout",
|
|
83
|
+
layout: Vue.unref(layoutData),
|
|
84
|
+
"onUpdate:layout": _cache[0] || (_cache[0] = ($event) => Vue.isRef(layoutData) ? layoutData.value = $event : null),
|
|
85
|
+
"row-height": rowHeight,
|
|
86
|
+
margin: [0, 0],
|
|
87
|
+
"col-num": colNum,
|
|
88
|
+
"use-css-transforms": false,
|
|
89
|
+
"is-draggable": false,
|
|
90
|
+
"is-resizable": false,
|
|
91
|
+
style: { "height": "100%" }
|
|
92
|
+
}, {
|
|
93
|
+
item: Vue.withCtx(({ item: { component } }) => [
|
|
94
|
+
Vue.createElementVNode("div", _hoisted_2, [
|
|
95
|
+
(Vue.openBlock(), Vue.createBlock(Vue.resolveDynamicComponent(getComp(component.fieldType)), Vue.mergeProps(component.props, {
|
|
96
|
+
modelValue: Vue.unref(formData)[component.props.fieldName],
|
|
97
|
+
"onUpdate:modelValue": ($event) => Vue.unref(formData)[component.props.fieldName] = $event,
|
|
98
|
+
dataSources: _ctx.dataSources
|
|
99
|
+
}), null, 16, ["modelValue", "onUpdate:modelValue", "dataSources"]))
|
|
100
|
+
])
|
|
101
|
+
]),
|
|
102
|
+
_: 1
|
|
103
|
+
}, 8, ["layout"]))
|
|
104
|
+
], 64))
|
|
105
|
+
]),
|
|
106
|
+
__props.currentPage.footerType == "tabbar" ? (Vue.openBlock(), Vue.createBlock(_component_FecMobileTabbar, Vue.mergeProps({
|
|
107
|
+
key: 1,
|
|
108
|
+
modelValue: Vue.unref(tabbarActive),
|
|
109
|
+
"onUpdate:modelValue": _cache[1] || (_cache[1] = ($event) => Vue.isRef(tabbarActive) ? tabbarActive.value = $event : null)
|
|
110
|
+
}, __props.currentPage.tabbarConfig, { onChange: onTabbarChange }), null, 16, ["modelValue"])) : Vue.createCommentVNode("", true),
|
|
111
|
+
__props.currentPage.footerType == "actionBar" ? (Vue.openBlock(), Vue.createBlock(_component_FecMobileActionBar, Vue.normalizeProps(Vue.mergeProps({ key: 2 }, __props.currentPage.actionBarConfig)), null, 16)) : Vue.createCommentVNode("", true)
|
|
112
|
+
], 64);
|
|
113
|
+
};
|
|
114
|
+
}
|
|
115
|
+
};
|
|
116
|
+
const MobilePage = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-08632dac"]]);
|
|
117
|
+
exports.default = MobilePage;
|