money amount validation funktion mit erklärendem kommentar versehen
This commit is contained in:
parent
6758bb5a44
commit
fee14d9349
1 changed files with 1 additions and 0 deletions
|
@ -24,6 +24,7 @@ def iso_date(field, value, error):
|
|||
|
||||
def valid_money_amount(field, value, error):
|
||||
try:
|
||||
# value is string, check formatting by parsing as float
|
||||
float(value)
|
||||
return True
|
||||
except (ValueError, TypeError):
|
||||
|
|
Loading…
Reference in a new issue