34 require
'../../main.inc.php';
35 require_once DOL_DOCUMENT_ROOT.
'/core/lib/admin.lib.php';
36 require_once DOL_DOCUMENT_ROOT.
'/core/lib/member.lib.php';
39 $langs->loadLangs(array(
"admin",
"members"));
46 $choices = array(
'yesno',
'texte',
'chaine');
48 $value =
GETPOST(
'value',
'alpha');
49 $label =
GETPOST(
'label',
'alpha');
50 $scandir =
GETPOST(
'scandir',
'alpha');
53 $action =
GETPOST(
'action',
'aZ09');
60 include DOL_DOCUMENT_ROOT.
'/core/actions_setmoduleoptions.inc.php';
62 if ($action ==
'set_default') {
65 } elseif ($action ==
'del_default') {
73 } elseif ($action ==
'setdoc') {
75 if (
dolibarr_set_const($db,
"MEMBER_ADDON_PDF_ODT", $value,
'chaine', 0,
'', $conf->entity)) {
78 $conf->global->MEMBER_ADDON_PDF_ODT = $value;
87 } elseif (preg_match(
'/set_([a-z0-9_\-]+)/i', $action, $reg)) {
90 header(
"Location: ".$_SERVER[
"PHP_SELF"]);
95 } elseif (preg_match(
'/del_([a-z0-9_\-]+)/i', $action, $reg)) {
98 header(
"Location: ".$_SERVER[
"PHP_SELF"]);
103 } elseif ($action ==
'updatemainoptions') {
105 $res1 = $res2 = $res3 = $res4 = $res5 = $res6 = $res7 = 0;
106 $res1 =
dolibarr_set_const($db,
'ADHERENT_LOGIN_NOT_REQUIRED',
GETPOST(
'ADHERENT_LOGIN_NOT_REQUIRED',
'alpha') ? 0 : 1,
'chaine', 0,
'', $conf->entity);
107 $res2 =
dolibarr_set_const($db,
'ADHERENT_MAIL_REQUIRED',
GETPOST(
'ADHERENT_MAIL_REQUIRED',
'alpha'),
'chaine', 0,
'', $conf->entity);
108 $res3 =
dolibarr_set_const($db,
'ADHERENT_DEFAULT_SENDINFOBYMAIL',
GETPOST(
'ADHERENT_DEFAULT_SENDINFOBYMAIL',
'alpha'),
'chaine', 0,
'', $conf->entity);
109 $res3 =
dolibarr_set_const($db,
'ADHERENT_CREATE_EXTERNAL_USER_LOGIN',
GETPOST(
'ADHERENT_CREATE_EXTERNAL_USER_LOGIN',
'alpha'),
'chaine', 0,
'', $conf->entity);
110 $res4 =
dolibarr_set_const($db,
'ADHERENT_BANK_USE',
GETPOST(
'ADHERENT_BANK_USE',
'alpha'),
'chaine', 0,
'', $conf->entity);
113 $res4 =
dolibarr_set_const($db,
'ADHERENT_VAT_FOR_SUBSCRIPTIONS',
GETPOST(
'ADHERENT_VAT_FOR_SUBSCRIPTIONS',
'alpha'),
'chaine', 0,
'', $conf->entity);
114 $res5 =
dolibarr_set_const($db,
'ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS',
GETPOST(
'ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS',
'alpha'),
'chaine', 0,
'', $conf->entity);
116 $res6 =
dolibarr_set_const($db,
'ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS',
GETPOST(
'ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS',
'alpha'),
'chaine', 0,
'', $conf->entity);
119 if ($res1 < 0 || $res2 < 0 || $res3 < 0 || $res4 < 0 || $res5 < 0 || $res6 < 0) {
126 } elseif ($action ==
'updatememberscards') {
128 $res1 = $res2 = $res3 = $res4 = 0;
130 $res2 =
dolibarr_set_const($db,
'ADHERENT_CARD_HEADER_TEXT',
GETPOST(
'ADHERENT_CARD_HEADER_TEXT',
'alpha'),
'chaine', 0,
'', $conf->entity);
131 $res3 =
dolibarr_set_const($db,
'ADHERENT_CARD_TEXT',
GETPOST(
'ADHERENT_CARD_TEXT',
'alpha'),
'chaine', 0,
'', $conf->entity);
132 $res3 =
dolibarr_set_const($db,
'ADHERENT_CARD_TEXT_RIGHT',
GETPOST(
'ADHERENT_CARD_TEXT_RIGHT',
'alpha'),
'chaine', 0,
'', $conf->entity);
133 $res4 =
dolibarr_set_const($db,
'ADHERENT_CARD_FOOTER_TEXT',
GETPOST(
'ADHERENT_CARD_FOOTER_TEXT',
'alpha'),
'chaine', 0,
'', $conf->entity);
135 if ($res1 < 0 || $res2 < 0 || $res3 < 0 || $res4 < 0) {
142 } elseif ($action ==
'updatememberstickets') {
145 $res1 =
dolibarr_set_const($db,
'ADHERENT_ETIQUETTE_TYPE',
GETPOST(
'ADHERENT_ETIQUETTE_TYPE'),
'chaine', 0,
'', $conf->entity);
146 $res2 =
dolibarr_set_const($db,
'ADHERENT_ETIQUETTE_TEXT',
GETPOST(
'ADHERENT_ETIQUETTE_TEXT',
'alpha'),
'chaine', 0,
'', $conf->entity);
148 if ($res1 < 0 || $res2 < 0) {
155 } elseif ($action ==
'setcodemember') {
156 $result =
dolibarr_set_const($db,
"MEMBER_CODEMEMBER_ADDON", $value,
'chaine', 0,
'', $conf->entity);
160 } elseif ($action ==
'update' || $action ==
'add') {
162 $constname =
GETPOST(
'constname',
'alpha');
163 $constvalue = (
GETPOST(
'constvalue_'.$constname) ?
GETPOST(
'constvalue_'.$constname) :
GETPOST(
'constvalue'));
166 if (($constname ==
'ADHERENT_CARD_TYPE' || $constname ==
'ADHERENT_ETIQUETTE_TYPE' || $constname ==
'ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS') && $constvalue == -1) {
169 if ($constname ==
'ADHERENT_LOGIN_NOT_REQUIRED') {
177 $consttype =
GETPOST(
'consttype',
'alpha');
178 $constnote =
GETPOST(
'constnote');
179 $res =
dolibarr_set_const($db, $constname, $constvalue, $choices[$consttype], 0, $constnote, $conf->entity);
193 if ($action ==
'set') {
201 if ($action ==
'unset') {
216 $help_url =
'EN:Module_Foundations|FR:Module_Adhérents|ES:Módulo_Miembros|DE:Modul_Mitglieder';
221 $linkback =
'<a href="'.DOL_URL_ROOT.
'/admin/modules.php?restore_lastsearch_values=1">'.$langs->trans(
"BackToModuleList").
'</a>';
222 print
load_fiche_titre($langs->trans(
"MembersSetup"), $linkback,
'title_setup');
229 $dirModMember = array_merge(array(
'/core/modules/member/'), $conf->modules_parts[
'member']);
230 foreach ($conf->modules_parts[
'models'] as $mo) {
232 $dirModMember[] = $mo.
'core/modules/member/';
239 print
'<div class="div-table-responsive-no-min">';
240 print
'<table class="noborder centpercent">'.
"\n";
241 print
'<tr class="liste_titre">'.
"\n";
242 print
' <td>'.$langs->trans(
"Name").
'</td>';
243 print
' <td>'.$langs->trans(
"Description").
'</td>';
244 print
' <td>'.$langs->trans(
"Example").
'</td>';
245 print
' <td class="center" width="80">'.$langs->trans(
"Status").
'</td>';
246 print
' <td class="center" width="60">'.$langs->trans(
"ShortInfo").
'</td>';
249 $arrayofmodules = array();
251 foreach ($dirModMember as $dirroot) {
254 $handle = @opendir($dir);
255 if (is_resource($handle)) {
257 while (($file = readdir($handle)) !==
false) {
259 if (substr($file, 0, 11) ==
'mod_member_' && substr($file, -3) ==
'php') {
260 $file = substr($file, 0,
dol_strlen($file) - 4);
267 $modCodeMember =
new $file;
269 if ($modCodeMember->version ==
'development' && $conf->global->MAIN_FEATURES_LEVEL < 2) {
272 if ($modCodeMember->version ==
'experimental' && $conf->global->MAIN_FEATURES_LEVEL < 1) {
276 $arrayofmodules[$file] = $modCodeMember;
285 foreach ($arrayofmodules as $file => $modCodeMember) {
286 print
'<tr class="oddeven">'.
"\n";
287 print
'<td width="140">'.$modCodeMember->name.
'</td>'.
"\n";
288 print
'<td>'.$modCodeMember->info($langs).
'</td>'.
"\n";
289 print
'<td class="nowrap">'.$modCodeMember->getExample($langs).
'</td>'.
"\n";
292 print
'<td class="center">'.
"\n";
293 print
img_picto($langs->trans(
"Activated"),
'switch_on');
296 $disabled = (
isModEnabled(
'multicompany') && (is_object($mc) && !empty($mc->sharings[
'referent']) && $mc->sharings[
'referent'] != $conf->entity) ?
true :
false);
297 print
'<td class="center">';
299 print
'<a class="reposition" href="'.$_SERVER[
'PHP_SELF'].
'?action=setcodemember&token='.
newToken().
'&value='.urlencode($file).
'">';
301 print
img_picto($langs->trans(
"Disabled"),
'switch_off');
308 print
'<td class="center">';
309 $s = $modCodeMember->getToolTip($langs,
null, -1);
310 print
$form->textwithpicto(
'', $s, 1);
320 print
'<form action="'.$_SERVER[
"PHP_SELF"].
'" method="POST">';
321 print
'<input type="hidden" name="token" value="'.newToken().
'">';
322 print
'<input type="hidden" name="action" value="updatemainoptions">';
329 print
'<div class="div-table-responsive-no-min">';
330 print
'<table class="noborder centpercent">';
331 print
'<tr class="liste_titre">';
332 print
'<td>'.$langs->trans(
"Description").
'</td>';
333 print
'<td>'.$langs->trans(
"Value").
'</td>';
337 print
'<tr class="oddeven"><td>'.$langs->trans(
"AdherentMailRequired").
'</td><td>';
338 print
$form->selectyesno(
'ADHERENT_MAIL_REQUIRED', (!empty($conf->global->ADHERENT_MAIL_REQUIRED) ? $conf->global->ADHERENT_MAIL_REQUIRED : 0), 1);
339 print
"</td></tr>\n";
342 print
'<tr class="oddeven"><td>'.$langs->trans(
"AdherentLoginRequired").
'</td><td>';
343 print
$form->selectyesno(
'ADHERENT_LOGIN_NOT_REQUIRED', (!empty($conf->global->ADHERENT_LOGIN_NOT_REQUIRED) ? 0 : 1), 1);
344 print
"</td></tr>\n";
347 print
'<tr class="oddeven"><td>'.$langs->trans(
"MemberSendInformationByMailByDefault").
'</td><td>';
348 print
$form->selectyesno(
'ADHERENT_DEFAULT_SENDINFOBYMAIL', (!empty($conf->global->ADHERENT_DEFAULT_SENDINFOBYMAIL) ? $conf->global->ADHERENT_DEFAULT_SENDINFOBYMAIL : 0), 1);
349 print
"</td></tr>\n";
352 print
'<tr class="oddeven"><td>'.$langs->trans(
"MemberCreateAnExternalUserForSubscriptionValidated").
'</td><td>';
353 print
$form->selectyesno(
'ADHERENT_CREATE_EXTERNAL_USER_LOGIN', (!empty($conf->global->ADHERENT_CREATE_EXTERNAL_USER_LOGIN) ? $conf->global->ADHERENT_CREATE_EXTERNAL_USER_LOGIN : 0), 1);
354 print
"</td></tr>\n";
364 print
'<tr class="oddeven"><td>'.$langs->trans(
"MoreActionsOnSubscription").
'</td>';
365 $arraychoices = array(
'0'=>$langs->trans(
"None"));
367 $arraychoices[
'bankdirect'] = $langs->trans(
"MoreActionBankDirect");
370 $arraychoices[
'invoiceonly'] = $langs->trans(
"MoreActionInvoiceOnly");
373 $arraychoices[
'bankviainvoice'] = $langs->trans(
"MoreActionBankViaInvoice");
378 print
'<br><div style="padding-top: 5px;"><span class="opacitymedium">'.$langs->trans(
"ABankAccountMustBeDefinedOnPaymentModeSetup").
'</span></div>';
385 print
'<tr class="oddeven"><td>'.$langs->trans(
"VATToUseForSubscriptions").
'</td>';
388 print
$form->selectarray(
'ADHERENT_VAT_FOR_SUBSCRIPTIONS', array(
'0'=>$langs->trans(
"NoVatOnSubscription"),
'defaultforfoundationcountry'=>$langs->trans(
"Default")), (empty($conf->global->ADHERENT_VAT_FOR_SUBSCRIPTIONS) ?
'0' : $conf->global->ADHERENT_VAT_FOR_SUBSCRIPTIONS), 0);
391 print
'<td class="right">';
392 print $langs->trans(
"WarningModuleNotActive", $langs->transnoentities(
"Module85Name"));
398 print
'<tr class="oddeven"><td>'.$langs->trans(
"ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS").
'</td>';
400 $selected = (empty($conf->global->ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS) ?
'' : $conf->global->ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS);
401 print
img_picto(
'',
'product',
'class="pictofixedwidth"');
402 $form->select_produits($selected,
'ADHERENT_PRODUCT_ID_FOR_SUBSCRIPTIONS',
'', 0);
411 print
'<div class="center">';
412 print
'<input type="submit" class="button" value="'.$langs->trans(
"Update").
'" name="Button">';
423 $dirmodels = array_merge(array(
'/'), (array) $conf->modules_parts[
'models']);
427 $sql =
"SELECT nom as name";
428 $sql .=
" FROM ".MAIN_DB_PREFIX.
"document_model";
429 $sql .=
" WHERE type = '".$db->escape($type).
"'";
430 $sql .=
" AND entity = ".$conf->entity;
431 $resql = $db->query($sql);
434 $num_rows = $db->num_rows(
$resql);
435 while ($i < $num_rows) {
436 $obj = $db->fetch_object(
$resql);
437 array_push($def, $obj->name);
447 print
'<div class="div-table-responsive-no-min">';
448 print
'<table class="noborder centpercent">';
449 print
'<tr class="liste_titre">';
450 print
'<td>'.$langs->trans(
"Name").
'</td>';
451 print
'<td>'.$langs->trans(
"Description").
'</td>';
452 print
'<td align="center" width="60">'.$langs->trans(
"Status").
"</td>\n";
453 print
'<td align="center" width="60">'.$langs->trans(
"Default").
"</td>\n";
454 print
'<td align="center" width="80">'.$langs->trans(
"ShortInfo").
'</td>';
455 print
'<td align="center" width="80">'.$langs->trans(
"Preview").
'</td>';
460 foreach ($dirmodels as $reldir) {
461 foreach (array(
'',
'/doc') as $valdir) {
464 $handle = opendir($dir);
465 if (is_resource($handle)) {
466 while (($file = readdir($handle)) !==
false) {
471 foreach ($filelist as $file) {
472 if (preg_match(
'/\.class\.php$/i', $file) && preg_match(
'/^(pdf_|doc_)/', $file)) {
473 if (file_exists($dir.
'/'.$file)) {
474 $name = substr($file, 4,
dol_strlen($file) - 14);
475 $classname = substr($file, 0,
dol_strlen($file) - 10);
477 require_once $dir.
'/'.$file;
478 $module =
new $classname($db);
480 $modulequalified = 1;
481 if ($module->version ==
'development' && $conf->global->MAIN_FEATURES_LEVEL < 2) {
482 $modulequalified = 0;
484 if ($module->version ==
'experimental' && $conf->global->MAIN_FEATURES_LEVEL < 1) {
485 $modulequalified = 0;
488 if ($modulequalified) {
489 print
'<tr class="oddeven"><td width="100">';
490 print (empty($module->name) ? $name : $module->name);
492 if (method_exists($module,
'info')) {
493 print $module->info($langs);
495 print $module->description;
500 if (in_array($name, $def)) {
501 print
'<td class="center">'.
"\n";
502 print
'<a href="'.$_SERVER[
"PHP_SELF"].
'?action=del_default&token='.
newToken().
'&value='.$name.
'">';
503 print
img_picto($langs->trans(
"Enabled"),
'switch_on');
507 print
'<td class="center">'.
"\n";
508 print
'<a href="'.$_SERVER[
"PHP_SELF"].
'?action=set_default&token='.
newToken().
'&value='.$name.
'&scandir='.(!empty($module->scandir) ? $module->scandir :
'').
'&label='.urlencode($module->name).
'">'.
img_picto($langs->trans(
"Disabled"),
'switch_off').
'</a>';
513 print
'<td class="center">';
515 print
img_picto($langs->trans(
"Default"),
'on');
517 print
'<a href="'.$_SERVER[
"PHP_SELF"].
'?action=setdoc&token='.
newToken().
'&value='.$name.
'&scandir='.(!empty($module->scandir) ? $module->scandir :
'').
'&label='.urlencode($module->name).
'" alt="'.$langs->trans(
"Default").
'">'.
img_picto($langs->trans(
"Disabled"),
'off').
'</a>';
522 $htmltooltip =
''.$langs->trans(
"Name").
': '.$module->name;
523 $htmltooltip .=
'<br>'.$langs->trans(
"Type").
': '.($module->type ? $module->type : $langs->trans(
"Unknown"));
524 if ($module->type ==
'pdf') {
525 $htmltooltip .=
'<br>'.$langs->trans(
"Width").
'/'.$langs->trans(
"Height").
': '.$module->page_largeur.
'/'.$module->page_hauteur;
527 $htmltooltip .=
'<br><br><u>'.$langs->trans(
"FeaturesSupported").
':</u>';
528 $htmltooltip .=
'<br>'.$langs->trans(
"Logo").
': '.
yn(!empty($module->option_logo) ? $module->option_logo : 0, 1, 1);
529 $htmltooltip .=
'<br>'.$langs->trans(
"MultiLanguage").
': '.
yn(!empty($module->option_multilang) ? $module->option_multilang : 0, 1, 1);
532 print
'<td class="center">';
533 print
$form->textwithpicto(
'', $htmltooltip, 1, 0);
537 print
'<td class="center">';
538 if ($module->type ==
'pdf') {
539 print
'<a href="'.$_SERVER[
"PHP_SELF"].
'?action=specimen&module='.$name.
'">'.
img_object($langs->trans(
"Preview"),
'contract').
'</a>';
541 print
img_object($langs->trans(
"PreviewNotAvailable"),
'generic');
563 print
'<form action="'.$_SERVER[
"PHP_SELF"].
'" method="POST">';
564 print
'<input type="hidden" name="token" value="'.newToken().
'">';
565 print
'<input type="hidden" name="action" value="updatememberscards">';
569 $helptext =
'*'.$langs->trans(
"FollowingConstantsWillBeSubstituted").
'<br>';
570 $helptext .=
'__DOL_MAIN_URL_ROOT__, __ID__, __FIRSTNAME__, __LASTNAME__, __FULLNAME__, __LOGIN__, __PASSWORD__, ';
571 $helptext .=
'__COMPANY__, __ADDRESS__, __ZIP__, __TOWN__, __COUNTRY__, __EMAIL__, __BIRTH__, __PHOTO__, __TYPE__, ';
572 $helptext .=
'__YEAR__, __MONTH__, __DAY__';
574 print
'<div class="div-table-responsive-no-min">';
575 print
'<table class="noborder centpercent">';
576 print
'<tr class="liste_titre">';
577 print
'<td>'.$langs->trans(
"Description").
'</td>';
578 print
'<td>'.$form->textwithpicto($langs->trans(
"Value"), $helptext, 1,
'help',
'', 0, 2,
'idhelptext').
'</td>';
582 print
'<tr class="oddeven"><td>'.$langs->trans(
"DescADHERENT_CARD_TYPE").
'</td><td>';
584 require_once DOL_DOCUMENT_ROOT.
'/core/lib/format_cards.lib.php';
585 $arrayoflabels = array();
586 foreach (array_keys($_Avery_Labels) as $codecards) {
587 $arrayoflabels[$codecards] = $_Avery_Labels[$codecards][
'name'];
591 print
"</td></tr>\n";
594 print
'<tr class="oddeven"><td>'.$langs->trans(
"DescADHERENT_CARD_HEADER_TEXT").
'</td><td>';
595 print
'<input type="text" class="flat minwidth300" name="ADHERENT_CARD_HEADER_TEXT" value="'.dol_escape_htmltag(
getDolGlobalString(
'ADHERENT_CARD_HEADER_TEXT')).
'">';
596 print
"</td></tr>\n";
599 print
'<tr class="oddeven"><td>'.$langs->trans(
"DescADHERENT_CARD_TEXT").
'</td><td>';
600 print
'<textarea class="flat" name="ADHERENT_CARD_TEXT" cols="50" rows="5" wrap="soft">'.
"\n";
603 print
"</td></tr>\n";
606 print
'<tr class="oddeven"><td>'.$langs->trans(
"DescADHERENT_CARD_TEXT_RIGHT").
'</td><td>';
607 print
'<textarea class="flat" name="ADHERENT_CARD_TEXT_RIGHT" cols="50" rows="5" wrap="soft">'.
"\n";
610 print
"</td></tr>\n";
613 print
'<tr class="oddeven"><td>'.$langs->trans(
"DescADHERENT_CARD_FOOTER_TEXT").
'</td><td>';
614 print
'<input type="text" class="flat minwidth300" name="ADHERENT_CARD_FOOTER_TEXT" value="'.dol_escape_htmltag(
getDolGlobalString(
'ADHERENT_CARD_FOOTER_TEXT')).
'">';
615 print
"</td></tr>\n";
620 print
'<div class="center">';
621 print
'<input type="submit" class="button" value="'.$langs->trans(
"Update").
'" name="Button">';
630 print
'<form action="'.$_SERVER[
"PHP_SELF"].
'" method="POST">';
631 print
'<input type="hidden" name="token" value="'.newToken().
'">';
632 print
'<input type="hidden" name="action" value="updatememberstickets">';
636 $helptext =
'*'.$langs->trans(
"FollowingConstantsWillBeSubstituted").
'<br>';
637 $helptext .=
'__DOL_MAIN_URL_ROOT__, __ID__, __FIRSTNAME__, __LASTNAME__, __FULLNAME__, __LOGIN__, __PASSWORD__, ';
638 $helptext .=
'__COMPANY__, __ADDRESS__, __ZIP__, __TOWN__, __COUNTRY__, __EMAIL__, __BIRTH__, __PHOTO__, __TYPE__, ';
639 $helptext .=
'__YEAR__, __MONTH__, __DAY__';
641 print
'<div class="div-table-responsive-no-min">';
642 print
'<table class="noborder centpercent">';
643 print
'<tr class="liste_titre">';
644 print
'<td>'.$langs->trans(
"Description").
'</td>';
645 print
'<td>'.$form->textwithpicto($langs->trans(
"Value"), $helptext, 1,
'help',
'', 0, 2,
'idhelptext').
'</td>';
649 print
'<tr class="oddeven"><td>'.$langs->trans(
"DescADHERENT_ETIQUETTE_TYPE").
'</td><td>';
651 require_once DOL_DOCUMENT_ROOT.
'/core/lib/format_cards.lib.php';
652 $arrayoflabels = array();
653 foreach (array_keys($_Avery_Labels) as $codecards) {
654 $arrayoflabels[$codecards] = $_Avery_Labels[$codecards][
'name'];
658 print
"</td></tr>\n";
661 print
'<tr class="oddeven"><td>'.$langs->trans(
"DescADHERENT_ETIQUETTE_TEXT").
'</td><td>';
662 print
'<textarea class="flat" name="ADHERENT_ETIQUETTE_TEXT" cols="50" rows="5" wrap="soft">'.
"\n";
665 print
"</td></tr>\n";
670 print
'<div class="center">';
671 print
'<input type="submit" class="button" value="'.$langs->trans(
"Update").
'" name="Button">';
if(GETPOST('button_removefilter_x', 'alpha')||GETPOST('button_removefilter.x', 'alpha')||GETPOST('button_removefilter', 'alpha')) if(GETPOST('button_search_x', 'alpha')||GETPOST('button_search.x', 'alpha')||GETPOST('button_search', 'alpha')) if($action=="save" &&empty($cancel)) $help_url
View.
addDocumentModel($name, $type, $label='', $description='')
Add document model used by doc generator.
dolibarr_set_const($db, $name, $value, $type='chaine', $visible=0, $note='', $entity=1)
Insert a parameter (key,value) into database (delete old key then insert it again).
dolibarr_del_const($db, $name, $entity=1)
Delete a constant.
delDocumentModel($name, $type)
Delete document model used by doc generator.
if(!defined('NOREQUIRESOC')) if(!defined('NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined('NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined('NOREQUIREAJAX')) llxHeader()
Empty header.
if(isModEnabled('facture') &&!empty($user->rights->facture->lire)) if((isModEnabled('fournisseur') &&empty($conf->global->MAIN_USE_NEW_SUPPLIERMOD) && $user->hasRight("fournisseur", "facture", "lire"))||(isModEnabled('supplier_invoice') && $user->hasRight("supplier_invoice", "lire"))) if(isModEnabled('don') &&!empty($user->rights->don->lire)) if(isModEnabled('tax') &&!empty($user->rights->tax->charges->lire)) if(isModEnabled('facture') &&isModEnabled('commande') && $user->hasRight("commande", "lire") &&empty($conf->global->WORKFLOW_DISABLE_CREATE_INVOICE_FROM_ORDER)) $resql
Social contributions to pay.
if($cancel &&! $id) if($action=='add' &&! $cancel) if($action=='delete') if($id) $form
Actions.
load_fiche_titre($titre, $morehtmlright='', $picto='generic', $pictoisfullpath=0, $id='', $morecssontable='', $morehtmlcenter='')
Load a title with picto.
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='')
Show tabs of a record.
yn($yesno, $case=1, $color=0)
Return yes or no in current language.
dol_print_error($db='', $error='', $errors=null)
Displays error message system with all the information to facilitate the diagnosis and the escalation...
img_object($titlealt, $picto, $moreatt='', $pictoisfullpath=false, $srconly=0, $notitle=0)
Show a picto called object_picto (generic function)
dol_get_fiche_end($notab=0)
Return tab footer of a card.
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='')
Set event messages in dol_events session object.
dol_strlen($string, $stringencoding='UTF-8')
Make a strlen call.
if(!function_exists('dol_getprefix')) dol_include_once($relpath, $classname='')
Make an include_once using default root and alternate root if it fails.
img_picto($titlealt, $picto, $moreatt='', $pictoisfullpath=false, $srconly=0, $notitle=0, $alt='', $morecss='', $marginleftonlyshort=2)
Show picto whatever it's its name (generic function)
dol_sort_array(&$array, $index, $order='asc', $natsort=0, $case_sensitive=0, $keepindex=0)
Advanced sort array by second index function, which produces ascending (default) or descending output...
newToken()
Return the value of token currently saved into session with name 'newtoken'.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
dol_buildpath($path, $type=0, $returnemptyifnotfound=0)
Return path of url or filesystem.
if(!function_exists('utf8_encode')) if(!function_exists('utf8_decode')) getDolGlobalString($key, $default='')
Return dolibarr global constant string value.
isModEnabled($module)
Is Dolibarr module enabled.
dol_syslog($message, $level=LOG_INFO, $ident=0, $suffixinfilename='', $restricttologhandler='', $logcontext=null)
Write log message into outputs.
member_admin_prepare_head()
Return array head with list of tabs to view object informations.
accessforbidden($message='', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Show a message to say access is forbidden and stop program.