forked from Wavyzz/dolibarr
Merge branch '16.0' of git@github.com:/Dolibarr/dolibarr.git into 17.0
This commit is contained in:
@@ -1442,8 +1442,14 @@ if ($action == 'create') {
|
|||||||
$preselectedids[GETPOST('contactid', 'int')] = GETPOST('contactid', 'int');
|
$preselectedids[GETPOST('contactid', 'int')] = GETPOST('contactid', 'int');
|
||||||
}
|
}
|
||||||
if ($origin=='contact') $preselectedids[GETPOST('originid', 'int')] = GETPOST('originid', 'int');
|
if ($origin=='contact') $preselectedids[GETPOST('originid', 'int')] = GETPOST('originid', 'int');
|
||||||
|
// select "all" or "none" contact by default
|
||||||
|
if (getDolGlobalInt('MAIN_ACTIONCOM_CAN_ADD_ANY_CONTACT')) {
|
||||||
|
$select_contact_default = 0; // select "all" contacts by default : avoid to use it if there is a lot of contacts
|
||||||
|
} else {
|
||||||
|
$select_contact_default = -1; // select "none" by default
|
||||||
|
}
|
||||||
print img_picto('', 'contact', 'class="paddingrightonly"');
|
print img_picto('', 'contact', 'class="paddingrightonly"');
|
||||||
print $form->selectcontacts(GETPOST('socid', 'int'), $preselectedids, 'socpeopleassigned[]', 1, '', '', 0, 'minwidth300 quatrevingtpercent', false, 0, array(), false, 'multiple', 'contactid');
|
print $form->selectcontacts(GETPOSTISSET('socid') ? GETPOSTINT('socid') : $select_contact_default, $preselectedids, 'socpeopleassigned[]', 1, '', '', 0, 'minwidth300 quatrevingtpercent', false, 0, array(), false, 'multiple', 'contactid');
|
||||||
print '</td></tr>';
|
print '</td></tr>';
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user