@das-fed/ui 6.4.0-dev.51 → 6.4.0-dev.53

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.
Files changed (187) hide show
  1. package/esm-map.json +3 -1
  2. package/i18n-collection/en.js +426 -425
  3. package/i18n-collection/zh-CN.js +437 -437
  4. package/package.json +5 -5
  5. package/packages/business-components/change-enterprises/i18n/index.d.ts +15 -0
  6. package/packages/business-components/change-enterprises/index.js +51 -45
  7. package/packages/business-components/change-enterprises/index.js.gz +0 -0
  8. package/packages/business-components/change-pwd/i18n/index.d.ts +77 -1
  9. package/packages/business-components/change-pwd/index.js +118 -99
  10. package/packages/business-components/change-pwd/index.js.gz +0 -0
  11. package/packages/business-components/currency-page/i18n/index.d.ts +19 -0
  12. package/packages/business-components/currency-page/index.js +27 -20
  13. package/packages/business-components/currency-page/index.js.gz +0 -0
  14. package/packages/business-components/device-panel/i18n/index.d.ts +767 -0
  15. package/packages/business-components/device-panel/index.js +4961 -4767
  16. package/packages/business-components/device-panel/index.js.gz +0 -0
  17. package/packages/business-components/device-panel/style.css +1 -1
  18. package/packages/business-components/device-panel/style.css.gz +0 -0
  19. package/packages/business-components/export-button/i18n/index.d.ts +51 -0
  20. package/packages/business-components/export-button/index.js +117 -102
  21. package/packages/business-components/export-button/index.js.gz +0 -0
  22. package/packages/business-components/import-button/i18n/index.d.ts +103 -0
  23. package/packages/business-components/import-button/index.js +220 -192
  24. package/packages/business-components/import-button/index.js.gz +0 -0
  25. package/packages/business-components/model-table-dialog/i18n/index.d.ts +27 -0
  26. package/packages/business-components/model-table-dialog/index.js +663 -660
  27. package/packages/business-components/model-table-dialog/index.js.gz +0 -0
  28. package/packages/business-components/model-table-dialog/src/ModelTable.vue.d.ts +48 -16
  29. package/packages/business-components/model-table-dialog/style.css +1 -1
  30. package/packages/business-components/model-table-dialog/style.css.gz +0 -0
  31. package/packages/business-components/process-configuration/i18n/index.d.ts +114 -1
  32. package/packages/business-components/process-configuration/index.js +158 -130
  33. package/packages/business-components/process-configuration/index.js.gz +0 -0
  34. package/packages/business-components/process-form/api-service/formPreView.d.ts +7 -0
  35. package/packages/business-components/process-form/apis.d.ts +1 -0
  36. package/packages/business-components/process-form/i18n/index.d.ts +279 -0
  37. package/packages/business-components/process-form/index.js +1170 -1071
  38. package/packages/business-components/process-form/index.js.gz +0 -0
  39. package/packages/business-components/process-form/src/widgets/store.d.ts +1 -0
  40. package/packages/business-components/process-form/style.css +1 -1
  41. package/packages/business-components/process-log/i18n/index.d.ts +33 -1
  42. package/packages/business-components/process-log/index.js +151 -146
  43. package/packages/business-components/process-log/index.js.gz +0 -0
  44. package/packages/business-components/process-search-form/i18n/index.d.ts +39 -0
  45. package/packages/business-components/process-search-form/index.d.ts +2 -2
  46. package/packages/business-components/process-search-form/index.js +420 -389
  47. package/packages/business-components/process-search-form/index.js.gz +0 -0
  48. package/packages/business-components/process-search-form/src/App.vue.d.ts +2 -2
  49. package/packages/business-components/process-search-form/src/type.d.ts +1 -1
  50. package/packages/business-components/process-table/i18n/index.d.ts +35 -0
  51. package/packages/business-components/process-table/index.js +265 -254
  52. package/packages/business-components/process-table/index.js.gz +0 -0
  53. package/packages/business-components/upload-file/i18n/index.d.ts +7 -0
  54. package/packages/business-components/upload-file/index.js +43 -38
  55. package/packages/business-components/upload-file/index.js.gz +0 -0
  56. package/packages/business-components/upload-file/src/type.d.ts +3 -0
  57. package/packages/business-components/urgent-panel/i18n/index.d.ts +331 -0
  58. package/packages/business-components/urgent-panel/index.js +900 -814
  59. package/packages/business-components/urgent-panel/index.js.gz +0 -0
  60. package/packages/business-components/user-org-dialog/i18n/index.d.ts +53 -1
  61. package/packages/business-components/user-org-dialog/index.js +196 -186
  62. package/packages/business-components/user-org-dialog/index.js.gz +0 -0
  63. package/packages/business-components/video-dialog/i18n/index.d.ts +71 -0
  64. package/packages/business-components/video-dialog/index.js +199 -179
  65. package/packages/business-components/video-dialog/index.js.gz +0 -0
  66. package/packages/components/button/i18n/index.d.ts +1 -6
  67. package/packages/components/button/index.js +16 -21
  68. package/packages/components/button/index.js.gz +0 -0
  69. package/packages/components/calendar/i18n/index.d.ts +52 -44
  70. package/packages/components/calendar/index.js +77 -75
  71. package/packages/components/calendar/index.js.gz +0 -0
  72. package/packages/components/cascader/i18n/index.d.ts +7 -0
  73. package/packages/components/cascader/index.js +38 -35
  74. package/packages/components/cascader/index.js.gz +0 -0
  75. package/packages/components/color-picker/i18n/index.d.ts +7 -0
  76. package/packages/components/color-picker/index.js +37 -34
  77. package/packages/components/color-picker/index.js.gz +0 -0
  78. package/packages/components/custom-search-item/i18n/index.d.ts +7 -0
  79. package/packages/components/custom-search-item/index.js +27 -24
  80. package/packages/components/custom-search-item/index.js.gz +0 -0
  81. package/packages/components/date-picker/i18n/index.d.ts +15 -0
  82. package/packages/components/date-picker/index.js +81 -76
  83. package/packages/components/date-picker/index.js.gz +0 -0
  84. package/packages/components/dialog/i18n/index.d.ts +6 -6
  85. package/packages/components/dialog/index.js +58 -58
  86. package/packages/components/dialog/index.js.gz +0 -0
  87. package/packages/components/dimple-layout/i18n/index.d.ts +43 -0
  88. package/packages/components/dimple-layout/index.js +1077 -1064
  89. package/packages/components/dimple-layout/index.js.gz +0 -0
  90. package/packages/components/dropdown/i18n/index.d.ts +7 -0
  91. package/packages/components/dropdown/index.js +32 -29
  92. package/packages/components/dropdown/index.js.gz +0 -0
  93. package/packages/components/empty/index.js +14 -16
  94. package/packages/components/empty/index.js.gz +0 -0
  95. package/packages/components/image-upload/i18n/index.d.ts +27 -3
  96. package/packages/components/image-upload/index.js +84 -78
  97. package/packages/components/image-upload/index.js.gz +0 -0
  98. package/packages/components/image-viewer/i18n/index.d.ts +31 -0
  99. package/packages/components/image-viewer/index.js +246 -237
  100. package/packages/components/image-viewer/index.js.gz +0 -0
  101. package/packages/components/input/i18n/index.d.ts +15 -0
  102. package/packages/components/input/index.js +50 -45
  103. package/packages/components/input/index.js.gz +0 -0
  104. package/packages/components/input-dialog-select/i18n/index.d.ts +1 -1
  105. package/packages/components/input-dialog-select/index.js +20 -23
  106. package/packages/components/input-dialog-select/index.js.gz +0 -0
  107. package/packages/components/live-player/i18n/index.d.ts +15 -0
  108. package/packages/components/live-player/index.js +15 -9
  109. package/packages/components/live-player/index.js.gz +0 -0
  110. package/packages/components/loading/i18n/index.d.ts +7 -0
  111. package/packages/components/loading/index.js +93 -90
  112. package/packages/components/loading/index.js.gz +0 -0
  113. package/packages/components/map/i18n/index.d.ts +23 -0
  114. package/packages/components/map/index.js +355 -347
  115. package/packages/components/map/index.js.gz +0 -0
  116. package/packages/components/menu-aside/i18n/index.d.ts +7 -0
  117. package/packages/components/menu-aside/index.js +150 -147
  118. package/packages/components/menu-aside/index.js.gz +0 -0
  119. package/packages/components/message/i18n/index.d.ts +7 -0
  120. package/packages/components/message/index.js +17 -14
  121. package/packages/components/message/index.js.gz +0 -0
  122. package/packages/components/notification/i18n/index.d.ts +7 -0
  123. package/packages/components/notification/index.js +10 -7
  124. package/packages/components/notification/index.js.gz +0 -0
  125. package/packages/components/pagination/i18n/index.d.ts +19 -0
  126. package/packages/components/pagination/index.js +81 -75
  127. package/packages/components/pagination/index.js.gz +0 -0
  128. package/packages/components/popover/i18n/index.d.ts +2 -2
  129. package/packages/components/preview/i18n/index.d.ts +1 -1
  130. package/packages/components/preview/index.js +1 -1
  131. package/packages/components/preview/index.js.gz +0 -0
  132. package/packages/components/rich-editor/i18n/index.d.ts +10 -3
  133. package/packages/components/rich-editor/index.js +4 -3
  134. package/packages/components/rich-editor/index.js.gz +0 -0
  135. package/packages/components/search/i18n/index.d.ts +25 -1
  136. package/packages/components/search/index.js +31 -28
  137. package/packages/components/search/index.js.gz +0 -0
  138. package/packages/components/select/i18n/index.d.ts +23 -0
  139. package/packages/components/select/index.js +204 -197
  140. package/packages/components/select/index.js.gz +0 -0
  141. package/packages/components/select-list/i18n/index.d.ts +4 -4
  142. package/packages/components/select-list/index.js +4 -4
  143. package/packages/components/select-list/index.js.gz +0 -0
  144. package/packages/components/special-range-picker-month/i18n/index.d.ts +4 -4
  145. package/packages/components/special-range-picker-month/index.js +15 -15
  146. package/packages/components/special-range-picker-month/index.js.gz +0 -0
  147. package/packages/components/special-range-picker-year/i18n/index.d.ts +3 -3
  148. package/packages/components/special-range-picker-year/index.js +81 -81
  149. package/packages/components/special-range-picker-year/index.js.gz +0 -0
  150. package/packages/components/spin/i18n/index.d.ts +7 -0
  151. package/packages/components/spin/index.js +35 -32
  152. package/packages/components/spin/index.js.gz +0 -0
  153. package/packages/components/table/i18n/index.d.ts +72 -2
  154. package/packages/components/table/index.js +1245 -1225
  155. package/packages/components/table/index.js.gz +0 -0
  156. package/packages/components/tabs/i18n/index.d.ts +15 -0
  157. package/packages/components/tabs/index.js +70 -65
  158. package/packages/components/tabs/index.js.gz +0 -0
  159. package/packages/components/time-line/i18n/index.d.ts +1 -1
  160. package/packages/components/time-line/index.js +6 -9
  161. package/packages/components/time-line/index.js.gz +0 -0
  162. package/packages/components/tooltip/i18n/index.d.ts +7 -0
  163. package/packages/components/tooltip/index.js +38 -35
  164. package/packages/components/tooltip/index.js.gz +0 -0
  165. package/packages/components/tree/i18n/index.d.ts +35 -0
  166. package/packages/components/tree/index.js +692 -682
  167. package/packages/components/tree/index.js.gz +0 -0
  168. package/packages/components/tree-table/index.js +69 -68
  169. package/packages/components/tree-table/index.js.gz +0 -0
  170. package/packages/components/tree-table/style.css +1 -1
  171. package/packages/components/tree-table/style.css.gz +0 -0
  172. package/packages/components/upload/i18n/index.d.ts +5 -5
  173. package/packages/components/upload/index.js +50 -50
  174. package/packages/components/upload/index.js.gz +0 -0
  175. package/packages/components/virtual-tree/i18n/index.d.ts +7 -0
  176. package/packages/components/virtual-tree/index.js +35 -31
  177. package/packages/components/virtual-tree/index.js.gz +0 -0
  178. package/packages/icons/edit-3/index.d.ts +1 -0
  179. package/packages/icons/edit-3/index.js +17 -0
  180. package/packages/icons/edit-3/index.js.gz +0 -0
  181. package/packages/icons/edit-3/index.vue.d.ts +16 -0
  182. package/packages/icons/index.d.ts +2 -0
  183. package/packages/icons/index.js +2 -0
  184. package/packages/icons/right-3/index.d.ts +1 -0
  185. package/packages/icons/right-3/index.js +17 -0
  186. package/packages/icons/right-3/index.js.gz +0 -0
  187. package/packages/icons/right-3/index.vue.d.ts +16 -0
@@ -1,79 +1,79 @@
1
1
  import '@das-fed/ui/packages/business-components/import-button/style.css';
2
2
  import { withInstall as fe } from "@das-fed/utils/with-install/index";
3
- import { ref as y, defineComponent as ge, watch as ve, openBlock as xe, createElementBlock as ye, createElementVNode as K, unref as l, renderSlot as se, createVNode as P, withCtx as V, createTextVNode as _, toDisplayString as A, createCommentVNode as oe, isRef as Q } from "vue";
4
- import { t as p, i18n as M } from "@das-fed/web/packages/i18n/index";
3
+ import { ref as x, defineComponent as ge, watch as ve, openBlock as he, createElementBlock as xe, createElementVNode as K, unref as l, renderSlot as se, createVNode as U, withCtx as R, createTextVNode as _, toDisplayString as A, createCommentVNode as oe, isRef as Q } from "vue";
4
+ import { t as p, i18n as M, setI18nRule as ye } from "@das-fed/web/packages/i18n/index";
5
5
  import { DasDialog as re } from "@das-fed/ui/packages/components/dialog/index";
6
6
  import { DasUpload as we } from "@das-fed/ui/packages/components/upload/index";
7
- import { DasProgress as he } from "@das-fed/ui/packages/components/progress/index";
7
+ import { DasProgress as Ne } from "@das-fed/ui/packages/components/progress/index";
8
8
  import { DasButton as W } from "@das-fed/ui/packages/components/button/index";
9
9
  import { iotMinio as ae, iotProgress as be } from "@das-fed/utils/api-services/modules/iot";
10
10
  import { DasMessage as L } from "@das-fed/ui/packages/components/message/index";
11
- import Te from "dayjs";
12
- import { getConfig as ie } from "@das-fed/utils/config";
13
- import { extractFilename as ke } from "@das-fed/utils/common-tools";
14
- import { getUserInfo as $e } from "@das-fed/utils/common-info/index";
15
- import { pureImageSrc as ne } from "@das-fed/utils/pure-image-src";
11
+ import Ce from "dayjs";
12
+ import { getConfig as ne } from "@das-fed/utils/config";
13
+ import { extractFilename as ze } from "@das-fed/utils/common-tools";
14
+ import { getUserInfo as Te } from "@das-fed/utils/common-info/index";
15
+ import { pureImageSrc as ie } from "@das-fed/utils/pure-image-src";
16
16
  let te = (e = 21) => {
17
17
  let c = "", m = crypto.getRandomValues(new Uint8Array(e));
18
18
  for (; e--; ) {
19
- let i = m[e] & 63;
20
- i < 36 ? c += i.toString(36) : i < 62 ? c += (i - 26).toString(36).toUpperCase() : i < 63 ? c += "_" : c += "-";
19
+ let n = m[e] & 63;
20
+ n < 36 ? c += n.toString(36) : n < 62 ? c += (n - 26).toString(36).toUpperCase() : n < 63 ? c += "_" : c += "-";
21
21
  }
22
22
  return c;
23
23
  };
24
- const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.headers = {}), e.headers["Content-Type"] = "multipart/form-data", e.responseType = "blob", e)), Ie = ae.post("upload-objects", (e) => (e.headers || (e.headers = {}), e.headers["Content-Type"] = "multipart/form-data", e.responseType = "blob", e)), Ue = be.get("progress"), Ce = (e) => {
25
- let c = y(!1), m = y(!1), i = y(""), x = y(0), u = y("normal"), w = y(!1), g, N = y(""), z = y(""), U = y(""), $ = y(""), C = y(!1), j = y(""), F = "", I = y(""), D;
26
- const h = () => {
27
- z.value = "", U.value = "", $.value = "", C.value = !1, j.value = "";
28
- }, B = async () => {
29
- const [s, o] = await Ne().run();
24
+ const ke = ae.get("token"), $e = ae.post("put-object", (e) => (e.headers || (e.headers = {}), e.headers["Content-Type"] = "multipart/form-data", e.responseType = "blob", e)), Ie = ae.post("upload-objects", (e) => (e.headers || (e.headers = {}), e.headers["Content-Type"] = "multipart/form-data", e.responseType = "blob", e)), Fe = be.get("progress"), Pe = (e) => {
25
+ let c = x(!1), m = x(!1), n = x(""), h = x(0), u = x("normal"), y = x(!1), g, T = x(""), D = x(""), I = x(""), z = x(""), F = x(!1), j = x(""), k = "", $ = x(""), P;
26
+ const w = () => {
27
+ D.value = "", I.value = "", z.value = "", F.value = !1, j.value = "";
28
+ }, E = async () => {
29
+ const [s, o] = await ke().run();
30
30
  return s ? { stauts: !1 } : { status: !0, data: o };
31
- }, R = (s) => new Promise((o, a) => {
32
- const n = [];
31
+ }, V = (s) => new Promise((o, a) => {
32
+ const i = [];
33
33
  let t = 0;
34
34
  for (; t < s.size; ) {
35
- const T = s.slice(t, t + 1048576);
36
- n.push(T), t += 1048576;
35
+ const b = s.slice(t, t + 1048576);
36
+ i.push(b), t += 1048576;
37
37
  }
38
- const b = new Blob(n, { type: s.type });
39
- o(b);
40
- }), E = async (s, o, a, r = !1, n = !0, t = "") => {
41
- F = t, I.value = "import", n && (u.value = "normal", x.value = 0, i.value = p("导入进度"), m.value = !0, N.value = ""), D = o;
42
- const b = await B();
43
- if (!b.status) return;
44
- let T = b.data, k = null, { autoContentType: Y, bucketName: H, importFileName: J } = a;
45
- const me = r ? Ie : Fe;
38
+ const N = new Blob(i, { type: s.type });
39
+ o(N);
40
+ }), B = async (s, o, a, r = !1, i = !0, t = "") => {
41
+ k = t, $.value = "import", i && (u.value = "normal", h.value = 0, n.value = p("导入进度"), m.value = !0, T.value = ""), P = o;
42
+ const N = await E();
43
+ if (!N.status) return;
44
+ let b = N.data, C = null, { autoContentType: Y, bucketName: H, importFileName: J } = a;
45
+ const me = r ? Ie : $e;
46
46
  if (r) {
47
47
  let X = [];
48
48
  await o.forEach(async (G) => {
49
- let ee = await R(G);
49
+ let ee = await V(G);
50
50
  X.push(ee);
51
- }), k = new FormData(), k.append("accessKeyId", T.accessKeyId), k.append("secretAccessKey", T.secretAccessKey), k.append("sessionToken", T.sessionToken), k.append("bucketName", H), o.forEach((G, ee) => {
52
- k.append("file", X[ee]);
51
+ }), C = new FormData(), C.append("accessKeyId", b.accessKeyId), C.append("secretAccessKey", b.secretAccessKey), C.append("sessionToken", b.sessionToken), C.append("bucketName", H), o.forEach((G, ee) => {
52
+ C.append("file", X[ee]);
53
53
  }), J.forEach((G) => {
54
- k.append("filePaths", G);
54
+ C.append("filePaths", G);
55
55
  });
56
56
  } else {
57
- const X = await R(o);
58
- k = {
59
- accessKeyId: T.accessKeyId,
60
- secretAccessKey: T.secretAccessKey,
61
- sessionToken: T.sessionToken,
57
+ const X = await V(o);
58
+ C = {
59
+ accessKeyId: b.accessKeyId,
60
+ secretAccessKey: b.secretAccessKey,
61
+ sessionToken: b.sessionToken,
62
62
  file: X,
63
63
  bucketName: H,
64
64
  filePath: J,
65
65
  autoContentType: Y
66
66
  };
67
67
  }
68
- const [pe, ce] = await me(k).run();
68
+ const [pe, ce] = await me(C).run();
69
69
  if (pe) return;
70
- const de = await ze(ce.data), Z = await (s == null ? void 0 : s(de));
71
- if (n) {
70
+ const de = await Se(ce.data), Z = await (s == null ? void 0 : s(de));
71
+ if (i) {
72
72
  if (!Z.status) {
73
73
  m.value = !1, u.value = "error";
74
74
  return;
75
75
  }
76
- i.value = p("导入进度"), m.value = !0, d(Z.taskId, "import", "");
76
+ n.value = p("导入进度"), m.value = !0, d(Z.taskId, "import", "");
77
77
  } else {
78
78
  if (!Z.status) return;
79
79
  u.value = "success", L.success({
@@ -83,7 +83,7 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
83
83
  });
84
84
  }
85
85
  }, O = async (s, o = "", a = "") => {
86
- u.value = "normal", x.value = 0, i.value = a || p("导出进度"), m.value = !0;
86
+ u.value = "normal", h.value = 0, n.value = a || p("导出进度"), m.value = !0;
87
87
  const r = await (s == null ? void 0 : s());
88
88
  if (!r.status) {
89
89
  m.value = !1, u.value = "error";
@@ -91,57 +91,57 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
91
91
  }
92
92
  d(r.taskId, "action", "");
93
93
  }, S = async (s, o = "", a = "xlsx") => {
94
- I.value = "export", u.value = "normal", x.value = 0, i.value = p("导出进度"), m.value = !0;
94
+ $.value = "export", u.value = "normal", h.value = 0, n.value = p("导出进度"), m.value = !0;
95
95
  const r = await (s == null ? void 0 : s());
96
96
  if (!r.status) {
97
97
  m.value = !1, u.value = "error";
98
98
  return;
99
99
  }
100
- Te().format("YYYYMMDDHHmmss") + "", d(r.taskId, "export", o || "", a);
100
+ Ce().format("YYYYMMDDHHmmss") + "", d(r.taskId, "export", o || "", a);
101
101
  }, d = async (s, o, a, r = "") => {
102
- w.value = !0, v(s, o, a, r), g = setTimeout(() => {
102
+ y.value = !0, v(s, o, a, r), g = setTimeout(() => {
103
103
  }, 50);
104
104
  }, f = () => {
105
105
  clearTimeout(g), g = null, m.value = !1;
106
106
  }, v = async (s, o = "export", a, r = "") => {
107
- var T, k;
108
- const [n, t] = await Ue("", {
107
+ var b, C;
108
+ const [i, t] = await Fe("", {
109
109
  url: `progress/${s}`
110
110
  }).run();
111
- if (n) {
112
- w.value = !1;
111
+ if (i) {
112
+ y.value = !1;
113
113
  return;
114
114
  }
115
- x.value = t.percentage;
116
- const b = o == "export" ? p("导出") : p("导入");
117
- if (x.value == 100)
118
- if (N.value = t, w.value = !1, f(), o == "export")
119
- t.status == 1 ? (u.value = "success", ue(`${ie().baseURL}/oss${t.filePath}`, a, r), w.value = !1) : t.status == 2 && ($.value = t.message || `${b}${p("失败")}`, L.error({
120
- message: t.message || `${b}${p("失败")}`,
115
+ h.value = t.percentage;
116
+ const N = o == "export" ? p("导出") : p("导入");
117
+ if (h.value == 100)
118
+ if (T.value = t, y.value = !1, f(), o == "export")
119
+ t.status == 1 ? (u.value = "success", ue(`${ne().baseURL}/oss${t.filePath}`, a, r), y.value = !1) : t.status == 2 && (z.value = t.message || `${N}${p("失败")}`, L.error({
120
+ message: t.message || `${N}${p("失败")}`,
121
121
  grouping: !0,
122
122
  repeatNum: 1
123
123
  }));
124
124
  else if (o == "import") {
125
125
  if (t.filePath) {
126
126
  u.value = "error";
127
- const Y = (T = D.name) == null ? void 0 : T.match(/(.*?)(\.[^.]*$|$)/);
128
- Y.length && Y[2], C.value = !0;
129
- let H = await ke(`/oss/${t == null ? void 0 : t.filePath}`);
130
- const J = ((k = H == null ? void 0 : H.split("/")) == null ? void 0 : k.pop()) || "";
131
- z.value = F || J, U.value = D.sizeText, $.value = p("部分数据校验不通过,请下载附件并修改,重新导入!"), j.value = `${ie().baseURL}/oss/${t == null ? void 0 : t.filePath}`;
127
+ const Y = (b = P.name) == null ? void 0 : b.match(/(.*?)(\.[^.]*$|$)/);
128
+ Y.length && Y[2], F.value = !0;
129
+ let H = await ze(`/oss/${t == null ? void 0 : t.filePath}`);
130
+ const J = ((C = H == null ? void 0 : H.split("/")) == null ? void 0 : C.pop()) || "";
131
+ D.value = k || J, I.value = P.sizeText, z.value = p("部分数据校验不通过,请下载附件并修改,重新导入!"), j.value = `${ne().baseURL}/oss/${t == null ? void 0 : t.filePath}`;
132
132
  }
133
- q(t.status, b, t.message), t.status == 1 && (c.value = !1), e("success");
133
+ q(t.status, N, t.message), t.status == 1 && (c.value = !1), e("success");
134
134
  } else o == "action" && (u.value = "success");
135
135
  else
136
136
  g && t.status != 2 ? g = setTimeout(() => {
137
137
  v(s, o, a, r);
138
- }, 50) : (N.value = t, w.value = !1, q(t.status, b, t.message), f(), C.value = !0, $.value = (t == null ? void 0 : t.message) || "", e("error", t));
138
+ }, 50) : (T.value = t, y.value = !1, q(t.status, N, t.message), f(), F.value = !0, z.value = (t == null ? void 0 : t.message) || "", e("error", t));
139
139
  }, q = (s, o, a) => {
140
140
  s == 1 ? (u.value = "success", L.success({
141
141
  message: `${o}${p("成功")}`,
142
142
  grouping: !0,
143
143
  repeatNum: 1
144
- }), z.value = "", U.value = "", $.value = "") : s == 2 ? (u.value = "error", L.error({
144
+ }), D.value = "", I.value = "", z.value = "") : s == 2 ? (u.value = "error", L.error({
145
145
  message: a || `${o}${p("失败")}`,
146
146
  grouping: !0,
147
147
  repeatNum: 1
@@ -154,18 +154,18 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
154
154
  return {
155
155
  importDialog: c,
156
156
  showProgressDialog: m,
157
- progressTitle: i,
158
- percent: x,
157
+ progressTitle: n,
158
+ percent: h,
159
159
  progressStatus: u,
160
- progressLoading: w,
161
- progressResult: N,
162
- errorFileName: z,
163
- errorFileSize: U,
164
- errorMessage: $,
165
- errorImport: C,
160
+ progressLoading: y,
161
+ progressResult: T,
162
+ errorFileName: D,
163
+ errorFileSize: I,
164
+ errorMessage: z,
165
+ errorImport: F,
166
166
  errorFilePath: j,
167
- fileHandleType: I,
168
- fileImport: E,
167
+ fileHandleType: $,
168
+ fileImport: B,
169
169
  fileExport: S,
170
170
  fileAction: O,
171
171
  generateUniqueName: (s) => {
@@ -173,7 +173,7 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
173
173
  return `${o.length ? o[1] : s}${te()}${a}`;
174
174
  },
175
175
  downloadFile: ue,
176
- resetStataus: h,
176
+ resetStataus: w,
177
177
  checkProgress: d
178
178
  };
179
179
  }, De = (e) => {
@@ -206,128 +206,128 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
206
206
  cer: "application/pkix-cert"
207
207
  }[c];
208
208
  }, ue = (e, c, m = "excel") => {
209
- const i = new XMLHttpRequest();
210
- i.open("get", e), i.setRequestHeader("Content-Type", "application/json; charset=UTF-8"), i.responseType = "blob", i.onload = function(x) {
209
+ const n = new XMLHttpRequest();
210
+ n.open("get", e), n.setRequestHeader("Content-Type", "application/json; charset=UTF-8"), n.responseType = "blob", n.onload = function(h) {
211
211
  const u = new Blob([this.response], {
212
212
  type: De(m)
213
- }), w = URL.createObjectURL(u);
213
+ }), y = URL.createObjectURL(u);
214
214
  if (window.navigator.msSaveOrOpenBlob)
215
215
  navigator.msSaveBlob(u, c);
216
216
  else {
217
217
  const g = document.createElement("a");
218
- g.href = w, g.download = c, g.click(), window.URL.revokeObjectURL(w);
218
+ g.href = y, g.download = c, g.click(), window.URL.revokeObjectURL(y);
219
219
  }
220
- }, i.send();
221
- }, ze = (e) => new Promise((c, m) => {
222
- var i = new FileReader();
223
- i.onload = function(x) {
220
+ }, n.send();
221
+ }, Se = (e) => new Promise((c, m) => {
222
+ var n = new FileReader();
223
+ n.onload = function(h) {
224
224
  let u = "";
225
- typeof i.result == "string" && (u = JSON.parse(i.result)), c(u);
226
- }, i.readAsText(e);
227
- }), Se = (e, c) => {
225
+ typeof n.result == "string" && (u = JSON.parse(n.result)), c(u);
226
+ }, n.readAsText(e);
227
+ }), Ue = (e, c) => {
228
228
  var o;
229
229
  const {
230
230
  importDialog: m,
231
- showProgressDialog: i,
232
- progressTitle: x,
231
+ showProgressDialog: n,
232
+ progressTitle: h,
233
233
  percent: u,
234
- progressStatus: w,
234
+ progressStatus: y,
235
235
  progressLoading: g,
236
- errorFileName: N,
237
- errorFileSize: z,
238
- errorMessage: U,
239
- errorImport: $,
240
- errorFilePath: C,
236
+ errorFileName: T,
237
+ errorFileSize: D,
238
+ errorMessage: I,
239
+ errorImport: z,
240
+ errorFilePath: F,
241
241
  fileHandleType: j,
242
- fileImport: F,
243
- fileExport: I,
244
- downloadFile: D
245
- } = Ce(c);
246
- let h = y([]), B = (o = $e()) == null ? void 0 : o.tenantId;
247
- const R = () => {
248
- h.value = [], $.value = !1, N.value = "", z.value = "", U.value = "", m.value = !0, C.value = "", c("open");
242
+ fileImport: k,
243
+ fileExport: $,
244
+ downloadFile: P
245
+ } = Pe(c);
246
+ let w = x([]), E = (o = Te()) == null ? void 0 : o.tenantId;
247
+ const V = () => {
248
+ w.value = [], z.value = !1, T.value = "", D.value = "", I.value = "", m.value = !0, F.value = "", c("open");
249
249
  };
250
- let E;
250
+ let B;
251
251
  const O = (a) => {
252
- const r = e.fileType.split(","), n = a.name.substring(a.name.lastIndexOf(".")), t = S(a.sizeText), b = S(e.fileMaxSize);
253
- if (!r.includes(n)) {
252
+ const r = e.fileType.split(","), i = a.name.substring(a.name.lastIndexOf(".")), t = S(a.sizeText), N = S(e.fileMaxSize);
253
+ if (!r.includes(i)) {
254
254
  L.warning(p("文件格式错误,请重新上传!")), setTimeout(() => {
255
- h.value = [];
255
+ w.value = [];
256
256
  });
257
257
  return;
258
258
  }
259
- if (t > b) {
259
+ if (t > N) {
260
260
  L.warning(`${p("文件大小不超过")}${e.fileMaxSize}`), setTimeout(() => {
261
- h.value = [];
261
+ w.value = [];
262
262
  });
263
263
  return;
264
264
  }
265
- E = a.name;
265
+ B = a.name;
266
266
  }, S = (a) => {
267
- let r = a.match(/\d+(\.\d+)?/)[0], n = a.match(/[a-zA-z]+/gi)[0], t = 0;
268
- return r = parseFloat(r), n = n.toLowerCase(), n === "gb" || n === "g" ? t = (r * 1024 * 1024 * 1024).toFixed(2) : n === "mb" || n === "m" ? t = (r * 1024 * 1024).toFixed(2) : n === "kb" || n === "k" ? t = (r * 1024).toFixed(2) : n === "b" && (t = r), parseFloat(t);
267
+ let r = a.match(/\d+(\.\d+)?/)[0], i = a.match(/[a-zA-z]+/gi)[0], t = 0;
268
+ return r = parseFloat(r), i = i.toLowerCase(), i === "gb" || i === "g" ? t = (r * 1024 * 1024 * 1024).toFixed(2) : i === "mb" || i === "m" ? t = (r * 1024 * 1024).toFixed(2) : i === "kb" || i === "k" ? t = (r * 1024).toFixed(2) : i === "b" && (t = r), parseFloat(t);
269
269
  }, d = async (a) => {
270
270
  const r = a.value.split("/");
271
- let n = te();
271
+ let i = te();
272
272
  const t = {
273
273
  fileName: r[r.length - 1],
274
274
  filePath: a.value,
275
- taskId: n,
275
+ taskId: i,
276
276
  ...e.importParams
277
- }, b = e.importParamsPosition === "params" ? e.importFun("", { params: t }) : e.importFun(t), [T, k] = await b.run();
278
- return T ? { status: !1 } : { status: !0, taskId: n };
277
+ }, N = e.importParamsPosition === "params" ? e.importFun("", { params: t }) : e.importFun(t), [b, C] = await N.run();
278
+ return b ? { status: !1 } : { status: !0, taskId: i };
279
279
  }, f = async () => {
280
- if (!h.value.length) return L.warning(p("请上传文件"));
280
+ if (!w.value.length) return L.warning(p("请上传文件"));
281
281
  const a = {
282
282
  bucketName: e.bucketName,
283
- importFileName: `${B}/${e.ossName}/${E}`
284
- }, r = e.maxCount > 1, n = e.maxCount > 1 ? h.value : h.value[0];
285
- await F(d, n, a, r);
283
+ importFileName: `${E}/${e.ossName}/${B}`
284
+ }, r = e.maxCount > 1, i = e.maxCount > 1 ? w.value : w.value[0];
285
+ await k(d, i, a, r);
286
286
  }, v = () => {
287
- D(C.value, N.value);
287
+ P(F.value, T.value);
288
288
  }, q = () => {
289
- I(le, e.templateName);
289
+ $(le, e.templateName);
290
290
  }, le = async () => {
291
291
  let a = te();
292
- const [r, n] = await e.templateFun({ taskId: a }).run();
292
+ const [r, i] = await e.templateFun({ taskId: a }).run();
293
293
  return r ? { status: !1 } : { status: !0, taskId: a };
294
294
  };
295
295
  return {
296
- showProgressDialog: i,
297
- progressTitle: x,
296
+ showProgressDialog: n,
297
+ progressTitle: h,
298
298
  percent: u,
299
- progressStatus: w,
299
+ progressStatus: y,
300
300
  progressLoading: g,
301
- errorFileName: N,
302
- errorFileSize: z,
303
- errorMessage: U,
304
- errorImport: $,
301
+ errorFileName: T,
302
+ errorFileSize: D,
303
+ errorMessage: I,
304
+ errorImport: z,
305
305
  importDialog: m,
306
- fileList: h,
306
+ fileList: w,
307
307
  fileHandleType: j,
308
- showImportHandle: R,
308
+ showImportHandle: V,
309
309
  confirmImport: f,
310
310
  fileUpload: O,
311
311
  errorFileDownload: v,
312
312
  downTemplate: async () => {
313
313
  let a = "";
314
314
  if (e.templateUrl)
315
- a = e.templateUrl, D(ne(a), e.templateName);
315
+ a = e.templateUrl, P(ie(a), e.templateName);
316
316
  else if (e.templateFun) {
317
317
  if (e.templateType === "static") {
318
318
  if (e.templateUrl)
319
319
  a = e.templateUrl;
320
320
  else if (e.templateFun) {
321
- const [r, n] = await e.templateFun().run();
322
- a = n;
321
+ const [r, i] = await e.templateFun().run();
322
+ a = i;
323
323
  }
324
- D(ne(a), e.templateName);
324
+ P(ie(a), e.templateName);
325
325
  }
326
326
  e.templateType === "dynamic" && e.templateFun && q();
327
327
  }
328
328
  }
329
329
  };
330
- }, Pe = { class: "das-import-button" }, Me = { class: "tip-box" }, Le = { class: "first-line" }, je = { class: "second-line" }, Ve = /* @__PURE__ */ ge({
330
+ }, Me = { class: "das-import-button" }, Le = { class: "tip-box" }, je = { class: "first-line" }, Re = { class: "second-line" }, Ee = /* @__PURE__ */ ge({
331
331
  __name: "App",
332
332
  props: {
333
333
  importFun: {},
@@ -349,42 +349,42 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
349
349
  },
350
350
  emits: ["open", "success", "error"],
351
351
  setup(e, { expose: c, emit: m }) {
352
- const i = e, x = m, {
352
+ const n = e, h = m, {
353
353
  showProgressDialog: u,
354
- progressTitle: w,
354
+ progressTitle: y,
355
355
  percent: g,
356
- progressStatus: N,
357
- progressLoading: z,
358
- errorFileName: U,
359
- errorFileSize: $,
360
- errorMessage: C,
356
+ progressStatus: T,
357
+ progressLoading: D,
358
+ errorFileName: I,
359
+ errorFileSize: z,
360
+ errorMessage: F,
361
361
  errorImport: j,
362
- importDialog: F,
363
- fileList: I,
364
- fileHandleType: D,
365
- showImportHandle: h,
366
- confirmImport: B,
367
- fileUpload: R,
368
- errorFileDownload: E,
362
+ importDialog: k,
363
+ fileList: $,
364
+ fileHandleType: P,
365
+ showImportHandle: w,
366
+ confirmImport: E,
367
+ fileUpload: V,
368
+ errorFileDownload: B,
369
369
  downTemplate: O
370
- } = Se(i, x);
370
+ } = Ue(n, h);
371
371
  let S;
372
- return ve(D, (d) => {
372
+ return ve(P, (d) => {
373
373
  d.includes("import") ? S = [p("正在导入中..."), p("导入失败"), p("导入成功")] : S = [p("正在导出中..."), p("导出失败"), p("导出成功")];
374
374
  }), c({
375
- confirmImport: B,
376
- showImportHandle: h
377
- }), (d, f) => (xe(), ye("div", Pe, [
375
+ confirmImport: E,
376
+ showImportHandle: w
377
+ }), (d, f) => (he(), xe("div", Me, [
378
378
  K("div", {
379
379
  onClick: f[0] || (f[0] = //@ts-ignore
380
- (...v) => l(h) && l(h)(...v))
380
+ (...v) => l(w) && l(w)(...v))
381
381
  }, [
382
382
  se(d.$slots, "default", {}, () => [
383
- P(l(W), {
383
+ U(l(W), {
384
384
  size: "middle",
385
385
  "btn-type": "primary"
386
386
  }, {
387
- default: V(() => [
387
+ default: R(() => [
388
388
  _(
389
389
  A(l(M)("导入").value),
390
390
  1
@@ -397,21 +397,21 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
397
397
  ], !0)
398
398
  ]),
399
399
  oe(" 导入弹窗 "),
400
- P(l(re), {
400
+ U(l(re), {
401
401
  title: l(M)(d.importDialogName).value,
402
- modelValue: l(F),
403
- "onUpdate:modelValue": f[3] || (f[3] = (v) => Q(F) ? F.value = v : null),
402
+ modelValue: l(k),
403
+ "onUpdate:modelValue": f[3] || (f[3] = (v) => Q(k) ? k.value = v : null),
404
404
  customClass: "upload-dialog",
405
405
  width: "610px",
406
406
  height: "500px"
407
407
  }, {
408
- footer: V(() => [
408
+ footer: R(() => [
409
409
  K("div", null, [
410
- P(l(W), {
410
+ U(l(W), {
411
411
  size: "middle",
412
- onClick: f[2] || (f[2] = (v) => F.value = !1)
412
+ onClick: f[2] || (f[2] = (v) => k.value = !1)
413
413
  }, {
414
- default: V(() => [
414
+ default: R(() => [
415
415
  _(
416
416
  A(l(M)("取消").value),
417
417
  1
@@ -421,14 +421,14 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
421
421
  _: 1
422
422
  /* STABLE */
423
423
  }),
424
- P(l(W), {
424
+ U(l(W), {
425
425
  size: "middle",
426
426
  "btn-type": "primary",
427
- disabled: d.openDisabled && l(I).length === 0,
427
+ disabled: d.openDisabled && l($).length === 0,
428
428
  style: { "margin-left": "12px" },
429
- onClick: l(B)
429
+ onClick: l(E)
430
430
  }, {
431
- default: V(() => [
431
+ default: R(() => [
432
432
  _(
433
433
  A(l(M)(`${d.confirmButtonName}`).value),
434
434
  1
@@ -440,22 +440,22 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
440
440
  }, 8, ["disabled", "onClick"])
441
441
  ])
442
442
  ]),
443
- default: V(() => [
443
+ default: R(() => [
444
444
  se(d.$slots, "tip", {}, () => [
445
- K("div", Me, [
446
- K("div", Le, [
445
+ K("div", Le, [
446
+ K("div", je, [
447
447
  _(
448
448
  A(l(M)("1、点击下载 ").value),
449
449
  1
450
450
  /* TEXT */
451
451
  ),
452
- P(l(W), {
452
+ U(l(W), {
453
453
  size: "large",
454
454
  btnType: "primary-text",
455
455
  block: "",
456
456
  onClick: l(O)
457
457
  }, {
458
- default: V(() => [
458
+ default: R(() => [
459
459
  _(
460
460
  A(l(M)(`${d.templateName}`).value),
461
461
  1
@@ -468,46 +468,46 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
468
468
  ]),
469
469
  K(
470
470
  "div",
471
- je,
471
+ Re,
472
472
  A(l(M)("2、仅支持上传Excel文件,重复数据以最后一条为准").value),
473
473
  1
474
474
  /* TEXT */
475
475
  )
476
476
  ])
477
477
  ], !0),
478
- P(l(we), {
479
- modelValue: l(I),
480
- "onUpdate:modelValue": f[1] || (f[1] = (v) => Q(I) ? I.value = v : null),
478
+ U(l(we), {
479
+ modelValue: l($),
480
+ "onUpdate:modelValue": f[1] || (f[1] = (v) => Q($) ? $.value = v : null),
481
481
  error: l(j),
482
- "error-file-name": l(U),
483
- "error-file-size": l($),
484
- "error-message": l(C),
482
+ "error-file-name": l(I),
483
+ "error-file-size": l(z),
484
+ "error-message": l(F),
485
485
  accept: d.fileType,
486
486
  maxCount: d.maxCount,
487
487
  multiple: d.multiple,
488
- onErrorFileDownload: l(E),
489
- onFileUpload: l(R)
488
+ onErrorFileDownload: l(B),
489
+ onFileUpload: l(V)
490
490
  }, null, 8, ["modelValue", "error", "error-file-name", "error-file-size", "error-message", "accept", "maxCount", "multiple", "onErrorFileDownload", "onFileUpload"])
491
491
  ]),
492
492
  _: 3
493
493
  /* FORWARDED */
494
494
  }, 8, ["title", "modelValue"]),
495
495
  oe(" 进度弹窗 "),
496
- P(l(re), {
496
+ U(l(re), {
497
497
  size: "mini",
498
- title: l(M)(l(w)).value,
498
+ title: l(M)(l(y)).value,
499
499
  "is-feedback-img": !1,
500
500
  modelValue: l(u),
501
501
  "onUpdate:modelValue": f[5] || (f[5] = (v) => Q(u) ? u.value = v : null),
502
502
  type: "feedback"
503
503
  }, {
504
- default: V(() => [
505
- P(l(he), {
504
+ default: R(() => [
505
+ U(l(Ne), {
506
506
  modelValue: l(g),
507
507
  "onUpdate:modelValue": f[4] || (f[4] = (v) => Q(g) ? g.value = v : null),
508
508
  style: { "margin-top": "35px" },
509
509
  type: "circle",
510
- status: l(N),
510
+ status: l(T),
511
511
  textMap: l(S)
512
512
  }, null, 8, ["modelValue", "status", "textMap"])
513
513
  ]),
@@ -516,13 +516,41 @@ const Ne = ae.get("token"), Fe = ae.post("put-object", (e) => (e.headers || (e.h
516
516
  }, 8, ["title", "modelValue"])
517
517
  ]));
518
518
  }
519
- }), Be = (e, c) => {
519
+ }), Ve = (e, c) => {
520
520
  const m = e.__vccOpts || e;
521
- for (const [i, x] of c)
522
- m[i] = x;
521
+ for (const [n, h] of c)
522
+ m[n] = h;
523
523
  return m;
524
- }, Re = /* @__PURE__ */ Be(Ve, [["__scopeId", "data-v-3fab7506"]]), et = fe(Re);
524
+ }, Be = /* @__PURE__ */ Ve(Ee, [["__scopeId", "data-v-3fab7506"]]), He = {
525
+ 点击下载: { "zh-CN": "点击下载", en: "Click to download" },
526
+ 仅支持上传: { "zh-CN": "仅支持上传", en: "Only support uploading" },
527
+ 文件: { "zh-CN": "文件", en: "file" },
528
+ 重复数据以最后一条为准: { "zh-CN": "重复数据以最后一条为准", en: "Duplicate data is subject to the last entry" },
529
+ 取消: { "zh-CN": "取消", en: "Cancel" },
530
+ 正在导入中: { "zh-CN": "正在导入中", en: "Importing" },
531
+ 导入失败: { "zh-CN": "导入失败", en: "Import failed" },
532
+ 正在导出中: { "zh-CN": "正在导出中", en: "Exporting" },
533
+ 导出失败: { "zh-CN": "导出失败", en: "Export failed" },
534
+ 导出成功: { "zh-CN": "导出成功", en: "Export successful" },
535
+ 文件格式错误: { "zh-CN": "文件格式错误", en: "File format error" },
536
+ 请重新上传: { "zh-CN": "请重新上传", en: "Please upload again" },
537
+ 文件大小不超过: { "zh-CN": "文件大小不超过", en: "File size does not exceed" },
538
+ 请上传文件: { "zh-CN": "请上传文件", en: "Please upload file" },
539
+ 导入进度: { "zh-CN": "导入进度", en: "Import progress" },
540
+ 导入成功: { "zh-CN": "导入成功", en: "Import successful" },
541
+ 导出进度: { "zh-CN": "导出进度", en: "Export progress" },
542
+ 导出: { "zh-CN": "导出", en: "Export" },
543
+ 导入: { "zh-CN": "导入", en: "Import" },
544
+ 失败: { "zh-CN": "失败", en: "Failure" },
545
+ 部分数据校验不通过: { "zh-CN": "部分数据校验不通过", en: "Some data validation failed" },
546
+ 请下载附件并修改: { "zh-CN": "请下载附件并修改", en: "Please download the attachment and modify it" },
547
+ 重新导入: { "zh-CN": "重新导入", en: "Re-import" },
548
+ 成功: { "zh-CN": "成功", en: "Success" },
549
+ 部分: { "zh-CN": "部分", en: "Partial" }
550
+ };
551
+ ye(He);
552
+ const at = fe(Be);
525
553
  export {
526
- et as DasImportButton,
527
- et as default
554
+ at as DasImportButton,
555
+ at as default
528
556
  };