Fix: Country default not selected
This commit is contained in:
parent
caab5ac4e0
commit
9139427d7f
@ -434,7 +434,7 @@ else
|
||||
|
||||
$colspan=3;
|
||||
if ($conf->use_javascript_ajax && $socid > 0) $colspan=2;
|
||||
|
||||
|
||||
// Address
|
||||
if (($objsoc->typent_code == 'TE_PRIVATE' || ! empty($conf->global->CONTACT_USE_COMPANY_ADDRESS)) && dol_strlen(trim($object->address)) == 0) $object->address = $objsoc->address; // Predefined with third party
|
||||
print '<tr><td>'.$langs->trans("Address");
|
||||
@ -442,9 +442,9 @@ else
|
||||
|
||||
if ($conf->use_javascript_ajax && $socid > 0)
|
||||
{
|
||||
$rowspan=3;
|
||||
$rowspan=3;
|
||||
if (empty($conf->global->SOCIETE_DISABLE_STATE)) $rowspan++;
|
||||
|
||||
|
||||
print '<td valign="middle" align="center" rowspan="'.$rowspan.'">';
|
||||
print '<a href="#" id="copyaddressfromsoc">'.$langs->trans('CopyAddressFromSoc').'</a>';
|
||||
print '</td>';
|
||||
@ -460,7 +460,7 @@ else
|
||||
print '</td></tr>';
|
||||
|
||||
// Country
|
||||
if (dol_strlen(trim($object->fk_pays)) == 0) $object->fk_pays = $objsoc->country_id; // Predefined with third party
|
||||
if (dol_strlen(trim($object->country_id)) == 0) $object->country_id = $objsoc->country_id; // Predefined with third party
|
||||
print '<tr><td>'.$langs->trans("Country").'</td><td colspan="'.$colspan.'">';
|
||||
print $form->select_country((isset($_POST["country_id"])?$_POST["country_id"]:$object->country_id),'country_id');
|
||||
if ($user->admin) print info_admin($langs->trans("YouCanChangeValuesForThisListFromDictionnarySetup"),1);
|
||||
|
||||
Loading…
Reference in New Issue
Block a user