FIX : late warning calculation on action comm list
This commit is contained in:
parent
87a66c7bf0
commit
97d9b4571a
@ -657,6 +657,8 @@ if ($resql)
|
|||||||
$actionstatic->label = $obj->label;
|
$actionstatic->label = $obj->label;
|
||||||
$actionstatic->location = $obj->location;
|
$actionstatic->location = $obj->location;
|
||||||
$actionstatic->note_private = dol_htmlentitiesbr($obj->note);
|
$actionstatic->note_private = dol_htmlentitiesbr($obj->note);
|
||||||
|
$actionstatic->datep = $db->jdate($obj->dp);
|
||||||
|
$actionstatic->percentage = $obj->percent;
|
||||||
|
|
||||||
$actionstatic->fetchResources();
|
$actionstatic->fetchResources();
|
||||||
|
|
||||||
@ -738,10 +740,7 @@ if ($resql)
|
|||||||
print '<td class="center nowraponall">';
|
print '<td class="center nowraponall">';
|
||||||
print dol_print_date($db->jdate($obj->dp), $formatToUse, 'tzuser');
|
print dol_print_date($db->jdate($obj->dp), $formatToUse, 'tzuser');
|
||||||
$late = 0;
|
$late = 0;
|
||||||
if ($obj->percent == 0 && $obj->dp && $db->jdate($obj->dp) < ($now - $delay_warning)) $late = 1;
|
if($actioncomm->hasDelay() && $actioncomm->percentage >= 0 && $actioncomm->percentage < 100 ) $late = 1;
|
||||||
if ($obj->percent == 0 && !$obj->dp && $obj->dp2 && $db->jdate($obj->dp) < ($now - $delay_warning)) $late = 1;
|
|
||||||
if ($obj->percent > 0 && $obj->percent < 100 && $obj->dp2 && $db->jdate($obj->dp2) < ($now - $delay_warning)) $late = 1;
|
|
||||||
if ($obj->percent > 0 && $obj->percent < 100 && !$obj->dp2 && $obj->dp && $db->jdate($obj->dp) < ($now - $delay_warning)) $late = 1;
|
|
||||||
if ($late) print img_warning($langs->trans("Late")).' ';
|
if ($late) print img_warning($langs->trans("Late")).' ';
|
||||||
print '</td>';
|
print '</td>';
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user