Add external code field to time_slot table and managment