xyvcard-order 0.0.21 → 0.0.23

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.
@@ -1,4 +1,4 @@
1
- import { _ as f } from "./deliver.vue_vue_type_script_setup_true_lang-bpU2ikKn.mjs";
1
+ import { _ as f } from "./deliver.vue_vue_type_script_setup_true_lang-KNWXpWfJ.mjs";
2
2
  export {
3
3
  f as default
4
4
  };
@@ -2,7 +2,7 @@ import { defineComponent as P, mergeModels as v, ref as b, reactive as T, useMod
2
2
  import { ElMessage as B } from "element-plus";
3
3
  import { useI18n as F } from "vue-i18n";
4
4
  import { C as u, D as G } from "./index-CIvF2jlB.mjs";
5
- import { o as K } from "./index-DRFiw9Ec.mjs";
5
+ import { o as K } from "./index-BZHtbIZR.mjs";
6
6
  const A = { class: "dialog-footer" }, W = /* @__PURE__ */ P({
7
7
  __name: "deliver",
8
8
  props: /* @__PURE__ */ v({
@@ -1,4 +1,4 @@
1
- import { _ as f } from "./edit.vue_vue_type_script_setup_true_lang-D2vJHeGo.mjs";
1
+ import { _ as f } from "./edit.vue_vue_type_script_setup_true_lang-CDDwv_I0.mjs";
2
2
  export {
3
3
  f as default
4
4
  };
@@ -2,7 +2,7 @@ import { defineComponent as K, mergeModels as V, reactive as h, ref as I, useMod
2
2
  import { ElMessage as A } from "element-plus";
3
3
  import { useI18n as D } from "vue-i18n";
4
4
  import { validatePhoneNumber as S } from "jmash-core";
5
- import { o as w } from "./index-DRFiw9Ec.mjs";
5
+ import { o as w } from "./index-BZHtbIZR.mjs";
6
6
  const z = { class: "dialog-footer" }, Q = /* @__PURE__ */ K({
7
7
  __name: "edit",
8
8
  props: /* @__PURE__ */ V({
@@ -0,0 +1,349 @@
1
+ import { defineComponent as Z, getCurrentInstance as x, ref as m, reactive as ee, resolveComponent as i, resolveDirective as ae, createElementBlock as S, openBlock as c, createElementVNode as n, createVNode as l, createBlock as R, createCommentVNode as k, withCtx as r, createTextVNode as v, toDisplayString as o, unref as g, withDirectives as te, Fragment as le, renderList as oe, isRef as re } from "vue";
2
+ import { useI18n as se } from "vue-i18n";
3
+ import { fileApi as C } from "jmash-core";
4
+ import { _ as ie, g as ne } from "./reply.vue_vue_type_script_setup_true_lang-AnsyNIM8.mjs";
5
+ import { D as de } from "./index-CIvF2jlB.mjs";
6
+ const pe = { class: "app-container" }, ue = { class: "search-container" }, me = { class: "wordsStyle" }, ce = { class: "wordsStyle" }, fe = { key: 0 }, ve = { class: "wordsStyle" }, ge = ["onClick"], Ve = /* @__PURE__ */ Z({
7
+ __name: "index",
8
+ setup(_e) {
9
+ const { t: E } = se(), { proxy: H } = x();
10
+ de.shopBizDict.useValues();
11
+ const A = m([]), d = m({
12
+ curPage: 1,
13
+ pageSize: 10
14
+ }), U = m(!1), _ = m([]), f = m(0);
15
+ let y = m([
16
+ // {
17
+ // label: "goodsAppraises.shopName",
18
+ // prop: "shopId",
19
+ // width: "200",
20
+ // slotName: "shopId",
21
+ // columnType: "slot",
22
+ // isColumn: true,
23
+ // },
24
+ {
25
+ label: "goodsAppraises.orderItemList",
26
+ prop: "orderItemList",
27
+ minWidth: "320",
28
+ slotName: "orderItemList",
29
+ columnType: "slot",
30
+ isColumn: !0
31
+ },
32
+ {
33
+ label: "goodsAppraises.nickName",
34
+ prop: "nickName",
35
+ width: "90",
36
+ isColumn: !0
37
+ },
38
+ {
39
+ label: "goodsAppraises.appraises",
40
+ prop: "appraises",
41
+ width: "220",
42
+ slotName: "appraises",
43
+ columnType: "slot",
44
+ isColumn: !0
45
+ },
46
+ {
47
+ label: "goodsAppraises.sellerReply",
48
+ prop: "sellerReply",
49
+ width: "160",
50
+ slotName: "sellerReply",
51
+ columnType: "slot",
52
+ isColumn: !0
53
+ }
54
+ ]);
55
+ const w = m({
56
+ title: E("goodsAppraises.sellerReply"),
57
+ visible: !1
58
+ });
59
+ let D = ee({});
60
+ function M(a) {
61
+ D.appraisesId = a.appraisesId, w.value.visible = !0;
62
+ }
63
+ function q(a) {
64
+ d.value.appraiseStartTime = a[0], d.value.appraiseEndTime = a[1];
65
+ }
66
+ function P(a) {
67
+ return a.split(",").map((t) => C.imageUrl(t, 30, 0));
68
+ }
69
+ async function I() {
70
+ U.value = !0;
71
+ try {
72
+ const { data: a } = await ne.findPage(d.value);
73
+ a && a.results ? (_.value = a.results, _.value.map((t) => {
74
+ var b, h;
75
+ if ((h = (b = t.orderInfo) == null ? void 0 : b.orderItemList) != null && h.results) {
76
+ const p = t.orderInfo.orderItemList.results.filter(
77
+ (V) => t.spuId === V.spuId
78
+ );
79
+ if (p.length > 0)
80
+ return {
81
+ ...t,
82
+ orderInfo: {
83
+ ...t.orderInfo,
84
+ orderItemList: {
85
+ ...t.orderInfo.orderItemList,
86
+ results: p
87
+ }
88
+ }
89
+ };
90
+ }
91
+ return t;
92
+ }), f.value = a.totalSize || 0) : (_.value = [], f.value = 0);
93
+ } catch (a) {
94
+ console.error("Error fetch data", a), _.value = [], f.value = 0;
95
+ } finally {
96
+ U.value = !1;
97
+ }
98
+ }
99
+ function B() {
100
+ d.value = {
101
+ curPage: 1,
102
+ pageSize: 10,
103
+ appraiseStartTime: "",
104
+ appraiseEndTime: ""
105
+ }, A.value = [], I();
106
+ }
107
+ function F() {
108
+ d.value.curPage = 1, I();
109
+ }
110
+ function K(a) {
111
+ a && I();
112
+ }
113
+ return I(), (a, t) => {
114
+ const b = i("el-date-picker"), h = i("el-form-item"), p = i("el-col"), V = i("el-button"), L = i("el-row"), Q = i("el-form"), W = i("jmash-column-select"), T = i("el-image"), $ = i("el-rate"), G = i("jmash-table"), J = i("jmash-pagination"), O = i("el-card"), X = ae("hasPerm");
115
+ return c(), S("div", pe, [
116
+ n("div", ue, [
117
+ l(Q, {
118
+ ref: "queryFormRef",
119
+ model: d.value,
120
+ inline: !0
121
+ }, {
122
+ default: r(() => [
123
+ l(L, null, {
124
+ default: r(() => [
125
+ l(p, { span: 6 }, {
126
+ default: r(() => [
127
+ l(h, {
128
+ label: a.$t("goodsAppraises.appraiseRange"),
129
+ prop: "appraiseRange"
130
+ }, {
131
+ default: r(() => [
132
+ l(b, {
133
+ modelValue: A.value,
134
+ "onUpdate:modelValue": t[0] || (t[0] = (e) => A.value = e),
135
+ type: "datetimerange",
136
+ "start-placeholder": a.$t("goodsAppraises.appraiseStartTime"),
137
+ "end-placeholder": a.$t("goodsAppraises.appraiseStartTime"),
138
+ format: "YYYY-MM-DD HH:mm:ss",
139
+ "value-format": "YYYY-MM-DD HH:mm:ss",
140
+ onChange: q
141
+ }, null, 8, ["modelValue", "start-placeholder", "end-placeholder"])
142
+ ]),
143
+ _: 1
144
+ }, 8, ["label"])
145
+ ]),
146
+ _: 1
147
+ }),
148
+ l(p, { span: 12 }, {
149
+ default: r(() => [
150
+ l(h, { class: "search-btn" }, {
151
+ default: r(() => [
152
+ l(V, {
153
+ type: "primary",
154
+ onClick: t[1] || (t[1] = (e) => F())
155
+ }, {
156
+ default: r(() => [
157
+ v(o(a.$t("common.search")), 1)
158
+ ]),
159
+ _: 1
160
+ }),
161
+ l(V, { onClick: B }, {
162
+ default: r(() => [
163
+ v(o(a.$t("common.reset")), 1)
164
+ ]),
165
+ _: 1
166
+ })
167
+ ]),
168
+ _: 1
169
+ })
170
+ ]),
171
+ _: 1
172
+ })
173
+ ]),
174
+ _: 1
175
+ })
176
+ ]),
177
+ _: 1
178
+ }, 8, ["model"])
179
+ ]),
180
+ l(O, {
181
+ shadow: "never",
182
+ class: "table-container"
183
+ }, {
184
+ header: r(() => [
185
+ l(L, null, {
186
+ default: r(() => [
187
+ l(p, { span: 17 }),
188
+ l(p, {
189
+ span: 7,
190
+ class: "container-float"
191
+ }, {
192
+ default: r(() => [
193
+ l(W, {
194
+ modelValue: g(y),
195
+ "onUpdate:modelValue": t[2] || (t[2] = (e) => re(y) ? y.value = e : y = e),
196
+ "label-name": "order/good-appraises"
197
+ }, null, 8, ["modelValue"])
198
+ ]),
199
+ _: 1
200
+ })
201
+ ]),
202
+ _: 1
203
+ })
204
+ ]),
205
+ footer: r(() => [
206
+ f.value > 0 ? (c(), R(J, {
207
+ key: 0,
208
+ total: f.value,
209
+ "onUpdate:total": t[3] || (t[3] = (e) => f.value = e),
210
+ "current-page": d.value.curPage,
211
+ "onUpdate:currentPage": t[4] || (t[4] = (e) => d.value.curPage = e),
212
+ "page-size": d.value.pageSize,
213
+ "onUpdate:pageSize": t[5] || (t[5] = (e) => d.value.pageSize = e),
214
+ onPagination: t[6] || (t[6] = (e) => I())
215
+ }, null, 8, ["total", "current-page", "page-size"])) : k("", !0)
216
+ ]),
217
+ default: r(() => [
218
+ l(G, {
219
+ ref: "multipleTableRef",
220
+ "row-key": "appraisesId",
221
+ "list-loading": U.value,
222
+ data: _.value,
223
+ "table-label": g(y),
224
+ isSelection: !1
225
+ }, {
226
+ orderItemList: r((e) => [
227
+ l(L, { gutter: 10 }, {
228
+ default: r(() => [
229
+ l(p, { span: 4 }, {
230
+ default: r(() => {
231
+ var s, u;
232
+ return [
233
+ l(T, {
234
+ src: g(C).imageUrl(
235
+ (s = e.data.row.orderInfo) == null ? void 0 : s.orderItemList.results[0].picUrl,
236
+ 80,
237
+ 0
238
+ ),
239
+ "preview-src-list": [
240
+ g(C).imageUrl(
241
+ (u = e.data.row.orderInfo) == null ? void 0 : u.orderItemList.results[0].picUrl
242
+ )
243
+ ],
244
+ "preview-teleported": "",
245
+ "hide-on-click-modal": "",
246
+ fit: "contain"
247
+ }, null, 8, ["src", "preview-src-list"])
248
+ ];
249
+ }),
250
+ _: 2
251
+ }, 1024),
252
+ l(p, { span: 20 }, {
253
+ default: r(() => {
254
+ var s, u, Y, N, z, j;
255
+ return [
256
+ n("div", null, o(a.$t("goodsAppraises.orderCode")) + ":" + o((s = e.data.row.orderInfo) == null ? void 0 : s.orderCode), 1),
257
+ n("div", me, o(a.$t("goodsAppraises.spuName")) + ":" + o((u = e.data.row.orderInfo) == null ? void 0 : u.orderItemList.results[0].spuName), 1),
258
+ n("div", null, o(a.$t("goodsAppraises.specInfo")) + ":" + o((Y = e.data.row.orderInfo) == null ? void 0 : Y.orderItemList.results[0].specInfo), 1),
259
+ n("div", null, o(a.$t("goodsAppraises.purchasePrice")) + ":" + o(((N = e.data.row.orderInfo) == null ? void 0 : N.orderItemList.results[0].quantity) * ((z = e.data.row.orderInfo) == null ? void 0 : z.orderItemList.results[0].salesPrice)), 1),
260
+ n("div", null, o(a.$t("goodsAppraises.quantity")) + ":" + o((j = e.data.row.orderInfo) == null ? void 0 : j.orderItemList.results[0].quantity), 1)
261
+ ];
262
+ }),
263
+ _: 2
264
+ }, 1024)
265
+ ]),
266
+ _: 2
267
+ }, 1024)
268
+ ]),
269
+ appraises: r((e) => [
270
+ n("div", null, [
271
+ v(o(a.$t("goodsAppraises.goodsScore")) + ": ", 1),
272
+ l($, {
273
+ modelValue: e.data.row.goodsScore,
274
+ "onUpdate:modelValue": (s) => e.data.row.goodsScore = s,
275
+ max: 5,
276
+ disabled: ""
277
+ }, null, 8, ["modelValue", "onUpdate:modelValue"])
278
+ ]),
279
+ n("div", null, [
280
+ v(o(a.$t("goodsAppraises.serviceScore")) + ": ", 1),
281
+ l($, {
282
+ modelValue: e.data.row.serviceScore,
283
+ "onUpdate:modelValue": (s) => e.data.row.serviceScore = s,
284
+ max: 5,
285
+ disabled: ""
286
+ }, null, 8, ["modelValue", "onUpdate:modelValue"])
287
+ ]),
288
+ n("div", null, [
289
+ v(o(a.$t("goodsAppraises.logisticsScore")) + ": ", 1),
290
+ l($, {
291
+ modelValue: e.data.row.logisticsScore,
292
+ "onUpdate:modelValue": (s) => e.data.row.logisticsScore = s,
293
+ max: 5,
294
+ disabled: ""
295
+ }, null, 8, ["modelValue", "onUpdate:modelValue"])
296
+ ]),
297
+ n("div", ce, o(a.$t("goodsAppraises.content")) + ":" + o(e.data.row.content), 1),
298
+ e.data.row.picUrls !== "" ? (c(), S("div", fe, [
299
+ (c(!0), S(le, null, oe(P(e.data.row.picUrls), (s, u) => (c(), R(T, {
300
+ key: u,
301
+ src: s,
302
+ "preview-src-list": P(e.data.row.picUrls),
303
+ "preview-teleported": "",
304
+ "hide-on-click-modal": "",
305
+ fit: "contain",
306
+ style: { "margin-right": "5px" }
307
+ }, null, 8, ["src", "preview-src-list"]))), 128))
308
+ ])) : k("", !0)
309
+ ]),
310
+ sellerReply: r((e) => {
311
+ var s;
312
+ return [
313
+ n("div", ve, o(e.data.row.sellerReply), 1),
314
+ n("div", null, o(g(H).$moment.formatDate(
315
+ e.data.row.replyTime,
316
+ "YYYY-MM-DD HH:mm:ss"
317
+ )), 1),
318
+ (s = e.data.row.orderInfo) != null && s.appraisesStatus && !e.data.row.sellerReply ? te((c(), S("span", {
319
+ key: 0,
320
+ class: "el-button-color",
321
+ onClick: (u) => M(e.data.row)
322
+ }, [
323
+ v(o(a.$t("goodsAppraises.sellerReply")), 1)
324
+ ], 8, ge)), [
325
+ [X, ["order:order_appraises:update"]]
326
+ ]) : k("", !0)
327
+ ];
328
+ }),
329
+ _: 1
330
+ }, 8, ["list-loading", "data", "table-label"])
331
+ ]),
332
+ _: 1
333
+ }),
334
+ w.value.visible ? (c(), R(ie, {
335
+ key: 0,
336
+ modelValue: w.value.visible,
337
+ "onUpdate:modelValue": t[7] || (t[7] = (e) => w.value.visible = e),
338
+ title: w.value.title,
339
+ "entity-key": g(D),
340
+ onRefresh: K,
341
+ width: "600px"
342
+ }, null, 8, ["modelValue", "title", "entity-key"])) : k("", !0)
343
+ ]);
344
+ };
345
+ }
346
+ });
347
+ export {
348
+ Ve as default
349
+ };