mirror of
https://github.com/Part-DB/Part-DB-server.git
synced 2025-07-20 19:05:14 +02:00
Use BigDecimal for Currency exchange rate.
This commit is contained in:
parent
08267b88b0
commit
db4d7dc5fc
9 changed files with 135 additions and 20 deletions
|
@ -43,6 +43,7 @@ declare(strict_types=1);
|
|||
namespace App\Form\AdminPages;
|
||||
|
||||
use App\Entity\Base\AbstractNamedDBElement;
|
||||
use App\Form\Type\BigDecimalMoneyType;
|
||||
use Symfony\Component\Form\Extension\Core\Type\CurrencyType;
|
||||
use Symfony\Component\Form\Extension\Core\Type\MoneyType;
|
||||
use Symfony\Component\Form\FormBuilderInterface;
|
||||
|
@ -74,7 +75,7 @@ class CurrencyAdminForm extends BaseEntityAdminForm
|
|||
'disabled' => ! $this->security->isGranted($is_new ? 'create' : 'edit', $entity),
|
||||
]);
|
||||
|
||||
$builder->add('exchange_rate', MoneyType::class, [
|
||||
$builder->add('exchange_rate', BigDecimalMoneyType::class, [
|
||||
'required' => false,
|
||||
'label' => 'currency.edit.exchange_rate',
|
||||
'currency' => $this->default_currency,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue