Fall back to 'pretty' hours display if config is invalid etc.
This commit is contained in:
parent
3111aad7cd
commit
76e71d634e
|
@ -355,6 +355,8 @@ class TimeSheetView(View):
|
|||
if self.request.user:
|
||||
hours_style = self.rattail_config.get('tailbone', 'hours_style.{}'.format(self.request.user.username),
|
||||
default='pretty')
|
||||
if hours_style != 'decimal':
|
||||
hours_style = 'pretty'
|
||||
|
||||
shift_type = 'scheduled' if cls is model.ScheduledShift else 'worked'
|
||||
min_time = localtime(self.rattail_config, datetime.datetime.combine(weekdays[0], datetime.time(0)))
|
||||
|
|
Loading…
Reference in a new issue