added functionality to the add a schedule form