Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .php-cs-fixer.php
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?php
$header = <<<EOF
@author Mygento Team
@copyright 2016-2024 Mygento (https://www.mygento.ru)
@copyright 2016-2025 Mygento (https://www.mygento.com)
@package Mygento_Shipment
EOF;

Expand Down
2 changes: 1 addition & 1 deletion Api/Carrier/AbstractCarrierInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Carrier/BaseInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Carrier/TrackingInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/CarrierManagerInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Client/AbstractClientInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Client/BaseInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Data/CalculateRequestInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Data/CalculateResultInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Data/EstimateTimeInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Data/PointInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Data/PointProviderInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Data/PointSearchResultsInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/DimensionInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/PointManagerInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/PointRepositoryInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Service/AutoshipInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Service/BaseInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Service/CalculateInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Service/MarkingInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Service/OrderInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Api/Service/PointInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Block/Adminhtml/Config/Carrier/TrackStatuses.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Block/Adminhtml/Config/Magento/OrderStatuses.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Block/Adminhtml/Order/DeliveryDatetime.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Block/Adminhtml/Order/Estimate.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Block/Adminhtml/Order/Tab/Delivery.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Controller/Adminhtml/Order/DeliveryDate.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Controller/Adminhtml/Order/DeliveryTab.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Controller/Adminhtml/Order/DeliveryTime.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Controller/Adminhtml/Point.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Controller/Adminhtml/Point/Index.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Helper/Data.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
13 changes: 10 additions & 3 deletions Helper/Dimensions.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down Expand Up @@ -122,9 +122,16 @@ public function dimenAlgo(array $dimensions): array
}

foreach ($dim as $d) {
($d['width'] > $result['width']) ? $result['width'] = $d['width'] : '';
//find the maximum items height
($d['height'] > $result['height']) ? $result['height'] = $d['height'] : '';
$result['length'] += $d['length'];

//find the longest horizontal side (either length or width) - used as the package length
$length = max($d['length'], $d['width']);
($length > $result['length']) ? $result['length'] = $length : '';

//sum the shorter horizontal side if items are laid in a row
$width = min($d['length'], $d['width']);
$result['width'] += $width;
}
$result['volume'] = $result['length'] * $result['height'] * $result['width'];

Expand Down
2 changes: 1 addition & 1 deletion Model/AbstractCarrier.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Model/AbstractClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Model/AbstractService.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Model/Carrier.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Model/CarrierManager.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Model/Client.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Model/Cron/Autoship.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
2 changes: 1 addition & 1 deletion Model/Estimate/Time.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

/**
* @author Mygento Team
* @copyright 2016-2024 Mygento (https://www.mygento.ru)
* @copyright 2016-2025 Mygento (https://www.mygento.com)
* @package Mygento_Shipment
*/

Expand Down
Loading
Loading