Web Portal - prevent user to set entry date in the past

Hi, in oneidentity version 8.2.1 I'd like to force users to chose an entrydate, in the new employee form, in the future and not in the past. Moreover when a date is chosen, then the exit date could be only a date in the next n days from the selected entrydate.It could be done?
I found a workaround that consists in a formatting script in the entrydate and exitdate attributes, but I would prefer to achieve it directly in the web portal, if it is possible.

Thanks,

Roberto