Make separate actions on the datepicker for showing and hiding