Skip to content

Commit

Permalink
feat: add support for small package (#1158)
Browse files Browse the repository at this point in the history
INT-644
  • Loading branch information
GravendeelJochem authored Sep 16, 2024
1 parent ccfc8f2 commit 158fb95
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
"name": "myparcelnl/woocommerce",
"version": "4.23.0",
"require": {
"myparcelnl/sdk": "~7.8.0"
"myparcelnl/sdk": "^7.15.4"
},
"autoload": {
"psr-4": {
Expand Down
3 changes: 3 additions & 0 deletions includes/class-wcmp-data.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ class WCMP_Data
AbstractConsignment::PACKAGE_TYPE_MAILBOX => 2000,
AbstractConsignment::PACKAGE_TYPE_LETTER => 2000,
AbstractConsignment::PACKAGE_TYPE_DIGITAL_STAMP => 2000,
AbstractConsignment::PACKAGE_TYPE_PACKAGE_SMALL => 5000,
];

public const DEFAULT_COUNTRY_CODE = 'NL';
Expand Down Expand Up @@ -78,13 +79,15 @@ public function __construct()
AbstractConsignment::PACKAGE_TYPE_MAILBOX_NAME,
AbstractConsignment::PACKAGE_TYPE_LETTER_NAME,
AbstractConsignment::PACKAGE_TYPE_DIGITAL_STAMP_NAME,
AbstractConsignment::PACKAGE_TYPE_PACKAGE_SMALL_NAME,
];

self::$packageTypesHuman = [
AbstractConsignment::PACKAGE_TYPE_PACKAGE_NAME => __('Package', 'woocommerce-myparcel'),
AbstractConsignment::PACKAGE_TYPE_MAILBOX_NAME => __('Mailbox', 'woocommerce-myparcel'),
AbstractConsignment::PACKAGE_TYPE_LETTER_NAME => __('Unpaid letter', 'woocommerce-myparcel'),
AbstractConsignment::PACKAGE_TYPE_DIGITAL_STAMP_NAME => __('Digital stamp', 'woocommerce-myparcel'),
AbstractConsignment::PACKAGE_TYPE_PACKAGE_SMALL_NAME => __('Small package', 'woocommerce-myparcel'),
];

self::$deliveryTypesHuman = [
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
},
"homepage": "https://github.com/myparcelnl/woocommerce#readme",
"dependencies": {
"@myparcel/delivery-options": "^5.7.4"
"@myparcel/delivery-options": "^5.17.0"
},
"devDependencies": {
"@babel/core": "^7.13.10",
Expand Down

0 comments on commit 158fb95

Please sign in to comment.