@fmdevui/fm-dev 1.0.66 → 1.0.68
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/core/ui/components/index.d.ts +27 -0
- package/es/core/ui/components/inputdropdown/index.vue.d.ts +45 -0
- package/es/packages/core/ui/components/inputdropdown/index.vue2.mjs +48 -3
- package/index.js +47 -3
- package/index.min.js +22 -22
- package/index.min.mjs +25 -25
- package/index.mjs +47 -3
- package/lib/core/ui/components/index.d.ts +27 -0
- package/lib/core/ui/components/inputdropdown/index.vue.d.ts +45 -0
- package/lib/packages/core/ui/components/inputdropdown/index.vue2.js +47 -2
- package/package.json +1 -1
- /package/es/{index.css → make-installer.css} +0 -0
package/index.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/*! fm-dev v1.0.
|
|
1
|
+
/*! fm-dev v1.0.68 */
|
|
2
2
|
import { defineComponent, reactive, computed, watch, resolveComponent, createBlock, openBlock, withCtx, createVNode, createElementVNode, createTextVNode, toDisplayString as toDisplayString$1, withDirectives, createElementBlock, Fragment, renderList, vShow, ref, onMounted, nextTick, normalizeStyle, createCommentVNode, normalizeClass, withModifiers, mergeModels, useModel, effectScope, getCurrentInstance, shallowRef, isRef as isRef$1, inject, onUnmounted, h, Text, resolveDirective, unref, resolveDynamicComponent, markRaw, toRaw as toRaw$1, hasInjectionContext, isReactive as isReactive$1, toRef, getCurrentScope, onScopeDispose, toRefs } from 'vue';
|
|
3
3
|
import crypto from 'crypto';
|
|
4
4
|
import require$$0 from 'url';
|
|
@@ -23901,6 +23901,27 @@ var _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
23901
23901
|
dropWidth: {
|
|
23902
23902
|
type: String,
|
|
23903
23903
|
default: "90px"
|
|
23904
|
+
},
|
|
23905
|
+
/**
|
|
23906
|
+
* api service name
|
|
23907
|
+
*/
|
|
23908
|
+
apiService: {
|
|
23909
|
+
type: String,
|
|
23910
|
+
default: "baseData"
|
|
23911
|
+
},
|
|
23912
|
+
/**
|
|
23913
|
+
* api service 下的方法
|
|
23914
|
+
*/
|
|
23915
|
+
apiAction: {
|
|
23916
|
+
type: String,
|
|
23917
|
+
default: "baseDataList"
|
|
23918
|
+
},
|
|
23919
|
+
/**
|
|
23920
|
+
* 基础编码 自动获取数据
|
|
23921
|
+
*/
|
|
23922
|
+
basecode: {
|
|
23923
|
+
type: String,
|
|
23924
|
+
default: ""
|
|
23904
23925
|
}
|
|
23905
23926
|
}, {
|
|
23906
23927
|
"id": {
|
|
@@ -23919,6 +23940,9 @@ var _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
23919
23940
|
const modeValueId = useModel(__props, "id");
|
|
23920
23941
|
const modeValueName = useModel(__props, "name");
|
|
23921
23942
|
const props = __props;
|
|
23943
|
+
const state = reactive({
|
|
23944
|
+
optionData: props.optionData
|
|
23945
|
+
});
|
|
23922
23946
|
const emit = __emit;
|
|
23923
23947
|
const handCommand = (command) => {
|
|
23924
23948
|
const fitem = props.optionData.find((item) => item[props.bvalue] === command);
|
|
@@ -23926,7 +23950,15 @@ var _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
23926
23950
|
modeValueName.value = fitem != null ? fitem[props.blabel] : "";
|
|
23927
23951
|
emit("change", fitem);
|
|
23928
23952
|
};
|
|
23953
|
+
onMounted(async () => {
|
|
23954
|
+
state.optionData = props.optionData;
|
|
23955
|
+
if (props.basecode && props.basecode != "") {
|
|
23956
|
+
const res = useBaseApi(props.apiService).get(null, props.apiAction + "/?codetype=" + props.basecode);
|
|
23957
|
+
state.optionData = res.data.result ?? [];
|
|
23958
|
+
}
|
|
23959
|
+
});
|
|
23929
23960
|
return (_ctx, _cache) => {
|
|
23961
|
+
const _component_el_button = resolveComponent("el-button");
|
|
23930
23962
|
const _component_el_input = resolveComponent("el-input");
|
|
23931
23963
|
const _component_el_dropdown_item = resolveComponent("el-dropdown-item");
|
|
23932
23964
|
const _component_el_dropdown_menu = resolveComponent("el-dropdown-menu");
|
|
@@ -23945,7 +23977,7 @@ var _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
23945
23977
|
(openBlock(true), createElementBlock(
|
|
23946
23978
|
Fragment,
|
|
23947
23979
|
null,
|
|
23948
|
-
renderList(
|
|
23980
|
+
renderList(state.optionData, (item, index) => {
|
|
23949
23981
|
return openBlock(), createBlock(_component_el_dropdown_item, {
|
|
23950
23982
|
key: index,
|
|
23951
23983
|
command: item[__props.bvalue],
|
|
@@ -23976,7 +24008,19 @@ var _sfc_main$3 = /* @__PURE__ */ defineComponent({
|
|
|
23976
24008
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => modeValueName.value = $event),
|
|
23977
24009
|
placeholder: props.placeholder,
|
|
23978
24010
|
style: normalizeStyle({ width: __props.inputWidth })
|
|
23979
|
-
},
|
|
24011
|
+
}, {
|
|
24012
|
+
append: withCtx(() => [
|
|
24013
|
+
createVNode(_component_el_button, { text: "" }, {
|
|
24014
|
+
default: withCtx(() => _cache[1] || (_cache[1] = [
|
|
24015
|
+
createTextVNode("\u5237\u65B0")
|
|
24016
|
+
])),
|
|
24017
|
+
_: 1,
|
|
24018
|
+
__: [1]
|
|
24019
|
+
})
|
|
24020
|
+
]),
|
|
24021
|
+
_: 1
|
|
24022
|
+
/* STABLE */
|
|
24023
|
+
}, 8, ["modelValue", "placeholder", "style"])
|
|
23980
24024
|
]),
|
|
23981
24025
|
_: 1
|
|
23982
24026
|
/* STABLE */
|
|
@@ -624,6 +624,18 @@ declare const Fminputdropdown: DefineComponent<ExtractPropTypes<{
|
|
|
624
624
|
type: StringConstructor;
|
|
625
625
|
default: string;
|
|
626
626
|
};
|
|
627
|
+
apiService: {
|
|
628
|
+
type: StringConstructor;
|
|
629
|
+
default: string;
|
|
630
|
+
};
|
|
631
|
+
apiAction: {
|
|
632
|
+
type: StringConstructor;
|
|
633
|
+
default: string;
|
|
634
|
+
};
|
|
635
|
+
basecode: {
|
|
636
|
+
type: StringConstructor;
|
|
637
|
+
default: string;
|
|
638
|
+
};
|
|
627
639
|
id: {
|
|
628
640
|
type: PropType<any>;
|
|
629
641
|
};
|
|
@@ -672,6 +684,18 @@ declare const Fminputdropdown: DefineComponent<ExtractPropTypes<{
|
|
|
672
684
|
type: StringConstructor;
|
|
673
685
|
default: string;
|
|
674
686
|
};
|
|
687
|
+
apiService: {
|
|
688
|
+
type: StringConstructor;
|
|
689
|
+
default: string;
|
|
690
|
+
};
|
|
691
|
+
apiAction: {
|
|
692
|
+
type: StringConstructor;
|
|
693
|
+
default: string;
|
|
694
|
+
};
|
|
695
|
+
basecode: {
|
|
696
|
+
type: StringConstructor;
|
|
697
|
+
default: string;
|
|
698
|
+
};
|
|
675
699
|
id: {
|
|
676
700
|
type: PropType<any>;
|
|
677
701
|
};
|
|
@@ -687,8 +711,11 @@ declare const Fminputdropdown: DefineComponent<ExtractPropTypes<{
|
|
|
687
711
|
optionData: any[];
|
|
688
712
|
bvalue: string;
|
|
689
713
|
blabel: string;
|
|
714
|
+
apiService: string;
|
|
715
|
+
apiAction: string;
|
|
690
716
|
inputWidth: string;
|
|
691
717
|
dropWidth: string;
|
|
718
|
+
basecode: string;
|
|
692
719
|
}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
693
720
|
declare const FmTree: DefineComponent<ExtractPropTypes<{
|
|
694
721
|
checkStrictly: {
|
|
@@ -43,6 +43,27 @@ declare const _default: DefineComponent<ExtractPropTypes<{
|
|
|
43
43
|
type: StringConstructor;
|
|
44
44
|
default: string;
|
|
45
45
|
};
|
|
46
|
+
/**
|
|
47
|
+
* api service name
|
|
48
|
+
*/
|
|
49
|
+
apiService: {
|
|
50
|
+
type: StringConstructor;
|
|
51
|
+
default: string;
|
|
52
|
+
};
|
|
53
|
+
/**
|
|
54
|
+
* api service 下的方法
|
|
55
|
+
*/
|
|
56
|
+
apiAction: {
|
|
57
|
+
type: StringConstructor;
|
|
58
|
+
default: string;
|
|
59
|
+
};
|
|
60
|
+
/**
|
|
61
|
+
* 基础编码 自动获取数据
|
|
62
|
+
*/
|
|
63
|
+
basecode: {
|
|
64
|
+
type: StringConstructor;
|
|
65
|
+
default: string;
|
|
66
|
+
};
|
|
46
67
|
id: {
|
|
47
68
|
type: PropType<any>;
|
|
48
69
|
};
|
|
@@ -97,6 +118,27 @@ declare const _default: DefineComponent<ExtractPropTypes<{
|
|
|
97
118
|
type: StringConstructor;
|
|
98
119
|
default: string;
|
|
99
120
|
};
|
|
121
|
+
/**
|
|
122
|
+
* api service name
|
|
123
|
+
*/
|
|
124
|
+
apiService: {
|
|
125
|
+
type: StringConstructor;
|
|
126
|
+
default: string;
|
|
127
|
+
};
|
|
128
|
+
/**
|
|
129
|
+
* api service 下的方法
|
|
130
|
+
*/
|
|
131
|
+
apiAction: {
|
|
132
|
+
type: StringConstructor;
|
|
133
|
+
default: string;
|
|
134
|
+
};
|
|
135
|
+
/**
|
|
136
|
+
* 基础编码 自动获取数据
|
|
137
|
+
*/
|
|
138
|
+
basecode: {
|
|
139
|
+
type: StringConstructor;
|
|
140
|
+
default: string;
|
|
141
|
+
};
|
|
100
142
|
id: {
|
|
101
143
|
type: PropType<any>;
|
|
102
144
|
};
|
|
@@ -112,7 +154,10 @@ declare const _default: DefineComponent<ExtractPropTypes<{
|
|
|
112
154
|
optionData: any[];
|
|
113
155
|
bvalue: string;
|
|
114
156
|
blabel: string;
|
|
157
|
+
apiService: string;
|
|
158
|
+
apiAction: string;
|
|
115
159
|
inputWidth: string;
|
|
116
160
|
dropWidth: string;
|
|
161
|
+
basecode: string;
|
|
117
162
|
}, {}, {}, {}, string, ComponentProvideOptions, true, {}, any>;
|
|
118
163
|
export default _default;
|
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', { value: true });
|
|
4
4
|
|
|
5
5
|
var vue = require('vue');
|
|
6
|
+
var index = require('../../../api/base/index.js');
|
|
6
7
|
|
|
7
8
|
var _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
8
9
|
...{
|
|
@@ -40,6 +41,27 @@ var _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
40
41
|
dropWidth: {
|
|
41
42
|
type: String,
|
|
42
43
|
default: "90px"
|
|
44
|
+
},
|
|
45
|
+
/**
|
|
46
|
+
* api service name
|
|
47
|
+
*/
|
|
48
|
+
apiService: {
|
|
49
|
+
type: String,
|
|
50
|
+
default: "baseData"
|
|
51
|
+
},
|
|
52
|
+
/**
|
|
53
|
+
* api service 下的方法
|
|
54
|
+
*/
|
|
55
|
+
apiAction: {
|
|
56
|
+
type: String,
|
|
57
|
+
default: "baseDataList"
|
|
58
|
+
},
|
|
59
|
+
/**
|
|
60
|
+
* 基础编码 自动获取数据
|
|
61
|
+
*/
|
|
62
|
+
basecode: {
|
|
63
|
+
type: String,
|
|
64
|
+
default: ""
|
|
43
65
|
}
|
|
44
66
|
}, {
|
|
45
67
|
"id": {
|
|
@@ -58,6 +80,9 @@ var _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
58
80
|
const modeValueId = vue.useModel(__props, "id");
|
|
59
81
|
const modeValueName = vue.useModel(__props, "name");
|
|
60
82
|
const props = __props;
|
|
83
|
+
const state = vue.reactive({
|
|
84
|
+
optionData: props.optionData
|
|
85
|
+
});
|
|
61
86
|
const emit = __emit;
|
|
62
87
|
const handCommand = (command) => {
|
|
63
88
|
const fitem = props.optionData.find((item) => item[props.bvalue] === command);
|
|
@@ -65,7 +90,15 @@ var _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
65
90
|
modeValueName.value = fitem != null ? fitem[props.blabel] : "";
|
|
66
91
|
emit("change", fitem);
|
|
67
92
|
};
|
|
93
|
+
vue.onMounted(async () => {
|
|
94
|
+
state.optionData = props.optionData;
|
|
95
|
+
if (props.basecode && props.basecode != "") {
|
|
96
|
+
const res = index.useBaseApi(props.apiService).get(null, props.apiAction + "/?codetype=" + props.basecode);
|
|
97
|
+
state.optionData = res.data.result ?? [];
|
|
98
|
+
}
|
|
99
|
+
});
|
|
68
100
|
return (_ctx, _cache) => {
|
|
101
|
+
const _component_el_button = vue.resolveComponent("el-button");
|
|
69
102
|
const _component_el_input = vue.resolveComponent("el-input");
|
|
70
103
|
const _component_el_dropdown_item = vue.resolveComponent("el-dropdown-item");
|
|
71
104
|
const _component_el_dropdown_menu = vue.resolveComponent("el-dropdown-menu");
|
|
@@ -84,7 +117,7 @@ var _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
84
117
|
(vue.openBlock(true), vue.createElementBlock(
|
|
85
118
|
vue.Fragment,
|
|
86
119
|
null,
|
|
87
|
-
vue.renderList(
|
|
120
|
+
vue.renderList(state.optionData, (item, index) => {
|
|
88
121
|
return vue.openBlock(), vue.createBlock(_component_el_dropdown_item, {
|
|
89
122
|
key: index,
|
|
90
123
|
command: item[__props.bvalue],
|
|
@@ -115,7 +148,19 @@ var _sfc_main = /* @__PURE__ */ vue.defineComponent({
|
|
|
115
148
|
"onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => modeValueName.value = $event),
|
|
116
149
|
placeholder: props.placeholder,
|
|
117
150
|
style: vue.normalizeStyle({ width: __props.inputWidth })
|
|
118
|
-
},
|
|
151
|
+
}, {
|
|
152
|
+
append: vue.withCtx(() => [
|
|
153
|
+
vue.createVNode(_component_el_button, { text: "" }, {
|
|
154
|
+
default: vue.withCtx(() => _cache[1] || (_cache[1] = [
|
|
155
|
+
vue.createTextVNode("\u5237\u65B0")
|
|
156
|
+
])),
|
|
157
|
+
_: 1,
|
|
158
|
+
__: [1]
|
|
159
|
+
})
|
|
160
|
+
]),
|
|
161
|
+
_: 1
|
|
162
|
+
/* STABLE */
|
|
163
|
+
}, 8, ["modelValue", "placeholder", "style"])
|
|
119
164
|
]),
|
|
120
165
|
_: 1
|
|
121
166
|
/* STABLE */
|
package/package.json
CHANGED
|
File without changes
|