added checkbox as field-type, correct JS, added validations on fields