feat: shayegan inbound charges workflow and copper kilogram unit enforcement
This commit is contained in:
@@ -717,6 +717,8 @@ class AssetSummaryService
|
||||
$meltedWeight = round(Controller::gramsToTradeUnit($meltedGrams), 3);
|
||||
$totalWeight = round($productWeight + $meltedWeight, 3);
|
||||
|
||||
$metalUnit = ((int) $metalId === 3 || $weightUnit === 'کیلوگرم') ? 'کیلوگرم' : $weightUnit;
|
||||
|
||||
$totals[] = [
|
||||
'metal_id' => (int) $metalId,
|
||||
'metal_label' => self::METAL_LABELS[$metalId] ?? 'فلز',
|
||||
@@ -724,7 +726,7 @@ class AssetSummaryService
|
||||
'product_weight' => $productWeight,
|
||||
'melted_weight' => $meltedWeight,
|
||||
'total_weight' => $totalWeight,
|
||||
'unit' => $weightUnit,
|
||||
'unit' => $metalUnit,
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user