Fixed bug with simple timesheet view mode and the unused quantity field

This commit is contained in:
Andreas Stöckel 2010-06-28 13:41:16 +00:00
parent 6b06060923
commit 1a142d1ad0

View File

@ -158,7 +158,7 @@ class timesheet_ui extends timesheet_bo
case 'save':
case 'save_new':
case 'apply':
if (!$this->data['ts_quantity'] && $this->data['ts_duration']) // set the quantity (in h) from the duration (in min)
if ((!$this->data['ts_quantity'] || $this->ts_viewtype == 'short') && $this->data['ts_duration']) // set the quantity (in h) from the duration (in min)
{
$this->data['ts_quantity'] = $this->data['ts_duration'] / 60.0;
}