xyvcard-paper-buyer 0.0.43 → 0.0.45
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/{applyEdit-DzxmV4oI.mjs → applyEdit-Ch-oVoTx.mjs} +2 -2
- package/dist/{index-C18T6VjZ.mjs → index-CBj9jO6o.mjs} +165 -190
- package/dist/index-Knr6dYOL.mjs +66 -0
- package/dist/index.mjs +2 -2
- package/dist/{info-CSgoyt6A.mjs → info-BshHBFtv.mjs} +1 -1
- package/dist/{invoiceEdit-D3qEYbNL.mjs → invoiceEdit-CpBEUGPH.mjs} +2 -2
- package/dist/{orderAddress-BXFhutnA.mjs → orderAddress-DMeZ9ynO.mjs} +82 -78
- package/dist/{orderInfo-BP5ei-W0.mjs → orderInfo-DY2LKHto.mjs} +1 -1
- package/dist/{orderPaper-DAXED5UU.mjs → orderPaper-DUCuNxKR.mjs} +50 -49
- package/dist/style.css +1 -1
- package/dist/{userInvoice-CZ7yW4I6.mjs → userInvoice-DPxbKmv9.mjs} +1 -1
- package/dist/{userInvoice.vue_vue_type_script_setup_true_lang-D-3fXoBu.mjs → userInvoice.vue_vue_type_script_setup_true_lang-3eHl8CCv.mjs} +1 -1
- package/dts/api/buyer/dict.d.ts +0 -13
- package/dts/api/buyer/index.d.ts +1 -4
- package/dts/api/buyer/order-newspaper/types.d.ts +2 -0
- package/dts/constant.d.ts +0 -1
- package/dts/main.d.ts +0 -1
- package/package.json +2 -4
- package/dist/index-BPKQNnjE.mjs +0 -153
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
var o = Object.defineProperty;
|
|
2
|
+
var l = (i, r, a) => r in i ? o(i, r, { enumerable: !0, configurable: !0, writable: !0, value: a }) : i[r] = a;
|
|
3
|
+
var t = (i, r, a) => l(i, typeof r != "symbol" ? r + "" : r, a);
|
|
4
|
+
import { ref as y } from "vue";
|
|
5
|
+
import { BizLayDict as T, CustomBizDict as E, EnumDict as _ } from "jmash-core";
|
|
6
|
+
import { goodsCategoryApi as I } from "xyvcard-paper-goods";
|
|
7
|
+
import { EntryDict as P } from "jmash-dict";
|
|
8
|
+
class e {
|
|
9
|
+
}
|
|
10
|
+
//模块
|
|
11
|
+
t(e, "PAPER_DICT", "paper"), // 订单状态
|
|
12
|
+
t(e, "ENUM_ORDER_STATUS", y([
|
|
13
|
+
{ key: "unpay", value: "待付款" },
|
|
14
|
+
{ key: "unpost", value: "订阅成功" }
|
|
15
|
+
])), // 订单状态常量
|
|
16
|
+
t(e, "UNPAY", "unpay"), t(e, "UNPOST", "unpost"), // 发票票种
|
|
17
|
+
t(e, "LQFP_FPPZ", "Fppz"), // 开票状态
|
|
18
|
+
t(e, "INVOICE_STATUS", "xyvcard.order.protobuf.InvoiceStatus"), t(e, "UNINVOICE", "uninvoice"), t(e, "INVOICING", "invoicing"), t(e, "INVOICED", "invoiced"), // 企业
|
|
19
|
+
t(e, "GMF_TYPE_ENT", "ent"), // 个人
|
|
20
|
+
t(e, "GMF_TYPE_PER", "person"), // 证件类型
|
|
21
|
+
t(e, "DICT_TYPE_ID", "TypeID"), // 抬头类型
|
|
22
|
+
t(e, "GMF_TYPE_VALUES", y([
|
|
23
|
+
{ key: "ent", value: "企业" },
|
|
24
|
+
{ key: "person", value: "个人" }
|
|
25
|
+
]));
|
|
26
|
+
function n(i, r, a) {
|
|
27
|
+
return !Array.isArray(i) || i.length === 0 ? [] : i.map((s) => {
|
|
28
|
+
let p = [];
|
|
29
|
+
return Array.isArray(s.children) && s.children.length > 0 && (p = n(s.children, r, a)), {
|
|
30
|
+
value: s[a],
|
|
31
|
+
label: s[r],
|
|
32
|
+
parentId: s.parentId,
|
|
33
|
+
children: p
|
|
34
|
+
};
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
class d extends T {
|
|
38
|
+
// 实现 useValues 方法
|
|
39
|
+
useValues() {
|
|
40
|
+
return new Promise((r, a) => {
|
|
41
|
+
I.findTreeListApi(this.query).then((u) => {
|
|
42
|
+
const { data: s } = u;
|
|
43
|
+
this.values.length = 0, this.values.push(...n(s.results, "label", "value")), r(this.values);
|
|
44
|
+
}).catch(a);
|
|
45
|
+
});
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
class c {
|
|
49
|
+
}
|
|
50
|
+
// 订单状态
|
|
51
|
+
t(c, "orderStatusEnum", new E(
|
|
52
|
+
e.ENUM_ORDER_STATUS,
|
|
53
|
+
{}
|
|
54
|
+
)), // 发票票种
|
|
55
|
+
t(c, "fppzDict", new P(e.LQFP_FPPZ)), // 开票状态
|
|
56
|
+
t(c, "invoiceStatusEnum", new _(
|
|
57
|
+
e.PAPER_DICT,
|
|
58
|
+
e.INVOICE_STATUS
|
|
59
|
+
)), // 商品分类(发行频率)
|
|
60
|
+
t(c, "goodsCategoryListBizLayDict", new d(
|
|
61
|
+
{}
|
|
62
|
+
)), t(c, "gmfTypeDict", new E(e.GMF_TYPE_VALUES, {}));
|
|
63
|
+
export {
|
|
64
|
+
e as C,
|
|
65
|
+
c as D
|
|
66
|
+
};
|
package/dist/index.mjs
CHANGED
|
@@ -377,7 +377,7 @@ function g(e) {
|
|
|
377
377
|
let i = e.global.getLocaleMessage("en");
|
|
378
378
|
i = d(i, b), e.global.setLocaleMessage("zh-cn", o), e.global.setLocaleMessage("en", i);
|
|
379
379
|
}
|
|
380
|
-
const R = () => import("./index-BWV5njqv.mjs"), w = () => import("./orderPaper-
|
|
380
|
+
const R = () => import("./index-BWV5njqv.mjs"), w = () => import("./orderPaper-DUCuNxKR.mjs"), P = () => import("./orderAddress-DMeZ9ynO.mjs"), q = () => import("./orderInfo-DY2LKHto.mjs"), D = () => import("./payment-DD_Lhvf0.mjs"), N = () => import("./invoice-Ca967WuM.mjs"), z = () => import("./invoiceView-BQ20QFpo.mjs"), x = () => import("./applyEdit-Ch-oVoTx.mjs"), C = () => import("./invoiceEdit-CpBEUGPH.mjs"), k = () => import("./info-BshHBFtv.mjs"), t = [
|
|
381
381
|
{
|
|
382
382
|
path: "/buyer",
|
|
383
383
|
component: r,
|
|
@@ -543,7 +543,7 @@ const R = () => import("./index-BWV5njqv.mjs"), w = () => import("./orderPaper-D
|
|
|
543
543
|
scrollBehavior: () => ({ left: 0, top: 0 })
|
|
544
544
|
});
|
|
545
545
|
c.value = T;
|
|
546
|
-
const A = /* @__PURE__ */ Object.assign({ "./views/buyer/order-info/applyEdit.vue": () => import("./applyEdit-
|
|
546
|
+
const A = /* @__PURE__ */ Object.assign({ "./views/buyer/order-info/applyEdit.vue": () => import("./applyEdit-Ch-oVoTx.mjs"), "./views/buyer/order-info/index.vue": () => import("./index-CBj9jO6o.mjs"), "./views/buyer/order-info/info.vue": () => import("./info-BshHBFtv.mjs"), "./views/buyer/order-info/invoice.vue": () => import("./invoice-Ca967WuM.mjs"), "./views/buyer/order-info/invoiceEdit.vue": () => import("./invoiceEdit-CpBEUGPH.mjs"), "./views/buyer/order-info/invoiceView.vue": () => import("./invoiceView-BQ20QFpo.mjs"), "./views/buyer/order-info/list.vue": () => import("./list-CeY2OdrK.mjs"), "./views/buyer/order-info/sendDialog.vue": () => import("./sendDialog-B0HE_2cs.mjs"), "./views/buyer/order-info/userInvoice.vue": () => import("./userInvoice-DPxbKmv9.mjs"), "./views/buyer/order-newspaper/confirm.vue": () => import("./confirm-BYEYokBP.mjs"), "./views/buyer/order-newspaper/edit.vue": () => import("./edit-Omp_CxC3.mjs"), "./views/buyer/order-newspaper/index.vue": () => import("./index-BWV5njqv.mjs"), "./views/buyer/order-newspaper/onlineBanking.vue": () => import("./onlineBanking-CdDAY0YQ.mjs"), "./views/buyer/order-newspaper/orderAddress.vue": () => import("./orderAddress-DMeZ9ynO.mjs"), "./views/buyer/order-newspaper/orderInfo.vue": () => import("./orderInfo-DY2LKHto.mjs"), "./views/buyer/order-newspaper/orderPaper.vue": () => import("./orderPaper-DUCuNxKR.mjs"), "./views/buyer/order-newspaper/payment.vue": () => import("./payment-DD_Lhvf0.mjs"), "./views/buyer/order-newspaper/prompt.vue": () => import("./prompt-DQX4apPU.mjs"), "./views/buyer/order-user-address/edit.vue": () => import("./edit-DwsTiwF8.mjs"), "./views/buyer/order-user-address/index.vue": () => import("./index-MoEV6c7S.mjs") }), M = {
|
|
547
547
|
install(e) {
|
|
548
548
|
l(A, 7), f(t), g(h);
|
|
549
549
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { defineComponent as Y, ref as v, onMounted as Z, resolveComponent as a, createElementBlock as x, openBlock as q, createVNode as t, withCtx as n, createElementVNode as e, unref as _, toDisplayString as i, createTextVNode as m, createBlock as ee, createCommentVNode as oe } from "vue";
|
|
2
|
-
import { D as h } from "./index-
|
|
2
|
+
import { D as h } from "./index-Knr6dYOL.mjs";
|
|
3
3
|
import { o as R } from "./index-BKZPqxLM.mjs";
|
|
4
4
|
import { fileApi as M, routerUtil as te } from "jmash-core";
|
|
5
5
|
import { useRouter as se, useRoute as le } from "vue-router";
|
|
@@ -3,9 +3,9 @@ import { useI18n as W } from "vue-i18n";
|
|
|
3
3
|
import "element-plus";
|
|
4
4
|
import { routerUtil as F } from "jmash-core";
|
|
5
5
|
import { useRouter as X, useRoute as Y } from "vue-router";
|
|
6
|
-
import { D as U } from "./index-
|
|
6
|
+
import { D as U } from "./index-Knr6dYOL.mjs";
|
|
7
7
|
import { l as Z } from "./index-DspCttgG.mjs";
|
|
8
|
-
import { _ as ee, u as le } from "./userInvoice.vue_vue_type_script_setup_true_lang-
|
|
8
|
+
import { _ as ee, u as le } from "./userInvoice.vue_vue_type_script_setup_true_lang-3eHl8CCv.mjs";
|
|
9
9
|
import { E as oe } from "./el-message-VSzNakoG.mjs";
|
|
10
10
|
import { _ as te } from "./_plugin-vue_export-helper-CHgC5LLL.mjs";
|
|
11
11
|
const ae = { class: "app-container" }, ne = { class: "search-container" }, se = { class: "form-footer" }, re = /* @__PURE__ */ O({
|
|
@@ -1,42 +1,42 @@
|
|
|
1
|
-
import { defineComponent as F, ref as d, computed as E, reactive as G, resolveComponent as
|
|
1
|
+
import { defineComponent as F, ref as d, computed as E, reactive as G, resolveComponent as f, createElementBlock as J, openBlock as k, createElementVNode as s, createBlock as q, createCommentVNode as U, toDisplayString as v, createVNode as a, withCtx as u, createTextVNode as y, unref as $ } from "vue";
|
|
2
2
|
import { o as D } from "./index-B90ZLkZ9.mjs";
|
|
3
3
|
import { o as M } from "./index-BP8zUjOw.mjs";
|
|
4
4
|
import { useTableHooks as K } from "jmash-core";
|
|
5
5
|
import { useI18n as W } from "vue-i18n";
|
|
6
6
|
import { useRoute as X, useRouter as Y } from "vue-router";
|
|
7
7
|
import Z from "./edit-Omp_CxC3.mjs";
|
|
8
|
-
import { E as
|
|
8
|
+
import { E as _ } from "./el-message-VSzNakoG.mjs";
|
|
9
9
|
import { _ as ee } from "./_plugin-vue_export-helper-CHgC5LLL.mjs";
|
|
10
|
-
const te = { class: "app-container" }, oe = { class: "search-container" }, se = { class: "address-management-container" },
|
|
10
|
+
const te = { class: "app-container" }, oe = { class: "search-container" }, se = { class: "address-management-container" }, le = { class: "subscription-info" }, ne = { class: "info-item" }, ae = { class: "value" }, de = { class: "info-item" }, re = { class: "value" }, ie = { class: "info-item" }, ue = { class: "value" }, me = { class: "action-bar" }, pe = { class: "address-table" }, ce = { class: "footer" }, fe = /* @__PURE__ */ F({
|
|
11
11
|
__name: "orderAddress",
|
|
12
12
|
setup(ve) {
|
|
13
|
-
const { t:
|
|
14
|
-
title:
|
|
13
|
+
const { t: b } = W(), m = d([]), w = X(), B = Y(), p = d(0), x = d(""), r = d({
|
|
14
|
+
title: b("common.edit"),
|
|
15
15
|
visible: !1
|
|
16
16
|
});
|
|
17
17
|
function L() {
|
|
18
|
-
r.value.title =
|
|
18
|
+
r.value.title = b("common.add"), r.value.visible = !0;
|
|
19
19
|
}
|
|
20
|
-
const
|
|
21
|
-
D.findOrderInfoById({ orderId:
|
|
22
|
-
var
|
|
23
|
-
|
|
24
|
-
const e = (
|
|
25
|
-
|
|
20
|
+
const A = d("");
|
|
21
|
+
D.findOrderInfoById({ orderId: w.query.orderId }).then((t) => {
|
|
22
|
+
var n, o, i, I;
|
|
23
|
+
x.value = (o = (n = t.data.orderItemList) == null ? void 0 : n.results[0]) == null ? void 0 : o.itemId;
|
|
24
|
+
const e = (I = (i = t.data.orderItemList) == null ? void 0 : i.results[0]) == null ? void 0 : I.quantity;
|
|
25
|
+
p.value = typeof e == "number" ? e : 0, A.value = t.data.shopId;
|
|
26
26
|
});
|
|
27
|
-
const
|
|
28
|
-
const e =
|
|
29
|
-
return
|
|
27
|
+
const g = E(() => m.value.reduce((t, e) => t + (e.goodsNum || 0), 0)), P = E(() => p.value - g.value), N = (t) => {
|
|
28
|
+
const e = g.value - (t.goodsNum || 0);
|
|
29
|
+
return p.value - e;
|
|
30
30
|
}, T = (t) => {
|
|
31
31
|
const e = t.goodsNum ?? 0;
|
|
32
32
|
e < 0 && (t.goodsNum = 0);
|
|
33
|
-
const
|
|
34
|
-
e >
|
|
33
|
+
const n = N(t);
|
|
34
|
+
e > n && (t.goodsNum = e, _.warning(`订阅份数不能超过${n}份`));
|
|
35
35
|
};
|
|
36
36
|
h();
|
|
37
37
|
function h() {
|
|
38
38
|
M.findList().then((t) => {
|
|
39
|
-
|
|
39
|
+
m.value = t.data.results.map((e) => ({
|
|
40
40
|
...e,
|
|
41
41
|
goodsNum: 0
|
|
42
42
|
// 初始化为0
|
|
@@ -47,37 +47,41 @@ const te = { class: "app-container" }, oe = { class: "search-container" }, se =
|
|
|
47
47
|
requestId: Math.random() * 10 + ""
|
|
48
48
|
}), j = () => {
|
|
49
49
|
let t = !0;
|
|
50
|
-
for (const o of
|
|
50
|
+
for (const o of m.value)
|
|
51
51
|
if (o.goodsNum && o.goodsNum > 0) {
|
|
52
|
-
const
|
|
53
|
-
if (o.goodsNum >
|
|
54
|
-
|
|
52
|
+
const i = N(o);
|
|
53
|
+
if (o.goodsNum > i) {
|
|
54
|
+
_.warning("某地址订阅份数超出可分配范围,请检查后重新提交"), t = !1;
|
|
55
55
|
break;
|
|
56
56
|
}
|
|
57
57
|
}
|
|
58
58
|
if (!t)
|
|
59
59
|
return;
|
|
60
|
-
|
|
60
|
+
if (g.value !== p.value) {
|
|
61
|
+
_.warning("分配份数与总订阅份数不匹配,请调整后重新提交");
|
|
62
|
+
return;
|
|
63
|
+
}
|
|
64
|
+
const n = m.value.filter((o) => o.goodsNum && o.goodsNum > 0).map((o) => ({
|
|
61
65
|
addressId: o.addressId,
|
|
62
66
|
goodsNum: o.goodsNum
|
|
63
67
|
}));
|
|
64
|
-
if (
|
|
65
|
-
|
|
68
|
+
if (n.length === 0) {
|
|
69
|
+
_.warning("请至少为一个地址分配订阅份数");
|
|
66
70
|
return;
|
|
67
71
|
}
|
|
68
72
|
D.createOrderAddress({
|
|
69
73
|
...R,
|
|
70
|
-
orderItemId:
|
|
71
|
-
userAddresses:
|
|
74
|
+
orderItemId: x.value,
|
|
75
|
+
userAddresses: n
|
|
72
76
|
}).then((o) => {
|
|
73
|
-
o && o.data === !0 && (
|
|
77
|
+
o && o.data === !0 && (_({
|
|
74
78
|
message: "提交成功",
|
|
75
79
|
type: "success"
|
|
76
80
|
}), B.push({
|
|
77
81
|
path: "/buyer/order-newspaper/orderDetails",
|
|
78
82
|
query: {
|
|
79
|
-
orderId:
|
|
80
|
-
shopId:
|
|
83
|
+
orderId: w.query.orderId,
|
|
84
|
+
shopId: A.value
|
|
81
85
|
}
|
|
82
86
|
}));
|
|
83
87
|
}).catch((o) => {
|
|
@@ -86,116 +90,116 @@ const te = { class: "app-container" }, oe = { class: "search-container" }, se =
|
|
|
86
90
|
function H(t) {
|
|
87
91
|
t && h();
|
|
88
92
|
}
|
|
89
|
-
const
|
|
93
|
+
const c = d(!1), O = d({}), { tableHooks: V } = K(b, M, O);
|
|
90
94
|
function Q() {
|
|
91
|
-
|
|
95
|
+
c.value = !1;
|
|
92
96
|
}
|
|
93
97
|
function S(t) {
|
|
94
|
-
t.updateMask = "",
|
|
95
|
-
|
|
98
|
+
t.updateMask = "", V.importExcel(t).then(() => {
|
|
99
|
+
c.value = !1, h();
|
|
96
100
|
});
|
|
97
101
|
}
|
|
98
102
|
return (t, e) => {
|
|
99
|
-
const
|
|
103
|
+
const n = f("el-button"), o = f("el-table-column"), i = f("el-input"), I = f("el-table"), z = f("jmash-import-upload");
|
|
100
104
|
return k(), J("div", te, [
|
|
101
105
|
s("div", oe, [
|
|
102
106
|
s("div", se, [
|
|
103
107
|
e[11] || (e[11] = s("div", { class: "header" }, [
|
|
104
108
|
s("h2", null, "收报地址")
|
|
105
109
|
], -1)),
|
|
106
|
-
s("div",
|
|
107
|
-
s("div",
|
|
110
|
+
s("div", le, [
|
|
111
|
+
s("div", ne, [
|
|
108
112
|
e[5] || (e[5] = s("span", null, "总订阅份数:", -1)),
|
|
109
|
-
s("span", ae,
|
|
113
|
+
s("span", ae, v(p.value) + "份", 1)
|
|
110
114
|
]),
|
|
111
115
|
s("div", de, [
|
|
112
116
|
e[6] || (e[6] = s("span", null, "已分配:", -1)),
|
|
113
|
-
s("span", re,
|
|
117
|
+
s("span", re, v(g.value) + "份", 1)
|
|
114
118
|
]),
|
|
115
119
|
s("div", ie, [
|
|
116
120
|
e[7] || (e[7] = s("span", null, "待分配:", -1)),
|
|
117
|
-
s("span", ue,
|
|
121
|
+
s("span", ue, v(P.value) + "份", 1)
|
|
118
122
|
])
|
|
119
123
|
]),
|
|
120
124
|
s("div", me, [
|
|
121
|
-
a(
|
|
125
|
+
a(n, {
|
|
122
126
|
type: "danger",
|
|
123
127
|
class: "add-button",
|
|
124
|
-
onClick: e[0] || (e[0] = (
|
|
128
|
+
onClick: e[0] || (e[0] = (l) => L())
|
|
125
129
|
}, {
|
|
126
|
-
default:
|
|
127
|
-
|
|
130
|
+
default: u(() => e[8] || (e[8] = [
|
|
131
|
+
y("新增收报地址")
|
|
128
132
|
])),
|
|
129
133
|
_: 1,
|
|
130
134
|
__: [8]
|
|
131
135
|
}),
|
|
132
|
-
a(
|
|
136
|
+
a(n, {
|
|
133
137
|
type: "danger",
|
|
134
138
|
class: "add-button",
|
|
135
|
-
onClick: e[1] || (e[1] = (
|
|
139
|
+
onClick: e[1] || (e[1] = (l) => c.value = !0)
|
|
136
140
|
}, {
|
|
137
|
-
default:
|
|
138
|
-
|
|
141
|
+
default: u(() => e[9] || (e[9] = [
|
|
142
|
+
y("导入收报地址")
|
|
139
143
|
])),
|
|
140
144
|
_: 1,
|
|
141
145
|
__: [9]
|
|
142
146
|
})
|
|
143
147
|
]),
|
|
144
148
|
s("div", pe, [
|
|
145
|
-
a(
|
|
146
|
-
data:
|
|
149
|
+
a(I, {
|
|
150
|
+
data: m.value,
|
|
147
151
|
border: "",
|
|
148
152
|
style: { width: "100%" },
|
|
149
153
|
"header-cell-style": { backgroundColor: "#fafafa", color: "#333" }
|
|
150
154
|
}, {
|
|
151
|
-
default:
|
|
152
|
-
a(
|
|
155
|
+
default: u(() => [
|
|
156
|
+
a(o, {
|
|
153
157
|
label: "序号",
|
|
154
158
|
width: "80",
|
|
155
159
|
align: "center",
|
|
156
160
|
type: "index"
|
|
157
161
|
}),
|
|
158
|
-
a(
|
|
162
|
+
a(o, {
|
|
159
163
|
prop: "note",
|
|
160
164
|
label: "收报单位",
|
|
161
165
|
"min-width": "180"
|
|
162
166
|
}),
|
|
163
|
-
a(
|
|
167
|
+
a(o, {
|
|
164
168
|
prop: "userName",
|
|
165
169
|
label: "收报人",
|
|
166
170
|
width: "120",
|
|
167
171
|
align: "center"
|
|
168
172
|
}),
|
|
169
|
-
a(
|
|
173
|
+
a(o, {
|
|
170
174
|
prop: "mobilePhone",
|
|
171
175
|
label: "联系电话",
|
|
172
176
|
width: "150",
|
|
173
177
|
align: "center"
|
|
174
178
|
}),
|
|
175
|
-
a(
|
|
179
|
+
a(o, {
|
|
176
180
|
prop: "detailInfo",
|
|
177
181
|
label: "收报地址",
|
|
178
182
|
"min-width": "250"
|
|
179
183
|
}, {
|
|
180
|
-
default:
|
|
181
|
-
|
|
184
|
+
default: u(({ row: l }) => [
|
|
185
|
+
y(v(l.cityName) + v(l.detailInfo), 1)
|
|
182
186
|
]),
|
|
183
187
|
_: 1
|
|
184
188
|
}),
|
|
185
|
-
a(
|
|
189
|
+
a(o, {
|
|
186
190
|
label: "订阅份数",
|
|
187
191
|
width: "100",
|
|
188
192
|
align: "center"
|
|
189
193
|
}, {
|
|
190
|
-
default:
|
|
191
|
-
a(
|
|
192
|
-
modelValue:
|
|
193
|
-
"onUpdate:modelValue": (C) =>
|
|
194
|
+
default: u(({ row: l }) => [
|
|
195
|
+
a(i, {
|
|
196
|
+
modelValue: l.goodsNum,
|
|
197
|
+
"onUpdate:modelValue": (C) => l.goodsNum = C,
|
|
194
198
|
modelModifiers: { number: !0 },
|
|
195
199
|
type: "number",
|
|
196
200
|
min: "0",
|
|
197
|
-
max: N(
|
|
198
|
-
onInput: (C) => T(
|
|
201
|
+
max: N(l),
|
|
202
|
+
onInput: (C) => T(l)
|
|
199
203
|
}, null, 8, ["modelValue", "onUpdate:modelValue", "max", "onInput"])
|
|
200
204
|
]),
|
|
201
205
|
_: 1
|
|
@@ -205,13 +209,13 @@ const te = { class: "app-container" }, oe = { class: "search-container" }, se =
|
|
|
205
209
|
}, 8, ["data"])
|
|
206
210
|
]),
|
|
207
211
|
s("div", ce, [
|
|
208
|
-
a(
|
|
212
|
+
a(n, {
|
|
209
213
|
type: "danger",
|
|
210
214
|
class: "confirm-button",
|
|
211
|
-
onClick: e[2] || (e[2] = (
|
|
215
|
+
onClick: e[2] || (e[2] = (l) => j())
|
|
212
216
|
}, {
|
|
213
|
-
default:
|
|
214
|
-
|
|
217
|
+
default: u(() => e[10] || (e[10] = [
|
|
218
|
+
y("确定")
|
|
215
219
|
])),
|
|
216
220
|
_: 1,
|
|
217
221
|
__: [10]
|
|
@@ -219,27 +223,27 @@ const te = { class: "app-container" }, oe = { class: "search-container" }, se =
|
|
|
219
223
|
])
|
|
220
224
|
])
|
|
221
225
|
]),
|
|
222
|
-
r.value.visible ? (k(),
|
|
226
|
+
r.value.visible ? (k(), q(Z, {
|
|
223
227
|
key: 0,
|
|
224
228
|
modelValue: r.value.visible,
|
|
225
|
-
"onUpdate:modelValue": e[3] || (e[3] = (
|
|
229
|
+
"onUpdate:modelValue": e[3] || (e[3] = (l) => r.value.visible = l),
|
|
226
230
|
title: r.value.title,
|
|
227
231
|
onRefresh: H,
|
|
228
232
|
width: "500px",
|
|
229
233
|
"close-on-click-modal": !1
|
|
230
|
-
}, null, 8, ["modelValue", "title"])) :
|
|
231
|
-
|
|
234
|
+
}, null, 8, ["modelValue", "title"])) : U("", !0),
|
|
235
|
+
c.value ? (k(), q(z, {
|
|
232
236
|
key: 1,
|
|
233
|
-
"upload-visible":
|
|
237
|
+
"upload-visible": c.value,
|
|
234
238
|
"template-title": t.$t("sysUser.templateDownload"),
|
|
235
|
-
onTemplateDown: e[4] || (e[4] = (
|
|
239
|
+
onTemplateDown: e[4] || (e[4] = (l) => $(V).downloadTemplate($(b)("newsPapepr.names"))),
|
|
236
240
|
onImportEvents: S,
|
|
237
241
|
onUploadClosed: Q
|
|
238
|
-
}, null, 8, ["upload-visible", "template-title"])) :
|
|
242
|
+
}, null, 8, ["upload-visible", "template-title"])) : U("", !0)
|
|
239
243
|
]);
|
|
240
244
|
};
|
|
241
245
|
}
|
|
242
|
-
}),
|
|
246
|
+
}), xe = /* @__PURE__ */ ee(fe, [["__scopeId", "data-v-64c6cbde"]]);
|
|
243
247
|
export {
|
|
244
|
-
|
|
248
|
+
xe as default
|
|
245
249
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent as we, ref as _, reactive as h, onMounted as Ke, resolveComponent as c, createElementBlock as Le, openBlock as k, createVNode as r, createBlock as B, createCommentVNode as D, withCtx as m, createElementVNode as t, unref as O, toDisplayString as a, createTextVNode as fe } from "vue";
|
|
2
2
|
import { useI18n as Ae } from "vue-i18n";
|
|
3
|
-
import { D as ve } from "./index-
|
|
3
|
+
import { D as ve } from "./index-Knr6dYOL.mjs";
|
|
4
4
|
import { o as be } from "./index-BKZPqxLM.mjs";
|
|
5
5
|
import { fileApi as ye } from "jmash-core";
|
|
6
6
|
import { useRoute as $e, useRouter as Ue } from "vue-router";
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useRouter as
|
|
1
|
+
import { defineComponent as C, ref as d, computed as g, reactive as M, resolveComponent as B, createElementBlock as L, openBlock as A, createElementVNode as t, createVNode as V, unref as I, toDisplayString as l, withDirectives as $, vModelText as z } from "vue";
|
|
2
|
+
import { useRouter as F, useRoute as O } from "vue-router";
|
|
3
3
|
import { o as p } from "./index-B90ZLkZ9.mjs";
|
|
4
|
-
import { useUserStore as
|
|
4
|
+
import { useUserStore as R, fileApi as h } from "jmash-core";
|
|
5
5
|
import { E as y } from "./el-message-VSzNakoG.mjs";
|
|
6
|
-
import { _ as
|
|
7
|
-
const
|
|
6
|
+
import { _ as J } from "./_plugin-vue_export-helper-CHgC5LLL.mjs";
|
|
7
|
+
const T = { class: "app-container" }, W = { class: "search-container" }, j = { class: "newspaper-info" }, G = { class: "newspaper-preview" }, H = { class: "subscription-form" }, K = { style: { "font-weight": "bold" } }, Q = { class: "form-group" }, X = { class: "form-value order-day" }, Y = { class: "form-group" }, Z = { class: "price-info" }, ee = { class: "price" }, te = { class: "form-group" }, se = { class: "quantity-selector" }, oe = { class: "total-price" }, re = { class: "price" }, ae = /* @__PURE__ */ C({
|
|
8
8
|
__name: "orderPaper",
|
|
9
|
-
setup(
|
|
10
|
-
const s =
|
|
9
|
+
setup(ne) {
|
|
10
|
+
const s = d({
|
|
11
11
|
picUrls: ""
|
|
12
|
-
}),
|
|
13
|
-
p.findById({ spuId:
|
|
12
|
+
}), b = F(), k = O(), v = localStorage.getItem("unionUserInfo"), P = (v ? JSON.parse(v) : {}).orgId;
|
|
13
|
+
p.findById({ spuId: k.query.spuId }).then((o) => {
|
|
14
14
|
s.value = o.data;
|
|
15
15
|
});
|
|
16
|
-
const w = g(() => s.value.goodsStartDate && s.value.goodsEndDate ? `${s.value.goodsStartDate}至${s.value.goodsEndDate}` : ""), r =
|
|
16
|
+
const w = g(() => s.value.goodsStartDate && s.value.goodsEndDate ? `${s.value.goodsStartDate}至${s.value.goodsEndDate}` : ""), r = d(1), U = () => {
|
|
17
17
|
r.value > 1 && r.value--;
|
|
18
18
|
}, N = () => {
|
|
19
19
|
r.value++;
|
|
@@ -21,23 +21,23 @@ const J = { class: "app-container" }, T = { class: "search-container" }, W = { c
|
|
|
21
21
|
var i, a, n;
|
|
22
22
|
const o = ((n = (a = (i = s.value.skuList) == null ? void 0 : i.results) == null ? void 0 : a[0]) == null ? void 0 : n.salePrice) || 0, e = r.value * o;
|
|
23
23
|
return parseFloat(e.toFixed(2));
|
|
24
|
-
}),
|
|
24
|
+
}), D = (o) => {
|
|
25
25
|
const e = parseInt(o.target.value);
|
|
26
26
|
isNaN(e) || e < 1 ? r.value = 1 : r.value = e;
|
|
27
|
-
}, f =
|
|
28
|
-
function
|
|
29
|
-
p.findUnionName({ tenant:
|
|
30
|
-
f.value = o.data.
|
|
27
|
+
}, m = d(""), f = d(""), x = R().user.tenant;
|
|
28
|
+
function S() {
|
|
29
|
+
p.findUnionName({ tenant: x }).then((o) => {
|
|
30
|
+
m.value = o.data.orgName, f.value = o.data.chargePersonMobile;
|
|
31
31
|
});
|
|
32
32
|
}
|
|
33
|
-
|
|
34
|
-
const
|
|
33
|
+
S();
|
|
34
|
+
const q = M({
|
|
35
35
|
requestId: Math.random() * 10 + ""
|
|
36
36
|
});
|
|
37
|
-
function
|
|
37
|
+
function E() {
|
|
38
38
|
var i, a, n, _;
|
|
39
39
|
const o = (a = (i = s.value.skuList) == null ? void 0 : i.results) == null ? void 0 : a[0], e = (_ = (n = s.value.skuList) == null ? void 0 : n.results) == null ? void 0 : _[0];
|
|
40
|
-
if (
|
|
40
|
+
if (!o || !e) {
|
|
41
41
|
y({
|
|
42
42
|
message: "商品信息不完整",
|
|
43
43
|
type: "error"
|
|
@@ -45,43 +45,44 @@ const J = { class: "app-container" }, T = { class: "search-container" }, W = { c
|
|
|
45
45
|
return;
|
|
46
46
|
}
|
|
47
47
|
p.create({
|
|
48
|
-
...
|
|
48
|
+
...q,
|
|
49
49
|
shopId: s.value.shopId,
|
|
50
50
|
spuId: s.value.spuId,
|
|
51
|
-
shopBrancheId:
|
|
51
|
+
shopBrancheId: P,
|
|
52
52
|
salesPrice: u.value,
|
|
53
53
|
orderPrice: u.value,
|
|
54
54
|
deliveryWay: "self_pickup",
|
|
55
55
|
remark: w.value,
|
|
56
|
-
unitName:
|
|
56
|
+
unitName: m.value,
|
|
57
|
+
mobilePhone: f.value,
|
|
57
58
|
orderItems: [
|
|
58
59
|
{
|
|
59
60
|
skuId: e.skuId,
|
|
60
61
|
quantity: r.value
|
|
61
62
|
}
|
|
62
63
|
]
|
|
63
|
-
}).then((
|
|
64
|
-
|
|
64
|
+
}).then((c) => {
|
|
65
|
+
c.status === 200 && (y({
|
|
65
66
|
message: "提交成功",
|
|
66
67
|
type: "success"
|
|
67
|
-
}),
|
|
68
|
+
}), b.push({
|
|
68
69
|
path: "/buyer/order-newspaper/orderAddress",
|
|
69
70
|
query: {
|
|
70
71
|
orderPrice: u.value,
|
|
71
|
-
orderId:
|
|
72
|
+
orderId: c.data.orderId
|
|
72
73
|
}
|
|
73
74
|
}));
|
|
74
|
-
}).catch((
|
|
75
|
+
}).catch((c) => {
|
|
75
76
|
});
|
|
76
77
|
}
|
|
77
78
|
return (o, e) => {
|
|
78
79
|
var a;
|
|
79
80
|
const i = B("el-image");
|
|
80
|
-
return A(), L("div",
|
|
81
|
-
t("div",
|
|
82
|
-
t("div",
|
|
83
|
-
t("div",
|
|
84
|
-
|
|
81
|
+
return A(), L("div", T, [
|
|
82
|
+
t("div", W, [
|
|
83
|
+
t("div", j, [
|
|
84
|
+
t("div", G, [
|
|
85
|
+
V(i, {
|
|
85
86
|
src: I(h).imageUrl(s.value.picUrls, 0, 0),
|
|
86
87
|
"preview-src-list": [I(h).imageUrl(s.value.picUrls)],
|
|
87
88
|
"preview-teleported": "",
|
|
@@ -89,34 +90,34 @@ const J = { class: "app-container" }, T = { class: "search-container" }, W = { c
|
|
|
89
90
|
fit: "contain"
|
|
90
91
|
}, null, 8, ["src", "preview-src-list"])
|
|
91
92
|
]),
|
|
92
|
-
t("div",
|
|
93
|
-
t("div",
|
|
94
|
-
t("div",
|
|
93
|
+
t("div", H, [
|
|
94
|
+
t("div", K, l(s.value.spuName), 1),
|
|
95
|
+
t("div", Q, [
|
|
95
96
|
e[2] || (e[2] = t("label", { class: "order-label" }, "订阅周期", -1)),
|
|
96
|
-
t("div",
|
|
97
|
+
t("div", X, l(s.value.goodsStartDate) + "至" + l(s.value.goodsEndDate), 1)
|
|
97
98
|
]),
|
|
98
|
-
t("div",
|
|
99
|
+
t("div", Y, [
|
|
99
100
|
e[4] || (e[4] = t("label", { style: { "font-weight": "600", color: "#000", "font-size": "13px" } }, "价格信息", -1)),
|
|
100
|
-
t("div",
|
|
101
|
+
t("div", Z, [
|
|
101
102
|
e[3] || (e[3] = t("span", { class: "form-value" }, "单价:", -1)),
|
|
102
|
-
t("div",
|
|
103
|
+
t("div", ee, " ¥" + l((a = s.value.skuList) == null ? void 0 : a.results[0].salePrice), 1)
|
|
103
104
|
])
|
|
104
105
|
]),
|
|
105
|
-
t("div",
|
|
106
|
-
t("div",
|
|
106
|
+
t("div", te, [
|
|
107
|
+
t("div", se, [
|
|
107
108
|
e[5] || (e[5] = t("label", { class: "form-value" }, "订阅份数:", -1)),
|
|
108
109
|
t("button", {
|
|
109
110
|
class: "btn-minus",
|
|
110
111
|
onClick: U
|
|
111
112
|
}, "-"),
|
|
112
|
-
|
|
113
|
+
$(t("input", {
|
|
113
114
|
type: "text",
|
|
114
115
|
"onUpdate:modelValue": e[0] || (e[0] = (n) => r.value = n),
|
|
115
116
|
class: "quantity-input",
|
|
116
|
-
onInput:
|
|
117
|
+
onInput: D
|
|
117
118
|
}, null, 544), [
|
|
118
119
|
[
|
|
119
|
-
|
|
120
|
+
z,
|
|
120
121
|
r.value,
|
|
121
122
|
void 0,
|
|
122
123
|
{ number: !0 }
|
|
@@ -128,21 +129,21 @@ const J = { class: "app-container" }, T = { class: "search-container" }, W = { c
|
|
|
128
129
|
}, "+")
|
|
129
130
|
])
|
|
130
131
|
]),
|
|
131
|
-
t("div",
|
|
132
|
+
t("div", oe, [
|
|
132
133
|
e[6] || (e[6] = t("span", { style: { "font-weight": "600", color: "#000", "font-size": "13px" } }, "总价", -1)),
|
|
133
|
-
t("div",
|
|
134
|
+
t("div", re, "¥" + l(u.value), 1)
|
|
134
135
|
])
|
|
135
136
|
])
|
|
136
137
|
]),
|
|
137
138
|
t("button", {
|
|
138
139
|
class: "order-btn",
|
|
139
|
-
onClick: e[1] || (e[1] = (n) =>
|
|
140
|
+
onClick: e[1] || (e[1] = (n) => E())
|
|
140
141
|
}, "立即订阅")
|
|
141
142
|
])
|
|
142
143
|
]);
|
|
143
144
|
};
|
|
144
145
|
}
|
|
145
|
-
}),
|
|
146
|
+
}), me = /* @__PURE__ */ J(ae, [["__scopeId", "data-v-f152c2e4"]]);
|
|
146
147
|
export {
|
|
147
|
-
|
|
148
|
+
me as default
|
|
148
149
|
};
|