Fix emailcollector edition

This commit is contained in:
Laurent Destailleur 2020-12-22 17:03:57 +01:00
parent 6fad9c2d3b
commit 083b6a8c87
2 changed files with 5 additions and 1 deletions

View File

@ -153,6 +153,10 @@ if (GETPOST('addoperation', 'alpha'))
$emailcollectoroperation->status = 1;
$emailcollectoroperation->position = 50;
if ($emailcollectoroperation->type == '-1') {
$error++;
setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Operation")), null, 'errors');
}
if (in_array($emailcollectoroperation->type, array('loadthirdparty', 'loadandcreatethirdparty'))
&& empty($emailcollectoroperation->actionparam)) {
$error++;

View File

@ -56,7 +56,7 @@ class EmailCollector extends CommonObject
/**
* @var string String with name of icon for emailcollector. Must be the part after the 'object_' into object_emailcollector.png
*/
public $picto = 'generic';
public $picto = 'email';
/**
* @var string Field with ID of parent key if this field has a parent