From 769a8886b98fb4b13bd0c92995b35caa461f1e4a Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Tue, 8 Dec 2020 20:32:37 +0100 Subject: [PATCH] Debug notification on events --- htdocs/comm/action/card.php | 15 +++++++++------ htdocs/core/class/html.form.class.php | 13 ++++++++----- 2 files changed, 17 insertions(+), 11 deletions(-) diff --git a/htdocs/comm/action/card.php b/htdocs/comm/action/card.php index f26ad2a36e2..5d284ce048a 100644 --- a/htdocs/comm/action/card.php +++ b/htdocs/comm/action/card.php @@ -1251,12 +1251,12 @@ if ($action == 'create') //Reminder Type print ''.$langs->trans("ReminderType").''; - print $form->selectarray('selectremindertype', $TRemindTypes); + print $form->selectarray('selectremindertype', $TRemindTypes, '', 0, 0, 0, '', 0, 0, 0, '', 'mimnwidth200', 1); print ''; //Mail Model print ''.$langs->trans("EMailTemplates").''; - print $form->selectModelMail('actioncommsend', 'actioncomm_send', 1); + print $form->selectModelMail('actioncommsend', 'actioncomm_send', 1, 1); print ''; @@ -1719,10 +1719,12 @@ if ($id > 0) $actionCommReminder->typeremind = 'email'; } - print ''.$langs->trans("AddReminder").''; + print '
'; print '
'; + print '
'; + print ''; // Reminder @@ -1731,9 +1733,8 @@ if ($id > 0) print ''; // Reminder Type - $TRemindTypes = array(); print ''; $hide = ''; @@ -1741,7 +1742,7 @@ if ($id > 0) // Mail Model print ''; print '
'.$langs->trans("ReminderType").''; - print $form->selectarray('selectremindertype', $TRemindTypes, $actionCommReminder->typeremind); + print $form->selectarray('selectremindertype', $TRemindTypes, $actionCommReminder->typeremind, 0, 0, 0, '', 0, 0, 0, '', 'minwidth200', 1); print '
'.$langs->trans("EMailTemplates").''; - print $form->selectModelMail('actioncommsend', 'actioncomm_send', 1); + print $form->selectModelMail('actioncommsend', 'actioncomm_send', 1, 1); print '
'; @@ -1767,6 +1768,8 @@ if ($id > 0) })'; print ''."\n"; + + print '
'; // End of div for reminderparameters } print dol_get_fiche_end(); diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index 8a125f65f86..8faad1f92e9 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -8234,12 +8234,13 @@ class Form /** * selectModelMail * - * @param string $prefix Prefix - * @param string $modelType Model type - * @param int $default 1=Show also Default mail template - * @return string HTML select string + * @param string $prefix Prefix + * @param string $modelType Model type + * @param int $default 1=Show also Default mail template + * @param int $addjscombo Add js combobox + * @return string HTML select string */ - public function selectModelMail($prefix, $modelType = '', $default = 0) + public function selectModelMail($prefix, $modelType = '', $default = 0, $addjscombo = 0) { global $langs, $db, $user; @@ -8267,6 +8268,8 @@ class Form $retstring .= ""; + if ($addjscombo) $retstring .= ajax_combobox('select_'.$prefix.'model_mail'); + return $retstring; } }