diff --git a/htdocs/admin/mails_templates.php b/htdocs/admin/mails_templates.php index 6d0267f802a71..42c365d0bfb5d 100644 --- a/htdocs/admin/mails_templates.php +++ b/htdocs/admin/mails_templates.php @@ -239,6 +239,11 @@ if (isModEnabled('partnership') && !empty($user->rights->partnership->read)) { $elementList['partnership_send'] = img_picto('', 'partnership', 'class="pictofixedwidth"').dol_escape_htmltag($langs->trans('MailToPartnership')); } +// START BACKPORT WENEOS - A SUPP EN V22.0 +if (isModEnabled('product') && !empty($user->rights->produit->lire)) { + $elementList['product_send'] = img_picto('', 'product', 'class="pictofixedwidth"').dol_escape_htmltag($langs->trans('Product')); +} +// END BACKPORT WENEOS - A SUPP EN V22.0 $parameters = array('elementList'=>$elementList); $reshook = $hookmanager->executeHooks('emailElementlist', $parameters); // Note that $action and $object may have been modified by some hooks diff --git a/htdocs/core/class/html.formmail.class.php b/htdocs/core/class/html.formmail.class.php index 49669a4c02cbb..e9ef6fb74ede2 100644 --- a/htdocs/core/class/html.formmail.class.php +++ b/htdocs/core/class/html.formmail.class.php @@ -521,7 +521,12 @@ public function get_form($addfileaction = 'addfile', $removefileaction = 'remove } elseif (!empty($this->param['models']) && in_array($this->param['models'], array( 'propal_send', 'order_send', 'facture_send', 'shipping_send', 'fichinter_send', 'supplier_proposal_send', 'order_supplier_send', - 'invoice_supplier_send', 'thirdparty', 'contract', 'user', 'recruitmentcandidature_send', 'all' + 'invoice_supplier_send', 'thirdparty', 'contract', 'user', 'recruitmentcandidature_send', + // START BACKPORT WENEOS - A SUPP EN V22.0 + 'product_send', + // END BACKPORT WENEOS - A SUPP EN V22.0 + 'all' + ))) { // If list of template is empty $out .= '