public function AdjustmentTransformerInterface::combineAdjustments in Commerce Core 8.2
Combines adjustments with the same type and source ID.
For example, all tax adjustments generated by the same tax type will be combined into a single adjustment, which can then be shown in total summaries.
Parameters
\Drupal\commerce_order\Adjustment[] $adjustments: The adjustments.
Return value
\Drupal\commerce_order\Adjustment[] The combined adjustments.
1 method overrides AdjustmentTransformerInterface::combineAdjustments()
- AdjustmentTransformer::combineAdjustments in modules/
order/ src/ AdjustmentTransformer.php - Combines adjustments with the same type and source ID.
File
- modules/
order/ src/ AdjustmentTransformerInterface.php, line 34
Class
- AdjustmentTransformerInterface
- Provides common logic for processing and transforming adjustments.
Namespace
Drupal\commerce_orderCode
public function combineAdjustments(array $adjustments);