29require
'../main.inc.php';
30require_once DOL_DOCUMENT_ROOT.
'/core/lib/contact.lib.php';
31require_once DOL_DOCUMENT_ROOT.
'/contact/class/contact.class.php';
33$action =
GETPOST(
'action',
'aZ09');
36$langs->load(
"companies");
46if ($user->socid > 0) {
47 if ($object->fk_soc > 0 && $object->fk_soc != $user->socid) {
51$result =
restrictedArea($user,
'contact', $id,
'socpeople&societe');
54$permissionnote = $user->hasRight(
'societe',
'creer');
58$hookmanager->initHooks(array(
'contactnote'));
66$reshook = $hookmanager->executeHooks(
'doActions', $parameters, $object, $action);
71 include DOL_DOCUMENT_ROOT.
'/core/actions_setnotes.inc.php';
81$title = (
getDolGlobalString(
'SOCIETE_ADDRESSES_MANAGEMENT') ? $langs->trans(
"Contacts") : $langs->trans(
"ContactsAddresses"));
85$help_url =
'EN:Module_Third_Parties|FR:Module_Tiers|ES:Empresas';
92 if (isModEnabled(
'notification')) {
93 $langs->load(
"mails");
100 $linkback =
'<a href="'.DOL_URL_ROOT.
'/contact/list.php?restore_lastsearch_values=1">'.$langs->trans(
"BackToList").
'</a>';
102 $morehtmlref =
'<a href="'.DOL_URL_ROOT.
'/contact/vcard.php?id='.$object->id.
'" class="refid">';
103 $morehtmlref .=
img_picto($langs->trans(
"Download").
' '.$langs->trans(
"VCard"),
'vcard.png',
'class="valignmiddle marginleftonly paddingrightonly"');
104 $morehtmlref .=
'</a>';
106 $morehtmlref .=
'<div class="refidno">';
109 $objsoc->fetch($object->socid);
111 if ($objsoc->id > 0) {
112 $morehtmlref .= $objsoc->getNomUrl(1);
114 $morehtmlref .=
'<span class="opacitymedium">'.$langs->trans(
"ContactNotLinkedToCompany").
'</span>';
117 $morehtmlref .=
'</div>';
119 dol_banner_tab($object,
'id', $linkback, 1,
'rowid',
'ref', $morehtmlref);
121 $cssclass =
'titlefield';
125 print
'<div class="fichecenter">';
126 print
'<div class="underbanner clearboth"></div>';
128 print
'<table class="border centpercent tableforfield">';
131 print
'<tr><td class="'.$cssclass.
'">'.$langs->trans(
"UserTitle").
'</td><td>';
132 print $object->getCivilityLabel();
138 $cssclass =
"titlefield";
139 include DOL_DOCUMENT_ROOT.
'/core/tpl/notes.tpl.php';
if(!defined('NOREQUIRESOC')) if(!defined( 'NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined( 'NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined( 'NOREQUIREAJAX')) llxHeader()
Empty header.
Class to manage third parties objects (customers, suppliers, prospects...)
dol_banner_tab($object, $paramid, $morehtml='', $shownav=1, $fieldid='rowid', $fieldref='ref', $morehtmlref='', $moreparam='', $nodbprefix=0, $morehtmlleft='', $morehtmlstatus='', $onlybanner=0, $morehtmlright='')
Show tab footer of a card.
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='', $dragdropfile=0)
Show tabs of a record.
dol_get_fiche_end($notab=0)
Return tab footer of a card.
dol_now($mode='auto')
Return date for now.
img_picto($titlealt, $picto, $moreatt='', $pictoisfullpath=false, $srconly=0, $notitle=0, $alt='', $morecss='', $marginleftonlyshort=2)
Show picto whatever it's its name (generic function)
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='', $noduplicate=0)
Set event messages in dol_events session object.
getDolGlobalString($key, $default='')
Return dolibarr global constant string value.
restrictedArea(User $user, $features, $object=0, $tableandshare='', $feature2='', $dbt_keyfield='fk_soc', $dbt_select='rowid', $isdraft=0, $mode=0)
Check permissions of a user to show a page and an object.
accessforbidden($message='', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Show a message to say access is forbidden and stop program.