-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AP-3563: Fix error message and form value rendering
This fixes an underlying bug that causes the behaviour described in the bug ticket AP-3563. Namely, that while the amount for any cash income or outgoing type is validated it is not done in the way common to other pages or forms. This has resulted in a difference whereby comma separated monetayr values, `1,000`, are invalid but where being rendered as a value when the form errors and rerenders. This has been corrected to emulate the functionality seen in form objects with monetary amount fields. 1. It now "cleans" the monetary amount params to remove `£` and `,`. 2. When rendering the form the field value is no longer rendered as a "number to currency" value with no unit - which was rendering commas for numeric values over 3 digits long.
- Loading branch information
Showing
4 changed files
with
31 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters