- $hours = $quota->quotaToFloat($request->getParameter('workdayHours'));
- if ($hours != $user->workday_hours) {
- if (!ttTeamHelper::update($user->team_id, array('name'=>$user->team,'workday_hours'=>$hours)))
- $err->add($i18n->getKey('error.db'));
+ $workday_minutes = ttTimeHelper::postedDurationToMinutes($request->getParameter('workdayHours'));
+ if ($workday_minutes != $user->getWorkdayMinutes()) {
+ if (!$user->updateGroup(array('workday_minutes'=>$workday_minutes)))
+ $err->add($i18n->get('error.db'));