yahee-components 0.0.108 → 0.0.109
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/annex-upload/annex-upload.vue.js +51 -154
- package/es/annex-upload/annex-upload.vue2.js +119 -2
- package/es/annex-upload/index.js +3 -3
- package/es/border-wrap/border-wrap.vue.js +64 -95
- package/es/border-wrap/border-wrap.vue2.js +46 -2
- package/es/common-import/common-import.vue.js +369 -693
- package/es/common-import/common-import.vue2.js +364 -2
- package/es/common-import/index.js +3 -3
- package/es/complex-search/batch-search-dialog.vue.js +116 -4
- package/es/complex-search/batch-search-dialog.vue2.js +27 -136
- package/es/complex-search/complex-search.vue.js +14 -14
- package/es/copy/copy.vue.js +37 -55
- package/es/copy/copy.vue2.js +34 -2
- package/es/copy/index.js +3 -3
- package/es/country-platform-shop-condition/country-platform-shop-condition.vue.js +114 -213
- package/es/country-platform-shop-condition/country-platform-shop-condition.vue2.js +125 -2
- package/es/drop-down-condition/drop-down-condition.vue.js +115 -215
- package/es/drop-down-condition/drop-down-condition.vue2.js +127 -2
- package/es/echart-gauge/echart-gauge.vue.js +12 -140
- package/es/echart-gauge/echart-gauge.vue2.js +147 -2
- package/es/echart-gauge/index.js +3 -3
- package/es/file-download-wrapper/file-download-wrapper.vue.js +143 -244
- package/es/file-download-wrapper/file-download-wrapper.vue2.js +113 -2
- package/es/file-download-wrapper/index.js +4 -4
- package/es/filter-container/filter-container.vue.js +18 -66
- package/es/filter-container/filter-container.vue2.js +59 -2
- package/es/filter-container/index.js +4 -4
- package/es/filter-wrapper/filter-wrapper.vue.js +16 -4
- package/es/filter-wrapper/filter-wrapper.vue2.js +40 -45
- package/es/height-collapse/height-collapse.vue.js +24 -51
- package/es/height-collapse/height-collapse.vue2.js +42 -2
- package/es/height-collapse/index.js +4 -4
- package/es/help-tag/help-tag.vue.js +44 -78
- package/es/help-tag/help-tag.vue2.js +49 -2
- package/es/help-tag/index.js +3 -3
- package/es/image-upload/image-upload.vue.js +109 -170
- package/es/image-upload/image-upload.vue2.js +91 -2
- package/es/image-upload/index.js +3 -3
- package/es/left-condition/index.js +3 -3
- package/es/left-condition/left-condition-sub.vue.js +32 -91
- package/es/left-condition/left-condition-sub.vue2.js +76 -2
- package/es/left-condition/left-condition.vue.js +70 -218
- package/es/left-condition/left-condition.vue2.js +160 -2
- package/es/left-condition-enum/index.js +3 -3
- package/es/left-condition-enum/left-condition-enum.vue.js +20 -49
- package/es/left-condition-enum/left-condition-enum.vue2.js +40 -2
- package/es/operation-log/operation-log-content.vue.js +71 -92
- package/es/operation-log/operation-log-content.vue2.js +39 -2
- package/es/operation-log/operation-log-dialog.vue.js +45 -67
- package/es/operation-log/operation-log-dialog.vue2.js +38 -2
- package/es/operation-log/operation-log-form.vue.js +108 -183
- package/es/operation-log/operation-log-form.vue2.js +104 -2
- package/es/operation-log/operation-log.vue.js +119 -228
- package/es/operation-log/operation-log.vue2.js +135 -2
- package/es/packages/components/api/log-server.js +6 -6
- package/es/packages/components/api/upload-server.js +1 -1
- package/es/packages/components/hooks/useEcharts.js +19 -19
- package/es/packages/components/hooks/useImg.js +8 -8
- package/es/scale-screen/index.js +4 -4
- package/es/scale-screen/scale-screen.vue.js +19 -126
- package/es/scale-screen/scale-screen.vue2.js +125 -2
- package/es/yahee-components.css +1 -1
- package/package.json +1 -1
|
@@ -1,4 +1,366 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { defineComponent as be, mergeDefaults as Ie, toRefs as Re, ref as n, watch as De, reactive as Ce, onMounted as Te, onUnmounted as $e } from "vue";
|
|
2
|
+
import { translateEmployeeName as Fe, M2 as M } from "../utils/translate.js";
|
|
3
|
+
import { get as Ue } from "../packages/components/api/log-server.js";
|
|
4
|
+
import { getDomainBaseReportUrl as xe, getDomainBaseUrl as Me } from "../utils/get-domain-base-url.js";
|
|
5
|
+
import { getUploadRecord as qe } from "../packages/components/api/common-import/index.js";
|
|
6
|
+
import { defaultCommonImportProps as Ne } from "./props.js";
|
|
7
|
+
import { ElMessage as u, vLoading as ke, ElUpload as Be, ElTableColumn as Oe, ElTable as Pe, ElRow as _e, ElProgress as Le, ElPagination as We, ElLink as Ge, ElDialog as Ae, ElCol as Je, ElCard as je, ElButton as ze, ElMessageBox as te } from "element-plus";
|
|
8
|
+
import "element-plus/theme-chalk/src/base.scss";
|
|
9
|
+
import "element-plus/theme-chalk/src/button.scss";
|
|
10
|
+
import "element-plus/theme-chalk/src/card.scss";
|
|
11
|
+
import "element-plus/theme-chalk/src/col.scss";
|
|
12
|
+
import "element-plus/theme-chalk/src/dialog.scss";
|
|
13
|
+
import "element-plus/theme-chalk/src/overlay.scss";
|
|
14
|
+
import "element-plus/theme-chalk/src/link.scss";
|
|
15
|
+
import "element-plus/theme-chalk/src/badge.scss";
|
|
16
|
+
import "element-plus/theme-chalk/src/message.scss";
|
|
17
|
+
import "element-plus/theme-chalk/src/message-box.scss";
|
|
18
|
+
import "element-plus/theme-chalk/src/input.scss";
|
|
19
|
+
import "element-plus/theme-chalk/src/pagination.scss";
|
|
20
|
+
import "element-plus/theme-chalk/src/tag.scss";
|
|
21
|
+
import "element-plus/theme-chalk/src/option.scss";
|
|
22
|
+
import "element-plus/theme-chalk/src/option-group.scss";
|
|
23
|
+
import "element-plus/theme-chalk/src/scrollbar.scss";
|
|
24
|
+
import "element-plus/theme-chalk/src/popper.scss";
|
|
25
|
+
import "element-plus/theme-chalk/src/select.scss";
|
|
26
|
+
import "element-plus/theme-chalk/src/progress.scss";
|
|
27
|
+
import "element-plus/theme-chalk/src/row.scss";
|
|
28
|
+
import "element-plus/theme-chalk/src/table.scss";
|
|
29
|
+
import "element-plus/theme-chalk/src/checkbox.scss";
|
|
30
|
+
import "element-plus/theme-chalk/src/tooltip.scss";
|
|
31
|
+
import "element-plus/theme-chalk/src/table-column.scss";
|
|
32
|
+
import "element-plus/theme-chalk/src/upload.scss";
|
|
33
|
+
import "../node_modules/.pnpm/axios@1.10.0/node_modules/axios/index.js";
|
|
34
|
+
import He from "../node_modules/.pnpm/axios@1.10.0/node_modules/axios/lib/axios.js";
|
|
35
|
+
const Xe = {
|
|
36
|
+
name: "YaheeCommonImport",
|
|
37
|
+
inheritAttrs: !1
|
|
38
|
+
}, Ft = /* @__PURE__ */ be({
|
|
39
|
+
...Xe,
|
|
40
|
+
props: /* @__PURE__ */ Ie({
|
|
41
|
+
isShowDialog: { type: Boolean, required: !1 },
|
|
42
|
+
isShowResponseDataMessage: { type: Boolean, required: !1 },
|
|
43
|
+
title: { type: String, required: !0 },
|
|
44
|
+
importId: { type: String, required: !0 },
|
|
45
|
+
multiple: { type: Boolean, required: !1 },
|
|
46
|
+
ProcessRequestData: { type: null, required: !1 },
|
|
47
|
+
AutoCompleteResult: { type: Boolean, required: !1 },
|
|
48
|
+
displayGetTemplate: { type: Boolean, required: !1 },
|
|
49
|
+
processImportUrl: { type: String, required: !0 },
|
|
50
|
+
requestData: { type: Object, required: !1 },
|
|
51
|
+
uploadRecord: { type: Function, required: !1 },
|
|
52
|
+
uploadFile: { type: Function, required: !1 },
|
|
53
|
+
uploadDisabled: { type: Boolean, required: !1 },
|
|
54
|
+
filePath: { type: String, required: !1 },
|
|
55
|
+
processFiles: { type: Function, required: !1 }
|
|
56
|
+
}, Ne()),
|
|
57
|
+
emits: [
|
|
58
|
+
"setIsShowDialog",
|
|
59
|
+
"closeDialog",
|
|
60
|
+
"setResponseData",
|
|
61
|
+
"submit",
|
|
62
|
+
"reloadTableData"
|
|
63
|
+
],
|
|
64
|
+
setup(oe, { expose: re, emit: ae }) {
|
|
65
|
+
re();
|
|
66
|
+
const q = oe, {
|
|
67
|
+
isShowDialog: ne,
|
|
68
|
+
isShowResponseDataMessage: N,
|
|
69
|
+
title: le,
|
|
70
|
+
importId: p,
|
|
71
|
+
processImportUrl: R,
|
|
72
|
+
requestData: D,
|
|
73
|
+
processFiles: k,
|
|
74
|
+
filePath: B
|
|
75
|
+
} = Re(q), C = n(!1), se = n(!1), v = n(!1), O = n([]), i = n({}), P = n(1), _ = n(1), T = n(50), m = n({}), w = n({}), $ = n({}), c = {}, d = n({}), y = n({}), g = n({}), S = n(""), F = n(!1), f = n({
|
|
76
|
+
siteId: null,
|
|
77
|
+
reportTime: null,
|
|
78
|
+
fileName: ""
|
|
79
|
+
}), E = ae, ie = () => {
|
|
80
|
+
E("closeDialog");
|
|
81
|
+
}, L = () => {
|
|
82
|
+
E("setResponseData", $.value);
|
|
83
|
+
}, W = () => {
|
|
84
|
+
E("submit");
|
|
85
|
+
}, ce = (e) => {
|
|
86
|
+
var t, o, r;
|
|
87
|
+
return Number(
|
|
88
|
+
((((t = i.value[e]) == null ? void 0 : t.successRowCount) + ((o = i.value[e]) == null ? void 0 : o.failedRowCount)) / ((r = i.value[e]) == null ? void 0 : r.totalRowCount) * 100).toFixed(0)
|
|
89
|
+
);
|
|
90
|
+
}, ue = (e) => {
|
|
91
|
+
const t = e == null ? void 0 : e.CreateOn;
|
|
92
|
+
if (typeof t != "string") return "---";
|
|
93
|
+
const o = t.match(/\/Date\((\d+)/);
|
|
94
|
+
if (!o) return "---";
|
|
95
|
+
const r = Number(o[1]);
|
|
96
|
+
if (Number.isNaN(r)) return "---";
|
|
97
|
+
const a = new Date(r);
|
|
98
|
+
if (Number.isNaN(a.getTime())) return "---";
|
|
99
|
+
const s = a.getFullYear(), l = String(a.getMonth() + 1).padStart(2, "0"), we = String(a.getDate()).padStart(2, "0"), ye = String(a.getHours()).padStart(2, "0"), Se = String(a.getMinutes()).padStart(2, "0"), Ee = String(a.getSeconds()).padStart(2, "0");
|
|
100
|
+
return `${s}-${l}-${we} ${ye}:${Se}:${Ee}`;
|
|
101
|
+
}, de = () => {
|
|
102
|
+
if (!d.value) return;
|
|
103
|
+
let e = "";
|
|
104
|
+
if (d.value.TemplateType == 1)
|
|
105
|
+
e = x(
|
|
106
|
+
`${d.value.Template}?dispositionType=attachment&t=${(/* @__PURE__ */ new Date()).getTime()}`
|
|
107
|
+
);
|
|
108
|
+
else if (d.value.TemplateType == 2) {
|
|
109
|
+
const t = d.value.Template;
|
|
110
|
+
if (!t) {
|
|
111
|
+
u.error("缺少报表ID");
|
|
112
|
+
return;
|
|
113
|
+
}
|
|
114
|
+
G(t);
|
|
115
|
+
}
|
|
116
|
+
window.open(e, "_self");
|
|
117
|
+
}, G = async (e) => {
|
|
118
|
+
const t = `Id=${e}`, o = {
|
|
119
|
+
method: "post",
|
|
120
|
+
url: `${j("ExportTable/OutputNew")}?${t}`,
|
|
121
|
+
headers: {
|
|
122
|
+
"Content-Type": "application/x-www-form-urlencoded; charset=UTF-8"
|
|
123
|
+
},
|
|
124
|
+
withCredentials: !0,
|
|
125
|
+
data: t
|
|
126
|
+
};
|
|
127
|
+
He(o).then((r) => {
|
|
128
|
+
r.data.Success ? window.open(`${r.data.Url}`, "_self") : console.log(r);
|
|
129
|
+
}).catch((r) => {
|
|
130
|
+
console.log(r);
|
|
131
|
+
});
|
|
132
|
+
}, me = () => {
|
|
133
|
+
C.value = !0, A(T.value);
|
|
134
|
+
}, pe = () => {
|
|
135
|
+
C.value = !1;
|
|
136
|
+
}, ge = () => {
|
|
137
|
+
h.value = /* @__PURE__ */ new Set();
|
|
138
|
+
}, fe = (e) => {
|
|
139
|
+
e && window.open(`${B.value}/${e}`, "_self");
|
|
140
|
+
}, A = async (e) => {
|
|
141
|
+
U(JSON.stringify({ rows: T.value, page: e }));
|
|
142
|
+
};
|
|
143
|
+
De(
|
|
144
|
+
() => D,
|
|
145
|
+
(e) => {
|
|
146
|
+
e && (f.value = D.value);
|
|
147
|
+
},
|
|
148
|
+
{ immediate: !0, deep: !0 }
|
|
149
|
+
);
|
|
150
|
+
const U = (e) => {
|
|
151
|
+
qe(`/ExcelImport/GetExcelImportRecords?importId=${p.value}`, e).then((t) => {
|
|
152
|
+
var o, r;
|
|
153
|
+
t.status !== 200 && (u.error(M("获取上传记录失败!")), console.log(`获取上传记录失败!${JSON.stringify(t)}`)), O.value = (o = t.data) == null ? void 0 : o.rows, _.value = (r = t.data) == null ? void 0 : r.total;
|
|
154
|
+
}).catch((t) => {
|
|
155
|
+
console.log(t);
|
|
156
|
+
});
|
|
157
|
+
}, he = (e) => {
|
|
158
|
+
U(JSON.stringify({ rows: e, page: P.value }));
|
|
159
|
+
}, J = async (e) => {
|
|
160
|
+
const t = `${b("/ExcelImport/GetExcelImportEvent")}?origin=${window.location.host}&importId=${e}`;
|
|
161
|
+
try {
|
|
162
|
+
const o = await fetch(t, {
|
|
163
|
+
method: "GET",
|
|
164
|
+
credentials: "include"
|
|
165
|
+
});
|
|
166
|
+
return o.ok || u.error(`Network response was not ok: ${o.statusText}`), await o.json();
|
|
167
|
+
} catch (o) {
|
|
168
|
+
return console.error("Failed to fetch Excel import event:", o), {};
|
|
169
|
+
}
|
|
170
|
+
}, x = (e) => {
|
|
171
|
+
let t = "";
|
|
172
|
+
const o = window.location.hostname;
|
|
173
|
+
return o.includes("localhost") || o.includes("127.0.0.1") || o.includes("yahee.com") ? t = "http://qas-service.yahee.com.cn:8088/FMSService/Latest/" : t = S.value, `${t}${e}`;
|
|
174
|
+
}, b = (e) => Me() + e, j = (e) => xe() + e, z = (e) => {
|
|
175
|
+
if (v.value = !0, e && !g.value[e])
|
|
176
|
+
try {
|
|
177
|
+
fetch(`${b("/Common/GetAllWebRoot")}?origin=${window.location.host}`, {
|
|
178
|
+
method: "GET",
|
|
179
|
+
credentials: "include"
|
|
180
|
+
}).then((t) => {
|
|
181
|
+
if (!t.ok)
|
|
182
|
+
throw new Error("Network response was not ok");
|
|
183
|
+
let o = {};
|
|
184
|
+
t.json().then((r) => {
|
|
185
|
+
if (o = r, g.value = o, !g.value) {
|
|
186
|
+
console.error("GetWebRoot 失败");
|
|
187
|
+
return;
|
|
188
|
+
}
|
|
189
|
+
S.value = g.value[e], S.value || console.error(`GetWebRoot未找到key为${e}的数据`);
|
|
190
|
+
});
|
|
191
|
+
}).finally(() => {
|
|
192
|
+
v.value = !1;
|
|
193
|
+
});
|
|
194
|
+
} catch (t) {
|
|
195
|
+
v.value = !1, console.error("GetWebRoot 失败", t);
|
|
196
|
+
}
|
|
197
|
+
}, h = n(/* @__PURE__ */ new Set()), I = Ce({}), ve = (e) => {
|
|
198
|
+
F.value = !0;
|
|
199
|
+
const { file: t } = e, o = 100 * 1024 * 1024;
|
|
200
|
+
if (t.size > o) {
|
|
201
|
+
console.error("文件大小不能超过 1GB"), u.success("文件大小不能超过 1GB");
|
|
202
|
+
return;
|
|
203
|
+
}
|
|
204
|
+
K(t.name), H(t).then((r) => {
|
|
205
|
+
X(t, r);
|
|
206
|
+
});
|
|
207
|
+
}, H = (e) => new Promise((t, o) => {
|
|
208
|
+
const r = new FileReader();
|
|
209
|
+
r.onload = () => t(r.result), r.onerror = (a) => o(a), r.readAsDataURL(e);
|
|
210
|
+
}), X = (e, t) => {
|
|
211
|
+
W(), h.value.has(e.name) ? (delete I[e.name], delete i.value[e.name], delete m.value[e.name], delete w.value[e.name], delete c[e.name], delete y.value[e.name]) : h.value.add(e.name);
|
|
212
|
+
const o = new FormData();
|
|
213
|
+
o.append("FileType", "115"), o.append("FileName", e.name), o.append("Base64Content", t), o.append("CreatedBy", "0"), o.append("Offset", "0"), o.append("IsOver", "true");
|
|
214
|
+
const r = new XMLHttpRequest();
|
|
215
|
+
r.open("POST", `${x("fragmentupload?t=")}${Math.random()}`, !0), r.upload.onprogress = (a) => {
|
|
216
|
+
a.lengthComputable && (I[e.name] = Math.round(a.loaded / a.total * 100));
|
|
217
|
+
}, r.onload = () => {
|
|
218
|
+
if (r.status === 200)
|
|
219
|
+
try {
|
|
220
|
+
const a = JSON.parse(r.responseText);
|
|
221
|
+
if (console.log("服务器返回值:", a), a.ACK !== "Success" || !a.FileId) {
|
|
222
|
+
u.error(`${e.name} 上传失败`);
|
|
223
|
+
return;
|
|
224
|
+
}
|
|
225
|
+
u.success(`${e.name} 上传成功`), I[e.name] = 100, setTimeout(() => {
|
|
226
|
+
f.value = {
|
|
227
|
+
...f.value,
|
|
228
|
+
// 保留原有字段
|
|
229
|
+
fileName: (e == null ? void 0 : e.name) || ""
|
|
230
|
+
// ES6可选链避免报错
|
|
231
|
+
}, m.value[e.name] || (m.value[e.name] = Z(20)), Y({
|
|
232
|
+
importId: p.value,
|
|
233
|
+
fileId: a.FileId,
|
|
234
|
+
wsSessionId: m.value[e.name],
|
|
235
|
+
file: e,
|
|
236
|
+
requestData: f.value
|
|
237
|
+
});
|
|
238
|
+
}, 500);
|
|
239
|
+
} catch (a) {
|
|
240
|
+
console.error("解析服务器返回值失败:", a), u.error(`${e.name} 上传完成,但解析返回值失败`);
|
|
241
|
+
}
|
|
242
|
+
else
|
|
243
|
+
u.error(`${e.name} 上传失败`);
|
|
244
|
+
}, r.onerror = () => {
|
|
245
|
+
u.error(`${e.name} 上传异常`);
|
|
246
|
+
}, r.send(o);
|
|
247
|
+
}, Y = (e) => {
|
|
248
|
+
k.value(R.value, e, {}).then((t) => {
|
|
249
|
+
var a;
|
|
250
|
+
if (F.value = !1, console.log("processFiles 返回值:", t), t != null && t.success) {
|
|
251
|
+
let s = "文件导入成功";
|
|
252
|
+
t != null && t.fileId && (s = "存在失败的条目,详情请查看输出文件"), te.alert(s, "操作成功", {
|
|
253
|
+
confirmButtonText: "确定",
|
|
254
|
+
callback: () => {
|
|
255
|
+
var l;
|
|
256
|
+
t != null && t.fileId && (w.value[(l = e == null ? void 0 : e.file) == null ? void 0 : l.name] = t.fileId, $.value = t.data, N.value && L());
|
|
257
|
+
}
|
|
258
|
+
});
|
|
259
|
+
return;
|
|
260
|
+
}
|
|
261
|
+
const r = (Array.isArray(t == null ? void 0 : t.messages) ? t.messages : ["未知错误"]).join(`
|
|
262
|
+
`) + `
|
|
263
|
+
|
|
264
|
+
(可使用鼠标滚轮滚动查看)`;
|
|
265
|
+
te.alert(r, "导入错误", {
|
|
266
|
+
confirmButtonText: "知道了",
|
|
267
|
+
customClass: "custom-common-import-alert",
|
|
268
|
+
dangerouslyUseHTMLString: !0
|
|
269
|
+
}), t != null && t.fileId && (w.value[(a = e == null ? void 0 : e.file) == null ? void 0 : a.name] = t.fileId);
|
|
270
|
+
}).catch((t) => {
|
|
271
|
+
var r;
|
|
272
|
+
console.error("processFiles 失败", t);
|
|
273
|
+
let o = t == null ? void 0 : t.exMsg;
|
|
274
|
+
o || (o = M("处理过程中发生错误!")), y.value[(r = e == null ? void 0 : e.file) == null ? void 0 : r.name] = o;
|
|
275
|
+
});
|
|
276
|
+
}, Z = (e, t) => {
|
|
277
|
+
t || (t = "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ");
|
|
278
|
+
let o = "";
|
|
279
|
+
for (let r = e; r > 0; --r)
|
|
280
|
+
o += t[Math.floor(Math.random() * t.length)];
|
|
281
|
+
return o;
|
|
282
|
+
}, Q = (e) => {
|
|
283
|
+
let t = "";
|
|
284
|
+
const { domain: o } = document;
|
|
285
|
+
return o.indexOf("localhost") >= 0 || o.indexOf("yahee.com") >= 0 ? t = "ws://qas-newerp.yahee.com.cn:8306" : t = "wss://websocket.yaheecloud.com:10001", t + e;
|
|
286
|
+
}, V = async () => await Ue(b("/Common/GetWsAuthCode")), K = (e) => {
|
|
287
|
+
c[e] = new WebSocket(Q("/excel-import/")), c[e].onmessage = (t) => {
|
|
288
|
+
var r, a;
|
|
289
|
+
if (t.data == "get-auth") {
|
|
290
|
+
V().then((s) => {
|
|
291
|
+
var l;
|
|
292
|
+
console.log("发送authCode:", s), (l = c[e]) == null || l.send(`auth:${s}`);
|
|
293
|
+
});
|
|
294
|
+
return;
|
|
295
|
+
}
|
|
296
|
+
const o = JSON.parse(t.data);
|
|
297
|
+
if (console.log("接收普通消息", o), !!o)
|
|
298
|
+
if (o.MessageType === 0) {
|
|
299
|
+
const s = o.MessageIndex || 0, l = JSON.parse(o == null ? void 0 : o.Content);
|
|
300
|
+
if ((l == null ? void 0 : l.error) == !0) {
|
|
301
|
+
y.value[e] = l.message;
|
|
302
|
+
return;
|
|
303
|
+
}
|
|
304
|
+
(!i.value[e] || s > ((r = i.value[e]) == null ? void 0 : r.MessageIndex)) && (i.value[e] = l, i.value[e].MessageIndex = s, l != null && l.finished && ((a = c[e]) == null || a.close()));
|
|
305
|
+
} else o.MessageType === 1 ? m.value[e] = o.Content : console.log("进度:", o);
|
|
306
|
+
}, c[e].onerror = (t) => {
|
|
307
|
+
console.error("WebSocket 错误:", t), t instanceof ErrorEvent ? console.error("Error message:", t.message) : console.error("Unknown WebSocket error:", t);
|
|
308
|
+
}, c[e].onclose = () => {
|
|
309
|
+
console.log("WebSocket 连接关闭");
|
|
310
|
+
};
|
|
311
|
+
};
|
|
312
|
+
Te(() => {
|
|
313
|
+
if (!R.value) {
|
|
314
|
+
console.error("processImportUrl不能为空!");
|
|
315
|
+
return;
|
|
316
|
+
}
|
|
317
|
+
if (!p.value) {
|
|
318
|
+
console.error("importId不能为空!");
|
|
319
|
+
return;
|
|
320
|
+
}
|
|
321
|
+
J(p.value).then((t) => {
|
|
322
|
+
d.value = t;
|
|
323
|
+
});
|
|
324
|
+
const e = window.location.hostname;
|
|
325
|
+
e.includes("localhost") || e.includes("127.0.0.1") || e.includes("yahee.com") || z("PictureUrlRoot");
|
|
326
|
+
}), $e(() => {
|
|
327
|
+
h.value.forEach((e) => {
|
|
328
|
+
var t;
|
|
329
|
+
(t = c[e]) == null || t.close();
|
|
330
|
+
});
|
|
331
|
+
});
|
|
332
|
+
const ee = { props: q, isShowDialog: ne, isShowResponseDataMessage: N, title: le, importId: p, processImportUrl: R, requestData: D, processFiles: k, filePath: B, isShowCoreImportRecordDialog: C, tableLoading: se, initWebRootUrlLoading: v, tableData: O, importProgress: i, pageNo: P, totalNum: _, pageSize: T, sessionIds: m, problemFiles: w, responseData: $, socket: c, eventData: d, errorMessage: y, allWebRoot: g, webRoot: S, uploadLoading: F, localRequestData: f, emit: E, handleClose: ie, emitResponseData: L, triggerSubmit: W, getProgressPercentage: ce, getFormattedDate: ue, getTemplateFile: de, fetchReport: G, displayRecords: me, handleCloseRecord: pe, handleOpen: ge, getFile: fe, handleSizeChange: A, getUploadRecordDataList: U, handleCurrentChange: he, fetchExcelImportEvent: J, getFileServiceUrl: x, getCommonUrl: b, getReportCommonUrl: j, getWebRoot: z, fileNames: h, uploadProgress: I, handleFileUpload: ve, readFileAsBase64: H, uploadConfigFile: X, processFile: Y, getRandomStr: Z, getWebSocketServerUrl: Q, getAuthCode: V, setupWebSocket: K, get M2() {
|
|
333
|
+
return M;
|
|
334
|
+
}, get translateEmployeeName() {
|
|
335
|
+
return Fe;
|
|
336
|
+
}, get ElButton() {
|
|
337
|
+
return ze;
|
|
338
|
+
}, get ElCard() {
|
|
339
|
+
return je;
|
|
340
|
+
}, get ElCol() {
|
|
341
|
+
return Je;
|
|
342
|
+
}, get ElDialog() {
|
|
343
|
+
return Ae;
|
|
344
|
+
}, get ElLink() {
|
|
345
|
+
return Ge;
|
|
346
|
+
}, get ElPagination() {
|
|
347
|
+
return We;
|
|
348
|
+
}, get ElProgress() {
|
|
349
|
+
return Le;
|
|
350
|
+
}, get ElRow() {
|
|
351
|
+
return _e;
|
|
352
|
+
}, get ElTable() {
|
|
353
|
+
return Pe;
|
|
354
|
+
}, get ElTableColumn() {
|
|
355
|
+
return Oe;
|
|
356
|
+
}, get ElUpload() {
|
|
357
|
+
return Be;
|
|
358
|
+
}, get vLoading() {
|
|
359
|
+
return ke;
|
|
360
|
+
} };
|
|
361
|
+
return Object.defineProperty(ee, "__isScriptSetup", { enumerable: !1, value: !0 }), ee;
|
|
362
|
+
}
|
|
363
|
+
});
|
|
2
364
|
export {
|
|
3
|
-
|
|
365
|
+
Ft as default
|
|
4
366
|
};
|
|
@@ -1,7 +1,119 @@
|
|
|
1
|
-
import
|
|
1
|
+
import w from "./batch-search-dialog.vue2.js";
|
|
2
|
+
import { resolveComponent as a, createBlock as m, openBlock as r, withCtx as t, createVNode as n, createElementBlock as u, Fragment as p, renderList as b, createElementVNode as v, createTextVNode as h } from "vue";
|
|
2
3
|
/* empty css */
|
|
3
|
-
import
|
|
4
|
-
const
|
|
4
|
+
import k from "../_virtual/_plugin-vue_export-helper.js";
|
|
5
|
+
const C = { class: "dialog-footer" };
|
|
6
|
+
function x(T, o, d, e, B, E) {
|
|
7
|
+
const s = a("el-option"), c = a("el-select"), i = a("el-form-item"), _ = a("el-row"), y = a("el-input"), V = a("el-form"), f = a("el-button"), g = a("el-dialog");
|
|
8
|
+
return r(), m(g, {
|
|
9
|
+
modelValue: e.visible,
|
|
10
|
+
"onUpdate:modelValue": o[3] || (o[3] = (l) => e.visible = l),
|
|
11
|
+
title: "批量查询",
|
|
12
|
+
width: "30%",
|
|
13
|
+
"before-close": e.handleClose,
|
|
14
|
+
"append-to-body": !0,
|
|
15
|
+
draggable: ""
|
|
16
|
+
}, {
|
|
17
|
+
footer: t(() => [
|
|
18
|
+
v("div", C, [
|
|
19
|
+
n(f, {
|
|
20
|
+
type: "primary",
|
|
21
|
+
loading: e.loading,
|
|
22
|
+
onClick: e.handleConfirm
|
|
23
|
+
}, {
|
|
24
|
+
default: t(() => o[4] || (o[4] = [
|
|
25
|
+
h(" 确认 ")
|
|
26
|
+
])),
|
|
27
|
+
_: 1,
|
|
28
|
+
__: [4]
|
|
29
|
+
}, 8, ["loading"]),
|
|
30
|
+
n(f, { onClick: e.handleClose }, {
|
|
31
|
+
default: t(() => o[5] || (o[5] = [
|
|
32
|
+
h("关闭")
|
|
33
|
+
])),
|
|
34
|
+
_: 1,
|
|
35
|
+
__: [5]
|
|
36
|
+
})
|
|
37
|
+
])
|
|
38
|
+
]),
|
|
39
|
+
default: t(() => [
|
|
40
|
+
n(V, {
|
|
41
|
+
ref: "formRef",
|
|
42
|
+
model: e.form,
|
|
43
|
+
rules: e.rules
|
|
44
|
+
}, {
|
|
45
|
+
default: t(() => [
|
|
46
|
+
n(_, { class: "row-class" }, {
|
|
47
|
+
default: t(() => [
|
|
48
|
+
n(i, { prop: "searchType" }, {
|
|
49
|
+
default: t(() => [
|
|
50
|
+
d.showSelect ? (r(), m(c, {
|
|
51
|
+
key: 0,
|
|
52
|
+
modelValue: e.form.searchType,
|
|
53
|
+
"onUpdate:modelValue": o[0] || (o[0] = (l) => e.form.searchType = l),
|
|
54
|
+
size: "small",
|
|
55
|
+
style: { width: "100px", "background-color": "white" }
|
|
56
|
+
}, {
|
|
57
|
+
default: t(() => [
|
|
58
|
+
(r(!0), u(p, null, b(d.isBatchSelectSameWithInput ? d.inputOptions : d.batchOptions, (l) => (r(), m(s, {
|
|
59
|
+
key: l.label,
|
|
60
|
+
label: l.label,
|
|
61
|
+
value: l.value
|
|
62
|
+
}, null, 8, ["label", "value"]))), 128))
|
|
63
|
+
]),
|
|
64
|
+
_: 1
|
|
65
|
+
}, 8, ["modelValue"])) : (r(), m(c, {
|
|
66
|
+
key: 1,
|
|
67
|
+
modelValue: e.form.searchType,
|
|
68
|
+
"onUpdate:modelValue": o[1] || (o[1] = (l) => e.form.searchType = l),
|
|
69
|
+
size: "small",
|
|
70
|
+
style: { width: "95px" },
|
|
71
|
+
disabled: ""
|
|
72
|
+
}, {
|
|
73
|
+
default: t(() => [
|
|
74
|
+
(r(!0), u(p, null, b(d.defaultOptions, (l) => (r(), m(s, {
|
|
75
|
+
key: l.label,
|
|
76
|
+
label: l.label,
|
|
77
|
+
value: l.value
|
|
78
|
+
}, null, 8, ["label", "value"]))), 128))
|
|
79
|
+
]),
|
|
80
|
+
_: 1
|
|
81
|
+
}, 8, ["modelValue"]))
|
|
82
|
+
]),
|
|
83
|
+
_: 1
|
|
84
|
+
})
|
|
85
|
+
]),
|
|
86
|
+
_: 1
|
|
87
|
+
}),
|
|
88
|
+
n(_, { class: "row-class" }, {
|
|
89
|
+
default: t(() => [
|
|
90
|
+
n(i, {
|
|
91
|
+
prop: "searchContent",
|
|
92
|
+
style: { width: "100%" }
|
|
93
|
+
}, {
|
|
94
|
+
default: t(() => [
|
|
95
|
+
n(y, {
|
|
96
|
+
modelValue: e.form.searchContent,
|
|
97
|
+
"onUpdate:modelValue": o[2] || (o[2] = (l) => e.form.searchContent = l),
|
|
98
|
+
placeholder: "请输入批量查询内容,从EXCEL复制可自动替换为`,",
|
|
99
|
+
type: "textarea",
|
|
100
|
+
rows: 5,
|
|
101
|
+
onPaste: e.handlePaste
|
|
102
|
+
}, null, 8, ["modelValue"])
|
|
103
|
+
]),
|
|
104
|
+
_: 1
|
|
105
|
+
})
|
|
106
|
+
]),
|
|
107
|
+
_: 1
|
|
108
|
+
})
|
|
109
|
+
]),
|
|
110
|
+
_: 1
|
|
111
|
+
}, 8, ["model"])
|
|
112
|
+
]),
|
|
113
|
+
_: 1
|
|
114
|
+
}, 8, ["modelValue"]);
|
|
115
|
+
}
|
|
116
|
+
const z = /* @__PURE__ */ k(w, [["render", x], ["__scopeId", "data-v-5ba0516b"], ["__file", "E:/工作/项目代码/common_componentsweb/packages/components/src/complex-search/batch-search-dialog.vue"]]);
|
|
5
117
|
export {
|
|
6
|
-
|
|
118
|
+
z as default
|
|
7
119
|
};
|