Whenever I save with an amount say £120.00, when I save & close and go back I end up with the amount £12,000.00, if I repeat this process I end up with £1,200,000.00 and so on. This happens every time I save & close.
I have the following in my table:
$table->integer('currency_id');
$table->decimal('amount', 15,2);
fields.yaml
price:
label: 'vektar.crm::lang.job.amount'
placeholder: '-- TOTAL AMOUNT --'
type: money
mode: amountcurrency
span: auto
tab: 'Job Information'
Model:
public $implement = [
'Initbiz.Money.Behaviors.MoneyFields'
];
public $moneyFields = [
'price' => [
'amountColumn' => 'amount',
'currencyIdColumn' => 'currency_id'
]
];
Any ideas why this might be happening?
Last updated