@myparcel-dev/pdk-admin-js 2.0.0 → 2.1.0
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/CHANGELOG.md +5 -0
- package/dist/ChildProductSettings-CyKUVRaK.js +4 -0
- package/dist/Modals-NMhNPPic.js +4 -0
- package/dist/Notifications-CEr-hfp0.js +4 -0
- package/dist/OrderBox-BeswqlPq.js +4 -0
- package/dist/OrderListItem-DZBgN8DK.js +4 -0
- package/dist/{OrderModeOrderListItem-CnEBPTEC.js → OrderModeOrderListItem-DXF6TEy-.js} +2 -2
- package/dist/PluginSettings-BDBzENE7.js +4 -0
- package/dist/{PrintOptionsModalForm-BUGvrOwt.js → PrintOptionsModalForm-Coh6mRx1.js} +1 -1
- package/dist/ProductSettings-B5kBwk1B.js +4 -0
- package/dist/{ShipmentLabel.vue_vue_type_script_setup_true_lang-CmhEHRaP.js → ShipmentLabel.vue_vue_type_script_setup_true_lang-CLnMQblC.js} +1 -1
- package/dist/{ShipmentModeOrderListItem-BVzk32iG.js → ShipmentModeOrderListItem-CmORFPYC.js} +2 -2
- package/dist/{ShipmentOptionsModalForm-INoRc2Gs.js → ShipmentOptionsModalForm-BHKttVyQ.js} +1 -1
- package/dist/{ShipmentTableBox-CzmZ6Xt4.js → ShipmentTableBox-DskzPlmr.js} +1 -1
- package/dist/{index-BfK2d6Yu.js → index-CwKPv7Cc.js} +91 -87
- package/dist/index.js +1 -1
- package/package.json +3 -3
- package/dist/ChildProductSettings-s8z5afQ0.js +0 -4
- package/dist/Modals-WFWEKC20.js +0 -4
- package/dist/Notifications-mywk4f35.js +0 -4
- package/dist/OrderBox-CQNS7zO9.js +0 -4
- package/dist/OrderListItem-DH0iYnG8.js +0 -4
- package/dist/PluginSettings-ymxANIm1.js +0 -4
- package/dist/ProductSettings-CEHnUs2T.js +0 -4
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
<!-- MONOWEAVE:BELOW -->
|
|
4
4
|
|
|
5
|
+
## [2.0.1](https://github.com/myparcelnl/js-pdk/compare/@myparcel-dev/pdk-admin-js@2.0.0...@myparcel-dev/pdk-admin-js@2.0.1) "@myparcel-dev/pdk-admin-js" (2026-07-20)
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
5
10
|
## [2.0.0](https://github.com/myparcelnl/js-pdk/compare/@myparcel-dev/pdk-admin-js@1.14.2...@myparcel-dev/pdk-admin-js@2.0.0) "@myparcel-dev/pdk-admin-js" (2026-06-04)
|
|
6
11
|
|
|
7
12
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { d as defineComponent, H as useOrderData, U as useOrderMode, c as computed, t as toValue, V as instantiateAction, W as orderViewInBackofficeAction, P as instantiateActions, X as LIST_ITEM_MODE_ACTIONS, s as resolveComponent, o as openBlock, L as createElementBlock, a as createBlock, b as unref, e as createCommentVNode, M as Fragment, O as renderList, y as createVNode, v as withCtx, Y as OrderMode, Z as _sfc_main$3, $ as Size } from "./index-
|
|
2
|
-
import { _ as _sfc_main$1, a as _sfc_main$2 } from "./ShipmentLabel.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
import { d as defineComponent, H as useOrderData, U as useOrderMode, c as computed, t as toValue, V as instantiateAction, W as orderViewInBackofficeAction, P as instantiateActions, X as LIST_ITEM_MODE_ACTIONS, s as resolveComponent, o as openBlock, L as createElementBlock, a as createBlock, b as unref, e as createCommentVNode, M as Fragment, O as renderList, y as createVNode, v as withCtx, Y as OrderMode, Z as _sfc_main$3, $ as Size } from "./index-CwKPv7Cc.js";
|
|
2
|
+
import { _ as _sfc_main$1, a as _sfc_main$2 } from "./ShipmentLabel.vue_vue_type_script_setup_true_lang-CLnMQblC.js";
|
|
3
3
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
4
4
|
__name: "OrderModeOrderListItem",
|
|
5
5
|
setup(__props) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as defineComponent, f as useContext, g as usePluginSettings, h as useAdminConfig, r as ref, i as onMounted, m as markRaw, N as Ne, A as AdminModalKey, j as generateFormFields, o as openBlock, a as createBlock, b as unref, x as xe, e as createCommentVNode } from "./index-
|
|
1
|
+
import { d as defineComponent, f as useContext, g as usePluginSettings, h as useAdminConfig, r as ref, i as onMounted, m as markRaw, N as Ne, A as AdminModalKey, j as generateFormFields, o as openBlock, a as createBlock, b as unref, x as xe, e as createCommentVNode } from "./index-CwKPv7Cc.js";
|
|
2
2
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
3
3
|
__name: "PrintOptionsModalForm",
|
|
4
4
|
setup(__props) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as defineComponent, l as useLocalizedFormatter, c as computed, F as Format, o as openBlock, L as createElementBlock, E as toDisplayString, I as useLanguage, s as resolveComponent, y as createVNode, D as createBaseVNode, b as unref, e as createCommentVNode, k as toRefs, a6 as useDigitalStampRanges, a7 as isOfType, a8 as _sfc_main$7, a9 as PackageTypeName, a as createBlock, aa as useFetchCarrier, t as toValue, ab as _sfc_main$8, M as Fragment, K as createTextVNode, H as useOrderData, h as useAdminConfig, G as normalizeClass, ac as getDynamicTranslation, n as useQueryStore, p as useShipmentData, v as withCtx, B as _sfc_main$9, C as _sfc_main$a, ad as withModifiers } from "./index-
|
|
1
|
+
import { d as defineComponent, l as useLocalizedFormatter, c as computed, F as Format, o as openBlock, L as createElementBlock, E as toDisplayString, I as useLanguage, s as resolveComponent, y as createVNode, D as createBaseVNode, b as unref, e as createCommentVNode, k as toRefs, a6 as useDigitalStampRanges, a7 as isOfType, a8 as _sfc_main$7, a9 as PackageTypeName, a as createBlock, aa as useFetchCarrier, t as toValue, ab as _sfc_main$8, M as Fragment, K as createTextVNode, H as useOrderData, h as useAdminConfig, G as normalizeClass, ac as getDynamicTranslation, n as useQueryStore, p as useShipmentData, v as withCtx, B as _sfc_main$9, C as _sfc_main$a, ad as withModifiers } from "./index-CwKPv7Cc.js";
|
|
2
2
|
const _hoisted_1$4 = ["title", "textContent"];
|
|
3
3
|
const _sfc_main$6 = /* @__PURE__ */ defineComponent({
|
|
4
4
|
__name: "DateRelative",
|
package/dist/{ShipmentModeOrderListItem-BVzk32iG.js → ShipmentModeOrderListItem-CmORFPYC.js}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { d as defineComponent, h as useAdminConfig, H as useOrderData, c as computed, t as toValue, a0 as ordersPrintAction, a1 as ordersFetchAction, a2 as orderExportAction, a3 as ordersExportPrintShipmentsAction, a4 as ordersEditAction, P as instantiateActions, s as resolveComponent, o as openBlock, L as createElementBlock, a as createBlock, b as unref, e as createCommentVNode, y as createVNode, v as withCtx, M as Fragment, O as renderList, a5 as TransitionGroup, $ as Size } from "./index-
|
|
2
|
-
import { _ as _sfc_main$1, a as _sfc_main$2 } from "./ShipmentLabel.vue_vue_type_script_setup_true_lang-
|
|
1
|
+
import { d as defineComponent, h as useAdminConfig, H as useOrderData, c as computed, t as toValue, a0 as ordersPrintAction, a1 as ordersFetchAction, a2 as orderExportAction, a3 as ordersExportPrintShipmentsAction, a4 as ordersEditAction, P as instantiateActions, s as resolveComponent, o as openBlock, L as createElementBlock, a as createBlock, b as unref, e as createCommentVNode, y as createVNode, v as withCtx, M as Fragment, O as renderList, a5 as TransitionGroup, $ as Size } from "./index-CwKPv7Cc.js";
|
|
2
|
+
import { _ as _sfc_main$1, a as _sfc_main$2 } from "./ShipmentLabel.vue_vue_type_script_setup_true_lang-CLnMQblC.js";
|
|
3
3
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
4
4
|
__name: "ShipmentModeOrderListItem",
|
|
5
5
|
setup(__props) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as defineComponent, c as computed, u as useOrdersData, t as toValue, o as openBlock, a as createBlock, b as unref, _ as _sfc_main$1, e as createCommentVNode } from "./index-
|
|
1
|
+
import { d as defineComponent, c as computed, u as useOrdersData, t as toValue, o as openBlock, a as createBlock, b as unref, _ as _sfc_main$1, e as createCommentVNode } from "./index-CwKPv7Cc.js";
|
|
2
2
|
const _sfc_main = /* @__PURE__ */ defineComponent({
|
|
3
3
|
__name: "ShipmentOptionsModalForm",
|
|
4
4
|
props: {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as ref, c as computed, w as watch, d as defineComponent, k as toRefs, h as useAdminConfig, l as useLocalizedFormatter, n as useQueryStore, p as useShipmentData, q as useVModel, F as Format, s as resolveComponent, o as openBlock, a as createBlock, v as withCtx, y as createVNode, b as unref, z as isRef, B as _sfc_main$3, C as _sfc_main$4, D as createBaseVNode, E as toDisplayString, G as normalizeClass, H as useOrderData, t as toValue, I as useLanguage, J as _sfc_main$5, K as createTextVNode, L as createElementBlock, M as Fragment, O as renderList, P as instantiateActions, Q as toRaw, R as shipmentActions, S as AdminIcon, e as createCommentVNode, T as isDef } from "./index-
|
|
1
|
+
import { r as ref, c as computed, w as watch, d as defineComponent, k as toRefs, h as useAdminConfig, l as useLocalizedFormatter, n as useQueryStore, p as useShipmentData, q as useVModel, F as Format, s as resolveComponent, o as openBlock, a as createBlock, v as withCtx, y as createVNode, b as unref, z as isRef, B as _sfc_main$3, C as _sfc_main$4, D as createBaseVNode, E as toDisplayString, G as normalizeClass, H as useOrderData, t as toValue, I as useLanguage, J as _sfc_main$5, K as createTextVNode, L as createElementBlock, M as Fragment, O as renderList, P as instantiateActions, Q as toRaw, R as shipmentActions, S as AdminIcon, e as createCommentVNode, T as isDef } from "./index-CwKPv7Cc.js";
|
|
2
2
|
const useBulkSelectCheckbox = (options, emit) => {
|
|
3
3
|
const selected = ref({});
|
|
4
4
|
const bulkModel = computed({
|
|
@@ -15528,6 +15528,66 @@ var toArray = (itemOrItems, separator) => {
|
|
|
15528
15528
|
}
|
|
15529
15529
|
return Array.isArray(itemOrItems) ? itemOrItems : [itemOrItems];
|
|
15530
15530
|
};
|
|
15531
|
+
var CarrierId = /* @__PURE__ */ ((CarrierId3) => {
|
|
15532
|
+
CarrierId3[CarrierId3["PostNl"] = 1] = "PostNl";
|
|
15533
|
+
CarrierId3[CarrierId3["Bpost"] = 2] = "Bpost";
|
|
15534
|
+
CarrierId3[CarrierId3["CheapCargo"] = 3] = "CheapCargo";
|
|
15535
|
+
CarrierId3[CarrierId3["Dpd"] = 4] = "Dpd";
|
|
15536
|
+
CarrierId3[CarrierId3["Instabox"] = 5] = "Instabox";
|
|
15537
|
+
CarrierId3[CarrierId3["Dhl"] = 6] = "Dhl";
|
|
15538
|
+
CarrierId3[CarrierId3["Bol"] = 7] = "Bol";
|
|
15539
|
+
CarrierId3[CarrierId3["BolCom"] = 7] = "BolCom";
|
|
15540
|
+
CarrierId3[CarrierId3["Ups"] = 8] = "Ups";
|
|
15541
|
+
CarrierId3[CarrierId3["DhlForYou"] = 9] = "DhlForYou";
|
|
15542
|
+
CarrierId3[CarrierId3["DhlParcelConnect"] = 10] = "DhlParcelConnect";
|
|
15543
|
+
CarrierId3[CarrierId3["DhlEuroPlus"] = 11] = "DhlEuroPlus";
|
|
15544
|
+
CarrierId3[CarrierId3["UpsStandard"] = 12] = "UpsStandard";
|
|
15545
|
+
CarrierId3[CarrierId3["UpsExpressSaver"] = 13] = "UpsExpressSaver";
|
|
15546
|
+
CarrierId3[CarrierId3["Gls"] = 14] = "Gls";
|
|
15547
|
+
CarrierId3[CarrierId3["Brt"] = 15] = "Brt";
|
|
15548
|
+
CarrierId3[CarrierId3["Trunkrs"] = 16] = "Trunkrs";
|
|
15549
|
+
CarrierId3[CarrierId3["InPost"] = 17] = "InPost";
|
|
15550
|
+
return CarrierId3;
|
|
15551
|
+
})(CarrierId || {});
|
|
15552
|
+
var CarrierName = /* @__PURE__ */ ((CarrierName3) => {
|
|
15553
|
+
CarrierName3["PostNl"] = "postnl";
|
|
15554
|
+
CarrierName3["Bpost"] = "bpost";
|
|
15555
|
+
CarrierName3["CheapCargo"] = "cheapcargo";
|
|
15556
|
+
CarrierName3["Dpd"] = "dpd";
|
|
15557
|
+
CarrierName3["Instabox"] = "instabox";
|
|
15558
|
+
CarrierName3["Dhl"] = "dhl";
|
|
15559
|
+
CarrierName3["Bol"] = "bol.com";
|
|
15560
|
+
CarrierName3["BolCom"] = "bol.com";
|
|
15561
|
+
CarrierName3["Ups"] = "ups";
|
|
15562
|
+
CarrierName3["DhlForYou"] = "dhlforyou";
|
|
15563
|
+
CarrierName3["DhlParcelConnect"] = "dhlparcelconnect";
|
|
15564
|
+
CarrierName3["DhlEuroPlus"] = "dhleuroplus";
|
|
15565
|
+
CarrierName3["UpsStandard"] = "upsstandard";
|
|
15566
|
+
CarrierName3["UpsExpressSaver"] = "upsexpresssaver";
|
|
15567
|
+
CarrierName3["Gls"] = "gls";
|
|
15568
|
+
CarrierName3["Brt"] = "brt";
|
|
15569
|
+
CarrierName3["Trunkrs"] = "trunkrs";
|
|
15570
|
+
CarrierName3["InPost"] = "inpost";
|
|
15571
|
+
return CarrierName3;
|
|
15572
|
+
})(CarrierName || {});
|
|
15573
|
+
var DeliveryTypeName = /* @__PURE__ */ ((DeliveryTypeName3) => {
|
|
15574
|
+
DeliveryTypeName3["Morning"] = "morning";
|
|
15575
|
+
DeliveryTypeName3["Standard"] = "standard";
|
|
15576
|
+
DeliveryTypeName3["Evening"] = "evening";
|
|
15577
|
+
DeliveryTypeName3["Pickup"] = "pickup";
|
|
15578
|
+
DeliveryTypeName3["Express"] = "express";
|
|
15579
|
+
return DeliveryTypeName3;
|
|
15580
|
+
})(DeliveryTypeName || {});
|
|
15581
|
+
var PackageTypeName = /* @__PURE__ */ ((PackageTypeName2) => {
|
|
15582
|
+
PackageTypeName2["Package"] = "package";
|
|
15583
|
+
PackageTypeName2["Mailbox"] = "mailbox";
|
|
15584
|
+
PackageTypeName2["Letter"] = "letter";
|
|
15585
|
+
PackageTypeName2["DigitalStamp"] = "digital_stamp";
|
|
15586
|
+
PackageTypeName2["Pallet"] = "pallet";
|
|
15587
|
+
PackageTypeName2["PackageSmall"] = "package_small";
|
|
15588
|
+
PackageTypeName2["Envelope"] = "envelope";
|
|
15589
|
+
return PackageTypeName2;
|
|
15590
|
+
})(PackageTypeName || {});
|
|
15531
15591
|
function createGlobalState(stateFactory) {
|
|
15532
15592
|
let initialized2 = false;
|
|
15533
15593
|
let state;
|
|
@@ -19382,65 +19442,6 @@ const _sfc_main$r = /* @__PURE__ */ defineComponent({
|
|
|
19382
19442
|
};
|
|
19383
19443
|
}
|
|
19384
19444
|
});
|
|
19385
|
-
var CarrierId = /* @__PURE__ */ ((CarrierId3) => {
|
|
19386
|
-
CarrierId3[CarrierId3["PostNl"] = 1] = "PostNl";
|
|
19387
|
-
CarrierId3[CarrierId3["Bpost"] = 2] = "Bpost";
|
|
19388
|
-
CarrierId3[CarrierId3["CheapCargo"] = 3] = "CheapCargo";
|
|
19389
|
-
CarrierId3[CarrierId3["Dpd"] = 4] = "Dpd";
|
|
19390
|
-
CarrierId3[CarrierId3["Instabox"] = 5] = "Instabox";
|
|
19391
|
-
CarrierId3[CarrierId3["Dhl"] = 6] = "Dhl";
|
|
19392
|
-
CarrierId3[CarrierId3["Bol"] = 7] = "Bol";
|
|
19393
|
-
CarrierId3[CarrierId3["BolCom"] = 7] = "BolCom";
|
|
19394
|
-
CarrierId3[CarrierId3["Ups"] = 8] = "Ups";
|
|
19395
|
-
CarrierId3[CarrierId3["DhlForYou"] = 9] = "DhlForYou";
|
|
19396
|
-
CarrierId3[CarrierId3["DhlParcelConnect"] = 10] = "DhlParcelConnect";
|
|
19397
|
-
CarrierId3[CarrierId3["DhlEuroPlus"] = 11] = "DhlEuroPlus";
|
|
19398
|
-
CarrierId3[CarrierId3["UpsStandard"] = 12] = "UpsStandard";
|
|
19399
|
-
CarrierId3[CarrierId3["UpsExpressSaver"] = 13] = "UpsExpressSaver";
|
|
19400
|
-
CarrierId3[CarrierId3["Gls"] = 14] = "Gls";
|
|
19401
|
-
CarrierId3[CarrierId3["Brt"] = 15] = "Brt";
|
|
19402
|
-
CarrierId3[CarrierId3["Trunkrs"] = 16] = "Trunkrs";
|
|
19403
|
-
CarrierId3[CarrierId3["InPost"] = 17] = "InPost";
|
|
19404
|
-
return CarrierId3;
|
|
19405
|
-
})(CarrierId || {});
|
|
19406
|
-
var CarrierName = /* @__PURE__ */ ((CarrierName3) => {
|
|
19407
|
-
CarrierName3["PostNl"] = "postnl";
|
|
19408
|
-
CarrierName3["Bpost"] = "bpost";
|
|
19409
|
-
CarrierName3["CheapCargo"] = "cheapcargo";
|
|
19410
|
-
CarrierName3["Dpd"] = "dpd";
|
|
19411
|
-
CarrierName3["Instabox"] = "instabox";
|
|
19412
|
-
CarrierName3["Dhl"] = "dhl";
|
|
19413
|
-
CarrierName3["Bol"] = "bol.com";
|
|
19414
|
-
CarrierName3["BolCom"] = "bol.com";
|
|
19415
|
-
CarrierName3["Ups"] = "ups";
|
|
19416
|
-
CarrierName3["DhlForYou"] = "dhlforyou";
|
|
19417
|
-
CarrierName3["DhlParcelConnect"] = "dhlparcelconnect";
|
|
19418
|
-
CarrierName3["DhlEuroPlus"] = "dhleuroplus";
|
|
19419
|
-
CarrierName3["UpsStandard"] = "upsstandard";
|
|
19420
|
-
CarrierName3["UpsExpressSaver"] = "upsexpresssaver";
|
|
19421
|
-
CarrierName3["Gls"] = "gls";
|
|
19422
|
-
CarrierName3["Brt"] = "brt";
|
|
19423
|
-
CarrierName3["Trunkrs"] = "trunkrs";
|
|
19424
|
-
CarrierName3["InPost"] = "inpost";
|
|
19425
|
-
return CarrierName3;
|
|
19426
|
-
})(CarrierName || {});
|
|
19427
|
-
var DeliveryTypeName = /* @__PURE__ */ ((DeliveryTypeName3) => {
|
|
19428
|
-
DeliveryTypeName3["Morning"] = "morning";
|
|
19429
|
-
DeliveryTypeName3["Standard"] = "standard";
|
|
19430
|
-
DeliveryTypeName3["Evening"] = "evening";
|
|
19431
|
-
DeliveryTypeName3["Pickup"] = "pickup";
|
|
19432
|
-
DeliveryTypeName3["Express"] = "express";
|
|
19433
|
-
return DeliveryTypeName3;
|
|
19434
|
-
})(DeliveryTypeName || {});
|
|
19435
|
-
var PackageTypeName = /* @__PURE__ */ ((PackageTypeName2) => {
|
|
19436
|
-
PackageTypeName2["Package"] = "package";
|
|
19437
|
-
PackageTypeName2["Mailbox"] = "mailbox";
|
|
19438
|
-
PackageTypeName2["Letter"] = "letter";
|
|
19439
|
-
PackageTypeName2["DigitalStamp"] = "digital_stamp";
|
|
19440
|
-
PackageTypeName2["Pallet"] = "pallet";
|
|
19441
|
-
PackageTypeName2["PackageSmall"] = "package_small";
|
|
19442
|
-
return PackageTypeName2;
|
|
19443
|
-
})(PackageTypeName || {});
|
|
19444
19445
|
const _hoisted_1$7 = ["title", "textContent"];
|
|
19445
19446
|
const _sfc_main$q = /* @__PURE__ */ defineComponent({
|
|
19446
19447
|
__name: "PackageType",
|
|
@@ -19838,15 +19839,15 @@ const useShipmentCapabilitiesQuery = (selection) => {
|
|
|
19838
19839
|
return useQuery(
|
|
19839
19840
|
queryKey,
|
|
19840
19841
|
async () => {
|
|
19841
|
-
const { cc, weight, carrier, packageType, deliveryType } = selection.value;
|
|
19842
|
+
const { cc, weight, isBusiness, carrier, packageType, deliveryType } = selection.value;
|
|
19842
19843
|
if (!cc || !carrier || !packageType || !deliveryType) return [];
|
|
19843
19844
|
const pdk = usePdkAdminApi();
|
|
19844
19845
|
const proxyCapabilities = pdk.proxyCapabilities;
|
|
19845
19846
|
const body = {
|
|
19846
|
-
recipient: { countryCode: cc },
|
|
19847
|
+
recipient: { countryCode: cc, ...isBusiness === void 0 ? null : { isBusiness } },
|
|
19847
19848
|
// PDK orders carry physical-properties weight in grams (see WeightServiceInterface::UNIT_GRAMS),
|
|
19848
19849
|
// and the SDK's PhysicalPropertiesWeightV2 expects a {value, unit} object — not a primitive.
|
|
19849
|
-
...weight
|
|
19850
|
+
...weight === void 0 ? null : { physicalProperties: { weight: { value: weight, unit: "g" } } },
|
|
19850
19851
|
carrier,
|
|
19851
19852
|
packageType,
|
|
19852
19853
|
deliveryType
|
|
@@ -19871,13 +19872,13 @@ const useOrderCapabilitiesQuery = (input) => {
|
|
|
19871
19872
|
return useQuery(
|
|
19872
19873
|
queryKey,
|
|
19873
19874
|
async () => {
|
|
19874
|
-
const { cc, weight } = input.value;
|
|
19875
|
+
const { cc, weight, isBusiness } = input.value;
|
|
19875
19876
|
if (!cc) return [];
|
|
19876
19877
|
const pdk = usePdkAdminApi();
|
|
19877
19878
|
const proxyCapabilities = pdk.proxyCapabilities;
|
|
19878
19879
|
const body = {
|
|
19879
|
-
recipient: { countryCode: cc },
|
|
19880
|
-
...weight
|
|
19880
|
+
recipient: { countryCode: cc, ...isBusiness === void 0 ? null : { isBusiness } },
|
|
19881
|
+
...weight === void 0 ? null : { physicalProperties: { weight: { value: weight, unit: "g" } } }
|
|
19881
19882
|
};
|
|
19882
19883
|
const response = await proxyCapabilities({ body, parameters: { filterSupported: true } });
|
|
19883
19884
|
return response.results ?? [];
|
|
@@ -19918,6 +19919,16 @@ const FIELD_PACKAGE_TYPE = `${DELIVERY_OPTIONS_PREFIX}.${PACKAGE_TYPE}`;
|
|
|
19918
19919
|
const FIELD_DELIVERY_TYPE = `${DELIVERY_OPTIONS_PREFIX}.${DELIVERY_TYPE}`;
|
|
19919
19920
|
const FIELD_MANUAL_WEIGHT = `${PHYSICAL_PROPERTIES_PREFIX}.${MANUAL_WEIGHT}`;
|
|
19920
19921
|
const FIELD_SHIPMENT_OPTIONS_PREFIX = `${DELIVERY_OPTIONS_PREFIX}.${SHIPMENT_OPTIONS}`;
|
|
19922
|
+
const resolveOrderInput = (form, order) => {
|
|
19923
|
+
var _a, _b, _c;
|
|
19924
|
+
const manualWeightRaw = form.getValue(FIELD_MANUAL_WEIGHT);
|
|
19925
|
+
const manualWeight = typeof manualWeightRaw === "number" && manualWeightRaw > 0 ? manualWeightRaw : void 0;
|
|
19926
|
+
return {
|
|
19927
|
+
cc: (_a = order.shippingAddress) == null ? void 0 : _a.cc,
|
|
19928
|
+
weight: manualWeight ?? ((_b = order.physicalProperties) == null ? void 0 : _b.initialWeight),
|
|
19929
|
+
isBusiness: (_c = order.shippingAddress) == null ? void 0 : _c.isBusiness
|
|
19930
|
+
};
|
|
19931
|
+
};
|
|
19921
19932
|
const wireProxyCapabilities = (form, order) => {
|
|
19922
19933
|
const orderId = order.externalIdentifier;
|
|
19923
19934
|
if (!orderId) {
|
|
@@ -19926,15 +19937,7 @@ const wireProxyCapabilities = (form, order) => {
|
|
|
19926
19937
|
}
|
|
19927
19938
|
const orderModifier = `${orderId}.order`;
|
|
19928
19939
|
const shipmentModifier = `${orderId}.shipment`;
|
|
19929
|
-
const orderInput = computed(() =>
|
|
19930
|
-
var _a, _b;
|
|
19931
|
-
const manualWeightRaw = form.getValue(FIELD_MANUAL_WEIGHT);
|
|
19932
|
-
const manualWeight = typeof manualWeightRaw === "number" && manualWeightRaw > 0 ? manualWeightRaw : void 0;
|
|
19933
|
-
return {
|
|
19934
|
-
cc: (_a = order.shippingAddress) == null ? void 0 : _a.cc,
|
|
19935
|
-
weight: manualWeight ?? ((_b = order.physicalProperties) == null ? void 0 : _b.initialWeight)
|
|
19936
|
-
};
|
|
19937
|
-
});
|
|
19940
|
+
const orderInput = computed(() => resolveOrderInput(form, order));
|
|
19938
19941
|
const formInput = computed(() => ({
|
|
19939
19942
|
carrier: form.getValue(FIELD_CARRIER),
|
|
19940
19943
|
packageType: form.getValue(FIELD_PACKAGE_TYPE),
|
|
@@ -19943,7 +19946,8 @@ const wireProxyCapabilities = (form, order) => {
|
|
|
19943
19946
|
const selection = useCapabilitiesWatcher(orderInput, formInput);
|
|
19944
19947
|
const orderInputForQuery = computed(() => ({
|
|
19945
19948
|
cc: selection.value.cc,
|
|
19946
|
-
weight: selection.value.weight
|
|
19949
|
+
weight: selection.value.weight,
|
|
19950
|
+
isBusiness: selection.value.isBusiness
|
|
19947
19951
|
}));
|
|
19948
19952
|
const orderQuery = useOrderCapabilitiesQuery(orderInputForQuery);
|
|
19949
19953
|
const shipmentQuery = useShipmentCapabilitiesQuery(selection);
|
|
@@ -21222,13 +21226,13 @@ const setupAdminApp = (app, appConfig) => {
|
|
|
21222
21226
|
app.directive("test", testIdDirective);
|
|
21223
21227
|
};
|
|
21224
21228
|
const renderMap = Object.freeze({
|
|
21225
|
-
[AdminView.ChildProductSettings]: async () => import("./ChildProductSettings-
|
|
21226
|
-
[AdminView.Modals]: async () => import("./Modals-
|
|
21227
|
-
[AdminView.Notifications]: async () => import("./Notifications-
|
|
21228
|
-
[AdminView.OrderBox]: async () => import("./OrderBox-
|
|
21229
|
-
[AdminView.OrderListItem]: async () => import("./OrderListItem-
|
|
21230
|
-
[AdminView.PluginSettings]: async () => import("./PluginSettings-
|
|
21231
|
-
[AdminView.ProductSettings]: async () => import("./ProductSettings-
|
|
21229
|
+
[AdminView.ChildProductSettings]: async () => import("./ChildProductSettings-CyKUVRaK.js"),
|
|
21230
|
+
[AdminView.Modals]: async () => import("./Modals-NMhNPPic.js"),
|
|
21231
|
+
[AdminView.Notifications]: async () => import("./Notifications-CEr-hfp0.js"),
|
|
21232
|
+
[AdminView.OrderBox]: async () => import("./OrderBox-BeswqlPq.js"),
|
|
21233
|
+
[AdminView.OrderListItem]: async () => import("./OrderListItem-DZBgN8DK.js"),
|
|
21234
|
+
[AdminView.PluginSettings]: async () => import("./PluginSettings-BDBzENE7.js"),
|
|
21235
|
+
[AdminView.ProductSettings]: async () => import("./ProductSettings-B5kBwk1B.js")
|
|
21232
21236
|
});
|
|
21233
21237
|
const renderViewComponent = async (componentName) => {
|
|
21234
21238
|
const renderMethod = renderMap[componentName];
|
|
@@ -23441,7 +23445,7 @@ const _sfc_main$f = /* @__PURE__ */ defineComponent({
|
|
|
23441
23445
|
const _sfc_main$e = /* @__PURE__ */ defineComponent({
|
|
23442
23446
|
__name: "ShipmentOptionsModal",
|
|
23443
23447
|
setup(__props) {
|
|
23444
|
-
const ShipmentOptionsModalForm = /* @__PURE__ */ defineAsyncComponent(() => import("./ShipmentOptionsModalForm-
|
|
23448
|
+
const ShipmentOptionsModalForm = /* @__PURE__ */ defineAsyncComponent(() => import("./ShipmentOptionsModalForm-BHKttVyQ.js"));
|
|
23445
23449
|
const orderMode = useOrderMode();
|
|
23446
23450
|
const ordersData = computed(() => useOrdersData());
|
|
23447
23451
|
const orderIds = computed(() => toValue$1(ordersData).map((data) => {
|
|
@@ -23473,7 +23477,7 @@ const _sfc_main$d = /* @__PURE__ */ defineComponent({
|
|
|
23473
23477
|
__name: "PrintOptionsModal",
|
|
23474
23478
|
setup(__props) {
|
|
23475
23479
|
const modalKey = AdminModalKey.PrintOptions;
|
|
23476
|
-
const PrintOptionsModalForm = /* @__PURE__ */ defineAsyncComponent(() => import("./PrintOptionsModalForm-
|
|
23480
|
+
const PrintOptionsModalForm = /* @__PURE__ */ defineAsyncComponent(() => import("./PrintOptionsModalForm-Coh6mRx1.js"));
|
|
23477
23481
|
const actionStore = useActionStore();
|
|
23478
23482
|
actionStore.register(modalSubmitFormAction);
|
|
23479
23483
|
const actions = instantiateActions([modalCloseAction, modalSubmitFormAction]);
|
|
@@ -23597,7 +23601,7 @@ const _sfc_main$a = /* @__PURE__ */ defineComponent({
|
|
|
23597
23601
|
const _sfc_main$9 = /* @__PURE__ */ defineComponent({
|
|
23598
23602
|
__name: "OrderBox",
|
|
23599
23603
|
setup(__props) {
|
|
23600
|
-
const ShipmentTableBox = /* @__PURE__ */ defineAsyncComponent(() => import("./ShipmentTableBox-
|
|
23604
|
+
const ShipmentTableBox = /* @__PURE__ */ defineAsyncComponent(() => import("./ShipmentTableBox-DskzPlmr.js"));
|
|
23601
23605
|
const queryStore = useQueryStore();
|
|
23602
23606
|
queryStore.registerContextQueries();
|
|
23603
23607
|
queryStore.registerOrderQueries();
|
|
@@ -23638,10 +23642,10 @@ const _sfc_main$7 = /* @__PURE__ */ defineComponent({
|
|
|
23638
23642
|
__name: "OrderListItem",
|
|
23639
23643
|
setup(__props) {
|
|
23640
23644
|
const OrderModeOrderListItem = /* @__PURE__ */ defineAsyncComponent(() => {
|
|
23641
|
-
return import("./OrderModeOrderListItem-
|
|
23645
|
+
return import("./OrderModeOrderListItem-DXF6TEy-.js");
|
|
23642
23646
|
});
|
|
23643
23647
|
const ShipmentModeOrderListItem = /* @__PURE__ */ defineAsyncComponent(() => {
|
|
23644
|
-
return import("./ShipmentModeOrderListItem-
|
|
23648
|
+
return import("./ShipmentModeOrderListItem-CmORFPYC.js");
|
|
23645
23649
|
});
|
|
23646
23650
|
const queryStore = useQueryStore();
|
|
23647
23651
|
queryStore.registerContextQueries();
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Z, as, at, cz, S, au, A, av, cn, cA, J, ae, aC, aD, aE, aF, aG, aH, aI, aJ, aK, aM, cB, aQ, aR, X, aS, co, af, aw, al, ag, c0, ct, cu, Y, a8, aU, am, aj, ak, bL, bM, an, ao, cm, B, _, C, $, cy, cw, ap, cs, aq, ar, cx, cv, ax, aW, aY, c9, aZ, ca, cb, aV, aX, cc, cd, bP, bS, ce, bV, cf, cg, ch, ci, cj, bT, bU, a_, aT, bY, bZ, cp, ay, az, aA, a2, b_, W, a4, a3, a1, a0, b$, c1, a$, bR, aB, aL, ck, cq, cl, R, c4, c2, c5, c3, bW, bX, bQ, b0, h, b3, b4, bG, br, bB, bH, bt, b5, b6, b6 as b62, aN, b7, b8, bw, bC, bI, bJ, bK, bN, bO, aO, aP, b9, ba, bb, bc, I, bd, be, bf, bg, b1, bh, b2, H, U, u, bF, bx, bD, bi, n, bj, bk, bl, bm, bu, bv, bn, bo, bp, bs, by, bz, bA, bE, bq, cr, c7, c8, c6 } from "./index-
|
|
1
|
+
import { Z, as, at, cz, S, au, A, av, cn, cA, J, ae, aC, aD, aE, aF, aG, aH, aI, aJ, aK, aM, cB, aQ, aR, X, aS, co, af, aw, al, ag, c0, ct, cu, Y, a8, aU, am, aj, ak, bL, bM, an, ao, cm, B, _, C, $, cy, cw, ap, cs, aq, ar, cx, cv, ax, aW, aY, c9, aZ, ca, cb, aV, aX, cc, cd, bP, bS, ce, bV, cf, cg, ch, ci, cj, bT, bU, a_, aT, bY, bZ, cp, ay, az, aA, a2, b_, W, a4, a3, a1, a0, b$, c1, a$, bR, aB, aL, ck, cq, cl, R, c4, c2, c5, c3, bW, bX, bQ, b0, h, b3, b4, bG, br, bB, bH, bt, b5, b6, b6 as b62, aN, b7, b8, bw, bC, bI, bJ, bK, bN, bO, aO, aP, b9, ba, bb, bc, I, bd, be, bf, bg, b1, bh, b2, H, U, u, bF, bx, bD, bi, n, bj, bk, bl, bm, bu, bv, bn, bo, bp, bs, by, bz, bA, bE, bq, cr, c7, c8, c6 } from "./index-CwKPv7Cc.js";
|
|
2
2
|
export {
|
|
3
3
|
Z as ActionButton,
|
|
4
4
|
as as AdminAction,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@myparcel-dev/pdk-admin-js",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.1.0",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "https://github.com/myparcelnl/js-pdk.git",
|
|
@@ -29,13 +29,13 @@
|
|
|
29
29
|
"test:update": "run ws:test:update \"$(pwd)\""
|
|
30
30
|
},
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@myparcel-dev/pdk-admin": "^2.
|
|
32
|
+
"@myparcel-dev/pdk-admin": "^2.1.0"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
35
35
|
"@myparcel-dev/pdk-build-vite": "1.0.0-alpha.0",
|
|
36
36
|
"typescript": "^5.2.2",
|
|
37
37
|
"vite": "^5.4.10",
|
|
38
|
-
"vitest": "^2.
|
|
38
|
+
"vitest": "^3.2.6"
|
|
39
39
|
},
|
|
40
40
|
"peerDependencies": {
|
|
41
41
|
"vue": "3.4.31"
|
package/dist/Modals-WFWEKC20.js
DELETED