xyvcard-paper-buyer 0.0.44 → 0.0.46

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,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-DAXED5UU.mjs"), P = () => import("./orderAddress-DMeZ9ynO.mjs"), q = () => import("./orderInfo-BE6BEAw1.mjs"), D = () => import("./payment-DD_Lhvf0.mjs"), N = () => import("./invoice-Ca967WuM.mjs"), z = () => import("./invoiceView-BQ20QFpo.mjs"), x = () => import("./applyEdit-DMbelNYl.mjs"), C = () => import("./invoiceEdit-D3qEYbNL.mjs"), k = () => import("./info-iJb2mpwO.mjs"), t = [
380
+ const R = () => import("./index-BWV5njqv.mjs"), w = () => import("./orderPaper-DUCuNxKR.mjs"), P = () => import("./orderAddress-DMeZ9ynO.mjs"), q = () => import("./orderInfo-D4kQAdLE.mjs"), D = () => import("./payment-D2PWs1qD.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-DMbelNYl.mjs"), "./views/buyer/order-info/index.vue": () => import("./index-CJvB_knp.mjs"), "./views/buyer/order-info/info.vue": () => import("./info-iJb2mpwO.mjs"), "./views/buyer/order-info/invoice.vue": () => import("./invoice-Ca967WuM.mjs"), "./views/buyer/order-info/invoiceEdit.vue": () => import("./invoiceEdit-D3qEYbNL.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-CZ7yW4I6.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-BE6BEAw1.mjs"), "./views/buyer/order-newspaper/orderPaper.vue": () => import("./orderPaper-DAXED5UU.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 = {
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-Cn-5Spij.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-CLQHmyNq.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-5anhjN7y.mjs"), "./views/buyer/order-newspaper/orderAddress.vue": () => import("./orderAddress-DMeZ9ynO.mjs"), "./views/buyer/order-newspaper/orderInfo.vue": () => import("./orderInfo-D4kQAdLE.mjs"), "./views/buyer/order-newspaper/orderPaper.vue": () => import("./orderPaper-DUCuNxKR.mjs"), "./views/buyer/order-newspaper/payment.vue": () => import("./payment-D2PWs1qD.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,6 +1,6 @@
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-BPKQNnjE.mjs";
3
- import { o as R } from "./index-DyTbbNUO.mjs";
2
+ import { D as h } from "./index-Knr6dYOL.mjs";
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";
6
6
  import { goodsSpuApi as ne } from "xyvcard-paper-goods";
@@ -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-BPKQNnjE.mjs";
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-D-3fXoBu.mjs";
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,9 +1,9 @@
1
- import { defineComponent as M, mergeModels as h, useModel as x, reactive as C, onMounted as S, resolveComponent as w, createBlock as q, openBlock as K, withCtx as c, createElementVNode as e, toDisplayString as a, unref as i, createVNode as $, createTextVNode as k } from "vue";
2
- import { useI18n as j } from "vue-i18n";
3
- import { o as I } from "./index-B90ZLkZ9.mjs";
1
+ import { defineComponent as x, mergeModels as _, useModel as E, reactive as h, onMounted as S, resolveComponent as C, createBlock as K, openBlock as j, withCtx as c, createElementVNode as e, toDisplayString as a, unref as i, createVNode as w, createTextVNode as $ } from "vue";
2
+ import { useI18n as O } from "vue-i18n";
3
+ import { o as k } from "./index-B90ZLkZ9.mjs";
4
4
  import { E as m } from "./el-message-VSzNakoG.mjs";
5
5
  import { ElMessage as v } from "element-plus";
6
- import { useRouter as O, useRoute as T } from "vue-router";
6
+ import { useRouter as T, useRoute as q } from "vue-router";
7
7
  import { _ as R } from "./_plugin-vue_export-helper-CHgC5LLL.mjs";
8
8
  function z(p) {
9
9
  if (console.log(navigator.clipboard && window.isSecureContext), navigator.clipboard && window.isSecureContext)
@@ -31,9 +31,9 @@ function z(p) {
31
31
  }
32
32
  }
33
33
  }
34
- const D = { class: "info-card" }, F = { class: "info-item" }, U = { class: "info-item-item" }, W = { class: "info-item" }, G = { class: "info-item-item" }, H = { class: "info-card-one" }, J = { class: "info-item" }, L = { class: "info-item-item" }, Q = { class: "info-item" }, X = { class: "info-item-item" }, Y = { class: "info-item" }, Z = { class: "info-item-item" }, ee = { class: "footer" }, oe = /* @__PURE__ */ M({
34
+ const D = { class: "info-card" }, F = { class: "info-item" }, U = { class: "info-item-item" }, W = { class: "info-item" }, G = { class: "info-item-item" }, H = { class: "info-card-one" }, J = { class: "info-item" }, L = { class: "info-item-item" }, Q = { class: "info-item" }, X = { class: "info-item-item" }, Y = { class: "info-item" }, Z = { class: "info-item-item" }, ee = { class: "footer" }, oe = /* @__PURE__ */ x({
35
35
  __name: "onlineBanking",
36
- props: /* @__PURE__ */ h({
36
+ props: /* @__PURE__ */ _({
37
37
  bankKey: {
38
38
  type: Object,
39
39
  default: () => ({})
@@ -50,13 +50,13 @@ const D = { class: "info-card" }, F = { class: "info-item" }, U = { class: "info
50
50
  modelValue: { type: Boolean, default: !1 },
51
51
  modelModifiers: {}
52
52
  }),
53
- emits: /* @__PURE__ */ h(["refresh", "close", "open-prompt"], ["update:modelValue"]),
53
+ emits: /* @__PURE__ */ _(["refresh", "close", "open-prompt"], ["update:modelValue"]),
54
54
  setup(p, { emit: s }) {
55
- const { t: l } = j(), P = O(), b = T(), u = p, y = x(p, "modelValue"), f = s, t = C({});
55
+ const { t: l } = O(), P = T(), I = q(), u = p, y = E(p, "modelValue"), f = s, t = h({});
56
56
  function N() {
57
- I.createPay({
57
+ k.createPay({
58
58
  shopPayInfoId: u.bankKey.shopPayInfoId,
59
- orderId: b.query.orderId
59
+ orderId: I.query.orderId
60
60
  }).then(({ data: n }) => {
61
61
  Object.assign(t, n);
62
62
  }).catch(() => {
@@ -64,11 +64,11 @@ const D = { class: "info-card" }, F = { class: "info-item" }, U = { class: "info
64
64
  });
65
65
  }
66
66
  S(N);
67
- let A = C({
67
+ let A = h({
68
68
  requestId: Math.random() * 10 + ""
69
69
  });
70
70
  function B() {
71
- I.completedTransfer({
71
+ k.completedTransfer({
72
72
  shopPayInfoId: u.bankKey.shopPayInfoId,
73
73
  orderCode: u.bankKey.orderCode,
74
74
  ...A
@@ -76,15 +76,14 @@ const D = { class: "info-card" }, F = { class: "info-item" }, U = { class: "info
76
76
  n.data === "success" ? (v({
77
77
  message: l("common.submitSuccess"),
78
78
  type: "success"
79
- }), f("refresh", !0), g(), P.push({
80
- path: "/buyer/order-info/applyEdit",
81
- query: { orderId: b.query.orderId }
79
+ }), f("refresh", !0), b(), P.push({
80
+ path: "/buyer/order-info"
82
81
  })) : f("open-prompt", t);
83
82
  }).catch(() => {
84
83
  v.error("提交失败,请重试");
85
84
  });
86
85
  }
87
- function g() {
86
+ function b() {
88
87
  f("close"), y.value = !1;
89
88
  }
90
89
  function r(n) {
@@ -104,30 +103,30 @@ const D = { class: "info-card" }, F = { class: "info-item" }, U = { class: "info
104
103
  r(o);
105
104
  }
106
105
  return (n, o) => {
107
- const _ = w("el-button"), E = w("el-dialog");
108
- return K(), q(E, {
106
+ const g = C("el-button"), M = C("el-dialog");
107
+ return j(), K(M, {
109
108
  modelValue: y.value,
110
109
  "onUpdate:modelValue": o[5] || (o[5] = (d) => y.value = d),
111
110
  title: p.title,
112
111
  width: p.width,
113
- onClose: g,
112
+ onClose: b,
114
113
  "destroy-on-close": ""
115
114
  }, {
116
115
  footer: c(() => [
117
116
  e("div", ee, [
118
- $(_, { onClick: V }, {
117
+ w(g, { onClick: V }, {
119
118
  default: c(() => o[6] || (o[6] = [
120
- k("一键复制")
119
+ $("一键复制")
121
120
  ])),
122
121
  _: 1,
123
122
  __: [6]
124
123
  }),
125
- $(_, {
124
+ w(g, {
126
125
  type: "primary",
127
126
  onClick: B
128
127
  }, {
129
128
  default: c(() => o[7] || (o[7] = [
130
- k("已完成转账")
129
+ $("已完成转账")
131
130
  ])),
132
131
  _: 1,
133
132
  __: [7]
@@ -196,7 +195,7 @@ const D = { class: "info-card" }, F = { class: "info-item" }, U = { class: "info
196
195
  }, 8, ["modelValue", "title", "width"]);
197
196
  };
198
197
  }
199
- }), re = /* @__PURE__ */ R(oe, [["__scopeId", "data-v-3c63890d"]]);
198
+ }), re = /* @__PURE__ */ R(oe, [["__scopeId", "data-v-e9758a95"]]);
200
199
  export {
201
200
  re as default
202
201
  };
@@ -1,13 +1,13 @@
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-BPKQNnjE.mjs";
4
- import { o as be } from "./index-DyTbbNUO.mjs";
3
+ import { D as ve } from "./index-Knr6dYOL.mjs";
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";
7
7
  import { goodsSpuApi as Me } from "xyvcard-paper-goods";
8
- import qe from "./onlineBanking-CdDAY0YQ.mjs";
8
+ import qe from "./onlineBanking-5anhjN7y.mjs";
9
9
  import Se from "./prompt-DQX4apPU.mjs";
10
- import Te from "./confirm-BYEYokBP.mjs";
10
+ import Te from "./confirm-CLQHmyNq.mjs";
11
11
  import { o as Ie } from "./index-B90ZLkZ9.mjs";
12
12
  import { E as _e } from "./el-message-VSzNakoG.mjs";
13
13
  import { _ as je } from "./_plugin-vue_export-helper-CHgC5LLL.mjs";
@@ -1,19 +1,19 @@
1
- import { defineComponent as E, ref as c, computed as g, reactive as C, resolveComponent as B, createElementBlock as L, openBlock as A, createElementVNode as t, createVNode as M, unref as I, toDisplayString as l, withDirectives as V, vModelText as $ } from "vue";
2
- import { useRouter as z, useRoute as F } from "vue-router";
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 O, fileApi as h } from "jmash-core";
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 R } from "./_plugin-vue_export-helper-CHgC5LLL.mjs";
7
- const J = { class: "app-container" }, T = { class: "search-container" }, W = { class: "newspaper-info" }, j = { class: "newspaper-preview" }, G = { class: "subscription-form" }, H = { style: { "font-weight": "bold" } }, K = { class: "form-group" }, Q = { class: "form-value order-day" }, X = { class: "form-group" }, Y = { class: "price-info" }, Z = { class: "price" }, ee = { class: "form-group" }, te = { class: "quantity-selector" }, se = { class: "total-price" }, oe = { class: "price" }, re = /* @__PURE__ */ E({
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(ae) {
10
- const s = c({
9
+ setup(ne) {
10
+ const s = d({
11
11
  picUrls: ""
12
- }), k = z(), v = F(), m = localStorage.getItem("unionUserInfo"), b = (m ? JSON.parse(m) : {}).orgId;
13
- p.findById({ spuId: v.query.spuId }).then((o) => {
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 = c(1), U = () => {
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
- }), P = (o) => {
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 = c(""), D = O().user.tenant;
28
- function q() {
29
- p.findUnionName({ tenant: D }).then((o) => {
30
- f.value = o.data.orgName;
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
- q();
34
- const x = C({
33
+ S();
34
+ const q = M({
35
35
  requestId: Math.random() * 10 + ""
36
36
  });
37
- function S() {
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 (v.query.tenant, !o || !e) {
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
- ...x,
48
+ ...q,
49
49
  shopId: s.value.shopId,
50
50
  spuId: s.value.spuId,
51
- shopBrancheId: b,
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: f.value,
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((d) => {
64
- d.status === 200 && (y({
64
+ }).then((c) => {
65
+ c.status === 200 && (y({
65
66
  message: "提交成功",
66
67
  type: "success"
67
- }), k.push({
68
+ }), b.push({
68
69
  path: "/buyer/order-newspaper/orderAddress",
69
70
  query: {
70
71
  orderPrice: u.value,
71
- orderId: d.data.orderId
72
+ orderId: c.data.orderId
72
73
  }
73
74
  }));
74
- }).catch((d) => {
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", J, [
81
- t("div", T, [
82
- t("div", W, [
83
- t("div", j, [
84
- M(i, {
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", G, [
93
- t("div", H, l(s.value.spuName), 1),
94
- t("div", K, [
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", Q, l(s.value.goodsStartDate) + "至" + l(s.value.goodsEndDate), 1)
97
+ t("div", X, l(s.value.goodsStartDate) + "至" + l(s.value.goodsEndDate), 1)
97
98
  ]),
98
- t("div", X, [
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", Y, [
101
+ t("div", Z, [
101
102
  e[3] || (e[3] = t("span", { class: "form-value" }, "单价:", -1)),
102
- t("div", Z, " ¥" + l((a = s.value.skuList) == null ? void 0 : a.results[0].salePrice), 1)
103
+ t("div", ee, " ¥" + l((a = s.value.skuList) == null ? void 0 : a.results[0].salePrice), 1)
103
104
  ])
104
105
  ]),
105
- t("div", ee, [
106
- t("div", te, [
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
- V(t("input", {
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: P
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", se, [
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", oe, "¥" + l(u.value), 1)
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) => S())
140
+ onClick: e[1] || (e[1] = (n) => E())
140
141
  }, "立即订阅")
141
142
  ])
142
143
  ]);
143
144
  };
144
145
  }
145
- }), ve = /* @__PURE__ */ R(re, [["__scopeId", "data-v-3ad371c0"]]);
146
+ }), me = /* @__PURE__ */ J(ae, [["__scopeId", "data-v-f152c2e4"]]);
146
147
  export {
147
- ve as default
148
+ me as default
148
149
  };
@@ -1,4 +1,4 @@
1
- import { defineComponent as x, ref as a, onMounted as L, onUnmounted as P, resolveComponent as _, createElementBlock as s, openBlock as l, createElementVNode as c, createCommentVNode as v, createVNode as u, withCtx as b, unref as C } from "vue";
1
+ import { defineComponent as L, ref as a, onMounted as P, onUnmounted as b, resolveComponent as _, createElementBlock as s, openBlock as l, createElementVNode as c, createCommentVNode as p, createVNode as u, withCtx as q, unref as C } from "vue";
2
2
  import { l as N } from "./index-sU6sAHrn.mjs";
3
3
  import { useRoute as U, useRouter as M } from "vue-router";
4
4
  import { o as R } from "./index-B90ZLkZ9.mjs";
@@ -10,16 +10,16 @@ const z = { class: "lakala-payment-container" }, A = ["src"], S = {
10
10
  }, j = { class: "loading-content" }, D = {
11
11
  key: 1,
12
12
  class: "error-message"
13
- }, F = /* @__PURE__ */ x({
13
+ }, F = /* @__PURE__ */ L({
14
14
  __name: "payment",
15
15
  setup(G) {
16
- const n = U(), y = M(), h = n.query.counterUrl, i = n.query.orderId, k = n.params.tenant, d = a(""), o = a(!0), r = a(""), I = a(null), t = a();
17
- L(() => {
16
+ const n = U(), v = M(), y = n.query.counterUrl, h = n.query.orderId, k = n.params.tenant, i = a(""), o = a(!0), r = a(""), I = a(null), t = a();
17
+ P(() => {
18
18
  g();
19
19
  });
20
20
  const g = () => {
21
21
  try {
22
- d.value = h, o.value = !0, r.value = "";
22
+ i.value = y, o.value = !0, r.value = "";
23
23
  } catch {
24
24
  r.value = "支付初始化失败,请刷新页面重试", o.value = !1;
25
25
  }
@@ -29,13 +29,10 @@ const z = { class: "lakala-payment-container" }, A = ["src"], S = {
29
29
  const m = async () => {
30
30
  try {
31
31
  (await R.queryPayResult({
32
- orderId: i,
32
+ orderId: h,
33
33
  tenant: k
34
- })).data.status === "success" && (clearInterval(t.value), y.push({
35
- // path: "/buyer/order-newspaper/orderAddress",
36
- // path: "/buyer/order-info",
37
- path: "/buyer/order-info/applyEdit",
38
- query: { orderId: i }
34
+ })).data.status === "success" && (clearInterval(t.value), v.push({
35
+ path: "/buyer/order-info"
39
36
  }));
40
37
  } catch {
41
38
  V.error("支付结果验证失败,请稍后查看订单状态");
@@ -43,19 +40,19 @@ const z = { class: "lakala-payment-container" }, A = ["src"], S = {
43
40
  }, w = () => {
44
41
  o.value = !1, t.value && clearInterval(t.value), t.value = setInterval(() => {
45
42
  m();
46
- }, 1500), window.addEventListener("message", f);
47
- }, f = (e) => {
43
+ }, 1500), window.addEventListener("message", d);
44
+ }, d = (e) => {
48
45
  e.origin === "拉卡拉支付域名" && e.data === "payment_completed" && m();
49
46
  };
50
- return P(() => {
51
- clearInterval(t.value), window.removeEventListener("message", f);
52
- }), (e, p) => {
53
- const E = _("el-icon"), q = _("el-alert");
47
+ return b(() => {
48
+ clearInterval(t.value), window.removeEventListener("message", d);
49
+ }), (e, f) => {
50
+ const x = _("el-icon"), E = _("el-alert");
54
51
  return l(), s("div", z, [
55
52
  c("iframe", {
56
53
  ref_key: "lakalaIframe",
57
54
  ref: I,
58
- src: d.value,
55
+ src: i.value,
59
56
  frameborder: "0",
60
57
  allowfullscreen: "",
61
58
  allowpaymentrequest: "",
@@ -64,30 +61,30 @@ const z = { class: "lakala-payment-container" }, A = ["src"], S = {
64
61
  }, null, 40, A),
65
62
  o.value ? (l(), s("div", S, [
66
63
  c("div", j, [
67
- u(E, {
64
+ u(x, {
68
65
  class: "loading-icon",
69
66
  size: 30
70
67
  }, {
71
- default: b(() => [
68
+ default: q(() => [
72
69
  u(C(N))
73
70
  ]),
74
71
  _: 1
75
72
  }),
76
- p[0] || (p[0] = c("div", { class: "loading-text" }, "正在加载支付页面...", -1))
73
+ f[0] || (f[0] = c("div", { class: "loading-text" }, "正在加载支付页面...", -1))
77
74
  ])
78
- ])) : v("", !0),
75
+ ])) : p("", !0),
79
76
  r.value ? (l(), s("div", D, [
80
- u(q, {
77
+ u(E, {
81
78
  title: r.value,
82
79
  type: "error",
83
80
  "show-icon": "",
84
81
  closable: !1
85
82
  }, null, 8, ["title"])
86
- ])) : v("", !0)
83
+ ])) : p("", !0)
87
84
  ]);
88
85
  };
89
86
  }
90
- }), W = /* @__PURE__ */ B(F, [["__scopeId", "data-v-d2febe1f"]]);
87
+ }), W = /* @__PURE__ */ B(F, [["__scopeId", "data-v-51042bda"]]);
91
88
  export {
92
89
  W as default
93
90
  };