27require
'../main.inc.php';
28require_once DOL_DOCUMENT_ROOT.
'/core/lib/functions2.lib.php';
29require_once DOL_DOCUMENT_ROOT.
'/core/lib/usergroups.lib.php';
30require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formadmin.class.php';
33$langs->loadLangs(array(
'companies',
'products',
'admin',
'users',
'languages',
'projects',
'members'));
36$canreaduser = ($user->admin || $user->hasRight(
"user",
"user",
"read"));
39$action =
GETPOST(
'action',
'aZ09');
40$contextpage =
GETPOST(
'contextpage',
'aZ') ?
GETPOST(
'contextpage',
'aZ') :
'userihm';
42if (!isset($id) || empty($id)) {
48 $caneditfield = ((($user->id == $id) && $user->hasRight(
"user",
"self",
"write"))
49 || (($user->id != $id) && $user->hasRight(
"user",
"user",
"write")));
54if ($user->socid > 0) {
55 $socid = $user->socid;
57$feature2 = (($socid && $user->hasRight(
"user",
"self",
"write")) ?
'' :
'user');
59$result =
restrictedArea($user,
'user', $id,
'user&user', $feature2);
60if ($user->id <> $id && !$canreaduser) {
64$dirtop =
"../core/menus/standard";
65$dirleft =
"../core/menus/standard";
68$object =
new User($db);
69$object->fetch($id,
'',
'', 1);
83$hookmanager->initHooks(array(
'usercard',
'userihm',
'globalcard'));
90$parameters = array(
'id'=>$socid);
91$reshook = $hookmanager->executeHooks(
'doActions', $parameters, $object, $action);
97 if ($action ==
'update' && ($caneditfield || !empty($user->admin))) {
101 if (
GETPOST(
"check_MAIN_LANDING_PAGE") ==
"on") {
102 $tabparam[
"MAIN_LANDING_PAGE"] =
GETPOST(
"MAIN_LANDING_PAGE",
'alphanohtml');
104 $tabparam[
"MAIN_LANDING_PAGE"] =
'';
107 if (
GETPOST(
"check_MAIN_LANG_DEFAULT") ==
"on") {
108 $tabparam[
"MAIN_LANG_DEFAULT"] =
GETPOST(
"main_lang_default",
'aZ09');
110 $tabparam[
"MAIN_LANG_DEFAULT"] =
'';
113 if (
GETPOST(
"check_SIZE_LISTE_LIMIT") ==
"on") {
114 $tabparam[
"MAIN_SIZE_LISTE_LIMIT"] =
GETPOST(
"main_size_liste_limit",
'int');
116 $tabparam[
"MAIN_SIZE_LISTE_LIMIT"] =
'';
119 if (
GETPOST(
"check_AGENDA_DEFAULT_VIEW") ==
"on") {
120 $tabparam[
"AGENDA_DEFAULT_VIEW"] =
GETPOST(
"AGENDA_DEFAULT_VIEW",
'aZ09');
122 $tabparam[
"AGENDA_DEFAULT_VIEW"] =
'';
125 if (
GETPOST(
"check_MAIN_THEME") ==
"on") {
126 $tabparam[
"MAIN_THEME"] =
GETPOST(
'main_theme',
'aZ09');
128 $tabparam[
"MAIN_THEME"] =
'';
133 $tabparam[
'THEME_ELDY_TOPMENU_BACK1'] =
'';
135 $tabparam[
'THEME_ELDY_TOPMENU_BACK1'] = join(
143 $tabparam[
'THEME_ELDY_BACKTITLE1'] =
'';
145 $tabparam[
'THEME_ELDY_BACKTITLE1'] = join(
151 if (
GETPOST(
'check_THEME_ELDY_USE_HOVER') ==
'on') {
152 $tabparam[
"THEME_ELDY_USE_HOVER"] = 1;
154 $tabparam[
"THEME_ELDY_USE_HOVER"] = 0;
157 if (
GETPOST(
'check_THEME_ELDY_USE_CHECKED') ==
'on') {
158 $tabparam[
"THEME_ELDY_USE_CHECKED"] = 1;
160 $tabparam[
"THEME_ELDY_USE_CHECKED"] = 0;
163 if (
GETPOST(
'MAIN_OPTIMIZEFORTEXTBROWSER')) {
164 $tabparam[
"MAIN_OPTIMIZEFORTEXTBROWSER"] = 1;
166 $tabparam[
"MAIN_OPTIMIZEFORTEXTBROWSER"] = 0;
169 if (
GETPOST(
'MAIN_OPTIMIZEFORCOLORBLIND')) {
170 $tabparam[
"MAIN_OPTIMIZEFORCOLORBLIND"] =
GETPOST(
'MAIN_OPTIMIZEFORCOLORBLIND',
'aZ09');
172 $tabparam[
"MAIN_OPTIMIZEFORCOLORBLIND"] = 0;
177 header(
'Location: '.$_SERVER[
"PHP_SELF"].
'?id='.$id);
188$person_name = !empty($object->firstname) ? $object->lastname.
", ".$object->firstname : $object->lastname;
189$title = $person_name.
" - ".$langs->trans(
'Card');
196$tmparray[
'index.php'] = array(
'label'=>
'Dashboard',
'picto'=>
'graph');
197if (isModEnabled(
"societe")) {
198 $tmparray[
'societe/index.php?mainmenu=companies&leftmenu='] = array(
'label'=>
'ThirdPartiesArea',
'picto'=>
'company');
200if (isModEnabled(
'project')) {
201 $tmparray[
'projet/index.php?mainmenu=project&leftmenu='] = array(
'label'=>
'ProjectsArea',
'picto'=>
'project');
203 $tmparray[
'projet/list.php?mainmenu=project&leftmenu=&search_usage_opportunity=1&search_status=99&search_opp_status=openedopp&contextpage=lead'] = array(
'label'=>
'ListOpenLeads',
'picto'=>
'project');
206if (isModEnabled(
'holiday') || isModEnabled(
'expensereport')) {
207 $tmparray[
'hrm/index.php?mainmenu=hrm&leftmenu='] = array(
'label'=>
'HRMArea',
'picto'=>
'user');
209if (isModEnabled(
"product") || isModEnabled(
"service")) {
210 $tmparray[
'product/index.php?mainmenu=products&leftmenu='] = array(
'label'=>
'ProductsAndServicesArea',
'picto'=>
'product');
212if (isModEnabled(
"propal") || isModEnabled(
'commande') || isModEnabled(
'ficheinter') || isModEnabled(
'contrat')) {
213 $tmparray[
'comm/index.php?mainmenu=commercial&leftmenu='] = array(
'label'=>
'CommercialArea',
'picto'=>
'commercial');
215if (isModEnabled(
'facture')) {
216 $tmparray[
'compta/index.php?mainmenu=billing&leftmenu='] = array(
'label'=>
'InvoicesArea',
'picto'=>
'bill');
218if (isModEnabled(
'comptabilite') || isModEnabled(
'accounting')) {
219 $tmparray[
'compta/index.php?mainmenu=accountancy&leftmenu='] = array(
'label'=>
'AccountancyTreasuryArea',
'picto'=>
'bill');
221if (isModEnabled(
'adherent')) {
222 $tmparray[
'adherents/index.php?mainmenu=members&leftmenu='] = array(
'label'=>
'MembersArea',
'picto'=>
'member');
224if (isModEnabled(
'agenda')) {
225 $tmparray[
'comm/action/index.php?mainmenu=agenda&leftmenu='] = array(
'label'=>
'Agenda',
'picto'=>
'action');
227if (isModEnabled(
'ticket')) {
228 $tmparray[
'ticket/list.php?mainmenu=ticket&leftmenu='] = array(
'label'=>
'Tickets',
'picto'=>
'ticket');
232 $sql =
"SELECT b.rowid, b.fk_user, b.url, b.title";
233 $sql .=
" FROM ".MAIN_DB_PREFIX.
"bookmark as b";
234 $sql .=
" WHERE b.entity IN (".getEntity(
'bookmark').
")";
235 $sql .=
" AND b.url NOT LIKE 'http%'";
236 if (!$object->admin) {
237 $sql .=
" AND (b.fk_user = ".((int) $object->id).
" OR b.fk_user is NULL OR b.fk_user = 0)";
239 $resql = $db->query($sql);
242 $num_rows = $db->num_rows($resql);
244 $tmparray[
'sep'.$i] = array(
'data-html'=>
'<span class="opacitymedium">--- '.$langs->trans(
"Bookmarks").
'</span>',
'label'=>
'--- '.$langs->trans(
"Bookmarks"));
245 while ($i < $num_rows) {
246 $obj = $db->fetch_object($resql);
248 $landing_url = str_replace(DOL_URL_ROOT,
'', $obj->url);
249 $tmparray[$landing_url] = array(
'label'=>$obj->title,
'picto'=>
'generic');
257$reshook = $hookmanager->executeHooks(
'addToLandingPageList', $tmparray, $object);
260} elseif ($reshook > 0) {
261 $tmparray = $hookmanager->resArray;
262} elseif ($reshook == 0) {
263 $tmparray = array_merge($tmparray, $hookmanager->resArray);
266foreach ($tmparray as $key => $val) {
267 $tmparray[$key][
'data-html'] =
img_picto($langs->trans($val[
'label']), $val[
'picto'],
'class="pictofixedwidth"').$langs->trans($val[
'label']);
268 $tmparray[$key][
'label'] = $langs->trans($val[
'label']);
273$title = $langs->trans(
"User");
275if ($action ==
'edit') {
276 print
'<form method="post" action="'.$_SERVER[
"PHP_SELF"].
'">';
277 print
'<input type="hidden" name="token" value="'.newToken().
'">';
278 print
'<input type="hidden" name="action" value="update">';
279 print
'<input type="hidden" name="id" value="'.$id.
'">';
283if ($action ==
'edit') {
288 if ($user->hasRight(
"user",
"user",
"read") || $user->admin) {
289 $linkback =
'<a href="'.DOL_URL_ROOT.
'/user/list.php?restore_lastsearch_values=1">'.$langs->trans(
"BackToList").
'</a>';
292 dol_banner_tab($object,
'id', $linkback, $user->hasRight(
"user",
"user",
"read") || $user->admin);
294 print
'<div class="underbanner clearboth"></div>';
299 if (!empty($conf->use_javascript_ajax)) {
300 print
'<script type="text/javascript">
301 jQuery(document).ready(function() {
302 function init_myfunc()
304 if (jQuery("#check_MAIN_LANDING_PAGE").prop("checked")) { jQuery("#MAIN_LANDING_PAGE").removeAttr(\'disabled\'); }
305 else { jQuery("#MAIN_LANDING_PAGE").attr(\'disabled\',\'disabled\'); }
307 if (jQuery("#check_MAIN_LANG_DEFAULT").prop("checked")) { jQuery("#main_lang_default").removeAttr(\'disabled\'); }
308 else { jQuery("#main_lang_default").attr(\'disabled\',\'disabled\'); }
310 if (jQuery("#check_SIZE_LISTE_LIMIT").prop("checked")) { jQuery("#main_size_liste_limit").removeAttr(\'disabled\'); }
311 else { jQuery("#main_size_liste_limit").attr(\'disabled\',\'disabled\'); }
313 if (jQuery("#check_AGENDA_DEFAULT_VIEW").prop("checked")) { jQuery("#AGENDA_DEFAULT_VIEW").removeAttr(\'disabled\'); }
314 else { jQuery("#AGENDA_DEFAULT_VIEW").attr(\'disabled\',\'disabled\'); }
316 if (jQuery("#check_MAIN_THEME").prop("checked")) { jQuery(".themethumbs").removeAttr(\'disabled\'); }
317 else { jQuery(".themethumbs").attr(\'disabled\',\'disabled\'); }
319 if (jQuery("#check_THEME_ELDY_TOPMENU_BACK1").prop("checked")) { jQuery("#colorpickerTHEME_ELDY_TOPMENU_BACK1").removeAttr(\'disabled\'); }
320 else { jQuery("#colorpickerTHEME_ELDY_TOPMENU_BACK1").attr(\'disabled\',\'disabled\'); }
323 jQuery("#check_MAIN_LANDING_PAGE").click(function() { init_myfunc(); });
324 jQuery("#check_MAIN_LANG_DEFAULT").click(function() { init_myfunc(); });
325 jQuery("#check_SIZE_LISTE_LIMIT").click(function() { init_myfunc(); });
326 jQuery("#check_AGENDA_DEFAULT_VIEW").click(function() { init_myfunc(); });
327 jQuery("#check_MAIN_THEME").click(function() { init_myfunc(); });
328 jQuery("#check_THEME_ELDY_TOPMENU_BACK1").click(function() { init_myfunc(); });
329 jQuery("#check_THEME_ELDY_BACKTITLE1").click(function() { init_myfunc(); });
337 print
'<table class="noborder centpercent">';
338 print
'<tr class="liste_titre"><td>'.$langs->trans(
"Parameter").
'</td><td>'.$langs->trans(
"DefaultValue").
'</td><td> </td><td>'.$langs->trans(
"PersonalValue").
'</td></tr>';
341 print
'<tr class="oddeven"><td class="titlefieldmiddle">'.$langs->trans(
"Language").
'</td>';
344 print $s ? $s.
' ' :
'';
345 print ($conf->global->MAIN_LANG_DEFAULT ==
'auto' ? $langs->trans(
"AutoDetectLang") : $langs->trans(
"Language_".$conf->global->MAIN_LANG_DEFAULT));
347 print
'<td class="nowrap" width="20%"><input class="oddeven" name="check_MAIN_LANG_DEFAULT" id="check_MAIN_LANG_DEFAULT" type="checkbox" '.(!empty($object->conf->MAIN_LANG_DEFAULT) ?
" checked" :
"");
348 print empty($dolibarr_main_demo) ?
'' :
' disabled="disabled"';
349 print
'> <label for="check_MAIN_LANG_DEFAULT">'.$langs->trans(
"UsePersonalValue").
'</label></td>';
351 print $formadmin->select_language((!empty($object->conf->MAIN_LANG_DEFAULT) ? $object->conf->MAIN_LANG_DEFAULT :
''),
'main_lang_default', 1, null, 0, 0, (!empty($dolibarr_main_demo)));
355 print
'<tr class="oddeven"><td>'.$langs->trans(
"LandingPage").
'</td>';
357 print (empty($conf->global->MAIN_LANDING_PAGE) ?
'' : $conf->global->MAIN_LANDING_PAGE);
359 print
'<td class="nowrap" width="20%"><input class="oddeven" name="check_MAIN_LANDING_PAGE" id="check_MAIN_LANDING_PAGE" type="checkbox" '.(!empty($object->conf->MAIN_LANDING_PAGE) ?
" checked" :
"");
360 print empty($dolibarr_main_demo) ?
'' :
' disabled="disabled"';
361 print
'> <label for="check_MAIN_LANDING_PAGE">'.$langs->trans(
"UsePersonalValue").
'</label></td>';
363 print $form->selectarray(
'MAIN_LANDING_PAGE', $tmparray, (!empty($object->conf->MAIN_LANDING_PAGE) ? $object->conf->MAIN_LANDING_PAGE :
''), 0, 0, 0,
'', 0, 0, 0,
'',
'maxwidth250');
368 print
'<tr class="oddeven">'.
"\n";
369 print
'<td>'.$langs->trans(
"AGENDA_DEFAULT_VIEW").
'</td>'.
"\n";
370 print
'<td class="center"> </td>'.
"\n";
371 print
'<td class="nowrap" width="20%"><input class="oddeven" name="check_AGENDA_DEFAULT_VIEW" id="check_AGENDA_DEFAULT_VIEW" type="checkbox" '.(!empty($object->conf->AGENDA_DEFAULT_VIEW) ?
" checked" :
"");
372 print empty($dolibarr_main_demo) ?
'' :
' disabled="disabled"';
373 print
'> <label for="check_AGENDA_DEFAULT_VIEW">'.$langs->trans(
"UsePersonalValue").
'</label></td>';
375 $tmplist = array(
''=>
' ',
'show_list'=>$langs->trans(
"ViewList"),
'show_month'=>$langs->trans(
"ViewCal"),
'show_week'=>$langs->trans(
"ViewWeek"),
'show_day'=>$langs->trans(
"ViewDay"),
'show_peruser'=>$langs->trans(
"ViewPerUser"));
376 print $form->selectarray(
'AGENDA_DEFAULT_VIEW', $tmplist, (isset($object->conf->AGENDA_DEFAULT_VIEW) ? $object->conf->AGENDA_DEFAULT_VIEW :
''), 0, 0, 0,
'');
377 print
'</td></tr>'.
"\n";
380 print
'<tr class="oddeven"><td>'.$langs->trans(
"MaxSizeList").
'</td>';
381 print
'<td>'.$conf->global->MAIN_SIZE_LISTE_LIMIT.
'</td>';
382 print
'<td class="nowrap" width="20%"><input class="oddeven" name="check_SIZE_LISTE_LIMIT" id="check_SIZE_LISTE_LIMIT" type="checkbox" '.(!empty($object->conf->MAIN_SIZE_LISTE_LIMIT) ?
" checked" :
"");
383 print empty($dolibarr_main_demo) ?
'' :
' disabled="disabled"';
384 print
'> <label for="check_SIZE_LISTE_LIMIT">'.$langs->trans(
"UsePersonalValue").
'</label></td>';
385 print
'<td><input class="flat" name="main_size_liste_limit" id="main_size_liste_limit" size="4" value="'.(!empty($object->conf->MAIN_SIZE_LISTE_LIMIT) ? $object->conf->MAIN_SIZE_LISTE_LIMIT :
'').
'"></td></tr>';
387 print
'</table><br>';
390 showSkins($object, (($user->admin || empty($dolibarr_main_demo)) ? 1 : 0), true);
393 print $form->buttonsSaveCancel();
397 $linkback =
'<a href="'.DOL_URL_ROOT.
'/user/list.php?restore_lastsearch_values=1">'.$langs->trans(
"BackToList").
'</a>';
399 $morehtmlref =
'<a href="'.DOL_URL_ROOT.
'/user/vcard.php?id='.$object->id.
'&output=file&file='.urlencode(
dol_sanitizeFileName($object->getFullName($langs).
'.vcf')).
'" class="refid" rel="noopener">';
400 $morehtmlref .=
img_picto($langs->trans(
"Download").
' '.$langs->trans(
"VCard"),
'vcard.png',
'class="valignmiddle marginleftonly paddingrightonly"');
401 $morehtmlref .=
'</a>';
403 $urltovirtualcard =
'/user/virtualcard.php?id='.((int) $object->id);
404 $morehtmlref .=
dolButtonToOpenUrlInDialogPopup(
'publicvirtualcard', $langs->trans(
"PublicVirtualCardUrl").
' - '.$object->getFullName($langs),
img_picto($langs->trans(
"PublicVirtualCardUrl"),
'card',
'class="valignmiddle marginleftonly paddingrightonly"'), $urltovirtualcard,
'',
'nohover');
406 dol_banner_tab($object,
'id', $linkback, $user->hasRight(
"user",
"user",
"read") || $user->admin,
'rowid',
'ref', $morehtmlref);
408 print
'<div class="fichecenter">';
410 print
'<div class="underbanner clearboth"></div>';
411 print
'<table class="border centpercent tableforfield">';
414 print
'<tr><td class="titlefield">'.$langs->trans(
"Login").
'</td>';
415 if (!empty($object->ldap_sid) && $object->statut == 0) {
416 print
'<td class="error">';
417 print $langs->trans(
"LoginAccountDisableInDolibarr");
422 if (property_exists($object,
'admin')) {
423 if (isModEnabled(
'multicompany') && !empty($object->admin) && empty($object->entity)) {
424 $addadmin .=
img_picto($langs->trans(
"SuperAdministratorDesc"),
"redstar",
'class="paddingleft"');
425 } elseif (!empty($object->admin)) {
426 $addadmin .=
img_picto($langs->trans(
"AdministratorDesc"),
"star",
'class="paddingleft"');
441 print
'<div class="div-table-responsive">';
442 print
'<table class="noborder centpercent">';
443 print
'<tr class="liste_titre"><td class="titlefieldmiddle">'.$langs->trans(
"Parameter").
'</td><td>'.$langs->trans(
"DefaultValue").
'</td><td> </td><td>'.$langs->trans(
"PersonalValue").
'</td></tr>';
446 print
'<tr class="oddeven"><td>'.$langs->trans(
"Language").
'</td>';
449 print ($s ? $s.
' ' :
'');
450 print (isset($conf->global->MAIN_LANG_DEFAULT) && $conf->global->MAIN_LANG_DEFAULT ==
'auto' ? $langs->trans(
"AutoDetectLang") : $langs->trans(
"Language_".$conf->global->MAIN_LANG_DEFAULT));
452 print
'<td class="nowrap"><input class="oddeven" type="checkbox" disabled '.(!empty($object->conf->MAIN_LANG_DEFAULT) ?
" checked" :
"").
'> '.$langs->trans(
"UsePersonalValue").
'</td>';
454 $s = (isset($object->conf->MAIN_LANG_DEFAULT) ?
picto_from_langcode($object->conf->MAIN_LANG_DEFAULT) :
'');
455 print ($s ? $s.
' ' :
'');
456 print (isset($object->conf->MAIN_LANG_DEFAULT) && $object->conf->MAIN_LANG_DEFAULT ==
'auto' ? $langs->trans(
"AutoDetectLang") : (!empty($object->
conf->MAIN_LANG_DEFAULT) ? $langs->trans(
"Language_".$object->
conf->MAIN_LANG_DEFAULT) :
''));
460 print
'<tr class="oddeven"><td>'.$langs->trans(
"LandingPage").
'</td>';
462 print (empty($conf->global->MAIN_LANDING_PAGE) ?
'' : $conf->global->MAIN_LANDING_PAGE);
464 print
'<td class="nowrap"><input class="oddeven" name="check_MAIN_LANDING_PAGE" disabled id="check_MAIN_LANDING_PAGE" type="checkbox" '.(!empty($object->conf->MAIN_LANDING_PAGE) ?
" checked" :
"");
465 print empty($dolibarr_main_demo) ?
'' :
' disabled="disabled"';
466 print
'> '.$langs->trans(
"UsePersonalValue").
'</td>';
467 print
'<td class="tdoverflowmax300">';
468 if (!empty($object->conf->MAIN_LANDING_PAGE)) {
470 if (!empty($tmparray[$object->conf->MAIN_LANDING_PAGE])) {
471 if (is_array($tmparray[$object->conf->MAIN_LANDING_PAGE])) {
472 $urltoshow = $langs->trans($tmparray[$object->conf->MAIN_LANDING_PAGE][
'label']);
474 $urltoshow = $langs->trans($tmparray[$object->conf->MAIN_LANDING_PAGE]);
477 $urltoshow = $object->conf->MAIN_LANDING_PAGE;
479 print
'<a href="'.DOL_URL_ROOT.
'/'.$object->conf->MAIN_LANDING_PAGE.
'" target="_blank" rel="noopener">';
481 if (!empty($tmparray[$object->conf->MAIN_LANDING_PAGE][
'picto'])) {
482 $s =
img_picto($urltoshow, $tmparray[$object->conf->MAIN_LANDING_PAGE][
'picto'],
'class="pictofixedwidth"');
485 print
img_picto($urltoshow,
'globe',
'class="pictofixedwidth"');
495 print
'<tr class="oddeven">'.
"\n";
496 print
'<td>'.$langs->trans(
"AGENDA_DEFAULT_VIEW").
'</td>'.
"\n";
497 print
'<td class="center"> </td>'.
"\n";
498 print
'<td class="nowrap" width="20%"><input class="oddeven" type="checkbox" disabled '.(!empty($object->conf->AGENDA_DEFAULT_VIEW) ?
" checked" :
"").
'> '.$langs->trans(
"UsePersonalValue").
'</td>';
500 $tmplist = array(
''=>
' ',
'show_list'=>$langs->trans(
"ViewList"),
'show_month'=>$langs->trans(
"ViewCal"),
'show_week'=>$langs->trans(
"ViewWeek"),
'show_day'=>$langs->trans(
"ViewDay"),
'show_peruser'=>$langs->trans(
"ViewPerUser"));
501 if (!empty($object->conf->AGENDA_DEFAULT_VIEW)) {
502 print $form->selectarray(
'AGENDA_DEFAULT_VIEW', $tmplist, $object->conf->AGENDA_DEFAULT_VIEW, 0, 0, 0,
'', 0, 0, 1);
504 print
'</td></tr>'.
"\n";
507 print
'<tr class="oddeven"><td>'.$langs->trans(
"MaxSizeList").
'</td>';
508 print
'<td>'.(!empty($conf->global->MAIN_SIZE_LISTE_LIMIT) ? $conf->global->MAIN_SIZE_LISTE_LIMIT :
' ').
'</td>';
509 print
'<td class="nowrap" width="20%"><input class="oddeven" type="checkbox" disabled '.(!empty($object->conf->MAIN_SIZE_LISTE_LIMIT) ?
" checked" :
"").
'> '.$langs->trans(
"UsePersonalValue").
'</td>';
510 print
'<td>'.(!empty($object->conf->MAIN_SIZE_LISTE_LIMIT) ? $object->conf->MAIN_SIZE_LISTE_LIMIT :
' ').
'</td></tr>';
521 print
'<div class="tabsAction">';
522 if (empty($user->admin) && !empty($dolibarr_main_demo)) {
523 print
'<a class="butActionRefused classfortooltip" title="'.$langs->trans(
"FeatureDisabledInDemo").
'" href="#">'.$langs->trans(
"Modify").
'</a>';
525 if ($caneditfield || !empty($user->admin)) {
526 print
'<a class="butAction" href="'.$_SERVER[
"PHP_SELF"].
'?action=edit&token='.newToken().
'&id='.$object->id.
'">'.$langs->trans(
"Modify").
'</a>';
528 print
'<a class="butActionRefused classfortooltip" title="'.$langs->trans(
"NotEnoughPermissions").
'" href="#">'.$langs->trans(
"Modify").
'</a>';
535if ($action ==
'edit') {
if(!defined('NOREQUIRESOC')) if(!defined( 'NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined( 'NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined( 'NOREQUIREAJAX')) llxHeader()
Empty header.
Class to manage Dolibarr users.
colorStringToArray($stringcolor, $colorifnotfound=array(88, 88, 88))
Convert a string RGB value ('FFFFFF', '255,255,255') into an array RGB array(255,255,...
dol_set_user_param($db, $conf, &$user, $tab)
Save personnal parameter.
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.
picto_from_langcode($codelang, $moreatt='', $notitlealt=0)
Return img flag of country for a language code or country code.
showValueWithClipboardCPButton($valuetocopy, $showonlyonhover=1, $texttoshow='')
Create a button to copy $valuetocopy in the clipboard (for copy and paste feature).
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.
dolButtonToOpenUrlInDialogPopup($name, $label, $buttonstring, $url, $disabled='', $morecss='classlink button bordertransp', $jsonopen='', $backtopagejsfields='', $accesskey='')
Return HTML code to output a button to open a dialog popup box.
dol_get_fiche_end($notab=0)
Return tab footer of a card.
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.
dol_sanitizeFileName($str, $newstr='_', $unaccent=1)
Clean a string to use it as a file name.
getDolGlobalString($key, $default='')
Return dolibarr global constant string value.
conf($dolibarr_main_document_root)
Load conf file (file must exists)
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.
user_prepare_head(User $object)
Prepare array with list of tabs.
showSkins($fuser, $edit=0, $foruserprofile=false)
Show list of themes.