@vicacha-devs/medusa-plugin-barcode 0.0.1 → 0.1.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.
|
@@ -2003,84 +2003,85 @@ var GuardedBarcodesOverviewPage = () => /* @__PURE__ */ (0, react_jsx_runtime.js
|
|
|
2003
2003
|
permission: "barcodes.read",
|
|
2004
2004
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BarcodesOverviewPage, {})
|
|
2005
2005
|
});
|
|
2006
|
-
// src/admin/routes/barcodes/
|
|
2007
|
-
var
|
|
2006
|
+
// src/admin/routes/barcodes/lookup/page.tsx
|
|
2007
|
+
var BarcodeLookupPage = () => {
|
|
2008
2008
|
const studio = useBarcodeStudio();
|
|
2009
2009
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_ui.Toaster, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer, {
|
|
2010
|
-
widgetsZonePrefix: "barcodes.
|
|
2010
|
+
widgetsZonePrefix: "barcodes.lookup.details",
|
|
2011
2011
|
preferredLayoutId: _medusajs_admin_shared.CORE_LAYOUT_IDS.TWO_COLUMN,
|
|
2012
2012
|
sections: {
|
|
2013
2013
|
main: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer.Entry, {
|
|
2014
|
-
id: "
|
|
2015
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
2016
|
-
form: studio.
|
|
2017
|
-
onFormChange: studio.
|
|
2018
|
-
|
|
2019
|
-
|
|
2014
|
+
id: "BarcodeLookupMainSection",
|
|
2015
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(GtinLookupLookupSection, {
|
|
2016
|
+
form: studio.lookupForm,
|
|
2017
|
+
onFormChange: studio.setLookupForm,
|
|
2018
|
+
lookupResult: studio.lookupResult,
|
|
2019
|
+
onLookup: () => void studio.handleLookupBarcode(),
|
|
2020
|
+
onCreateProduct: () => void studio.handleCreateProductFromBarcode()
|
|
2020
2021
|
})
|
|
2021
2022
|
}),
|
|
2022
2023
|
side: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer.Entry, {
|
|
2023
|
-
id: "
|
|
2024
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
2024
|
+
id: "BarcodeLookupBatchSection",
|
|
2025
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(GtinLookupBatchSection, {
|
|
2026
|
+
form: studio.lookupForm,
|
|
2027
|
+
onFormChange: studio.setLookupForm,
|
|
2028
|
+
barcodes: studio.barcodes,
|
|
2029
|
+
onBatchImport: () => void studio.handleBatchImport()
|
|
2030
|
+
})
|
|
2025
2031
|
})
|
|
2026
2032
|
}
|
|
2027
2033
|
})] });
|
|
2028
2034
|
};
|
|
2029
2035
|
var Breadcrumb$4 = () => {
|
|
2030
2036
|
const { t } = (0, react_i18next.useTranslation)();
|
|
2031
|
-
return t("
|
|
2037
|
+
return t("lookupTab.lookupTitle");
|
|
2032
2038
|
};
|
|
2033
2039
|
var config$4 = (0, _medusajs_admin_sdk.defineRouteConfig)({
|
|
2034
|
-
label: "
|
|
2040
|
+
label: "lookupTab.lookupTitle",
|
|
2035
2041
|
translationNs: "barcodes",
|
|
2036
|
-
icon: _medusajs_icons.
|
|
2042
|
+
icon: _medusajs_icons.MagnifyingGlass
|
|
2037
2043
|
});
|
|
2038
2044
|
var handle$4 = { breadcrumb: () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Breadcrumb$4, {}) };
|
|
2039
|
-
var
|
|
2045
|
+
var GuardedBarcodeLookupPage = () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RbacGuard, {
|
|
2040
2046
|
permission: "barcodes.read",
|
|
2041
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
2047
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BarcodeLookupPage, {})
|
|
2042
2048
|
});
|
|
2043
|
-
// src/admin/routes/barcodes/
|
|
2044
|
-
var
|
|
2049
|
+
// src/admin/routes/barcodes/print/page.tsx
|
|
2050
|
+
var BarcodePrintCenterPage = () => {
|
|
2045
2051
|
const studio = useBarcodeStudio();
|
|
2046
2052
|
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_ui.Toaster, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer, {
|
|
2047
|
-
widgetsZonePrefix: "barcodes.
|
|
2053
|
+
widgetsZonePrefix: "barcodes.print.details",
|
|
2048
2054
|
preferredLayoutId: _medusajs_admin_shared.CORE_LAYOUT_IDS.TWO_COLUMN,
|
|
2049
2055
|
sections: {
|
|
2050
2056
|
main: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer.Entry, {
|
|
2051
|
-
id: "
|
|
2052
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
2053
|
-
form: studio.
|
|
2054
|
-
onFormChange: studio.
|
|
2055
|
-
|
|
2056
|
-
|
|
2057
|
+
id: "BarcodePrintDesignerSection",
|
|
2058
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LabelPrintDesignerSection, {
|
|
2059
|
+
form: studio.printForm,
|
|
2060
|
+
onFormChange: studio.setPrintForm,
|
|
2061
|
+
templates: studio.templates,
|
|
2062
|
+
onRenderLabels: () => void studio.handleRenderLabels()
|
|
2057
2063
|
})
|
|
2058
2064
|
}),
|
|
2059
2065
|
side: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer.Entry, {
|
|
2060
|
-
id: "
|
|
2061
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
2062
|
-
sessions: studio.sessions,
|
|
2063
|
-
selectedSessionId: studio.selectedSessionId,
|
|
2064
|
-
onSelectSession: studio.setSelectedSessionId,
|
|
2065
|
-
onApplySession: (id) => void studio.handleApplyCountSession(id)
|
|
2066
|
-
})
|
|
2066
|
+
id: "BarcodePrintOutputSection",
|
|
2067
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(LabelPrintOutputSection, { output: studio.printOutput })
|
|
2067
2068
|
})
|
|
2068
2069
|
}
|
|
2069
2070
|
})] });
|
|
2070
2071
|
};
|
|
2071
2072
|
var Breadcrumb$3 = () => {
|
|
2072
2073
|
const { t } = (0, react_i18next.useTranslation)();
|
|
2073
|
-
return t("
|
|
2074
|
+
return t("tabs.print");
|
|
2074
2075
|
};
|
|
2075
2076
|
var config$3 = (0, _medusajs_admin_sdk.defineRouteConfig)({
|
|
2076
|
-
label: "
|
|
2077
|
+
label: "tabs.print",
|
|
2077
2078
|
translationNs: "barcodes",
|
|
2078
|
-
icon: _medusajs_icons.
|
|
2079
|
+
icon: _medusajs_icons.DocumentText
|
|
2079
2080
|
});
|
|
2080
2081
|
var handle$3 = { breadcrumb: () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Breadcrumb$3, {}) };
|
|
2081
|
-
var
|
|
2082
|
+
var GuardedBarcodePrintCenterPage = () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RbacGuard, {
|
|
2082
2083
|
permission: "barcodes.read",
|
|
2083
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(
|
|
2084
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BarcodePrintCenterPage, {})
|
|
2084
2085
|
});
|
|
2085
2086
|
// src/admin/routes/barcodes/providers/page.tsx
|
|
2086
2087
|
var BarcodeProvidersPage = () => {
|
|
@@ -2118,6 +2119,48 @@ var GuardedBarcodeProvidersPage = () => /* @__PURE__ */ (0, react_jsx_runtime.js
|
|
|
2118
2119
|
permission: "barcodes.read",
|
|
2119
2120
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BarcodeProvidersPage, {})
|
|
2120
2121
|
});
|
|
2122
|
+
// src/admin/routes/barcodes/stock-take/page.tsx
|
|
2123
|
+
var BarcodeStockTakePage = () => {
|
|
2124
|
+
const studio = useBarcodeStudio();
|
|
2125
|
+
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_ui.Toaster, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer, {
|
|
2126
|
+
widgetsZonePrefix: "barcodes.stock_take.details",
|
|
2127
|
+
preferredLayoutId: _medusajs_admin_shared.CORE_LAYOUT_IDS.TWO_COLUMN,
|
|
2128
|
+
sections: {
|
|
2129
|
+
main: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer.Entry, {
|
|
2130
|
+
id: "StockTakeControlsSection",
|
|
2131
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(StockTakeControlsSection, {
|
|
2132
|
+
form: studio.countForm,
|
|
2133
|
+
onFormChange: studio.setCountForm,
|
|
2134
|
+
onCreateSession: () => void studio.handleCreateCountSession(),
|
|
2135
|
+
onScanDelta: (delta) => void studio.handleScanIntoSession(delta)
|
|
2136
|
+
})
|
|
2137
|
+
}),
|
|
2138
|
+
side: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer.Entry, {
|
|
2139
|
+
id: "StockTakeSessionsSection",
|
|
2140
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(StockTakeSessionsSection, {
|
|
2141
|
+
sessions: studio.sessions,
|
|
2142
|
+
selectedSessionId: studio.selectedSessionId,
|
|
2143
|
+
onSelectSession: studio.setSelectedSessionId,
|
|
2144
|
+
onApplySession: (id) => void studio.handleApplyCountSession(id)
|
|
2145
|
+
})
|
|
2146
|
+
})
|
|
2147
|
+
}
|
|
2148
|
+
})] });
|
|
2149
|
+
};
|
|
2150
|
+
var Breadcrumb$1 = () => {
|
|
2151
|
+
const { t } = (0, react_i18next.useTranslation)();
|
|
2152
|
+
return t("stockTakeTab.createTitle");
|
|
2153
|
+
};
|
|
2154
|
+
var config$1 = (0, _medusajs_admin_sdk.defineRouteConfig)({
|
|
2155
|
+
label: "stockTakeTab.createTitle",
|
|
2156
|
+
translationNs: "barcodes",
|
|
2157
|
+
icon: _medusajs_icons.Buildings
|
|
2158
|
+
});
|
|
2159
|
+
var handle$1 = { breadcrumb: () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Breadcrumb$1, {}) };
|
|
2160
|
+
var GuardedBarcodeStockTakePage = () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RbacGuard, {
|
|
2161
|
+
permission: "barcodes.read",
|
|
2162
|
+
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BarcodeStockTakePage, {})
|
|
2163
|
+
});
|
|
2121
2164
|
// src/admin/routes/barcodes/tags/page.tsx
|
|
2122
2165
|
var BarcodeTagsPage = () => {
|
|
2123
2166
|
const navigate = (0, react_router_dom.useNavigate)();
|
|
@@ -2145,16 +2188,16 @@ var BarcodeTagsPage = () => {
|
|
|
2145
2188
|
}
|
|
2146
2189
|
})] });
|
|
2147
2190
|
};
|
|
2148
|
-
var Breadcrumb
|
|
2191
|
+
var Breadcrumb = () => {
|
|
2149
2192
|
const { t } = (0, react_i18next.useTranslation)();
|
|
2150
2193
|
return t("tagsTab.createTitle");
|
|
2151
2194
|
};
|
|
2152
|
-
var config
|
|
2195
|
+
var config = (0, _medusajs_admin_sdk.defineRouteConfig)({
|
|
2153
2196
|
label: "tagsTab.createTitle",
|
|
2154
2197
|
translationNs: "barcodes",
|
|
2155
2198
|
icon: _medusajs_icons.Tag
|
|
2156
2199
|
});
|
|
2157
|
-
var handle
|
|
2200
|
+
var handle = { breadcrumb: () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Breadcrumb, {}) };
|
|
2158
2201
|
var GuardedBarcodeTagsPage = () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RbacGuard, {
|
|
2159
2202
|
permission: "barcodes.read",
|
|
2160
2203
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BarcodeTagsPage, {})
|
|
@@ -2186,49 +2229,6 @@ var GuardedBarcodeTagCreateModal = () => /* @__PURE__ */ (0, react_jsx_runtime.j
|
|
|
2186
2229
|
permission: "barcodes.write",
|
|
2187
2230
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BarcodeTagCreateModal, {})
|
|
2188
2231
|
});
|
|
2189
|
-
// src/admin/routes/barcodes/lookup/page.tsx
|
|
2190
|
-
var BarcodeLookupPage = () => {
|
|
2191
|
-
const studio = useBarcodeStudio();
|
|
2192
|
-
return /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(react_jsx_runtime.Fragment, { children: [/* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_ui.Toaster, {}), /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer, {
|
|
2193
|
-
widgetsZonePrefix: "barcodes.lookup.details",
|
|
2194
|
-
preferredLayoutId: _medusajs_admin_shared.CORE_LAYOUT_IDS.TWO_COLUMN,
|
|
2195
|
-
sections: {
|
|
2196
|
-
main: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer.Entry, {
|
|
2197
|
-
id: "BarcodeLookupMainSection",
|
|
2198
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(GtinLookupLookupSection, {
|
|
2199
|
-
form: studio.lookupForm,
|
|
2200
|
-
onFormChange: studio.setLookupForm,
|
|
2201
|
-
lookupResult: studio.lookupResult,
|
|
2202
|
-
onLookup: () => void studio.handleLookupBarcode(),
|
|
2203
|
-
onCreateProduct: () => void studio.handleCreateProductFromBarcode()
|
|
2204
|
-
})
|
|
2205
|
-
}),
|
|
2206
|
-
side: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(_medusajs_dashboard_components.LayoutComposer.Entry, {
|
|
2207
|
-
id: "BarcodeLookupBatchSection",
|
|
2208
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(GtinLookupBatchSection, {
|
|
2209
|
-
form: studio.lookupForm,
|
|
2210
|
-
onFormChange: studio.setLookupForm,
|
|
2211
|
-
barcodes: studio.barcodes,
|
|
2212
|
-
onBatchImport: () => void studio.handleBatchImport()
|
|
2213
|
-
})
|
|
2214
|
-
})
|
|
2215
|
-
}
|
|
2216
|
-
})] });
|
|
2217
|
-
};
|
|
2218
|
-
var Breadcrumb = () => {
|
|
2219
|
-
const { t } = (0, react_i18next.useTranslation)();
|
|
2220
|
-
return t("lookupTab.lookupTitle");
|
|
2221
|
-
};
|
|
2222
|
-
var config = (0, _medusajs_admin_sdk.defineRouteConfig)({
|
|
2223
|
-
label: "lookupTab.lookupTitle",
|
|
2224
|
-
translationNs: "barcodes",
|
|
2225
|
-
icon: _medusajs_icons.MagnifyingGlass
|
|
2226
|
-
});
|
|
2227
|
-
var handle = { breadcrumb: () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Breadcrumb, {}) };
|
|
2228
|
-
var GuardedBarcodeLookupPage = () => /* @__PURE__ */ (0, react_jsx_runtime.jsx)(RbacGuard, {
|
|
2229
|
-
permission: "barcodes.read",
|
|
2230
|
-
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)(BarcodeLookupPage, {})
|
|
2231
|
-
});
|
|
2232
2232
|
var ar_default = {
|
|
2233
2233
|
nav: { "label": "استوديو الباركود والملصقات" },
|
|
2234
2234
|
header: {
|
|
@@ -3840,8 +3840,8 @@ var plugin = {
|
|
|
3840
3840
|
}
|
|
3841
3841
|
},
|
|
3842
3842
|
{
|
|
3843
|
-
Component:
|
|
3844
|
-
path: "/barcodes/
|
|
3843
|
+
Component: GuardedBarcodeLookupPage,
|
|
3844
|
+
path: "/barcodes/lookup",
|
|
3845
3845
|
handle: {
|
|
3846
3846
|
label: config$4.label,
|
|
3847
3847
|
translationNs: config$4.translationNs,
|
|
@@ -3850,8 +3850,8 @@ var plugin = {
|
|
|
3850
3850
|
}
|
|
3851
3851
|
},
|
|
3852
3852
|
{
|
|
3853
|
-
Component:
|
|
3854
|
-
path: "/barcodes/
|
|
3853
|
+
Component: GuardedBarcodePrintCenterPage,
|
|
3854
|
+
path: "/barcodes/print",
|
|
3855
3855
|
handle: {
|
|
3856
3856
|
label: config$3.label,
|
|
3857
3857
|
translationNs: config$3.translationNs,
|
|
@@ -3870,28 +3870,28 @@ var plugin = {
|
|
|
3870
3870
|
}
|
|
3871
3871
|
},
|
|
3872
3872
|
{
|
|
3873
|
-
Component:
|
|
3874
|
-
path: "/barcodes/
|
|
3873
|
+
Component: GuardedBarcodeStockTakePage,
|
|
3874
|
+
path: "/barcodes/stock-take",
|
|
3875
3875
|
handle: {
|
|
3876
3876
|
label: config$1.label,
|
|
3877
3877
|
translationNs: config$1.translationNs,
|
|
3878
3878
|
permissions: config$1.permissions,
|
|
3879
3879
|
...handle$1
|
|
3880
|
-
}
|
|
3881
|
-
children: [{
|
|
3882
|
-
Component: GuardedBarcodeTagCreateModal,
|
|
3883
|
-
path: "/barcodes/tags/create"
|
|
3884
|
-
}]
|
|
3880
|
+
}
|
|
3885
3881
|
},
|
|
3886
3882
|
{
|
|
3887
|
-
Component:
|
|
3888
|
-
path: "/barcodes/
|
|
3883
|
+
Component: GuardedBarcodeTagsPage,
|
|
3884
|
+
path: "/barcodes/tags",
|
|
3889
3885
|
handle: {
|
|
3890
3886
|
label: config.label,
|
|
3891
3887
|
translationNs: config.translationNs,
|
|
3892
3888
|
permissions: config.permissions,
|
|
3893
3889
|
...handle
|
|
3894
|
-
}
|
|
3890
|
+
},
|
|
3891
|
+
children: [{
|
|
3892
|
+
Component: GuardedBarcodeTagCreateModal,
|
|
3893
|
+
path: "/barcodes/tags/create"
|
|
3894
|
+
}]
|
|
3895
3895
|
}
|
|
3896
3896
|
] },
|
|
3897
3897
|
menuItemModule: { menuItems: [
|
|
@@ -3907,19 +3907,19 @@ var plugin = {
|
|
|
3907
3907
|
{
|
|
3908
3908
|
label: config$4.label,
|
|
3909
3909
|
icon: config$4.icon,
|
|
3910
|
-
path: "/barcodes/
|
|
3910
|
+
path: "/barcodes/lookup",
|
|
3911
3911
|
nested: void 0,
|
|
3912
3912
|
rank: void 0,
|
|
3913
3913
|
translationNs: config$4.translationNs,
|
|
3914
3914
|
permissions: void 0
|
|
3915
3915
|
},
|
|
3916
3916
|
{
|
|
3917
|
-
label: config.label,
|
|
3918
|
-
icon: config.icon,
|
|
3919
|
-
path: "/barcodes/
|
|
3917
|
+
label: config$3.label,
|
|
3918
|
+
icon: config$3.icon,
|
|
3919
|
+
path: "/barcodes/print",
|
|
3920
3920
|
nested: void 0,
|
|
3921
3921
|
rank: void 0,
|
|
3922
|
-
translationNs: config.translationNs,
|
|
3922
|
+
translationNs: config$3.translationNs,
|
|
3923
3923
|
permissions: void 0
|
|
3924
3924
|
},
|
|
3925
3925
|
{
|
|
@@ -3932,21 +3932,21 @@ var plugin = {
|
|
|
3932
3932
|
permissions: void 0
|
|
3933
3933
|
},
|
|
3934
3934
|
{
|
|
3935
|
-
label: config$
|
|
3936
|
-
icon: config$
|
|
3935
|
+
label: config$1.label,
|
|
3936
|
+
icon: config$1.icon,
|
|
3937
3937
|
path: "/barcodes/stock-take",
|
|
3938
3938
|
nested: void 0,
|
|
3939
3939
|
rank: void 0,
|
|
3940
|
-
translationNs: config$
|
|
3940
|
+
translationNs: config$1.translationNs,
|
|
3941
3941
|
permissions: void 0
|
|
3942
3942
|
},
|
|
3943
3943
|
{
|
|
3944
|
-
label: config
|
|
3945
|
-
icon: config
|
|
3944
|
+
label: config.label,
|
|
3945
|
+
icon: config.icon,
|
|
3946
3946
|
path: "/barcodes/tags",
|
|
3947
3947
|
nested: void 0,
|
|
3948
3948
|
rank: void 0,
|
|
3949
|
-
translationNs: config
|
|
3949
|
+
translationNs: config.translationNs,
|
|
3950
3950
|
permissions: void 0
|
|
3951
3951
|
}
|
|
3952
3952
|
] },
|
|
@@ -2024,6 +2024,43 @@ var GuardedBarcodeLookupPage = () => /* @__PURE__ */ jsx(RbacGuard, {
|
|
|
2024
2024
|
permission: "barcodes.read",
|
|
2025
2025
|
children: /* @__PURE__ */ jsx(BarcodeLookupPage, {})
|
|
2026
2026
|
});
|
|
2027
|
+
// src/admin/routes/barcodes/print/page.tsx
|
|
2028
|
+
var BarcodePrintCenterPage = () => {
|
|
2029
|
+
const studio = useBarcodeStudio();
|
|
2030
|
+
return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(Toaster, {}), /* @__PURE__ */ jsx(LayoutComposer, {
|
|
2031
|
+
widgetsZonePrefix: "barcodes.print.details",
|
|
2032
|
+
preferredLayoutId: CORE_LAYOUT_IDS.TWO_COLUMN,
|
|
2033
|
+
sections: {
|
|
2034
|
+
main: /* @__PURE__ */ jsx(LayoutComposer.Entry, {
|
|
2035
|
+
id: "BarcodePrintDesignerSection",
|
|
2036
|
+
children: /* @__PURE__ */ jsx(LabelPrintDesignerSection, {
|
|
2037
|
+
form: studio.printForm,
|
|
2038
|
+
onFormChange: studio.setPrintForm,
|
|
2039
|
+
templates: studio.templates,
|
|
2040
|
+
onRenderLabels: () => void studio.handleRenderLabels()
|
|
2041
|
+
})
|
|
2042
|
+
}),
|
|
2043
|
+
side: /* @__PURE__ */ jsx(LayoutComposer.Entry, {
|
|
2044
|
+
id: "BarcodePrintOutputSection",
|
|
2045
|
+
children: /* @__PURE__ */ jsx(LabelPrintOutputSection, { output: studio.printOutput })
|
|
2046
|
+
})
|
|
2047
|
+
}
|
|
2048
|
+
})] });
|
|
2049
|
+
};
|
|
2050
|
+
var Breadcrumb$3 = () => {
|
|
2051
|
+
const { t } = useTranslation();
|
|
2052
|
+
return t("tabs.print");
|
|
2053
|
+
};
|
|
2054
|
+
var config$3 = defineRouteConfig({
|
|
2055
|
+
label: "tabs.print",
|
|
2056
|
+
translationNs: "barcodes",
|
|
2057
|
+
icon: DocumentText
|
|
2058
|
+
});
|
|
2059
|
+
var handle$3 = { breadcrumb: () => /* @__PURE__ */ jsx(Breadcrumb$3, {}) };
|
|
2060
|
+
var GuardedBarcodePrintCenterPage = () => /* @__PURE__ */ jsx(RbacGuard, {
|
|
2061
|
+
permission: "barcodes.read",
|
|
2062
|
+
children: /* @__PURE__ */ jsx(BarcodePrintCenterPage, {})
|
|
2063
|
+
});
|
|
2027
2064
|
// src/admin/routes/barcodes/providers/page.tsx
|
|
2028
2065
|
var BarcodeProvidersPage = () => {
|
|
2029
2066
|
const studio = useBarcodeStudio();
|
|
@@ -2046,16 +2083,16 @@ var BarcodeProvidersPage = () => {
|
|
|
2046
2083
|
}
|
|
2047
2084
|
})] });
|
|
2048
2085
|
};
|
|
2049
|
-
var Breadcrumb$
|
|
2086
|
+
var Breadcrumb$2 = () => {
|
|
2050
2087
|
const { t } = useTranslation();
|
|
2051
2088
|
return t("providersTab.providersTitle");
|
|
2052
2089
|
};
|
|
2053
|
-
var config$
|
|
2090
|
+
var config$2 = defineRouteConfig({
|
|
2054
2091
|
label: "providersTab.providersTitle",
|
|
2055
2092
|
translationNs: "barcodes",
|
|
2056
2093
|
icon: CheckCircle
|
|
2057
2094
|
});
|
|
2058
|
-
var handle$
|
|
2095
|
+
var handle$2 = { breadcrumb: () => /* @__PURE__ */ jsx(Breadcrumb$2, {}) };
|
|
2059
2096
|
var GuardedBarcodeProvidersPage = () => /* @__PURE__ */ jsx(RbacGuard, {
|
|
2060
2097
|
permission: "barcodes.read",
|
|
2061
2098
|
children: /* @__PURE__ */ jsx(BarcodeProvidersPage, {})
|
|
@@ -2088,16 +2125,16 @@ var BarcodeStockTakePage = () => {
|
|
|
2088
2125
|
}
|
|
2089
2126
|
})] });
|
|
2090
2127
|
};
|
|
2091
|
-
var Breadcrumb$
|
|
2128
|
+
var Breadcrumb$1 = () => {
|
|
2092
2129
|
const { t } = useTranslation();
|
|
2093
2130
|
return t("stockTakeTab.createTitle");
|
|
2094
2131
|
};
|
|
2095
|
-
var config$
|
|
2132
|
+
var config$1 = defineRouteConfig({
|
|
2096
2133
|
label: "stockTakeTab.createTitle",
|
|
2097
2134
|
translationNs: "barcodes",
|
|
2098
2135
|
icon: Buildings
|
|
2099
2136
|
});
|
|
2100
|
-
var handle$
|
|
2137
|
+
var handle$1 = { breadcrumb: () => /* @__PURE__ */ jsx(Breadcrumb$1, {}) };
|
|
2101
2138
|
var GuardedBarcodeStockTakePage = () => /* @__PURE__ */ jsx(RbacGuard, {
|
|
2102
2139
|
permission: "barcodes.read",
|
|
2103
2140
|
children: /* @__PURE__ */ jsx(BarcodeStockTakePage, {})
|
|
@@ -2129,16 +2166,16 @@ var BarcodeTagsPage = () => {
|
|
|
2129
2166
|
}
|
|
2130
2167
|
})] });
|
|
2131
2168
|
};
|
|
2132
|
-
var Breadcrumb
|
|
2169
|
+
var Breadcrumb = () => {
|
|
2133
2170
|
const { t } = useTranslation();
|
|
2134
2171
|
return t("tagsTab.createTitle");
|
|
2135
2172
|
};
|
|
2136
|
-
var config
|
|
2173
|
+
var config = defineRouteConfig({
|
|
2137
2174
|
label: "tagsTab.createTitle",
|
|
2138
2175
|
translationNs: "barcodes",
|
|
2139
2176
|
icon: Tag
|
|
2140
2177
|
});
|
|
2141
|
-
var handle
|
|
2178
|
+
var handle = { breadcrumb: () => /* @__PURE__ */ jsx(Breadcrumb, {}) };
|
|
2142
2179
|
var GuardedBarcodeTagsPage = () => /* @__PURE__ */ jsx(RbacGuard, {
|
|
2143
2180
|
permission: "barcodes.read",
|
|
2144
2181
|
children: /* @__PURE__ */ jsx(BarcodeTagsPage, {})
|
|
@@ -2170,43 +2207,6 @@ var GuardedBarcodeTagCreateModal = () => /* @__PURE__ */ jsx(RbacGuard, {
|
|
|
2170
2207
|
permission: "barcodes.write",
|
|
2171
2208
|
children: /* @__PURE__ */ jsx(BarcodeTagCreateModal, {})
|
|
2172
2209
|
});
|
|
2173
|
-
// src/admin/routes/barcodes/print/page.tsx
|
|
2174
|
-
var BarcodePrintCenterPage = () => {
|
|
2175
|
-
const studio = useBarcodeStudio();
|
|
2176
|
-
return /* @__PURE__ */ jsxs(Fragment, { children: [/* @__PURE__ */ jsx(Toaster, {}), /* @__PURE__ */ jsx(LayoutComposer, {
|
|
2177
|
-
widgetsZonePrefix: "barcodes.print.details",
|
|
2178
|
-
preferredLayoutId: CORE_LAYOUT_IDS.TWO_COLUMN,
|
|
2179
|
-
sections: {
|
|
2180
|
-
main: /* @__PURE__ */ jsx(LayoutComposer.Entry, {
|
|
2181
|
-
id: "BarcodePrintDesignerSection",
|
|
2182
|
-
children: /* @__PURE__ */ jsx(LabelPrintDesignerSection, {
|
|
2183
|
-
form: studio.printForm,
|
|
2184
|
-
onFormChange: studio.setPrintForm,
|
|
2185
|
-
templates: studio.templates,
|
|
2186
|
-
onRenderLabels: () => void studio.handleRenderLabels()
|
|
2187
|
-
})
|
|
2188
|
-
}),
|
|
2189
|
-
side: /* @__PURE__ */ jsx(LayoutComposer.Entry, {
|
|
2190
|
-
id: "BarcodePrintOutputSection",
|
|
2191
|
-
children: /* @__PURE__ */ jsx(LabelPrintOutputSection, { output: studio.printOutput })
|
|
2192
|
-
})
|
|
2193
|
-
}
|
|
2194
|
-
})] });
|
|
2195
|
-
};
|
|
2196
|
-
var Breadcrumb = () => {
|
|
2197
|
-
const { t } = useTranslation();
|
|
2198
|
-
return t("tabs.print");
|
|
2199
|
-
};
|
|
2200
|
-
var config = defineRouteConfig({
|
|
2201
|
-
label: "tabs.print",
|
|
2202
|
-
translationNs: "barcodes",
|
|
2203
|
-
icon: DocumentText
|
|
2204
|
-
});
|
|
2205
|
-
var handle = { breadcrumb: () => /* @__PURE__ */ jsx(Breadcrumb, {}) };
|
|
2206
|
-
var GuardedBarcodePrintCenterPage = () => /* @__PURE__ */ jsx(RbacGuard, {
|
|
2207
|
-
permission: "barcodes.read",
|
|
2208
|
-
children: /* @__PURE__ */ jsx(BarcodePrintCenterPage, {})
|
|
2209
|
-
});
|
|
2210
2210
|
var ar_default = {
|
|
2211
2211
|
nav: { "label": "استوديو الباركود والملصقات" },
|
|
2212
2212
|
header: {
|
|
@@ -3828,8 +3828,8 @@ var plugin = {
|
|
|
3828
3828
|
}
|
|
3829
3829
|
},
|
|
3830
3830
|
{
|
|
3831
|
-
Component:
|
|
3832
|
-
path: "/barcodes/
|
|
3831
|
+
Component: GuardedBarcodePrintCenterPage,
|
|
3832
|
+
path: "/barcodes/print",
|
|
3833
3833
|
handle: {
|
|
3834
3834
|
label: config$3.label,
|
|
3835
3835
|
translationNs: config$3.translationNs,
|
|
@@ -3838,8 +3838,8 @@ var plugin = {
|
|
|
3838
3838
|
}
|
|
3839
3839
|
},
|
|
3840
3840
|
{
|
|
3841
|
-
Component:
|
|
3842
|
-
path: "/barcodes/
|
|
3841
|
+
Component: GuardedBarcodeProvidersPage,
|
|
3842
|
+
path: "/barcodes/providers",
|
|
3843
3843
|
handle: {
|
|
3844
3844
|
label: config$2.label,
|
|
3845
3845
|
translationNs: config$2.translationNs,
|
|
@@ -3848,28 +3848,28 @@ var plugin = {
|
|
|
3848
3848
|
}
|
|
3849
3849
|
},
|
|
3850
3850
|
{
|
|
3851
|
-
Component:
|
|
3852
|
-
path: "/barcodes/
|
|
3851
|
+
Component: GuardedBarcodeStockTakePage,
|
|
3852
|
+
path: "/barcodes/stock-take",
|
|
3853
3853
|
handle: {
|
|
3854
3854
|
label: config$1.label,
|
|
3855
3855
|
translationNs: config$1.translationNs,
|
|
3856
3856
|
permissions: config$1.permissions,
|
|
3857
3857
|
...handle$1
|
|
3858
|
-
}
|
|
3859
|
-
children: [{
|
|
3860
|
-
Component: GuardedBarcodeTagCreateModal,
|
|
3861
|
-
path: "/barcodes/tags/create"
|
|
3862
|
-
}]
|
|
3858
|
+
}
|
|
3863
3859
|
},
|
|
3864
3860
|
{
|
|
3865
|
-
Component:
|
|
3866
|
-
path: "/barcodes/
|
|
3861
|
+
Component: GuardedBarcodeTagsPage,
|
|
3862
|
+
path: "/barcodes/tags",
|
|
3867
3863
|
handle: {
|
|
3868
3864
|
label: config.label,
|
|
3869
3865
|
translationNs: config.translationNs,
|
|
3870
3866
|
permissions: config.permissions,
|
|
3871
3867
|
...handle
|
|
3872
|
-
}
|
|
3868
|
+
},
|
|
3869
|
+
children: [{
|
|
3870
|
+
Component: GuardedBarcodeTagCreateModal,
|
|
3871
|
+
path: "/barcodes/tags/create"
|
|
3872
|
+
}]
|
|
3873
3873
|
}
|
|
3874
3874
|
] },
|
|
3875
3875
|
menuItemModule: { menuItems: [
|
|
@@ -3891,19 +3891,10 @@ var plugin = {
|
|
|
3891
3891
|
translationNs: config$4.translationNs,
|
|
3892
3892
|
permissions: void 0
|
|
3893
3893
|
},
|
|
3894
|
-
{
|
|
3895
|
-
label: config.label,
|
|
3896
|
-
icon: config.icon,
|
|
3897
|
-
path: "/barcodes/print",
|
|
3898
|
-
nested: void 0,
|
|
3899
|
-
rank: void 0,
|
|
3900
|
-
translationNs: config.translationNs,
|
|
3901
|
-
permissions: void 0
|
|
3902
|
-
},
|
|
3903
3894
|
{
|
|
3904
3895
|
label: config$3.label,
|
|
3905
3896
|
icon: config$3.icon,
|
|
3906
|
-
path: "/barcodes/
|
|
3897
|
+
path: "/barcodes/print",
|
|
3907
3898
|
nested: void 0,
|
|
3908
3899
|
rank: void 0,
|
|
3909
3900
|
translationNs: config$3.translationNs,
|
|
@@ -3912,7 +3903,7 @@ var plugin = {
|
|
|
3912
3903
|
{
|
|
3913
3904
|
label: config$2.label,
|
|
3914
3905
|
icon: config$2.icon,
|
|
3915
|
-
path: "/barcodes/
|
|
3906
|
+
path: "/barcodes/providers",
|
|
3916
3907
|
nested: void 0,
|
|
3917
3908
|
rank: void 0,
|
|
3918
3909
|
translationNs: config$2.translationNs,
|
|
@@ -3921,11 +3912,20 @@ var plugin = {
|
|
|
3921
3912
|
{
|
|
3922
3913
|
label: config$1.label,
|
|
3923
3914
|
icon: config$1.icon,
|
|
3924
|
-
path: "/barcodes/
|
|
3915
|
+
path: "/barcodes/stock-take",
|
|
3925
3916
|
nested: void 0,
|
|
3926
3917
|
rank: void 0,
|
|
3927
3918
|
translationNs: config$1.translationNs,
|
|
3928
3919
|
permissions: void 0
|
|
3920
|
+
},
|
|
3921
|
+
{
|
|
3922
|
+
label: config.label,
|
|
3923
|
+
icon: config.icon,
|
|
3924
|
+
path: "/barcodes/tags",
|
|
3925
|
+
nested: void 0,
|
|
3926
|
+
rank: void 0,
|
|
3927
|
+
translationNs: config.translationNs,
|
|
3928
|
+
permissions: void 0
|
|
3929
3929
|
}
|
|
3930
3930
|
] },
|
|
3931
3931
|
formModule: { customFields: {} },
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { z } from "zod";
|
|
1
|
+
import { z } from "@medusajs/framework/zod";
|
|
2
2
|
import { BARCODE_MODULE } from "../../../modules/barcode/types";
|
|
3
3
|
const AdminListBarcodesQuerySchema = z.object({
|
|
4
4
|
product_id: z.string().min(1).max(256).optional(),
|
|
@@ -24,4 +24,4 @@ export async function GET(req, res) {
|
|
|
24
24
|
overview,
|
|
25
25
|
});
|
|
26
26
|
}
|
|
27
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
27
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicm91dGUuanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi8uLi8uLi8uLi9zcmMvYXBpL2FkbWluL2JhcmNvZGVzL3JvdXRlLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUNBLE9BQU8sRUFBRSxDQUFDLEVBQUUsTUFBTSx5QkFBeUIsQ0FBQTtBQUUzQyxPQUFPLEVBQUUsY0FBYyxFQUFFLE1BQU0sZ0NBQWdDLENBQUE7QUFFL0QsTUFBTSw0QkFBNEIsR0FBRyxDQUFDLENBQUMsTUFBTSxDQUFDO0lBQzVDLFVBQVUsRUFBRSxDQUFDLENBQUMsTUFBTSxFQUFFLENBQUMsR0FBRyxDQUFDLENBQUMsQ0FBQyxDQUFDLEdBQUcsQ0FBQyxHQUFHLENBQUMsQ0FBQyxRQUFRLEVBQUU7Q0FDbEQsQ0FBQyxDQUFBO0FBRUYsTUFBTSxDQUFDLEtBQUssVUFBVSxHQUFHLENBQUMsR0FBa0IsRUFBRSxHQUFtQjtJQUMvRCxNQUFNLE1BQU0sR0FBRyw0QkFBNEIsQ0FBQyxTQUFTLENBQUMsR0FBRyxDQUFDLEtBQUssSUFBSSxFQUFFLENBQUMsQ0FBQTtJQUN0RSxJQUFJLENBQUMsTUFBTSxDQUFDLE9BQU8sRUFBRSxDQUFDO1FBQ3BCLE9BQU8sR0FBRyxDQUFDLE1BQU0sQ0FBQyxHQUFHLENBQUMsQ0FBQyxJQUFJLENBQUM7WUFDMUIsT0FBTyxFQUFFLDBCQUEwQjtZQUNuQyxNQUFNLEVBQUUsTUFBTSxDQUFDLEtBQUssQ0FBQyxPQUFPLEVBQUUsQ0FBQyxXQUFXO1NBQzNDLENBQUMsQ0FBQTtJQUNKLENBQUM7SUFFRCxNQUFNLGNBQWMsR0FBRyxHQUFHLENBQUMsS0FBSyxDQUFDLE9BQU8sQ0FDdEMsY0FBYyxDQUNTLENBQUE7SUFFekIsTUFBTSxTQUFTLEdBQUcsTUFBTSxDQUFDLElBQUksQ0FBQyxVQUFVLENBQUE7SUFDeEMsTUFBTSxNQUFNLEdBQUcsU0FBUyxDQUFDLENBQUMsQ0FBQyxFQUFFLFVBQVUsRUFBRSxTQUFTLEVBQUUsQ0FBQyxDQUFDLENBQUMsRUFBRSxDQUFBO0lBRXpELE1BQU0sQ0FBQyxlQUFlLEVBQUUsUUFBUSxDQUFDLEdBQUcsTUFBTSxPQUFPLENBQUMsR0FBRyxDQUFDO1FBQ3BELGNBQWMsQ0FBQyxtQkFBbUIsQ0FBQyxNQUFNLEVBQUUsRUFBRSxJQUFJLEVBQUUsR0FBRyxFQUFFLENBQUM7UUFDekQsY0FBYyxDQUFDLG9CQUFvQixFQUFFO0tBQ3RDLENBQUMsQ0FBQTtJQUVGLEdBQUcsQ0FBQyxJQUFJLENBQUM7UUFDUCxRQUFRLEVBQUUsZUFBZTtRQUN6QixLQUFLLEVBQUUsZUFBZSxDQUFDLE1BQU07UUFDN0IsUUFBUTtLQUNULENBQUMsQ0FBQTtBQUNKLENBQUMifQ==
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vicacha-devs/medusa-plugin-barcode",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.1.1",
|
|
4
4
|
"description": "Unified 4-in-1 Barcode, GS1, Dynamic QR, Multi-Provider GTIN Lookup, Thermal/Sheet Label Printing (HTML/SVG & ZPL II), Anti-Counterfeit Verification & Warehouse Stock-Take Scanner plugin for Medusa v2.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"barcode",
|
|
@@ -22,6 +22,11 @@
|
|
|
22
22
|
],
|
|
23
23
|
"license": "MIT",
|
|
24
24
|
"author": "Vicacha Devs",
|
|
25
|
+
"repository": {
|
|
26
|
+
"type": "git",
|
|
27
|
+
"url": "git+https://github.com/Vicacha-Devs/medusa-plugins.git",
|
|
28
|
+
"directory": "packages/barcode"
|
|
29
|
+
},
|
|
25
30
|
"files": [
|
|
26
31
|
".medusa/server",
|
|
27
32
|
"src",
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { MedusaRequest, MedusaResponse } from "@medusajs/framework/http"
|
|
2
|
-
import { z } from "zod"
|
|
2
|
+
import { z } from "@medusajs/framework/zod"
|
|
3
3
|
import type { BarcodeModuleService } from "../../../modules/barcode/service"
|
|
4
4
|
import { BARCODE_MODULE } from "../../../modules/barcode/types"
|
|
5
5
|
|