xyvcard-goods 0.0.8 → 0.0.9
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/dist/{approveFailIndex-BecI6njE.mjs → approveFailIndex-DJf9bHab.mjs} +1 -1
- package/dist/{approveFailIndex.vue_vue_type_script_setup_true_lang-1FXHUoMJ.mjs → approveFailIndex.vue_vue_type_script_setup_true_lang-mXqZdtba.mjs} +31 -31
- package/dist/{auditIndex-ByyMgebr.mjs → auditIndex-CCkGsSy2.mjs} +1 -1
- package/dist/{auditIndex.vue_vue_type_script_setup_true_lang-DT2irP9g.mjs → auditIndex.vue_vue_type_script_setup_true_lang-DHolmNaP.mjs} +19 -19
- package/dist/edit-D37yka6Z.mjs +470 -0
- package/dist/{index-AZ4TxL-_.mjs → index-CKeHa-Cx.mjs} +55 -55
- package/dist/{index-BypI3ZNk.mjs → index-vcmJ06-Y.mjs} +81 -81
- package/dist/index.mjs +8 -37
- package/dist/{info-BJ1Ld_6D.mjs → info-CPZykxS1.mjs} +27 -27
- package/dist/{saleIndex-CBtuv6um.mjs → saleIndex-CdAcvCzO.mjs} +1 -1
- package/dist/{saleIndex.vue_vue_type_script_setup_true_lang-Cxv3foxp.mjs → saleIndex.vue_vue_type_script_setup_true_lang-CLzVH-ix.mjs} +36 -36
- package/dist/{shelfIndex-CykEAeD4.mjs → shelfIndex-ZHuhzU_h.mjs} +1 -1
- package/dist/{shelfIndex.vue_vue_type_script_setup_true_lang-UPt1ZDpP.mjs → shelfIndex.vue_vue_type_script_setup_true_lang-CTv-j8Xe.mjs} +8 -8
- package/dist/{skuForm-DdiMztDh.mjs → skuForm-BSlT4TYd.mjs} +48 -48
- package/dist/skuTable-DYmQYXk3.mjs +535 -0
- package/dist/style.css +1 -1
- package/dts/components/EnumRadio/index.vue.d.ts +3 -4
- package/dts/components/GoodsUpload/ImageUpload.vue.d.ts +18 -10
- package/dts/constant.d.ts +4 -4
- package/dts/router/index.d.ts +2 -2
- package/dts/views/goods/goods-spu/skuForm.vue.d.ts +1 -1
- package/package.json +65 -65
- package/dist/edit-BWUxDk9Y.mjs +0 -594
- package/dist/skuTable-Cg06m_5i.mjs +0 -606
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as te, ref as
|
|
2
|
-
import { C as
|
|
3
|
-
import { s as de, _ as re } from "./skuTable-
|
|
1
|
+
import { defineComponent as te, ref as b, computed as se, watch as D, resolveComponent as i, openBlock as m, createElementBlock as _, Fragment as k, unref as O, createVNode as o, withCtx as a, createCommentVNode as I, renderList as y, createElementVNode as S, toDisplayString as Y, createTextVNode as w, createBlock as P } from "vue";
|
|
2
|
+
import { C as E, D as ue, S as H, a as ne } from "./index-CKeHa-Cx.mjs";
|
|
3
|
+
import { s as de, _ as re } from "./skuTable-DYmQYXk3.mjs";
|
|
4
4
|
const pe = { key: 0 }, ce = {
|
|
5
5
|
key: 1,
|
|
6
6
|
class: "w-full"
|
|
@@ -23,9 +23,9 @@ const pe = { key: 0 }, ce = {
|
|
|
23
23
|
}
|
|
24
24
|
},
|
|
25
25
|
emits: ["getGoodsSku", "getFormData"],
|
|
26
|
-
setup(
|
|
26
|
+
setup(L, { emit: J }) {
|
|
27
27
|
var T, q, R;
|
|
28
|
-
const r =
|
|
28
|
+
const r = b({
|
|
29
29
|
picUrl: "",
|
|
30
30
|
salePrice: 0,
|
|
31
31
|
marketPrice: 0,
|
|
@@ -34,17 +34,17 @@ const pe = { key: 0 }, ce = {
|
|
|
34
34
|
volume: 0,
|
|
35
35
|
stock: 0,
|
|
36
36
|
skuCode: ""
|
|
37
|
-
}), t =
|
|
37
|
+
}), t = b([]), C = b(), V = b([]), h = b([]), $ = b([]), v = L, U = J, F = se(() => t.value.filter(
|
|
38
38
|
(e) => e.name && e.specValueList != null && e.specValueList.length
|
|
39
39
|
));
|
|
40
|
-
|
|
40
|
+
D(
|
|
41
41
|
v.form,
|
|
42
42
|
(e) => e,
|
|
43
43
|
{
|
|
44
44
|
deep: !0,
|
|
45
45
|
immediate: !0
|
|
46
46
|
}
|
|
47
|
-
),
|
|
47
|
+
), D(
|
|
48
48
|
r,
|
|
49
49
|
(e) => {
|
|
50
50
|
U("getGoodsSku", e);
|
|
@@ -53,14 +53,14 @@ const pe = { key: 0 }, ce = {
|
|
|
53
53
|
deep: !0,
|
|
54
54
|
immediate: !0
|
|
55
55
|
}
|
|
56
|
-
),
|
|
56
|
+
), D(
|
|
57
57
|
F,
|
|
58
58
|
(e) => e,
|
|
59
59
|
{
|
|
60
60
|
deep: !0,
|
|
61
61
|
immediate: !0
|
|
62
62
|
}
|
|
63
|
-
), v.form.spuId && (v.form.specType ===
|
|
63
|
+
), v.form.spuId && (v.form.specType === E.SPEC_TYPE.UNIFIED_SPEC ? r.value = (T = v.form.skuList) == null ? void 0 : T.results[0] : ($.value = (q = v.form.skuList) == null ? void 0 : q.results, (R = v.form.skuList) == null || R.results.forEach((e) => {
|
|
64
64
|
var l;
|
|
65
65
|
(l = e.specValues) == null || l.map((s) => {
|
|
66
66
|
ue.specInfoDict.useValues().then((n) => {
|
|
@@ -76,13 +76,13 @@ const pe = { key: 0 }, ce = {
|
|
|
76
76
|
const p = /* @__PURE__ */ new Map();
|
|
77
77
|
t.value = t.value.filter(
|
|
78
78
|
(f) => !p.has(f.id) && p.set(f.id, f)
|
|
79
|
-
),
|
|
79
|
+
), K(s.specValueId);
|
|
80
80
|
});
|
|
81
81
|
});
|
|
82
82
|
})));
|
|
83
|
-
function
|
|
83
|
+
function K(e) {
|
|
84
84
|
t.value.forEach((l) => {
|
|
85
|
-
|
|
85
|
+
V.value = new H({ specId: l.id }), V.value.useValues().then((s) => {
|
|
86
86
|
s.forEach((n) => {
|
|
87
87
|
if (n.key === e) {
|
|
88
88
|
let p = {
|
|
@@ -99,14 +99,14 @@ const pe = { key: 0 }, ce = {
|
|
|
99
99
|
});
|
|
100
100
|
});
|
|
101
101
|
}
|
|
102
|
-
function
|
|
102
|
+
function Q(e) {
|
|
103
103
|
t.value.splice(e, 1);
|
|
104
104
|
}
|
|
105
|
-
function
|
|
105
|
+
function W(e, l) {
|
|
106
106
|
t.value[e].specValueList.splice(l, 1);
|
|
107
107
|
}
|
|
108
|
-
function
|
|
109
|
-
|
|
108
|
+
function X() {
|
|
109
|
+
h.value = new ne({ shopId: v.form.shopId }), h.value.useValues().then((e) => {
|
|
110
110
|
e.forEach((l) => {
|
|
111
111
|
Array.isArray(t.value) && t.value.length > 0 && t.value.forEach((s) => {
|
|
112
112
|
l.key === s.id && (l.disabled = !0);
|
|
@@ -115,17 +115,17 @@ const pe = { key: 0 }, ce = {
|
|
|
115
115
|
});
|
|
116
116
|
}
|
|
117
117
|
function Z(e) {
|
|
118
|
-
let l =
|
|
118
|
+
let l = h.value.values.filter((n) => n.key === e), s = {
|
|
119
119
|
id: l[0].key,
|
|
120
120
|
name: l[0].value,
|
|
121
121
|
specValueList: []
|
|
122
122
|
};
|
|
123
|
-
t.value.push(s),
|
|
123
|
+
t.value.push(s), C.value = "";
|
|
124
124
|
}
|
|
125
125
|
function z(e) {
|
|
126
|
-
|
|
126
|
+
V.value = new H({
|
|
127
127
|
specId: t.value[e].id
|
|
128
|
-
}),
|
|
128
|
+
}), V.value.useValues().then((l) => {
|
|
129
129
|
l.map((s) => {
|
|
130
130
|
Array.isArray(t.value[e].specValueList) && t.value[e].specValueList.length > 0 && t.value[e].specValueList.forEach((n) => {
|
|
131
131
|
s.key === n.id && (s.disabled = !0);
|
|
@@ -135,7 +135,7 @@ const pe = { key: 0 }, ce = {
|
|
|
135
135
|
}
|
|
136
136
|
function x(e, l) {
|
|
137
137
|
var d, p;
|
|
138
|
-
let s =
|
|
138
|
+
let s = V.value.values.filter((f) => f.key === e), n = {
|
|
139
139
|
id: s[0].key,
|
|
140
140
|
name: s[0].value
|
|
141
141
|
};
|
|
@@ -146,8 +146,8 @@ const pe = { key: 0 }, ce = {
|
|
|
146
146
|
}
|
|
147
147
|
return (e, l) => {
|
|
148
148
|
const s = i("el-input-number"), n = i("el-form-item"), d = i("el-col"), p = i("el-row"), f = i("Delete"), le = i("el-icon"), oe = i("el-tag"), B = i("el-button"), N = i("el-option"), j = i("el-select"), A = i("el-popover"), G = i("el-tab-pane"), M = i("el-tabs");
|
|
149
|
-
return m(),
|
|
150
|
-
v.specType == O(
|
|
149
|
+
return m(), _(k, null, [
|
|
150
|
+
v.specType == O(E).SPEC_TYPE.UNIFIED_SPEC ? (m(), _("div", pe, [
|
|
151
151
|
o(p, null, {
|
|
152
152
|
default: a(() => [
|
|
153
153
|
o(d, { span: 8 }, {
|
|
@@ -280,21 +280,21 @@ const pe = { key: 0 }, ce = {
|
|
|
280
280
|
]),
|
|
281
281
|
_: 1
|
|
282
282
|
})
|
|
283
|
-
])) :
|
|
284
|
-
v.specType == O(
|
|
283
|
+
])) : I("", !0),
|
|
284
|
+
v.specType == O(E).SPEC_TYPE.MULTI_SPEC ? (m(), _("div", ce, [
|
|
285
285
|
o(M, { type: "border-card" }, {
|
|
286
286
|
default: a(() => [
|
|
287
287
|
o(G, { label: "商品规格" }, {
|
|
288
288
|
default: a(() => [
|
|
289
|
-
(m(!0),
|
|
289
|
+
(m(!0), _(k, null, y(t.value, (u, g) => (m(), _("div", {
|
|
290
290
|
class: "goods-spec",
|
|
291
291
|
key: g
|
|
292
292
|
}, [
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
293
|
+
S("div", ie, [
|
|
294
|
+
S("span", null, Y(u.name), 1),
|
|
295
|
+
S("span", {
|
|
296
296
|
class: "goods-delete",
|
|
297
|
-
onClick: (c) =>
|
|
297
|
+
onClick: (c) => Q(g)
|
|
298
298
|
}, [
|
|
299
299
|
o(le, null, {
|
|
300
300
|
default: a(() => [
|
|
@@ -305,17 +305,17 @@ const pe = { key: 0 }, ce = {
|
|
|
305
305
|
l[7] || (l[7] = w("移除 "))
|
|
306
306
|
], 8, me)
|
|
307
307
|
]),
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
(m(!0),
|
|
308
|
+
S("div", fe, [
|
|
309
|
+
S("div", ve, [
|
|
310
|
+
(m(!0), _(k, null, y(t.value[g].specValueList, (c, ae) => (m(), P(oe, {
|
|
311
311
|
key: c,
|
|
312
312
|
closable: "",
|
|
313
313
|
type: "info",
|
|
314
314
|
class: "right-dis",
|
|
315
|
-
onClose: (
|
|
315
|
+
onClose: (_e) => W(g, ae)
|
|
316
316
|
}, {
|
|
317
317
|
default: a(() => [
|
|
318
|
-
w(
|
|
318
|
+
w(Y(c.name), 1)
|
|
319
319
|
]),
|
|
320
320
|
_: 2
|
|
321
321
|
}, 1032, ["onClose"]))), 128))
|
|
@@ -342,7 +342,7 @@ const pe = { key: 0 }, ce = {
|
|
|
342
342
|
onChange: (c) => x(c, g)
|
|
343
343
|
}, {
|
|
344
344
|
default: a(() => [
|
|
345
|
-
(m(!0),
|
|
345
|
+
(m(!0), _(k, null, y(V.value.values, (c) => (m(), P(N, {
|
|
346
346
|
key: c.key,
|
|
347
347
|
label: c.value,
|
|
348
348
|
value: c.key,
|
|
@@ -360,12 +360,12 @@ const pe = { key: 0 }, ce = {
|
|
|
360
360
|
placement: "bottom",
|
|
361
361
|
width: 200,
|
|
362
362
|
trigger: "click",
|
|
363
|
-
onShow:
|
|
363
|
+
onShow: X
|
|
364
364
|
}, {
|
|
365
365
|
reference: a(() => [
|
|
366
366
|
o(B, {
|
|
367
367
|
class: "m-2",
|
|
368
|
-
disabled:
|
|
368
|
+
disabled: L.isDisabled
|
|
369
369
|
}, {
|
|
370
370
|
default: a(() => l[9] || (l[9] = [
|
|
371
371
|
w("添加规格")
|
|
@@ -375,13 +375,13 @@ const pe = { key: 0 }, ce = {
|
|
|
375
375
|
]),
|
|
376
376
|
default: a(() => [
|
|
377
377
|
o(j, {
|
|
378
|
-
modelValue:
|
|
379
|
-
"onUpdate:modelValue": l[6] || (l[6] = (u) =>
|
|
378
|
+
modelValue: C.value,
|
|
379
|
+
"onUpdate:modelValue": l[6] || (l[6] = (u) => C.value = u),
|
|
380
380
|
placeholder: e.$t("goodsSpu.specRequired"),
|
|
381
381
|
onChange: Z
|
|
382
382
|
}, {
|
|
383
383
|
default: a(() => [
|
|
384
|
-
(m(!0),
|
|
384
|
+
(m(!0), _(k, null, y(h.value.values, (u) => (m(), P(N, {
|
|
385
385
|
key: u.key,
|
|
386
386
|
label: u.value,
|
|
387
387
|
value: u.key,
|
|
@@ -403,23 +403,23 @@ const pe = { key: 0 }, ce = {
|
|
|
403
403
|
default: a(() => [
|
|
404
404
|
o(G, { label: "规格售价与库存" }, {
|
|
405
405
|
default: a(() => [
|
|
406
|
-
t.value.length > 0 ? (m(),
|
|
406
|
+
t.value.length > 0 ? (m(), P(de, {
|
|
407
407
|
key: 0,
|
|
408
408
|
specData: F.value,
|
|
409
|
-
goodsSku:
|
|
409
|
+
goodsSku: $.value,
|
|
410
410
|
onGetFormData: ee
|
|
411
|
-
}, null, 8, ["specData", "goodsSku"])) :
|
|
411
|
+
}, null, 8, ["specData", "goodsSku"])) : I("", !0)
|
|
412
412
|
]),
|
|
413
413
|
_: 1
|
|
414
414
|
})
|
|
415
415
|
]),
|
|
416
416
|
_: 1
|
|
417
417
|
})
|
|
418
|
-
])) :
|
|
418
|
+
])) : I("", !0)
|
|
419
419
|
], 64);
|
|
420
420
|
};
|
|
421
421
|
}
|
|
422
|
-
}),
|
|
422
|
+
}), Se = /* @__PURE__ */ re(ge, [["__scopeId", "data-v-1db08e7e"]]);
|
|
423
423
|
export {
|
|
424
|
-
|
|
424
|
+
Se as default
|
|
425
425
|
};
|