@feedmepos/mf-inventory-portal 1.2.0 → 1.2.2-5.dev-1
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-DMkUg806.js +297 -0
- package/dist/{ApprovalView-Dr-qd_Ai.js → ApprovalView-DWJh2K6W.js} +65 -64
- package/dist/{BindingsDialog-Chh00-83.js → BindingsDialog-EmHCvqJI.js} +2 -2
- package/dist/{BindingsPicker-DCTGJ8eM.js → BindingsPicker-h_9jm1s0.js} +3 -3
- package/dist/{BindingsTable-BsDs5d0V.js → BindingsTable-BAVWGUoa.js} +1 -1
- package/dist/ClosingDraftView-Du4kOwIg.js +1899 -0
- package/dist/ClosingHistoryView-DuW2Vtrs.js +355 -0
- package/dist/ClosingTemplateView-CfPY8R5M.js +2001 -0
- package/dist/{DeliveryOrderPrintPreview-CrH9UVdW.js → DeliveryOrderPrintPreview-C6Cj8mOp.js} +9 -9
- package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-WWIrybw_.js +230 -0
- package/dist/{FmMultiselectDialog-ypgaHejh.js → FmMultiselectDialog-BzWrQOS4.js} +1 -1
- package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-DJctVhvZ.js → FmUnitInput.vue_vue_type_script_setup_true_lang-DwqVRUFz.js} +36 -36
- package/dist/ImportView-lKlYeLay.js +1291 -0
- package/dist/{IngredientBindedItem.vue_vue_type_script_setup_true_lang-D59M4Bl1.js → IngredientBindedItem.vue_vue_type_script_setup_true_lang-_2WZMZU2.js} +5 -5
- package/dist/{IngredientGroupView-Cf9ePE7_.js → IngredientGroupView-CrmwR2Xt.js} +34 -35
- package/dist/IngredientsView-1bAsyz-b.js +2254 -0
- package/dist/{IntegrationView-DEDn2mc5.js → IntegrationView-D16qeEc_.js} +1773 -1635
- package/dist/{InventoryBindingForm-AB8rum4-.js → InventoryBindingForm-BRwOXV_P.js} +1 -1
- package/dist/{InventoryBindingForm.vue_vue_type_script_setup_true_lang-BgZt_9h1.js → InventoryBindingForm.vue_vue_type_script_setup_true_lang-NDbtbtqK.js} +28 -28
- package/dist/{InventoryBindingSummary-CWOG5DIz.js → InventoryBindingSummary-DKM2gX8_.js} +1 -1
- package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-CmN30iEZ.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-CdaiYTdf.js} +4 -4
- package/dist/{PremiumBadge.vue_vue_type_script_setup_true_lang-C1cUDp0u.js → PremiumBadge.vue_vue_type_script_setup_true_lang-B0OKeK5O.js} +7 -7
- package/dist/{PublishView-FHyjjevA.js → PublishView-D0NnU22l.js} +73 -63
- package/dist/{PurchaseOrderPrintPreview-BPvvkjkR.js → PurchaseOrderPrintPreview-BmuwNbeL.js} +4 -4
- package/dist/{ReceiveRequestView-CoWU2g0R.js → ReceiveRequestView-j79m7TKk.js} +343 -333
- package/dist/RecipeView-D_fNQQ-C.js +636 -0
- package/dist/StockView-DX_xeFBT.js +2385 -0
- package/dist/SubsidiaryTreeDialog.vue_vue_type_script_setup_true_lang-Bg49isUy.js +172 -0
- package/dist/{SupplierView-CJG2Idbl.js → SupplierView-DuFTqbOg.js} +1193 -1073
- package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-c428GXwc.js +3233 -0
- package/dist/{TransferTemplateView-DZnPt5b5.js → TransferTemplateView-Ccsfcetz.js} +104 -103
- package/dist/UnitView-BklpNsFN.js +674 -0
- package/dist/WarehouseView-BrURbU67.js +1066 -0
- package/dist/api/adjustment-template.d.ts +1 -0
- package/dist/api/bill.d.ts +140 -2
- package/dist/api/closing-template.d.ts +1 -0
- package/dist/api/closing.d.ts +1 -0
- package/dist/api/inventory.d.ts +405 -0
- package/dist/api/netsuite.d.ts +5 -1
- package/dist/api/purchase-order-template.d.ts +1 -0
- package/dist/api/purchase-order.d.ts +3 -0
- package/dist/api/shipment.d.ts +11 -0
- package/dist/api/stock.d.ts +2 -44
- package/dist/api/warehouse.d.ts +3 -1
- package/dist/{app-B6mXF-3v.js → app-a9r50k3U.js} +68557 -67576
- package/dist/app.d.ts +646 -15
- package/dist/app.js +6 -6
- package/dist/components/FmAdminBadge.vue.d.ts +1 -4
- package/dist/components/FmEnhancedSelect.vue.d.ts +30 -0
- package/dist/components/FmInventoryTableToolbar.vue.d.ts +16 -2
- package/dist/components/FmLockableField.vue.d.ts +3 -0
- package/dist/components/netsuite/ItemSubsidiaryTreeDialog.vue.d.ts +16 -0
- package/dist/components/netsuite/SubsidiaryTreeDialog.vue.d.ts +2 -0
- package/dist/composable/defineApi.d.ts +1 -1
- package/dist/composable/useIframe.d.ts +2 -2
- package/dist/{decimal-DErYDfEJ.js → decimal-AusUnA1W.js} +1 -1
- package/dist/{format-unit-display-BtjJtmQp.js → format-unit-display-BqkHL-ph.js} +397 -429
- package/dist/helper/array.d.ts +1 -0
- package/dist/helper/core/country/utils.d.ts +3 -4
- package/dist/helper/country.d.ts +6 -255
- package/dist/helper/number.d.ts +1 -0
- package/dist/import-export.helper-PIyNeHfa.js +238 -0
- package/dist/{index-lj4ClRIU.js → index-CjxirPvn.js} +283 -268
- package/dist/{index-CvfUsVdt.js → index-Dj9-pdT9.js} +1 -1
- package/dist/layout/SingleColumnLayout.vue.d.ts +6 -3
- package/dist/purchase-order-template-CQikvY1p.js +41 -0
- package/dist/router/name.d.ts +2 -0
- package/dist/stock-CDZ2uWSF.js +83 -0
- package/dist/stock-Dw908dIC.js +74 -0
- package/dist/stores/feature.d.ts +12 -0
- package/dist/stores/integration/netsuite.d.ts +42 -0
- package/dist/stores/inventory.d.ts +28 -199
- package/dist/stores/location.d.ts +331 -1
- package/dist/stores/supplier.d.ts +96 -0
- package/dist/stores/warehouse.d.ts +4 -0
- package/dist/style.css +1 -1
- package/dist/{supplier-D_2yzArc.js → supplier-BPPBUudN.js} +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{use-ingredient-select-dialog-C9iEMCVA.js → use-ingredient-select-dialog-C_fSKN3_.js} +5 -5
- package/dist/{use-inventory-binding-dialog-CavX3SFd.js → use-inventory-binding-dialog-ClAkJ864.js} +8 -8
- package/dist/views/adjustment-template/wastage-template/actions.d.ts +60 -0
- package/dist/views/adjustment-template/wastage-template/table.d.ts +60 -0
- package/dist/views/closing-draft/components/closing-draft-dialog/ClosingDraftDialog.vue.d.ts +56 -0
- package/dist/views/closing-draft/composables/use-closing-draft-actions.d.ts +3 -3
- package/dist/views/closing-draft/composables/use-closing-draft-table.d.ts +468 -0
- package/dist/views/closing-draft/helpers/export-draft.helper.d.ts +9 -2
- package/dist/views/closing-history/ClosingHistoryView.vue.d.ts +2 -0
- package/dist/views/closing-template/composables/use-closing-template-actions.d.ts +4 -1
- package/dist/views/closing-template/helpers/import-export.helper.d.ts +5 -0
- package/dist/views/import/ImportView.vue.d.ts +3 -0
- package/dist/views/import/components/ImportDialog.vue.d.ts +2 -0
- package/dist/views/import/helper/import-export.helper.d.ts +4 -0
- package/dist/views/ingredients/components/ingredient-dialog/IngredientDialogProps.d.ts +1 -1
- package/dist/views/ingredients/components/ingredient-form/IngredientForm.vue.d.ts +181 -12
- package/dist/views/ingredients/components/ingredient-form/IngredientFormProps.d.ts +6 -0
- package/dist/views/ingredients/helper/import-export.helper.d.ts +4 -1
- package/dist/views/integration/components/netsuite/business/BusinessNetSuiteSideSheet.vue.d.ts +2 -0
- package/dist/views/receive-request/components/delivery-order-form/CreateForm.vue.d.ts +16 -0
- package/dist/views/receive-request/components/delivery-order-form/CreateFormProps.d.ts +4 -0
- package/dist/views/receive-request/components/delivery-order-form/EditForm.vue.d.ts +16 -0
- package/dist/views/receive-request/components/delivery-order-form/EditFormProps.d.ts +4 -0
- package/dist/views/receive-request/components/delivery-order-form/SystemTrailDialog.vue.d.ts +21 -0
- package/dist/views/receive-request/components/netsuite/NetSuiteTransactionChangeLog.vue.d.ts +15 -0
- package/dist/views/receive-request/components/transfer-details/TransferDetailsProps.d.ts +1 -0
- package/dist/views/receive-request/components/transfer-form/TransferForm.vue.d.ts +420 -2
- package/dist/views/receive-request/composables/use-process-purchase-order.d.ts +99 -0
- package/dist/views/receive-request/composables/use-receive-request-form.d.ts +644 -13
- package/dist/views/receive-request/composables/use-receive-request-table.d.ts +711 -14
- package/dist/views/recipe/RecipeView.vue.d.ts +1 -0
- package/dist/views/recipe/components/import-recipes/ImportRecipeItem.vue.d.ts +16 -0
- package/dist/views/recipe/components/import-recipes/ImportRecipes.vue.d.ts +2 -0
- package/dist/views/recipe/helper/import-recipe.d.ts +48 -0
- package/dist/views/stock/components/StockRecordCard.vue.d.ts +70 -1
- package/dist/views/stock/components/dialog/RecalculationDialog.vue.d.ts +11 -0
- package/dist/views/stock/components/dialog/RecalculationDialogProps.d.ts +3 -0
- package/dist/views/stock/components/dialog/StockAdjustmentSideSheet.vue.d.ts +20 -0
- package/dist/views/supplier/components/SupplierForm.vue.d.ts +8 -0
- package/dist/views/supplier/components/SupplierSupplyItemField.vue.d.ts +3 -0
- package/dist/views/supplier/composables/use-supplier-table.d.ts +4 -0
- package/dist/views/transfer-template/components/transfer-template-dialog/TransferTemplateDialog.vue.d.ts +8 -0
- package/dist/views/transfer-template/components/transfer-template-form/components/NetSuiteCustomCodeSelection.vue.d.ts +2 -0
- package/dist/views/transfer-template/components/transfer-template-form/composables/use-transfer-locations.d.ts +16 -0
- package/dist/views/transfer-template/composables/use-transfer-template-actions.d.ts +48 -0
- package/dist/views/transfer-template/composables/use-transfer-template-table.d.ts +48 -0
- package/dist/views/unit/UnitView.vue.d.ts +1 -0
- package/dist/views/unit/components/import-units/ImportUnitItem.vue.d.ts +12 -0
- package/dist/views/unit/components/import-units/ImportUnitItemProps.d.ts +6 -0
- package/dist/views/unit/components/import-units/ImportUnits.vue.d.ts +9 -0
- package/dist/views/unit/components/import-units/ImportUnitsProps.d.ts +5 -0
- package/dist/views/unit/helper/import-export.helper.d.ts +40 -0
- package/dist/views/warehouse/components/WarehouseForm.vue.d.ts +8 -0
- package/package.json +3 -3
- package/dist/App-Bs0pR0sL.js +0 -276
- package/dist/ClosingDraftView-Dyr4hrHk.js +0 -1687
- package/dist/ClosingTemplateView-Dw0Lld6E.js +0 -1908
- package/dist/FmAdminBadge-BUJh40aj.js +0 -34
- package/dist/FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-B-p9ffPK.js +0 -224
- package/dist/IngredientsView-61WfWyGy.js +0 -1858
- package/dist/RecipeView-CznjQMrS.js +0 -621
- package/dist/StockForecast.vue_vue_type_style_index_0_lang-KLXSWvo5.js +0 -59
- package/dist/StockView-N-84Q5Ih.js +0 -2086
- package/dist/TransferDetails.vue_vue_type_script_setup_true_lang-BmU-VLNN.js +0 -2336
- package/dist/UnitView-BrLjAWNq.js +0 -667
- package/dist/WarehouseView-CI-RuaPq.js +0 -1034
- package/dist/array-Ca8T3f_G.js +0 -44
- package/dist/helper/core/country/codes.d.ts +0 -255
- package/dist/stock-CIpuon0m.js +0 -146
|
@@ -1,19 +1,18 @@
|
|
|
1
|
-
import { reactive as gt, onMounted as
|
|
2
|
-
import { b as Ue,
|
|
3
|
-
import { u as
|
|
4
|
-
import { _ as Ct, u as ns, i as ls, e as rs } from "./PremiumBadge.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
import { reactive as gt, onMounted as Ke, watch as be, computed as N, h as L, defineComponent as ce, openBlock as S, createElementBlock as T, Fragment as de, renderList as Se, createElementVNode as n, toDisplayString as M, unref as s, resolveComponent as $, createVNode as y, withCtx as A, createCommentVNode as j, ref as q, createBlock as W, normalizeClass as G, normalizeStyle as _t, createTextVNode as Te, nextTick as It, mergeProps as Je, isRef as xe, createSlots as $t, Teleport as Tt, normalizeProps as Dt, guardReactiveProps as Pt } from "vue";
|
|
2
|
+
import { b as Ue, $ as Ge, c as We, r as Me, n as Ce, af as Ye, a0 as Vt, aI as Rt, A as qe, M as At, s as ht, am as et, L as fe, ay as Et, aJ as tt, aK as Ot, aL as Mt, ac as qt, aM as Ut, Q as kt, u as st, a as ot, aN as Nt, aO as Bt, ae as zt, a6 as Lt, aP as Ht, K as xt, x as jt, e as Oe, aQ as Qt, as as Yt, C as Kt, E as Xt, m as Qe, ag as ft, G as Zt, N as Jt, H as Gt, I as Wt, J as es, a2 as vt } from "./app-a9r50k3U.js";
|
|
3
|
+
import { u as ts, P as Ze, a as ss, _ as os, g as as } from "./TransferDetails.vue_vue_type_script_setup_true_lang-c428GXwc.js";
|
|
4
|
+
import { _ as Ct, u as ns, i as ls, e as rs } from "./PremiumBadge.vue_vue_type_script_setup_true_lang-B0OKeK5O.js";
|
|
5
5
|
import { u as is } from "./useTabStorage-BkIVScW_.js";
|
|
6
|
-
import { useBreakpoints as
|
|
7
|
-
import { P as
|
|
8
|
-
import { _ as cs, F as ms, a as ps, b as fs } from "./FmUnitInput.vue_vue_type_script_setup_true_lang-
|
|
9
|
-
import { c as $e, u as vs, _ as ys } from "./FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-
|
|
10
|
-
import { useI18n as
|
|
11
|
-
import "./FmMultiselectDialog-
|
|
12
|
-
import { u as
|
|
6
|
+
import { useBreakpoints as at, components as ye, FmButtonVariant as us, useSnackbar as De, useDialog as ds, useProxiedModel as St } from "@feedmepos/ui-library";
|
|
7
|
+
import { P as ae, u as wt } from "./format-unit-display-BqkHL-ph.js";
|
|
8
|
+
import { _ as cs, F as ms, a as ps, b as fs } from "./FmUnitInput.vue_vue_type_script_setup_true_lang-DwqVRUFz.js";
|
|
9
|
+
import { c as $e, u as vs, _ as ys } from "./FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-WWIrybw_.js";
|
|
10
|
+
import { useI18n as ge } from "@feedmepos/mf-common";
|
|
11
|
+
import "./FmMultiselectDialog-BzWrQOS4.js";
|
|
12
|
+
import { u as nt } from "./supplier-BPPBUudN.js";
|
|
13
13
|
import { _ as bs } from "./PreviewBadge.vue_vue_type_script_setup_true_lang-CRZiQHjx.js";
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
const gs = () => (_e(), L(
|
|
14
|
+
var te = /* @__PURE__ */ ((g) => (g.Code = "Code", g.Name = "Name", g.TemplateName = "TemplateName", g.Amount = "Amount", g.Cost = "Cost", g.TotalCost = "TotalCost", g.Delete = "Delete", g))(te || {});
|
|
15
|
+
const gs = () => (ge(), L(
|
|
17
16
|
Ct,
|
|
18
17
|
{
|
|
19
18
|
zIndex: 50,
|
|
@@ -22,8 +21,8 @@ const gs = () => (_e(), L(
|
|
|
22
21
|
`Total (${ht()})`
|
|
23
22
|
));
|
|
24
23
|
function _s(g) {
|
|
25
|
-
const { t: w } =
|
|
26
|
-
|
|
24
|
+
const { t: w } = ge(), r = gt({}), { breakpoints: p } = at(), x = We(), t = Ue();
|
|
25
|
+
Ke(() => {
|
|
27
26
|
for (const v of g.items) {
|
|
28
27
|
if (!v.totalCost)
|
|
29
28
|
continue;
|
|
@@ -37,7 +36,7 @@ function _s(g) {
|
|
|
37
36
|
), u = v.totalCost ?? Ge.reset();
|
|
38
37
|
e ? r[v.sku._id] = e.amount !== u.amount || e.precision !== u.precision : r[v.sku._id] = !0;
|
|
39
38
|
}
|
|
40
|
-
}),
|
|
39
|
+
}), be([() => g.supplier], ([v]) => {
|
|
41
40
|
for (const e of g.items) {
|
|
42
41
|
if (!e.totalCost || r[e.sku._id] || !f(e.sku))
|
|
43
42
|
continue;
|
|
@@ -65,7 +64,7 @@ function _s(g) {
|
|
|
65
64
|
cell(v) {
|
|
66
65
|
const e = v.row.original;
|
|
67
66
|
return t.isEnabled ? L(
|
|
68
|
-
|
|
67
|
+
ye.FmTooltip,
|
|
69
68
|
{
|
|
70
69
|
content: e.code,
|
|
71
70
|
placement: "top",
|
|
@@ -79,7 +78,7 @@ function _s(g) {
|
|
|
79
78
|
},
|
|
80
79
|
e.code
|
|
81
80
|
)
|
|
82
|
-
) : L(
|
|
81
|
+
) : L(ye.FmTextField, {
|
|
83
82
|
modelValue: e.code,
|
|
84
83
|
"onUpdate:modelValue": (u) => {
|
|
85
84
|
g.updateItem({
|
|
@@ -101,7 +100,7 @@ function _s(g) {
|
|
|
101
100
|
cell(v) {
|
|
102
101
|
const e = v.row.original;
|
|
103
102
|
return t.isEnabled ? L(
|
|
104
|
-
|
|
103
|
+
ye.FmTooltip,
|
|
105
104
|
{
|
|
106
105
|
content: e.name,
|
|
107
106
|
placement: "top",
|
|
@@ -115,7 +114,7 @@ function _s(g) {
|
|
|
115
114
|
},
|
|
116
115
|
e.name
|
|
117
116
|
)
|
|
118
|
-
) : L(
|
|
117
|
+
) : L(ye.FmTextField, {
|
|
119
118
|
modelValue: e.name,
|
|
120
119
|
"onUpdate:modelValue": (u) => {
|
|
121
120
|
g.updateItem({
|
|
@@ -138,7 +137,7 @@ function _s(g) {
|
|
|
138
137
|
cell(v) {
|
|
139
138
|
const e = v.row.original, u = e.code, k = e.name;
|
|
140
139
|
return L(
|
|
141
|
-
|
|
140
|
+
ye.FmTooltip,
|
|
142
141
|
{ zIndex: 50 },
|
|
143
142
|
{
|
|
144
143
|
default() {
|
|
@@ -252,7 +251,7 @@ function _s(g) {
|
|
|
252
251
|
key: e.sku._id
|
|
253
252
|
},
|
|
254
253
|
[
|
|
255
|
-
L(
|
|
254
|
+
L(ye.FmButton, {
|
|
256
255
|
prependIcon: "edit",
|
|
257
256
|
variant: us.Tertiary,
|
|
258
257
|
disabled: g.disabled,
|
|
@@ -271,7 +270,7 @@ function _s(g) {
|
|
|
271
270
|
[
|
|
272
271
|
L(
|
|
273
272
|
"span",
|
|
274
|
-
k ?
|
|
273
|
+
k ? Ye(a) : Ce(a)
|
|
275
274
|
),
|
|
276
275
|
L(
|
|
277
276
|
"span",
|
|
@@ -292,7 +291,7 @@ function _s(g) {
|
|
|
292
291
|
]
|
|
293
292
|
},
|
|
294
293
|
[
|
|
295
|
-
|
|
294
|
+
Ye(i.costPerUnit),
|
|
296
295
|
"/",
|
|
297
296
|
i.measurement ? L(
|
|
298
297
|
"span",
|
|
@@ -308,7 +307,7 @@ function _s(g) {
|
|
|
308
307
|
);
|
|
309
308
|
}
|
|
310
309
|
return L(
|
|
311
|
-
|
|
310
|
+
ye.FmTextField,
|
|
312
311
|
{
|
|
313
312
|
modelValue: Ce(e.totalCost ?? { amount: 0, precision: 0 }),
|
|
314
313
|
key: e.sku._id,
|
|
@@ -316,7 +315,7 @@ function _s(g) {
|
|
|
316
315
|
g.updateItem({
|
|
317
316
|
...e,
|
|
318
317
|
totalCost: {
|
|
319
|
-
...
|
|
318
|
+
...Vt(+a),
|
|
320
319
|
currency: Rt()
|
|
321
320
|
}
|
|
322
321
|
});
|
|
@@ -337,7 +336,7 @@ function _s(g) {
|
|
|
337
336
|
) : null;
|
|
338
337
|
},
|
|
339
338
|
append() {
|
|
340
|
-
return u ? L(
|
|
339
|
+
return u ? L(ye.FmButton, {
|
|
341
340
|
prependIcon: "close",
|
|
342
341
|
variant: "tertiary",
|
|
343
342
|
disabled: g.disabled,
|
|
@@ -370,7 +369,7 @@ function _s(g) {
|
|
|
370
369
|
cell(v) {
|
|
371
370
|
const e = v.row.original;
|
|
372
371
|
return L("div", { class: "flex justify-end" }, [
|
|
373
|
-
L(
|
|
372
|
+
L(ye.FmButton, {
|
|
374
373
|
key: e.sku._id,
|
|
375
374
|
class: "delete-button",
|
|
376
375
|
type: "button",
|
|
@@ -393,7 +392,7 @@ function _s(g) {
|
|
|
393
392
|
}
|
|
394
393
|
];
|
|
395
394
|
return {
|
|
396
|
-
columnDefs: N(() => x.enableTotalCost && g.transferType ===
|
|
395
|
+
columnDefs: N(() => x.enableTotalCost && g.transferType === ae.PURCHASE ? F : F.filter(
|
|
397
396
|
(v) => v.id !== "Cost"
|
|
398
397
|
/* Cost */
|
|
399
398
|
))
|
|
@@ -405,7 +404,7 @@ const hs = { class: "flex flex-col gap-8 px-16 xs:px-4 sm:px-4 py-4 items-center
|
|
|
405
404
|
prices: {}
|
|
406
405
|
},
|
|
407
406
|
setup(g) {
|
|
408
|
-
const w =
|
|
407
|
+
const w = nt();
|
|
409
408
|
function r(p) {
|
|
410
409
|
return w.suppliers.find((x) => x._id === p);
|
|
411
410
|
}
|
|
@@ -419,21 +418,21 @@ const hs = { class: "flex flex-col gap-8 px-16 xs:px-4 sm:px-4 py-4 items-center
|
|
|
419
418
|
n("div", ks, M((f = r(t)) == null ? void 0 : f.name), 1),
|
|
420
419
|
n("div", xs, [
|
|
421
420
|
(S(!0), T(de, null, Se(p.prices[t].slice(0, 3), (F) => {
|
|
422
|
-
var
|
|
421
|
+
var I;
|
|
423
422
|
return S(), T("div", {
|
|
424
423
|
key: F.date,
|
|
425
424
|
class: "flex flex-col w-[150px] xs:flex-1 text-ellipsis cursor-pointer"
|
|
426
425
|
}, [
|
|
427
426
|
n("div", Cs, [
|
|
428
|
-
n("span", null, M(F.totalCost ? s(
|
|
427
|
+
n("span", null, M(F.totalCost ? s(Ye)(F.totalCost) : "No data"), 1),
|
|
429
428
|
x[0] || (x[0] = n("span", { class: "text-fm-color-typo-secondary" }, "/", -1)),
|
|
430
429
|
n("span", null, M(s(Ce)(F.totalUnit, !1)), 1),
|
|
431
|
-
n("span", null, M(((
|
|
430
|
+
n("span", null, M(((I = F.measurement) == null ? void 0 : I.abbrev) ?? F.unit.abbrev), 1)
|
|
432
431
|
]),
|
|
433
432
|
n("div", Ss, [
|
|
434
433
|
n("span", null, "(#" + M(F.seqNumber) + ")", 1),
|
|
435
434
|
x[1] || (x[1] = n("span", null, M(" "), -1)),
|
|
436
|
-
n("span", null, M(s(
|
|
435
|
+
n("span", null, M(s(et)(new Date(F.date))), 1)
|
|
437
436
|
])
|
|
438
437
|
]);
|
|
439
438
|
}), 128))
|
|
@@ -442,7 +441,7 @@ const hs = { class: "flex flex-col gap-8 px-16 xs:px-4 sm:px-4 py-4 items-center
|
|
|
442
441
|
}), 128))
|
|
443
442
|
]));
|
|
444
443
|
}
|
|
445
|
-
}), ws = { class: "flex flex-col gap-8 py-16" }, Fs = { class: "flex items-center" },
|
|
444
|
+
}), ws = { class: "flex flex-col gap-8 py-16" }, Fs = { class: "flex items-center" }, Is = { class: "flex-1 flex gap-1 items-center" }, $s = { class: "fm-typo-en-body-lg-400 text-fm-color-typo-secondary" }, Ts = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary" }, Ds = { class: "flex gap-8 w-full" }, Ps = { class: "flex-1 flex flex-col gap-4" }, Vs = { class: "flex-1 flex flex-col gap-4" }, Rs = { class: "flex gap-8 w-full" }, As = { class: "flex-1 flex flex-col gap-4" }, Es = {
|
|
446
445
|
key: 0,
|
|
447
446
|
class: "flex-1 flex flex-col gap-4"
|
|
448
447
|
}, Os = /* @__PURE__ */ ce({
|
|
@@ -454,41 +453,41 @@ const hs = { class: "flex flex-col gap-8 px-16 xs:px-4 sm:px-4 py-4 items-center
|
|
|
454
453
|
row: {}
|
|
455
454
|
},
|
|
456
455
|
setup(g) {
|
|
457
|
-
const { t: w } =
|
|
456
|
+
const { t: w } = ge();
|
|
458
457
|
return (r, p) => {
|
|
459
|
-
var f, F,
|
|
460
|
-
const x =
|
|
458
|
+
var f, F, I, v, e, u, k, a, i, h, _, C, l, c, D, B, Q, Y, K, O, U, V, d, b, R, X, Z;
|
|
459
|
+
const x = $("FmLabel"), t = $("FmSpacer");
|
|
461
460
|
return S(), T("div", ws, [
|
|
462
461
|
n("div", Fs, [
|
|
463
|
-
n("div",
|
|
464
|
-
n("span",
|
|
462
|
+
n("div", Is, [
|
|
463
|
+
n("span", $s, " (" + M(r.row.original.sku.code) + ") ", 1),
|
|
465
464
|
n("span", Ts, M(r.row.original.sku.name), 1)
|
|
466
465
|
]),
|
|
467
466
|
n("div", null, [
|
|
468
467
|
y(s(fe), {
|
|
469
|
-
render: (
|
|
468
|
+
render: (I = (F = (f = r.cellByColId.Delete) == null ? void 0 : f.column) == null ? void 0 : F.columnDef) == null ? void 0 : I.cell,
|
|
470
469
|
props: (e = (v = r.cellByColId.Delete) == null ? void 0 : v.getContext) == null ? void 0 : e.call(v)
|
|
471
470
|
}, null, 8, ["render", "props"])
|
|
472
471
|
])
|
|
473
472
|
]),
|
|
474
473
|
n("div", Ds, [
|
|
475
|
-
n("div",
|
|
474
|
+
n("div", Ps, [
|
|
476
475
|
y(x, {
|
|
477
|
-
label: s(w)(`inventory.transfer.form.items.table.${s(
|
|
476
|
+
label: s(w)(`inventory.transfer.form.items.table.${s(te).Code}`)
|
|
478
477
|
}, null, 8, ["label"]),
|
|
479
478
|
y(s(fe), {
|
|
480
|
-
render: (a = (k = (u = r.cellByColId[s(
|
|
481
|
-
props: (h = (i = r.cellByColId[s(
|
|
479
|
+
render: (a = (k = (u = r.cellByColId[s(te).Code]) == null ? void 0 : u.column) == null ? void 0 : k.columnDef) == null ? void 0 : a.cell,
|
|
480
|
+
props: (h = (i = r.cellByColId[s(te).Code]) == null ? void 0 : i.getContext) == null ? void 0 : h.call(i)
|
|
482
481
|
}, null, 8, ["render", "props"]),
|
|
483
482
|
p[0] || (p[0] = n("div", { class: "fm-typo-en-body-md-600 text-fm-color-primary" }, null, -1))
|
|
484
483
|
]),
|
|
485
|
-
n("div",
|
|
484
|
+
n("div", Vs, [
|
|
486
485
|
y(x, {
|
|
487
|
-
label: s(w)(`inventory.transfer.form.items.table.${s(
|
|
486
|
+
label: s(w)(`inventory.transfer.form.items.table.${s(te).Name}`)
|
|
488
487
|
}, null, 8, ["label"]),
|
|
489
488
|
y(s(fe), {
|
|
490
|
-
render: (l = (C = (_ = r.cellByColId[s(
|
|
491
|
-
props: (D = (c = r.cellByColId[s(
|
|
489
|
+
render: (l = (C = (_ = r.cellByColId[s(te).Name]) == null ? void 0 : _.column) == null ? void 0 : C.columnDef) == null ? void 0 : l.cell,
|
|
490
|
+
props: (D = (c = r.cellByColId[s(te).Name]) == null ? void 0 : c.getContext) == null ? void 0 : D.call(c)
|
|
492
491
|
}, null, 8, ["render", "props"]),
|
|
493
492
|
p[1] || (p[1] = n("div", { class: "fm-typo-en-body-md-600 text-fm-color-primary" }, null, -1))
|
|
494
493
|
])
|
|
@@ -496,26 +495,26 @@ const hs = { class: "flex flex-col gap-8 px-16 xs:px-4 sm:px-4 py-4 items-center
|
|
|
496
495
|
n("div", Rs, [
|
|
497
496
|
n("div", As, [
|
|
498
497
|
y(x, {
|
|
499
|
-
label: s(w)(`inventory.transfer.form.items.table.${s(
|
|
498
|
+
label: s(w)(`inventory.transfer.form.items.table.${s(te).Amount}`)
|
|
500
499
|
}, null, 8, ["label"]),
|
|
501
500
|
y(s(fe), {
|
|
502
|
-
render: (Y = (Q = (B = r.cellByColId[s(
|
|
503
|
-
props: (O = (K = r.cellByColId[s(
|
|
501
|
+
render: (Y = (Q = (B = r.cellByColId[s(te).Amount]) == null ? void 0 : B.column) == null ? void 0 : Q.columnDef) == null ? void 0 : Y.cell,
|
|
502
|
+
props: (O = (K = r.cellByColId[s(te).Amount]) == null ? void 0 : K.getContext) == null ? void 0 : O.call(K)
|
|
504
503
|
}, null, 8, ["render", "props"]),
|
|
505
504
|
p[2] || (p[2] = n("div", { class: "fm-typo-en-body-md-600 text-fm-color-primary" }, null, -1))
|
|
506
505
|
]),
|
|
507
|
-
r.cellByColId[s(
|
|
506
|
+
r.cellByColId[s(te).Cost] ? (S(), T("div", Es, [
|
|
508
507
|
y(Ct, { "z-index": 50 }, {
|
|
509
508
|
default: A(() => [
|
|
510
509
|
y(x, {
|
|
511
|
-
label: s(w)(`inventory.transfer.form.items.table.${s(
|
|
510
|
+
label: s(w)(`inventory.transfer.form.items.table.${s(te).Cost}2`)
|
|
512
511
|
}, null, 8, ["label"])
|
|
513
512
|
]),
|
|
514
513
|
_: 1
|
|
515
514
|
}),
|
|
516
515
|
y(s(fe), {
|
|
517
|
-
render: (d = (
|
|
518
|
-
props: (R = (b = r.cellByColId[s(
|
|
516
|
+
render: (d = (V = (U = r.cellByColId[s(te).Cost]) == null ? void 0 : U.column) == null ? void 0 : V.columnDef) == null ? void 0 : d.cell,
|
|
517
|
+
props: (R = (b = r.cellByColId[s(te).Cost]) == null ? void 0 : b.getContext) == null ? void 0 : R.call(b)
|
|
519
518
|
}, null, 8, ["render", "props"]),
|
|
520
519
|
p[3] || (p[3] = n("div", { class: "fm-typo-en-body-md-600 text-fm-color-primary" }, null, -1))
|
|
521
520
|
])) : j("", !0)
|
|
@@ -548,7 +547,7 @@ function Ms(g) {
|
|
|
548
547
|
}
|
|
549
548
|
}), p = N({
|
|
550
549
|
get() {
|
|
551
|
-
return w.value === null ? "" :
|
|
550
|
+
return w.value === null ? "" : et(w.value);
|
|
552
551
|
},
|
|
553
552
|
set(t) {
|
|
554
553
|
t ? w.value = /* @__PURE__ */ new Date(`${t} ${x.value}`) : w.value = null;
|
|
@@ -612,7 +611,7 @@ const qs = {
|
|
|
612
611
|
}, null, 8, zs)
|
|
613
612
|
]));
|
|
614
613
|
}
|
|
615
|
-
}), Hs = { class: "flex gap-8 items-center" }, js = { class: "fm-typo-en-body-lg-600 line-clamp-1" }, Qs = { class: "w-[343px] px-24 py-16 rounded-lg shadow-light-300 flex flex-col gap-[20px]" }, Ys = { class: "flex items-center w-full" }, Ks = { class: "flex-1" }, Xs = { class: "fm-typo-en-title-sm-800" }, Zs = { class: "flex items-start gap-8" },
|
|
614
|
+
}), Hs = { class: "flex gap-8 items-center" }, js = { class: "fm-typo-en-body-lg-600 line-clamp-1" }, Qs = { class: "w-[343px] px-24 py-16 rounded-lg shadow-light-300 flex flex-col gap-[20px]" }, Ys = { class: "flex items-center w-full" }, Ks = { class: "flex-1" }, Xs = { class: "fm-typo-en-title-sm-800" }, Zs = { class: "flex items-start gap-8" }, Js = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary" }, Gs = { class: "flex gap-1" }, Ws = /* @__PURE__ */ ce({
|
|
616
615
|
__name: "ForecastStock",
|
|
617
616
|
props: {
|
|
618
617
|
templateId: {},
|
|
@@ -622,7 +621,7 @@ const qs = {
|
|
|
622
621
|
},
|
|
623
622
|
emits: ["update:poItems", "update:forecastAmounts"],
|
|
624
623
|
setup(g, { emit: w }) {
|
|
625
|
-
const r = g, p = w, x = q(!1), t = q(7), f = ns(), F =
|
|
624
|
+
const r = g, p = w, x = q(!1), t = q(7), f = ns(), F = De(), { t: I } = ge();
|
|
626
625
|
function v(a, i, h) {
|
|
627
626
|
return i != null && a < i && (a = i), h != null && a > h && (a = h), a;
|
|
628
627
|
}
|
|
@@ -666,7 +665,7 @@ const qs = {
|
|
|
666
665
|
const a = f.purchaseOrderForecast.skus;
|
|
667
666
|
if (a.length === 0) {
|
|
668
667
|
F.open({
|
|
669
|
-
message:
|
|
668
|
+
message: I("inventory.transfer.form.items.forecastStock.notAvailable"),
|
|
670
669
|
type: "info"
|
|
671
670
|
});
|
|
672
671
|
return;
|
|
@@ -703,8 +702,8 @@ const qs = {
|
|
|
703
702
|
p("update:poItems", i), p("update:forecastAmounts", h);
|
|
704
703
|
}
|
|
705
704
|
return (a, i) => {
|
|
706
|
-
const h =
|
|
707
|
-
return S(),
|
|
705
|
+
const h = $("FmButton"), _ = $("FmIcon"), C = $("FmStepperField"), l = $("FmPopover");
|
|
706
|
+
return S(), W(l, {
|
|
708
707
|
disabled: a.disabled,
|
|
709
708
|
class: "flex",
|
|
710
709
|
"show-popover": x.value,
|
|
@@ -725,7 +724,7 @@ const qs = {
|
|
|
725
724
|
size: 24,
|
|
726
725
|
color: a.disabled ? "#c7c7cc" : "#ff7823"
|
|
727
726
|
}, null, 8, ["color"]),
|
|
728
|
-
n("div", js, M(s(
|
|
727
|
+
n("div", js, M(s(I)("inventory.transfer.form.items.forecastStock.title")), 1)
|
|
729
728
|
])
|
|
730
729
|
]),
|
|
731
730
|
_: 1
|
|
@@ -737,7 +736,7 @@ const qs = {
|
|
|
737
736
|
n("div", Ks, [
|
|
738
737
|
y(bs, { "z-index": 99 }, {
|
|
739
738
|
default: A(() => [
|
|
740
|
-
n("p", Xs, M(s(
|
|
739
|
+
n("p", Xs, M(s(I)("inventory.transfer.form.items.forecastStock.title")), 1)
|
|
741
740
|
]),
|
|
742
741
|
_: 1
|
|
743
742
|
})
|
|
@@ -752,7 +751,7 @@ const qs = {
|
|
|
752
751
|
y(C, {
|
|
753
752
|
modelValue: t.value,
|
|
754
753
|
"onUpdate:modelValue": i[1] || (i[1] = (c) => t.value = c),
|
|
755
|
-
label: s(
|
|
754
|
+
label: s(I)("inventory.transfer.form.items.forecastStock.days"),
|
|
756
755
|
rules: [s(qe)(1)]
|
|
757
756
|
}, {
|
|
758
757
|
"helper-text": A(() => [
|
|
@@ -762,20 +761,20 @@ const qs = {
|
|
|
762
761
|
size: "sm",
|
|
763
762
|
class: "text-fm-color-system-warning-300"
|
|
764
763
|
}),
|
|
765
|
-
n("div",
|
|
764
|
+
n("div", Js, M(s(I)("inventory.transfer.form.items.forecastStock.replace")), 1)
|
|
766
765
|
])
|
|
767
766
|
]),
|
|
768
767
|
_: 1
|
|
769
768
|
}, 8, ["modelValue", "label", "rules"]),
|
|
770
|
-
n("div",
|
|
769
|
+
n("div", Gs, [
|
|
771
770
|
i[4] || (i[4] = n("div", { class: "grow" }, null, -1)),
|
|
772
771
|
y(h, {
|
|
773
|
-
label: s(
|
|
772
|
+
label: s(I)("common.cancel"),
|
|
774
773
|
variant: "tertiary",
|
|
775
774
|
onClick: i[2] || (i[2] = (c) => x.value = !1)
|
|
776
775
|
}, null, 8, ["label"]),
|
|
777
776
|
y(h, {
|
|
778
|
-
label: s(
|
|
777
|
+
label: s(I)("inventory.transfer.form.items.forecastStock.generate"),
|
|
779
778
|
onClick: k
|
|
780
779
|
}, null, 8, ["label"])
|
|
781
780
|
])
|
|
@@ -787,8 +786,8 @@ const qs = {
|
|
|
787
786
|
}
|
|
788
787
|
});
|
|
789
788
|
function eo() {
|
|
790
|
-
const g =
|
|
791
|
-
|
|
789
|
+
const g = De(), w = tt(), r = q(!1);
|
|
790
|
+
be(r, (f) => {
|
|
792
791
|
f && (x.value = !0, p().finally(() => {
|
|
793
792
|
x.value = !1;
|
|
794
793
|
}));
|
|
@@ -849,17 +848,17 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
849
848
|
var x, t;
|
|
850
849
|
return S(), T(de, null, [
|
|
851
850
|
n("tr", {
|
|
852
|
-
class:
|
|
851
|
+
class: G(["border-b border-fm-color-neutral-gray-100 hover:bg-fm-color-opacity-sm", {
|
|
853
852
|
"bg-fm-color-neutral-gray-100": r.row.getIsSelected()
|
|
854
853
|
}])
|
|
855
854
|
}, [
|
|
856
855
|
(S(!0), T(de, null, Se(r.row.getVisibleCells(), (f) => {
|
|
857
|
-
var F,
|
|
856
|
+
var F, I, v, e;
|
|
858
857
|
return S(), T("td", {
|
|
859
858
|
key: f.id,
|
|
860
|
-
class:
|
|
859
|
+
class: G(["h-[56px] text-fm-color-typo-primary", ((F = w(f)) == null ? void 0 : F.cellClass) ?? "px-16"]),
|
|
861
860
|
style: _t({
|
|
862
|
-
width: (
|
|
861
|
+
width: (I = w(f)) == null ? void 0 : I.width,
|
|
863
862
|
maxWidth: (v = w(f)) == null ? void 0 : v.maxWidth,
|
|
864
863
|
textAlign: ((e = w(f)) == null ? void 0 : e.textAlign) ?? "left"
|
|
865
864
|
})
|
|
@@ -904,7 +903,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
904
903
|
emits: ["netsuite:ready"],
|
|
905
904
|
setup(g, { emit: w }) {
|
|
906
905
|
const r = Ue(), p = g, x = w, { t } = Ut(), f = q(!1), F = q();
|
|
907
|
-
|
|
906
|
+
Ke(() => {
|
|
908
907
|
var u, k, a, i;
|
|
909
908
|
let e = {
|
|
910
909
|
id: "",
|
|
@@ -952,7 +951,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
952
951
|
!r.isEnabled || h && r.isEnabled && h == _ ? x("netsuite:ready", e) : f.value = !0;
|
|
953
952
|
}
|
|
954
953
|
});
|
|
955
|
-
const
|
|
954
|
+
const I = N(
|
|
956
955
|
() => p.supplier.internal ? r.currentLocationSubsidiary() : r.currentVendorSubsidiary(p.supplier._id)
|
|
957
956
|
), v = N(() => {
|
|
958
957
|
var e, u;
|
|
@@ -960,7 +959,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
960
959
|
location is ${(u = r.getLocationSubsidiary((e = F.value) == null ? void 0 : e.netSuiteId)) == null ? void 0 : u.fullName}`;
|
|
961
960
|
});
|
|
962
961
|
return (e, u) => {
|
|
963
|
-
const k =
|
|
962
|
+
const k = $("FmLabel"), a = $("FmIcon"), i = $("FmField"), h = $("FmTooltip");
|
|
964
963
|
return s(r).isEnabled && p.required ? (S(), T("div", no, [
|
|
965
964
|
y(k, {
|
|
966
965
|
label: `NetSuite ${s(t)("inventory.transfer.form.netsuite.subsidiary")}`
|
|
@@ -972,7 +971,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
972
971
|
disabled: e.disabled
|
|
973
972
|
}, {
|
|
974
973
|
content: A(() => u[0] || (u[0] = [
|
|
975
|
-
|
|
974
|
+
Te("This field is locked and based on the location of the request.")
|
|
976
975
|
])),
|
|
977
976
|
default: A(() => [
|
|
978
977
|
y(i, null, {
|
|
@@ -986,8 +985,8 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
986
985
|
color: e.disabled ? "neutral-gray-200" : "neutral-gray-400"
|
|
987
986
|
}, null, 8, ["color"]),
|
|
988
987
|
n("div", {
|
|
989
|
-
class:
|
|
990
|
-
}, M((_ =
|
|
988
|
+
class: G([e.disabled ? "text-fm-color-typo-disabled" : ""])
|
|
989
|
+
}, M((_ = I.value) == null ? void 0 : _.fullName), 3)
|
|
991
990
|
])
|
|
992
991
|
];
|
|
993
992
|
}),
|
|
@@ -1010,7 +1009,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1010
1009
|
}, Co = { class: "flex-1" }, So = { class: "flex-1" }, wo = {
|
|
1011
1010
|
key: 1,
|
|
1012
1011
|
class: "flex items-center gap-4"
|
|
1013
|
-
}, Fo = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary translate-y-[1px]" },
|
|
1012
|
+
}, Fo = { class: "fm-typo-en-body-sm-400 text-fm-color-typo-secondary translate-y-[1px]" }, Io = { class: "flex flex-col gap-16" }, $o = { class: "flex-1 gap-8 fm-typo-en-title-sm-600" }, To = { class: "flex gap-8" }, Do = { key: 0 }, Po = /* @__PURE__ */ ce({
|
|
1014
1013
|
__name: "TransferForm2",
|
|
1015
1014
|
props: {
|
|
1016
1015
|
modelValue: {},
|
|
@@ -1022,7 +1021,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1022
1021
|
},
|
|
1023
1022
|
emits: ["validation-success", "form:ready"],
|
|
1024
1023
|
setup(g, { expose: w, emit: r }) {
|
|
1025
|
-
const p = g, x = r, t = kt(), { t: f } =
|
|
1024
|
+
const p = g, x = r, t = kt(), { t: f } = ge(), F = st(), I = ot(), v = Ue(), e = nt(), u = We(), k = wt(), { breakpoints: a } = at(), i = N(() => a.value.xs || a.value.sm), h = gt({
|
|
1026
1025
|
value: !1
|
|
1027
1026
|
}), _ = q(!1), C = q(0), l = q([]), c = N(
|
|
1028
1027
|
() => {
|
|
@@ -1030,7 +1029,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1030
1029
|
return ((o = p.modelValue) == null ? void 0 : o.templateDoc) ?? k.templates.find((m) => m._id === t.template);
|
|
1031
1030
|
}
|
|
1032
1031
|
), D = N(() => t.status === "DRAFT" || !t._rev);
|
|
1033
|
-
|
|
1032
|
+
be(c, (o) => {
|
|
1034
1033
|
var m, E;
|
|
1035
1034
|
if (o) {
|
|
1036
1035
|
if (o && !o.purchaseOrder.supplier)
|
|
@@ -1038,44 +1037,45 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1038
1037
|
if (D.value) {
|
|
1039
1038
|
const H = (m = o.purchaseOrder) == null ? void 0 : m.supplier.internal;
|
|
1040
1039
|
if (H && (H == "restaurant" || H == "warehouse")) {
|
|
1041
|
-
const
|
|
1042
|
-
(
|
|
1040
|
+
const ne = (E = o.purchaseOrder) == null ? void 0 : E.supplier._id, me = `${H}_${ne}`, J = F.allLocations.find(
|
|
1041
|
+
(le) => le.type === H && le.dbName === me
|
|
1043
1042
|
);
|
|
1044
|
-
if (
|
|
1045
|
-
const
|
|
1043
|
+
if (J) {
|
|
1044
|
+
const le = {
|
|
1046
1045
|
...o.purchaseOrder.supplier,
|
|
1047
|
-
name:
|
|
1048
|
-
contactName:
|
|
1049
|
-
email:
|
|
1050
|
-
phoneNumber:
|
|
1051
|
-
registrationNumber:
|
|
1052
|
-
address:
|
|
1046
|
+
name: J.doc.profile.name,
|
|
1047
|
+
contactName: J.doc.profile.name,
|
|
1048
|
+
email: J.doc.profile.email,
|
|
1049
|
+
phoneNumber: J.doc.profile.phoneNo,
|
|
1050
|
+
registrationNumber: J.doc.profile.regNo,
|
|
1051
|
+
address: J.doc.profile.address,
|
|
1052
|
+
preparationTime: J.preparationTime
|
|
1053
1053
|
};
|
|
1054
|
-
t.supplier =
|
|
1054
|
+
t.supplier = le;
|
|
1055
1055
|
}
|
|
1056
1056
|
} else {
|
|
1057
|
-
const
|
|
1057
|
+
const ne = e.suppliers.find(
|
|
1058
1058
|
(me) => {
|
|
1059
|
-
var
|
|
1060
|
-
return me._id === ((
|
|
1059
|
+
var J;
|
|
1060
|
+
return me._id === ((J = o.purchaseOrder.supplier) == null ? void 0 : J._id);
|
|
1061
1061
|
}
|
|
1062
1062
|
);
|
|
1063
|
-
t.supplier =
|
|
1063
|
+
t.supplier = ne ?? t.supplier;
|
|
1064
1064
|
}
|
|
1065
1065
|
if (!t.supplier)
|
|
1066
1066
|
throw new Error("Unable to resolve supplier from template");
|
|
1067
1067
|
}
|
|
1068
1068
|
}
|
|
1069
|
-
}),
|
|
1069
|
+
}), Ke(() => {
|
|
1070
1070
|
var o;
|
|
1071
1071
|
try {
|
|
1072
|
-
const m =
|
|
1072
|
+
const m = I.skuById;
|
|
1073
1073
|
let E = t.items.map((H) => ({ ...H, id: H.id ?? H.sku._id }));
|
|
1074
1074
|
t.template && (t.items.length || (E = ((o = c.value) == null ? void 0 : o.purchaseOrder.items) ?? [])), t.items = E.filter((H) => !m[H.sku._id].isInactive);
|
|
1075
1075
|
} finally {
|
|
1076
1076
|
_.value = !0;
|
|
1077
1077
|
}
|
|
1078
|
-
}),
|
|
1078
|
+
}), be([_, h], ([o, m], [E, H]) => {
|
|
1079
1079
|
m.value && H.value && x("form:ready");
|
|
1080
1080
|
});
|
|
1081
1081
|
const B = N(
|
|
@@ -1094,21 +1094,21 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1094
1094
|
), K = N({
|
|
1095
1095
|
get() {
|
|
1096
1096
|
var o;
|
|
1097
|
-
return typeof ((o = t == null ? void 0 : t.supplier) == null ? void 0 : o.internal) == "string" ?
|
|
1097
|
+
return typeof ((o = t == null ? void 0 : t.supplier) == null ? void 0 : o.internal) == "string" ? ae.TRANSFER : ae.PURCHASE;
|
|
1098
1098
|
},
|
|
1099
1099
|
set(o) {
|
|
1100
1100
|
var E;
|
|
1101
|
-
const m = typeof ((E = t == null ? void 0 : t.supplier) == null ? void 0 : E.internal) == "string" ?
|
|
1102
|
-
o !== m && (t.supplier = o ===
|
|
1101
|
+
const m = typeof ((E = t == null ? void 0 : t.supplier) == null ? void 0 : E.internal) == "string" ? ae.TRANSFER : ae.PURCHASE;
|
|
1102
|
+
o !== m && (t.supplier = o === ae.PURCHASE ? Y.locationOptionsTypePurchase.value[0] : Y.locationOptionsTypeTransfer.value[0]);
|
|
1103
1103
|
}
|
|
1104
1104
|
});
|
|
1105
|
-
|
|
1105
|
+
be(
|
|
1106
1106
|
() => {
|
|
1107
1107
|
var o;
|
|
1108
1108
|
return (o = p.modelValue) == null ? void 0 : o.template;
|
|
1109
1109
|
},
|
|
1110
1110
|
(o) => {
|
|
1111
|
-
u.mustUsePoTemplate && !o &&
|
|
1111
|
+
u.mustUsePoTemplate && !o && It(() => {
|
|
1112
1112
|
var m, E;
|
|
1113
1113
|
t.supplier = ((E = (m = Y.locationOptionsTypeTransfer.value) == null ? void 0 : m.filter(
|
|
1114
1114
|
(H) => H.internal === "restaurant"
|
|
@@ -1131,7 +1131,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1131
1131
|
set(o) {
|
|
1132
1132
|
Y.transferLocationModel.value = o;
|
|
1133
1133
|
}
|
|
1134
|
-
}),
|
|
1134
|
+
}), V = N({
|
|
1135
1135
|
get() {
|
|
1136
1136
|
return t.remark ?? void 0;
|
|
1137
1137
|
},
|
|
@@ -1145,19 +1145,19 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1145
1145
|
setEffectiveAt(o) {
|
|
1146
1146
|
t.effectiveAt = o;
|
|
1147
1147
|
}
|
|
1148
|
-
}), { comparePricesToggle: Z, comparePriceFetching: he, comparePriceBySku: ke } = eo(),
|
|
1148
|
+
}), { comparePricesToggle: Z, comparePriceFetching: he, comparePriceBySku: ke } = eo(), re = q();
|
|
1149
1149
|
w({
|
|
1150
1150
|
validateInputs: () => {
|
|
1151
1151
|
var o, m;
|
|
1152
|
-
(m = (o =
|
|
1152
|
+
(m = (o = re.value) == null ? void 0 : o.validateInputs) == null || m.call(o);
|
|
1153
1153
|
},
|
|
1154
1154
|
resetInputsValidation: () => {
|
|
1155
1155
|
var o, m;
|
|
1156
|
-
(m = (o =
|
|
1156
|
+
(m = (o = re.value) == null ? void 0 : o.resetInputsValidation) == null || m.call(o);
|
|
1157
1157
|
},
|
|
1158
1158
|
resetInputs: () => {
|
|
1159
1159
|
var o, m;
|
|
1160
|
-
(m = (o =
|
|
1160
|
+
(m = (o = re.value) == null ? void 0 : o.resetInputs) == null || m.call(o);
|
|
1161
1161
|
}
|
|
1162
1162
|
});
|
|
1163
1163
|
const we = N(() => ({
|
|
@@ -1193,43 +1193,51 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1193
1193
|
}
|
|
1194
1194
|
}), Be = N(() => Ne.columnDefs.value);
|
|
1195
1195
|
function ze() {
|
|
1196
|
-
var
|
|
1197
|
-
const o = (
|
|
1198
|
-
var
|
|
1199
|
-
const
|
|
1196
|
+
var le, Fe, He, Ae, je;
|
|
1197
|
+
const o = (He = (Fe = (le = c.value) == null ? void 0 : le.purchaseOrder) == null ? void 0 : Fe.items) == null ? void 0 : He.groupBy((z) => z.sku._id), m = v.isEnabled ? v.getAvailableItems((je = (Ae = t.netSuite) == null ? void 0 : Ae.subsidiary) == null ? void 0 : je.id) : [], E = o != null && o.size ? I.skus.filter((z) => o.has(z._id)) : I.skus, H = v.isEnabled ? E.filter((z) => {
|
|
1198
|
+
var ie, se, ue, pe;
|
|
1199
|
+
const ee = (se = (ie = c.value) == null ? void 0 : ie.purchaseOrder) == null ? void 0 : se.items.find(
|
|
1200
1200
|
(ve) => ve.sku._id === z._id
|
|
1201
1201
|
);
|
|
1202
|
-
if (
|
|
1202
|
+
if (ee != null && ee.measurement != null) {
|
|
1203
1203
|
const ve = v.getAvailableMeasurements(
|
|
1204
|
-
|
|
1204
|
+
ee.sku._id,
|
|
1205
1205
|
(pe = (ue = t.netSuite) == null ? void 0 : ue.subsidiary) == null ? void 0 : pe.id
|
|
1206
1206
|
);
|
|
1207
|
-
return m.includes(
|
|
1207
|
+
return m.includes(ee.sku._id) && ve.includes(ee.measurement.id);
|
|
1208
1208
|
}
|
|
1209
1209
|
return m.includes(z._id);
|
|
1210
|
-
}).map((z) => z._id) : E.map((z) => z._id),
|
|
1210
|
+
}).map((z) => z._id) : E.map((z) => z._id), ne = E.map(
|
|
1211
1211
|
(z) => {
|
|
1212
|
-
var
|
|
1212
|
+
var ee, ie, se, ue;
|
|
1213
1213
|
return {
|
|
1214
|
-
label: ((
|
|
1214
|
+
label: ((ie = (ee = o == null ? void 0 : o.get(z._id)) == null ? void 0 : ee[0]) == null ? void 0 : ie.name) ?? z.name,
|
|
1215
1215
|
sublabel: ((ue = (se = o == null ? void 0 : o.get(z._id)) == null ? void 0 : se[0]) == null ? void 0 : ue.code) ?? z.code,
|
|
1216
1216
|
value: z,
|
|
1217
1217
|
disabled: !!(!H.includes(z._id) || z.isInactive),
|
|
1218
|
-
tags: z.isInactive ? ["Inactive"] : []
|
|
1218
|
+
tags: z.isInactive ? ["Inactive"] : ["Active"]
|
|
1219
1219
|
};
|
|
1220
1220
|
}
|
|
1221
|
-
), me =
|
|
1222
|
-
var
|
|
1223
|
-
return (
|
|
1224
|
-
}).map((z) => z.value)
|
|
1221
|
+
), me = ne.filter((z) => {
|
|
1222
|
+
var ee;
|
|
1223
|
+
return (ee = t.items) == null ? void 0 : ee.find((ie) => ie.sku._id === z.value._id);
|
|
1224
|
+
}).map((z) => z.value), J = [
|
|
1225
|
+
{
|
|
1226
|
+
type: "string",
|
|
1227
|
+
key: "tags",
|
|
1228
|
+
entity: "item",
|
|
1229
|
+
values: ["Inactive", "Active"]
|
|
1230
|
+
}
|
|
1231
|
+
];
|
|
1225
1232
|
Q.open({
|
|
1226
1233
|
title: f("inventory.transfer.form.items.selectItem"),
|
|
1227
1234
|
closeButton: !0,
|
|
1228
1235
|
contentComponent: jt,
|
|
1229
1236
|
contentComponentProps: {
|
|
1230
1237
|
modelValue: me,
|
|
1231
|
-
items:
|
|
1232
|
-
virtualScroll: !0
|
|
1238
|
+
items: ne,
|
|
1239
|
+
virtualScroll: !0,
|
|
1240
|
+
filterAttributes: J
|
|
1233
1241
|
},
|
|
1234
1242
|
primaryActions: {
|
|
1235
1243
|
text: f("common.confirm"),
|
|
@@ -1241,13 +1249,13 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1241
1249
|
variant: "tertiary"
|
|
1242
1250
|
}
|
|
1243
1251
|
}).onPrimary((z) => {
|
|
1244
|
-
const
|
|
1245
|
-
var ve,
|
|
1246
|
-
const ue =
|
|
1252
|
+
const ee = t.items ?? [], ie = z.map((se) => {
|
|
1253
|
+
var ve, Ie;
|
|
1254
|
+
const ue = ee.find((_e) => _e.sku._id === se._id);
|
|
1247
1255
|
if (ue)
|
|
1248
1256
|
return ue;
|
|
1249
|
-
const pe = ((
|
|
1250
|
-
(
|
|
1257
|
+
const pe = ((Ie = (ve = c.value) == null ? void 0 : ve.purchaseOrder.items) == null ? void 0 : Ie.find(
|
|
1258
|
+
(_e) => _e.sku._id === se._id
|
|
1251
1259
|
)) ?? {
|
|
1252
1260
|
sku: se,
|
|
1253
1261
|
code: se.code,
|
|
@@ -1257,8 +1265,8 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1257
1265
|
precision: 0
|
|
1258
1266
|
}
|
|
1259
1267
|
};
|
|
1260
|
-
if (K.value ==
|
|
1261
|
-
const { cost:
|
|
1268
|
+
if (K.value == ae.PURCHASE) {
|
|
1269
|
+
const { cost: _e } = $e(
|
|
1262
1270
|
pe.sku,
|
|
1263
1271
|
pe.quantity,
|
|
1264
1272
|
pe.measurement,
|
|
@@ -1266,19 +1274,19 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1266
1274
|
supplier: t.supplier
|
|
1267
1275
|
}
|
|
1268
1276
|
);
|
|
1269
|
-
pe.totalCost =
|
|
1277
|
+
pe.totalCost = _e;
|
|
1270
1278
|
}
|
|
1271
1279
|
return pe;
|
|
1272
1280
|
});
|
|
1273
|
-
|
|
1281
|
+
ie.sort((se, ue) => se.sku.code.localeCompare(ue.sku.code)), t.items = ie;
|
|
1274
1282
|
});
|
|
1275
1283
|
}
|
|
1276
|
-
function
|
|
1284
|
+
function Pe(o) {
|
|
1277
1285
|
return o;
|
|
1278
1286
|
}
|
|
1279
1287
|
const Le = N(() => {
|
|
1280
1288
|
var o;
|
|
1281
|
-
return c.value ? ((o = c.value) == null ? void 0 : o.purchaseOrder.items) || [] :
|
|
1289
|
+
return c.value ? ((o = c.value) == null ? void 0 : o.purchaseOrder.items) || [] : I.skus.map((m) => ({
|
|
1282
1290
|
quantity: {
|
|
1283
1291
|
amount: 0,
|
|
1284
1292
|
precision: 0
|
|
@@ -1296,24 +1304,24 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1296
1304
|
const o = [];
|
|
1297
1305
|
return (!u.mustUsePoTemplate || u.mustUsePoTemplate && t.template) && o.push({
|
|
1298
1306
|
label: f("inventory.transfer.form.type.purchase"),
|
|
1299
|
-
value:
|
|
1307
|
+
value: ae.PURCHASE
|
|
1300
1308
|
}), o.push({
|
|
1301
1309
|
label: f("inventory.transfer.form.type.transfer"),
|
|
1302
|
-
value:
|
|
1310
|
+
value: ae.TRANSFER
|
|
1303
1311
|
}), o;
|
|
1304
|
-
}),
|
|
1312
|
+
}), Re = N(() => {
|
|
1305
1313
|
var o;
|
|
1306
1314
|
return (o = p.modelValue) == null ? void 0 : o.items.every((m) => m.quantity.amount <= 0);
|
|
1307
1315
|
});
|
|
1308
1316
|
return (o, m) => {
|
|
1309
|
-
var
|
|
1310
|
-
const E =
|
|
1317
|
+
var pe, ve;
|
|
1318
|
+
const E = $("FmChip"), H = $("FmLabel"), ne = $("FmIcon"), me = $("FmField"), J = $("FmTooltip"), le = $("FmSelect"), Fe = $("FmTextField"), He = $("FmTextarea"), Ae = $("FmSwitch"), je = $("FmDatePicker"), z = $("FmTimePicker"), ee = $("FmFormGroup"), ie = $("FmButton"), se = $("FmTable"), ue = $("FmForm");
|
|
1311
1319
|
return S(), T("div", co, [
|
|
1312
1320
|
n("div", mo, [
|
|
1313
|
-
(
|
|
1321
|
+
(pe = p.modelValue) != null && pe.template ? (S(), W(E, {
|
|
1314
1322
|
key: 0,
|
|
1315
1323
|
variant: o.disabled ? "warning" : void 0,
|
|
1316
|
-
label: `${s(f)("inventory.transfer.template.title")}: ${((
|
|
1324
|
+
label: `${s(f)("inventory.transfer.template.title")}: ${((ve = c.value) == null ? void 0 : ve.name) ?? s(f)("inventory.transfer.form.loading")}`,
|
|
1317
1325
|
icon: "summarize",
|
|
1318
1326
|
compact: ""
|
|
1319
1327
|
}, null, 8, ["variant", "label"])) : j("", !0),
|
|
@@ -1322,51 +1330,51 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1322
1330
|
icon: "storefront",
|
|
1323
1331
|
compact: ""
|
|
1324
1332
|
}, null, 8, ["label"]),
|
|
1325
|
-
o.lastClosingDate ? (S(),
|
|
1333
|
+
o.lastClosingDate ? (S(), W(E, {
|
|
1326
1334
|
key: 1,
|
|
1327
|
-
label: `${s(f)("inventory.transfer.form.lastClosing")}: ${s(
|
|
1335
|
+
label: `${s(f)("inventory.transfer.form.lastClosing")}: ${s(et)(o.lastClosingDate)} ${s(zt)(o.lastClosingDate)}`,
|
|
1328
1336
|
icon: "calendar_month",
|
|
1329
1337
|
compact: ""
|
|
1330
1338
|
}, null, 8, ["label"])) : j("", !0)
|
|
1331
1339
|
]),
|
|
1332
|
-
y(
|
|
1340
|
+
y(ue, {
|
|
1333
1341
|
ref_key: "formRef",
|
|
1334
|
-
ref:
|
|
1342
|
+
ref: re,
|
|
1335
1343
|
class: "flex flex-col gap-32",
|
|
1336
1344
|
disabled: o.disabled,
|
|
1337
1345
|
onValidationFailed: console.log,
|
|
1338
|
-
onValidationSuccess: m[14] || (m[14] = (
|
|
1346
|
+
onValidationSuccess: m[14] || (m[14] = (Ie) => x("validation-success"))
|
|
1339
1347
|
}, {
|
|
1340
1348
|
default: A(() => {
|
|
1341
|
-
var
|
|
1349
|
+
var Ie, _e, lt, rt, it, ut, dt, ct;
|
|
1342
1350
|
return [
|
|
1343
1351
|
n("div", po, [
|
|
1344
1352
|
n("div", fo, [
|
|
1345
|
-
(
|
|
1353
|
+
(Ie = p.modelValue) != null && Ie.template ? (S(), T(de, { key: 0 }, [
|
|
1346
1354
|
n("div", vo, [
|
|
1347
1355
|
y(H, {
|
|
1348
1356
|
label: s(f)("inventory.transfer.form.type.title")
|
|
1349
1357
|
}, null, 8, ["label"]),
|
|
1350
1358
|
n("div", yo, [
|
|
1351
|
-
y(
|
|
1359
|
+
y(J, {
|
|
1352
1360
|
"z-index": 51,
|
|
1353
1361
|
placement: "left",
|
|
1354
1362
|
disabled: o.disabled
|
|
1355
1363
|
}, {
|
|
1356
1364
|
content: A(() => m[15] || (m[15] = [
|
|
1357
|
-
|
|
1365
|
+
Te("This field is locked from template.")
|
|
1358
1366
|
])),
|
|
1359
1367
|
default: A(() => [
|
|
1360
1368
|
y(me, null, {
|
|
1361
1369
|
default: A(() => [
|
|
1362
1370
|
n("div", bo, [
|
|
1363
|
-
y(
|
|
1371
|
+
y(ne, {
|
|
1364
1372
|
name: "lock_outline",
|
|
1365
1373
|
size: "sm",
|
|
1366
1374
|
color: o.disabled ? "neutral-gray-200" : "neutral-gray-400"
|
|
1367
1375
|
}, null, 8, ["color"]),
|
|
1368
1376
|
n("div", {
|
|
1369
|
-
class:
|
|
1377
|
+
class: G({ "text-fm-color-typo-disabled": o.disabled })
|
|
1370
1378
|
}, M(s(f)(`inventory.transfer.form.type.${K.value.toLocaleLowerCase("en-us")}`)), 3)
|
|
1371
1379
|
])
|
|
1372
1380
|
]),
|
|
@@ -1376,7 +1384,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1376
1384
|
_: 1
|
|
1377
1385
|
}, 8, ["disabled"]),
|
|
1378
1386
|
n("div", {
|
|
1379
|
-
class:
|
|
1387
|
+
class: G([
|
|
1380
1388
|
"fm-typo-en-body-sm-400",
|
|
1381
1389
|
o.disabled ? "text-fm-color-typo-disabled" : "text-fm-color-typo-secondary"
|
|
1382
1390
|
])
|
|
@@ -1385,31 +1393,31 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1385
1393
|
]),
|
|
1386
1394
|
n("div", go, [
|
|
1387
1395
|
y(H, {
|
|
1388
|
-
label: K.value === s(
|
|
1396
|
+
label: K.value === s(ae).PURCHASE ? s(f)("inventory.transfer.form.purchaseFrom") : s(f)("inventory.transfer.form.transferFrom")
|
|
1389
1397
|
}, null, 8, ["label"]),
|
|
1390
1398
|
n("div", _o, [
|
|
1391
|
-
y(
|
|
1399
|
+
y(J, {
|
|
1392
1400
|
"z-index": 51,
|
|
1393
1401
|
placement: "left",
|
|
1394
1402
|
disabled: o.disabled
|
|
1395
1403
|
}, {
|
|
1396
1404
|
content: A(() => m[16] || (m[16] = [
|
|
1397
|
-
|
|
1405
|
+
Te("This field is locked from template.")
|
|
1398
1406
|
])),
|
|
1399
1407
|
default: A(() => [
|
|
1400
1408
|
y(me, null, {
|
|
1401
1409
|
default: A(() => {
|
|
1402
|
-
var
|
|
1410
|
+
var P;
|
|
1403
1411
|
return [
|
|
1404
1412
|
n("div", ho, [
|
|
1405
|
-
y(
|
|
1413
|
+
y(ne, {
|
|
1406
1414
|
name: "lock_outline",
|
|
1407
1415
|
size: "sm",
|
|
1408
1416
|
color: o.disabled ? "neutral-gray-200" : "neutral-gray-400"
|
|
1409
1417
|
}, null, 8, ["color"]),
|
|
1410
1418
|
n("div", {
|
|
1411
|
-
class:
|
|
1412
|
-
}, M((
|
|
1419
|
+
class: G({ "text-fm-color-typo-disabled": o.disabled })
|
|
1420
|
+
}, M((P = O.value.find((oe) => oe.value === U.value)) == null ? void 0 : P.label), 3)
|
|
1413
1421
|
])
|
|
1414
1422
|
];
|
|
1415
1423
|
}),
|
|
@@ -1421,17 +1429,17 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1421
1429
|
])
|
|
1422
1430
|
])
|
|
1423
1431
|
], 64)) : (S(), T(de, { key: 1 }, [
|
|
1424
|
-
y(
|
|
1432
|
+
y(le, {
|
|
1425
1433
|
label: s(f)("inventory.transfer.form.type.title"),
|
|
1426
1434
|
"label-mark": "required",
|
|
1427
1435
|
modelValue: K.value,
|
|
1428
|
-
"onUpdate:modelValue": m[0] || (m[0] = (
|
|
1436
|
+
"onUpdate:modelValue": m[0] || (m[0] = (P) => K.value = P),
|
|
1429
1437
|
items: Ve.value,
|
|
1430
1438
|
rules: [s(qe)(1)(Ve.value)]
|
|
1431
1439
|
}, {
|
|
1432
1440
|
default: A(() => [
|
|
1433
1441
|
n("span", {
|
|
1434
|
-
class:
|
|
1442
|
+
class: G([
|
|
1435
1443
|
"line-clamp-1 fm-typo-en-body-lg-400",
|
|
1436
1444
|
o.disabled ? "text-fm-color-typo-disabled" : "text-fm-color-typo-primary"
|
|
1437
1445
|
])
|
|
@@ -1439,32 +1447,32 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1439
1447
|
]),
|
|
1440
1448
|
_: 1
|
|
1441
1449
|
}, 8, ["label", "modelValue", "items", "rules"]),
|
|
1442
|
-
y(
|
|
1443
|
-
label: K.value === s(
|
|
1450
|
+
y(le, {
|
|
1451
|
+
label: K.value === s(ae).PURCHASE ? s(f)("inventory.transfer.form.purchaseFrom") : s(f)("inventory.transfer.form.transferFrom"),
|
|
1444
1452
|
"label-mark": "required",
|
|
1445
1453
|
modelValue: U.value,
|
|
1446
|
-
"onUpdate:modelValue": m[1] || (m[1] = (
|
|
1454
|
+
"onUpdate:modelValue": m[1] || (m[1] = (P) => U.value = P),
|
|
1447
1455
|
items: O.value,
|
|
1448
1456
|
rules: [s(qe)(1)(O.value)]
|
|
1449
1457
|
}, {
|
|
1450
|
-
"menu-wrapper": A((
|
|
1458
|
+
"menu-wrapper": A((P) => {
|
|
1451
1459
|
var oe, Ee;
|
|
1452
1460
|
return [
|
|
1453
|
-
y(ys,
|
|
1461
|
+
y(ys, Je(P, {
|
|
1454
1462
|
items: O.value,
|
|
1455
1463
|
"model-value": (Ee = (oe = o.modelValue) == null ? void 0 : oe.supplier) == null ? void 0 : Ee._id
|
|
1456
1464
|
}), null, 16, ["items", "model-value"])
|
|
1457
1465
|
];
|
|
1458
1466
|
}),
|
|
1459
1467
|
default: A(() => {
|
|
1460
|
-
var
|
|
1468
|
+
var P;
|
|
1461
1469
|
return [
|
|
1462
1470
|
n("span", {
|
|
1463
|
-
class:
|
|
1471
|
+
class: G([
|
|
1464
1472
|
"line-clamp-1 fm-typo-en-body-lg-400",
|
|
1465
1473
|
o.disabled ? "text-fm-color-typo-disabled" : "text-fm-color-typo-primary"
|
|
1466
1474
|
])
|
|
1467
|
-
}, M((
|
|
1475
|
+
}, M((P = O.value.find((oe) => oe.value === U.value)) == null ? void 0 : P.label), 3)
|
|
1468
1476
|
];
|
|
1469
1477
|
}),
|
|
1470
1478
|
_: 1
|
|
@@ -1474,73 +1482,73 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1474
1482
|
label: s(f)("inventory.transfer.form.reference"),
|
|
1475
1483
|
"label-mark": "optional",
|
|
1476
1484
|
modelValue: s(t).ref,
|
|
1477
|
-
"onUpdate:modelValue": m[2] || (m[2] = (
|
|
1485
|
+
"onUpdate:modelValue": m[2] || (m[2] = (P) => s(t).ref = P)
|
|
1478
1486
|
}, null, 8, ["label", "modelValue"]),
|
|
1479
1487
|
y(He, {
|
|
1480
1488
|
label: s(f)("inventory.transfer.form.remark"),
|
|
1481
1489
|
"label-mark": "optional",
|
|
1482
1490
|
"max-length": 240,
|
|
1483
|
-
modelValue:
|
|
1484
|
-
"onUpdate:modelValue": m[3] || (m[3] = (
|
|
1485
|
-
class:
|
|
1491
|
+
modelValue: V.value,
|
|
1492
|
+
"onUpdate:modelValue": m[3] || (m[3] = (P) => V.value = P),
|
|
1493
|
+
class: G([o.disabled ? "text-fm-color-typo-disabled " : ""])
|
|
1486
1494
|
}, null, 8, ["label", "modelValue", "class"]),
|
|
1487
|
-
_.value ? (S(),
|
|
1495
|
+
_.value ? (S(), W(uo, {
|
|
1488
1496
|
key: 2,
|
|
1489
1497
|
required: s(t).template != null,
|
|
1490
1498
|
disabled: o.disabled,
|
|
1491
1499
|
supplier: s(t).supplier,
|
|
1492
1500
|
setting: s(t).netSuite,
|
|
1493
1501
|
items: s(t).items,
|
|
1494
|
-
onChange: (
|
|
1495
|
-
s(t).items =
|
|
1502
|
+
onChange: (P, oe) => {
|
|
1503
|
+
s(t).items = P, s(t).netSuite = oe;
|
|
1496
1504
|
},
|
|
1497
|
-
"onNetsuite:ready": m[4] || (m[4] = (
|
|
1505
|
+
"onNetsuite:ready": m[4] || (m[4] = (P) => {
|
|
1498
1506
|
h.value = !0;
|
|
1499
1507
|
})
|
|
1500
1508
|
}, null, 8, ["required", "disabled", "supplier", "setting", "items", "onChange"])) : j("", !0),
|
|
1501
1509
|
s(u).enableBackdatePo ? (S(), T("div", ko, [
|
|
1502
1510
|
n("div", {
|
|
1503
|
-
class:
|
|
1511
|
+
class: G([
|
|
1504
1512
|
"flex",
|
|
1505
1513
|
{
|
|
1506
1514
|
"flex-col": i.value
|
|
1507
1515
|
}
|
|
1508
1516
|
])
|
|
1509
1517
|
}, [
|
|
1510
|
-
y(
|
|
1518
|
+
y(Ae, {
|
|
1511
1519
|
modelValue: s(b),
|
|
1512
|
-
"onUpdate:modelValue": m[5] || (m[5] = (
|
|
1520
|
+
"onUpdate:modelValue": m[5] || (m[5] = (P) => xe(b) ? b.value = P : null),
|
|
1513
1521
|
label: s(f)("inventory.transfer.form.backdate.title"),
|
|
1514
1522
|
sublabel: s(f)("inventory.transfer.form.backdate.subtitle"),
|
|
1515
1523
|
"label-placement": "right",
|
|
1516
1524
|
disabled: B.value && !o.lastClosingDate || o.disabled
|
|
1517
1525
|
}, null, 8, ["modelValue", "label", "sublabel", "disabled"]),
|
|
1518
1526
|
n("div", {
|
|
1519
|
-
class:
|
|
1527
|
+
class: G({ hidden: i.value, "w-16": !i.value })
|
|
1520
1528
|
}, null, 2),
|
|
1521
1529
|
s(b) ? (S(), T("div", xo, [
|
|
1522
1530
|
n("div", Co, [
|
|
1523
|
-
y(
|
|
1531
|
+
y(je, {
|
|
1524
1532
|
modelValue: s(R),
|
|
1525
|
-
"onUpdate:modelValue": m[6] || (m[6] = (
|
|
1533
|
+
"onUpdate:modelValue": m[6] || (m[6] = (P) => xe(R) ? R.value = P : null)
|
|
1526
1534
|
}, null, 8, ["modelValue"])
|
|
1527
1535
|
]),
|
|
1528
1536
|
n("div", So, [
|
|
1529
|
-
y(
|
|
1537
|
+
y(z, {
|
|
1530
1538
|
modelValue: s(X),
|
|
1531
|
-
"onUpdate:modelValue": m[7] || (m[7] = (
|
|
1539
|
+
"onUpdate:modelValue": m[7] || (m[7] = (P) => xe(X) ? X.value = P : null)
|
|
1532
1540
|
}, null, 8, ["modelValue"])
|
|
1533
1541
|
])
|
|
1534
1542
|
])) : j("", !0)
|
|
1535
1543
|
], 2),
|
|
1536
|
-
s(d) ? (S(),
|
|
1544
|
+
s(d) ? (S(), W(ee, {
|
|
1537
1545
|
key: 0,
|
|
1538
1546
|
modelValue: s(d),
|
|
1539
|
-
"onUpdate:modelValue": m[8] || (m[8] = (
|
|
1547
|
+
"onUpdate:modelValue": m[8] || (m[8] = (P) => xe(d) ? d.value = P : null),
|
|
1540
1548
|
rules: [s(Ht)(new Date(o.lastClosingDate), /* @__PURE__ */ new Date())]
|
|
1541
1549
|
}, null, 8, ["modelValue", "rules"])) : j("", !0),
|
|
1542
1550
|
B.value && !o.lastClosingDate ? (S(), T("div", wo, [
|
|
1543
|
-
y(
|
|
1551
|
+
y(ne, {
|
|
1544
1552
|
name: "error",
|
|
1545
1553
|
size: "sm",
|
|
1546
1554
|
class: "text-fm-color-typo-warning"
|
|
@@ -1550,13 +1558,13 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1550
1558
|
])) : j("", !0)
|
|
1551
1559
|
])
|
|
1552
1560
|
]),
|
|
1553
|
-
n("div",
|
|
1554
|
-
y(
|
|
1561
|
+
n("div", Io, [
|
|
1562
|
+
y(ee, {
|
|
1555
1563
|
"model-value": s(t).items,
|
|
1556
1564
|
rules: [s(qe)(1)]
|
|
1557
1565
|
}, null, 8, ["model-value", "rules"]),
|
|
1558
1566
|
n("div", {
|
|
1559
|
-
class:
|
|
1567
|
+
class: G([
|
|
1560
1568
|
"flex gap-16",
|
|
1561
1569
|
{
|
|
1562
1570
|
"flex-col items-start": i.value,
|
|
@@ -1564,9 +1572,9 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1564
1572
|
}
|
|
1565
1573
|
])
|
|
1566
1574
|
}, [
|
|
1567
|
-
n("div",
|
|
1575
|
+
n("div", $o, M(s(f)("inventory.transfer.form.items.title")), 1),
|
|
1568
1576
|
n("div", To, [
|
|
1569
|
-
y(
|
|
1577
|
+
y(ie, {
|
|
1570
1578
|
disabled: o.disabled,
|
|
1571
1579
|
label: s(f)("inventory.transfer.form.items.addItem"),
|
|
1572
1580
|
"prepend-icon": "add",
|
|
@@ -1574,73 +1582,73 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1574
1582
|
"text-color": "primary",
|
|
1575
1583
|
"bg-color": "transparent",
|
|
1576
1584
|
"border-color": "primary",
|
|
1577
|
-
onClick: m[9] || (m[9] = (
|
|
1585
|
+
onClick: m[9] || (m[9] = (P) => ze()),
|
|
1578
1586
|
size: "md"
|
|
1579
1587
|
}, null, 8, ["disabled", "label"]),
|
|
1580
|
-
y(
|
|
1588
|
+
y(Ws, {
|
|
1581
1589
|
"template-id": s(t).template || void 0,
|
|
1582
1590
|
"template-items": Le.value,
|
|
1583
1591
|
"po-items": s(t).items,
|
|
1584
|
-
"onUpdate:forecastAmounts": m[10] || (m[10] = (
|
|
1585
|
-
l.value =
|
|
1592
|
+
"onUpdate:forecastAmounts": m[10] || (m[10] = (P) => {
|
|
1593
|
+
l.value = P;
|
|
1586
1594
|
}),
|
|
1587
|
-
"onUpdate:poItems": m[11] || (m[11] = (
|
|
1588
|
-
s(t).items =
|
|
1595
|
+
"onUpdate:poItems": m[11] || (m[11] = (P) => {
|
|
1596
|
+
s(t).items = P, C.value++;
|
|
1589
1597
|
})
|
|
1590
1598
|
}, null, 8, ["template-id", "template-items", "po-items"])
|
|
1591
1599
|
])
|
|
1592
1600
|
], 2),
|
|
1593
|
-
K.value === s(
|
|
1594
|
-
y(
|
|
1601
|
+
K.value === s(ae).PURCHASE && D.value && s(u).enableTotalCost && ((_e = o.modelValue) != null && _e.items.length) ? (S(), T("div", Do, [
|
|
1602
|
+
y(Ae, {
|
|
1595
1603
|
label: s(he) ? s(f)("inventory.transfer.form.items.fetchingData") : s(f)("inventory.transfer.form.items.comparePriceHistory"),
|
|
1596
1604
|
"prepend-icon": "compare_arrows",
|
|
1597
1605
|
"label-placement": "right",
|
|
1598
1606
|
"model-value": s(Z),
|
|
1599
|
-
"onUpdate:modelValue": m[12] || (m[12] = (
|
|
1607
|
+
"onUpdate:modelValue": m[12] || (m[12] = (P) => xe(Z) ? Z.value = P : null),
|
|
1600
1608
|
disabled: s(he) || o.disabled
|
|
1601
1609
|
}, null, 8, ["label", "model-value", "disabled"])
|
|
1602
1610
|
])) : j("", !0),
|
|
1603
|
-
y(
|
|
1604
|
-
"model-value":
|
|
1605
|
-
rules: [() =>
|
|
1611
|
+
y(ee, {
|
|
1612
|
+
"model-value": Re.value,
|
|
1613
|
+
rules: [() => Re.value ? "Must have at least one non-zero item" : !0]
|
|
1606
1614
|
}, null, 8, ["model-value", "rules"]),
|
|
1607
|
-
(S(),
|
|
1615
|
+
(S(), W(se, {
|
|
1608
1616
|
"column-defs": Be.value,
|
|
1609
1617
|
"column-visibility": {
|
|
1610
|
-
[s(
|
|
1611
|
-
[s(
|
|
1612
|
-
[s(
|
|
1618
|
+
[s(te).Code]: !(((lt = o.modelValue) == null ? void 0 : lt.template) ?? ((rt = o.modelValue) == null ? void 0 : rt.templateDoc)),
|
|
1619
|
+
[s(te).Name]: !(((it = o.modelValue) == null ? void 0 : it.template) ?? ((ut = o.modelValue) == null ? void 0 : ut.templateDoc)),
|
|
1620
|
+
[s(te).TemplateName]: !!(((dt = o.modelValue) == null ? void 0 : dt.template) ?? ((ct = o.modelValue) == null ? void 0 : ct.templateDoc))
|
|
1613
1621
|
},
|
|
1614
1622
|
"row-data": s(t).items,
|
|
1615
1623
|
key: C.value,
|
|
1616
1624
|
"hide-footer": "",
|
|
1617
1625
|
"page-size": s(t).items.length
|
|
1618
1626
|
}, {
|
|
1619
|
-
"table-row": A((
|
|
1627
|
+
"table-row": A((P) => {
|
|
1620
1628
|
var oe, Ee, mt, pt;
|
|
1621
1629
|
return [
|
|
1622
1630
|
y(ao, {
|
|
1623
1631
|
"compare-price-by-sku": s(ke),
|
|
1624
|
-
"show-compare-price": K.value === s(
|
|
1625
|
-
row:
|
|
1632
|
+
"show-compare-price": K.value === s(ae).PURCHASE && s(Z),
|
|
1633
|
+
row: P,
|
|
1626
1634
|
"template-item": (pt = (mt = (Ee = (oe = o.modelValue) == null ? void 0 : oe.templateDoc) == null ? void 0 : Ee.purchaseOrder) == null ? void 0 : mt.items) == null ? void 0 : pt.find(
|
|
1627
|
-
(
|
|
1635
|
+
(Xe) => Xe.sku._id === P.original.sku._id
|
|
1628
1636
|
),
|
|
1629
|
-
"onUpdate:item": m[13] || (m[13] = (
|
|
1637
|
+
"onUpdate:item": m[13] || (m[13] = (Xe) => we.value.updateItem(Xe)),
|
|
1630
1638
|
disabled: o.disabled
|
|
1631
1639
|
}, null, 8, ["compare-price-by-sku", "show-compare-price", "row", "template-item", "disabled"])
|
|
1632
1640
|
];
|
|
1633
1641
|
}),
|
|
1634
|
-
"list-row": A((
|
|
1635
|
-
(S(),
|
|
1636
|
-
row:
|
|
1642
|
+
"list-row": A((P) => [
|
|
1643
|
+
(S(), W(xt, {
|
|
1644
|
+
row: P,
|
|
1637
1645
|
key: s(t).items.map((oe) => oe.sku._id).join(".")
|
|
1638
1646
|
}, {
|
|
1639
1647
|
default: A((oe) => [
|
|
1640
1648
|
y(Os, {
|
|
1641
1649
|
"compare-price-by-sku": s(ke),
|
|
1642
|
-
"show-compare-price": K.value === s(
|
|
1643
|
-
row:
|
|
1650
|
+
"show-compare-price": K.value === s(ae).PURCHASE && s(Z),
|
|
1651
|
+
row: P,
|
|
1644
1652
|
"cell-by-col-id": oe
|
|
1645
1653
|
}, null, 8, ["compare-price-by-sku", "show-compare-price", "row", "cell-by-col-id"])
|
|
1646
1654
|
]),
|
|
@@ -1657,7 +1665,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1657
1665
|
]);
|
|
1658
1666
|
};
|
|
1659
1667
|
}
|
|
1660
|
-
}),
|
|
1668
|
+
}), Vo = { class: "flex items-center" }, Ro = { class: "fm-typo-en-title-md-800" }, Ao = { class: "flex gap-4" }, Eo = /* @__PURE__ */ ce({
|
|
1661
1669
|
__name: "TransferDialog",
|
|
1662
1670
|
props: {
|
|
1663
1671
|
mode: {},
|
|
@@ -1668,13 +1676,13 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1668
1676
|
},
|
|
1669
1677
|
emits: ["update:show", "submitted"],
|
|
1670
1678
|
setup(g, { expose: w, emit: r }) {
|
|
1671
|
-
var
|
|
1672
|
-
const p = g, x = r, t =
|
|
1679
|
+
var V;
|
|
1680
|
+
const p = g, x = r, t = tt(), f = wt(), F = De(), I = nt(), v = ot(), e = st(), { t: u } = ge(), k = q(!1), a = q(!1), i = q(!1);
|
|
1673
1681
|
async function h(d) {
|
|
1674
1682
|
if (d) {
|
|
1675
1683
|
a.value = !1;
|
|
1676
1684
|
try {
|
|
1677
|
-
await
|
|
1685
|
+
await I.readSuppliers(), a.value = !0;
|
|
1678
1686
|
} catch {
|
|
1679
1687
|
F.open({
|
|
1680
1688
|
title: u("inventory.transfer.form.unableToFetchListOfSuppliers.title"),
|
|
@@ -1719,8 +1727,8 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1719
1727
|
templateDoc: f.templates.find((b) => b._id === p.templateId)
|
|
1720
1728
|
};
|
|
1721
1729
|
}
|
|
1722
|
-
const C = St(p, "show"), l = q(p.modelValue ?? _()), c = q(((
|
|
1723
|
-
|
|
1730
|
+
const C = St(p, "show"), l = q(p.modelValue ?? _()), c = q(((V = p.modelValue) == null ? void 0 : V._id) ?? `${Math.random()}`);
|
|
1731
|
+
be(
|
|
1724
1732
|
() => p.show,
|
|
1725
1733
|
(d) => {
|
|
1726
1734
|
var b;
|
|
@@ -1832,8 +1840,8 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1832
1840
|
(X = (R = Q.value) == null ? void 0 : R.validateInputs) == null || X.call(R);
|
|
1833
1841
|
}
|
|
1834
1842
|
return (d, b) => {
|
|
1835
|
-
const R =
|
|
1836
|
-
return S(),
|
|
1843
|
+
const R = $("FmButton"), X = $("FmSideSheet");
|
|
1844
|
+
return S(), W(X, {
|
|
1837
1845
|
modelValue: s(C),
|
|
1838
1846
|
"onUpdate:modelValue": b[3] || (b[3] = (Z) => xe(C) ? C.value = Z : null),
|
|
1839
1847
|
"dismiss-away": "",
|
|
@@ -1841,12 +1849,12 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1841
1849
|
"max-width": 900
|
|
1842
1850
|
}, {
|
|
1843
1851
|
"side-sheet-header": A(() => [
|
|
1844
|
-
n("div",
|
|
1852
|
+
n("div", Vo, [
|
|
1845
1853
|
n("div", Ro, M(B.value), 1)
|
|
1846
1854
|
])
|
|
1847
1855
|
]),
|
|
1848
1856
|
default: A(() => [
|
|
1849
|
-
(S(),
|
|
1857
|
+
(S(), W(Po, {
|
|
1850
1858
|
class: "w-full",
|
|
1851
1859
|
ref_key: "formRef",
|
|
1852
1860
|
ref: Q,
|
|
@@ -1855,7 +1863,7 @@ const to = { class: "fm-typo-body-md-400 line-clamp-2 w-full" }, so = { key: 0 }
|
|
|
1855
1863
|
modelValue: l.value,
|
|
1856
1864
|
"onUpdate:modelValue": b[1] || (b[1] = (Z) => l.value = Z),
|
|
1857
1865
|
disabled: k.value || D.value,
|
|
1858
|
-
suppliers: s(
|
|
1866
|
+
suppliers: s(I).suppliers,
|
|
1859
1867
|
skus: s(v).skus,
|
|
1860
1868
|
key: c.value,
|
|
1861
1869
|
"last-closing-date": d.lastClosingDate
|
|
@@ -1905,8 +1913,8 @@ function Mo(g) {
|
|
|
1905
1913
|
try {
|
|
1906
1914
|
return w.reduce(
|
|
1907
1915
|
(p, x) => {
|
|
1908
|
-
const t = new Array(), f = g.Sheets[x], F =
|
|
1909
|
-
for (const { index: u, data: k } of
|
|
1916
|
+
const t = new Array(), f = g.Sheets[x], F = ot(), I = Oo(f), v = [];
|
|
1917
|
+
for (const { index: u, data: k } of I) {
|
|
1910
1918
|
k.scanned_code === "" && t.push(`Row ${u + 1}: Scanned code is empty`), k.item_name === "" && t.push(`Row ${u + 1}: Item name is empty`), k.uom === "" && t.push(`Row ${u + 1}: UOM is empty`), k["transfer_quantity(uom)"] === "" && t.push(`Row ${u + 1}: Transfer quantity is empty`);
|
|
1911
1919
|
const a = F.skus.find((_) => _.code === k.scanned_code);
|
|
1912
1920
|
if (!a) {
|
|
@@ -1956,7 +1964,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
1956
1964
|
key: 0,
|
|
1957
1965
|
class: "text-fm-color-typo-secondary fm-typo-en-body-sm-400"
|
|
1958
1966
|
}, zo = { key: 0 }, Lo = {
|
|
1959
|
-
class: /* @__PURE__ */
|
|
1967
|
+
class: /* @__PURE__ */ G(["fm-typo-en-body-lg-600"])
|
|
1960
1968
|
}, Ho = { class: "flex-1" }, jo = { class: "flex-auto line-clamp-2 text-ellipsis break-all fm-typo-en-body-sm-400" }, Qo = { class: "flex-auto line-clamp-2 text-ellipsis break-all" }, Yo = { class: "text-fm-color-typo-primary" }, Ko = { class: "ml-auto" }, Xo = { key: 0 }, Zo = /* @__PURE__ */ ce({
|
|
1961
1969
|
__name: "XilnexResult",
|
|
1962
1970
|
props: {
|
|
@@ -1966,27 +1974,27 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
1966
1974
|
errors: {}
|
|
1967
1975
|
},
|
|
1968
1976
|
setup(g) {
|
|
1969
|
-
const w = g, { t: r } =
|
|
1977
|
+
const w = g, { t: r } = ge(), p = q(!1), x = () => {
|
|
1970
1978
|
w.errors.length && (p.value = !p.value);
|
|
1971
1979
|
};
|
|
1972
1980
|
return (t, f) => {
|
|
1973
1981
|
var v;
|
|
1974
|
-
const F =
|
|
1982
|
+
const F = $("FmIcon"), I = $("FmTooltip");
|
|
1975
1983
|
return S(), T("div", qo, [
|
|
1976
1984
|
n("div", {
|
|
1977
1985
|
onClick: x,
|
|
1978
|
-
class:
|
|
1986
|
+
class: G({
|
|
1979
1987
|
"cursor-pointer": t.errors.length
|
|
1980
1988
|
})
|
|
1981
1989
|
}, [
|
|
1982
1990
|
n("div", Uo, [
|
|
1983
1991
|
n("div", No, [
|
|
1984
1992
|
n("div", {
|
|
1985
|
-
class:
|
|
1993
|
+
class: G({
|
|
1986
1994
|
"text-fm-color-system-error-300": t.errors.length
|
|
1987
1995
|
})
|
|
1988
1996
|
}, [
|
|
1989
|
-
|
|
1997
|
+
Te(M(t.name) + " ", 1),
|
|
1990
1998
|
t.type === "create" ? (S(), T("span", Bo, "(" + M(s(r)("inventory.closing.template.import.new")) + ")", 1)) : j("", !0)
|
|
1991
1999
|
], 2),
|
|
1992
2000
|
t.errors.length ? (S(), T("div", zo, [
|
|
@@ -2004,7 +2012,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2004
2012
|
class: "flex gap-4 mt-2 items-center"
|
|
2005
2013
|
}, [
|
|
2006
2014
|
n("div", Ho, [
|
|
2007
|
-
y(
|
|
2015
|
+
y(I, {
|
|
2008
2016
|
content: e.code,
|
|
2009
2017
|
placement: "top",
|
|
2010
2018
|
"z-index": 51
|
|
@@ -2014,7 +2022,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2014
2022
|
]),
|
|
2015
2023
|
_: 2
|
|
2016
2024
|
}, 1032, ["content"]),
|
|
2017
|
-
y(
|
|
2025
|
+
y(I, {
|
|
2018
2026
|
content: e.name,
|
|
2019
2027
|
placement: "top",
|
|
2020
2028
|
"z-index": 51
|
|
@@ -2029,13 +2037,13 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2029
2037
|
n("span", Yo, M(s(Ge).toFormatString({
|
|
2030
2038
|
value: e.quantity
|
|
2031
2039
|
})), 1),
|
|
2032
|
-
|
|
2040
|
+
Te(" " + M(e.measurement ? e.measurement.abbrev : e.sku.unit.abbrev), 1)
|
|
2033
2041
|
])
|
|
2034
2042
|
]))), 128)) : j("", !0)
|
|
2035
2043
|
])
|
|
2036
2044
|
]),
|
|
2037
2045
|
n("div", Ko, [
|
|
2038
|
-
t.errors.length ? (S(),
|
|
2046
|
+
t.errors.length ? (S(), W(F, {
|
|
2039
2047
|
key: 0,
|
|
2040
2048
|
name: p.value ? "keyboard_arrow_up" : "keyboard_arrow_down",
|
|
2041
2049
|
size: "md"
|
|
@@ -2044,7 +2052,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2044
2052
|
], 2),
|
|
2045
2053
|
p.value ? (S(), T("div", {
|
|
2046
2054
|
key: 0,
|
|
2047
|
-
class:
|
|
2055
|
+
class: G(["flex flex-col gap-4 pl-8 fm-typo-en-body-sm-400", {
|
|
2048
2056
|
"text-fm-color-typo-secondary": !t.errors.length,
|
|
2049
2057
|
"text-fm-color-system-error-300": t.errors.length
|
|
2050
2058
|
}])
|
|
@@ -2058,10 +2066,10 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2058
2066
|
]);
|
|
2059
2067
|
};
|
|
2060
2068
|
}
|
|
2061
|
-
}),
|
|
2069
|
+
}), Jo = { class: "flex flex-col gap-24" }, Go = {
|
|
2062
2070
|
key: 0,
|
|
2063
2071
|
class: "flex items-center gap-8"
|
|
2064
|
-
},
|
|
2072
|
+
}, Wo = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ea = { class: "flex flex-col gap-8" }, ta = { class: "line-clamp-2 text-ellipsis break-all" }, sa = {
|
|
2065
2073
|
key: 2,
|
|
2066
2074
|
class: "shrink-0"
|
|
2067
2075
|
}, oa = {
|
|
@@ -2073,7 +2081,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2073
2081
|
}, la = { class: "fm-typo-en-body-lg-600" }, yt = "Transfer note", ra = /* @__PURE__ */ ce({
|
|
2074
2082
|
__name: "XilnexImportForm",
|
|
2075
2083
|
setup(g, { expose: w }) {
|
|
2076
|
-
const r = q(null), p =
|
|
2084
|
+
const r = q(null), p = De(), x = q(!1), t = q(!1), f = kt(), F = q(!1), I = Ue();
|
|
2077
2085
|
q([]);
|
|
2078
2086
|
const v = N({
|
|
2079
2087
|
get() {
|
|
@@ -2097,8 +2105,8 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2097
2105
|
});
|
|
2098
2106
|
}
|
|
2099
2107
|
});
|
|
2100
|
-
|
|
2101
|
-
const l = await
|
|
2108
|
+
Ke(async () => {
|
|
2109
|
+
const l = await I.getNetSuiteLocations();
|
|
2102
2110
|
console.log(l), F.value = !0;
|
|
2103
2111
|
});
|
|
2104
2112
|
const e = N({
|
|
@@ -2138,7 +2146,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2138
2146
|
(c = (l = h.value) == null ? void 0 : l.resetInputs) == null || c.call(l);
|
|
2139
2147
|
}
|
|
2140
2148
|
});
|
|
2141
|
-
const { t: _ } =
|
|
2149
|
+
const { t: _ } = ge();
|
|
2142
2150
|
async function C(l) {
|
|
2143
2151
|
k.value = [], a.value = [];
|
|
2144
2152
|
try {
|
|
@@ -2172,16 +2180,16 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2172
2180
|
}), x.value = !1;
|
|
2173
2181
|
}
|
|
2174
2182
|
}
|
|
2175
|
-
return
|
|
2183
|
+
return be(r, (l) => {
|
|
2176
2184
|
l && C(l);
|
|
2177
2185
|
}), (l, c) => {
|
|
2178
|
-
const D =
|
|
2179
|
-
return S(),
|
|
2186
|
+
const D = $("FmSelect"), B = $("FmDatePicker"), Q = $("FmTimePicker"), Y = $("FmCircularProgress"), K = $("FmLabel"), O = $("FmIcon"), U = $("FmButton"), V = $("FmForm");
|
|
2187
|
+
return S(), W(V, {
|
|
2180
2188
|
ref_key: "formRef",
|
|
2181
2189
|
ref: h
|
|
2182
2190
|
}, {
|
|
2183
2191
|
default: A(() => [
|
|
2184
|
-
n("div",
|
|
2192
|
+
n("div", Jo, [
|
|
2185
2193
|
y(D, {
|
|
2186
2194
|
modelValue: v.value,
|
|
2187
2195
|
"onUpdate:modelValue": c[0] || (c[0] = (d) => v.value = d),
|
|
@@ -2211,18 +2219,18 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2211
2219
|
label: "Transfer time",
|
|
2212
2220
|
rules: [s(Me)()]
|
|
2213
2221
|
}, null, 8, ["modelValue", "rules"]),
|
|
2214
|
-
t.value ? (S(), T("div",
|
|
2222
|
+
t.value ? (S(), T("div", Go, [
|
|
2215
2223
|
n("div", null, [
|
|
2216
2224
|
y(Y, {
|
|
2217
2225
|
size: "md",
|
|
2218
2226
|
color: "neutral-gray-200"
|
|
2219
2227
|
})
|
|
2220
2228
|
]),
|
|
2221
|
-
n("div",
|
|
2229
|
+
n("div", Wo, M(s(_)("inventory.formField.loading")), 1)
|
|
2222
2230
|
])) : (S(), T(de, { key: 1 }, [
|
|
2223
2231
|
y(Kt, {
|
|
2224
2232
|
"max-file-size": 5,
|
|
2225
|
-
class:
|
|
2233
|
+
class: G({
|
|
2226
2234
|
"w-full": !0,
|
|
2227
2235
|
"h-[200px]": !r.value
|
|
2228
2236
|
}),
|
|
@@ -2230,19 +2238,19 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2230
2238
|
label: yt,
|
|
2231
2239
|
onFileUpload: c[3] || (c[3] = (d) => r.value = d),
|
|
2232
2240
|
"button-label": s(_)("inventory.ingredient.import.selectFile")
|
|
2233
|
-
},
|
|
2241
|
+
}, $t({ _: 2 }, [
|
|
2234
2242
|
r.value ? {
|
|
2235
2243
|
name: "default",
|
|
2236
2244
|
fn: A(({ openFileDialog: d }) => [
|
|
2237
2245
|
y(K, null, {
|
|
2238
2246
|
default: A(() => [
|
|
2239
|
-
|
|
2247
|
+
Te(M(yt))
|
|
2240
2248
|
]),
|
|
2241
2249
|
_: 1
|
|
2242
2250
|
}),
|
|
2243
2251
|
n("div", ea, [
|
|
2244
2252
|
n("div", {
|
|
2245
|
-
class:
|
|
2253
|
+
class: G([
|
|
2246
2254
|
"fm-corner-radius-md p-16 flex items-center gap-16",
|
|
2247
2255
|
{
|
|
2248
2256
|
"border border-fm-color-neutral-gray-100": x.value,
|
|
@@ -2251,18 +2259,18 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2251
2259
|
}
|
|
2252
2260
|
])
|
|
2253
2261
|
}, [
|
|
2254
|
-
x.value ? (S(),
|
|
2262
|
+
x.value ? (S(), W(Y, {
|
|
2255
2263
|
key: 0,
|
|
2256
2264
|
size: "md",
|
|
2257
2265
|
color: "neutral-gray-200"
|
|
2258
|
-
})) : (S(),
|
|
2266
|
+
})) : (S(), W(O, {
|
|
2259
2267
|
key: 1,
|
|
2260
2268
|
name: i.value ? "error" : "attach_file",
|
|
2261
2269
|
outline: "",
|
|
2262
2270
|
color: i.value ? "system-error-300" : void 0
|
|
2263
2271
|
}, null, 8, ["name", "color"])),
|
|
2264
2272
|
n("div", {
|
|
2265
|
-
class:
|
|
2273
|
+
class: G([
|
|
2266
2274
|
"fm-typo-en-body-md-400 flex-1 h-[36px] flex items-center",
|
|
2267
2275
|
{
|
|
2268
2276
|
"text-fm-color-typo-disabled": x.value,
|
|
@@ -2301,7 +2309,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2301
2309
|
]), 1032, ["class", "button-label"]),
|
|
2302
2310
|
r.value ? (S(), T("div", na, [
|
|
2303
2311
|
n("div", la, M(s(_)("inventory.ingredient.import.summary")), 1),
|
|
2304
|
-
(S(!0), T(de, null, Se(a.value, (d, b) => (S(),
|
|
2312
|
+
(S(!0), T(de, null, Se(a.value, (d, b) => (S(), W(Zo, {
|
|
2305
2313
|
key: b,
|
|
2306
2314
|
name: `Transfer Note ${b + 1}`,
|
|
2307
2315
|
items: d.poItems,
|
|
@@ -2323,7 +2331,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2323
2331
|
},
|
|
2324
2332
|
emits: ["update:show", "submitted"],
|
|
2325
2333
|
setup(g, { expose: w, emit: r }) {
|
|
2326
|
-
const p = r, t = St(g, "show"), f =
|
|
2334
|
+
const p = r, t = St(g, "show"), f = De(), F = tt(), I = q(!1), v = q(), e = q();
|
|
2327
2335
|
w({
|
|
2328
2336
|
validateInputs: () => {
|
|
2329
2337
|
var a, i;
|
|
@@ -2377,7 +2385,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2377
2385
|
});
|
|
2378
2386
|
return;
|
|
2379
2387
|
}
|
|
2380
|
-
|
|
2388
|
+
I.value = !0;
|
|
2381
2389
|
try {
|
|
2382
2390
|
await F.importFromXilnex(e.value), p("update:show", !1);
|
|
2383
2391
|
} catch (c) {
|
|
@@ -2387,12 +2395,12 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2387
2395
|
type: "error"
|
|
2388
2396
|
});
|
|
2389
2397
|
} finally {
|
|
2390
|
-
|
|
2398
|
+
I.value = !1;
|
|
2391
2399
|
}
|
|
2392
2400
|
}
|
|
2393
2401
|
return (a, i) => {
|
|
2394
|
-
const h =
|
|
2395
|
-
return S(),
|
|
2402
|
+
const h = $("FmSpacer"), _ = $("FmButton"), C = $("FmDialog");
|
|
2403
|
+
return S(), W(C, {
|
|
2396
2404
|
modelValue: s(t),
|
|
2397
2405
|
"onUpdate:modelValue": i[2] || (i[2] = (l) => xe(t) ? t.value = l : null),
|
|
2398
2406
|
overlay: !0,
|
|
@@ -2404,7 +2412,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2404
2412
|
"dialog-footer": A(() => [
|
|
2405
2413
|
y(h, { class: "sm:hidden xs:hidden" }),
|
|
2406
2414
|
y(_, {
|
|
2407
|
-
disabled:
|
|
2415
|
+
disabled: I.value,
|
|
2408
2416
|
class: "sm:w-full xs:w-full",
|
|
2409
2417
|
label: "Cancel",
|
|
2410
2418
|
size: "md",
|
|
@@ -2412,8 +2420,8 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2412
2420
|
onClick: i[1] || (i[1] = (l) => p("update:show", !1))
|
|
2413
2421
|
}, null, 8, ["disabled"]),
|
|
2414
2422
|
y(_, {
|
|
2415
|
-
disabled:
|
|
2416
|
-
loading:
|
|
2423
|
+
disabled: I.value,
|
|
2424
|
+
loading: I.value,
|
|
2417
2425
|
class: "sm:w-full xs:w-full",
|
|
2418
2426
|
label: "Upload",
|
|
2419
2427
|
size: "md",
|
|
@@ -2439,14 +2447,14 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2439
2447
|
}), da = { class: "flex flex-col py-8" }, ca = { class: "fm-typo-en-body-md-400 text-fm-color-typo-secondary" }, ma = { class: "fm-typo-en-body-lg-600 text-fm-color-typo-primary line-clamp-1" }, pa = { class: "fm-typo-en-body-md-400 text-fm-color-typo-primary line-clamp-1" }, fa = {
|
|
2440
2448
|
key: 0,
|
|
2441
2449
|
class: "fm-typo-en-body-md-400 text-fm-color-typo-primary line-clamp-1"
|
|
2442
|
-
}, va = { class: "pt-8" }, bt = "ReceiveRequestViewSearchCriteria",
|
|
2450
|
+
}, va = { class: "pt-8" }, bt = "ReceiveRequestViewSearchCriteria", Ta = /* @__PURE__ */ ce({
|
|
2443
2451
|
__name: "ReceiveRequestView",
|
|
2444
2452
|
setup(g) {
|
|
2445
|
-
const { t: w } =
|
|
2446
|
-
|
|
2447
|
-
name:
|
|
2448
|
-
startDate:
|
|
2449
|
-
endDate:
|
|
2453
|
+
const { t: w } = ge(), r = De();
|
|
2454
|
+
Qe.object({
|
|
2455
|
+
name: Qe.string().optional().nullable(),
|
|
2456
|
+
startDate: Qe.string().optional().nullable(),
|
|
2457
|
+
endDate: Qe.string().optional().nullable()
|
|
2450
2458
|
});
|
|
2451
2459
|
const p = N(
|
|
2452
2460
|
() => !k._currentLocation || e.loading.value
|
|
@@ -2464,23 +2472,24 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2464
2472
|
return O;
|
|
2465
2473
|
}
|
|
2466
2474
|
}
|
|
2467
|
-
function
|
|
2475
|
+
function I() {
|
|
2468
2476
|
x.setItem(bt, JSON.stringify(v.value));
|
|
2469
2477
|
}
|
|
2470
2478
|
const v = q(F()), e = ts(
|
|
2471
|
-
|
|
2479
|
+
Ze.RECEIVE_REQUEST,
|
|
2472
2480
|
v.value
|
|
2473
2481
|
), { columnDefs: u } = ss(
|
|
2474
|
-
|
|
2475
|
-
e
|
|
2476
|
-
|
|
2482
|
+
Ze.RECEIVE_REQUEST,
|
|
2483
|
+
e,
|
|
2484
|
+
e.shipments
|
|
2485
|
+
), k = st();
|
|
2477
2486
|
async function a() {
|
|
2478
2487
|
const O = `inventory-record_${vt(v.value.startDate).format("DD-MM-YYYY_HH-mm")}-${vt(v.value.endDate).format("DD-MM-YYYY_HH-mm")}.xlsx`, U = e.purchaseOrders.value.flatMap(
|
|
2479
2488
|
(d) => d.items.map((b) => {
|
|
2480
|
-
var
|
|
2489
|
+
var re;
|
|
2481
2490
|
const R = new Date(ls(d._id) ?? ""), X = d.effectiveAt ? new Date(d.effectiveAt) : void 0, Z = Ce(
|
|
2482
2491
|
as(b.sku, d.deliveryOrder || [])
|
|
2483
|
-
), he = Ce(b.quantity), ke = ((
|
|
2492
|
+
), he = Ce(b.quantity), ke = ((re = b == null ? void 0 : b.measurement) == null ? void 0 : re.abbrev) || b.sku.unit.abbrev;
|
|
2484
2493
|
return {
|
|
2485
2494
|
"SKU code": b.code,
|
|
2486
2495
|
"SKU name": b.name,
|
|
@@ -2492,10 +2501,10 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2492
2501
|
"Received quantity": Z,
|
|
2493
2502
|
"Ordered quantity": he,
|
|
2494
2503
|
Unit: ke,
|
|
2495
|
-
"Total cost": b.totalCost ?
|
|
2504
|
+
"Total cost": b.totalCost ? Ye(b.totalCost) : null
|
|
2496
2505
|
};
|
|
2497
2506
|
})
|
|
2498
|
-
),
|
|
2507
|
+
), V = [
|
|
2499
2508
|
"SKU code",
|
|
2500
2509
|
"SKU name",
|
|
2501
2510
|
"PO #",
|
|
@@ -2506,12 +2515,12 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2506
2515
|
"Ordered quantity",
|
|
2507
2516
|
"Unit"
|
|
2508
2517
|
];
|
|
2509
|
-
t.enableBackdatePo &&
|
|
2518
|
+
t.enableBackdatePo && V.insert("Effective at", 4), t.enableTotalCost && V.push("Total cost"), await rs(
|
|
2510
2519
|
[
|
|
2511
2520
|
{
|
|
2512
2521
|
name: "purchases",
|
|
2513
2522
|
data: U,
|
|
2514
|
-
columns:
|
|
2523
|
+
columns: V
|
|
2515
2524
|
}
|
|
2516
2525
|
],
|
|
2517
2526
|
O
|
|
@@ -2522,13 +2531,13 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2522
2531
|
});
|
|
2523
2532
|
}
|
|
2524
2533
|
const i = q(ft()), h = q("");
|
|
2525
|
-
|
|
2534
|
+
be([() => i.value], ([O]) => {
|
|
2526
2535
|
!O.startDate || !O.endDate || (v.value.startDate = O.startDate, v.value.endDate = O.endDate, e.updateDateRange(
|
|
2527
2536
|
v.value.startDate,
|
|
2528
2537
|
v.value.endDate
|
|
2529
|
-
),
|
|
2530
|
-
}),
|
|
2531
|
-
|
|
2538
|
+
), I());
|
|
2539
|
+
}), be([() => h.value], () => {
|
|
2540
|
+
I();
|
|
2532
2541
|
});
|
|
2533
2542
|
function _(O) {
|
|
2534
2543
|
if (O === "create") {
|
|
@@ -2549,7 +2558,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2549
2558
|
if (O === "export")
|
|
2550
2559
|
return a();
|
|
2551
2560
|
}
|
|
2552
|
-
const { breakpoints: C } =
|
|
2561
|
+
const { breakpoints: C } = at(), l = N(() => C.value.xs || C.value.sm), c = N(() => l.value ? 10 : 20), D = Zt(), B = N(() => [
|
|
2553
2562
|
{
|
|
2554
2563
|
label: w("inventory.transfer.receiveRequest.actions.create"),
|
|
2555
2564
|
value: "create",
|
|
@@ -2577,7 +2586,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2577
2586
|
key: "status",
|
|
2578
2587
|
entity: "purchaseOrder",
|
|
2579
2588
|
values: Array.from(
|
|
2580
|
-
new Set(e.purchaseOrders.value.map((
|
|
2589
|
+
new Set(e.purchaseOrders.value.map((V) => V.status))
|
|
2581
2590
|
)
|
|
2582
2591
|
}
|
|
2583
2592
|
], U = [
|
|
@@ -2585,40 +2594,40 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2585
2594
|
type: "string",
|
|
2586
2595
|
key: "netsuiteTransactionNumber",
|
|
2587
2596
|
entity: "purchaseOrder",
|
|
2588
|
-
values: e.purchaseOrders.value.map((
|
|
2597
|
+
values: e.purchaseOrders.value.map((V) => {
|
|
2589
2598
|
var d, b;
|
|
2590
|
-
return (b = (d =
|
|
2591
|
-
}).filter((
|
|
2599
|
+
return (b = (d = V.netSuite) == null ? void 0 : d.additionalInfo) == null ? void 0 : b.transactionnumber;
|
|
2600
|
+
}).filter((V) => V != null)
|
|
2592
2601
|
},
|
|
2593
2602
|
{
|
|
2594
2603
|
type: "string",
|
|
2595
2604
|
key: "netsuiteOrderNo",
|
|
2596
2605
|
entity: "purchaseOrder",
|
|
2597
|
-
values: e.purchaseOrders.value.map((
|
|
2606
|
+
values: e.purchaseOrders.value.map((V) => {
|
|
2598
2607
|
var d;
|
|
2599
|
-
return (d =
|
|
2600
|
-
}).filter((
|
|
2608
|
+
return (d = V.netSuite) == null ? void 0 : d.refNo;
|
|
2609
|
+
}).filter((V) => V != null)
|
|
2601
2610
|
},
|
|
2602
2611
|
{
|
|
2603
2612
|
type: "string",
|
|
2604
2613
|
key: "netsuiteOrderId",
|
|
2605
2614
|
entity: "purchaseOrder",
|
|
2606
|
-
values: e.purchaseOrders.value.map((
|
|
2615
|
+
values: e.purchaseOrders.value.map((V) => {
|
|
2607
2616
|
var d;
|
|
2608
|
-
return (d =
|
|
2609
|
-
}).filter((
|
|
2617
|
+
return (d = V.netSuite) == null ? void 0 : d.id;
|
|
2618
|
+
}).filter((V) => V != null)
|
|
2610
2619
|
}
|
|
2611
2620
|
];
|
|
2612
2621
|
return [...O, ...f.isEnabled ? U : []];
|
|
2613
2622
|
}), Y = q(null), K = N(() => {
|
|
2614
2623
|
if (!Y.value)
|
|
2615
2624
|
return e.purchaseOrders.value;
|
|
2616
|
-
const O =
|
|
2625
|
+
const O = Jt.build(Y.value);
|
|
2617
2626
|
return e.purchaseOrders.value.filter((U) => {
|
|
2618
|
-
var
|
|
2619
|
-
return
|
|
2627
|
+
var V, d, b, R;
|
|
2628
|
+
return Gt(
|
|
2620
2629
|
{
|
|
2621
|
-
netsuiteTransactionNumber: (d = (
|
|
2630
|
+
netsuiteTransactionNumber: (d = (V = U.netSuite) == null ? void 0 : V.additionalInfo) == null ? void 0 : d.transactionnumber,
|
|
2622
2631
|
netsuiteOrderNo: (b = U.netSuite) == null ? void 0 : b.refNo,
|
|
2623
2632
|
netsuiteOrderId: (R = U.netSuite) == null ? void 0 : R.id,
|
|
2624
2633
|
status: U.status
|
|
@@ -2628,8 +2637,8 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2628
2637
|
});
|
|
2629
2638
|
});
|
|
2630
2639
|
return (O, U) => {
|
|
2631
|
-
const
|
|
2632
|
-
return S(),
|
|
2640
|
+
const V = $("FmTable");
|
|
2641
|
+
return S(), W(Wt, {
|
|
2633
2642
|
title: s(w)("inventory.transfer.receiveRequest.title2"),
|
|
2634
2643
|
actions: B.value,
|
|
2635
2644
|
"onClick:action": _
|
|
@@ -2638,7 +2647,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2638
2647
|
var d, b;
|
|
2639
2648
|
return [
|
|
2640
2649
|
n("div", {
|
|
2641
|
-
class:
|
|
2650
|
+
class: G([
|
|
2642
2651
|
"flex flex-col gap-8 max-h-full",
|
|
2643
2652
|
{
|
|
2644
2653
|
"p-0": l.value,
|
|
@@ -2659,7 +2668,7 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2659
2668
|
filter: Y.value,
|
|
2660
2669
|
"onUpdate:filter": U[2] || (U[2] = (R) => Y.value = R)
|
|
2661
2670
|
}, null, 8, ["date-range", "search", "filter-attributes", "filter"]),
|
|
2662
|
-
(S(),
|
|
2671
|
+
(S(), W(V, {
|
|
2663
2672
|
style: _t(s(D).tableHeight),
|
|
2664
2673
|
"column-defs": s(u),
|
|
2665
2674
|
"row-data": K.value,
|
|
@@ -2675,32 +2684,32 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2675
2684
|
onRowClick: s(e).promptShowTransferDetails
|
|
2676
2685
|
}, {
|
|
2677
2686
|
default: A((X) => {
|
|
2678
|
-
var Z, he, ke,
|
|
2687
|
+
var Z, he, ke, re, we, Ne, Be, ze, Pe, Le, Ve, Re, o, m, E, H, ne, me, J, le;
|
|
2679
2688
|
return [
|
|
2680
2689
|
n("div", da, [
|
|
2681
2690
|
n("div", ca, [
|
|
2682
2691
|
y(s(fe), {
|
|
2683
2692
|
render: (ke = (he = (Z = X._id) == null ? void 0 : Z.column) == null ? void 0 : he.columnDef) == null ? void 0 : ke.cell,
|
|
2684
|
-
props: (we = (
|
|
2693
|
+
props: (we = (re = X._id) == null ? void 0 : re.getContext) == null ? void 0 : we.call(re)
|
|
2685
2694
|
}, null, 8, ["render", "props"])
|
|
2686
2695
|
]),
|
|
2687
2696
|
n("div", ma, [
|
|
2688
2697
|
y(s(fe), {
|
|
2689
2698
|
render: (ze = (Be = (Ne = X.supplier_name) == null ? void 0 : Ne.column) == null ? void 0 : Be.columnDef) == null ? void 0 : ze.cell,
|
|
2690
|
-
props: (Le = (
|
|
2699
|
+
props: (Le = (Pe = X.supplier_name) == null ? void 0 : Pe.getContext) == null ? void 0 : Le.call(Pe)
|
|
2691
2700
|
}, null, 8, ["render", "props"])
|
|
2692
2701
|
]),
|
|
2693
2702
|
n("div", pa, M(R.original.items.map((Fe) => `${Fe.name}`).join(", ")), 1),
|
|
2694
2703
|
R.original.ref ? (S(), T("div", fa, [
|
|
2695
2704
|
y(s(fe), {
|
|
2696
|
-
render: (o = (
|
|
2705
|
+
render: (o = (Re = (Ve = X.ref) == null ? void 0 : Ve.column) == null ? void 0 : Re.columnDef) == null ? void 0 : o.cell,
|
|
2697
2706
|
props: (E = (m = X.ref) == null ? void 0 : m.getContext) == null ? void 0 : E.call(m)
|
|
2698
2707
|
}, null, 8, ["render", "props"])
|
|
2699
2708
|
])) : j("", !0),
|
|
2700
2709
|
n("div", va, [
|
|
2701
2710
|
y(s(fe), {
|
|
2702
|
-
render: (me = (
|
|
2703
|
-
props: (
|
|
2711
|
+
render: (me = (ne = (H = X.status) == null ? void 0 : H.column) == null ? void 0 : ne.columnDef) == null ? void 0 : me.cell,
|
|
2712
|
+
props: (le = (J = X.status) == null ? void 0 : J.getContext) == null ? void 0 : le.call(J)
|
|
2704
2713
|
}, null, 8, ["render", "props"])
|
|
2705
2714
|
])
|
|
2706
2715
|
])
|
|
@@ -2712,19 +2721,20 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2712
2721
|
_: 1
|
|
2713
2722
|
}, 8, ["style", "column-defs", "row-data", "search-value", "loading", "page-size"]))
|
|
2714
2723
|
], 2),
|
|
2715
|
-
(S(),
|
|
2716
|
-
y(Eo,
|
|
2724
|
+
(S(), W(Tt, { to: "body" }, [
|
|
2725
|
+
y(Eo, Je(s(e).transferDialogProps.value, {
|
|
2717
2726
|
onSubmitted: s(e).fetchData
|
|
2718
2727
|
}), null, 16, ["onSubmitted"]),
|
|
2719
|
-
y(os,
|
|
2720
|
-
scope: s(
|
|
2728
|
+
y(os, Je({
|
|
2729
|
+
scope: s(Ze).RECEIVE_REQUEST
|
|
2721
2730
|
}, {
|
|
2722
2731
|
...s(e).transferDetailsProps.value,
|
|
2723
|
-
receivedMap: ((b = s(e).transferDetailsProps.value) == null ? void 0 : b.receivedMap) ?? {}
|
|
2732
|
+
receivedMap: ((b = s(e).transferDetailsProps.value) == null ? void 0 : b.receivedMap) ?? {},
|
|
2733
|
+
shipments: s(e).shipments.value ?? []
|
|
2724
2734
|
}, {
|
|
2725
2735
|
onSubmitted: s(e).fetchData
|
|
2726
2736
|
}), null, 16, ["scope", "onSubmitted"]),
|
|
2727
|
-
y(ua, Dt(
|
|
2737
|
+
y(ua, Dt(Pt(s(e).xilnexImportDialogProps.value)), null, 16)
|
|
2728
2738
|
]))
|
|
2729
2739
|
];
|
|
2730
2740
|
}),
|
|
@@ -2734,5 +2744,5 @@ const qo = { class: "flex flex-col flex-1" }, Uo = { class: "flex flex-col" }, N
|
|
|
2734
2744
|
}
|
|
2735
2745
|
});
|
|
2736
2746
|
export {
|
|
2737
|
-
|
|
2747
|
+
Ta as default
|
|
2738
2748
|
};
|