Debug contact by default
This commit is contained in:
parent
c6c498fd67
commit
c83f40fc7e
@ -1595,7 +1595,7 @@ if ($action == 'create')
|
|||||||
|
|
||||||
if ($socid > 0)
|
if ($socid > 0)
|
||||||
{
|
{
|
||||||
// Contacts (ask contact only if thirdparty already defined). TODO do this also into order and invoice.
|
// Contacts (ask contact only if thirdparty already defined).
|
||||||
print "<tr><td>" . $langs->trans("DefaultContact") . '</td><td>';
|
print "<tr><td>" . $langs->trans("DefaultContact") . '</td><td>';
|
||||||
$form->select_contacts($soc->id, $contactid, 'contactid', 1, $srccontactslist);
|
$form->select_contacts($soc->id, $contactid, 'contactid', 1, $srccontactslist);
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|||||||
@ -70,6 +70,7 @@ $action = GETPOST('action', 'alpha');
|
|||||||
$cancel = GETPOST('cancel', 'alpha');
|
$cancel = GETPOST('cancel', 'alpha');
|
||||||
$confirm = GETPOST('confirm', 'alpha');
|
$confirm = GETPOST('confirm', 'alpha');
|
||||||
$lineid = GETPOST('lineid', 'int');
|
$lineid = GETPOST('lineid', 'int');
|
||||||
|
$contactid = GETPOST('contactid', 'int');
|
||||||
$projectid = GETPOST('projectid', 'int');
|
$projectid = GETPOST('projectid', 'int');
|
||||||
$origin = GETPOST('origin', 'alpha');
|
$origin = GETPOST('origin', 'alpha');
|
||||||
$originid = (GETPOST('originid', 'int') ? GETPOST('originid', 'int') : GETPOST('origin_id', 'int')); // For backward compatibility
|
$originid = (GETPOST('originid', 'int') ? GETPOST('originid', 'int') : GETPOST('origin_id', 'int')); // For backward compatibility
|
||||||
@ -1646,8 +1647,9 @@ if ($action == 'create' && $usercancreate)
|
|||||||
|
|
||||||
// Contact of order
|
// Contact of order
|
||||||
if ($socid > 0) {
|
if ($socid > 0) {
|
||||||
|
// Contacts (ask contact only if thirdparty already defined).
|
||||||
print "<tr><td>" . $langs->trans("DefaultContact") . '</td><td>';
|
print "<tr><td>" . $langs->trans("DefaultContact") . '</td><td>';
|
||||||
$form->select_contacts($soc->id, $setcontact, 'contactid', 1, $srccontactslist, '', 1);
|
$form->select_contacts($soc->id, $contactid, 'contactid', 1, $srccontactslist, '', 1);
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Ligne info remises tiers
|
// Ligne info remises tiers
|
||||||
|
|||||||
@ -371,7 +371,7 @@ if (empty($reshook))
|
|||||||
$object->priv = GETPOST("priv", 'int');
|
$object->priv = GETPOST("priv", 'int');
|
||||||
$object->note_public = GETPOST("note_public", 'none');
|
$object->note_public = GETPOST("note_public", 'none');
|
||||||
$object->note_private = GETPOST("note_private", 'none');
|
$object->note_private = GETPOST("note_private", 'none');
|
||||||
$object->roles = GETPOST("roles", 'array');
|
$object->roles = GETPOST("roles", 'array');
|
||||||
|
|
||||||
// Fill array 'array_options' with data from add form
|
// Fill array 'array_options' with data from add form
|
||||||
$ret = $extrafields->setOptionalsFromPost(null, $object);
|
$ret = $extrafields->setOptionalsFromPost(null, $object);
|
||||||
@ -725,9 +725,9 @@ else
|
|||||||
print "</td></tr>";
|
print "</td></tr>";
|
||||||
}
|
}
|
||||||
|
|
||||||
//Role
|
// Contact by default
|
||||||
if (!empty($socid)) {
|
if (!empty($socid)) {
|
||||||
print '<tr><td>' . $langs->trans("Role") . '</td>';
|
print '<tr><td>' . $langs->trans("ContactByDefaultFor") . '</td>';
|
||||||
print '<td colspan="3">';
|
print '<td colspan="3">';
|
||||||
$contactType = $object->listeTypeContacts('external', '', 1);
|
$contactType = $object->listeTypeContacts('external', '', 1);
|
||||||
print $form->multiselectarray('roles', $contactType);
|
print $form->multiselectarray('roles', $contactType);
|
||||||
@ -1050,9 +1050,9 @@ else
|
|||||||
print "</td></tr>";
|
print "</td></tr>";
|
||||||
}
|
}
|
||||||
|
|
||||||
//Role
|
// Contact by default
|
||||||
if (!empty($object->socid)) {
|
if (!empty($object->socid)) {
|
||||||
print '<tr><td>' . $langs->trans("Role") . '</td>';
|
print '<tr><td>' . $langs->trans("ContactByDefaultFor") . '</td>';
|
||||||
print '<td colspan="3">';
|
print '<td colspan="3">';
|
||||||
print $formcompany->showRoles("roles", $object, 'edit', $object->roles);
|
print $formcompany->showRoles("roles", $object, 'edit', $object->roles);
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
@ -1206,7 +1206,7 @@ else
|
|||||||
print $object->getCivilityLabel();
|
print $object->getCivilityLabel();
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|
||||||
// Role
|
// Job / position
|
||||||
print '<tr><td>'.$langs->trans("PostOrFunction").'</td><td>'.$object->poste.'</td></tr>';
|
print '<tr><td>'.$langs->trans("PostOrFunction").'</td><td>'.$object->poste.'</td></tr>';
|
||||||
|
|
||||||
// Email
|
// Email
|
||||||
@ -1257,7 +1257,7 @@ else
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!empty($object->socid)) {
|
if (!empty($object->socid)) {
|
||||||
print '<tr><td class="titlefield">' . $langs->trans("Roles") . '</td>';
|
print '<tr><td class="titlefield">' . $langs->trans("ContactByDefaultFor") . '</td>';
|
||||||
print '<td colspan="3">';
|
print '<td colspan="3">';
|
||||||
print $formcompany->showRoles("roles", $object, 'view');
|
print $formcompany->showRoles("roles", $object, 'view');
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
|
|||||||
@ -298,6 +298,7 @@ FromContactName=Name:
|
|||||||
NoContactDefinedForThirdParty=No contact defined for this third party
|
NoContactDefinedForThirdParty=No contact defined for this third party
|
||||||
NoContactDefined=No contact defined
|
NoContactDefined=No contact defined
|
||||||
DefaultContact=Default contact/address
|
DefaultContact=Default contact/address
|
||||||
|
ContactByDefaultFor=Default contact/address for
|
||||||
AddThirdParty=Create third party
|
AddThirdParty=Create third party
|
||||||
DeleteACompany=Delete a company
|
DeleteACompany=Delete a company
|
||||||
PersonalInformations=Personal data
|
PersonalInformations=Personal data
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user