Validation of number (decimal) field not working as expected