Skip to content
Snippets Groups Projects
Commit d60f6b42 authored by Bojan Živanović's avatar Bojan Živanović
Browse files

Issue #2876660 by bojanz: The Custom tax type should allow decimal amounts

parent 8cac69ae
No related branches found
Tags 8.x-2.0-beta7
No related merge requests found
......@@ -44,7 +44,7 @@ class Custom extends LocalTaxTypeBase {
* The event dispatcher.
* @param \Drupal\commerce_price\RounderInterface $rounder
* The rounder.
* @param \Drupal\commerce_tax\ChainTaxRateResolverInterface $chain_rate_resolver
* @param \Drupal\commerce_tax\Resolver\ChainTaxRateResolverInterface $chain_rate_resolver
* The chain tax rate resolver.
* @param \Drupal\Component\Uuid\UuidInterface $uuid_generator
* The UUID generator.
......@@ -142,7 +142,7 @@ class Custom extends LocalTaxTypeBase {
'#required' => TRUE,
];
$rate_form['amount'] = [
'#type' => 'number',
'#type' => 'commerce_number',
'#title' => 'Amount',
'#default_value' => $rate ? $rate['amount'] * 100 : 0,
'#field_suffix' => $this->t('%'),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment