Implemented truncate(to => 'local_week')

Implemented truncate(to => 'local_week') and simplified calculation of local_day_of_week()