Added end date and block adding when end date set