xyvcard-order 0.0.22 → 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.
@@ -0,0 +1,408 @@
1
+ import { defineComponent as le, getCurrentInstance as re, ref as R, reactive as oe, onMounted as ne, watch as ae, onActivated as ue, resolveComponent as d, resolveDirective as de, createElementBlock as h, openBlock as f, createElementVNode as i, createVNode as r, createBlock as V, createCommentVNode as C, withCtx as o, withKeys as S, unref as a, createTextVNode as T, toDisplayString as u, withDirectives as se, isRef as I } from "vue";
2
+ import { useRoute as ie } from "vue-router";
3
+ import { ElMessageBox as me, ElMessage as M } from "element-plus";
4
+ import { useTableHooks as fe } from "jmash-core";
5
+ import { useI18n as pe } from "vue-i18n";
6
+ import { o as U } from "./index-DAb5kkOk.mjs";
7
+ import { _ as ce } from "./review.vue_vue_type_script_setup_true_lang-C5Fb8wnP.mjs";
8
+ import { _ as ve } from "./info.vue_vue_type_script_setup_true_lang-Dj376rSp.mjs";
9
+ import { D as _, C as q } from "./index-CIvF2jlB.mjs";
10
+ const ye = { class: "app-container" }, be = { class: "search-container" }, Re = ["onClick"], Ce = ["onClick"], ge = ["onClick"], Ne = /* @__PURE__ */ le({
11
+ __name: "index",
12
+ setup(we) {
13
+ const { t: m } = pe(), P = ie(), { proxy: A } = re();
14
+ _.shopBizDict.useValues();
15
+ const k = R([]), n = R({
16
+ curPage: 1,
17
+ pageSize: 10
18
+ }), {
19
+ tableHooks: s,
20
+ multipleTableRef: j,
21
+ queryFormRef: Q,
22
+ listLoading: z,
23
+ tableData: B,
24
+ total: g
25
+ } = fe(m, U, n);
26
+ let c = R([
27
+ // {
28
+ // label: "orderInfo.shopName",
29
+ // prop: "shopId",
30
+ // minWidth: "200",
31
+ // slotName: "shopId",
32
+ // columnType: "slot",
33
+ // isColumn: true,
34
+ // },
35
+ {
36
+ label: "orderRefunds.createTime",
37
+ prop: "createTime",
38
+ width: "160",
39
+ slotName: "createTime",
40
+ columnType: "slot",
41
+ isColumn: !0
42
+ },
43
+ {
44
+ label: "orderRefunds.order",
45
+ prop: "order",
46
+ minWidth: "270",
47
+ slotName: "order",
48
+ columnType: "slot",
49
+ isColumn: !0
50
+ },
51
+ {
52
+ label: "orderRefunds.refundStatus",
53
+ prop: "status",
54
+ width: "90",
55
+ slotName: "refundStatus",
56
+ columnType: "slot",
57
+ isColumn: !0
58
+ },
59
+ {
60
+ label: "orderRefunds.refundAmount",
61
+ prop: "refundAmount",
62
+ width: "90",
63
+ isColumn: !0
64
+ },
65
+ {
66
+ label: "orderRefunds.refundCode",
67
+ prop: "refundCode",
68
+ width: "210",
69
+ isColumn: !0
70
+ },
71
+ {
72
+ label: "orderRefunds.refundReson",
73
+ prop: "refundReson",
74
+ width: "200",
75
+ isColumn: !0
76
+ },
77
+ {
78
+ label: "orderRefunds.refuseRefundReson",
79
+ prop: "refuseRefundReson",
80
+ width: "200",
81
+ isColumn: !0
82
+ },
83
+ {
84
+ label: "common.operate",
85
+ width: "130",
86
+ slotName: "operation",
87
+ columnType: "slot",
88
+ fixed: "right",
89
+ isColumn: !0
90
+ }
91
+ ]);
92
+ const v = R({
93
+ title: m("orderRefunds.refundOperation"),
94
+ visible: !1
95
+ }), y = R({
96
+ title: m("orderRefunds.info"),
97
+ visible: !1
98
+ });
99
+ let w = oe({});
100
+ function L(t) {
101
+ w.refundId = t.refundId, v.value.visible = !0;
102
+ }
103
+ const K = async (t) => {
104
+ me.confirm(
105
+ m("orderRefunds.refundConfirm"),
106
+ m("orderRefunds.refund"),
107
+ {
108
+ confirmButtonText: m("common.confirm"),
109
+ cancelButtonText: m("common.cancel"),
110
+ type: "warning"
111
+ }
112
+ ).then(() => {
113
+ U.refund({
114
+ refundId: t.refundId,
115
+ requestId: Math.random() * 10 + ""
116
+ }).then((l) => {
117
+ l.status === 200 && (M({
118
+ message: m("orderRefunds.refundSuccess"),
119
+ type: "success"
120
+ }), s.handleQuery());
121
+ }).catch((l) => {
122
+ console.error("Error canceling order:", l), M({
123
+ message: m("orderRefunds.refundFailed"),
124
+ type: "error"
125
+ });
126
+ });
127
+ }).catch(() => {
128
+ });
129
+ };
130
+ function H(t) {
131
+ w.refundId = t.refundId, y.value.visible = !0;
132
+ }
133
+ function O(t) {
134
+ n.value.startCreateTime = t[0], n.value.endCreateTime = t[1];
135
+ }
136
+ function W() {
137
+ k.value = [], n.value.startCreateTime = "", n.value.endCreateTime = "", s.resetQuery();
138
+ }
139
+ function D(t) {
140
+ t && s.getList();
141
+ }
142
+ return ne(() => {
143
+ const t = P.query.refundStatus;
144
+ t && (n.value = {
145
+ ...n.value,
146
+ refundStatus: t
147
+ }, s.handleQuery());
148
+ }), ae(
149
+ () => P.query.refundStatus,
150
+ (t) => {
151
+ t && (n.value = {
152
+ ...n.value,
153
+ refundStatus: t
154
+ }), s.handleQuery();
155
+ }
156
+ ), ue(() => {
157
+ s.getList();
158
+ }), (t, l) => {
159
+ const N = d("el-input"), b = d("el-form-item"), p = d("el-col"), F = d("jmash-select"), $ = d("el-row"), G = d("el-date-picker"), Y = d("el-button"), J = d("el-form"), X = d("jmash-column-select"), Z = d("jmash-table"), x = d("jmash-pagination"), ee = d("el-card"), te = de("hasPerm");
160
+ return f(), h("div", ye, [
161
+ i("div", be, [
162
+ r(J, {
163
+ ref_key: "queryFormRef",
164
+ ref: Q,
165
+ model: n.value,
166
+ inline: !0
167
+ }, {
168
+ default: o(() => [
169
+ r($, null, {
170
+ default: o(() => [
171
+ r(p, { span: 6 }, {
172
+ default: o(() => [
173
+ r(b, {
174
+ label: t.$t("orderRefunds.refundCode"),
175
+ prop: "likeOrderCode"
176
+ }, {
177
+ default: o(() => [
178
+ r(N, {
179
+ modelValue: n.value.likeOrderCode,
180
+ "onUpdate:modelValue": l[0] || (l[0] = (e) => n.value.likeOrderCode = e),
181
+ placeholder: t.$t("orderRefunds.refundCodeRequired"),
182
+ clearable: "",
183
+ onKeyup: l[1] || (l[1] = S((e) => a(s).handleQuery(), ["enter"])),
184
+ class: "!w-[203px]"
185
+ }, null, 8, ["modelValue", "placeholder"])
186
+ ]),
187
+ _: 1
188
+ }, 8, ["label"])
189
+ ]),
190
+ _: 1
191
+ }),
192
+ r(p, { span: 6 }, {
193
+ default: o(() => [
194
+ r(b, {
195
+ label: t.$t("orderRefunds.spuName"),
196
+ prop: "likeSpuName"
197
+ }, {
198
+ default: o(() => [
199
+ r(N, {
200
+ modelValue: n.value.likeSpuName,
201
+ "onUpdate:modelValue": l[2] || (l[2] = (e) => n.value.likeSpuName = e),
202
+ placeholder: t.$t("orderRefunds.spuNameRequired"),
203
+ clearable: "",
204
+ onKeyup: l[3] || (l[3] = S((e) => a(s).handleQuery(), ["enter"])),
205
+ class: "!w-[203px]"
206
+ }, null, 8, ["modelValue", "placeholder"])
207
+ ]),
208
+ _: 1
209
+ }, 8, ["label"])
210
+ ]),
211
+ _: 1
212
+ }),
213
+ r(p, { span: 6 }, {
214
+ default: o(() => [
215
+ r(b, {
216
+ label: t.$t("orderRefunds.refundStatus"),
217
+ prop: "refundStatus"
218
+ }, {
219
+ default: o(() => [
220
+ r(F, {
221
+ modelValue: n.value.refundStatus,
222
+ "onUpdate:modelValue": l[4] || (l[4] = (e) => n.value.refundStatus = e),
223
+ data: a(_).refundApplyEnum.values,
224
+ placeholder: t.$t("orderRefunds.refundStatusRequired"),
225
+ clearable: "",
226
+ onKeyup: l[5] || (l[5] = S((e) => a(s).handleQuery(), ["enter"]))
227
+ }, null, 8, ["modelValue", "data", "placeholder"])
228
+ ]),
229
+ _: 1
230
+ }, 8, ["label"])
231
+ ]),
232
+ _: 1
233
+ })
234
+ ]),
235
+ _: 1
236
+ }),
237
+ r($, null, {
238
+ default: o(() => [
239
+ r(p, { span: 6 }, {
240
+ default: o(() => [
241
+ r(b, {
242
+ label: t.$t("orderRefunds.refundsTime"),
243
+ prop: "startCreateTime"
244
+ }, {
245
+ default: o(() => [
246
+ r(G, {
247
+ modelValue: k.value,
248
+ "onUpdate:modelValue": l[6] || (l[6] = (e) => k.value = e),
249
+ type: "daterange",
250
+ "start-placeholder": t.$t("orderRefunds.startCreateTime"),
251
+ "end-placeholder": t.$t("orderRefunds.endCreateTime"),
252
+ format: "YYYY-MM-DD",
253
+ "value-format": "YYYY-MM-DD",
254
+ onChange: O
255
+ }, null, 8, ["modelValue", "start-placeholder", "end-placeholder"])
256
+ ]),
257
+ _: 1
258
+ }, 8, ["label"])
259
+ ]),
260
+ _: 1
261
+ }),
262
+ r(p, { span: 18 }, {
263
+ default: o(() => [
264
+ r(b, { class: "search-btn" }, {
265
+ default: o(() => [
266
+ r(Y, {
267
+ type: "primary",
268
+ onClick: l[7] || (l[7] = (e) => a(s).handleQuery())
269
+ }, {
270
+ default: o(() => [
271
+ T(u(t.$t("common.search")), 1)
272
+ ]),
273
+ _: 1
274
+ }),
275
+ r(Y, { onClick: W }, {
276
+ default: o(() => [
277
+ T(u(t.$t("common.reset")), 1)
278
+ ]),
279
+ _: 1
280
+ })
281
+ ]),
282
+ _: 1
283
+ })
284
+ ]),
285
+ _: 1
286
+ })
287
+ ]),
288
+ _: 1
289
+ })
290
+ ]),
291
+ _: 1
292
+ }, 8, ["model"]),
293
+ l[15] || (l[15] = i("div", { class: "clear" }, null, -1))
294
+ ]),
295
+ r(ee, {
296
+ shadow: "never",
297
+ class: "table-container"
298
+ }, {
299
+ header: o(() => [
300
+ r($, null, {
301
+ default: o(() => [
302
+ r(p, {
303
+ span: 24,
304
+ class: "container-float"
305
+ }, {
306
+ default: o(() => [
307
+ r(X, {
308
+ modelValue: a(c),
309
+ "onUpdate:modelValue": l[8] || (l[8] = (e) => I(c) ? c.value = e : c = e),
310
+ "label-name": "order/order-refunds"
311
+ }, null, 8, ["modelValue"])
312
+ ]),
313
+ _: 1
314
+ })
315
+ ]),
316
+ _: 1
317
+ })
318
+ ]),
319
+ footer: o(() => [
320
+ a(g) > 0 ? (f(), V(x, {
321
+ key: 0,
322
+ total: a(g),
323
+ "onUpdate:total": l[9] || (l[9] = (e) => I(g) ? g.value = e : null),
324
+ "current-page": n.value.curPage,
325
+ "onUpdate:currentPage": l[10] || (l[10] = (e) => n.value.curPage = e),
326
+ "page-size": n.value.pageSize,
327
+ "onUpdate:pageSize": l[11] || (l[11] = (e) => n.value.pageSize = e),
328
+ onPagination: l[12] || (l[12] = (e) => a(s).getList())
329
+ }, null, 8, ["total", "current-page", "page-size"])) : C("", !0)
330
+ ]),
331
+ default: o(() => [
332
+ r(Z, {
333
+ ref_key: "multipleTableRef",
334
+ ref: j,
335
+ "row-key": "refundId",
336
+ "list-loading": a(z),
337
+ data: a(B),
338
+ "table-label": a(c),
339
+ isSelection: !1
340
+ }, {
341
+ createTime: o((e) => [
342
+ i("span", null, u(a(A).$moment.formatDate(
343
+ e.data.row.createTime,
344
+ "YYYY-MM-DD HH:mm:ss"
345
+ )), 1)
346
+ ]),
347
+ order: o((e) => [
348
+ i("div", null, [
349
+ i("div", null, u(t.$t("orderRefunds.orderCode")) + ":" + u(e.data.row.orderCode), 1),
350
+ i("div", null, u(t.$t("orderRefunds.orderPrice")) + ":¥" + u(e.data.row.orderPrice), 1),
351
+ i("div", null, u(t.$t("orderRefunds.freightPrice")) + ":¥" + u(e.data.row.freightPrice), 1),
352
+ i("div", null, u(t.$t("orderRefunds.paymentCouponPrice")) + ":¥" + u(e.data.row.paymentCouponPrice), 1),
353
+ i("div", null, u(t.$t("orderRefunds.paymentWay")) + ": " + u(a(_).paymentWayEnum.getEnumValue(e.data.row.paymentWay)), 1)
354
+ ])
355
+ ]),
356
+ refundStatus: o((e) => [
357
+ i("span", null, u(a(_).refundApplyEnum.getEnumValue(e.data.row.status)), 1)
358
+ ]),
359
+ operation: o((e) => [
360
+ se((f(), h("span", {
361
+ class: "el-button-color",
362
+ onClick: (E) => H(e.data.row)
363
+ }, [
364
+ T(u(t.$t("common.view")), 1)
365
+ ], 8, Re)), [
366
+ [te, ["order:order_refunds:view"]]
367
+ ]),
368
+ e.data.row.status === a(q).APPLY ? (f(), h("span", {
369
+ key: 0,
370
+ class: "el-button-color dropdown-left",
371
+ onClick: (E) => L(e.data.row)
372
+ }, u(t.$t("orderRefunds.refundReview")), 9, Ce)) : C("", !0),
373
+ e.data.row.status === a(q).PASS ? (f(), h("span", {
374
+ key: 1,
375
+ class: "el-button-color dropdown-left",
376
+ onClick: (E) => K(e.data.row)
377
+ }, u(t.$t("orderRefunds.refund")), 9, ge)) : C("", !0)
378
+ ]),
379
+ _: 1
380
+ }, 8, ["list-loading", "data", "table-label"])
381
+ ]),
382
+ _: 1
383
+ }),
384
+ v.value.visible ? (f(), V(ce, {
385
+ key: 0,
386
+ modelValue: v.value.visible,
387
+ "onUpdate:modelValue": l[13] || (l[13] = (e) => v.value.visible = e),
388
+ title: v.value.title,
389
+ "entity-key": a(w),
390
+ onRefresh: D,
391
+ width: "800px"
392
+ }, null, 8, ["modelValue", "title", "entity-key"])) : C("", !0),
393
+ y.value.visible ? (f(), V(ve, {
394
+ key: 1,
395
+ modelValue: y.value.visible,
396
+ "onUpdate:modelValue": l[14] || (l[14] = (e) => y.value.visible = e),
397
+ title: y.value.title,
398
+ "entity-key": a(w),
399
+ onRefresh: D,
400
+ width: "900px"
401
+ }, null, 8, ["modelValue", "title", "entity-key"])) : C("", !0)
402
+ ]);
403
+ };
404
+ }
405
+ });
406
+ export {
407
+ Ne as default
408
+ };
@@ -2,7 +2,7 @@ import { defineComponent as N, ref as k, onMounted as E, resolveComponent as p,
2
2
  import { useRoute as U } from "vue-router";
3
3
  import "element-plus";
4
4
  import { C as a, D as B } from "./index-CIvF2jlB.mjs";
5
- import { _ as f } from "./orderList.vue_vue_type_script_setup_true_lang-CZwgX-8z.mjs";
5
+ import { _ as f } from "./orderList.vue_vue_type_script_setup_true_lang-DHrP4RpK.mjs";
6
6
  const L = { class: "app-container" }, D = /* @__PURE__ */ N({
7
7
  __name: "index",
8
8
  setup(M) {
package/dist/index.mjs CHANGED
@@ -2743,7 +2743,7 @@ function Ni(e) {
2743
2743
  let r = e.global.getLocaleMessage("en");
2744
2744
  r = Dt(r, xi), e.global.setLocaleMessage("zh-cn", t), e.global.setLocaleMessage("en", r);
2745
2745
  }
2746
- const Wi = /* @__PURE__ */ Object.assign({ "./views/order/order-appraises/index.vue": () => import("./index-ax4ZoEdg.mjs"), "./views/order/order-appraises/reply.vue": () => import("./reply-BWKE7lzJ.mjs"), "./views/order/order-info/deliver.vue": () => import("./deliver-xdoW8QbQ.mjs"), "./views/order/order-info/edit.vue": () => import("./edit-syt7QO1o.mjs"), "./views/order/order-info/index.vue": () => import("./index-CBDuTdON.mjs"), "./views/order/order-info/info.vue": () => import("./info-DV1TgYo0.mjs"), "./views/order/order-info/orderList.vue": () => import("./orderList-B210nJTG.mjs"), "./views/order/order-info/viewLogist.vue": () => import("./viewLogist-CHiDaaZx.mjs"), "./views/order/order-refunds/index.vue": () => import("./index-B9DBGDon.mjs"), "./views/order/order-refunds/info.vue": () => import("./info-Lp4w5kOC.mjs"), "./views/order/order-refunds/review.vue": () => import("./review-DH5466Un.mjs") }), Ci = {
2746
+ const Wi = /* @__PURE__ */ Object.assign({ "./views/order/order-appraises/index.vue": () => import("./index-BMrv-n10.mjs"), "./views/order/order-appraises/reply.vue": () => import("./reply-BWKE7lzJ.mjs"), "./views/order/order-info/deliver.vue": () => import("./deliver-xdoW8QbQ.mjs"), "./views/order/order-info/edit.vue": () => import("./edit-syt7QO1o.mjs"), "./views/order/order-info/index.vue": () => import("./index-C2K-uAKW.mjs"), "./views/order/order-info/info.vue": () => import("./info-DV1TgYo0.mjs"), "./views/order/order-info/orderList.vue": () => import("./orderList-C0Zyo4nE.mjs"), "./views/order/order-info/viewLogist.vue": () => import("./viewLogist-CHiDaaZx.mjs"), "./views/order/order-refunds/index.vue": () => import("./index-BhfIsPKv.mjs"), "./views/order/order-refunds/info.vue": () => import("./info-Lp4w5kOC.mjs"), "./views/order/order-refunds/review.vue": () => import("./review-DH5466Un.mjs") }), Ci = {
2747
2747
  install(e) {
2748
2748
  vr(Wi, 7), Ni(Yr), e.use(Ti), Dr(Ri);
2749
2749
  }
@@ -1,4 +1,4 @@
1
- import { _ as f } from "./orderList.vue_vue_type_script_setup_true_lang-CZwgX-8z.mjs";
1
+ import { _ as f } from "./orderList.vue_vue_type_script_setup_true_lang-DHrP4RpK.mjs";
2
2
  export {
3
3
  f as default
4
4
  };