@fecp/designer 5.4.77 → 5.4.79
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/index.vue.mjs +1 -1
- package/es/designer/src/packages/dialog/index.vue2.mjs +1 -1
- package/es/designer/src/packages/dialogGlobal/index.vue.mjs +1 -1
- package/es/designer/src/packages/form/property/approvalHistory.vue.mjs +8 -17
- package/es/designer/src/packages/form/property/contract.vue.mjs +13 -22
- package/es/designer/src/packages/form/property/document.vue.mjs +11 -20
- package/es/designer/src/packages/form/property/subForm.vue.mjs +16 -25
- package/es/designer/src/packages/form/property/subTable.vue.mjs +17 -26
- package/es/designer/src/packages/form/property/subTitleH2.vue.mjs +5 -14
- package/es/designer/src/packages/form/property/widgets.vue.mjs +81 -90
- package/es/designer/src/packages/table/property/widgets.vue.mjs +25 -34
- package/es/designer.css +248 -229
- package/es/packages/mobile/src/components/base/button/Button.vue.mjs +3 -3
- package/es/packages/mobile/src/components/navigation/tabbar/Tabbar.vue.mjs +22 -8
- package/es/packages/vue/index.mjs +2 -0
- package/es/packages/vue/src/components/details/footer/Footer.vue.mjs +7 -4
- package/es/packages/vue/src/components/details/header/Header.vue.mjs +7 -4
- package/es/packages/vue/src/components/forms/form/Form.vue.mjs +3 -3
- package/es/packages/vue/src/components/forms/h2/H2.vue.mjs +1 -1
- package/es/packages/vue/src/components/layout/Layout.vue.mjs +8 -15
- package/es/packages/vue/src/components/table/CustomButtons.vue.mjs +11 -6
- package/es/packages/vue/src/components/table/DynamicQuery.vue.mjs +7 -4
- package/es/packages/vue/src/components/table/TableColumn.vue.mjs +18 -2
- package/es/packages/vue/src/directive/auth.mjs +29 -0
- package/lib/designer/package.json.js +1 -1
- package/lib/designer/src/packages/dialog/index.vue.js +1 -1
- package/lib/designer/src/packages/dialog/index.vue2.js +1 -1
- package/lib/designer/src/packages/dialogGlobal/index.vue.js +1 -1
- package/lib/designer/src/packages/form/property/approvalHistory.vue.js +8 -17
- package/lib/designer/src/packages/form/property/contract.vue.js +13 -22
- package/lib/designer/src/packages/form/property/document.vue.js +11 -20
- package/lib/designer/src/packages/form/property/subForm.vue.js +16 -25
- package/lib/designer/src/packages/form/property/subTable.vue.js +17 -26
- package/lib/designer/src/packages/form/property/subTitleH2.vue.js +5 -14
- package/lib/designer/src/packages/form/property/widgets.vue.js +81 -90
- package/lib/designer/src/packages/table/property/widgets.vue.js +25 -34
- package/lib/designer.css +248 -229
- package/lib/packages/mobile/src/components/base/button/Button.vue.js +2 -2
- package/lib/packages/mobile/src/components/navigation/tabbar/Tabbar.vue.js +21 -7
- package/lib/packages/vue/index.js +2 -0
- package/lib/packages/vue/src/components/details/footer/Footer.vue.js +6 -3
- package/lib/packages/vue/src/components/details/header/Header.vue.js +6 -3
- package/lib/packages/vue/src/components/forms/form/Form.vue.js +3 -3
- package/lib/packages/vue/src/components/forms/h2/H2.vue.js +1 -1
- package/lib/packages/vue/src/components/layout/Layout.vue.js +8 -15
- package/lib/packages/vue/src/components/table/CustomButtons.vue.js +10 -5
- package/lib/packages/vue/src/components/table/DynamicQuery.vue.js +6 -3
- package/lib/packages/vue/src/components/table/TableColumn.vue.js +18 -2
- package/lib/packages/vue/src/directive/auth.js +29 -0
- package/package.json +1 -1
|
@@ -12,7 +12,7 @@ const index = require("../../../../../../node_modules/vant/es/button/index.js");
|
|
|
12
12
|
const _sfc_main = {};
|
|
13
13
|
function _sfc_render(_ctx, _cache) {
|
|
14
14
|
const _component_van_button = index.Button;
|
|
15
|
-
return vue.openBlock(), vue.createBlock(_component_van_button, vue.
|
|
15
|
+
return vue.openBlock(), vue.createBlock(_component_van_button, vue.mergeProps({ class: "fec-button" }, _ctx.$attrs), vue.createSlots({ _: 2 }, [
|
|
16
16
|
vue.renderList(_ctx.$slots, (item, key) => {
|
|
17
17
|
return {
|
|
18
18
|
name: key,
|
|
@@ -23,5 +23,5 @@ function _sfc_render(_ctx, _cache) {
|
|
|
23
23
|
})
|
|
24
24
|
]), 1040);
|
|
25
25
|
}
|
|
26
|
-
const _Button = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-
|
|
26
|
+
const _Button = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["render", _sfc_render], ["__scopeId", "data-v-96b4e696"]]);
|
|
27
27
|
exports.default = _Button;
|
|
@@ -11,36 +11,50 @@ const index$1 = require("../../../../../../node_modules/vant/es/tabbar-item/inde
|
|
|
11
11
|
const _sfc_main = {
|
|
12
12
|
__name: "Tabbar",
|
|
13
13
|
props: {
|
|
14
|
+
modelValue: {
|
|
15
|
+
type: Number,
|
|
16
|
+
default: 0
|
|
17
|
+
},
|
|
14
18
|
tabbarOptions: {
|
|
15
19
|
type: Array,
|
|
16
20
|
default: []
|
|
17
21
|
}
|
|
18
22
|
},
|
|
19
|
-
|
|
23
|
+
emits: ["update:modelValue"],
|
|
24
|
+
setup(__props, { emit: __emit }) {
|
|
25
|
+
const props = __props;
|
|
26
|
+
const emit = __emit;
|
|
27
|
+
const activeName = vue.computed({
|
|
28
|
+
get: () => {
|
|
29
|
+
return props.modelValue;
|
|
30
|
+
},
|
|
31
|
+
set: (val) => {
|
|
32
|
+
emit("update:modelValue", val);
|
|
33
|
+
}
|
|
34
|
+
});
|
|
20
35
|
return (_ctx, _cache) => {
|
|
21
36
|
const _component_van_tabbar_item = index$1.TabbarItem;
|
|
22
37
|
const _component_van_tabbar = index.Tabbar;
|
|
23
38
|
return vue.openBlock(), vue.createBlock(_component_van_tabbar, vue.mergeProps(_ctx.$attrs, {
|
|
24
|
-
|
|
39
|
+
modelValue: vue.unref(activeName),
|
|
40
|
+
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => vue.isRef(activeName) ? activeName.value = $event : null),
|
|
25
41
|
fixed: false
|
|
26
42
|
}), {
|
|
27
43
|
default: vue.withCtx(() => [
|
|
28
44
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList(__props.tabbarOptions, (item) => {
|
|
29
45
|
return vue.openBlock(), vue.createBlock(_component_van_tabbar_item, {
|
|
30
|
-
icon: item.icon
|
|
31
|
-
replace: "",
|
|
32
|
-
to: item.to
|
|
46
|
+
icon: item.icon
|
|
33
47
|
}, {
|
|
34
48
|
default: vue.withCtx(() => [
|
|
35
49
|
vue.createTextVNode(vue.toDisplayString(item.title), 1)
|
|
36
50
|
]),
|
|
37
51
|
_: 2
|
|
38
|
-
}, 1032, ["icon"
|
|
52
|
+
}, 1032, ["icon"]);
|
|
39
53
|
}), 256)),
|
|
40
54
|
vue.renderSlot(_ctx.$slots, "default")
|
|
41
55
|
]),
|
|
42
56
|
_: 3
|
|
43
|
-
}, 16);
|
|
57
|
+
}, 16, ["modelValue"]);
|
|
44
58
|
};
|
|
45
59
|
}
|
|
46
60
|
};
|
|
@@ -8,6 +8,7 @@ const components = require("../../node_modules/vxe-pc-ui/es/components.js");
|
|
|
8
8
|
;/* empty css */
|
|
9
9
|
;/* empty css */
|
|
10
10
|
const layout = require("./src/directive/layout.js");
|
|
11
|
+
const auth = require("./src/directive/auth.js");
|
|
11
12
|
const fecVue = {
|
|
12
13
|
install: (app) => {
|
|
13
14
|
for (let c in all) {
|
|
@@ -23,6 +24,7 @@ const fecVue = {
|
|
|
23
24
|
});
|
|
24
25
|
app.use(components);
|
|
25
26
|
app.use(layout.default);
|
|
27
|
+
app.use(auth.default);
|
|
26
28
|
}
|
|
27
29
|
};
|
|
28
30
|
exports.default = fecVue;
|
|
@@ -34,6 +34,7 @@ const _sfc_main = {
|
|
|
34
34
|
var _a;
|
|
35
35
|
const _component_el_button = index$1.ElButton;
|
|
36
36
|
const _component_el_footer = index.ElFooter;
|
|
37
|
+
const _directive_fec_auth = vue.resolveDirective("fec-auth");
|
|
37
38
|
return __props.pageFooterConfig.enabled && ((_a = __props.pageFooterConfig.actions) == null ? void 0 : _a.length) ? (vue.openBlock(), vue.createBlock(_component_el_footer, {
|
|
38
39
|
key: 0,
|
|
39
40
|
class: "form-details-footer"
|
|
@@ -43,7 +44,7 @@ const _sfc_main = {
|
|
|
43
44
|
return vue.openBlock(), vue.createElementBlock(vue.Fragment, {
|
|
44
45
|
key: button.id
|
|
45
46
|
}, [
|
|
46
|
-
button.btnType == "default" || button.btnType == "primary" && __props.formMode == "edit" ? (vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
47
|
+
button.btnType == "default" || button.btnType == "primary" && __props.formMode == "edit" ? vue.withDirectives((vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
47
48
|
key: 0,
|
|
48
49
|
type: button.btnType,
|
|
49
50
|
onClick: ($event) => handleButtonClick(button)
|
|
@@ -52,7 +53,9 @@ const _sfc_main = {
|
|
|
52
53
|
vue.createTextVNode(vue.toDisplayString(button.label), 1)
|
|
53
54
|
]),
|
|
54
55
|
_: 2
|
|
55
|
-
}, 1032, ["type", "onClick"]))
|
|
56
|
+
}, 1032, ["type", "onClick"])), [
|
|
57
|
+
[_directive_fec_auth, button.permission]
|
|
58
|
+
]) : vue.createCommentVNode("", true)
|
|
56
59
|
], 64);
|
|
57
60
|
}), 128))
|
|
58
61
|
]),
|
|
@@ -61,5 +64,5 @@ const _sfc_main = {
|
|
|
61
64
|
};
|
|
62
65
|
}
|
|
63
66
|
};
|
|
64
|
-
const component = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
67
|
+
const component = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-97973006"]]);
|
|
65
68
|
exports.default = component;
|
|
@@ -74,6 +74,7 @@ const _sfc_main = {
|
|
|
74
74
|
var _a, _b, _c, _d, _e;
|
|
75
75
|
const _component_el_button = index$2.ElButton;
|
|
76
76
|
const _component_el_page_header = index.ElPageHeader;
|
|
77
|
+
const _directive_fec_auth = vue.resolveDirective("fec-auth");
|
|
77
78
|
return ((_a = __props.pageHeaderConfig) == null ? void 0 : _a.enabled) && (vue.unref(canBack) || ((_c = (_b = __props.pageHeaderConfig) == null ? void 0 : _b.actions) == null ? void 0 : _c.length) > 0) ? (vue.openBlock(), vue.createBlock(_component_el_page_header, {
|
|
78
79
|
key: 0,
|
|
79
80
|
icon: vue.unref(canBack) ? vue.unref(index$1.ArrowLeftBold) : null,
|
|
@@ -95,7 +96,7 @@ const _sfc_main = {
|
|
|
95
96
|
var _a2;
|
|
96
97
|
return [
|
|
97
98
|
(vue.openBlock(true), vue.createElementBlock(vue.Fragment, null, vue.renderList((_a2 = __props.pageHeaderConfig) == null ? void 0 : _a2.actions, (action) => {
|
|
98
|
-
return vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
99
|
+
return vue.withDirectives((vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
99
100
|
key: action.id,
|
|
100
101
|
type: getButtonType(action.btnStyle),
|
|
101
102
|
onClick: ($event) => handleActionClick(action)
|
|
@@ -104,7 +105,9 @@ const _sfc_main = {
|
|
|
104
105
|
vue.createTextVNode(vue.toDisplayString(action.label), 1)
|
|
105
106
|
]),
|
|
106
107
|
_: 2
|
|
107
|
-
}, 1032, ["type", "onClick"])
|
|
108
|
+
}, 1032, ["type", "onClick"])), [
|
|
109
|
+
[_directive_fec_auth, action.permission]
|
|
110
|
+
]);
|
|
108
111
|
}), 128))
|
|
109
112
|
];
|
|
110
113
|
}),
|
|
@@ -114,5 +117,5 @@ const _sfc_main = {
|
|
|
114
117
|
};
|
|
115
118
|
}
|
|
116
119
|
};
|
|
117
|
-
const component = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
120
|
+
const component = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-a55fc4ab"]]);
|
|
118
121
|
exports.default = component;
|
|
@@ -119,8 +119,8 @@ const _sfc_main = /* @__PURE__ */ Object.assign({
|
|
|
119
119
|
const dataSourceOptions = vue.ref({});
|
|
120
120
|
const dictionaryOptions = vue.ref({});
|
|
121
121
|
const productData = vue.ref({});
|
|
122
|
-
const fieldsData = vue.ref(
|
|
123
|
-
const hiddenFields = vue.ref(
|
|
122
|
+
const fieldsData = vue.ref([]);
|
|
123
|
+
const hiddenFields = vue.ref([]);
|
|
124
124
|
const rowHeight = vue.ref(1);
|
|
125
125
|
const pageEvents = props.canPageEvent ? usePageEvents.usePageEvents(() => ({
|
|
126
126
|
pageEventConfig: localConfig.value.pageEventConfig,
|
|
@@ -1098,5 +1098,5 @@ const _sfc_main = /* @__PURE__ */ Object.assign({
|
|
|
1098
1098
|
};
|
|
1099
1099
|
}
|
|
1100
1100
|
});
|
|
1101
|
-
const _Form = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
1101
|
+
const _Form = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-2e861481"]]);
|
|
1102
1102
|
exports.default = _Form;
|
|
@@ -38,5 +38,5 @@ const _sfc_main = {
|
|
|
38
38
|
};
|
|
39
39
|
}
|
|
40
40
|
};
|
|
41
|
-
const _H2 = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
41
|
+
const _H2 = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-60bd3722"]]);
|
|
42
42
|
exports.default = _H2;
|
|
@@ -38,19 +38,13 @@ const _sfc_main = {
|
|
|
38
38
|
const formData = vue.ref(props.initFormData);
|
|
39
39
|
const emit = __emit;
|
|
40
40
|
const showCard = vue.ref(false);
|
|
41
|
-
const isDialog = vue.ref(false);
|
|
42
41
|
function loaded(option, formData2) {
|
|
43
42
|
showCard.value = true;
|
|
44
|
-
|
|
45
|
-
const
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
cols.forEach((col) => {
|
|
50
|
-
col.style.height = offsetHeight + "px";
|
|
51
|
-
});
|
|
52
|
-
isDialog.value = true;
|
|
53
|
-
}
|
|
43
|
+
let offsetHeight = layoutRowRef.value.$el.offsetHeight;
|
|
44
|
+
const cols = layoutRowRef.value.$el.querySelectorAll(".el-col");
|
|
45
|
+
cols.forEach((col) => {
|
|
46
|
+
col.style.height = offsetHeight + "px";
|
|
47
|
+
});
|
|
54
48
|
emit("loaded", common.cloneDeep(formData2));
|
|
55
49
|
}
|
|
56
50
|
return (_ctx, _cache) => {
|
|
@@ -76,9 +70,8 @@ const _sfc_main = {
|
|
|
76
70
|
modelValue: vue.unref(formData),
|
|
77
71
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => vue.isRef(formData) ? formData.value = $event : null),
|
|
78
72
|
onLoaded: loaded,
|
|
79
|
-
initFormMode: __props.initFormMode
|
|
80
|
-
|
|
81
|
-
}, null, 8, ["templateKey", "modelValue", "initFormMode", "isDialog"])
|
|
73
|
+
initFormMode: __props.initFormMode
|
|
74
|
+
}, null, 8, ["templateKey", "modelValue", "initFormMode"])
|
|
82
75
|
]),
|
|
83
76
|
_: 1
|
|
84
77
|
}, 512)
|
|
@@ -102,5 +95,5 @@ const _sfc_main = {
|
|
|
102
95
|
};
|
|
103
96
|
}
|
|
104
97
|
};
|
|
105
|
-
const _Layout = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
98
|
+
const _Layout = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-317e7dd8"]]);
|
|
106
99
|
exports.default = _Layout;
|
|
@@ -111,6 +111,7 @@ const _sfc_main = {
|
|
|
111
111
|
return (_ctx, _cache) => {
|
|
112
112
|
const _component_el_icon = index.ElIcon;
|
|
113
113
|
const _component_el_button = index$3.ElButton;
|
|
114
|
+
const _directive_fec_auth = vue.resolveDirective("fec-auth");
|
|
114
115
|
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
|
|
115
116
|
__props.localConfig.showReturn ? (vue.openBlock(), vue.createElementBlock("div", {
|
|
116
117
|
key: 0,
|
|
@@ -132,7 +133,7 @@ const _sfc_main = {
|
|
|
132
133
|
}, {
|
|
133
134
|
buttons: vue.withCtx(() => [
|
|
134
135
|
leftButtons.value.length ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 0 }, vue.renderList(leftButtons.value, (btn) => {
|
|
135
|
-
return vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
136
|
+
return vue.withDirectives((vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
136
137
|
key: btn.id,
|
|
137
138
|
type: getBtnType(btn),
|
|
138
139
|
icon: getBtnIcon(btn.btnType),
|
|
@@ -142,12 +143,14 @@ const _sfc_main = {
|
|
|
142
143
|
vue.createTextVNode(vue.toDisplayString(btn.label), 1)
|
|
143
144
|
]),
|
|
144
145
|
_: 2
|
|
145
|
-
}, 1032, ["type", "icon", "onClick"])
|
|
146
|
+
}, 1032, ["type", "icon", "onClick"])), [
|
|
147
|
+
[_directive_fec_auth, btn.permission]
|
|
148
|
+
]);
|
|
146
149
|
}), 128)) : vue.createCommentVNode("", true)
|
|
147
150
|
]),
|
|
148
151
|
tools: vue.withCtx(() => [
|
|
149
152
|
rightButtons.value.length ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 0 }, vue.renderList(rightButtons.value, (btn) => {
|
|
150
|
-
return vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
153
|
+
return vue.withDirectives((vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
151
154
|
key: btn.id,
|
|
152
155
|
type: getBtnType(btn),
|
|
153
156
|
icon: getBtnIcon(btn.btnType),
|
|
@@ -157,7 +160,9 @@ const _sfc_main = {
|
|
|
157
160
|
vue.createTextVNode(vue.toDisplayString(btn.label), 1)
|
|
158
161
|
]),
|
|
159
162
|
_: 2
|
|
160
|
-
}, 1032, ["type", "icon", "onClick"])
|
|
163
|
+
}, 1032, ["type", "icon", "onClick"])), [
|
|
164
|
+
[_directive_fec_auth, btn.permission]
|
|
165
|
+
]);
|
|
161
166
|
}), 128)) : vue.createCommentVNode("", true)
|
|
162
167
|
]),
|
|
163
168
|
_: 1
|
|
@@ -166,5 +171,5 @@ const _sfc_main = {
|
|
|
166
171
|
};
|
|
167
172
|
}
|
|
168
173
|
};
|
|
169
|
-
const CustomButtons = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
174
|
+
const CustomButtons = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-7610c2d4"]]);
|
|
170
175
|
exports.default = CustomButtons;
|
|
@@ -267,6 +267,7 @@ const _sfc_main = {
|
|
|
267
267
|
const _component_el_form_item = index$7.ElFormItem;
|
|
268
268
|
const _component_el_form = index$7.ElForm;
|
|
269
269
|
const _component_el_collapse_transition = index$6.ElCollapseTransition;
|
|
270
|
+
const _directive_fec_auth = vue.resolveDirective("fec-auth");
|
|
270
271
|
return vue.openBlock(), vue.createElementBlock("div", _hoisted_1, [
|
|
271
272
|
vue.createElementVNode("div", _hoisted_2, [
|
|
272
273
|
__props.localConfig.showReturn ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_3, [
|
|
@@ -329,7 +330,7 @@ const _sfc_main = {
|
|
|
329
330
|
}, {
|
|
330
331
|
tools: vue.withCtx(() => [
|
|
331
332
|
!__props.isSubTable && rightButtons.value.length ? (vue.openBlock(true), vue.createElementBlock(vue.Fragment, { key: 0 }, vue.renderList(rightButtons.value, (btn) => {
|
|
332
|
-
return vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
333
|
+
return vue.withDirectives((vue.openBlock(), vue.createBlock(_component_el_button, {
|
|
333
334
|
key: btn.id,
|
|
334
335
|
type: getBtnType(btn),
|
|
335
336
|
icon: getBtnIcon(btn.btnType),
|
|
@@ -339,7 +340,9 @@ const _sfc_main = {
|
|
|
339
340
|
vue.createTextVNode(vue.toDisplayString(btn.label), 1)
|
|
340
341
|
]),
|
|
341
342
|
_: 2
|
|
342
|
-
}, 1032, ["type", "icon", "onClick"])
|
|
343
|
+
}, 1032, ["type", "icon", "onClick"])), [
|
|
344
|
+
[_directive_fec_auth, btn.permission]
|
|
345
|
+
]);
|
|
343
346
|
}), 128)) : vue.createCommentVNode("", true)
|
|
344
347
|
]),
|
|
345
348
|
_: 1
|
|
@@ -452,5 +455,5 @@ const _sfc_main = {
|
|
|
452
455
|
};
|
|
453
456
|
}
|
|
454
457
|
};
|
|
455
|
-
const DynamicQuery = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
458
|
+
const DynamicQuery = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-d11a831a"]]);
|
|
456
459
|
exports.default = DynamicQuery;
|
|
@@ -264,8 +264,24 @@ const _sfc_main = {
|
|
|
264
264
|
if (!item.showCondition) return true;
|
|
265
265
|
return parseFilterConfig.checkFilterMatch(item.showCondition, row, props.fieldsData);
|
|
266
266
|
});
|
|
267
|
-
return btnList
|
|
267
|
+
return btnList.filter((item) => {
|
|
268
|
+
return hasPerm(item.permission);
|
|
269
|
+
});
|
|
268
270
|
};
|
|
271
|
+
function hasPerm(permission) {
|
|
272
|
+
if (permission === true || permission === void 0 || permission === "") {
|
|
273
|
+
return true;
|
|
274
|
+
}
|
|
275
|
+
let btnFlag = false;
|
|
276
|
+
const myBtns = window.$store.getters.funcAuthList;
|
|
277
|
+
for (let i in myBtns) {
|
|
278
|
+
if (myBtns[i] == permission) {
|
|
279
|
+
btnFlag = true;
|
|
280
|
+
break;
|
|
281
|
+
}
|
|
282
|
+
}
|
|
283
|
+
return btnFlag;
|
|
284
|
+
}
|
|
269
285
|
const shouldShowOptColumn = vue.computed(() => {
|
|
270
286
|
if (!props.isOptBtns || !props.optBtns.length) return false;
|
|
271
287
|
if (!props.tableData || props.tableData.length === 0) return true;
|
|
@@ -431,5 +447,5 @@ const _sfc_main = {
|
|
|
431
447
|
};
|
|
432
448
|
}
|
|
433
449
|
};
|
|
434
|
-
const TableColumn = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
450
|
+
const TableColumn = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-77be03fc"]]);
|
|
435
451
|
exports.default = TableColumn;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
|
+
const auth = {
|
|
4
|
+
mounted(el, binding, vnode, prevVnode) {
|
|
5
|
+
const permission = binding.value;
|
|
6
|
+
const btnFlag = auth.hasPerm(permission);
|
|
7
|
+
if (!btnFlag) {
|
|
8
|
+
el.parentNode.removeChild(el);
|
|
9
|
+
}
|
|
10
|
+
},
|
|
11
|
+
hasPerm(permission) {
|
|
12
|
+
if (permission === true || permission === void 0 || permission === "") {
|
|
13
|
+
return true;
|
|
14
|
+
}
|
|
15
|
+
let btnFlag = false;
|
|
16
|
+
const myBtns = window.$store.getters.funcAuthList;
|
|
17
|
+
for (let i in myBtns) {
|
|
18
|
+
if (myBtns[i] === permission) {
|
|
19
|
+
btnFlag = true;
|
|
20
|
+
break;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
return btnFlag;
|
|
24
|
+
}
|
|
25
|
+
};
|
|
26
|
+
auth.install = function(Vue) {
|
|
27
|
+
Vue.directive("fec-auth", auth);
|
|
28
|
+
};
|
|
29
|
+
exports.default = auth;
|