@fecp/designer 5.5.5 → 5.5.6
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/_virtual/app.mjs +5 -0
- package/es/_virtual/app2.mjs +4 -0
- package/es/designer/package.json.mjs +1 -1
- package/es/designer/src/api/index.mjs +30 -31
- package/es/designer/src/components/DocumentParam.vue.mjs +5 -3
- package/es/designer/src/components/RiskSchemeDialog.vue2.mjs +5 -3
- package/es/designer/src/components/TemplateDialog.vue.mjs +5 -3
- package/es/designer/src/layout/header/index.vue.mjs +4 -2
- package/es/designer/src/layout/index.vue.mjs +6 -4
- package/es/designer/src/packages/advancedFilter/ValueInput.vue2.mjs +5 -3
- package/es/designer/src/packages/dataLinkage/index.vue.mjs +0 -3
- package/es/designer/src/packages/dialog/index.vue2.mjs +6 -4
- package/es/designer/src/packages/dialog/useDialogDialog.mjs +1 -1
- package/es/designer/src/packages/dialogGlobal/index.vue2.mjs +9 -7
- package/es/designer/src/packages/dialogGlobal/useDialogGlobalDialog.mjs +1 -1
- package/es/designer/src/packages/eventFlow/dialog/action/Dialog.vue.mjs +5 -3
- package/es/designer/src/packages/eventFlow/dialog/action/TableChildSelection.vue2.mjs +5 -3
- package/es/designer/src/packages/form/components/ComponentPreviewWrapper.vue.mjs +5 -3
- package/es/designer/src/packages/form/components/DefaultValueEditor.vue.mjs +2 -2
- package/es/designer/src/packages/form/property/contract.vue.mjs +5 -3
- package/es/designer/src/packages/form/property/subTable.vue.mjs +5 -3
- package/es/designer/src/packages/form/property/widgets.vue.mjs +8 -6
- package/es/designer/src/packages/prod/index.vue.mjs +5 -3
- package/es/designer/src/packages/table/headerBtn.vue.mjs +1 -4
- package/es/designer/src/utils/optionLoader.mjs +8 -7
- package/es/designer.css +214 -185
- package/es/node_modules/element-china-category-data/dist/app.mjs +77 -0
- package/es/packages/mobile/index.mjs +4 -0
- package/es/packages/mobile/src/components/all.mjs +4 -0
- package/es/packages/mobile/src/components/form/checkboxGroup/CheckboxGroup.vue.mjs +2 -2
- package/es/packages/mobile/src/components/form/fieldCheckbox/FieldCheckbox.vue.mjs +29 -25
- package/es/packages/mobile/src/components/form/fieldIndustry/FieldIndustry.vue.mjs +195 -0
- package/es/packages/mobile/src/components/form/fieldIndustry/index.mjs +10 -0
- package/es/packages/mobile/src/components/form/fieldPicker/FieldPicker.vue.mjs +3 -25
- package/es/packages/mobile/src/components/form/fieldRadio/FieldRadio.vue.mjs +34 -7
- package/es/packages/mobile/src/components/form/fieldSubTitle/FieldSubTitle.vue.mjs +27 -0
- package/es/packages/mobile/src/components/form/fieldSubTitle/index.mjs +10 -0
- package/es/packages/mobile/src/components/form/radioGroup/RadioGroup.vue.mjs +1 -1
- package/es/packages/mobile/src/components/navigation/actionBar/ActionBar.vue.mjs +35 -16
- package/es/packages/mobile/src/components/navigation/tabbar/Tabbar.vue.mjs +2 -1
- package/es/packages/mobile/src/utils/common.mjs +28 -0
- package/es/packages/mobile/src/utils/datasource.mjs +354 -0
- package/es/packages/mobile/src/utils/optionUtil.mjs +63 -40
- package/es/packages/mobile/src/utils/parseRouteParams.mjs +41 -0
- package/es/packages/vue/src/components/dialog/DialogRenderer.vue2.mjs +1 -1
- package/es/packages/vue/src/components/forms/text/Text.vue.mjs +1 -1
- package/es/packages/vue/src/components/table/TableColumn.vue.mjs +1 -1
- package/es/packages/vue/src/composables/usePageEvents.mjs +1 -1
- package/es/packages/vue/src/utils/datasource.mjs +1 -1
- package/lib/_virtual/app.js +5 -0
- package/lib/_virtual/app2.js +4 -0
- package/lib/designer/package.json.js +1 -1
- package/lib/designer/src/api/index.js +30 -31
- package/lib/designer/src/components/DocumentParam.vue.js +4 -2
- package/lib/designer/src/components/RiskSchemeDialog.vue2.js +4 -2
- package/lib/designer/src/components/TemplateDialog.vue.js +4 -2
- package/lib/designer/src/layout/header/index.vue.js +3 -1
- package/lib/designer/src/layout/index.vue.js +5 -3
- package/lib/designer/src/packages/advancedFilter/ValueInput.vue2.js +4 -2
- package/lib/designer/src/packages/dataLinkage/index.vue.js +0 -3
- package/lib/designer/src/packages/dialog/index.vue2.js +5 -3
- package/lib/designer/src/packages/dialog/useDialogDialog.js +1 -1
- package/lib/designer/src/packages/dialogGlobal/index.vue2.js +8 -6
- package/lib/designer/src/packages/dialogGlobal/useDialogGlobalDialog.js +1 -1
- package/lib/designer/src/packages/eventFlow/dialog/action/Dialog.vue.js +4 -2
- package/lib/designer/src/packages/eventFlow/dialog/action/TableChildSelection.vue2.js +4 -2
- package/lib/designer/src/packages/form/components/ComponentPreviewWrapper.vue.js +4 -2
- package/lib/designer/src/packages/form/components/DefaultValueEditor.vue.js +2 -2
- package/lib/designer/src/packages/form/property/contract.vue.js +4 -2
- package/lib/designer/src/packages/form/property/subTable.vue.js +4 -2
- package/lib/designer/src/packages/form/property/widgets.vue.js +7 -5
- package/lib/designer/src/packages/prod/index.vue.js +4 -2
- package/lib/designer/src/packages/table/headerBtn.vue.js +1 -4
- package/lib/designer/src/utils/optionLoader.js +8 -7
- package/lib/designer.css +214 -185
- package/lib/node_modules/element-china-category-data/dist/app.js +77 -0
- package/lib/packages/mobile/index.js +48 -44
- package/lib/packages/mobile/src/components/all.js +48 -44
- package/lib/packages/mobile/src/components/form/checkboxGroup/CheckboxGroup.vue.js +2 -2
- package/lib/packages/mobile/src/components/form/fieldCheckbox/FieldCheckbox.vue.js +28 -24
- package/lib/packages/mobile/src/components/form/fieldIndustry/FieldIndustry.vue.js +195 -0
- package/lib/packages/mobile/src/components/form/fieldIndustry/index.js +10 -0
- package/lib/packages/mobile/src/components/form/fieldPicker/FieldPicker.vue.js +2 -24
- package/lib/packages/mobile/src/components/form/fieldRadio/FieldRadio.vue.js +33 -6
- package/lib/packages/mobile/src/components/form/fieldSubTitle/FieldSubTitle.vue.js +27 -0
- package/lib/packages/mobile/src/components/form/fieldSubTitle/index.js +10 -0
- package/lib/packages/mobile/src/components/form/radioGroup/RadioGroup.vue.js +1 -1
- package/lib/packages/mobile/src/components/navigation/actionBar/ActionBar.vue.js +34 -15
- package/lib/packages/mobile/src/components/navigation/tabbar/Tabbar.vue.js +2 -1
- package/lib/packages/mobile/src/utils/common.js +28 -0
- package/lib/packages/mobile/src/utils/datasource.js +354 -0
- package/lib/packages/mobile/src/utils/optionUtil.js +64 -41
- package/lib/packages/mobile/src/utils/parseRouteParams.js +41 -0
- package/lib/packages/vue/src/components/dialog/DialogRenderer.vue2.js +1 -1
- package/lib/packages/vue/src/components/forms/text/Text.vue.js +1 -1
- package/lib/packages/vue/src/components/table/TableColumn.vue.js +1 -1
- package/lib/packages/vue/src/composables/usePageEvents.js +1 -1
- package/lib/packages/vue/src/utils/datasource.js +1 -1
- package/package.json +1 -1
|
@@ -23,6 +23,8 @@ const _sfc_main = {
|
|
|
23
23
|
formData: Object
|
|
24
24
|
},
|
|
25
25
|
setup(__props) {
|
|
26
|
+
const currentInstance = vue.getCurrentInstance();
|
|
27
|
+
const ctx = currentInstance.proxy;
|
|
26
28
|
const props = __props;
|
|
27
29
|
const fieldList = vue.computed(() => {
|
|
28
30
|
return common.getEditConfigDataFields().filter(
|
|
@@ -36,7 +38,7 @@ const _sfc_main = {
|
|
|
36
38
|
const fieldItem = common.getEditConfigDataFields().find((item) => item.id == id);
|
|
37
39
|
if (fieldItem) {
|
|
38
40
|
const subTableId = fieldItem.subTableId;
|
|
39
|
-
index.default.getById(subTableId).then((data) => {
|
|
41
|
+
index.default.getById(ctx.$http, subTableId).then((data) => {
|
|
40
42
|
subTableOptions.value = JSON.parse(data.context);
|
|
41
43
|
});
|
|
42
44
|
}
|
|
@@ -97,5 +99,5 @@ const _sfc_main = {
|
|
|
97
99
|
};
|
|
98
100
|
}
|
|
99
101
|
};
|
|
100
|
-
const TableChildSelection = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
102
|
+
const TableChildSelection = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-170db076"]]);
|
|
101
103
|
exports.default = TableChildSelection;
|
|
@@ -57,6 +57,8 @@ const _sfc_main = {
|
|
|
57
57
|
}
|
|
58
58
|
},
|
|
59
59
|
setup(__props) {
|
|
60
|
+
const currentInstance = vue.getCurrentInstance();
|
|
61
|
+
const ctx = currentInstance.proxy;
|
|
60
62
|
const props = __props;
|
|
61
63
|
const commProps = vue.computed(() => {
|
|
62
64
|
return {
|
|
@@ -68,7 +70,7 @@ const _sfc_main = {
|
|
|
68
70
|
showWordLimit: props.componentData.showWordCount || false
|
|
69
71
|
};
|
|
70
72
|
});
|
|
71
|
-
const { options } = optionLoader.useOptions(props.componentData);
|
|
73
|
+
const { options } = optionLoader.useOptions(ctx, props.componentData);
|
|
72
74
|
const cascaderPropsDataValue = vue.computed(() => {
|
|
73
75
|
let propsData = props.componentData.propsData || {};
|
|
74
76
|
if (props.componentData.fieldType == "area" || props.componentData.fieldType == "industry") {
|
|
@@ -301,5 +303,5 @@ const _sfc_main = {
|
|
|
301
303
|
};
|
|
302
304
|
}
|
|
303
305
|
};
|
|
304
|
-
const ComponentPreviewWrapper = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
306
|
+
const ComponentPreviewWrapper = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-58df4a86"]]);
|
|
305
307
|
exports.default = ComponentPreviewWrapper;
|
|
@@ -52,7 +52,7 @@ const _sfc_main = {
|
|
|
52
52
|
}
|
|
53
53
|
return component;
|
|
54
54
|
});
|
|
55
|
-
const { options: optionData } = optionLoader.useOptions(props.config);
|
|
55
|
+
const { options: optionData } = optionLoader.useOptions(ctx, props.config);
|
|
56
56
|
const componentProps = vue.computed(() => {
|
|
57
57
|
const fieldProps = common.cloneDeep(props.config);
|
|
58
58
|
fieldProps.disabled = false;
|
|
@@ -85,5 +85,5 @@ const _sfc_main = {
|
|
|
85
85
|
};
|
|
86
86
|
}
|
|
87
87
|
};
|
|
88
|
-
const DefaultValueEditor = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
88
|
+
const DefaultValueEditor = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-2b89d5b3"]]);
|
|
89
89
|
exports.default = DefaultValueEditor;
|
|
@@ -32,12 +32,14 @@ const index$5 = require("../../../../../node_modules/element-plus/es/components/
|
|
|
32
32
|
const _sfc_main = {
|
|
33
33
|
__name: "contract",
|
|
34
34
|
setup(__props) {
|
|
35
|
+
const currentInstance = vue.getCurrentInstance();
|
|
36
|
+
const ctx = currentInstance.proxy;
|
|
35
37
|
const currentItem = vue.computed(() => {
|
|
36
38
|
return common.getCurrentItem();
|
|
37
39
|
});
|
|
38
40
|
const activeName = vue.ref(["common"]);
|
|
39
41
|
const scenarioOptions = vue.ref([]);
|
|
40
|
-
index.default.getModeNoList4Cont().then((data) => {
|
|
42
|
+
index.default.getModeNoList4Cont(ctx.$http).then((data) => {
|
|
41
43
|
scenarioOptions.value = data.map((item) => ({
|
|
42
44
|
label: item.modeName,
|
|
43
45
|
value: item.modeNo
|
|
@@ -214,5 +216,5 @@ const _sfc_main = {
|
|
|
214
216
|
};
|
|
215
217
|
}
|
|
216
218
|
};
|
|
217
|
-
const contract = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
219
|
+
const contract = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-7ebeb42d"]]);
|
|
218
220
|
exports.default = contract;
|
|
@@ -56,6 +56,8 @@ const _hoisted_9 = { class: "button-type" };
|
|
|
56
56
|
const _sfc_main = {
|
|
57
57
|
__name: "subTable",
|
|
58
58
|
setup(__props) {
|
|
59
|
+
const currentInstance = vue.getCurrentInstance();
|
|
60
|
+
const ctx = currentInstance.proxy;
|
|
59
61
|
const currentItem = vue.computed(() => {
|
|
60
62
|
const item = common.getCurrentItem();
|
|
61
63
|
if (!item.btnRollback) {
|
|
@@ -79,7 +81,7 @@ const _sfc_main = {
|
|
|
79
81
|
},
|
|
80
82
|
(pkId) => {
|
|
81
83
|
if (pkId) {
|
|
82
|
-
index.default.getById(pkId).then((data) => {
|
|
84
|
+
index.default.getById(ctx.$http, pkId).then((data) => {
|
|
83
85
|
subTableOptions.value = JSON.parse(data.context);
|
|
84
86
|
});
|
|
85
87
|
}
|
|
@@ -456,5 +458,5 @@ const _sfc_main = {
|
|
|
456
458
|
};
|
|
457
459
|
}
|
|
458
460
|
};
|
|
459
|
-
const subTable = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
461
|
+
const subTable = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-b5400259"]]);
|
|
460
462
|
exports.default = subTable;
|
|
@@ -54,8 +54,8 @@ const _pluginVue_exportHelper = require("../../../../../_virtual/_plugin-vue_exp
|
|
|
54
54
|
require("../../../components/TemplateSelector.vue.js");
|
|
55
55
|
require("../../table/default.js");
|
|
56
56
|
;/* empty css */
|
|
57
|
-
;/* empty css
|
|
58
|
-
;/* empty css
|
|
57
|
+
;/* empty css */
|
|
58
|
+
;/* empty css */
|
|
59
59
|
require("../../../store/index.js");
|
|
60
60
|
;/* empty css */
|
|
61
61
|
const index$2 = require("../../../../../node_modules/element-plus/es/components/collapse/index.js");
|
|
@@ -104,6 +104,8 @@ const _hoisted_20 = {
|
|
|
104
104
|
const _sfc_main = {
|
|
105
105
|
__name: "widgets",
|
|
106
106
|
setup(__props) {
|
|
107
|
+
const currentInstance = vue.getCurrentInstance();
|
|
108
|
+
const ctx = currentInstance.proxy;
|
|
107
109
|
const currentItem = vue.computed(() => {
|
|
108
110
|
return common.getCurrentItem();
|
|
109
111
|
});
|
|
@@ -219,7 +221,7 @@ const _sfc_main = {
|
|
|
219
221
|
const loadGlobalDialogs = async () => {
|
|
220
222
|
dialogLoading.value = true;
|
|
221
223
|
try {
|
|
222
|
-
const response = await index$1.default.getAllTemplateDialog();
|
|
224
|
+
const response = await index$1.default.getAllTemplateDialog(ctx.$http);
|
|
223
225
|
globalDialogs.value = [];
|
|
224
226
|
for (let dialog of response) {
|
|
225
227
|
globalDialogs.value.push({
|
|
@@ -264,7 +266,7 @@ const _sfc_main = {
|
|
|
264
266
|
const tableId = currDialog.value.subTableId;
|
|
265
267
|
if (tableId) {
|
|
266
268
|
try {
|
|
267
|
-
const response = await index$1.default.getById(tableId, false);
|
|
269
|
+
const response = await index$1.default.getById(ctx.$http, tableId, false);
|
|
268
270
|
tableOptions.value = JSON.parse(response.context);
|
|
269
271
|
console.log("🚀 ~ 需要获取表格配置,表格ID:", tableId);
|
|
270
272
|
} catch (error) {
|
|
@@ -1182,5 +1184,5 @@ const _sfc_main = {
|
|
|
1182
1184
|
};
|
|
1183
1185
|
}
|
|
1184
1186
|
};
|
|
1185
|
-
const widgets = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
1187
|
+
const widgets = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-7f8b937d"]]);
|
|
1186
1188
|
exports.default = widgets;
|
|
@@ -41,6 +41,8 @@ const _sfc_main = {
|
|
|
41
41
|
emits: ["update:modelValue"],
|
|
42
42
|
setup(__props, { expose: __expose }) {
|
|
43
43
|
var _a;
|
|
44
|
+
const currentInstance = vue.getCurrentInstance();
|
|
45
|
+
const ctx = currentInstance.proxy;
|
|
44
46
|
const dialogVisible = vue.useModel(__props, "modelValue");
|
|
45
47
|
const prodConfig = vue.ref(((_a = common.getEditConfigData()) == null ? void 0 : _a.prodConfig) || {});
|
|
46
48
|
vue.watch(
|
|
@@ -160,7 +162,7 @@ const _sfc_main = {
|
|
|
160
162
|
};
|
|
161
163
|
const fetchProductConfig = async () => {
|
|
162
164
|
try {
|
|
163
|
-
const response = await index.default.getProductConfig();
|
|
165
|
+
const response = await index.default.getProductConfig(ctx.$http);
|
|
164
166
|
parsedConfig.value = response.map((item) => ({
|
|
165
167
|
fieldName: item.fieldName || "",
|
|
166
168
|
fieldDesc: item.label || item.fieldName || "",
|
|
@@ -513,5 +515,5 @@ const _sfc_main = {
|
|
|
513
515
|
};
|
|
514
516
|
}
|
|
515
517
|
};
|
|
516
|
-
const ProdDialog = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-
|
|
518
|
+
const ProdDialog = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-dc928684"]]);
|
|
517
519
|
exports.default = ProdDialog;
|
|
@@ -73,10 +73,6 @@ require("../formulaEditor/core/functionCore.js");
|
|
|
73
73
|
;/* empty css */
|
|
74
74
|
;/* empty css */
|
|
75
75
|
;/* empty css */
|
|
76
|
-
require("../../axios/config.js");
|
|
77
|
-
require("../../../../_virtual/FileSaver.min.js");
|
|
78
|
-
require("../../../../_virtual/index.js");
|
|
79
|
-
;/* empty css */
|
|
80
76
|
const useDialogDialog = require("../dialog/useDialogDialog.js");
|
|
81
77
|
const useDialogGlobalDialog = require("../dialogGlobal/useDialogGlobalDialog.js");
|
|
82
78
|
;/* empty css */
|
|
@@ -97,6 +93,7 @@ const useAdvancedFilterDialog = require("../advancedFilter/useAdvancedFilterDial
|
|
|
97
93
|
;/* empty css */
|
|
98
94
|
;/* empty css */
|
|
99
95
|
require("../../../../node_modules/element-plus/theme-chalk/el-date-picker.css.js");
|
|
96
|
+
require("../../axios/config.js");
|
|
100
97
|
;/* empty css */
|
|
101
98
|
;/* empty css */
|
|
102
99
|
;/* empty css */
|
|
@@ -5,7 +5,7 @@ const datasource = require("../packages/utils/datasource.js");
|
|
|
5
5
|
const common = require("../packages/utils/common.js");
|
|
6
6
|
const simpleCache = require("./simpleCache.js");
|
|
7
7
|
const index = require("../api/index.js");
|
|
8
|
-
async function loadOptions(config, callback) {
|
|
8
|
+
async function loadOptions(ctx, config, callback) {
|
|
9
9
|
const { fieldType, optionConfig = {} } = config;
|
|
10
10
|
if (fieldType !== "select" && fieldType !== "multipleSelection" && fieldType !== "cascader" && fieldType !== "area" && fieldType !== "industry" && fieldType !== "radio" && fieldType !== "checkbox") {
|
|
11
11
|
const result = optionConfig.options || [];
|
|
@@ -15,7 +15,7 @@ async function loadOptions(config, callback) {
|
|
|
15
15
|
const rawData = await simpleCache.getDataSourceWithConcurrencyControl(
|
|
16
16
|
"sysArea",
|
|
17
17
|
async () => {
|
|
18
|
-
const data = await index.default.getDataDicArea4Cascader();
|
|
18
|
+
const data = await index.default.getDataDicArea4Cascader(ctx.$http);
|
|
19
19
|
return data;
|
|
20
20
|
}
|
|
21
21
|
);
|
|
@@ -24,7 +24,7 @@ async function loadOptions(config, callback) {
|
|
|
24
24
|
const rawData = await simpleCache.getDataSourceWithConcurrencyControl(
|
|
25
25
|
"sysIndustry",
|
|
26
26
|
async () => {
|
|
27
|
-
const data = await index.default.getDataDicTrade4Cascader();
|
|
27
|
+
const data = await index.default.getDataDicTrade4Cascader(ctx.$http);
|
|
28
28
|
return data;
|
|
29
29
|
}
|
|
30
30
|
);
|
|
@@ -54,6 +54,7 @@ async function loadOptions(config, callback) {
|
|
|
54
54
|
}
|
|
55
55
|
if (optionSource === "dictionary" && dictionaryValue) {
|
|
56
56
|
const result = await loadDictionaryOptions(
|
|
57
|
+
ctx,
|
|
57
58
|
dictionaryValue,
|
|
58
59
|
staticOptions
|
|
59
60
|
);
|
|
@@ -105,11 +106,11 @@ async function loadDataSourceOptions(dataSourceValue, displayField, valueField,
|
|
|
105
106
|
return fallbackOptions;
|
|
106
107
|
}
|
|
107
108
|
}
|
|
108
|
-
async function loadDictionaryOptions(dictionaryValue, fallbackOptions = []) {
|
|
109
|
+
async function loadDictionaryOptions(ctx, dictionaryValue, fallbackOptions = []) {
|
|
109
110
|
try {
|
|
110
111
|
const dictData = await simpleCache.getDictionaryWithConcurrencyControl(
|
|
111
112
|
dictionaryValue,
|
|
112
|
-
() => index.default.getDicDataByKey(dictionaryValue)
|
|
113
|
+
() => index.default.getDicDataByKey(ctx.$http, dictionaryValue)
|
|
113
114
|
);
|
|
114
115
|
const result = [];
|
|
115
116
|
for (const key in dictData) {
|
|
@@ -124,7 +125,7 @@ async function loadDictionaryOptions(dictionaryValue, fallbackOptions = []) {
|
|
|
124
125
|
return fallbackOptions;
|
|
125
126
|
}
|
|
126
127
|
}
|
|
127
|
-
function useOptions(config) {
|
|
128
|
+
function useOptions(ctx, config) {
|
|
128
129
|
const options = vue.ref([]);
|
|
129
130
|
const loading = vue.ref(false);
|
|
130
131
|
const configRef = isRef(config) ? config : vue.ref(config);
|
|
@@ -135,7 +136,7 @@ function useOptions(config) {
|
|
|
135
136
|
if (!newConfig) return;
|
|
136
137
|
loading.value = true;
|
|
137
138
|
try {
|
|
138
|
-
const result = await loadOptions(newConfig);
|
|
139
|
+
const result = await loadOptions(ctx, newConfig);
|
|
139
140
|
options.value = result;
|
|
140
141
|
} catch (error) {
|
|
141
142
|
console.error("加载选项失败:", error);
|