@feedmepos/mf-inventory-portal 1.2.37-dev.2 → 1.2.37-dev.3
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/{App-BNC_VGLY.js → App-CD8VnJ2H.js} +3 -3
- package/dist/{ApprovalView-C3-qwfBy.js → ApprovalView-Bolcj_tP.js} +5 -5
- package/dist/{BindingsDialog-DJYcwvLj.js → BindingsDialog-lKTIRoyx.js} +2 -2
- package/dist/{BindingsPicker-BfjaThga.js → BindingsPicker-BND4bzyn.js} +2 -2
- package/dist/{BindingsTable-CxsJ7J29.js → BindingsTable-g3RjbO1T.js} +3 -3
- package/dist/{ClosingDraftView-lWH-HNt8.js → ClosingDraftView-CKWN87FO.js} +8 -8
- package/dist/{ClosingHistoryView-tDq0ShBo.js → ClosingHistoryView-CuNlKY6J.js} +3 -3
- package/dist/{ClosingTemplateView-VDIoPSGE.js → ClosingTemplateView-DWxJYyX6.js} +14 -14
- package/dist/{DeliveryOrderPrintPreview-BB57thjw.js → DeliveryOrderPrintPreview-B3j5bRvr.js} +1 -1
- package/dist/{FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-BFJquom_.js → FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-6YZN79sn.js} +5 -5
- package/dist/{FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-D6nFHej1.js → FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-BWj71msy.js} +2 -2
- package/dist/{FmMultiselectDialog-ByhflquX.js → FmMultiselectDialog-C3-2Dr6d.js} +2 -2
- package/dist/{FmMultiselectDialog-pbQjC6ox.js → FmMultiselectDialog-CWgEzEwT.js} +1 -1
- package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-BVkl9ATd.js → FmUnitInput.vue_vue_type_script_setup_true_lang-DLIipU_w.js} +3 -3
- package/dist/{ImportView-BESMNYR1.js → ImportView-CQU75C7a.js} +6 -6
- package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-6nCLOWwx.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-BV3xSQCM.js} +1 -1
- package/dist/{IngredientGroupView-JdgXfEsA.js → IngredientGroupView-D3WW4zUe.js} +5 -5
- package/dist/{IngredientsView-Btcmhy3H.js → IngredientsView-YzKkGD7A.js} +14 -14
- package/dist/{IntegrationView-CxHNZ7E3.js → IntegrationView-CJ3n2xwM.js} +199 -202
- package/dist/{InventoryBindingForm-CpLif5mq.js → InventoryBindingForm-Dfo61wMe.js} +1 -1
- package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-B2AQxOn1.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-BMxnjBbe.js} +4 -4
- package/dist/{InventoryBindingSummary-DGBAel1C.js → InventoryBindingSummary-3hzbFGYh.js} +1 -1
- package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-oQlPxFAX.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-J2HLdfnn.js} +1 -1
- package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-DuWFQ6Q0.js → PremiumBadge.vue_vue_type_script_setup_true_lang-BMZKKl_Z.js} +2 -2
- package/dist/{PublishView-C-UiGWym.js → PublishView-B20R6kNi.js} +3 -3
- package/dist/{PurchaseOrderPrintPreview-mO_oxnft.js → PurchaseOrderPrintPreview-WC_Y24lf.js} +1 -1
- package/dist/{ReceiveRequestView-Cr6Xrv4Q.js → ReceiveRequestView-D1laHiZU.js} +19 -19
- package/dist/{RecipeView-Bk9O5UiN.js → RecipeView-Bbgjm3Bt.js} +8 -8
- package/dist/{StockView-C2op154q.js → StockView-optz_EZ6.js} +15 -15
- package/dist/{SubsidiaryTreeDialog.vue_vue_type_script_setup_true_lang-CntpgdYL.js → SubsidiaryTreeDialog.vue_vue_type_script_setup_true_lang-BBC-ZUNx.js} +1 -1
- package/dist/{SupplierView-2qjnAlnU.js → SupplierView-4SURx1s3.js} +11 -11
- package/dist/{SystemTrailDialog.vue_vue_type_script_setup_true_lang-DqdgsUES.js → SystemTrailDialog.vue_vue_type_script_setup_true_lang-dTqgPsg7.js} +2 -2
- package/dist/{TemplatePublishDialog.vue_vue_type_script_setup_true_lang-CbSWd397.js → TemplatePublishDialog.vue_vue_type_script_setup_true_lang-BhwX2jFa.js} +1 -1
- package/dist/{TransferDetails.vue_vue_type_script_setup_true_lang-U5KJ5_b2.js → TransferDetails.vue_vue_type_script_setup_true_lang-B3GqoprI.js} +14 -14
- package/dist/{TransferTemplateView-Dw4Ukcce.js → TransferTemplateView-1aLMHMeM.js} +15 -15
- package/dist/{UnitView-H4Sgdzg5.js → UnitView-CD2vaeCV.js} +6 -6
- package/dist/{WarehouseView-DzR1A-Cr.js → WarehouseView-DUVodtRz.js} +5 -5
- package/dist/{WastageTemplateView-Sb2KtrF3.js → WastageTemplateView-BfTAruKY.js} +14 -14
- package/dist/{app-Cnok7m8q.js → app-BwepdcDI.js} +7 -7
- package/dist/app.js +1 -1
- package/dist/{closing-template-u2ACSj7R.js → closing-template-DL6w2Dg7.js} +1 -1
- package/dist/{date2-DtnfdJTF.js → date2-K4W_yblK.js} +1 -1
- package/dist/{dayjs.min-DcraCntx.js → dayjs.min-CbTj4kCs.js} +1 -1
- package/dist/{decimal-CIJMix9a.js → decimal-C4tfRShD.js} +2 -2
- package/dist/{defineDeepModel-LcFLGZe5.js → defineDeepModel-D0UEmaXm.js} +1 -1
- package/dist/{duplicate-template-Btr1_Yzf.js → duplicate-template-chD1EoHj.js} +1 -1
- package/dist/{feature-DSy7PE3I.js → feature-B7AE08ql.js} +2 -2
- package/dist/{format-time-from-id-Dh_SXggJ.js → format-time-from-id-QOYFKV10.js} +1 -1
- package/dist/{format-unit-display-BZ9AAp4V.js → format-unit-display-C1wJe-Gr.js} +10 -10
- package/dist/{import-export.helper-C3aWPNyJ.js → import-export.helper-Iwt-idQz.js} +5 -5
- package/dist/{index-eN7NxI-_.js → index-BHetDmy2.js} +1 -1
- package/dist/{index-DbWKRddg.js → index-DsXGv2ab.js} +3 -3
- package/dist/{index-BTM5svgh.js → index-ZPzpEsHL.js} +1 -1
- package/dist/{lodash-DUlA5LSE.js → lodash-5E2A8OkY.js} +1 -1
- package/dist/{netsuite-ekrD_FS6.js → netsuite-DVvZz2U0.js} +37 -40
- package/dist/{purchase-order-template-C4S6XRoE.js → purchase-order-template-BEUYQowA.js} +1 -1
- package/dist/{rules-Buw1aczb.js → rules-CQN_rhwa.js} +3 -3
- package/dist/{stock-CLvc2DUC.js → stock-CEY9W-x-.js} +3 -3
- package/dist/{stock-DqZP0ldB.js → stock-LfuniSDW.js} +1 -1
- package/dist/stores/integration/netsuite.d.ts +0 -6
- package/dist/{supplier-BA4riI7a.js → supplier-6OLoIB8O.js} +2 -2
- package/dist/{use-ingredient-select-dialog-BFI0Mdnw.js → use-ingredient-select-dialog-zq-B-tyI.js} +2 -2
- package/dist/{use-inventory-binding-dialog-BIqgx607.js → use-inventory-binding-dialog-DCjNYz-I.js} +2 -2
- package/dist/{use-template-enabled-locations-2-CyBo9a3I.js → use-template-enabled-locations-2-CGOlEVFg.js} +2 -2
- package/dist/{vue-i18n-C62Txccp.js → vue-i18n-W94mo81w.js} +201 -201
- package/dist/{xlsx-Cmu71X0Z.js → xlsx-B-urH5Xf.js} +1 -1
- package/dist/{xlsx.util-DI9MSTQE.js → xlsx.util-CA9U1NRi.js} +1 -1
- package/package.json +1 -1
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { defineComponent as Y, mergeModels as Qe, useModel as ke, onMounted as de, ref as L, computed as O, resolveComponent as k, openBlock as I, createElementBlock as E, createElementVNode as r, toDisplayString as R, unref as V, createVNode as y, createBlock as H, withCtx as N, Fragment as Q, renderList as W, normalizeClass as q, normalizeStyle as Pe, createSlots as se, createCommentVNode as j, withModifiers as Je, reactive as Fe, watch as
|
|
1
|
+
import { defineComponent as Y, mergeModels as Qe, useModel as ke, onMounted as de, ref as L, computed as O, resolveComponent as k, openBlock as I, createElementBlock as E, createElementVNode as r, toDisplayString as R, unref as V, createVNode as y, createBlock as H, withCtx as N, Fragment as Q, renderList as W, normalizeClass as q, normalizeStyle as Pe, createSlots as se, createCommentVNode as j, withModifiers as Je, reactive as Fe, watch as Ce, isRef as ie, Teleport as fe, h as F, createTextVNode as K, watchEffect as Ke } from "vue";
|
|
2
2
|
import { E as qe } from "./empty-placeholder-wf6-BWE8.js";
|
|
3
|
-
import { w as Ge, x as Ze, c as ae, u as ne, y as We, a as ce, N as ge, z as Ae, A as Z, s as te, B as
|
|
3
|
+
import { w as Ge, x as Ze, c as ae, u as ne, y as We, a as ce, N as ge, z as Ae, A as Z, s as te, B as Be, C as Ve, t as me } from "./app-BwepdcDI.js";
|
|
4
4
|
import { useDialogChild as $e, useDialog as be, useProxiedModel as re, useSnackbar as $, useBreakpoints as _e, components as J } from "@feedmepos/ui-library";
|
|
5
5
|
import { F as Ee, _ as et } from "./SingleColumnLayout.vue_vue_type_script_setup_true_lang-CWZkVCAj.js";
|
|
6
6
|
import { useI18n as ee, useCoreStore as le } from "@feedmepos/mf-common";
|
|
7
|
-
import { _ as tt } from "./FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-
|
|
8
|
-
import { u as nt, a as ot, b as st, c as at } from "./index-
|
|
9
|
-
import { u as oe, a as pe } from "./netsuite-
|
|
10
|
-
import { b as lt, a as it } from "./FmMultiselectDialog-
|
|
11
|
-
import { R as rt, a as ut } from "./rules-
|
|
7
|
+
import { _ as tt } from "./FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-BWj71msy.js";
|
|
8
|
+
import { u as nt, a as ot, b as st, c as at } from "./index-DsXGv2ab.js";
|
|
9
|
+
import { u as oe, a as pe } from "./netsuite-DVvZz2U0.js";
|
|
10
|
+
import { b as lt, a as it } from "./FmMultiselectDialog-C3-2Dr6d.js";
|
|
11
|
+
import { R as rt, a as ut } from "./rules-CQN_rhwa.js";
|
|
12
12
|
import { N as Ne, H as Le, b as De } from "./app-uBuHtW8m.js";
|
|
13
|
-
import { u as dt } from "./supplier-
|
|
14
|
-
import { u as ve } from "./vue-i18n-
|
|
15
|
-
import { _ as ct, a as mt } from "./FmUnitInput.vue_vue_type_script_setup_true_lang-
|
|
16
|
-
import { a as he, f as Te } from "./date2-
|
|
17
|
-
import { u as Re } from "./feature-
|
|
13
|
+
import { u as dt } from "./supplier-6OLoIB8O.js";
|
|
14
|
+
import { u as ve } from "./vue-i18n-W94mo81w.js";
|
|
15
|
+
import { _ as ct, a as mt } from "./FmUnitInput.vue_vue_type_script_setup_true_lang-DLIipU_w.js";
|
|
16
|
+
import { a as he, f as Te } from "./date2-K4W_yblK.js";
|
|
17
|
+
import { u as Re } from "./feature-B7AE08ql.js";
|
|
18
18
|
import { F as Me } from "./FmDroppableField-J0xUsOTV.js";
|
|
19
|
-
import { r as Oe, u as ze } from "./xlsx-
|
|
19
|
+
import { r as Oe, u as ze } from "./xlsx-B-urH5Xf.js";
|
|
20
20
|
const ft = "data:image/svg+xml,%3csvg%20width='200'%20height='101'%20viewBox='0%200%20200%20101'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M98.9161%2038.4456V24.1772H108.527V27.1988H102.12V30.2202H107.347V32.7382H102.12V38.4456H98.9161Z'%20fill='%235D5359'/%3e%3cpath%20d='M110.382%2031.2276C110.382%2027.5345%20113.249%2024.1772%20117.127%2024.1772C121.174%2024.1772%20123.872%2027.7024%20123.872%2031.3953C123.872%2035.0884%20121.005%2038.6133%20117.127%2038.6133C113.08%2038.4456%20110.382%2034.9204%20110.382%2031.2276ZM117.127%2035.5919C119.487%2035.5919%20120.499%2033.4096%20120.499%2031.2276C120.499%2029.0452%20119.319%2027.0309%20117.127%2027.0309C114.935%2027.0309%20113.754%2029.213%20113.754%2031.2276C113.754%2033.5776%20114.935%2035.5919%20117.127%2035.5919Z'%20fill='%235D5359'/%3e%3cpath%20d='M126.232%2031.2276C126.232%2027.5345%20129.099%2024.1772%20132.977%2024.1772C137.024%2024.1772%20139.722%2027.7024%20139.722%2031.3953C139.722%2035.0884%20136.855%2038.6133%20132.977%2038.6133C128.93%2038.4456%20126.232%2034.9204%20126.232%2031.2276ZM132.977%2035.5919C135.337%2035.5919%20136.349%2033.4096%20136.349%2031.2276C136.349%2029.0452%20135.169%2027.0309%20132.977%2027.0309C130.785%2027.0309%20129.604%2029.213%20129.604%2031.2276C129.604%2033.5776%20130.785%2035.5919%20132.977%2035.5919Z'%20fill='%235D5359'/%3e%3cpath%20d='M142.926%2038.4455V24.345H148.153C152.874%2024.345%20155.235%2027.5343%20155.235%2031.3952C155.235%2035.5918%20152.368%2038.4455%20148.153%2038.4455H142.926ZM148.153%2027.0308H146.129V35.4238H148.153C150.513%2035.4238%20151.862%2033.5775%20151.862%2031.2272C151.862%2028.8773%20150.513%2027.0308%20148.153%2027.0308Z'%20fill='%235D5359'/%3e%3cpath%20d='M110.045%2057.5607V49.1676L107.009%2055.2107H105.324L102.12%2049.1676V57.5607H98.9161V43.4604H102.457L106.167%2050.8465L109.876%2043.4604H113.417V57.5607H110.045Z'%20fill='%235D5359'/%3e%3cpath%20d='M115.947%2057.5607L121.342%2043.4604H124.04L129.436%2057.5607H125.895L124.715%2054.3716H120.331L119.319%2057.5607H115.947ZM122.691%2046.9856L121.005%2052.1893H124.378L122.691%2046.9856Z'%20fill='%235D5359'/%3e%3cpath%20d='M131.965%2057.5607V43.4604H138.373C141.07%2043.4604%20142.925%2045.8105%20142.925%2048.1605C142.925%2049.8393%20142.082%2051.5179%20140.565%2052.1893L143.768%2057.393H140.059L137.192%2052.8607H135V57.393H131.965V57.5607ZM135.169%2050.175H138.204C139.047%2050.175%20139.553%2049.3356%20139.553%2048.1605C139.553%2046.9856%20138.71%2046.3142%20138.035%2046.3142H135.169V50.175Z'%20fill='%235D5359'/%3e%3cpath%20d='M146.635%2057.5607V43.4604H150.007V49.8393L155.403%2043.4604H158.776L153.548%2049.6713L159.281%2057.5607H155.74L151.693%2051.5179L150.007%2053.3642V57.5607H146.635Z'%20fill='%235D5359'/%3e%3cpath%20d='M171.422%2054.7073V57.5607H161.474V43.4604H171.253V46.3142H164.677V48.9999H170.242V51.6856H164.677V54.7073H171.422Z'%20fill='%235D5359'/%3e%3cpath%20d='M185.417%2046.3142H181.202V57.5607H177.829V46.3142H173.614V43.4604H185.417V46.3142Z'%20fill='%235D5359'/%3e%3cpath%20d='M111.057%2062.5967V76.6973H107.853V70.9898H102.12V76.6973H98.9161V62.5967H102.12V68.1361H107.853V62.5967H111.057Z'%20fill='%235D5359'/%3e%3cpath%20d='M124.04%2069.815V62.5967H127.244V69.815C127.244%2073.6758%20125.389%2076.865%20121.005%2076.865C116.453%2076.865%20114.766%2073.5078%20114.766%2069.815V62.5967H117.97V69.815C117.97%2071.997%20118.813%2074.0115%20121.005%2074.0115C123.366%2074.0115%20124.04%2071.997%20124.04%2069.815Z'%20fill='%235D5359'/%3e%3cpath%20d='M138.036%2076.6973H131.122V62.5967H139.047C141.071%2062.5967%20142.251%2064.4433%20142.251%2066.2898C142.251%2067.6327%20141.576%2068.9755%20140.228%2069.4793C141.914%2069.9827%20142.926%2071.1578%20142.926%2073.1721C142.757%2075.5221%20140.733%2076.6973%20138.036%2076.6973ZM134.326%2065.4504V68.3041H137.53C138.204%2068.3041%20138.879%2067.8004%20138.879%2066.7933C138.879%2065.7861%20138.373%2065.2827%20137.698%2065.2827H134.326V65.4504ZM138.204%2070.8221H134.494V73.8435H138.204C139.047%2073.8435%20139.722%2073.1721%20139.722%2072.3327C139.553%2071.6613%20138.879%2070.8221%20138.204%2070.8221Z'%20fill='%235D5359'/%3e%3cpath%20fill-rule='evenodd'%20clip-rule='evenodd'%20d='M73.4753%2051.4994C78.7281%2050.5396%2082.8911%2046.4891%2083.9954%2041.3137L84.1232%2040.7134L83.9445%2040.1256C80.5804%2029.066%2071.9945%2020.2704%2061.0373%2016.5726C57.4%2015.3451%2053.5046%2014.6804%2049.458%2014.6804C45.4112%2014.6804%2041.5158%2015.3451%2037.8784%2016.5726C26.9214%2020.2704%2018.3354%2029.066%2014.9712%2040.1256L14.7924%2040.7134L14.9206%2041.3137C16.0247%2046.4891%2020.1875%2050.5396%2025.4405%2051.4994V58.8839H14.4183C14.6758%2059.9557%2014.9818%2061.0088%2015.3337%2062.0411C20.1553%2076.1811%2033.6083%2086.3619%2049.458%2086.3619C65.3074%2086.3619%2078.7606%2076.1811%2083.5822%2062.0411C83.9342%2061.0088%2084.2399%2059.9557%2084.4974%2058.8839H73.4753V51.4994ZM41.0517%2020.5973V38.5742C41.0517%2043.1931%2044.8155%2046.9371%2049.458%2046.9371C54.1005%2046.9371%2057.8641%2043.1931%2057.8641%2038.5742V20.5973C55.1919%2019.856%2052.3732%2019.4592%2049.458%2019.4592C46.5428%2019.4592%2043.7241%2019.856%2041.0517%2020.5973ZM62.6675%2022.3673V38.5742C62.6675%2043.1931%2066.431%2046.9371%2071.0735%2046.9371C74.9051%2046.9371%2078.1425%2044.3848%2079.1528%2040.8942C76.4672%2032.6902%2070.4379%2025.9824%2062.6675%2022.3673ZM60.2658%2046.1322C57.8753%2049.5094%2053.9255%2051.7159%2049.458%2051.7159C44.9902%2051.7159%2041.0408%2049.5094%2038.65%2046.1322C36.6982%2048.8894%2033.7074%2050.8662%2030.2439%2051.4994V58.8839H68.6718V51.4994C65.2083%2050.8662%2062.2175%2048.8894%2060.2658%2046.1322ZM21.1583%2063.6628C26.1349%2074.2514%2036.9382%2081.5834%2049.458%2081.5834C61.9776%2081.5834%2072.781%2074.2514%2077.7574%2063.6628H21.1583ZM36.2482%2038.5742V22.3673C28.4779%2025.9824%2022.4486%2032.6902%2019.7631%2040.8942C20.7733%2044.3848%2024.0106%2046.9371%2027.8422%2046.9371C32.4847%2046.9371%2036.2482%2043.1931%2036.2482%2038.5742Z'%20fill='%23FFC35D'/%3e%3c/svg%3e";
|
|
21
21
|
var je = { exports: {} };
|
|
22
22
|
(function(_, h) {
|
|
@@ -32,8 +32,8 @@ var je = { exports: {} };
|
|
|
32
32
|
s = s || {};
|
|
33
33
|
var i = 0, n = [], f = t.length, A = 0, m = 0, a = s.pre || "", g = s.post || "", x = s.caseSensitive && t || t.toLowerCase(), S;
|
|
34
34
|
d = s.caseSensitive && d || d.toLowerCase();
|
|
35
|
-
for (var
|
|
36
|
-
S = t[
|
|
35
|
+
for (var C = 0; C < f; C++)
|
|
36
|
+
S = t[C], x[C] === d[i] ? (S = a + S + g, i += 1, m += 1 + m) : m = 0, A += m, n[n.length] = S;
|
|
37
37
|
return i === d.length ? (A = x === d ? 1 / 0 : A, { rendered: n.join(""), score: A }) : null;
|
|
38
38
|
}, o.filter = function(d, t, s) {
|
|
39
39
|
return !t || t.length === 0 ? [] : typeof d != "string" ? t : (s = s || {}, t.reduce(function(i, n, f, A) {
|
|
@@ -130,25 +130,25 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
130
130
|
function n(u, b) {
|
|
131
131
|
if (!d.value)
|
|
132
132
|
return !0;
|
|
133
|
-
const [
|
|
134
|
-
if (typeof
|
|
133
|
+
const [B, ...D] = u;
|
|
134
|
+
if (typeof B != "number")
|
|
135
135
|
return !1;
|
|
136
|
-
const M = b[
|
|
136
|
+
const M = b[B];
|
|
137
137
|
return Ie(
|
|
138
138
|
d.value,
|
|
139
139
|
M.sublabel ? [M.label, M.sublabel] : [M.label]
|
|
140
140
|
) ? !0 : D.length === 0 ? i(M) : G(M) ? n(D, M.children) : !1;
|
|
141
141
|
}
|
|
142
|
-
function f(u, b,
|
|
142
|
+
function f(u, b, B = 0, D = !1) {
|
|
143
143
|
if (G(u) && u.children.length) {
|
|
144
144
|
const { children: M, ...X } = u, T = M.flatMap(
|
|
145
|
-
(z, U) => f(z, [...b, U],
|
|
145
|
+
(z, U) => f(z, [...b, U], B + 1, D || u.disabled)
|
|
146
146
|
);
|
|
147
147
|
return [
|
|
148
148
|
{
|
|
149
149
|
...X,
|
|
150
150
|
keys: b,
|
|
151
|
-
indent:
|
|
151
|
+
indent: B,
|
|
152
152
|
collapsible: !0,
|
|
153
153
|
disabled: D || u.disabled
|
|
154
154
|
},
|
|
@@ -159,14 +159,14 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
159
159
|
{
|
|
160
160
|
...u,
|
|
161
161
|
keys: b,
|
|
162
|
-
indent:
|
|
162
|
+
indent: B,
|
|
163
163
|
collapsible: !1,
|
|
164
164
|
disabled: D || u.disabled
|
|
165
165
|
}
|
|
166
166
|
];
|
|
167
167
|
}
|
|
168
168
|
const A = O(() => h.value.flatMap(
|
|
169
|
-
(u, b) => f(u, [b]).filter((
|
|
169
|
+
(u, b) => f(u, [b]).filter((B) => n(B.keys, h.value))
|
|
170
170
|
));
|
|
171
171
|
function m(u) {
|
|
172
172
|
if (G(u)) {
|
|
@@ -179,10 +179,10 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
179
179
|
return u.active ?? !1;
|
|
180
180
|
}
|
|
181
181
|
function a(u, b) {
|
|
182
|
-
const [
|
|
183
|
-
if (typeof
|
|
182
|
+
const [B, ...D] = u;
|
|
183
|
+
if (typeof B != "number")
|
|
184
184
|
return !1;
|
|
185
|
-
const M = b[
|
|
185
|
+
const M = b[B];
|
|
186
186
|
return D.length === 0 ? m(M ?? []) : G(M) ? a(D, M.children ?? []) : !1;
|
|
187
187
|
}
|
|
188
188
|
function g(u) {
|
|
@@ -196,10 +196,10 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
196
196
|
return !1;
|
|
197
197
|
}
|
|
198
198
|
function x(u, b) {
|
|
199
|
-
const [
|
|
200
|
-
if (typeof
|
|
199
|
+
const [B, ...D] = u;
|
|
200
|
+
if (typeof B != "number")
|
|
201
201
|
return !1;
|
|
202
|
-
const M = b[
|
|
202
|
+
const M = b[B];
|
|
203
203
|
return D.length === 0 ? g(M ?? []) : G(M) ? x(D, (M == null ? void 0 : M.children) ?? []) : !1;
|
|
204
204
|
}
|
|
205
205
|
function S(u, b) {
|
|
@@ -207,15 +207,15 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
207
207
|
return u;
|
|
208
208
|
if (G(u)) {
|
|
209
209
|
if (i(u)) {
|
|
210
|
-
const
|
|
210
|
+
const B = s(u) ? u.children : u.children.filter(i);
|
|
211
211
|
return {
|
|
212
212
|
...u,
|
|
213
|
-
children: u.children.map((D) =>
|
|
213
|
+
children: u.children.map((D) => B.find((X) => Ze(X.value, D.value)) ? S(D, b) : D)
|
|
214
214
|
};
|
|
215
215
|
}
|
|
216
216
|
return {
|
|
217
217
|
...u,
|
|
218
|
-
children: u.children.map((
|
|
218
|
+
children: u.children.map((B) => S(B, b))
|
|
219
219
|
};
|
|
220
220
|
}
|
|
221
221
|
return {
|
|
@@ -223,41 +223,41 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
223
223
|
active: b
|
|
224
224
|
};
|
|
225
225
|
}
|
|
226
|
-
function
|
|
226
|
+
function C(u, b, B) {
|
|
227
227
|
const [D, ...M] = u;
|
|
228
|
-
return typeof D != "number" ? b : M.length === 0 ? b.map((X, T) => D !== T ? X : S(X,
|
|
228
|
+
return typeof D != "number" ? b : M.length === 0 ? b.map((X, T) => D !== T ? X : S(X, B)) : b.map(
|
|
229
229
|
(X, T) => D === T && G(X) ? {
|
|
230
230
|
...X,
|
|
231
|
-
children:
|
|
231
|
+
children: C(M, X.children, B)
|
|
232
232
|
} : X
|
|
233
233
|
);
|
|
234
234
|
}
|
|
235
235
|
const c = L(new Array());
|
|
236
236
|
function e(u) {
|
|
237
237
|
const b = u.join();
|
|
238
|
-
return c.value.find((
|
|
238
|
+
return c.value.find((B) => b === B);
|
|
239
239
|
}
|
|
240
240
|
function v(u) {
|
|
241
241
|
const b = u.join();
|
|
242
|
-
e(u) ? c.value = c.value.filter((
|
|
242
|
+
e(u) ? c.value = c.value.filter((B) => B !== b) : c.value = [...c.value, b];
|
|
243
243
|
}
|
|
244
244
|
function w(u) {
|
|
245
245
|
const b = u.join();
|
|
246
|
-
return c.value.find((
|
|
246
|
+
return c.value.find((B) => b.startsWith(B) && b !== B);
|
|
247
247
|
}
|
|
248
248
|
const p = O(
|
|
249
249
|
() => A.value.filter((u) => n(u.keys, h.value) && u.active).length
|
|
250
250
|
);
|
|
251
|
-
function l(u, b,
|
|
252
|
-
h.value =
|
|
251
|
+
function l(u, b, B) {
|
|
252
|
+
h.value = C(u, b, B), o.emitData(h.value);
|
|
253
253
|
}
|
|
254
254
|
return (u, b) => {
|
|
255
|
-
const
|
|
255
|
+
const B = k("FmSearch"), D = k("FmCheckbox"), M = k("FmButton"), X = k("FmListItem"), T = k("FmList");
|
|
256
256
|
return I(), E("div", gt, [
|
|
257
257
|
r("div", yt, [
|
|
258
258
|
r("div", At, R(V(t)("inventory.formField.itemsSelected", { count: p.value })), 1),
|
|
259
259
|
r("div", bt, [
|
|
260
|
-
y(
|
|
260
|
+
y(B, {
|
|
261
261
|
modelValue: d.value,
|
|
262
262
|
"onUpdate:modelValue": b[0] || (b[0] = (z) => d.value = z),
|
|
263
263
|
placeholder: V(t)("inventory.formField.filterItems")
|
|
@@ -340,10 +340,10 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
340
340
|
]);
|
|
341
341
|
};
|
|
342
342
|
}
|
|
343
|
-
}), wt = { class: "flex flex-col rounded border border-fm-color-neutral-gray-100 px-5 py-5 gap-5" }, kt = { class: "flex items-center" }, Ft = { class: "text-lg font-bold flex-grow" },
|
|
343
|
+
}), wt = { class: "flex flex-col rounded border border-fm-color-neutral-gray-100 px-5 py-5 gap-5" }, kt = { class: "flex items-center" }, Ft = { class: "text-lg font-bold flex-grow" }, Ct = {
|
|
344
344
|
key: 0,
|
|
345
345
|
class: "table-auto w-full"
|
|
346
|
-
},
|
|
346
|
+
}, Bt = { class: "text-left" }, Vt = { class: "min-w-64" }, _t = { class: "flex flex-col" }, Et = { class: "fm-typo-en-body-md-400" }, Nt = {
|
|
347
347
|
key: 0,
|
|
348
348
|
class: "fm-typo-en-body-sm-400 text-fm-color-neutral-gray-400"
|
|
349
349
|
}, Lt = { class: "w-1" }, Dt = /* @__PURE__ */ Y({
|
|
@@ -369,7 +369,7 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
369
369
|
setup(_, { emit: h }) {
|
|
370
370
|
const o = _, d = h, t = be(), s = O(() => {
|
|
371
371
|
const a = o.groups.flatMap((g) => g.items.map((x) => {
|
|
372
|
-
const S = o.items.find((
|
|
372
|
+
const S = o.items.find((C) => C._id === x._id);
|
|
373
373
|
return {
|
|
374
374
|
...x,
|
|
375
375
|
groupName: g.name,
|
|
@@ -377,11 +377,11 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
377
377
|
};
|
|
378
378
|
}));
|
|
379
379
|
return o.modifiers.map((g) => {
|
|
380
|
-
const x = a.find((c) => c.selection === g.selection), S = (x == null ? void 0 : x.name) ?? "-",
|
|
380
|
+
const x = a.find((c) => c.selection === g.selection), S = (x == null ? void 0 : x.name) ?? "-", C = (x == null ? void 0 : x.groupName) ?? "";
|
|
381
381
|
return {
|
|
382
382
|
...g,
|
|
383
383
|
name: S,
|
|
384
|
-
groupName:
|
|
384
|
+
groupName: C
|
|
385
385
|
};
|
|
386
386
|
});
|
|
387
387
|
}), i = O(() => o.groups.flatMap((a) => a.items.map((g) => ({ ...g, groupId: a._id }))));
|
|
@@ -399,18 +399,18 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
399
399
|
let a = [];
|
|
400
400
|
o.groups.forEach((x) => {
|
|
401
401
|
let S = !1;
|
|
402
|
-
x.items.every((
|
|
402
|
+
x.items.every((C) => C._id.startsWith("item")) && (S = !0), a.push({
|
|
403
403
|
label: x.name,
|
|
404
404
|
sublabel: "Group",
|
|
405
405
|
value: x._id,
|
|
406
406
|
disabled: S,
|
|
407
|
-
children: x.items.reduce((
|
|
407
|
+
children: x.items.reduce((C, c) => {
|
|
408
408
|
var w;
|
|
409
409
|
const e = o.items.find((p) => p._id === c._id), v = (w = e == null ? void 0 : e.variant) == null ? void 0 : w.variantCombinations.find(
|
|
410
410
|
(p) => p.combinationKey === (c == null ? void 0 : c.combinationKey)
|
|
411
411
|
);
|
|
412
412
|
return [
|
|
413
|
-
...
|
|
413
|
+
...C,
|
|
414
414
|
{
|
|
415
415
|
label: `${c.name ?? (e == null ? void 0 : e.name)} ${v ? `(${v.name})` : ""}`,
|
|
416
416
|
value: `${c.selection}${v ? `/${v == null ? void 0 : v.combinationKey}` : ""}`,
|
|
@@ -434,7 +434,7 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
434
434
|
}
|
|
435
435
|
}).onPrimary((x) => {
|
|
436
436
|
const S = ae(o.modifiers);
|
|
437
|
-
let
|
|
437
|
+
let C = [];
|
|
438
438
|
function c(e, v) {
|
|
439
439
|
if (v(e), G(e))
|
|
440
440
|
for (let w of e.children)
|
|
@@ -444,14 +444,14 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
444
444
|
c(e, (v) => {
|
|
445
445
|
var u;
|
|
446
446
|
if (o.groups.find(({ _id: b }) => b === v.value)) return;
|
|
447
|
-
const p = i.value.find(({ selection: b }) => b === v.value), l =
|
|
448
|
-
!G(v) && v.active && l === void 0 &&
|
|
447
|
+
const p = i.value.find(({ selection: b }) => b === v.value), l = C.find(({ selection: b }) => v.value === b);
|
|
448
|
+
!G(v) && v.active && l === void 0 && C.push({
|
|
449
449
|
addonGroupId: (p == null ? void 0 : p.groupId) ?? "",
|
|
450
450
|
selection: v.value,
|
|
451
451
|
code: ((u = S.find(({ selection: b }) => v.value === b)) == null ? void 0 : u.code) ?? ""
|
|
452
452
|
});
|
|
453
453
|
});
|
|
454
|
-
}), d("update:modifiers",
|
|
454
|
+
}), d("update:modifiers", C);
|
|
455
455
|
});
|
|
456
456
|
}
|
|
457
457
|
const { t: m } = ee();
|
|
@@ -466,30 +466,30 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
466
466
|
size: "md",
|
|
467
467
|
icon: "link",
|
|
468
468
|
label: V(m)("inventory.integration.apply.applyAddon"),
|
|
469
|
-
onClick: g[0] || (g[0] = (
|
|
469
|
+
onClick: g[0] || (g[0] = (C) => A())
|
|
470
470
|
}, null, 8, ["label"])
|
|
471
471
|
]),
|
|
472
472
|
r("div", null, [
|
|
473
|
-
s.value.length > 0 ? (I(), E("table",
|
|
474
|
-
r("tr",
|
|
473
|
+
s.value.length > 0 ? (I(), E("table", Ct, [
|
|
474
|
+
r("tr", Bt, [
|
|
475
475
|
r("th", Vt, R(V(m)("inventory.integration.apply.name")), 1),
|
|
476
476
|
r("th", null, R(V(m)("inventory.integration.apply.code")), 1),
|
|
477
477
|
g[1] || (g[1] = r("th", { class: "w-1" }, " ", -1))
|
|
478
478
|
]),
|
|
479
|
-
(I(!0), E(Q, null, W(s.value, (
|
|
479
|
+
(I(!0), E(Q, null, W(s.value, (C, c) => (I(), E(Q, { key: c }, [
|
|
480
480
|
g[2] || (g[2] = r("tr", { class: "block h-8" }, null, -1)),
|
|
481
481
|
r("tr", null, [
|
|
482
482
|
r("td", null, [
|
|
483
483
|
r("div", _t, [
|
|
484
|
-
r("div", Et, R(
|
|
485
|
-
|
|
484
|
+
r("div", Et, R(C.name), 1),
|
|
485
|
+
C.groupName ? (I(), E("div", Nt, R(C.groupName), 1)) : j("", !0)
|
|
486
486
|
])
|
|
487
487
|
]),
|
|
488
488
|
r("td", null, [
|
|
489
489
|
y(S, {
|
|
490
490
|
disabled: _.loading,
|
|
491
|
-
"model-value":
|
|
492
|
-
"onUpdate:modelValue": [(e) =>
|
|
491
|
+
"model-value": C.code,
|
|
492
|
+
"onUpdate:modelValue": [(e) => C.code = e, (e) => f(C, e)],
|
|
493
493
|
rules: [
|
|
494
494
|
function(v) {
|
|
495
495
|
return !!v || "Required";
|
|
@@ -505,7 +505,7 @@ const gt = { class: "flex flex-col gap-12 h-[350px]" }, yt = { class: "flex item
|
|
|
505
505
|
icon: "delete",
|
|
506
506
|
"icon-color": "#000000",
|
|
507
507
|
size: "md",
|
|
508
|
-
onClick: (e) => n(
|
|
508
|
+
onClick: (e) => n(C)
|
|
509
509
|
}, null, 8, ["disabled", "onClick"])
|
|
510
510
|
])
|
|
511
511
|
])
|
|
@@ -529,10 +529,10 @@ function Rt(_, h, o) {
|
|
|
529
529
|
variant: {
|
|
530
530
|
variantGroupIds: ((a = i.variant) == null ? void 0 : a.variantGroupIds) || [],
|
|
531
531
|
variantCombinations: (((g = i.variant) == null ? void 0 : g.variantCombinations) || []).map((x) => {
|
|
532
|
-
const S = x.code,
|
|
532
|
+
const S = x.code, C = x.name || f[x.combinationKey || ""];
|
|
533
533
|
return {
|
|
534
534
|
...x,
|
|
535
|
-
codeName: [S,
|
|
535
|
+
codeName: [S, C].filter((c) => !!c).join(" ").trim() || "-"
|
|
536
536
|
};
|
|
537
537
|
})
|
|
538
538
|
}
|
|
@@ -624,13 +624,13 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
624
624
|
const e = n.value.flatMap((v) => v.items);
|
|
625
625
|
return o.bindings.map((v) => {
|
|
626
626
|
var b;
|
|
627
|
-
const w = e.find((
|
|
627
|
+
const w = e.find((B) => B._id === v.productId), p = (w == null ? void 0 : w.name) ?? "-";
|
|
628
628
|
let l = (w == null ? void 0 : w.code) ?? "-", u;
|
|
629
629
|
if (v.combinationKey) {
|
|
630
|
-
const
|
|
630
|
+
const B = (((b = w == null ? void 0 : w.variant) == null ? void 0 : b.variantCombinations) || []).find(
|
|
631
631
|
(D) => D.combinationKey === v.combinationKey
|
|
632
632
|
);
|
|
633
|
-
u = (
|
|
633
|
+
u = (B == null ? void 0 : B.name) ?? (B == null ? void 0 : B.codeName) ?? "", l = (B == null ? void 0 : B.code) ?? l;
|
|
634
634
|
}
|
|
635
635
|
return {
|
|
636
636
|
...v,
|
|
@@ -717,16 +717,16 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
717
717
|
if (G(p))
|
|
718
718
|
return p.children.filter((b) => b.active).map((b) => {
|
|
719
719
|
var M, X;
|
|
720
|
-
const { productId:
|
|
720
|
+
const { productId: B, combinationKey: D } = b.value;
|
|
721
721
|
return D ? {
|
|
722
|
-
productId:
|
|
722
|
+
productId: B,
|
|
723
723
|
combinationKey: D,
|
|
724
724
|
code: ((M = v.find(
|
|
725
|
-
({ productId: T, combinationKey: z }) =>
|
|
725
|
+
({ productId: T, combinationKey: z }) => B === T && D === z
|
|
726
726
|
)) == null ? void 0 : M.code) ?? ""
|
|
727
727
|
} : {
|
|
728
|
-
productId:
|
|
729
|
-
code: ((X = v.find(({ productId: T, combinationKey: z }) =>
|
|
728
|
+
productId: B,
|
|
729
|
+
code: ((X = v.find(({ productId: T, combinationKey: z }) => B === T && !z)) == null ? void 0 : X.code) ?? ""
|
|
730
730
|
};
|
|
731
731
|
});
|
|
732
732
|
if (!p.active)
|
|
@@ -735,7 +735,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
735
735
|
return [
|
|
736
736
|
{
|
|
737
737
|
productId: l,
|
|
738
|
-
code: ((u = v.find(({ productId: b, combinationKey:
|
|
738
|
+
code: ((u = v.find(({ productId: b, combinationKey: B }) => l === b && !B)) == null ? void 0 : u.code) ?? ""
|
|
739
739
|
}
|
|
740
740
|
];
|
|
741
741
|
}));
|
|
@@ -752,7 +752,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
752
752
|
}
|
|
753
753
|
);
|
|
754
754
|
}
|
|
755
|
-
function
|
|
755
|
+
function C() {
|
|
756
756
|
let e;
|
|
757
757
|
o.isAddon ? e = g() : e = a();
|
|
758
758
|
const v = {
|
|
@@ -783,7 +783,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
783
783
|
size: "md",
|
|
784
784
|
icon: "link",
|
|
785
785
|
label: _.isAddon ? V(c)("inventory.integration.apply.applyAddon") : V(c)("inventory.integration.apply.applyProduct"),
|
|
786
|
-
onClick: v[0] || (v[0] = (l) =>
|
|
786
|
+
onClick: v[0] || (v[0] = (l) => C())
|
|
787
787
|
}, null, 8, ["label"])
|
|
788
788
|
]),
|
|
789
789
|
r("div", null, [
|
|
@@ -810,8 +810,8 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
810
810
|
"model-value": l.code,
|
|
811
811
|
"onUpdate:modelValue": [(b) => l.code = b, (b) => m(l, b)],
|
|
812
812
|
rules: [
|
|
813
|
-
function(
|
|
814
|
-
return !!
|
|
813
|
+
function(B) {
|
|
814
|
+
return !!B || "Required";
|
|
815
815
|
}
|
|
816
816
|
]
|
|
817
817
|
}, null, 8, ["model-value", "onUpdate:modelValue", "rules"])
|
|
@@ -848,7 +848,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
848
848
|
emits: ["update:setting", "update:show", "submit"],
|
|
849
849
|
setup(_, { emit: h }) {
|
|
850
850
|
const o = _, d = h, t = Fe(ae(o.setting));
|
|
851
|
-
|
|
851
|
+
Ce([() => o.show], ([m]) => {
|
|
852
852
|
if (m)
|
|
853
853
|
for (const a of Object.keys(o.setting))
|
|
854
854
|
t[a] = o.setting[a];
|
|
@@ -863,8 +863,8 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
863
863
|
}
|
|
864
864
|
const { t: A } = ee();
|
|
865
865
|
return (m, a) => {
|
|
866
|
-
const g = k("FmChip"), x = k("FmForm"), S = k("FmButton"),
|
|
867
|
-
return I(), H(
|
|
866
|
+
const g = k("FmChip"), x = k("FmForm"), S = k("FmButton"), C = k("FmSideSheet");
|
|
867
|
+
return I(), H(C, {
|
|
868
868
|
modelValue: V(i),
|
|
869
869
|
"onUpdate:modelValue": a[4] || (a[4] = (c) => ie(i) ? i.value = c : null),
|
|
870
870
|
header: V(A)("inventory.integration.apply.title"),
|
|
@@ -928,7 +928,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
928
928
|
emits: ["update:setting", "update:show", "submit"],
|
|
929
929
|
setup(_, { emit: h }) {
|
|
930
930
|
const o = _, d = h, t = Fe(ae(o.setting));
|
|
931
|
-
|
|
931
|
+
Ce([() => o.show], ([c]) => {
|
|
932
932
|
if (c)
|
|
933
933
|
for (const e of Object.keys(o.setting))
|
|
934
934
|
t[e] = o.setting[e];
|
|
@@ -954,13 +954,13 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
954
954
|
function S() {
|
|
955
955
|
d("update:setting", ae(t)), d("submit");
|
|
956
956
|
}
|
|
957
|
-
const { t:
|
|
957
|
+
const { t: C } = ee();
|
|
958
958
|
return (c, e) => {
|
|
959
959
|
const v = k("FmChip"), w = k("FmForm"), p = k("FmButton"), l = k("FmSideSheet");
|
|
960
960
|
return I(), H(l, {
|
|
961
961
|
modelValue: V(g),
|
|
962
962
|
"onUpdate:modelValue": e[4] || (e[4] = (u) => ie(g) ? g.value = u : null),
|
|
963
|
-
header: V(
|
|
963
|
+
header: V(C)("inventory.integration.apply.title"),
|
|
964
964
|
"dismiss-away": "",
|
|
965
965
|
"close-button": "",
|
|
966
966
|
"max-width": 500
|
|
@@ -1000,7 +1000,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1000
1000
|
y(p, {
|
|
1001
1001
|
loading: c.loading,
|
|
1002
1002
|
type: "submit",
|
|
1003
|
-
label: V(
|
|
1003
|
+
label: V(C)("common.confirm"),
|
|
1004
1004
|
onClick: e[3] || (e[3] = (u) => x())
|
|
1005
1005
|
}, null, 8, ["loading", "label"])
|
|
1006
1006
|
]),
|
|
@@ -1020,7 +1020,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1020
1020
|
async function x() {
|
|
1021
1021
|
g.value = !0;
|
|
1022
1022
|
}
|
|
1023
|
-
const { breakpoints: S } = _e(),
|
|
1023
|
+
const { breakpoints: S } = _e(), C = O(() => S.value.xs || S.value.sm), c = O(() => C.value);
|
|
1024
1024
|
async function e() {
|
|
1025
1025
|
const w = s.state.setting;
|
|
1026
1026
|
if (w) {
|
|
@@ -1134,8 +1134,8 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1134
1134
|
)
|
|
1135
1135
|
), i = O(() => s.value.search(t.value));
|
|
1136
1136
|
return (n, f) => {
|
|
1137
|
-
const A = k("FmLabel"), m = k("FmField"), a = k("FmIcon"), g = k("FmTextField"), x = k("FmMenuItem"), S = k("FmMenu"),
|
|
1138
|
-
return I(), H(
|
|
1137
|
+
const A = k("FmLabel"), m = k("FmField"), a = k("FmIcon"), g = k("FmTextField"), x = k("FmMenuItem"), S = k("FmMenu"), C = k("FmFormGroup");
|
|
1138
|
+
return I(), H(C, {
|
|
1139
1139
|
"model-value": n.modelValue,
|
|
1140
1140
|
rules: [V(rt)()],
|
|
1141
1141
|
"label-mark": "required"
|
|
@@ -1303,7 +1303,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1303
1303
|
id: "fmLocation",
|
|
1304
1304
|
header: "FeedMe Location",
|
|
1305
1305
|
cell(x) {
|
|
1306
|
-
const S = x.row.original,
|
|
1306
|
+
const S = x.row.original, C = F(J.FmIcon, {
|
|
1307
1307
|
name: S.type,
|
|
1308
1308
|
color: "neutral-gray-400",
|
|
1309
1309
|
size: "md",
|
|
@@ -1311,7 +1311,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1311
1311
|
outline: !0
|
|
1312
1312
|
});
|
|
1313
1313
|
return F("div", { class: "flex items-center" }, [
|
|
1314
|
-
|
|
1314
|
+
C,
|
|
1315
1315
|
F("div", { class: "flex flex-col" }, [
|
|
1316
1316
|
F("span", { class: "font-medium" }, S.name),
|
|
1317
1317
|
F("span", { class: "text-xs text-gray-400" }, S.doc._id)
|
|
@@ -1323,13 +1323,13 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1323
1323
|
id: "nsLocation",
|
|
1324
1324
|
header: "NetSuite Location",
|
|
1325
1325
|
cell(x) {
|
|
1326
|
-
const S = x.row.original,
|
|
1327
|
-
([e, v]) => e !== S.dbName && v.netsuiteId === (
|
|
1326
|
+
const S = x.row.original, C = n.value[S.dbName], c = Object.entries(n.value).some(
|
|
1327
|
+
([e, v]) => e !== S.dbName && v.netsuiteId === (C == null ? void 0 : C.netsuiteId)
|
|
1328
1328
|
);
|
|
1329
1329
|
return F(hn, {
|
|
1330
1330
|
isDuplicate: c,
|
|
1331
1331
|
nsLocationOptions: m.value,
|
|
1332
|
-
modelValue:
|
|
1332
|
+
modelValue: C,
|
|
1333
1333
|
fmLocation: S,
|
|
1334
1334
|
"onUpdate:modelValue": (e) => {
|
|
1335
1335
|
e.netsuiteId ? n.value = {
|
|
@@ -1367,7 +1367,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1367
1367
|
}
|
|
1368
1368
|
}
|
|
1369
1369
|
return (x, S) => {
|
|
1370
|
-
const
|
|
1370
|
+
const C = k("FmTable"), c = k("FmForm"), e = k("FmSpacer"), v = k("FmButton"), w = k("FmDialog");
|
|
1371
1371
|
return I(), H(w, {
|
|
1372
1372
|
modelValue: _.showDialog,
|
|
1373
1373
|
"onUpdate:modelValue": S[2] || (S[2] = (p) => x.$emit("update:showDialog", p)),
|
|
@@ -1395,7 +1395,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1395
1395
|
"onUpdate:modelValue": S[1] || (S[1] = (p) => f.value = p)
|
|
1396
1396
|
}, {
|
|
1397
1397
|
default: N(() => [
|
|
1398
|
-
y(
|
|
1398
|
+
y(C, {
|
|
1399
1399
|
modelValue: f.value,
|
|
1400
1400
|
"onUpdate:modelValue": S[0] || (S[0] = (p) => f.value = p),
|
|
1401
1401
|
"row-data": s.fmLocationNotYetConfigured,
|
|
@@ -1514,7 +1514,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1514
1514
|
(c) => !o.state.setting.locations.some(
|
|
1515
1515
|
(e) => e.netSuiteId === c.netsuiteId
|
|
1516
1516
|
)
|
|
1517
|
-
)),
|
|
1517
|
+
)), C = () => {
|
|
1518
1518
|
t.value = !0;
|
|
1519
1519
|
};
|
|
1520
1520
|
return (c, e) => {
|
|
@@ -1536,7 +1536,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1536
1536
|
]),
|
|
1537
1537
|
y(w, {
|
|
1538
1538
|
label: "Add location",
|
|
1539
|
-
onClick:
|
|
1539
|
+
onClick: C
|
|
1540
1540
|
})
|
|
1541
1541
|
]),
|
|
1542
1542
|
y(p, {
|
|
@@ -1561,10 +1561,10 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1561
1561
|
]);
|
|
1562
1562
|
};
|
|
1563
1563
|
}
|
|
1564
|
-
}), kn = { class: "flex-col items-center" }, Fn = { class: "flex gap-2" },
|
|
1564
|
+
}), kn = { class: "flex-col items-center" }, Fn = { class: "flex gap-2" }, Cn = {
|
|
1565
1565
|
key: 0,
|
|
1566
1566
|
class: "text-xs text-red-500 mt-2"
|
|
1567
|
-
},
|
|
1567
|
+
}, Bn = {
|
|
1568
1568
|
key: 1,
|
|
1569
1569
|
class: "flex items-center mt-2"
|
|
1570
1570
|
}, Vn = { class: "flex flex-col" }, _n = { class: "font-medium" }, En = { class: "text-xs text-gray-400" }, Nn = { class: "text-xs text-gray-400" }, Ln = /* @__PURE__ */ Y({
|
|
@@ -1606,8 +1606,8 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1606
1606
|
}))
|
|
1607
1607
|
})) : j("", !0)
|
|
1608
1608
|
]),
|
|
1609
|
-
s.isDuplicate ? (I(), E("div",
|
|
1610
|
-
d.value.netsuiteId ? (I(), E("div",
|
|
1609
|
+
s.isDuplicate ? (I(), E("div", Cn, " NetSuite vendor being used by another FeedMe supplier. ")) : j("", !0),
|
|
1610
|
+
d.value.netsuiteId ? (I(), E("div", Bn, [
|
|
1611
1611
|
y(f, {
|
|
1612
1612
|
name: "cloud",
|
|
1613
1613
|
color: "neutral-gray-400",
|
|
@@ -1658,7 +1658,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1658
1658
|
id: "fmSupplier",
|
|
1659
1659
|
header: "FeedMe Supplier",
|
|
1660
1660
|
cell(x) {
|
|
1661
|
-
const S = x.row.original,
|
|
1661
|
+
const S = x.row.original, C = F(J.FmIcon, {
|
|
1662
1662
|
name: "apartment",
|
|
1663
1663
|
color: "neutral-gray-400",
|
|
1664
1664
|
size: "md",
|
|
@@ -1666,7 +1666,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1666
1666
|
outline: !0
|
|
1667
1667
|
});
|
|
1668
1668
|
return F("div", { class: "flex items-center" }, [
|
|
1669
|
-
|
|
1669
|
+
C,
|
|
1670
1670
|
F("div", { class: "flex flex-col" }, [
|
|
1671
1671
|
F("span", { class: "font-medium" }, S.name),
|
|
1672
1672
|
F("span", { class: "text-xs text-gray-400" }, S._id)
|
|
@@ -1678,13 +1678,13 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1678
1678
|
id: "nsVendor",
|
|
1679
1679
|
header: "NetSuite Vendor",
|
|
1680
1680
|
cell(x) {
|
|
1681
|
-
const S = x.row.original,
|
|
1682
|
-
([e, v]) => e !== S._id && v.netsuiteId === (
|
|
1681
|
+
const S = x.row.original, C = n.value[S._id], c = Object.entries(n.value).some(
|
|
1682
|
+
([e, v]) => e !== S._id && v.netsuiteId === (C == null ? void 0 : C.netsuiteId)
|
|
1683
1683
|
);
|
|
1684
1684
|
return F(Ln, {
|
|
1685
1685
|
isDuplicate: c,
|
|
1686
1686
|
nsVendorOptions: m.value,
|
|
1687
|
-
modelValue:
|
|
1687
|
+
modelValue: C,
|
|
1688
1688
|
fmSupplier: S,
|
|
1689
1689
|
"onUpdate:modelValue": (e) => {
|
|
1690
1690
|
e.netsuiteId ? n.value = {
|
|
@@ -1700,13 +1700,10 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1700
1700
|
});
|
|
1701
1701
|
}
|
|
1702
1702
|
}
|
|
1703
|
-
], s = _, i = h, n = L({}), f = L(), A = L(""), m = O(() => {
|
|
1704
|
-
|
|
1705
|
-
|
|
1706
|
-
|
|
1707
|
-
value: S
|
|
1708
|
-
}));
|
|
1709
|
-
}), a = O(() => Object.values(n.value).length === 0 || Object.values(n.value).some(
|
|
1703
|
+
], s = _, i = h, n = L({}), f = L(), A = L(""), m = O(() => s.nsVendorsNotBeingUsed.filter((x) => x.name).map((x) => ({
|
|
1704
|
+
label: x.name,
|
|
1705
|
+
value: x
|
|
1706
|
+
}))), a = O(() => Object.values(n.value).length === 0 || Object.values(n.value).some(
|
|
1710
1707
|
(x) => Object.values(n.value).filter((S) => S.netsuiteId === x.netsuiteId).length > 1
|
|
1711
1708
|
));
|
|
1712
1709
|
async function g() {
|
|
@@ -1725,7 +1722,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1725
1722
|
}
|
|
1726
1723
|
}
|
|
1727
1724
|
return (x, S) => {
|
|
1728
|
-
const
|
|
1725
|
+
const C = k("FmSpinner"), c = k("FmTable"), e = k("FmForm"), v = k("FmSpacer"), w = k("FmButton"), p = k("FmDialog");
|
|
1729
1726
|
return I(), H(p, {
|
|
1730
1727
|
modelValue: _.showDialog,
|
|
1731
1728
|
"onUpdate:modelValue": S[2] || (S[2] = (l) => x.$emit("update:showDialog", l)),
|
|
@@ -1747,7 +1744,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1747
1744
|
]),
|
|
1748
1745
|
default: N(() => [
|
|
1749
1746
|
s.nsVendorsLoading ? (I(), E("div", Dn, [
|
|
1750
|
-
y(
|
|
1747
|
+
y(C, { size: "lg" }),
|
|
1751
1748
|
S[4] || (S[4] = r("span", { class: "ml-3 text-gray-500" }, "Loading NetSuite vendors...", -1))
|
|
1752
1749
|
])) : (I(), H(e, {
|
|
1753
1750
|
key: 1,
|
|
@@ -1870,7 +1867,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1870
1867
|
)
|
|
1871
1868
|
)), S = () => {
|
|
1872
1869
|
s.value = !0;
|
|
1873
|
-
},
|
|
1870
|
+
}, C = O(() => !n.value && !f.value && i.value.length > 0);
|
|
1874
1871
|
return (c, e) => {
|
|
1875
1872
|
const v = k("FmSearch"), w = k("FmButton"), p = k("FmTable");
|
|
1876
1873
|
return I(), E("div", null, [
|
|
@@ -1886,7 +1883,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
1886
1883
|
y(w, {
|
|
1887
1884
|
label: "Add vendor",
|
|
1888
1885
|
onClick: S,
|
|
1889
|
-
disabled: !
|
|
1886
|
+
disabled: !C.value
|
|
1890
1887
|
}, null, 8, ["disabled"])
|
|
1891
1888
|
])
|
|
1892
1889
|
]),
|
|
@@ -2157,8 +2154,8 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2157
2154
|
"Inventory Transfer"
|
|
2158
2155
|
];
|
|
2159
2156
|
return (m, a) => {
|
|
2160
|
-
const g = k("FmChip"), x = k("FmTabs"), S = k("FmButton"),
|
|
2161
|
-
return I(), H(
|
|
2157
|
+
const g = k("FmChip"), x = k("FmTabs"), S = k("FmButton"), C = k("FmSideSheet");
|
|
2158
|
+
return I(), H(C, {
|
|
2162
2159
|
modelValue: V(s),
|
|
2163
2160
|
"onUpdate:modelValue": a[2] || (a[2] = (c) => ie(s) ? s.value = c : null),
|
|
2164
2161
|
header: V(f)("inventory.integration.netsuite.title"),
|
|
@@ -2516,7 +2513,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2516
2513
|
value: u,
|
|
2517
2514
|
disabled: l.some((b) => b.netSuiteId === u.netsuiteId) || u.subsidiaryId !== (p == null ? void 0 : p.subsidiaryId)
|
|
2518
2515
|
}));
|
|
2519
|
-
}),
|
|
2516
|
+
}), C = O({
|
|
2520
2517
|
get() {
|
|
2521
2518
|
return a.value ? a.value.toISOString().slice(0, 10) : "";
|
|
2522
2519
|
},
|
|
@@ -2539,7 +2536,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2539
2536
|
const [l, u] = p.split(":").map(Number), b = a.value ?? /* @__PURE__ */ new Date();
|
|
2540
2537
|
b.setHours(l, u), a.value = new Date(b);
|
|
2541
2538
|
}
|
|
2542
|
-
}), e = O(() =>
|
|
2539
|
+
}), e = O(() => C.value && c.value && g.value && n.value.length > 0 && !m.value);
|
|
2543
2540
|
async function v() {
|
|
2544
2541
|
if (e.value) {
|
|
2545
2542
|
if (!x.currentLocationSetting) {
|
|
@@ -2579,7 +2576,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2579
2576
|
value: D,
|
|
2580
2577
|
disabled: !u.includes(D._id)
|
|
2581
2578
|
})
|
|
2582
|
-
),
|
|
2579
|
+
), B = b.filter((D) => {
|
|
2583
2580
|
var M;
|
|
2584
2581
|
return (M = n.value) == null ? void 0 : M.find((X) => X.sku._id === D.value._id);
|
|
2585
2582
|
}).map((D) => D.value);
|
|
@@ -2588,7 +2585,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2588
2585
|
closeButton: !0,
|
|
2589
2586
|
contentComponent: it,
|
|
2590
2587
|
contentComponentProps: {
|
|
2591
|
-
modelValue:
|
|
2588
|
+
modelValue: B,
|
|
2592
2589
|
items: b,
|
|
2593
2590
|
virtualScroll: !0
|
|
2594
2591
|
},
|
|
@@ -2618,7 +2615,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2618
2615
|
});
|
|
2619
2616
|
}
|
|
2620
2617
|
return (p, l) => {
|
|
2621
|
-
const u = k("FmButtonGroup"), b = k("FmLabel"),
|
|
2618
|
+
const u = k("FmButtonGroup"), b = k("FmLabel"), B = k("FmField"), D = k("FmSimpleDatePicker"), M = k("FmTimePicker"), X = k("FmSelect"), T = k("FmIcon"), z = k("FmButton");
|
|
2622
2619
|
return I(), E("div", $n, [
|
|
2623
2620
|
y(u, {
|
|
2624
2621
|
modelValue: A.value,
|
|
@@ -2633,7 +2630,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2633
2630
|
])),
|
|
2634
2631
|
_: 1
|
|
2635
2632
|
}),
|
|
2636
|
-
y(
|
|
2633
|
+
y(B, {
|
|
2637
2634
|
class: "my-4",
|
|
2638
2635
|
disabled: "",
|
|
2639
2636
|
"prepend-icon": "lock"
|
|
@@ -2649,7 +2646,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2649
2646
|
])),
|
|
2650
2647
|
_: 1
|
|
2651
2648
|
}),
|
|
2652
|
-
y(
|
|
2649
|
+
y(B, {
|
|
2653
2650
|
class: "my-4",
|
|
2654
2651
|
disabled: "",
|
|
2655
2652
|
"prepend-icon": "lock"
|
|
@@ -2666,8 +2663,8 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2666
2663
|
_: 1
|
|
2667
2664
|
}),
|
|
2668
2665
|
y(D, {
|
|
2669
|
-
modelValue:
|
|
2670
|
-
"onUpdate:modelValue": l[1] || (l[1] = (U) =>
|
|
2666
|
+
modelValue: C.value,
|
|
2667
|
+
"onUpdate:modelValue": l[1] || (l[1] = (U) => C.value = U)
|
|
2671
2668
|
}, null, 8, ["modelValue"]),
|
|
2672
2669
|
y(b, { class: "fm-typo-en-body-md-600" }, {
|
|
2673
2670
|
default: N(() => l[10] || (l[10] = [
|
|
@@ -2778,7 +2775,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2778
2775
|
function S(p, l) {
|
|
2779
2776
|
l ? n.value.add(p) : n.value.delete(p), n.value = new Set(n.value);
|
|
2780
2777
|
}
|
|
2781
|
-
function
|
|
2778
|
+
function C(p) {
|
|
2782
2779
|
return n.value.has(p);
|
|
2783
2780
|
}
|
|
2784
2781
|
async function c() {
|
|
@@ -2833,7 +2830,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2833
2830
|
}
|
|
2834
2831
|
return (p, l) => {
|
|
2835
2832
|
var X;
|
|
2836
|
-
const u = k("FmButton"), b = k("FmCheckbox"),
|
|
2833
|
+
const u = k("FmButton"), b = k("FmCheckbox"), B = k("FmRadio"), D = k("FmRadioGroup"), M = k("FmDialog");
|
|
2837
2834
|
return I(), E("div", fo, [
|
|
2838
2835
|
r("span", null, "Current date and time: " + R((/* @__PURE__ */ new Date()).toLocaleString()), 1),
|
|
2839
2836
|
y(u, {
|
|
@@ -2865,7 +2862,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2865
2862
|
key: 0,
|
|
2866
2863
|
label: `${T.id} (${T.tranid})`,
|
|
2867
2864
|
value: T.id,
|
|
2868
|
-
modelValue:
|
|
2865
|
+
modelValue: C(T.id),
|
|
2869
2866
|
"onUpdate:modelValue": (U) => S(T.id, U)
|
|
2870
2867
|
}, null, 8, ["label", "value", "modelValue", "onUpdate:modelValue"])) : (I(), E("span", yo, R(T.id) + " (" + R(T.tranid) + ")", 1))
|
|
2871
2868
|
]);
|
|
@@ -2918,7 +2915,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2918
2915
|
"onUpdate:modelValue": l[0] || (l[0] = (T) => A.value = T)
|
|
2919
2916
|
}, {
|
|
2920
2917
|
default: N(() => [
|
|
2921
|
-
(I(), E(Q, null, W(m, (T) => y(
|
|
2918
|
+
(I(), E(Q, null, W(m, (T) => y(B, {
|
|
2922
2919
|
key: T.value,
|
|
2923
2920
|
value: T.value,
|
|
2924
2921
|
label: T.label,
|
|
@@ -2937,7 +2934,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2937
2934
|
}), Io = { class: "flex flex-col gap-8" }, So = {
|
|
2938
2935
|
key: 0,
|
|
2939
2936
|
class: "flex flex-col gap-4"
|
|
2940
|
-
}, wo = { class: "flex flex-col gap-2" }, ko = { class: "flex flex-col gap-2 pl-6" }, Fo = { key: 1 },
|
|
2937
|
+
}, wo = { class: "flex flex-col gap-2" }, ko = { class: "flex flex-col gap-2 pl-6" }, Fo = { key: 1 }, Co = { class: "flex justify-end" }, Bo = { class: "flex flex-col gap-4" }, Vo = { class: "ml-auto flex gap-4" }, _o = /* @__PURE__ */ Y({
|
|
2941
2938
|
__name: "PurchaseOrder",
|
|
2942
2939
|
props: {
|
|
2943
2940
|
currentLocationSetting: {}
|
|
@@ -2957,7 +2954,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
2957
2954
|
function S(p, l) {
|
|
2958
2955
|
l ? n.value.add(p) : n.value.delete(p), n.value = new Set(n.value);
|
|
2959
2956
|
}
|
|
2960
|
-
function
|
|
2957
|
+
function C(p) {
|
|
2961
2958
|
return n.value.has(p);
|
|
2962
2959
|
}
|
|
2963
2960
|
async function c() {
|
|
@@ -3012,7 +3009,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
3012
3009
|
}
|
|
3013
3010
|
return (p, l) => {
|
|
3014
3011
|
var X;
|
|
3015
|
-
const u = k("FmButton"), b = k("FmCheckbox"),
|
|
3012
|
+
const u = k("FmButton"), b = k("FmCheckbox"), B = k("FmRadio"), D = k("FmRadioGroup"), M = k("FmDialog");
|
|
3016
3013
|
return I(), E("div", Io, [
|
|
3017
3014
|
r("span", null, "Current date and time: " + R((/* @__PURE__ */ new Date()).toLocaleString()), 1),
|
|
3018
3015
|
y(u, {
|
|
@@ -3044,14 +3041,14 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
3044
3041
|
key: 0,
|
|
3045
3042
|
label: T,
|
|
3046
3043
|
value: T,
|
|
3047
|
-
modelValue:
|
|
3044
|
+
modelValue: C(T),
|
|
3048
3045
|
"onUpdate:modelValue": (U) => S(T, U)
|
|
3049
3046
|
}, null, 8, ["label", "value", "modelValue", "onUpdate:modelValue"])) : (I(), E("span", Fo, R(T), 1))
|
|
3050
3047
|
]);
|
|
3051
3048
|
}), 128))
|
|
3052
3049
|
])
|
|
3053
3050
|
]),
|
|
3054
|
-
r("div",
|
|
3051
|
+
r("div", Co, [
|
|
3055
3052
|
y(Ee, null, {
|
|
3056
3053
|
default: N(() => [
|
|
3057
3054
|
i.value.length > 0 ? (I(), H(u, {
|
|
@@ -3090,14 +3087,14 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
3090
3087
|
])
|
|
3091
3088
|
]),
|
|
3092
3089
|
default: N(() => [
|
|
3093
|
-
r("div",
|
|
3090
|
+
r("div", Bo, [
|
|
3094
3091
|
r("p", null, " Choose which purchase order version to use for syncing " + R(n.value.size) + " selected purchase orders: ", 1),
|
|
3095
3092
|
y(D, {
|
|
3096
3093
|
modelValue: A.value,
|
|
3097
3094
|
"onUpdate:modelValue": l[0] || (l[0] = (T) => A.value = T)
|
|
3098
3095
|
}, {
|
|
3099
3096
|
default: N(() => [
|
|
3100
|
-
(I(), E(Q, null, W(m, (T) => y(
|
|
3097
|
+
(I(), E(Q, null, W(m, (T) => y(B, {
|
|
3101
3098
|
key: T.value,
|
|
3102
3099
|
value: T.value,
|
|
3103
3100
|
label: T.label,
|
|
@@ -3122,8 +3119,8 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
3122
3119
|
},
|
|
3123
3120
|
emits: ["update:show"],
|
|
3124
3121
|
setup(_, { emit: h }) {
|
|
3125
|
-
var
|
|
3126
|
-
const o = le(), d = oe(), t = _, s = re(t, "show"), { t: i } = ee(), n = h, f = ne(), A = ((
|
|
3122
|
+
var C;
|
|
3123
|
+
const o = le(), d = oe(), t = _, s = re(t, "show"), { t: i } = ee(), n = h, f = ne(), A = ((C = f._currentLocation) == null ? void 0 : C.type) || "", m = [
|
|
3127
3124
|
{
|
|
3128
3125
|
label: "Inventory Transfer (Out)",
|
|
3129
3126
|
value: "inventoryTransfer"
|
|
@@ -3200,7 +3197,7 @@ const Ot = { class: "flex flex-col rounded border border-fm-color-neutral-gray-1
|
|
|
3200
3197
|
]),
|
|
3201
3198
|
y(w, {
|
|
3202
3199
|
"model-value": a.value,
|
|
3203
|
-
"onUpdate:modelValue": e[0] || (e[0] = (
|
|
3200
|
+
"onUpdate:modelValue": e[0] || (e[0] = (B) => a.value = B),
|
|
3204
3201
|
items: m
|
|
3205
3202
|
}, null, 8, ["model-value"])
|
|
3206
3203
|
])
|
|
@@ -3332,8 +3329,8 @@ async function Yo(_, h, o) {
|
|
|
3332
3329
|
});
|
|
3333
3330
|
continue;
|
|
3334
3331
|
}
|
|
3335
|
-
const
|
|
3336
|
-
if (!
|
|
3332
|
+
const C = h.find((p) => p.code === a);
|
|
3333
|
+
if (!C) {
|
|
3337
3334
|
t.push({
|
|
3338
3335
|
row: m.excelRow,
|
|
3339
3336
|
itemCode: a,
|
|
@@ -3344,7 +3341,7 @@ async function Yo(_, h, o) {
|
|
|
3344
3341
|
continue;
|
|
3345
3342
|
}
|
|
3346
3343
|
let c = Number(m.totalPhysicalCustomCost);
|
|
3347
|
-
const e = _[
|
|
3344
|
+
const e = _[C._id];
|
|
3348
3345
|
e && (c = e * Number(x));
|
|
3349
3346
|
const v = te.fromNumber(Number(x)), w = {
|
|
3350
3347
|
amount: v,
|
|
@@ -3353,14 +3350,14 @@ async function Yo(_, h, o) {
|
|
|
3353
3350
|
currency: "MYR"
|
|
3354
3351
|
}
|
|
3355
3352
|
};
|
|
3356
|
-
x != "0" && S == "0" && console.warn(`Item ${a} ${g} has 0 cost.`), s[i =
|
|
3353
|
+
x != "0" && S == "0" && console.warn(`Item ${a} ${g} has 0 cost.`), s[i = C._id] ?? (s[i] = {
|
|
3357
3354
|
skuAdjustment: {
|
|
3358
|
-
sku:
|
|
3355
|
+
sku: C,
|
|
3359
3356
|
fromBalance: te.fromNumber(0),
|
|
3360
3357
|
amounts: [
|
|
3361
3358
|
{
|
|
3362
3359
|
_id: null,
|
|
3363
|
-
type:
|
|
3360
|
+
type: Be.Enum.CLOSING,
|
|
3364
3361
|
remark: "Opening Balance",
|
|
3365
3362
|
amount: v,
|
|
3366
3363
|
measurement: null,
|
|
@@ -3372,7 +3369,7 @@ async function Yo(_, h, o) {
|
|
|
3372
3369
|
toCostBalances: [w]
|
|
3373
3370
|
},
|
|
3374
3371
|
skuBalance: {
|
|
3375
|
-
id:
|
|
3372
|
+
id: C._id,
|
|
3376
3373
|
balance: v,
|
|
3377
3374
|
costs: [w]
|
|
3378
3375
|
}
|
|
@@ -3443,16 +3440,16 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3443
3440
|
disabledReason: "Current location is not binded to NetSuite"
|
|
3444
3441
|
}
|
|
3445
3442
|
] : []
|
|
3446
|
-
]), f = L(n.value[0].value), { t: A } = ve(), m = L(null), a = L(), g = L(""), x = L([]), S = L([]),
|
|
3443
|
+
]), f = L(n.value[0].value), { t: A } = ve(), m = L(null), a = L(), g = L(""), x = L([]), S = L([]), C = [
|
|
3447
3444
|
{
|
|
3448
3445
|
id: "ingredient",
|
|
3449
3446
|
header: () => "Ingredient",
|
|
3450
3447
|
cell(b) {
|
|
3451
|
-
const
|
|
3448
|
+
const B = b.row.original;
|
|
3452
3449
|
return F("div", { class: "flex flex-col" }, [
|
|
3453
|
-
F("span", { class: "font-medium" },
|
|
3450
|
+
F("span", { class: "font-medium" }, B.skuAdjustment.sku.name),
|
|
3454
3451
|
F("span", { class: "text-fm-color-typo-secondary fm-typo-en-body-md-400" }, [
|
|
3455
|
-
|
|
3452
|
+
B.skuAdjustment.sku.code
|
|
3456
3453
|
])
|
|
3457
3454
|
]);
|
|
3458
3455
|
}
|
|
@@ -3461,13 +3458,13 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3461
3458
|
id: "openingBalance",
|
|
3462
3459
|
header: () => "Opening Balance",
|
|
3463
3460
|
cell(b) {
|
|
3464
|
-
const
|
|
3461
|
+
const B = b.row.original;
|
|
3465
3462
|
return F("div", { class: "flex flex-col" }, [
|
|
3466
3463
|
F(
|
|
3467
3464
|
"span",
|
|
3468
3465
|
{ class: "font-medium" },
|
|
3469
3466
|
te.toFormatString({
|
|
3470
|
-
value:
|
|
3467
|
+
value: B.skuAdjustment.amounts[0].amount
|
|
3471
3468
|
})
|
|
3472
3469
|
)
|
|
3473
3470
|
]);
|
|
@@ -3477,18 +3474,18 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3477
3474
|
id: "unit",
|
|
3478
3475
|
header: () => "Unit",
|
|
3479
3476
|
cell(b) {
|
|
3480
|
-
const
|
|
3481
|
-
let M =
|
|
3477
|
+
const B = b.row.original, D = !B.skuAdjustment.amounts[0].measurement;
|
|
3478
|
+
let M = B.skuAdjustment.sku.unit.name;
|
|
3482
3479
|
if (!D) {
|
|
3483
|
-
const X =
|
|
3484
|
-
(T) => T.id ===
|
|
3480
|
+
const X = B.skuAdjustment.sku.unit.measurements.find(
|
|
3481
|
+
(T) => T.id === B.skuAdjustment.amounts[0].measurement.id
|
|
3485
3482
|
);
|
|
3486
3483
|
M = X ? X.name : "Error: Measurement not found";
|
|
3487
3484
|
}
|
|
3488
3485
|
return F("div", { class: "flex flex-col" }, [
|
|
3489
3486
|
F("span", { class: "font-medium" }, M),
|
|
3490
3487
|
D ? null : F("span", { class: "text-fm-color-typo-secondary fm-typo-en-body-md-400" }, [
|
|
3491
|
-
`Base unit: ${
|
|
3488
|
+
`Base unit: ${B.skuAdjustment.sku.unit.name}`
|
|
3492
3489
|
])
|
|
3493
3490
|
]);
|
|
3494
3491
|
}
|
|
@@ -3497,7 +3494,7 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3497
3494
|
id: "totalCost",
|
|
3498
3495
|
header: () => "Total Cost",
|
|
3499
3496
|
cell(b) {
|
|
3500
|
-
const
|
|
3497
|
+
const B = b.row.original, { currency: D, ...M } = B.skuAdjustment.amounts[0].cost ?? {
|
|
3501
3498
|
amount: 0,
|
|
3502
3499
|
precision: 0,
|
|
3503
3500
|
currency: ""
|
|
@@ -3541,12 +3538,12 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3541
3538
|
try {
|
|
3542
3539
|
let b = {};
|
|
3543
3540
|
f.value === "netsuite" && (b = await o.getItemAverageCosts());
|
|
3544
|
-
const { errors:
|
|
3541
|
+
const { errors: B, rows: D } = await Yo(
|
|
3545
3542
|
b,
|
|
3546
3543
|
d.skus,
|
|
3547
3544
|
m.value
|
|
3548
3545
|
);
|
|
3549
|
-
x.value =
|
|
3546
|
+
x.value = B, S.value = Object.values(D);
|
|
3550
3547
|
} catch {
|
|
3551
3548
|
s.open({
|
|
3552
3549
|
message: "Error verifying file",
|
|
@@ -3598,7 +3595,7 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3598
3595
|
const b = new Date(p.value);
|
|
3599
3596
|
return isNaN(b.getTime()) ? null : he(b);
|
|
3600
3597
|
});
|
|
3601
|
-
return (b,
|
|
3598
|
+
return (b, B) => {
|
|
3602
3599
|
const D = k("FmLabel"), M = k("FmField"), X = k("FmSimpleDatePicker"), T = k("FmButton"), z = k("FmIcon"), U = k("FmRadio"), ue = k("FmRadioGroup"), xe = k("FmTable");
|
|
3603
3600
|
return I(), E("div", Jo, [
|
|
3604
3601
|
r("div", Ko, [
|
|
@@ -3614,7 +3611,7 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3614
3611
|
_: 1
|
|
3615
3612
|
}),
|
|
3616
3613
|
V(h).state.closingDocumentId ? (I(), E("div", cs, [
|
|
3617
|
-
|
|
3614
|
+
B[6] || (B[6] = r("span", { class: "text-fm-color-typo-secondary fm-typo-en-body-md-400" }, " Not able to import opening balance as closing document already exists. ", -1)),
|
|
3618
3615
|
V(i)._currentLocation ? (I(), E(Q, { key: 0 }, [
|
|
3619
3616
|
y(D, { label: "Location ID" }),
|
|
3620
3617
|
y(M, {
|
|
@@ -3630,7 +3627,7 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3630
3627
|
])) : (I(), E("div", qo, [
|
|
3631
3628
|
y(X, {
|
|
3632
3629
|
modelValue: l.value,
|
|
3633
|
-
"onUpdate:modelValue":
|
|
3630
|
+
"onUpdate:modelValue": B[0] || (B[0] = (P) => l.value = P),
|
|
3634
3631
|
label: "Last closing time"
|
|
3635
3632
|
}, {
|
|
3636
3633
|
"trigger-button": N(() => [
|
|
@@ -3651,7 +3648,7 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3651
3648
|
y(D, { label: "Stock take file" })
|
|
3652
3649
|
]),
|
|
3653
3650
|
y(Me, {
|
|
3654
|
-
onFileUpload:
|
|
3651
|
+
onFileUpload: B[1] || (B[1] = (P) => {
|
|
3655
3652
|
P && (m.value = P);
|
|
3656
3653
|
}),
|
|
3657
3654
|
accept: ".xlsx, .xls, .csv"
|
|
@@ -3678,7 +3675,7 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3678
3675
|
]), 1024),
|
|
3679
3676
|
y(ue, {
|
|
3680
3677
|
modelValue: f.value,
|
|
3681
|
-
"onUpdate:modelValue":
|
|
3678
|
+
"onUpdate:modelValue": B[2] || (B[2] = (P) => f.value = P),
|
|
3682
3679
|
label: "Retrieve cost from",
|
|
3683
3680
|
class: "my-5"
|
|
3684
3681
|
}, {
|
|
@@ -3729,18 +3726,18 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3729
3726
|
}, null, 8, ["disabled", "loading"])
|
|
3730
3727
|
]),
|
|
3731
3728
|
m.value && S.value.length > 0 ? (I(), E(Q, { key: 0 }, [
|
|
3732
|
-
|
|
3729
|
+
B[4] || (B[4] = r("h2", { class: "fm-typo-en-title-md-800 mt-8 mb-4" }, "Results", -1)),
|
|
3733
3730
|
y(xe, {
|
|
3734
3731
|
modelValue: a.value,
|
|
3735
|
-
"onUpdate:modelValue":
|
|
3732
|
+
"onUpdate:modelValue": B[3] || (B[3] = (P) => a.value = P),
|
|
3736
3733
|
"row-data": S.value,
|
|
3737
|
-
"column-defs":
|
|
3734
|
+
"column-defs": C,
|
|
3738
3735
|
"shrink-at": !1,
|
|
3739
3736
|
"search-value": g.value
|
|
3740
3737
|
}, null, 8, ["modelValue", "row-data", "search-value"])
|
|
3741
3738
|
], 64)) : j("", !0),
|
|
3742
3739
|
x.value.length > 0 ? (I(), E(Q, { key: 1 }, [
|
|
3743
|
-
|
|
3740
|
+
B[5] || (B[5] = r("h2", { class: "fm-typo-en-title-md-800 mt-8 mb-4 text-red-600" }, "Errors", -1)),
|
|
3744
3741
|
y(xe, {
|
|
3745
3742
|
"row-data": x.value,
|
|
3746
3743
|
"column-defs": c
|
|
@@ -3785,7 +3782,7 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3785
3782
|
], m = L(A[0]);
|
|
3786
3783
|
return (g, x) => {
|
|
3787
3784
|
var v;
|
|
3788
|
-
const S = k("FmIcon"),
|
|
3785
|
+
const S = k("FmIcon"), C = k("FmButtonGroup"), c = k("FmButton"), e = k("FmSideSheet");
|
|
3789
3786
|
return I(), H(e, {
|
|
3790
3787
|
modelValue: V(t),
|
|
3791
3788
|
"onUpdate:modelValue": x[2] || (x[2] = (w) => ie(t) ? t.value = w : null),
|
|
@@ -3836,7 +3833,7 @@ const Jo = { class: "flex flex-col gap-4" }, Ko = { class: "flex flex-col" }, qo
|
|
|
3836
3833
|
r("div", gs, R((w = V(n)._currentLocation) == null ? void 0 : w.name), 1)
|
|
3837
3834
|
])
|
|
3838
3835
|
]),
|
|
3839
|
-
y(
|
|
3836
|
+
y(C, {
|
|
3840
3837
|
modelValue: m.value,
|
|
3841
3838
|
"onUpdate:modelValue": x[0] || (x[0] = (p) => m.value = p),
|
|
3842
3839
|
items: A
|
|
@@ -3920,8 +3917,8 @@ async function Ss(_, h, o) {
|
|
|
3920
3917
|
});
|
|
3921
3918
|
continue;
|
|
3922
3919
|
}
|
|
3923
|
-
const
|
|
3924
|
-
if (!
|
|
3920
|
+
const C = h.find((p) => p.code === a);
|
|
3921
|
+
if (!C) {
|
|
3925
3922
|
t.push({
|
|
3926
3923
|
row: m.excelRow,
|
|
3927
3924
|
itemCode: a,
|
|
@@ -3932,7 +3929,7 @@ async function Ss(_, h, o) {
|
|
|
3932
3929
|
continue;
|
|
3933
3930
|
}
|
|
3934
3931
|
let c = Number(m.total);
|
|
3935
|
-
const e = _[
|
|
3932
|
+
const e = _[C._id];
|
|
3936
3933
|
e && (c = e * Number(x));
|
|
3937
3934
|
const v = te.fromNumber(Number(x)), w = {
|
|
3938
3935
|
amount: v,
|
|
@@ -3941,14 +3938,14 @@ async function Ss(_, h, o) {
|
|
|
3941
3938
|
currency: "MYR"
|
|
3942
3939
|
}
|
|
3943
3940
|
};
|
|
3944
|
-
x != "0" && S == "0" && console.warn(`Item ${a} ${g} has 0 cost.`), s[f =
|
|
3941
|
+
x != "0" && S == "0" && console.warn(`Item ${a} ${g} has 0 cost.`), s[f = C._id] ?? (s[f] = {
|
|
3945
3942
|
skuAdjustment: {
|
|
3946
|
-
sku:
|
|
3943
|
+
sku: C,
|
|
3947
3944
|
fromBalance: te.fromNumber(0),
|
|
3948
3945
|
amounts: [
|
|
3949
3946
|
{
|
|
3950
3947
|
_id: null,
|
|
3951
|
-
type:
|
|
3948
|
+
type: Be.Enum.CLOSING,
|
|
3952
3949
|
remark: "Opening Balance",
|
|
3953
3950
|
amount: v,
|
|
3954
3951
|
measurement: null,
|
|
@@ -3960,7 +3957,7 @@ async function Ss(_, h, o) {
|
|
|
3960
3957
|
toCostBalances: [w]
|
|
3961
3958
|
},
|
|
3962
3959
|
skuBalance: {
|
|
3963
|
-
id:
|
|
3960
|
+
id: C._id,
|
|
3964
3961
|
balance: v,
|
|
3965
3962
|
costs: [w]
|
|
3966
3963
|
}
|
|
@@ -3999,7 +3996,7 @@ async function ks(_) {
|
|
|
3999
3996
|
}
|
|
4000
3997
|
return o;
|
|
4001
3998
|
}
|
|
4002
|
-
const Fs = { class: "flex flex-col gap-4" },
|
|
3999
|
+
const Fs = { class: "flex flex-col gap-4" }, Cs = { class: "flex flex-col" }, Bs = {
|
|
4003
4000
|
key: 0,
|
|
4004
4001
|
class: "flex flex-col gap-4 my-5"
|
|
4005
4002
|
}, Vs = { class: "flex flex-col gap-8" }, _s = { class: "flex flex-col gap-8" }, Es = {
|
|
@@ -4050,15 +4047,15 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4050
4047
|
header: () => "Unit",
|
|
4051
4048
|
cell(l) {
|
|
4052
4049
|
const u = l.row.original, b = !u.skuAdjustment.amounts[0].measurement;
|
|
4053
|
-
let
|
|
4050
|
+
let B = u.skuAdjustment.sku.unit.name;
|
|
4054
4051
|
if (!b) {
|
|
4055
4052
|
const D = u.skuAdjustment.sku.unit.measurements.find(
|
|
4056
4053
|
(M) => M.id === u.skuAdjustment.amounts[0].measurement.id
|
|
4057
4054
|
);
|
|
4058
|
-
|
|
4055
|
+
B = D ? D.name : "Error: Measurement not found";
|
|
4059
4056
|
}
|
|
4060
4057
|
return F("div", { class: "flex flex-col" }, [
|
|
4061
|
-
F("span", { class: "font-medium" },
|
|
4058
|
+
F("span", { class: "font-medium" }, B),
|
|
4062
4059
|
b ? null : F("span", { class: "text-fm-color-typo-secondary fm-typo-en-body-md-400" }, [
|
|
4063
4060
|
`Base unit: ${u.skuAdjustment.sku.unit.name}`
|
|
4064
4061
|
])
|
|
@@ -4069,7 +4066,7 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4069
4066
|
id: "totalCost",
|
|
4070
4067
|
header: () => "Total Cost",
|
|
4071
4068
|
cell(l) {
|
|
4072
|
-
const u = l.row.original, { currency: b, ...
|
|
4069
|
+
const u = l.row.original, { currency: b, ...B } = u.skuAdjustment.amounts[0].cost ?? {
|
|
4073
4070
|
amount: 0,
|
|
4074
4071
|
precision: 0,
|
|
4075
4072
|
currency: ""
|
|
@@ -4079,7 +4076,7 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4079
4076
|
"span",
|
|
4080
4077
|
{ class: "font-medium" },
|
|
4081
4078
|
te.toFormatString({
|
|
4082
|
-
value:
|
|
4079
|
+
value: B
|
|
4083
4080
|
})
|
|
4084
4081
|
)
|
|
4085
4082
|
]);
|
|
@@ -4106,10 +4103,10 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4106
4103
|
accessorKey: "message",
|
|
4107
4104
|
header: "Error Message"
|
|
4108
4105
|
}
|
|
4109
|
-
],
|
|
4106
|
+
], C = L(!1);
|
|
4110
4107
|
async function c() {
|
|
4111
4108
|
if (f.value) {
|
|
4112
|
-
|
|
4109
|
+
C.value = !0;
|
|
4113
4110
|
try {
|
|
4114
4111
|
let l = {};
|
|
4115
4112
|
const { errors: u, rows: b } = await Ss(
|
|
@@ -4124,13 +4121,13 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4124
4121
|
type: "error"
|
|
4125
4122
|
});
|
|
4126
4123
|
} finally {
|
|
4127
|
-
|
|
4124
|
+
C.value = !1;
|
|
4128
4125
|
}
|
|
4129
4126
|
}
|
|
4130
4127
|
}
|
|
4131
4128
|
async function e() {
|
|
4132
4129
|
if (f.value) {
|
|
4133
|
-
|
|
4130
|
+
C.value = !0;
|
|
4134
4131
|
try {
|
|
4135
4132
|
if (!w.value) {
|
|
4136
4133
|
t.open({
|
|
@@ -4153,7 +4150,7 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4153
4150
|
type: "error"
|
|
4154
4151
|
});
|
|
4155
4152
|
} finally {
|
|
4156
|
-
|
|
4153
|
+
C.value = !1;
|
|
4157
4154
|
}
|
|
4158
4155
|
}
|
|
4159
4156
|
}
|
|
@@ -4170,12 +4167,12 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4170
4167
|
return isNaN(l.getTime()) ? null : he(l);
|
|
4171
4168
|
});
|
|
4172
4169
|
return (l, u) => {
|
|
4173
|
-
const b = k("FmLabel"),
|
|
4170
|
+
const b = k("FmLabel"), B = k("FmField"), D = k("FmSimpleDatePicker"), M = k("FmButton"), X = k("FmRadio"), T = k("FmRadioGroup"), z = k("FmTable");
|
|
4174
4171
|
return I(), E("div", Fs, [
|
|
4175
|
-
r("div",
|
|
4172
|
+
r("div", Cs, [
|
|
4176
4173
|
y(b, { label: "Latest closing" })
|
|
4177
4174
|
]),
|
|
4178
|
-
y(
|
|
4175
|
+
y(B, {
|
|
4179
4176
|
"prepend-icon": "lock_outline",
|
|
4180
4177
|
disabled: ""
|
|
4181
4178
|
}, {
|
|
@@ -4186,14 +4183,14 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4186
4183
|
}),
|
|
4187
4184
|
V(h).state.closingDocumentId ? (I(), E("div", zs, u[6] || (u[6] = [
|
|
4188
4185
|
r("span", { class: "text-fm-color-typo-secondary fm-typo-en-body-md-400" }, " Not able to import opening balance as closing document already exists. ", -1)
|
|
4189
|
-
]))) : (I(), E("div",
|
|
4186
|
+
]))) : (I(), E("div", Bs, [
|
|
4190
4187
|
y(D, {
|
|
4191
4188
|
modelValue: w.value,
|
|
4192
4189
|
"onUpdate:modelValue": u[0] || (u[0] = (U) => w.value = U),
|
|
4193
4190
|
label: "Last closing time"
|
|
4194
4191
|
}, {
|
|
4195
4192
|
"trigger-button": N(() => [
|
|
4196
|
-
y(
|
|
4193
|
+
y(B, {
|
|
4197
4194
|
"prepend-icon": "calendar_today",
|
|
4198
4195
|
readonly: "",
|
|
4199
4196
|
label: "Last closing time"
|
|
@@ -4266,8 +4263,8 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4266
4263
|
variant: "secondary",
|
|
4267
4264
|
"prepend-icon": "troubleshoot",
|
|
4268
4265
|
label: "Verify",
|
|
4269
|
-
disabled: !f.value && !
|
|
4270
|
-
loading:
|
|
4266
|
+
disabled: !f.value && !C.value,
|
|
4267
|
+
loading: C.value,
|
|
4271
4268
|
onClick: c
|
|
4272
4269
|
}, null, 8, ["disabled", "loading"])
|
|
4273
4270
|
]),
|
|
@@ -4296,7 +4293,7 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4296
4293
|
"prepend-icon": "file_upload",
|
|
4297
4294
|
variant: "primary",
|
|
4298
4295
|
label: "Import Opening Balance",
|
|
4299
|
-
disabled: !f.value ||
|
|
4296
|
+
disabled: !f.value || C.value,
|
|
4300
4297
|
onClick: e
|
|
4301
4298
|
}, null, 8, ["disabled"])) : j("", !0)
|
|
4302
4299
|
])
|
|
@@ -4318,7 +4315,7 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4318
4315
|
var A;
|
|
4319
4316
|
const o = le(), t = re(_, "show"), { t: s } = ee(), i = h, n = ne(), f = ((A = n._currentLocation) == null ? void 0 : A.type) || "";
|
|
4320
4317
|
return (m, a) => {
|
|
4321
|
-
var
|
|
4318
|
+
var C;
|
|
4322
4319
|
const g = k("FmIcon"), x = k("FmButton"), S = k("FmSideSheet");
|
|
4323
4320
|
return I(), H(S, {
|
|
4324
4321
|
modelValue: V(t),
|
|
@@ -4347,7 +4344,7 @@ const Fs = { class: "flex flex-col gap-4" }, Bs = { class: "flex flex-col" }, Cs
|
|
|
4347
4344
|
]),
|
|
4348
4345
|
_: 2
|
|
4349
4346
|
}, [
|
|
4350
|
-
(
|
|
4347
|
+
(C = V(o).sessionUser.value) != null && C.role.isAdmin ? {
|
|
4351
4348
|
name: "side-sheet-header",
|
|
4352
4349
|
fn: N(() => {
|
|
4353
4350
|
var c;
|