public function Subtotal::load in Ubercart 8.4
File
- uc_order/
src/ Plugin/ Ubercart/ LineItem/ Subtotal.php, line 22
Class
- Subtotal
- Handles the subtotal line item.
Namespace
Drupal\uc_order\Plugin\Ubercart\LineItemCode
public function load(OrderInterface $order) {
$lines[] = [
'id' => 'subtotal',
'title' => $this
->t('Subtotal'),
'amount' => $order
->getSubtotal(),
];
return $lines;
}