mg-ocr-invoice 0.2.7 → 0.2.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/index.es.js CHANGED
@@ -4663,9 +4663,9 @@ const getToken = () => api.get("token"), __uploadInvoice = (n, r) => instance({
4663
4663
  case "invalid":
4664
4664
  return "error";
4665
4665
  case "unused":
4666
- return "warning";
4667
- case "using":
4668
4666
  return "ok";
4667
+ case "using":
4668
+ return "error";
4669
4669
  case "used":
4670
4670
  return "default";
4671
4671
  case "noNeed":
@@ -4678,8 +4678,6 @@ const getToken = () => api.get("token"), __uploadInvoice = (n, r) => instance({
4678
4678
  return "error";
4679
4679
  case "abnormal":
4680
4680
  return "error";
4681
- case "invalid":
4682
- return "error";
4683
4681
  default:
4684
4682
  return "ok";
4685
4683
  }
@@ -5800,7 +5798,7 @@ P[Symbol.toStringTag] = "Decimal";
5800
5798
  var Decimal = P.constructor = clone(DEFAULTS);
5801
5799
  LN10 = new Decimal(LN10);
5802
5800
  PI = new Decimal(PI);
5803
- const _withScopeId$2 = (n) => (pushScopeId("data-v-a355bbf7"), n = n(), popScopeId(), n), _hoisted_1$3 = { class: "Invoice" }, _hoisted_2$3 = { class: "top" }, _hoisted_3$3 = ["src", "onClick"], _hoisted_4$3 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", { class: "Field-title" }, [
5801
+ const _withScopeId$2 = (n) => (pushScopeId("data-v-85422d22"), n = n(), popScopeId(), n), _hoisted_1$3 = { class: "Invoice" }, _hoisted_2$3 = { class: "top" }, _hoisted_3$3 = ["src", "onClick"], _hoisted_4$3 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("div", { class: "Field-title" }, [
5804
5802
  /* @__PURE__ */ createElementVNode("span", { class: "titleLeft" }, "公司信息")
5805
5803
  ], -1)), _hoisted_5$2 = { class: "marPX" }, _hoisted_6$2 = { class: "marPX" }, _hoisted_7$2 = { class: "marPX" }, _hoisted_8$2 = { class: "marPX" }, _hoisted_9$1 = { style: { color: "#333", "font-weight": "400", "font-size": "16px", "margin-right": "12px" } }, _hoisted_10$1 = /* @__PURE__ */ _withScopeId$2(() => /* @__PURE__ */ createElementVNode("thead", null, [
5806
5804
  /* @__PURE__ */ createElementVNode("tr", null, [
@@ -5847,7 +5845,7 @@ const _withScopeId$2 = (n) => (pushScopeId("data-v-a355bbf7"), n = n(), popScope
5847
5845
  r("saveSuccess");
5848
5846
  }, v = () => {
5849
5847
  showImagePreview([o.invoiceData.attachmentLink]);
5850
- }, b = computed(() => o.invoiceData.realStatus === "noNeed" || o.invoiceData.invoiceExceptionInfo === "abnormal" || o.invoiceData.manualModify || o.invoiceData.rerealStatus === "checkFail"), _ = async () => {
5848
+ }, b = computed(() => o.invoiceData.realStatus === "noNeed" || o.invoiceData.invoiceExceptionInfo === "abnormal" || o.invoiceData.manualModify || o.invoiceData.realStatus === "checkFail" || o.invoiceData.realStatus === "notCheck"), _ = async () => {
5851
5849
  f.value = !0;
5852
5850
  try {
5853
5851
  (await __updateInvoiceData(a.value)).code === 200 && (showToast({
@@ -6221,12 +6219,12 @@ const _withScopeId$2 = (n) => (pushScopeId("data-v-a355bbf7"), n = n(), popScope
6221
6219
  }, 8, ["show"])
6222
6220
  ], 64));
6223
6221
  }
6224
- }), index_vue_vue_type_style_index_0_scoped_a355bbf7_lang = "", _export_sfc = (n, r) => {
6222
+ }), index_vue_vue_type_style_index_0_scoped_85422d22_lang = "", _export_sfc = (n, r) => {
6225
6223
  const o = n.__vccOpts || n;
6226
6224
  for (const [a, u] of r)
6227
6225
  o[a] = u;
6228
6226
  return o;
6229
- }, Invoice = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__scopeId", "data-v-a355bbf7"]]), index$2 = "";
6227
+ }, Invoice = /* @__PURE__ */ _export_sfc(_sfc_main$3, [["__scopeId", "data-v-85422d22"]]), index$2 = "";
6230
6228
  /*!
6231
6229
  * Compressor.js v1.2.1
6232
6230
  * https://fengyuanchen.github.io/compressorjs
@@ -6323,7 +6321,7 @@ const takePhoto = () => new Promise((n, r) => {
6323
6321
  }, a.oncancel = () => {
6324
6322
  document.body.removeChild(a);
6325
6323
  }, a.click();
6326
- }), _withScopeId$1 = (n) => (pushScopeId("data-v-d6802564"), n = n(), popScopeId(), n), _hoisted_1$2 = { class: "InvoiceList" }, _hoisted_2$2 = { class: "selectAll" }, _hoisted_3$2 = { class: "left" }, _hoisted_4$2 = { class: "right" }, _hoisted_5$1 = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ createElementVNode("span", null, "全选", -1)), _hoisted_6$1 = ["onChange"], _hoisted_7$1 = { class: "card" }, _hoisted_8$1 = ["onClick"], _hoisted_9 = { class: "li" }, _hoisted_10 = {
6324
+ }), _withScopeId$1 = (n) => (pushScopeId("data-v-845dc5ab"), n = n(), popScopeId(), n), _hoisted_1$2 = { class: "InvoiceList" }, _hoisted_2$2 = { class: "selectAll" }, _hoisted_3$2 = { class: "left" }, _hoisted_4$2 = { class: "right" }, _hoisted_5$1 = /* @__PURE__ */ _withScopeId$1(() => /* @__PURE__ */ createElementVNode("span", null, "全选", -1)), _hoisted_6$1 = ["onChange"], _hoisted_7$1 = { class: "card" }, _hoisted_8$1 = ["onClick"], _hoisted_9 = { class: "li" }, _hoisted_10 = {
6327
6325
  key: 0,
6328
6326
  class: "item-card"
6329
6327
  }, _hoisted_11 = ["onClick"], _hoisted_12 = { class: "storeName" }, _hoisted_13 = { class: "name" }, _hoisted_14 = { class: "left" }, _hoisted_15 = {
@@ -6377,6 +6375,8 @@ const takePhoto = () => new Promise((n, r) => {
6377
6375
  console.log(we), ae(we);
6378
6376
  }
6379
6377
  }), C = (X) => {
6378
+ if (console.log(X.invoiceStatus), X.invoiceStatus !== "unused")
6379
+ return showToast("发票已被使用!");
6380
6380
  X.selected = !X.selected;
6381
6381
  }, L = (X) => {
6382
6382
  r(
@@ -6389,7 +6389,7 @@ const takePhoto = () => new Promise((n, r) => {
6389
6389
  b.value
6390
6390
  );
6391
6391
  }, O = (X) => X.invoiceStatus === "unused" ? !!(X.manualModify || !X.invoiceExceptionInfo) : !1, k = ref(!1), I = (X) => {
6392
- b.value.forEach((ae) => {
6392
+ k.value && showToast("存在已使用或异常发票, 已自动过滤"), b.value.forEach((ae) => {
6393
6393
  ae.selected = O(ae) && k.value;
6394
6394
  });
6395
6395
  }, S = () => {
@@ -6645,7 +6645,7 @@ const takePhoto = () => new Promise((n, r) => {
6645
6645
  }, 8, ["show"])
6646
6646
  ], 64));
6647
6647
  }
6648
- }), index_vue_vue_type_style_index_0_scoped_d6802564_lang = "", InvoiceList = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__scopeId", "data-v-d6802564"]]), _withScopeId = (n) => (pushScopeId("data-v-87442ad9"), n = n(), popScopeId(), n), _hoisted_1$1 = { class: "PaymentMode" }, _hoisted_2$1 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("div", { class: "title" }, "选择识别方式", -1)), _hoisted_3$1 = { class: "list" }, _hoisted_4$1 = ["onClick"], _hoisted_5 = { class: "left-text" }, _hoisted_6 = { class: "icon-left" }, _hoisted_7 = { class: "text" }, _hoisted_8 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("div", { class: "right-icon" }, [
6648
+ }), index_vue_vue_type_style_index_0_scoped_845dc5ab_lang = "", InvoiceList = /* @__PURE__ */ _export_sfc(_sfc_main$2, [["__scopeId", "data-v-845dc5ab"]]), _withScopeId = (n) => (pushScopeId("data-v-87442ad9"), n = n(), popScopeId(), n), _hoisted_1$1 = { class: "PaymentMode" }, _hoisted_2$1 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("div", { class: "title" }, "选择识别方式", -1)), _hoisted_3$1 = { class: "list" }, _hoisted_4$1 = ["onClick"], _hoisted_5 = { class: "left-text" }, _hoisted_6 = { class: "icon-left" }, _hoisted_7 = { class: "text" }, _hoisted_8 = /* @__PURE__ */ _withScopeId(() => /* @__PURE__ */ createElementVNode("div", { class: "right-icon" }, [
6649
6649
  /* @__PURE__ */ createElementVNode("i", { class: "iconfont icon-xiangyou" })
6650
6650
  ], -1)), _sfc_main$1 = /* @__PURE__ */ defineComponent({
6651
6651
  __name: "index",