Skip to content

Commit

Permalink
Update ManageShippingRates.php
Browse files Browse the repository at this point in the history
  • Loading branch information
wychoong authored Sep 23, 2024
1 parent a5088b7 commit fc6e1c9
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ static function (Forms\Components\Repeater $component, ?Model $record = null): v
'customer_group_id' => $price->customer_group_id,
'price' => $price->price->decimal,
'currency_id' => $price->currency_id,
'min_quantity' => $chargeBy == 'cart_total' ? $price->min_quantity / $currency->factor : $price->min_quantity / 1000,
'min_quantity' => $chargeBy == 'cart_total' ? $price->min_quantity / $currency->factor : $price->min_quantity / 100,
];
})->toArray()
);
Expand Down Expand Up @@ -219,7 +219,7 @@ function ($price) use ($chargeBy, $currencies) {
if ($chargeBy == 'cart_total') {
$price['min_quantity'] = (int) ($price['min_quantity'] * $currency->factor);
} else {
$price['min_quantity'] = (int) ($price['min_quantity'] * 1000);
$price['min_quantity'] = (int) ($price['min_quantity'] * 100);
}

$price['price'] = (int) ($price['price'] * $currency->factor);
Expand Down

0 comments on commit fc6e1c9

Please sign in to comment.