@huyooo/ui 0.14.3 → 0.14.5

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.
@@ -6,9 +6,9 @@
6
6
  import { U as Ct } from "./index-D3Kp6R4z.js";
7
7
  /* empty css */
8
8
  /* empty css */
9
- import { f as B, g as Z } from "./apiClients-CkI47p36.js";
10
- import { ref as g, computed as A, onUnmounted as Ae, defineComponent as It, openBlock as l, createElementBlock as r, Fragment as Q, createVNode as u, unref as n, isRef as xt, withCtx as s, createElementVNode as a, toDisplayString as o, createBlock as q, createTextVNode as d, createCommentVNode as T, renderList as Ne, normalizeClass as Oe } from "vue";
11
- import { Message as S, Modal as We, Button as k, Popconfirm as ae, Tabs as Nt, TabPane as ne, Spin as me, Empty as Te, Progress as Ot, Tag as X, Tooltip as Wt } from "@arco-design/web-vue";
9
+ import { f as B, g as X } from "./apiClients-CkI47p36.js";
10
+ import { ref as g, computed as A, onUnmounted as Ae, defineComponent as It, openBlock as l, createElementBlock as u, Fragment as te, createVNode as r, unref as n, isRef as xt, withCtx as s, createElementVNode as a, toDisplayString as o, createBlock as q, createTextVNode as v, createCommentVNode as z, renderList as Ne, normalizeClass as Oe } from "vue";
11
+ import { Message as S, Modal as We, Button as k, Popconfirm as ae, Tabs as Nt, TabPane as ne, Spin as me, Empty as Te, Progress as Ot, Tag as Q, Tooltip as Wt } from "@arco-design/web-vue";
12
12
  import { u as Tt, b as zt, a as At } from "./useBillingStatusOptions-D5Ehwtbj.js";
13
13
  import { u as Et } from "./useAuthkitCreateAndUpdate-u-ceTc-m.js";
14
14
  import { C as fe } from "./CustomTable-BT-cnhLR.js";
@@ -26,7 +26,7 @@ function ze() {
26
26
  };
27
27
  }
28
28
  function $t() {
29
- const v = g(ze()), _ = g(!1), p = A(() => v.value.current), h = A(() => v.value.trial), P = A(() => v.value.entitlement), x = A(() => v.value.features), y = A(() => v.value.quotas), f = A(() => v.value.pointsBalance), R = A(() => v.value.pendingInvoice);
29
+ const p = g(ze()), _ = g(!1), d = A(() => p.value.current), h = A(() => p.value.trial), P = A(() => p.value.entitlement), x = A(() => p.value.features), y = A(() => p.value.quotas), f = A(() => p.value.pointsBalance), R = A(() => p.value.pendingInvoice);
30
30
  async function E() {
31
31
  _.value = !0;
32
32
  try {
@@ -36,14 +36,14 @@ function $t() {
36
36
  } = await B.subscriptions.summary.post();
37
37
  if (C)
38
38
  throw new Error(C.message || "获取订阅摘要失败");
39
- v.value = b || ze();
39
+ p.value = b || ze();
40
40
  } finally {
41
41
  _.value = !1;
42
42
  }
43
43
  }
44
44
  return {
45
- summary: v,
46
- current: p,
45
+ summary: p,
46
+ current: d,
47
47
  trial: h,
48
48
  entitlement: P,
49
49
  features: x,
@@ -54,29 +54,29 @@ function $t() {
54
54
  refresh: E
55
55
  };
56
56
  }
57
- function Ut(v) {
58
- return /^https?:\/\//i.test(v) || v.startsWith("//");
57
+ function Ut(p) {
58
+ return /^https?:\/\//i.test(p) || p.startsWith("//");
59
59
  }
60
60
  function Bt() {
61
- if (Z.openPricing) {
62
- Z.openPricing();
61
+ if (X.openPricing) {
62
+ X.openPricing();
63
63
  return;
64
64
  }
65
- const v = Z.pricingUrl || "/Pricing";
66
- if (Ut(v)) {
67
- window.open(v, "_blank", "noopener,noreferrer");
65
+ const p = X.pricingUrl || "/Pricing";
66
+ if (Ut(p)) {
67
+ window.open(p, "_blank", "noopener,noreferrer");
68
68
  return;
69
69
  }
70
- window.location.assign(v);
70
+ window.location.assign(p);
71
71
  }
72
- async function K(v, _ = {}) {
73
- const p = localStorage.getItem("jwtToken"), h = await fetch(`${Z.billingPrefixUrl}${v}`, {
72
+ async function K(p, _ = {}) {
73
+ const d = localStorage.getItem("jwtToken"), h = await fetch(`${X.billingPrefixUrl}${p}`, {
74
74
  method: "POST",
75
75
  headers: {
76
76
  "Content-Type": "application/json",
77
- "app-id": Z.appId,
78
- ...p ? {
79
- authorization: `Bearer ${p}`
77
+ "app-id": X.appId,
78
+ ...d ? {
79
+ authorization: `Bearer ${d}`
80
80
  } : {}
81
81
  },
82
82
  body: JSON.stringify(_)
@@ -85,26 +85,26 @@ async function K(v, _ = {}) {
85
85
  throw new Error((P == null ? void 0 : P.message) || "请求失败");
86
86
  return P;
87
87
  }
88
- async function Ht(v, _) {
89
- if (v === "recharge") {
90
- const p = await K("/pointsRecharge/verifyPayment", {
88
+ async function Ht(p, _) {
89
+ if (p === "recharge") {
90
+ const d = await K("/pointsRecharge/verifyPayment", {
91
91
  orderId: _
92
92
  });
93
93
  return {
94
- success: !!(p.success || p.status === "paid"),
95
- status: p.status || "unknown",
96
- message: p.message,
97
- pointsAdded: p.pointsAdded
94
+ success: !!(d.success || d.status === "paid"),
95
+ status: d.status || "unknown",
96
+ message: d.message,
97
+ pointsAdded: d.pointsAdded
98
98
  };
99
99
  }
100
- if (v === "subscription") {
101
- const p = await K("/invoices/verifyPayment", {
100
+ if (p === "subscription") {
101
+ const d = await K("/invoices/verifyPayment", {
102
102
  orderId: _
103
103
  });
104
104
  return {
105
- success: !!(p.success || p.status === "paid"),
106
- status: p.status || "unknown",
107
- message: p.message
105
+ success: !!(d.success || d.status === "paid"),
106
+ status: d.status || "unknown",
107
+ message: d.message
108
108
  };
109
109
  }
110
110
  return {
@@ -115,17 +115,17 @@ async function Ht(v, _) {
115
115
  }
116
116
  const Dt = 3e3;
117
117
  function Ee() {
118
- const v = g(!1), _ = g("");
119
- let p = null;
118
+ const p = g(!1), _ = g("");
119
+ let d = null;
120
120
  function h() {
121
- p && (clearInterval(p), p = null);
121
+ d && (clearInterval(d), d = null);
122
122
  }
123
123
  async function P(y, f) {
124
- v.value = !0;
124
+ p.value = !0;
125
125
  try {
126
126
  return await Ht(y, f);
127
127
  } finally {
128
- v.value = !1;
128
+ p.value = !1;
129
129
  }
130
130
  }
131
131
  function x(y) {
@@ -143,20 +143,20 @@ function Ee() {
143
143
  h(), (E = y.onError) == null || E.call(y, b);
144
144
  }
145
145
  };
146
- f(), p = setInterval(() => {
146
+ f(), d = setInterval(() => {
147
147
  f();
148
148
  }, Dt);
149
149
  }
150
150
  return Ae(h), {
151
- checking: v,
151
+ checking: p,
152
152
  statusText: _,
153
153
  startPolling: x,
154
154
  stopPolling: h,
155
155
  verifyNow: P
156
156
  };
157
157
  }
158
- function mn(v) {
159
- const _ = g("loading"), p = g("正在确认支付结果..."), {
158
+ function fn(p) {
159
+ const _ = g("loading"), d = g("正在确认支付结果..."), {
160
160
  checking: h,
161
161
  statusText: P,
162
162
  startPolling: x,
@@ -164,25 +164,25 @@ function mn(v) {
164
164
  verifyNow: f
165
165
  } = Ee();
166
166
  async function R(E, b) {
167
- _.value = "loading", p.value = "正在确认支付结果...", x({
167
+ _.value = "loading", d.value = "正在确认支付结果...", x({
168
168
  scene: E,
169
169
  orderId: b,
170
170
  onSuccess: (C) => {
171
- _.value = "success", p.value = C.message || "支付成功", window.setTimeout(() => {
172
- window.location.replace(v());
171
+ _.value = "success", d.value = C.message || "支付成功", window.setTimeout(() => {
172
+ window.location.replace(p());
173
173
  }, 1200);
174
174
  },
175
175
  onWaiting: (C) => {
176
- p.value = C.message || P.value || "等待支付确认...";
176
+ d.value = C.message || P.value || "等待支付确认...";
177
177
  },
178
178
  onError: (C) => {
179
- _.value = "failed", p.value = C instanceof Error ? C.message : "确认支付失败", S.error(p.value);
179
+ _.value = "failed", d.value = C instanceof Error ? C.message : "确认支付失败", S.error(d.value);
180
180
  }
181
181
  });
182
182
  }
183
183
  return {
184
184
  phase: _,
185
- message: p,
185
+ message: d,
186
186
  checking: h,
187
187
  statusText: P,
188
188
  confirmPayment: R,
@@ -307,38 +307,40 @@ const Yt = {
307
307
  }, $a = {
308
308
  class: "points-package-meta"
309
309
  }, Ua = {
310
- class: "points-pay-row"
310
+ class: "points-package-extra"
311
311
  }, Ba = {
312
- key: 0
312
+ class: "points-pay-row"
313
313
  }, Ha = {
314
- key: 1
314
+ key: 0
315
315
  }, Da = {
316
316
  key: 1
317
317
  }, Ya = {
318
+ key: 1
319
+ }, Ma = {
318
320
  key: 0,
319
321
  class: "invoice-actions"
320
- }, Ma = {
321
- key: 1
322
322
  }, Fa = {
323
- class: "points-money-cell"
323
+ key: 1
324
324
  }, Va = {
325
- class: "payment-wait-content"
325
+ class: "points-money-cell"
326
326
  }, ja = {
327
- class: "payment-wait-summary"
327
+ class: "payment-wait-content"
328
328
  }, qa = {
329
- class: "payment-wait-icon"
329
+ class: "payment-wait-summary"
330
330
  }, Ka = {
331
- class: "payment-wait-tip"
331
+ class: "payment-wait-icon"
332
332
  }, Ja = {
333
+ class: "payment-wait-tip"
334
+ }, Ga = {
333
335
  class: "payment-wait-actions"
334
- }, Ga = /* @__PURE__ */ It({
336
+ }, Qa = /* @__PURE__ */ It({
335
337
  __name: "PaySubscriptions",
336
338
  emits: ["confirm", "cancel"],
337
- setup(v, {
339
+ setup(p, {
338
340
  expose: _,
339
- emit: p
341
+ emit: d
340
342
  }) {
341
- const h = p, {
343
+ const h = d, {
342
344
  changeType: P,
343
345
  show: x
344
346
  } = Et(h), y = g("overview"), {
@@ -355,7 +357,7 @@ const Yt = {
355
357
  total: 0
356
358
  }), M = g([]), $ = g(""), re = g(!1), ue = g(!1), F = g(!1), O = g(null), {
357
359
  checking: Le,
358
- statusText: z,
360
+ statusText: T,
359
361
  startPolling: Re,
360
362
  stopPolling: ce,
361
363
  verifyNow: $e
@@ -367,7 +369,7 @@ const Yt = {
367
369
  current: 1,
368
370
  pageSize: 10,
369
371
  total: 0
370
- }), ee = A(() => M.value.find((e) => e.id === $.value)), Ue = A(() => ge.value), Be = [{
372
+ }), Z = A(() => M.value.find((e) => e.id === $.value)), Ue = A(() => ge.value), Be = [{
371
373
  dataIndex: "id",
372
374
  slotName: "id",
373
375
  title: "账单 ID",
@@ -696,7 +698,7 @@ const Yt = {
696
698
  async function lt() {
697
699
  var e;
698
700
  if ($.value) {
699
- ue.value = !0, O.value = null, z.value = "";
701
+ ue.value = !0, O.value = null, T.value = "";
700
702
  try {
701
703
  const t = await K("/pointsRecharge/createOrder", {
702
704
  packageId: $.value,
@@ -704,7 +706,7 @@ const Yt = {
704
706
  });
705
707
  t.alipayUrl ? (O.value = {
706
708
  orderId: t.orderId,
707
- packageName: ((e = ee.value) == null ? void 0 : e.name) || "积分充值",
709
+ packageName: ((e = Z.value) == null ? void 0 : e.name) || "积分充值",
708
710
  priceYuan: t.priceYuan,
709
711
  totalPoints: t.totalPoints
710
712
  }, window.open(t.alipayUrl, "_blank", "noopener,noreferrer"), F.value = !0, rt(t.orderId), await U()) : S.error("获取支付链接失败");
@@ -716,19 +718,19 @@ const Yt = {
716
718
  }
717
719
  }
718
720
  function rt(e) {
719
- z.value = "等待支付确认...", Re({
721
+ T.value = "等待支付确认...", Re({
720
722
  scene: "recharge",
721
723
  orderId: e,
722
724
  onSuccess: async (t) => {
723
725
  var w;
724
726
  const m = t.pointsAdded || ((w = O.value) == null ? void 0 : w.totalPoints) || 0;
725
- F.value = !1, O.value = null, z.value = "", S.success(`充值成功,已到账 ${I(m)} 积分`), await L(), await U(), await J();
727
+ F.value = !1, O.value = null, T.value = "", S.success(`充值成功,已到账 ${I(m)} 积分`), await L(), await U(), await J();
726
728
  },
727
729
  onWaiting: (t) => {
728
- z.value = t.message || "等待支付确认...";
730
+ T.value = t.message || "等待支付确认...";
729
731
  },
730
732
  onError: (t) => {
731
- z.value = t instanceof Error ? t.message : "查询支付状态失败";
733
+ T.value = t instanceof Error ? t.message : "查询支付状态失败";
732
734
  }
733
735
  });
734
736
  }
@@ -739,16 +741,16 @@ const Yt = {
739
741
  const m = await $e("recharge", O.value.orderId);
740
742
  if (m.success) {
741
743
  const w = m.pointsAdded || ((t = O.value) == null ? void 0 : t.totalPoints) || 0;
742
- ce(), F.value = !1, O.value = null, z.value = "", S.success(`充值成功,已到账 ${I(w)} 积分`), await L(), await U(), await J();
744
+ ce(), F.value = !1, O.value = null, T.value = "", S.success(`充值成功,已到账 ${I(w)} 积分`), await L(), await U(), await J();
743
745
  return;
744
746
  }
745
- z.value = m.message || "等待支付确认...";
747
+ T.value = m.message || "等待支付确认...";
746
748
  } catch (m) {
747
- z.value = m instanceof Error ? m.message : "查询支付状态失败";
749
+ T.value = m instanceof Error ? m.message : "查询支付状态失败";
748
750
  }
749
751
  }
750
752
  function xe() {
751
- ce(), F.value = !1, O.value = null, z.value = "", U();
753
+ ce(), F.value = !1, O.value = null, T.value = "", U();
752
754
  }
753
755
  async function ct(e) {
754
756
  const {
@@ -855,7 +857,7 @@ const Yt = {
855
857
  ce();
856
858
  }), _({
857
859
  setData: St
858
- }), (e, t) => (l(), r(Q, null, [u(n(We), {
860
+ }), (e, t) => (l(), u(te, null, [r(n(We), {
859
861
  visible: n(x),
860
862
  "onUpdate:visible": t[1] || (t[1] = (m) => xt(x) ? x.value = m : null),
861
863
  loading: !1,
@@ -866,16 +868,16 @@ const Yt = {
866
868
  "unmount-on-close": "",
867
869
  onCancel: at
868
870
  }, {
869
- title: s(() => [...t[3] || (t[3] = [d(" 订阅与积分 ", -1)])]),
871
+ title: s(() => [...t[3] || (t[3] = [v(" 订阅与积分 ", -1)])]),
870
872
  default: s(() => {
871
873
  var m, w, G;
872
- return [a("div", Yt, [N.value ? (l(), r("div", Mt, [a("div", Ft, [a("div", Vt, [a("h3", null, o(N.value.productName), 1)]), a("div", jt, [N.value.type === "trial" ? (l(), q(n(k), {
874
+ return [a("div", Yt, [N.value ? (l(), u("div", Mt, [a("div", Ft, [a("div", Vt, [a("h3", null, o(N.value.productName), 1)]), a("div", jt, [N.value.type === "trial" ? (l(), q(n(k), {
873
875
  key: 0,
874
876
  type: "primary",
875
877
  size: "small",
876
878
  onClick: ve
877
879
  }, {
878
- default: s(() => [...t[4] || (t[4] = [d(" 立即订阅 ", -1)])]),
880
+ default: s(() => [...t[4] || (t[4] = [v(" 立即订阅 ", -1)])]),
879
881
  _: 1
880
882
  })) : (m = n(f)) != null && m.cancelAtPeriodEnd ? (l(), q(n(k), {
881
883
  key: 1,
@@ -883,97 +885,97 @@ const Yt = {
883
885
  size: "small",
884
886
  onClick: ft
885
887
  }, {
886
- default: s(() => [...t[5] || (t[5] = [d(" 恢复订阅 ", -1)])]),
888
+ default: s(() => [...t[5] || (t[5] = [v(" 恢复订阅 ", -1)])]),
887
889
  _: 1
888
- })) : n(f) ? (l(), r(Q, {
890
+ })) : n(f) ? (l(), u(te, {
889
891
  key: 2
890
- }, [u(n(k), {
892
+ }, [r(n(k), {
891
893
  type: "primary",
892
894
  size: "small",
893
895
  onClick: ve
894
896
  }, {
895
- default: s(() => [...t[6] || (t[6] = [d(" 修改订阅 ", -1)])]),
897
+ default: s(() => [...t[6] || (t[6] = [v(" 修改订阅 ", -1)])]),
896
898
  _: 1
897
- }), u(n(ae), {
899
+ }), r(n(ae), {
898
900
  content: "取消后订阅将在当前周期结束时失效,确定取消吗?",
899
901
  onOk: mt
900
902
  }, {
901
- default: s(() => [u(n(k), {
903
+ default: s(() => [r(n(k), {
902
904
  type: "outline",
903
905
  size: "small",
904
906
  status: "warning"
905
907
  }, {
906
- default: s(() => [...t[7] || (t[7] = [d(" 取消订阅 ", -1)])]),
908
+ default: s(() => [...t[7] || (t[7] = [v(" 取消订阅 ", -1)])]),
907
909
  _: 1
908
910
  })]),
909
911
  _: 1
910
- })], 64)) : T("", !0)])]), a("div", qt, [n(f) ? (l(), r("div", Kt, [t[8] || (t[8] = a("span", {
912
+ })], 64)) : z("", !0)])]), a("div", qt, [n(f) ? (l(), u("div", Kt, [t[8] || (t[8] = a("span", {
911
913
  class: "label"
912
- }, "价格方案:", -1)), a("span", null, o(N.value.productName), 1)])) : T("", !0), n(f) ? (l(), r("div", Jt, [t[9] || (t[9] = a("span", {
914
+ }, "价格方案:", -1)), a("span", null, o(N.value.productName), 1)])) : z("", !0), n(f) ? (l(), u("div", Jt, [t[9] || (t[9] = a("span", {
913
915
  class: "label"
914
- }, "计费周期:", -1)), a("span", null, o(Se(n(f).interval, n(f).intervalCount)), 1)])) : T("", !0), n(f) ? (l(), r("div", Gt, [t[10] || (t[10] = a("span", {
916
+ }, "计费周期:", -1)), a("span", null, o(Se(n(f).interval, n(f).intervalCount)), 1)])) : z("", !0), n(f) ? (l(), u("div", Gt, [t[10] || (t[10] = a("span", {
915
917
  class: "label"
916
- }, "价格:", -1)), a("span", null, o(Je(n(f).unitAmount, n(f).interval, n(f).intervalCount)), 1)])) : T("", !0), N.value.endAt ? (l(), r("div", Qt, [a("span", Xt, o(N.value.type === "trial" ? "试用有效期至:" : "当前周期结束:"), 1), a("span", null, o(N.value.endAt), 1)])) : T("", !0), (w = n(f)) != null && w.cancelAtPeriodEnd ? (l(), r("div", Zt, [...t[11] || (t[11] = [a("span", {
918
+ }, "价格:", -1)), a("span", null, o(Je(n(f).unitAmount, n(f).interval, n(f).intervalCount)), 1)])) : z("", !0), N.value.endAt ? (l(), u("div", Qt, [a("span", Xt, o(N.value.type === "trial" ? "试用有效期至:" : "当前周期结束:"), 1), a("span", null, o(N.value.endAt), 1)])) : z("", !0), (w = n(f)) != null && w.cancelAtPeriodEnd ? (l(), u("div", Zt, [...t[11] || (t[11] = [a("span", {
917
919
  class: "label"
918
- }, "订阅将于周期结束后停止", -1)])])) : (G = n(f)) != null && G.pendingChange ? (l(), r("div", ea, [t[12] || (t[12] = a("span", {
920
+ }, "订阅将于周期结束后停止", -1)])])) : (G = n(f)) != null && G.pendingChange ? (l(), u("div", ea, [t[12] || (t[12] = a("span", {
919
921
  class: "label"
920
- }, "到期后变更为:", -1)), a("span", null, o(n(f).pendingChange.productName || "新方案"), 1)])) : T("", !0), n(b) ? (l(), r("div", ta, [t[13] || (t[13] = a("span", {
922
+ }, "到期后变更为:", -1)), a("span", null, o(n(f).pendingChange.productName || "新方案"), 1)])) : z("", !0), n(b) ? (l(), u("div", ta, [t[13] || (t[13] = a("span", {
921
923
  class: "label"
922
- }, "积分余额:", -1)), a("span", null, o(n(b).totalPoints), 1)])) : T("", !0)]), n(C) ? (l(), r("div", aa, [t[15] || (t[15] = a("div", null, [a("strong", null, "存在待支付订阅账单"), a("span", null, "可继续支付,也可取消后重新选择方案。")], -1)), u(n(k), {
924
+ }, "积分余额:", -1)), a("span", null, o(n(b).totalPoints), 1)])) : z("", !0)]), n(C) ? (l(), u("div", aa, [t[15] || (t[15] = a("div", null, [a("strong", null, "存在待支付订阅账单"), a("span", null, "可继续支付,也可取消后重新选择方案。")], -1)), r(n(k), {
923
925
  type: "primary",
924
926
  status: "warning",
925
927
  size: "small",
926
928
  onClick: nt
927
929
  }, {
928
- default: s(() => [...t[14] || (t[14] = [d(" 处理 ", -1)])]),
930
+ default: s(() => [...t[14] || (t[14] = [v(" 处理 ", -1)])]),
929
931
  _: 1
930
- })])) : T("", !0)])) : (l(), r("div", na, [t[17] || (t[17] = a("span", {
932
+ })])) : z("", !0)])) : (l(), u("div", na, [t[17] || (t[17] = a("span", {
931
933
  class: "no-subscription-text"
932
- }, "暂无方案", -1)), u(n(k), {
934
+ }, "暂无方案", -1)), r(n(k), {
933
935
  type: "primary",
934
936
  size: "small",
935
937
  onClick: ve
936
938
  }, {
937
- default: s(() => [...t[16] || (t[16] = [d("查看价格方案", -1)])]),
939
+ default: s(() => [...t[16] || (t[16] = [v("查看价格方案", -1)])]),
938
940
  _: 1
939
- })])), u(n(Nt), {
941
+ })])), r(n(Nt), {
940
942
  "active-key": y.value,
941
943
  "onUpdate:activeKey": t[0] || (t[0] = (i) => y.value = i),
942
944
  class: "subscription-tabs",
943
945
  onChange: Pt
944
946
  }, {
945
- default: s(() => [u(n(ne), {
947
+ default: s(() => [r(n(ne), {
946
948
  key: "overview",
947
949
  title: "概览"
948
950
  }, {
949
951
  default: s(() => {
950
- var i, c, te;
952
+ var i, c, ee;
951
953
  return [a("div", sa, [a("div", ia, [t[18] || (t[18] = a("div", {
952
954
  class: "overview-card__label"
953
- }, "当前权益", -1)), a("div", oa, o(((i = N.value) == null ? void 0 : i.productName) || "暂无方案"), 1), (c = N.value) != null && c.endAt ? (l(), r("div", la, o(N.value.type === "trial" ? "试用有效期至" : "当前周期结束") + ":" + o(N.value.endAt), 1)) : T("", !0)]), a("div", ra, [t[19] || (t[19] = a("div", {
955
+ }, "当前权益", -1)), a("div", oa, o(((i = N.value) == null ? void 0 : i.productName) || "暂无方案"), 1), (c = N.value) != null && c.endAt ? (l(), u("div", la, o(N.value.type === "trial" ? "试用有效期至" : "当前周期结束") + ":" + o(N.value.endAt), 1)) : z("", !0)]), a("div", ra, [t[19] || (t[19] = a("div", {
954
956
  class: "overview-card__label"
955
- }, "积分余额", -1)), a("div", ua, o(I(((te = n(b)) == null ? void 0 : te.totalPoints) || 0)), 1), t[20] || (t[20] = a("div", {
957
+ }, "积分余额", -1)), a("div", ua, o(I(((ee = n(b)) == null ? void 0 : ee.totalPoints) || 0)), 1), t[20] || (t[20] = a("div", {
956
958
  class: "overview-card__meta"
957
959
  }, "用于 AI 模型调用和按量服务消费", -1))]), a("div", ca, [t[21] || (t[21] = a("div", {
958
960
  class: "overview-card__label"
959
961
  }, "待支付订阅账单", -1)), a("div", da, o(n(C) ? `¥${(n(C).total / 100).toFixed(2)}` : "无"), 1), t[22] || (t[22] = a("div", {
960
962
  class: "overview-card__meta"
961
- }, "仅包含订阅方案产生的待支付账单", -1))])]), Ue.value ? (l(), r("div", pa, [u(n(me))])) : n(E).length === 0 ? (l(), r("div", va, [u(n(Te), {
963
+ }, "仅包含订阅方案产生的待支付账单", -1))])]), Ue.value ? (l(), u("div", pa, [r(n(me))])) : n(E).length === 0 ? (l(), u("div", va, [r(n(Te), {
962
964
  description: "暂无配额限制"
963
- })])) : (l(), r("div", ma, [(l(!0), r(Q, null, Ne(n(E), (W) => (l(), r("div", {
965
+ })])) : (l(), u("div", ma, [(l(!0), u(te, null, Ne(n(E), (W) => (l(), u("div", {
964
966
  key: W.featureKey,
965
967
  class: "quota-card"
966
- }, [a("div", fa, [a("span", ga, o(W.name), 1), a("span", ya, o(Ke(W.period)), 1)]), a("div", _a, [u(n(Ot), {
968
+ }, [a("div", fa, [a("span", ga, o(W.name), 1), a("span", ya, o(Ke(W.period)), 1)]), a("div", _a, [r(n(Ot), {
967
969
  percent: W.percentage,
968
970
  status: W.percentage >= 90 ? "danger" : W.percentage >= 70 ? "warning" : "normal"
969
- }, null, 8, ["percent", "status"])]), a("div", wa, [W.unlimited ? (l(), r("span", ba, "无限制")) : (l(), r("span", ha, "已使用 " + o(W.used) + " / " + o(W.limit), 1)), W.resetsAt ? (l(), r("span", ka, o(W.resetsAt) + " 重置", 1)) : T("", !0)])]))), 128))]))];
971
+ }, null, 8, ["percent", "status"])]), a("div", wa, [W.unlimited ? (l(), u("span", ba, "无限制")) : (l(), u("span", ha, "已使用 " + o(W.used) + " / " + o(W.limit), 1)), W.resetsAt ? (l(), u("span", ka, o(W.resetsAt) + " 重置", 1)) : z("", !0)])]))), 128))]))];
970
972
  }),
971
973
  _: 1
972
- }), u(n(ne), {
974
+ }), r(n(ne), {
973
975
  key: "invoices",
974
976
  title: "订阅账单"
975
977
  }, {
976
- default: s(() => [u(fe, {
978
+ default: s(() => [r(fe, {
977
979
  columns: Be,
978
980
  data: ye.value,
979
981
  loading: le.value,
@@ -986,73 +988,73 @@ const Yt = {
986
988
  }) => [a("span", {
987
989
  class: "copyable-id mono-value",
988
990
  title: i.id
989
- }, [a("span", null, o(i.id), 1), u(Lt, {
991
+ }, [a("span", null, o(i.id), 1), r(Lt, {
990
992
  value: i.id,
991
993
  message: "账单 ID 已复制"
992
994
  }, null, 8, ["value"])], 8, Pa)]),
993
995
  status: s(({
994
996
  record: i
995
- }) => [u(n(X), {
997
+ }) => [r(n(Q), {
996
998
  color: Ye(i.status)
997
999
  }, {
998
- default: s(() => [d(o(Me(i.status)), 1)]),
1000
+ default: s(() => [v(o(Me(i.status)), 1)]),
999
1001
  _: 2
1000
1002
  }, 1032, ["color"])]),
1001
1003
  billingType: s(({
1002
1004
  record: i
1003
- }) => [d(o(je(i.billingType)), 1)]),
1005
+ }) => [v(o(je(i.billingType)), 1)]),
1004
1006
  refund: s(({
1005
1007
  record: i
1006
- }) => [i.refund ? (l(), q(n(X), {
1008
+ }) => [i.refund ? (l(), q(n(Q), {
1007
1009
  key: 0,
1008
1010
  color: be(i.refund.status)
1009
1011
  }, {
1010
- default: s(() => [d(o(he(i.refund.status)), 1)]),
1012
+ default: s(() => [v(o(he(i.refund.status)), 1)]),
1011
1013
  _: 2
1012
- }, 1032, ["color"])) : (l(), r("span", Sa, "-"))]),
1014
+ }, 1032, ["color"])) : (l(), u("span", Sa, "-"))]),
1013
1015
  total: s(({
1014
1016
  record: i
1015
- }) => [d(" ¥" + o((i.total / 100).toFixed(2)), 1)]),
1017
+ }) => [v(" ¥" + o((i.total / 100).toFixed(2)), 1)]),
1016
1018
  actions: s(({
1017
1019
  record: i
1018
- }) => [i.status === "open" ? (l(), r("div", Ca, [u(n(k), {
1020
+ }) => [i.status === "open" ? (l(), u("div", Ca, [r(n(k), {
1019
1021
  type: "primary",
1020
1022
  status: "warning",
1021
1023
  size: "small",
1022
1024
  onClick: (c) => ct(i)
1023
1025
  }, {
1024
- default: s(() => [...t[23] || (t[23] = [d(" 去支付 ", -1)])]),
1026
+ default: s(() => [...t[23] || (t[23] = [v(" 去支付 ", -1)])]),
1025
1027
  _: 1
1026
- }, 8, ["onClick"]), u(n(ae), {
1028
+ }, 8, ["onClick"]), r(n(ae), {
1027
1029
  content: "取消后可重新发起支付,订阅方案不会变更。确定取消吗?",
1028
1030
  onOk: (c) => dt(i)
1029
1031
  }, {
1030
- default: s(() => [u(n(k), {
1032
+ default: s(() => [r(n(k), {
1031
1033
  type: "secondary",
1032
1034
  status: "warning",
1033
1035
  size: "small"
1034
1036
  }, {
1035
- default: s(() => [...t[24] || (t[24] = [d("取消支付", -1)])]),
1037
+ default: s(() => [...t[24] || (t[24] = [v("取消支付", -1)])]),
1036
1038
  _: 1
1037
1039
  })]),
1038
1040
  _: 1
1039
- }, 8, ["onOk"])])) : i.status === "paid" && !i.refund ? (l(), r("div", Ia, [u(n(ae), {
1041
+ }, 8, ["onOk"])])) : i.status === "paid" && !i.refund ? (l(), u("div", Ia, [r(n(ae), {
1040
1042
  content: "提交后将进入人工审核,审核通过后原路退款。确定申请退款吗?",
1041
1043
  onOk: (c) => pt(i)
1042
1044
  }, {
1043
- default: s(() => [u(n(k), {
1045
+ default: s(() => [r(n(k), {
1044
1046
  type: "secondary",
1045
1047
  size: "small"
1046
1048
  }, {
1047
- default: s(() => [...t[25] || (t[25] = [d(" 申请退款 ", -1)])]),
1049
+ default: s(() => [...t[25] || (t[25] = [v(" 申请退款 ", -1)])]),
1048
1050
  _: 1
1049
1051
  })]),
1050
1052
  _: 1
1051
- }, 8, ["onOk"])])) : (l(), r("span", xa, "-"))]),
1053
+ }, 8, ["onOk"])])) : (l(), u("span", xa, "-"))]),
1052
1054
  _: 1
1053
1055
  }, 8, ["data", "loading", "pagination"])]),
1054
1056
  _: 1
1055
- }), u(n(ne), {
1057
+ }), r(n(ne), {
1056
1058
  key: "points",
1057
1059
  title: "积分账户"
1058
1060
  }, {
@@ -1062,36 +1064,34 @@ const Yt = {
1062
1064
  class: "points-balance-label"
1063
1065
  }, "当前积分余额", -1)), a("div", Wa, o(I(((i = n(b)) == null ? void 0 : i.totalPoints) || 0)), 1), t[27] || (t[27] = a("div", {
1064
1066
  class: "points-balance-tip"
1065
- }, "充值后实时到账。退款需账户积分不少于该单充值积分。", -1))]), u(n(k), {
1067
+ }, "充值后实时到账。退款需账户积分不少于该单充值积分。", -1))]), r(n(k), {
1066
1068
  loading: n(ge),
1067
1069
  onClick: n(L)
1068
1070
  }, {
1069
- default: s(() => [...t[28] || (t[28] = [d("刷新余额", -1)])]),
1071
+ default: s(() => [...t[28] || (t[28] = [v("刷新余额", -1)])]),
1070
1072
  _: 1
1071
1073
  }, 8, ["loading", "onClick"])]), t[32] || (t[32] = a("div", {
1072
1074
  class: "points-section-header"
1073
- }, [a("h4", null, "充值套餐")], -1)), re.value ? (l(), r("div", Ta, [u(n(me))])) : M.value.length === 0 ? (l(), r("div", za, [u(n(Te), {
1075
+ }, [a("h4", null, "充值套餐")], -1)), re.value ? (l(), u("div", Ta, [r(n(me))])) : M.value.length === 0 ? (l(), u("div", za, [r(n(Te), {
1074
1076
  description: "暂无充值套餐"
1075
- })])) : (l(), r("div", Aa, [(l(!0), r(Q, null, Ne(M.value, (c) => (l(), r("button", {
1077
+ })])) : (l(), u("div", Aa, [(l(!0), u(te, null, Ne(M.value, (c) => (l(), u("button", {
1076
1078
  key: c.id,
1077
1079
  type: "button",
1078
1080
  class: Oe(["points-package", {
1079
1081
  "points-package--selected": $.value === c.id
1080
1082
  }]),
1081
- onClick: (te) => $.value = c.id
1082
- }, [a("span", La, o(c.name), 1), a("span", Ra, o(I(c.totalPoints)) + " 积分", 1), a("span", $a, [d(" ¥" + o(c.priceYuan) + " ", 1), c.bonus > 0 ? (l(), r(Q, {
1083
- key: 0
1084
- }, [d(" · 赠送 " + o(I(c.bonus)), 1)], 64)) : T("", !0)])], 10, Ea))), 128))])), a("div", Ua, [ee.value ? (l(), r("span", Ba, " 应付 ¥" + o(ee.value.priceYuan) + ",获得 " + o(I(ee.value.totalPoints)) + " 积分 ", 1)) : (l(), r("span", Ha, "请选择充值套餐")), u(n(k), {
1083
+ onClick: (ee) => $.value = c.id
1084
+ }, [a("span", La, o(c.name), 1), a("span", Ra, o(I(c.totalPoints)) + " 积分", 1), a("span", $a, "¥" + o(c.priceYuan), 1), a("span", Ua, " 基础 " + o(I(c.points)) + " · 赠送 " + o(I(c.bonus)), 1)], 10, Ea))), 128))])), a("div", Ba, [Z.value ? (l(), u("span", Ha, " 应付 ¥" + o(Z.value.priceYuan) + ",获得 " + o(I(Z.value.totalPoints)) + " 积分 ", 1)) : (l(), u("span", Da, "请选择充值套餐")), r(n(k), {
1085
1085
  type: "primary",
1086
1086
  loading: ue.value,
1087
1087
  disabled: !$.value,
1088
1088
  onClick: lt
1089
1089
  }, {
1090
- default: s(() => [...t[29] || (t[29] = [d(" 立即充值 ", -1)])]),
1090
+ default: s(() => [...t[29] || (t[29] = [v(" 立即充值 ", -1)])]),
1091
1091
  _: 1
1092
1092
  }, 8, ["loading", "disabled"])]), t[33] || (t[33] = a("div", {
1093
1093
  class: "points-section-header"
1094
- }, [a("h4", null, "充值记录")], -1)), u(fe, {
1094
+ }, [a("h4", null, "充值记录")], -1)), r(fe, {
1095
1095
  columns: He,
1096
1096
  data: _e.value,
1097
1097
  loading: de.value,
@@ -1101,39 +1101,39 @@ const Yt = {
1101
1101
  }, {
1102
1102
  price: s(({
1103
1103
  record: c
1104
- }) => [d(" ¥" + o(c.priceYuan), 1)]),
1104
+ }) => [v(" ¥" + o(c.priceYuan), 1)]),
1105
1105
  points: s(({
1106
1106
  record: c
1107
- }) => [d(o(I(c.totalPoints)), 1)]),
1107
+ }) => [v(o(I(c.totalPoints)), 1)]),
1108
1108
  status: s(({
1109
1109
  record: c
1110
- }) => [u(n(X), {
1110
+ }) => [r(n(Q), {
1111
1111
  color: Fe(c.status)
1112
1112
  }, {
1113
- default: s(() => [d(o(Ve(c.status)), 1)]),
1113
+ default: s(() => [v(o(Ve(c.status)), 1)]),
1114
1114
  _: 2
1115
1115
  }, 1032, ["color"])]),
1116
1116
  refund: s(({
1117
1117
  record: c
1118
- }) => [c.refund ? (l(), q(n(X), {
1118
+ }) => [c.refund ? (l(), q(n(Q), {
1119
1119
  key: 0,
1120
1120
  color: be(c.refund.status)
1121
1121
  }, {
1122
- default: s(() => [d(o(he(c.refund.status)), 1)]),
1122
+ default: s(() => [v(o(he(c.refund.status)), 1)]),
1123
1123
  _: 2
1124
- }, 1032, ["color"])) : (l(), r("span", Da, "-"))]),
1124
+ }, 1032, ["color"])) : (l(), u("span", Ya, "-"))]),
1125
1125
  actions: s(({
1126
1126
  record: c
1127
- }) => [c.status === "paid" && !c.refund ? (l(), r("div", Ya, [Pe(c) ? (l(), q(n(ae), {
1127
+ }) => [c.status === "paid" && !c.refund ? (l(), u("div", Ma, [Pe(c) ? (l(), q(n(ae), {
1128
1128
  key: 0,
1129
1129
  content: qe(c),
1130
- onOk: (te) => vt(c)
1130
+ onOk: (ee) => vt(c)
1131
1131
  }, {
1132
- default: s(() => [u(n(k), {
1132
+ default: s(() => [r(n(k), {
1133
1133
  type: "secondary",
1134
1134
  size: "small"
1135
1135
  }, {
1136
- default: s(() => [...t[30] || (t[30] = [d(" 申请退款 ", -1)])]),
1136
+ default: s(() => [...t[30] || (t[30] = [v(" 申请退款 ", -1)])]),
1137
1137
  _: 1
1138
1138
  })]),
1139
1139
  _: 1
@@ -1141,25 +1141,25 @@ const Yt = {
1141
1141
  key: 1,
1142
1142
  content: "账户积分不足,无法退款"
1143
1143
  }, {
1144
- default: s(() => [u(n(k), {
1144
+ default: s(() => [r(n(k), {
1145
1145
  type: "secondary",
1146
1146
  size: "small",
1147
1147
  disabled: ""
1148
1148
  }, {
1149
- default: s(() => [...t[31] || (t[31] = [d(" 积分不足 ", -1)])]),
1149
+ default: s(() => [...t[31] || (t[31] = [v(" 积分不足 ", -1)])]),
1150
1150
  _: 1
1151
1151
  })]),
1152
1152
  _: 1
1153
- }))])) : (l(), r("span", Ma, "-"))]),
1153
+ }))])) : (l(), u("span", Fa, "-"))]),
1154
1154
  _: 1
1155
1155
  }, 8, ["data", "loading", "pagination"])])];
1156
1156
  }),
1157
1157
  _: 1
1158
- }), u(n(ne), {
1158
+ }), r(n(ne), {
1159
1159
  key: "usage",
1160
1160
  title: "积分流水"
1161
1161
  }, {
1162
- default: s(() => [u(fe, {
1162
+ default: s(() => [r(fe, {
1163
1163
  columns: De,
1164
1164
  data: we.value,
1165
1165
  loading: pe.value,
@@ -1169,10 +1169,10 @@ const Yt = {
1169
1169
  }, {
1170
1170
  type: s(({
1171
1171
  record: i
1172
- }) => [u(n(X), {
1172
+ }) => [r(n(Q), {
1173
1173
  color: Xe(i.type)
1174
1174
  }, {
1175
- default: s(() => [d(o(Ze(i.type)), 1)]),
1175
+ default: s(() => [v(o(Ze(i.type)), 1)]),
1176
1176
  _: 2
1177
1177
  }, 1032, ["color"])]),
1178
1178
  amount: s(({
@@ -1182,16 +1182,16 @@ const Yt = {
1182
1182
  }, [a("span", null, o(Ce(i.amount, !0)), 1), a("small", null, o(i.amount >= 0 ? "+" : "") + o(I(i.amount)) + " 积分", 1)], 2)]),
1183
1183
  balance: s(({
1184
1184
  record: i
1185
- }) => [a("div", Fa, [a("span", null, o(Ce(i.balance)), 1), a("small", null, o(Ge(i.balance)) + " 积分", 1)])]),
1185
+ }) => [a("div", Va, [a("span", null, o(Ce(i.balance)), 1), a("small", null, o(Ge(i.balance)) + " 积分", 1)])]),
1186
1186
  exchangeRate: s(({
1187
1187
  record: i
1188
- }) => [d(o(Qe(i)), 1)]),
1188
+ }) => [v(o(Qe(i)), 1)]),
1189
1189
  description: s(({
1190
1190
  record: i
1191
- }) => [d(o(i.description || "-"), 1)]),
1191
+ }) => [v(o(i.description || "-"), 1)]),
1192
1192
  service: s(({
1193
1193
  record: i
1194
- }) => [d(o(tt(i)), 1)]),
1194
+ }) => [v(o(tt(i)), 1)]),
1195
1195
  _: 1
1196
1196
  }, 8, ["data", "loading", "pagination"])]),
1197
1197
  _: 1
@@ -1200,7 +1200,7 @@ const Yt = {
1200
1200
  }, 8, ["active-key"])])];
1201
1201
  }),
1202
1202
  _: 1
1203
- }, 8, ["visible", "width"]), u(n(We), {
1203
+ }, 8, ["visible", "width"]), r(n(We), {
1204
1204
  visible: F.value,
1205
1205
  "onUpdate:visible": t[2] || (t[2] = (m) => F.value = m),
1206
1206
  title: "等待支付完成",
@@ -1211,30 +1211,30 @@ const Yt = {
1211
1211
  }, {
1212
1212
  default: s(() => {
1213
1213
  var m, w;
1214
- return [a("div", Va, [a("div", ja, [a("span", null, o(((m = O.value) == null ? void 0 : m.packageName) || "积分充值"), 1), a("strong", null, "¥" + o(((w = O.value) == null ? void 0 : w.priceYuan) || "0.00"), 1)]), a("div", qa, [u(n(me), {
1214
+ return [a("div", ja, [a("div", qa, [a("span", null, o(((m = O.value) == null ? void 0 : m.packageName) || "积分充值"), 1), a("strong", null, "¥" + o(((w = O.value) == null ? void 0 : w.priceYuan) || "0.00"), 1)]), a("div", Ka, [r(n(me), {
1215
1215
  size: 32
1216
- })]), a("div", Ka, [t[34] || (t[34] = a("span", null, "支付宝收银台已在浏览器打开", -1)), a("small", null, o(n(z) || "请在支付宝页面完成支付,支付成功后这里会自动刷新余额"), 1)]), a("div", Ja, [u(n(k), {
1216
+ })]), a("div", Ja, [t[34] || (t[34] = a("span", null, "支付宝收银台已在浏览器打开", -1)), a("small", null, o(n(T) || "请在支付宝页面完成支付,支付成功后这里会自动刷新余额"), 1)]), a("div", Ga, [r(n(k), {
1217
1217
  onClick: xe
1218
1218
  }, {
1219
- default: s(() => [...t[35] || (t[35] = [d("取消", -1)])]),
1219
+ default: s(() => [...t[35] || (t[35] = [v("取消", -1)])]),
1220
1220
  _: 1
1221
- }), u(n(k), {
1221
+ }), r(n(k), {
1222
1222
  type: "primary",
1223
1223
  loading: n(Le),
1224
1224
  onClick: ut
1225
1225
  }, {
1226
- default: s(() => [...t[36] || (t[36] = [d(" 我已完成支付 ", -1)])]),
1226
+ default: s(() => [...t[36] || (t[36] = [v(" 我已完成支付 ", -1)])]),
1227
1227
  _: 1
1228
1228
  }, 8, ["loading"])])])];
1229
1229
  }),
1230
1230
  _: 1
1231
1231
  }, 8, ["visible"])], 64));
1232
1232
  }
1233
- }), fn = /* @__PURE__ */ Rt(Ga, [["__scopeId", "data-v-59c72969"]]);
1233
+ }), gn = /* @__PURE__ */ Rt(Qa, [["__scopeId", "data-v-6a329ee9"]]);
1234
1234
  export {
1235
- fn as P,
1235
+ gn as P,
1236
1236
  Ee as a,
1237
- mn as b,
1237
+ fn as b,
1238
1238
  Bt as o,
1239
1239
  $t as u,
1240
1240
  Ht as v