You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have an issue where a user inputs a value into a numerical input. If an issue occurs further down the call chain and the changeset is not valid the numerical input then displays the value with the currency symbol.
Is there a way to extract and display the value only?
Input if another input causes invalid changeset and page is re-rendered:
How do I ensure the amount is extracted from the changeset when this happens? Because this way if the form was submitted again would then cause an error on the amount input now because of the symbol.
The text was updated successfully, but these errors were encountered:
At the end I'm keeping running to this catch. If I don't convert money to decimal the input form shows nothing.
If I do convert money to decimal as proposed in the example above it looks right,
But if I change any other fields more than one time the value starts to raise by a factor 100 each time.
I have tried a lot of hacks, but I prefere to keep my code clean so until I understand this better I will omit Money
I have an issue where a user inputs a value into a numerical input. If an issue occurs further down the call chain and the changeset is not valid the numerical input then displays the value with the currency symbol.
Is there a way to extract and display the value only?
<.input field={f[:amount]} type="donation" required />
Input before changeset:

Input if another input causes invalid changeset and page is re-rendered:
How do I ensure the amount is extracted from the changeset when this happens? Because this way if the form was submitted again would then cause an error on the amount input now because of the symbol.
The text was updated successfully, but these errors were encountered: