Fix: possibility to use alternative addresses management
This commit is contained in:
parent
1194de5089
commit
0c8686b5b4
@ -786,11 +786,6 @@ if ($id > 0)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*if ($user->rights->societe->contact->creer)
|
|
||||||
{
|
|
||||||
print '<a class="butAction" href="'.DOL_URL_ROOT.'/contact/fiche.php?socid='.$object->id.'&action=create">'.$langs->trans("AddContact").'</a>';
|
|
||||||
}*/
|
|
||||||
|
|
||||||
print '</div>';
|
print '</div>';
|
||||||
print "<br>\n";
|
print "<br>\n";
|
||||||
|
|
||||||
|
|||||||
@ -312,8 +312,6 @@ if ($socid > 0)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//print '<a class="butAction" href="'.DOL_URL_ROOT.'/contact/fiche.php?socid='.$societe->id.'&action=create">'.$langs->trans("AddContact").'</a>';
|
|
||||||
|
|
||||||
print '</div>';
|
print '</div>';
|
||||||
|
|
||||||
print '<br>';
|
print '<br>';
|
||||||
|
|||||||
@ -349,8 +349,9 @@ else
|
|||||||
$object->country_code = $tmparray['code'];
|
$object->country_code = $tmparray['code'];
|
||||||
$object->country = $tmparray['label'];
|
$object->country = $tmparray['label'];
|
||||||
}
|
}
|
||||||
|
|
||||||
print_fiche_titre($langs->trans("AddContact"));
|
$title = $addcontact = (! empty($conf->global->SOCIETE_ADDRESSES_MANAGEMENT) ? $langs->trans("AddContact") : $langs->trans("AddContactAddress"));
|
||||||
|
print_fiche_titre($title);
|
||||||
|
|
||||||
// Affiche les erreurs
|
// Affiche les erreurs
|
||||||
dol_htmloutput_errors($error,$errors);
|
dol_htmloutput_errors($error,$errors);
|
||||||
|
|||||||
@ -2644,8 +2644,9 @@ class Form
|
|||||||
$num=$this->select_contacts($societe->id, $selected, $htmlname);
|
$num=$this->select_contacts($societe->id, $selected, $htmlname);
|
||||||
if ($num==0)
|
if ($num==0)
|
||||||
{
|
{
|
||||||
|
$addcontact = (! empty($conf->global->SOCIETE_ADDRESSES_MANAGEMENT) ? $langs->trans("AddContact") : $langs->trans("AddContactAddress"));
|
||||||
print '<font class="error">Cette societe n\'a pas de contact, veuillez en cr<63>er un avant de faire votre proposition commerciale</font><br>';
|
print '<font class="error">Cette societe n\'a pas de contact, veuillez en cr<63>er un avant de faire votre proposition commerciale</font><br>';
|
||||||
print '<a href="'.DOL_URL_ROOT.'/contact/fiche.php?socid='.$societe->id.'&action=create&backtoreferer=1">'.$langs->trans('AddContact').'</a>';
|
print '<a href="'.DOL_URL_ROOT.'/contact/fiche.php?socid='.$societe->id.'&action=create&backtoreferer=1">'.$addcontact.'</a>';
|
||||||
}
|
}
|
||||||
print '</td>';
|
print '</td>';
|
||||||
print '<td align="left"><input type="submit" class="button" value="'.$langs->trans("Modify").'"></td>';
|
print '<td align="left"><input type="submit" class="button" value="'.$langs->trans("Modify").'"></td>';
|
||||||
|
|||||||
@ -502,12 +502,14 @@ function show_contacts($conf,$langs,$db,$object,$backtopage='')
|
|||||||
$buttoncreate='';
|
$buttoncreate='';
|
||||||
if ($user->rights->societe->contact->creer)
|
if ($user->rights->societe->contact->creer)
|
||||||
{
|
{
|
||||||
//$buttoncreate='<a class="butAction" href="'.DOL_URL_ROOT.'/contact/fiche.php?socid='.$object->id.'&action=create&backtopage='.urlencode($backtopage).'">'.$langs->trans("AddContact").'</a>'."\n";
|
$addcontact = (! empty($conf->global->SOCIETE_ADDRESSES_MANAGEMENT) ? $langs->trans("AddContact") : $langs->trans("AddContactAddress"));
|
||||||
$buttoncreate='<a class="addnewrecord" href="'.DOL_URL_ROOT.'/contact/fiche.php?socid='.$object->id.'&action=create&backtopage='.urlencode($backtopage).'">'.$langs->trans("AddContact").' '.img_picto($langs->trans("AddContact"),'filenew').'</a>'."\n";
|
$buttoncreate='<a class="addnewrecord" href="'.DOL_URL_ROOT.'/contact/fiche.php?socid='.$object->id.'&action=create&backtopage='.urlencode($backtopage).'">'.$addcontact.' '.img_picto($addcontact,'filenew').'</a>'."\n";
|
||||||
}
|
}
|
||||||
|
|
||||||
print "\n";
|
print "\n";
|
||||||
print_fiche_titre($langs->trans("ContactsForCompany"),$buttoncreate,'');
|
|
||||||
|
$title = (! empty($conf->global->SOCIETE_ADDRESSES_MANAGEMENT) ? $langs->trans("ContactsForCompany") : $langs->trans("ContactsAddressesForCompany"));
|
||||||
|
print_fiche_titre($title,$buttoncreate,'');
|
||||||
|
|
||||||
print "\n".'<table class="noborder" width="100%">'."\n";
|
print "\n".'<table class="noborder" width="100%">'."\n";
|
||||||
|
|
||||||
|
|||||||
@ -394,11 +394,6 @@ if ($object->fetch($id))
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*if ($user->rights->societe->contact->creer)
|
|
||||||
{
|
|
||||||
print "<a class=\"butAction\" href=\"".DOL_URL_ROOT.'/contact/fiche.php?socid='.$socid."&action=create\">".$langs->trans("AddContact")."</a>";
|
|
||||||
}*/
|
|
||||||
|
|
||||||
print '</div>';
|
print '</div>';
|
||||||
print '<br>';
|
print '<br>';
|
||||||
|
|
||||||
|
|||||||
@ -225,8 +225,10 @@ AvailableGlobalDiscounts=Absolute discounts available
|
|||||||
DiscountNone=None
|
DiscountNone=None
|
||||||
Supplier=Supplier
|
Supplier=Supplier
|
||||||
CompanyList=Company's list
|
CompanyList=Company's list
|
||||||
AddContact=Add contact/address
|
AddContact=Add contact
|
||||||
EditContact=Edit contact/address
|
AddContactAddress=Add contact/address
|
||||||
|
EditContact=Edit contact
|
||||||
|
EditContactAddress=Edit contact/address
|
||||||
Contact=Contact
|
Contact=Contact
|
||||||
ContactsAddresses=Contacts/Addresses
|
ContactsAddresses=Contacts/Addresses
|
||||||
NoContactDefined=No contact defined for this third party
|
NoContactDefined=No contact defined for this third party
|
||||||
|
|||||||
@ -328,7 +328,8 @@ ActionRunningNotStarted=To start
|
|||||||
ActionRunningShort=Started
|
ActionRunningShort=Started
|
||||||
ActionDoneShort=Finished
|
ActionDoneShort=Finished
|
||||||
CompanyFoundation=Company/Foundation
|
CompanyFoundation=Company/Foundation
|
||||||
ContactsForCompany=Contacts/adresses for this third party
|
ContactsForCompany=Contacts for this third party
|
||||||
|
ContactsAddressesForCompany=Contacts/adresses for this third party
|
||||||
ActionsOnCompany=Events about this third party
|
ActionsOnCompany=Events about this third party
|
||||||
ActionsOnMember=Events about this member
|
ActionsOnMember=Events about this member
|
||||||
NActions=%s events
|
NActions=%s events
|
||||||
|
|||||||
@ -227,8 +227,10 @@ AvailableGlobalDiscounts=Remises fixes disponibles
|
|||||||
DiscountNone=Aucune
|
DiscountNone=Aucune
|
||||||
Supplier=Fournisseur
|
Supplier=Fournisseur
|
||||||
CompanyList=Liste des sociétés
|
CompanyList=Liste des sociétés
|
||||||
AddContact=Créer contact/adresse
|
AddContact=Créer contact
|
||||||
EditContact=Editer contact/adresse
|
AddContactAddress=Créer contact/adresse
|
||||||
|
EditContact=Editer contact
|
||||||
|
EditContactAddress=Editer contact/adresse
|
||||||
Contact=Contact
|
Contact=Contact
|
||||||
NoContactDefined=Aucun contact défini pour ce tiers
|
NoContactDefined=Aucun contact défini pour ce tiers
|
||||||
DefaultContact=Contact par défaut
|
DefaultContact=Contact par défaut
|
||||||
|
|||||||
@ -329,7 +329,8 @@ ActionRunningNotStarted=A réaliser
|
|||||||
ActionRunningShort=En cours
|
ActionRunningShort=En cours
|
||||||
ActionDoneShort=Terminé
|
ActionDoneShort=Terminé
|
||||||
CompanyFoundation=Société ou institution
|
CompanyFoundation=Société ou institution
|
||||||
ContactsForCompany=Contacts/adresses de ce tiers
|
ContactsForCompany=Contacts de ce tiers
|
||||||
|
ContactsAddressesForCompany=Contacts/adresses de ce tiers
|
||||||
ActionsOnCompany=Événements vis à vis de ce tiers
|
ActionsOnCompany=Événements vis à vis de ce tiers
|
||||||
ActionsOnMember=Événements vis à vis de cet adhérent
|
ActionsOnMember=Événements vis à vis de cet adhérent
|
||||||
NActions=%s événements
|
NActions=%s événements
|
||||||
|
|||||||
@ -241,10 +241,6 @@ for ($i=1; $i<=4; $i++) {
|
|||||||
<a class="butAction" href="<?php echo $_SERVER["PHP_SELF"].'?socid='.$this->control->tpl['id'].'&action=edit&canvas='.$canvas; ?>"><?php echo $langs->trans("Modify"); ?></a>
|
<a class="butAction" href="<?php echo $_SERVER["PHP_SELF"].'?socid='.$this->control->tpl['id'].'&action=edit&canvas='.$canvas; ?>"><?php echo $langs->trans("Modify"); ?></a>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
|
|
||||||
<?php if ($user->rights->societe->contact->creer) { ?>
|
|
||||||
<a class="butAction" href="<?php echo DOL_URL_ROOT.'/contact/fiche.php?socid='.$this->control->tpl['id'].'&action=create&canvas=default'; ?>"><?php echo $langs->trans("AddContact"); ?></a>
|
|
||||||
<?php } ?>
|
|
||||||
|
|
||||||
<?php if ($user->rights->societe->supprimer) { ?>
|
<?php if ($user->rights->societe->supprimer) { ?>
|
||||||
<?php if ($conf->use_javascript_ajax) { ?>
|
<?php if ($conf->use_javascript_ajax) { ?>
|
||||||
<span id="action-delete" class="butActionDelete"><?php echo $langs->trans('Delete'); ?></span>
|
<span id="action-delete" class="butActionDelete"><?php echo $langs->trans('Delete'); ?></span>
|
||||||
|
|||||||
@ -182,10 +182,6 @@ dol_fiche_head($head, 'card', $langs->trans("ThirdParty"),0,'company');
|
|||||||
<a class="butAction" href="<?php echo $_SERVER["PHP_SELF"].'?socid='.$this->control->tpl['id'].'&action=edit&canvas='.$canvas; ?>"><?php echo $langs->trans("Modify"); ?></a>
|
<a class="butAction" href="<?php echo $_SERVER["PHP_SELF"].'?socid='.$this->control->tpl['id'].'&action=edit&canvas='.$canvas; ?>"><?php echo $langs->trans("Modify"); ?></a>
|
||||||
<?php } ?>
|
<?php } ?>
|
||||||
|
|
||||||
<?php if ($user->rights->societe->contact->creer) { ?>
|
|
||||||
<a class="butAction" href="<?php echo DOL_URL_ROOT.'/contact/fiche.php?socid='.$this->control->tpl['id'].'&action=create&canvas=default'; ?>"><?php echo $langs->trans("AddContact"); ?></a>
|
|
||||||
<?php } ?>
|
|
||||||
|
|
||||||
<?php if ($user->rights->societe->supprimer) { ?>
|
<?php if ($user->rights->societe->supprimer) { ?>
|
||||||
<?php if ($conf->use_javascript_ajax) { ?>
|
<?php if ($conf->use_javascript_ajax) { ?>
|
||||||
<span id="action-delete" class="butActionDelete"><?php echo $langs->trans('Delete'); ?></span>
|
<span id="action-delete" class="butActionDelete"><?php echo $langs->trans('Delete'); ?></span>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user