assign based on office hours

assign based on office hours

can i assign a ticket based on office hours?
if ticket arrived during office hours, assign to TEAM 1,
if ticket arrived outside office hours, assign to TEAM 2?