@feedmepos/mf-inventory-portal 1.8.0-dev.3 → 1.8.0-dev.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/App-DEbWEOwe.js +1537 -0
- package/dist/{ApprovalView-hV1msz5Y.js → ApprovalView-BEnYHIlU.js} +9 -9
- package/dist/{BindingsDialog-BX1Lopf0.js → BindingsDialog-CJVkMoBS.js} +2 -2
- package/dist/{BindingsPicker-BNKW8-XY.js → BindingsPicker-CX9o-xdQ.js} +2 -2
- package/dist/{BindingsTable-DiLDsL83.js → BindingsTable-Cil4LJ7l.js} +4 -4
- package/dist/{BulkReceiveRequestView-oQh6kFLc.js → BulkReceiveRequestView-DYEc2jPw.js} +21 -22
- package/dist/{ChangeLocationComponent.vue_vue_type_script_setup_true_lang-BaMcGU-x.js → ChangeLocationComponent.vue_vue_type_script_setup_true_lang-DoAv2mHA.js} +1 -1
- package/dist/{ClosingDraftView-sgLoaSf4.js → ClosingDraftView-Bz94Iejf.js} +20 -20
- package/dist/{ClosingHistoryView-BnE9HrzA.js → ClosingHistoryView-B479Y-mH.js} +5 -5
- package/dist/{ClosingTemplateView-BD3Pa11r.js → ClosingTemplateView-F_nx43n6.js} +18 -18
- package/dist/{CustomPrintTemplatePreview.vue_vue_type_script_setup_true_lang-DlbyxkMQ.js → CustomPrintTemplatePreview.vue_vue_type_script_setup_true_lang-DddYGHxQ.js} +1 -1
- package/dist/{DefaultView-CuzvVkfE.js → DefaultView-CkZOl0ov.js} +5 -5
- package/dist/{DeliveryOrderPrintPreview-w-1aAOY1.js → DeliveryOrderPrintPreview-BJEpwAX6.js} +2 -2
- package/dist/{EmailDialog.vue_vue_type_script_setup_true_lang-CxD12Qct.js → EmailDialog.vue_vue_type_script_setup_true_lang-BW988AoC.js} +29 -30
- package/dist/{FeatureCapabilityBadge.vue_vue_type_script_setup_true_lang-CMoQKl_a.js → FeatureCapabilityBadge.vue_vue_type_script_setup_true_lang-Izn-hTjK.js} +107 -118
- package/dist/{FmDateRangePickerChip.vue_vue_type_script_setup_true_lang-BqCh_vTP.js → FmDateRangePickerChip.vue_vue_type_script_setup_true_lang-CoUWxHlj.js} +1 -1
- package/dist/{FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-CAXnmdUy.js → FmFilterableMenuOptions.vue_vue_type_script_setup_true_lang-Ci81xTbl.js} +2 -2
- package/dist/{FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-NhOdW33O.js → FmInventoryTableToolbar.vue_vue_type_script_setup_true_lang-CnaHTAUZ.js} +2 -2
- package/dist/{FmMultiselectDialog-CULwA_hi.js → FmMultiselectDialog-BE8BlO6_.js} +2 -2
- package/dist/FmMultiselectDialog-COKgBmPZ.js +123 -0
- package/dist/{FmUnitInput.vue_vue_type_script_setup_true_lang-CI3Y9kDl.js → FmUnitInput.vue_vue_type_script_setup_true_lang-BQHd3NjM.js} +6 -6
- package/dist/ImportView-Crb_yrNb.js +1291 -0
- package/dist/{IngredientsView-pzpP6oXT.js → IngredientsView-lDypeR4c.js} +34 -35
- package/dist/{IntegrationExplorerView-C5aAhB6e.js → IntegrationExplorerView-DgOFGj7H.js} +4 -4
- package/dist/{IntegrationView-Bqun7nX0.js → IntegrationView-0sbjINo5.js} +973 -974
- package/dist/{InventoryBindingForm-r_Ua1C4a.js → InventoryBindingForm-BhyrjIXJ.js} +1 -1
- package/dist/InventoryBindingForm.vue_vue_type_script_setup_true_lang-KCz_BQ6T.js +472 -0
- package/dist/{InventoryBindingSummary-BQuZLohR.js → InventoryBindingSummary-CsfNKd1r.js} +1 -1
- package/dist/{NumberPrecisionInput.vue_vue_type_script_setup_true_lang-7r-QcJdU.js → NumberPrecisionInput.vue_vue_type_script_setup_true_lang-C32OoIBz.js} +1 -1
- package/dist/{ProductionRunDetailView-95fu_CfH.js → ProductionRunDetailView-BxbDtGMo.js} +4 -4
- package/dist/{ProductionRunLifecycleDialogs.vue_vue_type_script_setup_true_lang-CdOca1tV.js → ProductionRunLifecycleDialogs.vue_vue_type_script_setup_true_lang-BdJVvwSP.js} +9 -9
- package/dist/{ProductionRunView-DIjor_Ix.js → ProductionRunView-CJhNEIzT.js} +3 -3
- package/dist/{PublishView-DYObyHQq.js → PublishView-vkt6-D6P.js} +3 -3
- package/dist/{PurchaseOrderPrintPreview-C0jCmI9L.js → PurchaseOrderPrintPreview-25dHfVKp.js} +2 -2
- package/dist/{ReceiveRequestView-i7ibPfIE.js → ReceiveRequestView-BO4Z2dZu.js} +15 -16
- package/dist/RecipeView-B_AE7QQv.js +3428 -0
- package/dist/{SettingsView-CdBloj9k.js → SettingsView-qTUvQCuu.js} +163 -168
- package/dist/{StockView-g_6eJ62R.js → StockView-yh6qkYUS.js} +269 -270
- package/dist/{SubsidiaryTreeDialog.vue_vue_type_script_setup_true_lang-C1rKc7MA.js → SubsidiaryTreeDialog.vue_vue_type_script_setup_true_lang-Cn_fx9qG.js} +1 -1
- package/dist/{SupplierView-DkYp_Frj.js → SupplierView-Dqzu1Bvh.js} +14 -14
- package/dist/{SurchargeView-CfkV4Y3y.js → SurchargeView-CDosn36c.js} +7 -7
- package/dist/{SystemTrailDialog.vue_vue_type_script_setup_true_lang-2MtN1p5t.js → SystemTrailDialog.vue_vue_type_script_setup_true_lang-DZ3Gdlp9.js} +2 -2
- package/dist/{TemplatePublishDialog.vue_vue_type_script_setup_true_lang-CYMjKXq4.js → TemplatePublishDialog.vue_vue_type_script_setup_true_lang-CWoh2FqQ.js} +1 -1
- package/dist/{TransferDetails.vue_vue_type_script_setup_true_lang-D0zNr_vQ.js → TransferDetails.vue_vue_type_script_setup_true_lang-BtjKnIwf.js} +867 -844
- package/dist/{TransferTemplateView-Ne2gYUSn.js → TransferTemplateView-fDZcC9i4.js} +22 -23
- package/dist/{UnitCostHistoryView-Db0_otOb.js → UnitCostHistoryView-CmTTIXAp.js} +4 -4
- package/dist/{UnitDisplayControl.vue_vue_type_script_setup_true_lang-BzO1lq7j.js → UnitDisplayControl.vue_vue_type_script_setup_true_lang-DZihCM0T.js} +4 -4
- package/dist/{UnitView-CiCeQ63i.js → UnitView-BTx59sFK.js} +8 -8
- package/dist/{WarehouseView-BcuJSOMF.js → WarehouseView-BIFe08FJ.js} +8 -8
- package/dist/{WastageTemplateView-CPQmtOKQ.js → WastageTemplateView-B_oJqm0_.js} +15 -15
- package/dist/api/feature-flags.d.ts +2 -0
- package/dist/api/license.d.ts +0 -2
- package/dist/{app-DqJp3dcI.js → app-DyEvx3Em.js} +1628 -1817
- package/dist/app.d.ts +0 -150
- package/dist/app.js +1 -1
- package/dist/{closing-template-BNlgZviN.js → closing-template-FgcLy4RT.js} +1 -1
- package/dist/components/FeatureCapabilityBadge.vue.d.ts +1 -1
- package/dist/{date2-Ci7521dn.js → date2-Rv4IwT9a.js} +1 -1
- package/dist/{dayjs.min-Cyp32v4J.js → dayjs.min-DOq1QM_M.js} +1 -1
- package/dist/{decimal-BGdm5R3A.js → decimal-7vA05AaD.js} +2 -2
- package/dist/{defineDeepModel-B2cJ-rtd.js → defineDeepModel-22Md2SKY.js} +1 -1
- package/dist/{duplicate-template-By5WeKZ0.js → duplicate-template-D2tjCY7C.js} +1 -1
- package/dist/{core-Js7d-3Pv.js → feature-BMTKl6PK.js} +732 -389
- package/dist/feature-flags/core.d.ts +3 -2
- package/dist/feature-flags/portal-feature-catalog.d.ts +0 -5
- package/dist/feature-flags/vue.d.ts +2 -0
- package/dist/{format-time-from-id-Q8C2P96H.js → format-time-from-id-DXhm_Ji1.js} +1 -1
- package/dist/{format-unit-display-CICrmm8r.js → format-unit-display-DxWLjFPz.js} +13 -13
- package/dist/helper/menu-usage-module.d.ts +1 -1
- package/dist/{id-to-date-DeN5x0LR.js → id-to-date-VKlOL3mN.js} +1 -1
- package/dist/{import-export.helper-BOTQWxr6.js → import-export.helper-BiF5aKUp.js} +28 -28
- package/dist/{index-BbbqCCfp.js → index-DEl_gZn0.js} +3 -3
- package/dist/{index-tCYhLCKP.js → index-DdtsVAcv.js} +1 -1
- package/dist/{index-Cxm3Sgfv.js → index-DoBWE4Ci.js} +1 -1
- package/dist/{lz-string-Dy4Pg8mh.js → lz-string-BwQj8QRN.js} +1 -1
- package/dist/{netsuite-BaJjkDM8.js → netsuite-s1S33-lP.js} +2 -2
- package/dist/{number-CB36d2PQ.js → number-BmKjsNrc.js} +3 -3
- package/dist/{predefined-templates-DLm93Bpx.js → predefined-templates-BZ2KqNix.js} +1 -1
- package/dist/{purchase-order-template-CDhn9ZIF.js → purchase-order-template-CINU4my1.js} +1 -1
- package/dist/{recalculationUtils-Cqvefakh.js → recalculationUtils-R5tFu_ts.js} +1 -1
- package/dist/router/name.d.ts +0 -1
- package/dist/{row-action.enum-NTfVmGY8.js → row-action.enum-ePO-Py0V.js} +1 -1
- package/dist/{rules-C8dfM84-.js → rules-BZrZVzw7.js} +2 -2
- package/dist/{stock-BGB0Siue.js → stock-C2HOKq0k.js} +8 -8
- package/dist/{stock-Qu5IiN2_.js → stock-Ce1UvAZ3.js} +1 -1
- package/dist/stores/feature.d.ts +10 -9
- package/dist/stores/inventory.d.ts +0 -47
- package/dist/stores/supplier.d.ts +1 -1
- package/dist/style.css +1 -1
- package/dist/{supplier-CZdNOSMN.js → supplier-DgT66emI.js} +17 -17
- package/dist/{surcharge-Cm40oJvU.js → surcharge-CsVMuzPM.js} +1 -1
- package/dist/tsconfig.app.tsbuildinfo +1 -1
- package/dist/{uom-rules-L-IW4Nwk.js → uom-rules-CR1XukyM.js} +1 -1
- package/dist/{use-ingredient-select-dialog-B2TDVJM6.js → use-ingredient-select-dialog-CJkG4hEX.js} +2 -2
- package/dist/use-inventory-binding-dialog-B36kPj4V.js +113 -0
- package/dist/{use-template-enabled-locations-DYAPMvo9.js → use-template-enabled-locations-Boa9QLPV.js} +2 -2
- package/dist/{use-transfer-locations-w-9tymYS.js → use-transfer-locations-BxOygSUg.js} +2 -2
- package/dist/{useHrmPermission-BFCIo5sA.js → useHrmPermission-DLHAqbLV.js} +1 -1
- package/dist/{useNavigationMenu-BPHAH5sJ.js → useNavigationMenu-D6abZMGz.js} +102 -109
- package/dist/{useSseClient-CWjRacRs.js → useSseClient-C7pff-EW.js} +1 -1
- package/dist/views/ingredients/components/inventory-binding/InventoryBindingForm.vue.d.ts +0 -1
- package/dist/views/ingredients/components/inventory-binding/composables/use-inventory-binding-dialog.d.ts +0 -1
- package/dist/views/ingredients/components/inventory-binding/v2/InventoryBindingFormV2.vue.d.ts +0 -1
- package/dist/views/ingredients/components/inventory-binding/v2/composables/use-inventory-binding-dialog.d.ts +0 -1
- package/dist/views/ingredients/helper/is-linked-ingredient-error.d.ts +1 -1
- package/dist/views/integration/components/IntegrationCard.vue.d.ts +3 -3
- package/dist/views/recipe/helper/bulk-edit-simulation.helper.d.ts +0 -1
- package/dist/views/recipe/helper/import-recipe.d.ts +2 -2
- package/dist/{vue-i18n-S4YQ9w6a.js → vue-i18n-CpOOFhVU.js} +219 -219
- package/dist/{xlsx.util-CP8_VajN.js → xlsx.util-xwI5tVz6.js} +2 -2
- package/package.json +5 -5
- package/dist/App-DRXADP0k.js +0 -1498
- package/dist/DeprecateSoonWarningDialog.vue_vue_type_script_setup_true_lang-Bp8bjDU1.js +0 -58
- package/dist/FmMultiselectDialog-BqZgHP8s.js +0 -77
- package/dist/ImportView-DqQG673_.js +0 -1302
- package/dist/IngredientBindedItem.vue_vue_type_script_setup_true_lang-DfvNUu80.js +0 -51
- package/dist/IngredientGroupView-CyngKxPo.js +0 -1000
- package/dist/InventoryBindingForm.vue_vue_type_script_setup_true_lang-CYDuu4kU.js +0 -563
- package/dist/RecipeView-C5VO7yr3.js +0 -3625
- package/dist/feature-fG7d73oi.js +0 -371
- package/dist/index-Dqf27vLH.js +0 -841
- package/dist/random-CSbEbElR.js +0 -10
- package/dist/use-inventory-binding-dialog-BJ00hl5f.js +0 -152
- package/dist/usePromise-CbVUCxhj.js +0 -29
- package/dist/views/ingredient-group/IngredientGroupView.vue.d.ts +0 -3
- package/dist/views/ingredient-group/components/ingredient-group-dialog/IngredientGroupDialog.vue.d.ts +0 -31
- package/dist/views/ingredient-group/components/ingredient-group-dialog/IngredientGroupDialogProps.d.ts +0 -10
- package/dist/views/ingredient-group/components/ingredient-group-form/IngredientGroupForm.vue.d.ts +0 -21
- package/dist/views/ingredient-group/components/ingredient-group-form/IngredientGroupFormProps.d.ts +0 -12
- package/dist/views/ingredient-group/components/ingredient-group-rule-field/IngredientGroupRuleField.vue.d.ts +0 -37
- package/dist/views/ingredient-group/composables/use-ingredient-group-actions.d.ts +0 -24
- package/dist/views/ingredient-group/composables/use-ingredient-group-rule-item.d.ts +0 -31
- package/dist/views/ingredient-group/composables/use-ingredient-group-table.d.ts +0 -77
package/dist/feature-fG7d73oi.js
DELETED
|
@@ -1,371 +0,0 @@
|
|
|
1
|
-
import { useCoreStore as c } from "@feedmepos/mf-common";
|
|
2
|
-
import { a as R, u as m, k as P } from "./app-DqJp3dcI.js";
|
|
3
|
-
import { u as p, h as I, p as x } from "./index-Dqf27vLH.js";
|
|
4
|
-
import { ref as C } from "vue";
|
|
5
|
-
import { I as n } from "./core-Js7d-3Pv.js";
|
|
6
|
-
var q = { development: { appEndpoint: { licenseV2: "https://license-v2-dev.feedmeapi.com" } } };
|
|
7
|
-
function W() {
|
|
8
|
-
return q.development.appEndpoint.licenseV2.replace(/\/$/, "");
|
|
9
|
-
}
|
|
10
|
-
async function T(a) {
|
|
11
|
-
var s;
|
|
12
|
-
const t = c(), o = await fetch(`${W()}${a}`, {
|
|
13
|
-
headers: { authorization: `Bearer ${((s = t.sessionUser.value) == null ? void 0 : s.token) ?? ""}` },
|
|
14
|
-
mode: "cors"
|
|
15
|
-
});
|
|
16
|
-
if (!o.ok)
|
|
17
|
-
throw new Error(`License API request failed (${o.status}): ${await o.text()}`);
|
|
18
|
-
return await o.text();
|
|
19
|
-
}
|
|
20
|
-
function F() {
|
|
21
|
-
return {
|
|
22
|
-
async getWarehouseQuota(a) {
|
|
23
|
-
const t = await T(`/api/business/${a}/feature/warehouse`);
|
|
24
|
-
return JSON.parse(t);
|
|
25
|
-
},
|
|
26
|
-
async getInventoryPlan(a) {
|
|
27
|
-
const t = (await T(`/api/restaurant-features/${a}/inventory`)).trim();
|
|
28
|
-
if (!t || t === "null") return null;
|
|
29
|
-
if (t === "Standard" || t === "Premium") return t;
|
|
30
|
-
throw new Error(`Unexpected inventory plan response: ${t}`);
|
|
31
|
-
}
|
|
32
|
-
};
|
|
33
|
-
}
|
|
34
|
-
const B = /* @__PURE__ */ new Set([
|
|
35
|
-
// vivo pizza prod
|
|
36
|
-
"business_6687e91fa7240b001ba3f4c2",
|
|
37
|
-
// vivo dev
|
|
38
|
-
"business_669a1d2efc050a001cfbb5a2"
|
|
39
|
-
]), L = /* @__PURE__ */ new Set([
|
|
40
|
-
// zus dev
|
|
41
|
-
"business_671005de24a7f4001c87e25e",
|
|
42
|
-
// zus prod
|
|
43
|
-
"business_6776a1fe205a52001c516efa"
|
|
44
|
-
]);
|
|
45
|
-
function w() {
|
|
46
|
-
return {
|
|
47
|
-
isLoaded: !1,
|
|
48
|
-
planTier: "standard",
|
|
49
|
-
inventoryPlan: null,
|
|
50
|
-
warehouseQuota: [],
|
|
51
|
-
autoReceiveWarehouse: !1,
|
|
52
|
-
businessSupplierOnly: !1,
|
|
53
|
-
enableBackdatePo: !1,
|
|
54
|
-
enableClosingTemplate: !1,
|
|
55
|
-
enableIngredientGroup: !1,
|
|
56
|
-
enablePoTemplate: !1,
|
|
57
|
-
enableTotalCost: !1,
|
|
58
|
-
enableWastageTemplate: !1,
|
|
59
|
-
manualReceive: !1,
|
|
60
|
-
mustUseDefaultCost: !1,
|
|
61
|
-
mustUsePoTemplate: !1,
|
|
62
|
-
enableXilnexTransferNote: !1,
|
|
63
|
-
enableCustomAttribute: !1,
|
|
64
|
-
usePurchaseOrderV2: !1,
|
|
65
|
-
acceptRequireFulfillment: !1,
|
|
66
|
-
useOperatePurchaseOrderV2: !1,
|
|
67
|
-
inventory_xilnex_opening_migration: !1,
|
|
68
|
-
inventory_synergy_opening_migration: !1,
|
|
69
|
-
inventory_netsuite_inventory_transfer_out: !1,
|
|
70
|
-
inventory_portal_supplier_preparation_time: !1,
|
|
71
|
-
inventory_portal_delivery_order_write: !1,
|
|
72
|
-
inventory_pos_transfer_require_fulfillment: !1,
|
|
73
|
-
inventory_backdate_receive: !1,
|
|
74
|
-
inventory_purchase_order_custom_cost: !1,
|
|
75
|
-
inventory_bulk_import: !1,
|
|
76
|
-
inventory_portal_surcharge: !1,
|
|
77
|
-
inventory_purchase_order_cost_edit: !1,
|
|
78
|
-
inventory_purchase_order_price_adjustment: !1,
|
|
79
|
-
inventory_purchase_order_workflow_allow_to_mark_completed: !1,
|
|
80
|
-
inventory_recipe_v2: !1,
|
|
81
|
-
inventory_print_template: !1,
|
|
82
|
-
inventory_purchase_order_email: !1,
|
|
83
|
-
inventory_bulk_edit_recipes: !1,
|
|
84
|
-
inventory_receive_request_beta: !1,
|
|
85
|
-
inventory_portal_production_item: !1,
|
|
86
|
-
report_portal_po_forecast_days_constraint: null,
|
|
87
|
-
report_portal_po_forecast_days_default: 7
|
|
88
|
-
};
|
|
89
|
-
}
|
|
90
|
-
const e = C(w()), G = () => ({
|
|
91
|
-
get businessDbName() {
|
|
92
|
-
var o;
|
|
93
|
-
return `business_${((o = c().currentBusiness.value) == null ? void 0 : o._id) ?? ""}`;
|
|
94
|
-
},
|
|
95
|
-
get isWarehouse() {
|
|
96
|
-
var t;
|
|
97
|
-
return ((t = m()._currentLocation) == null ? void 0 : t.type) === P.enum.warehouse;
|
|
98
|
-
},
|
|
99
|
-
get restaurantPosVersion() {
|
|
100
|
-
var o;
|
|
101
|
-
const a = m();
|
|
102
|
-
return (o = c().restaurants.value.find(
|
|
103
|
-
(s) => {
|
|
104
|
-
var i;
|
|
105
|
-
return s._id === ((i = a._currentLocation) == null ? void 0 : i.doc._id);
|
|
106
|
-
}
|
|
107
|
-
)) == null ? void 0 : o.posVersion;
|
|
108
|
-
},
|
|
109
|
-
get enableTotalCost() {
|
|
110
|
-
return e.value.enableTotalCost;
|
|
111
|
-
},
|
|
112
|
-
get enableBackdatePo() {
|
|
113
|
-
return e.value.enableBackdatePo;
|
|
114
|
-
},
|
|
115
|
-
/** @deprecated TODO: remove */
|
|
116
|
-
get autoReceiveWarehouse() {
|
|
117
|
-
return e.value.autoReceiveWarehouse;
|
|
118
|
-
},
|
|
119
|
-
/** @deprecated TODO: remove */
|
|
120
|
-
get manualReceive() {
|
|
121
|
-
return e.value.manualReceive;
|
|
122
|
-
},
|
|
123
|
-
get isLoaded() {
|
|
124
|
-
return e.value.isLoaded;
|
|
125
|
-
},
|
|
126
|
-
get planTier() {
|
|
127
|
-
return e.value.planTier;
|
|
128
|
-
},
|
|
129
|
-
get inventoryPlan() {
|
|
130
|
-
return e.value.inventoryPlan;
|
|
131
|
-
},
|
|
132
|
-
get warehouseQuota() {
|
|
133
|
-
return e.value.warehouseQuota;
|
|
134
|
-
},
|
|
135
|
-
hasPlanTier(a) {
|
|
136
|
-
return I(e.value.planTier, a);
|
|
137
|
-
},
|
|
138
|
-
get enablePoTemplate() {
|
|
139
|
-
return e.value.enablePoTemplate;
|
|
140
|
-
},
|
|
141
|
-
get enableClosingTemplate() {
|
|
142
|
-
return e.value.enableClosingTemplate;
|
|
143
|
-
},
|
|
144
|
-
get enableWastageTemplate() {
|
|
145
|
-
return e.value.enableWastageTemplate;
|
|
146
|
-
},
|
|
147
|
-
get enableIngredientGroup() {
|
|
148
|
-
return e.value.enableIngredientGroup;
|
|
149
|
-
},
|
|
150
|
-
get mustUsePoTemplate() {
|
|
151
|
-
return e.value.mustUsePoTemplate;
|
|
152
|
-
},
|
|
153
|
-
get businessSupplierOnly() {
|
|
154
|
-
return e.value.businessSupplierOnly;
|
|
155
|
-
},
|
|
156
|
-
get enableXilnexTransferNote() {
|
|
157
|
-
return e.value.enableXilnexTransferNote;
|
|
158
|
-
},
|
|
159
|
-
get enabledXilnexOpeningMigration() {
|
|
160
|
-
return e.value.inventory_xilnex_opening_migration;
|
|
161
|
-
},
|
|
162
|
-
get enabledSynergyOpeningMigration() {
|
|
163
|
-
return e.value.inventory_synergy_opening_migration;
|
|
164
|
-
},
|
|
165
|
-
get enableCustomAttribute() {
|
|
166
|
-
return e.value.enableCustomAttribute;
|
|
167
|
-
},
|
|
168
|
-
get usePurchaseOrderV2() {
|
|
169
|
-
return e.value.usePurchaseOrderV2;
|
|
170
|
-
},
|
|
171
|
-
get acceptRequireFulfillment() {
|
|
172
|
-
return e.value.acceptRequireFulfillment;
|
|
173
|
-
},
|
|
174
|
-
get useOperatePurchaseOrderV2() {
|
|
175
|
-
return e.value.useOperatePurchaseOrderV2;
|
|
176
|
-
},
|
|
177
|
-
get isNetSuiteInventoryTransferOutEnabled() {
|
|
178
|
-
return e.value.inventory_netsuite_inventory_transfer_out;
|
|
179
|
-
},
|
|
180
|
-
get enableSupplierPreparationTime() {
|
|
181
|
-
return e.value.inventory_portal_supplier_preparation_time;
|
|
182
|
-
},
|
|
183
|
-
get enablePortalDeliveryOrderWrite() {
|
|
184
|
-
return e.value.inventory_portal_delivery_order_write ?? !0;
|
|
185
|
-
},
|
|
186
|
-
get enablePOSTransferRequireFulfillment() {
|
|
187
|
-
return e.value.inventory_pos_transfer_require_fulfillment;
|
|
188
|
-
},
|
|
189
|
-
get enableBackdateReceive() {
|
|
190
|
-
return e.value.inventory_backdate_receive;
|
|
191
|
-
},
|
|
192
|
-
get enablePurchaseOrderReceiveWithCustomCost() {
|
|
193
|
-
return e.value.inventory_purchase_order_custom_cost;
|
|
194
|
-
},
|
|
195
|
-
get enableBulkImport() {
|
|
196
|
-
return e.value.inventory_bulk_import;
|
|
197
|
-
},
|
|
198
|
-
get enableSurcharge() {
|
|
199
|
-
return e.value.inventory_portal_surcharge;
|
|
200
|
-
},
|
|
201
|
-
get enablePurchaseOrderCostEdit() {
|
|
202
|
-
return e.value.inventory_purchase_order_cost_edit;
|
|
203
|
-
},
|
|
204
|
-
get enablePurchaseOrderPriceAdjustment() {
|
|
205
|
-
return e.value.inventory_purchase_order_price_adjustment;
|
|
206
|
-
},
|
|
207
|
-
get poWorkflowAllowToMarkCompleted() {
|
|
208
|
-
return e.value.inventory_purchase_order_workflow_allow_to_mark_completed;
|
|
209
|
-
},
|
|
210
|
-
get enableRecipeV2() {
|
|
211
|
-
return e.value.inventory_recipe_v2;
|
|
212
|
-
},
|
|
213
|
-
get enablePrintTemplate() {
|
|
214
|
-
return e.value.inventory_print_template;
|
|
215
|
-
},
|
|
216
|
-
get enablePurchaseOrderEmail() {
|
|
217
|
-
return e.value.inventory_purchase_order_email;
|
|
218
|
-
},
|
|
219
|
-
get enableBulkEditRecipes() {
|
|
220
|
-
return e.value.inventory_bulk_edit_recipes;
|
|
221
|
-
},
|
|
222
|
-
get enableReceiveRequestBeta() {
|
|
223
|
-
return e.value.inventory_receive_request_beta;
|
|
224
|
-
},
|
|
225
|
-
get enableProductionRun() {
|
|
226
|
-
return e.value.inventory_portal_production_item;
|
|
227
|
-
},
|
|
228
|
-
get poForecastDaysConstraint() {
|
|
229
|
-
return e.value.report_portal_po_forecast_days_constraint;
|
|
230
|
-
},
|
|
231
|
-
get poForecastDaysDefault() {
|
|
232
|
-
return e.value.report_portal_po_forecast_days_default;
|
|
233
|
-
},
|
|
234
|
-
async init() {
|
|
235
|
-
const a = c(), { init: t, setBusiness: o } = p(), s = F(), i = R(), u = a.namespace.value === "prod";
|
|
236
|
-
await t({
|
|
237
|
-
apiKey: u ? "6GhcttsJ9Rj9cTevcdrpin" : "MaGoXrEWuEJNpWgKTqseee"
|
|
238
|
-
// url: 'https://flag.feedme.farm/api/v1/', // optional -> this is a default URL value
|
|
239
|
-
// enableAnalytics: true, // optional, defaults to true
|
|
240
|
-
// cacheFlags: true // optional, defaults to true
|
|
241
|
-
}), m().watchLocation(async (v) => {
|
|
242
|
-
var g, b, h;
|
|
243
|
-
if (!v) {
|
|
244
|
-
e.value = w();
|
|
245
|
-
return;
|
|
246
|
-
}
|
|
247
|
-
const d = ((g = a.currentBusiness.value) == null ? void 0 : g._id) ?? "";
|
|
248
|
-
await o(d);
|
|
249
|
-
const [l, _] = await Promise.allSettled([
|
|
250
|
-
s.getInventoryPlan(v.doc._id),
|
|
251
|
-
s.getWarehouseQuota(d)
|
|
252
|
-
]);
|
|
253
|
-
l.status === "rejected" && console.error(
|
|
254
|
-
"Unable to load the inventory plan from the license API",
|
|
255
|
-
l.reason
|
|
256
|
-
), _.status === "rejected" && console.error(
|
|
257
|
-
"Unable to load the warehouse quota from the license API",
|
|
258
|
-
_.reason
|
|
259
|
-
);
|
|
260
|
-
const k = `business_${d}`, S = v.type === P.enum.warehouse, f = (
|
|
261
|
-
// if menu v4, must manual receive && must use outlet app
|
|
262
|
-
((b = a.currentBusiness.value) == null ? void 0 : b.menuVersion) === "v4" && // more guard for businesses using menu v4, only those listed for manual receive will be included
|
|
263
|
-
// TODO: may be removed to use menu version only
|
|
264
|
-
B.has(this.businessDbName)
|
|
265
|
-
), y = L.has(k) || r(n.inventory_portal_must_use_transfer_template), O = r(n.inventory_purchase_order_backdate) && (this.isWarehouse || i.state.closing !== null);
|
|
266
|
-
e.value = {
|
|
267
|
-
isLoaded: !0,
|
|
268
|
-
planTier: x(
|
|
269
|
-
l.status === "fulfilled" ? l.value : null
|
|
270
|
-
),
|
|
271
|
-
inventoryPlan: l.status === "fulfilled" ? l.value : null,
|
|
272
|
-
warehouseQuota: _.status === "fulfilled" ? _.value : [],
|
|
273
|
-
enableTotalCost: ((h = a.currentBusiness.value) == null ? void 0 : h.menuVersion) === "v4",
|
|
274
|
-
enableBackdatePo: O,
|
|
275
|
-
autoReceiveWarehouse: S && !f,
|
|
276
|
-
manualReceive: f,
|
|
277
|
-
enablePoTemplate: y,
|
|
278
|
-
enableClosingTemplate: r(n.inventory_pos_closing_v2),
|
|
279
|
-
enableWastageTemplate: r(n.inventory_pos_adjust_v2_wastage),
|
|
280
|
-
enableIngredientGroup: r(n.inventory_ingredient_group),
|
|
281
|
-
mustUsePoTemplate: y,
|
|
282
|
-
businessSupplierOnly: y,
|
|
283
|
-
enableXilnexTransferNote: r(n.inventory_portal_xilnex_transfer_note),
|
|
284
|
-
enableCustomAttribute: r(n.inventory_portal_custom_attribute),
|
|
285
|
-
usePurchaseOrderV2: r(n.inventory_portal_purchase_order_v2),
|
|
286
|
-
acceptRequireFulfillment: r(
|
|
287
|
-
n.inventory_portal_accept_require_fulfillment
|
|
288
|
-
),
|
|
289
|
-
useOperatePurchaseOrderV2: r(n.inventory_portal_po_operate_v2),
|
|
290
|
-
inventory_xilnex_opening_migration: r(
|
|
291
|
-
n.inventory_xilnex_opening_migration
|
|
292
|
-
),
|
|
293
|
-
inventory_synergy_opening_migration: r(
|
|
294
|
-
n.inventory_synergy_opening_migration
|
|
295
|
-
),
|
|
296
|
-
inventory_netsuite_inventory_transfer_out: r(
|
|
297
|
-
n.inventory_netsuite_inventory_transfer_out
|
|
298
|
-
),
|
|
299
|
-
inventory_portal_supplier_preparation_time: r(
|
|
300
|
-
n.inventory_portal_supplier_preparation_time
|
|
301
|
-
),
|
|
302
|
-
inventory_portal_delivery_order_write: r(
|
|
303
|
-
n.inventory_portal_delivery_order_write
|
|
304
|
-
),
|
|
305
|
-
inventory_pos_transfer_require_fulfillment: r(
|
|
306
|
-
n.inventory_pos_transfer_require_fulfillment
|
|
307
|
-
),
|
|
308
|
-
inventory_backdate_receive: r(n.inventory_backdate_receive),
|
|
309
|
-
inventory_purchase_order_custom_cost: r(
|
|
310
|
-
n.inventory_purchase_order_custom_cost
|
|
311
|
-
),
|
|
312
|
-
inventory_bulk_import: r(n.inventory_bulk_import),
|
|
313
|
-
inventory_portal_surcharge: r(n.inventory_portal_surcharge),
|
|
314
|
-
inventory_purchase_order_cost_edit: r(
|
|
315
|
-
n.inventory_purchase_order_cost_edit
|
|
316
|
-
),
|
|
317
|
-
inventory_purchase_order_price_adjustment: r(
|
|
318
|
-
n.inventory_purchase_order_price_adjustment
|
|
319
|
-
),
|
|
320
|
-
inventory_purchase_order_workflow_allow_to_mark_completed: r(
|
|
321
|
-
n.inventory_purchase_order_workflow_allow_to_mark_completed
|
|
322
|
-
),
|
|
323
|
-
inventory_recipe_v2: r(n.inventory_recipe_v2),
|
|
324
|
-
inventory_print_template: r(n.inventory_print_template),
|
|
325
|
-
inventory_purchase_order_email: r(n.inventory_purchase_order_email),
|
|
326
|
-
inventory_bulk_edit_recipes: r(n.inventory_bulk_edit_recipes),
|
|
327
|
-
inventory_receive_request_beta: r(
|
|
328
|
-
"inventory_receive_request_beta"
|
|
329
|
-
),
|
|
330
|
-
inventory_portal_production_item: r(
|
|
331
|
-
n.inventory_portal_production_item
|
|
332
|
-
),
|
|
333
|
-
report_portal_po_forecast_days_constraint: N(
|
|
334
|
-
"report_portal_po_forecast_days_constraint"
|
|
335
|
-
),
|
|
336
|
-
report_portal_po_forecast_days_default: V(
|
|
337
|
-
"report_portal_po_forecast_days_default",
|
|
338
|
-
7
|
|
339
|
-
)
|
|
340
|
-
};
|
|
341
|
-
}, "feature");
|
|
342
|
-
},
|
|
343
|
-
async awaitFeatureLoaded(a) {
|
|
344
|
-
return new Promise((t) => {
|
|
345
|
-
const o = () => {
|
|
346
|
-
e.value.isLoaded ? t(a()) : setTimeout(o, 100);
|
|
347
|
-
};
|
|
348
|
-
o();
|
|
349
|
-
});
|
|
350
|
-
}
|
|
351
|
-
});
|
|
352
|
-
function r(a, t) {
|
|
353
|
-
t = t === void 0 ? null : t;
|
|
354
|
-
const { getFlagValue: o } = p();
|
|
355
|
-
return o(a, (s) => s === "true") ?? t;
|
|
356
|
-
}
|
|
357
|
-
function N(a) {
|
|
358
|
-
const { getFlagValue: t } = p();
|
|
359
|
-
return t(a, (s) => s.trim() ? s.trim() : null) ?? null;
|
|
360
|
-
}
|
|
361
|
-
function V(a, t) {
|
|
362
|
-
const { getFlagValue: o } = p();
|
|
363
|
-
return o(a, (i) => {
|
|
364
|
-
const u = parseInt(i, 10);
|
|
365
|
-
return isNaN(u) ? null : u;
|
|
366
|
-
}) ?? t;
|
|
367
|
-
}
|
|
368
|
-
export {
|
|
369
|
-
n as InventoryFeatureFlags,
|
|
370
|
-
G as useFeatureStore
|
|
371
|
-
};
|