@fmdevui/fm-dev 1.0.86 → 1.0.88
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/index.d.ts +1 -0
- package/es/core/utils/cityparess/index.d.ts +6 -0
- package/es/index.mjs +1 -0
- package/es/packages/core/index.mjs +1 -0
- package/es/packages/core/ui/components/fmaddressparsing/index.vue2.mjs +40 -22
- package/es/packages/core/utils/cityparess/index.mjs +44877 -0
- package/es/{defaults.css → version.css} +2 -1
- package/index.js +3560 -23
- package/index.min.js +30 -30
- package/index.min.mjs +30 -30
- package/index.mjs +3560 -24
- package/lib/core/index.d.ts +1 -0
- package/lib/core/utils/cityparess/index.d.ts +6 -0
- package/lib/index.js +2 -0
- package/lib/packages/core/index.js +2 -0
- package/lib/packages/core/ui/components/fmaddressparsing/index.vue2.js +40 -22
- package/lib/packages/core/utils/cityparess/index.js +44879 -0
- package/package.json +1 -1
package/es/core/index.d.ts
CHANGED
package/es/index.mjs
CHANGED
|
@@ -38,6 +38,7 @@ export { PUB } from './packages/core/utils/const/index.mjs';
|
|
|
38
38
|
export { auth, authAll, auths, hAuth, hAuthAll, hAuths } from './packages/core/auth/index.mjs';
|
|
39
39
|
export { useDateTimeShortCust } from './packages/core/hook/dateTimeShortCust.mjs';
|
|
40
40
|
export { useVxeTable } from './packages/core/hook/useVxeTableOptionsHook.mjs';
|
|
41
|
+
export { addressparsing } from './packages/core/utils/cityparess/index.mjs';
|
|
41
42
|
|
|
42
43
|
const install = installer.install;
|
|
43
44
|
|
|
@@ -9,6 +9,7 @@ import './utils/index.mjs';
|
|
|
9
9
|
export { auth, authAll, auths, hAuth, hAuthAll, hAuths } from './auth/index.mjs';
|
|
10
10
|
export { useDateTimeShortCust } from './hook/dateTimeShortCust.mjs';
|
|
11
11
|
export { useVxeTable } from './hook/useVxeTableOptionsHook.mjs';
|
|
12
|
+
export { addressparsing } from './utils/cityparess/index.mjs';
|
|
12
13
|
import './types/index.mjs';
|
|
13
14
|
export { elSvg } from './ui/components/svgIcon/index.mjs';
|
|
14
15
|
export { useApi, useBaseApi } from './api/base/index.mjs';
|
|
@@ -57,9 +57,9 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
57
57
|
if (newValue.length < 2) {
|
|
58
58
|
return;
|
|
59
59
|
}
|
|
60
|
-
let cityobj = chkeCity(newValue.substr(0, 2));
|
|
60
|
+
let cityobj = chkeCity(province, newValue.substr(0, 2));
|
|
61
61
|
if (cityobj.c == "" && newValue.length > 2) {
|
|
62
|
-
cityobj = chkeCity(newValue.substr(0, 3));
|
|
62
|
+
cityobj = chkeCity(province, newValue.substr(0, 3));
|
|
63
63
|
if (cityobj.c != "" && province == "") {
|
|
64
64
|
province = cityobj.p;
|
|
65
65
|
}
|
|
@@ -68,29 +68,29 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
68
68
|
if (newValue.length < 2) {
|
|
69
69
|
return;
|
|
70
70
|
}
|
|
71
|
-
let countyOjb = chkeCounty(newValue.substr(0, 2));
|
|
71
|
+
let countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 2));
|
|
72
72
|
if (countyOjb.x == "" && newValue.length > 2) {
|
|
73
|
-
countyOjb = chkeCounty(newValue.substr(0, 3));
|
|
73
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 3));
|
|
74
74
|
if (countyOjb.x == "" && newValue.length > 3) {
|
|
75
|
-
countyOjb = chkeCounty(newValue.substr(0, 4));
|
|
75
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 4));
|
|
76
76
|
if (countyOjb.x == "" && newValue.length > 4) {
|
|
77
|
-
countyOjb = chkeCounty(newValue.substr(0, 5));
|
|
77
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 5));
|
|
78
78
|
if (countyOjb.x == "" && newValue.length > 5) {
|
|
79
|
-
countyOjb = chkeCounty(newValue.substr(0, 6));
|
|
79
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 6));
|
|
80
80
|
if (countyOjb.x == "" && newValue.length > 6) {
|
|
81
|
-
countyOjb = chkeCounty(newValue.substr(0, 7));
|
|
81
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 7));
|
|
82
82
|
if (countyOjb.x == "" && newValue.length > 7) {
|
|
83
|
-
countyOjb = chkeCounty(newValue.substr(0, 8));
|
|
83
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 8));
|
|
84
84
|
if (countyOjb.x == "" && newValue.length > 8) {
|
|
85
|
-
countyOjb = chkeCounty(newValue.substr(0, 9));
|
|
85
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 9));
|
|
86
86
|
if (countyOjb.x == "" && newValue.length > 9) {
|
|
87
|
-
countyOjb = chkeCounty(newValue.substr(0, 10));
|
|
87
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 10));
|
|
88
88
|
if (countyOjb.x == "" && newValue.length > 10) {
|
|
89
|
-
countyOjb = chkeCounty(newValue.substr(0, 11));
|
|
89
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 11));
|
|
90
90
|
if (countyOjb.x == "" && newValue.length > 11) {
|
|
91
|
-
countyOjb = chkeCounty(newValue.substr(0, 12));
|
|
91
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 12));
|
|
92
92
|
if (countyOjb.x == "" && newValue.length > 12) {
|
|
93
|
-
countyOjb = chkeCounty(newValue.substr(0, 13));
|
|
93
|
+
countyOjb = chkeCounty(province, cityobj.c, newValue.substr(0, 13));
|
|
94
94
|
}
|
|
95
95
|
}
|
|
96
96
|
}
|
|
@@ -180,7 +180,7 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
180
180
|
}
|
|
181
181
|
return province;
|
|
182
182
|
};
|
|
183
|
-
const chkeCity = (val) => {
|
|
183
|
+
const chkeCity = (province, val) => {
|
|
184
184
|
if (val == null || val == void 0 || val == "") {
|
|
185
185
|
return { p: "", c: "" };
|
|
186
186
|
}
|
|
@@ -190,15 +190,24 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
190
190
|
const arrTemp = cityData[i].split("|");
|
|
191
191
|
const arr = arrTemp.filter((item) => item == val);
|
|
192
192
|
if (arr && arr.length > 0) {
|
|
193
|
-
|
|
194
|
-
|
|
193
|
+
if (province != "") {
|
|
194
|
+
if (cityData[i].split("|")[0] == province) {
|
|
195
|
+
cityobj.p = cityData[i].split("|")[0];
|
|
196
|
+
cityobj.c = cityData[i].split("|")[1];
|
|
197
|
+
break;
|
|
198
|
+
}
|
|
199
|
+
} else {
|
|
200
|
+
cityobj.p = cityData[i].split("|")[0];
|
|
201
|
+
cityobj.c = cityData[i].split("|")[1];
|
|
202
|
+
break;
|
|
203
|
+
}
|
|
195
204
|
break;
|
|
196
205
|
}
|
|
197
206
|
}
|
|
198
207
|
}
|
|
199
208
|
return cityobj;
|
|
200
209
|
};
|
|
201
|
-
const chkeCounty = (val) => {
|
|
210
|
+
const chkeCounty = (province, city, val) => {
|
|
202
211
|
if (val == null || val == void 0 || val == "") {
|
|
203
212
|
return { p: "", c: "", x: "" };
|
|
204
213
|
}
|
|
@@ -208,10 +217,19 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
208
217
|
const arrTemp = countyData[i].split("|");
|
|
209
218
|
const arr = arrTemp.filter((item) => item == val);
|
|
210
219
|
if (arr && arr.length > 0) {
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
220
|
+
if (province != "" && city != "") {
|
|
221
|
+
if (countyData[i].split("|")[0] == province && countyData[i].split("|")[1] == city) {
|
|
222
|
+
countyobj.p = countyData[i].split("|")[0];
|
|
223
|
+
countyobj.c = countyData[i].split("|")[1];
|
|
224
|
+
countyobj.x = countyData[i].split("|")[2];
|
|
225
|
+
break;
|
|
226
|
+
}
|
|
227
|
+
} else {
|
|
228
|
+
countyobj.p = countyData[i].split("|")[0];
|
|
229
|
+
countyobj.c = countyData[i].split("|")[1];
|
|
230
|
+
countyobj.x = countyData[i].split("|")[2];
|
|
231
|
+
break;
|
|
232
|
+
}
|
|
215
233
|
}
|
|
216
234
|
}
|
|
217
235
|
}
|