How to set min and max value of number field?