Fix bad code of datetimepicker