When adjusting infologs dates to create a project from template, take real start date into account too, if set.

This commit is contained in:
nathangray 2016-07-20 13:04:57 -06:00 committed by Ralf Becker
parent 35eda073dd
commit 82796fc155

View File

@ -123,7 +123,12 @@ class infolog_datasource extends datasource
} }
// Apply date offsets, if any // Apply date offsets, if any
$map = array('planned_start' => 'info_startdate', 'planned_end' => 'info_enddate', 'real_end' => 'info_datecompleted'); $map = array(
'planned_start' => 'info_startdate',
'planned_end' => 'info_enddate',
'real_start' => 'info_startdate',
'real_end' => 'info_datecompleted'
);
foreach($map as $offset_field => $info_field) foreach($map as $offset_field => $info_field)
{ {
if($date_offsets[$offset_field] && $info[$info_field]) if($date_offsets[$offset_field] && $info[$info_field])