update code
This commit is contained in:
parent
402d52e160
commit
a8531a4afd
@ -1587,13 +1587,13 @@ if (is_object($objcanvas) && $objcanvas->displayCanvasExists($action)) {
|
|||||||
|
|
||||||
// Email / Web
|
// Email / Web
|
||||||
print '<tr><td>'.$form->editfieldkey('EMail', 'email', '', $object, 0, 'string', '', empty($conf->global->SOCIETE_EMAIL_MANDATORY) ? '' : $conf->global->SOCIETE_EMAIL_MANDATORY).'</td>';
|
print '<tr><td>'.$form->editfieldkey('EMail', 'email', '', $object, 0, 'string', '', empty($conf->global->SOCIETE_EMAIL_MANDATORY) ? '' : $conf->global->SOCIETE_EMAIL_MANDATORY).'</td>';
|
||||||
print '<td'.(($conf->browser->layout == 'phone') || empty($conf->mailing->enabled) ? ' colspan="3"' : '').'>'.img_picto('', 'object_email', 'class="pictofixedwidth"').' <input type="text" class="maxwidth200 widthcentpercentminusx" name="email" id="email" value="'.$object->email.'"></td>';
|
print '<td'.(($conf->browser->layout == 'phone') || !isModEnabled('mailing') ? ' colspan="3"' : '').'>'.img_picto('', 'object_email', 'class="pictofixedwidth"').' <input type="text" class="maxwidth200 widthcentpercentminusx" name="email" id="email" value="'.$object->email.'"></td>';
|
||||||
if (isModEnabled('mailing') && !empty($conf->global->THIRDPARTY_SUGGEST_ALSO_ADDRESS_CREATION)) {
|
if (isModEnabled('mailing') && !empty($conf->global->THIRDPARTY_SUGGEST_ALSO_ADDRESS_CREATION)) {
|
||||||
if ($conf->browser->layout == 'phone') {
|
if ($conf->browser->layout == 'phone') {
|
||||||
print '</tr><tr>';
|
print '</tr><tr>';
|
||||||
}
|
}
|
||||||
print '<td class="individualline noemail">'.$form->editfieldkey($langs->trans('No_Email') .' ('.$langs->trans('Contact').')', 'contact_no_email', '', $object, 0).'</td>';
|
print '<td class="individualline noemail">'.$form->editfieldkey($langs->trans('No_Email') .' ('.$langs->trans('Contact').')', 'contact_no_email', '', $object, 0).'</td>';
|
||||||
print '<td class="individualline" '.(($conf->browser->layout == 'phone') || empty($conf->mailing->enabled) ? ' colspan="3"' : '').'>'.$form->selectyesno('contact_no_email', (GETPOSTISSET("contact_no_email") ? GETPOST("contact_no_email", 'alpha') : (empty($object->no_email) ? 0 : 1)), 1, false, 1).'</td>';
|
print '<td class="individualline" '.(($conf->browser->layout == 'phone') || !isModEnabled('mailing') ? ' colspan="3"' : '').'>'.$form->selectyesno('contact_no_email', (GETPOSTISSET("contact_no_email") ? GETPOST("contact_no_email", 'alpha') : (empty($object->no_email) ? 0 : 1)), 1, false, 1).'</td>';
|
||||||
}
|
}
|
||||||
print '</tr>';
|
print '</tr>';
|
||||||
print '<tr><td>'.$form->editfieldkey('Web', 'url', '', $object, 0).'</td>';
|
print '<tr><td>'.$form->editfieldkey('Web', 'url', '', $object, 0).'</td>';
|
||||||
|
|||||||
@ -1097,7 +1097,7 @@ class Societe extends CommonObject
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (empty($error) && !empty($conf->mailing->enabled) && !empty($contact->email) && isset($no_email)) {
|
if (empty($error) && isModEnabled('mailing') && !empty($contact->email) && isset($no_email)) {
|
||||||
$result = $contact->setNoEmail($no_email);
|
$result = $contact->setNoEmail($no_email);
|
||||||
if ($result < 0) {
|
if ($result < 0) {
|
||||||
$this->error = $contact->error;
|
$this->error = $contact->error;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user