diff --git a/htdocs/comm/action/card.php b/htdocs/comm/action/card.php index 2b3aae73a4d..365e45a2f5e 100644 --- a/htdocs/comm/action/card.php +++ b/htdocs/comm/action/card.php @@ -2447,6 +2447,7 @@ if ($id > 0) { print ' ('.$tmpuserstatic->getNomUrl(0, '', 0, 0, 16).')'; } print ' - '.$actioncommreminder->offsetvalue.' '.$TDurationTypes[$actioncommreminder->offsetunit]; + if ($actioncommreminder->status == $actioncommreminder::STATUS_TODO) { print ' - '; print $langs->trans("NotSent"); @@ -2455,6 +2456,10 @@ if ($id > 0) { print ' - '; print $langs->trans("Done"); print ' '; + } elseif ($actioncommreminder->status == $actioncommreminder::STATUS_ERROR) { + print ' - '; + print $form->textwithpicto($langs->trans("Error"), $actioncommreminder->lasterror); + print ' '; } print '
'; } diff --git a/htdocs/comm/action/class/actioncomm.class.php b/htdocs/comm/action/class/actioncomm.class.php index 69bc112e081..75a7638f676 100644 --- a/htdocs/comm/action/class/actioncomm.class.php +++ b/htdocs/comm/action/class/actioncomm.class.php @@ -2414,7 +2414,7 @@ class ActionComm extends CommonObject $this->reminders = array(); //Select all action comm reminders for event - $sql = "SELECT rowid as id, typeremind, dateremind, status, offsetvalue, offsetunit, fk_user"; + $sql = "SELECT rowid as id, typeremind, dateremind, status, offsetvalue, offsetunit, fk_user, fk_email_template, lasterror"; $sql .= " FROM ".MAIN_DB_PREFIX."actioncomm_reminder"; $sql .= " WHERE fk_actioncomm = ".((int) $this->id); if ($onlypast) { @@ -2446,6 +2446,8 @@ class ActionComm extends CommonObject $tmpactioncommreminder->offsetunit = $obj->offsetunit; $tmpactioncommreminder->status = $obj->status; $tmpactioncommreminder->fk_user = $obj->fk_user; + $tmpactioncommreminder->fk_email_template = $obj->fk_email_template; + $tmpactioncommreminder->lasterror = $obj->lasterror; $this->reminders[$obj->id] = $tmpactioncommreminder; }