29require 
'../main.inc.php';
 
   30require_once DOL_DOCUMENT_ROOT.
'/resource/class/dolresource.class.php';
 
   33$langs->loadLangs(array(
"resource", 
"companies", 
"other"));
 
   37$action     = 
GETPOST(
'action', 
'alpha');
 
   38$massaction   = 
GETPOST(
'massaction', 
'alpha'); 
 
   39$confirm    = 
GETPOST(
'confirm', 
'alpha');
 
   40$toselect   = 
GETPOST(
'toselect', 
'array');
 
   41$contextpage  = 
GETPOST(
'contextpage', 
'aZ') ? 
GETPOST(
'contextpage', 
'aZ') : 
'interventionlist';
 
   44$element    = 
GETPOST(
'element', 
'alpha');
 
   48$sortorder    = 
GETPOST(
'sortorder', 
'aZ09comma');
 
   49$sortfield    = 
GETPOST(
'sortfield', 
'aZ09comma');
 
   50$optioncss    = 
GETPOST(
'optioncss', 
'alpha');
 
   53$contextpage  = 
GETPOST(
'contextpage', 
'aZ') ? 
GETPOST(
'contextpage', 
'aZ') : 
'resourcelist';
 
   60$extrafields->fetch_name_optionals_label(
$object->table_element);
 
   61$search_array_options = $extrafields->getOptionalsFromPost(
$object->table_element, 
'', 
'search_');
 
   62if (!is_array($search_array_options)) {
 
   63  $search_array_options = array();
 
   65$search_ref     = 
GETPOST(
"search_ref", 
'alpha');
 
   66$search_type    = 
GETPOST(
"search_type", 
'alpha');
 
   67$search_address   = 
GETPOST(
"search_address", 
'alpha');
 
   68$search_zip     = 
GETPOST(
"search_zip", 
'alpha');
 
   69$search_town    = 
GETPOST(
"search_town", 
'alpha');
 
   70$search_state   = 
GETPOST(
"search_state", 
'alpha');
 
   71$search_country   = 
GETPOST(
"search_country", 
'alpha');
 
   72$search_phone   = 
GETPOST(
"search_phone", 
'alpha');
 
   73$search_email   = 
GETPOST(
"search_email", 
'alpha');
 
   74$search_max_users = 
GETPOST(
"search_max_users", 
'alpha');
 
   75$search_url     = 
GETPOST(
"search_url", 
'alpha');
 
   79$hookmanager->initHooks(array(
'resourcelist'));
 
   81if (empty($sortorder)) {
 
   84if (empty($sortfield)) {
 
   92if (empty($page) || $page == -1) {
 
   95$offset = $limit * $page;
 
  101    'label' => $langs->trans(
"Ref"),
 
  106    'label' => $langs->trans(
"Type"),
 
  110  't.address' => array(
 
  111    'label' => $langs->trans(
"Address"),
 
  116    'label' => $langs->trans(
"Zip"),
 
  121    'label' => $langs->trans(
"Town"),
 
  126    'label' => $langs->trans(
"State"),
 
  131    'label' => $langs->trans(
"Country"),
 
  136    'label' => $langs->trans(
"Phone"),
 
  141    'label' => $langs->trans(
"Email"),
 
  145  't.max_users' => array(
 
  146    'label' => $langs->trans(
"MaxUsersLabel"),
 
  151    'label' => $langs->trans(
"URL"),
 
  157include DOL_DOCUMENT_ROOT.
'/core/tpl/extrafields_list_array_fields.tpl.php';
 
  161'@phan-var-force array<string,array{label:string,checked?:int<0,1>,position?:int,help?:string}> $arrayfields';  
 
  163include DOL_DOCUMENT_ROOT.
'/core/actions_changeselectedfields.inc.php';
 
  166if (
GETPOST(
'button_removefilter_x', 
'alpha') || 
GETPOST(
'button_removefilter.x', 
'alpha') || 
GETPOST(
'button_removefilter', 
'alpha')) { 
 
  169  $search_address = 
"";
 
  173  $search_country = 
"";
 
  176  $search_max_users = 
"";
 
  179  $search_array_options = array();
 
  182$permissiontoread = $user->hasRight(
'resource', 
'read');
 
  183$permissiontoadd = $user->hasRight(
'resource', 
'write');
 
  184$permissiontodelete = $user->hasRight(
'resource', 
'delete');
 
  185if (!$permissiontoread) {
 
  190$objectclass = 
'Dolresource';
 
  191$objectlabel = 
'Resources';
 
  192$uploaddir = $conf->resource->dir_output;
 
  193include DOL_DOCUMENT_ROOT.
'/core/actions_massactions.inc.php';
 
  199if (
GETPOST(
'cancel', 
'alpha')) {
 
  203if (!
GETPOST(
'confirmmassaction', 
'alpha') && $massaction != 
'presend' && $massaction != 
'confirm_presend') {
 
  207$parameters = array();
 
  208$reshook = $hookmanager->executeHooks(
'doActions', $parameters, $object, $action); 
 
  217$form = 
new Form($db);
 
  221$title = $langs->trans(
'Resources');
 
  225$varpage = empty($contextpage) ? $_SERVER[
"PHP_SELF"] : $contextpage;
 
  226$selectedfields = $form->multiSelectArrayWithCheckbox(
'selectedfields', $arrayfields, $varpage); 
 
  232$sql .= 
" t.address,";
 
  235$sql .= 
" t.fk_country,";
 
  236$sql .= 
" t.fk_state,";
 
  237$sql .= 
" t.description,";
 
  240$sql .= 
" t.max_users,";
 
  242$sql .= 
" t.fk_code_type_resource,";
 
  243$sql .= 
" t.tms as date_modification,";
 
  244$sql .= 
" t.datec as date_creation, ";
 
  245$sql .= 
" ty.label as type_label, ";
 
  246$sql .= 
" st.nom as state_label, ";
 
  247$sql .= 
" co.label as country_label ";
 
  249if (!empty($extrafields->attributes[
$object->table_element][
'label'])) {
 
  250  foreach ($extrafields->attributes[
$object->table_element][
'label'] as $key => $val) {
 
  251    $sql .= ($extrafields->attributes[
$object->table_element][
'type'][$key] != 
'separate' ? 
", ef.".$key.
" as options_".$key : 
'');
 
  255$parameters = array();
 
  256$reshook = $hookmanager->executeHooks(
'printFieldListSelect', $parameters, $object, $action); 
 
  257$sql .= $hookmanager->resPrint;
 
  261$sql .= 
" FROM ".MAIN_DB_PREFIX.
"resource as t";
 
  262$sql .= 
" LEFT JOIN ".MAIN_DB_PREFIX.
"c_type_resource as ty ON ty.code=t.fk_code_type_resource";
 
  263$sql .= 
" LEFT JOIN ".MAIN_DB_PREFIX.
"c_departements as st ON st.rowid=t.fk_state";
 
  264$sql .= 
" LEFT JOIN ".MAIN_DB_PREFIX.
"c_country as co ON co.rowid=t.fk_country";
 
  265if (isset($extrafields->attributes[
$object->table_element][
'label']) && is_array($extrafields->attributes[
$object->table_element][
'label']) && count($extrafields->attributes[
$object->table_element][
'label'])) {
 
  266  $sql .= 
" LEFT JOIN ".MAIN_DB_PREFIX.$object->table_element.
"_extrafields as ef on (t.rowid = ef.fk_object)";
 
  270$parameters = array();
 
  271$reshook = $hookmanager->executeHooks(
'printFieldListFrom', $parameters, $object, $action); 
 
  272$sql .= $hookmanager->resPrint;
 
  274$sql .= 
" WHERE t.entity IN (".getEntity(
'resource').
")";
 
  281if ($search_address) {
 
  293if ($search_country && $search_country != 
'-1') {
 
  294  $sql .= 
" AND t.fk_country IN (".$db->sanitize($search_country).
')';
 
  302if ($search_max_users) {
 
  310include DOL_DOCUMENT_ROOT.
'/core/tpl/extrafields_list_search_sql.tpl.php';
 
  312$parameters = array();
 
  313$reshook = $hookmanager->executeHooks(
'printFieldListWhere', $parameters, $object, $action); 
 
  314$sql .= $hookmanager->resPrint;
 
  317$nbtotalofrecords = 
'';
 
  320  $sqlforcount = preg_replace(
'/^'.preg_quote($sqlfields, 
'/').
'/', 
'SELECT COUNT(*) as nbtotalofrecords', $sql);
 
  321  $sqlforcount = preg_replace(
'/GROUP BY .*$/', 
'', $sqlforcount);
 
  322  $resql = $db->query($sqlforcount);
 
  324    $objforcount = $db->fetch_object($resql);
 
  325    $nbtotalofrecords = $objforcount->nbtotalofrecords;
 
  330  if (($page * $limit) > $nbtotalofrecords) { 
 
  338$sql .= $db->order($sortfield, $sortorder);
 
  340  $sql .= $db->plimit($limit + 1, $offset);
 
  343$resql = $db->query($sql);
 
  349$num = $db->num_rows($resql);
 
  352if ($num == 1 && 
getDolGlobalString(
'MAIN_SEARCH_DIRECT_OPEN_IF_ONLY_ONE') && !$page) {
 
  353  $obj = $db->fetch_object($resql);
 
  355  header(
"Location: ".
dol_buildpath(
'/resource/card.php', 1).
'?id='.$id);
 
  361llxHeader(
'', $title, $help_url, 
'', 0, 0, $morejs, $morecss, 
'', 
'mod-resource page-list bodyforlist');  
 
  363$arrayofselected = is_array($toselect) ? $toselect : array();
 
  366if (!empty($contextpage) && $contextpage != $_SERVER[
"PHP_SELF"]) {
 
  367  $param .= 
'&contextpage='.urlencode($contextpage);
 
  369if ($limit > 0 && $limit != $conf->liste_limit) {
 
  370  $param .= 
'&limit='.((int) $limit);
 
  372if ($search_ref != 
'') {
 
  373  $param .= 
'&search_ref='.urlencode($search_ref);
 
  375if ($search_type != 
'') {
 
  376  $param .= 
'&search_type='.urlencode($search_type);
 
  378if ($search_address != 
'') {
 
  379  $param .= 
'&search_address='.urlencode($search_address);
 
  381if ($search_zip != 
'') {
 
  382  $param .= 
'&search_zip='.urlencode($search_zip);
 
  384if ($search_town != 
'') {
 
  385  $param .= 
'&search_town='.urlencode($search_town);
 
  387if ($search_state != 
'') {
 
  388  $param .= 
'&search_state='.urlencode($search_state);
 
  390if ($search_country != 
'') {
 
  391  $param .= 
'&search_country='.urlencode($search_country);
 
  393if ($search_phone != 
'') {
 
  394  $param .= 
'&search_phone='.urlencode($search_phone);
 
  396if ($search_email != 
'') {
 
  397  $param .= 
'&search_email='.urlencode($search_email);
 
  399if ($search_max_users != 
'') {
 
  400  $param .= 
'&search_max_users='.urlencode($search_max_users);
 
  402if ($search_url != 
'') {
 
  403  $param .= 
'&search_url='.urlencode($search_url);
 
  407include DOL_DOCUMENT_ROOT.
'/core/tpl/extrafields_list_search_param.tpl.php';
 
  410$arrayofmassactions = array();
 
  411if (!empty($permissiontodelete)) {
 
  412  $arrayofmassactions[
'predelete'] = 
img_picto(
'', 
'delete', 
'class="pictofixedwidth"').$langs->trans(
"Delete");
 
  414if (
GETPOSTINT(
'nomassaction') || in_array($massaction, array(
'presend', 
'predelete'))) {
 
  415  $arrayofmassactions = array();
 
  417$massactionbutton = $form->selectMassAction(
'', $arrayofmassactions);
 
  419$varpage = empty($contextpage) ? $_SERVER[
"PHP_SELF"] : $contextpage;
 
  420$selectedfields = $form->multiSelectArrayWithCheckbox(
'selectedfields', $arrayfields, $varpage, 
getDolGlobalString(
'MAIN_CHECKBOX_LEFT_COLUMN'));
 
  422print 
'<form method="POST" id="searchFormList" action="'.$_SERVER[
"PHP_SELF"].
'">';
 
  423if ($optioncss != 
'') {
 
  424  print 
'<input type="hidden" name="optioncss" value="'.$optioncss.
'">';
 
  426print 
'<input type="hidden" name="token" value="'.newToken().
'">';
 
  427print 
'<input type="hidden" name="formfilteraction" id="formfilteraction" value="list">';
 
  428print 
'<input type="hidden" name="action" value="list">';
 
  429print 
'<input type="hidden" name="sortfield" value="'.$sortfield.
'">';
 
  430print 
'<input type="hidden" name="sortorder" value="'.$sortorder.
'">';
 
  431print 
'<input type="hidden" name="page" value="'.$page.
'">';
 
  432print 
'<input type="hidden" name="contextpage" value="'.$contextpage.
'">';
 
  435$url = DOL_URL_ROOT.
'/resource/card.php?action=create';
 
  437$newcardbutton = 
dolGetButtonTitle($langs->trans(
'NewResource'), 
'', 
'fa fa-plus-circle', $url, 
'', $permissiontoadd);
 
  439print_barre_liste($title, $page, $_SERVER[
'PHP_SELF'], $param, $sortfield, $sortorder, $massactionbutton, $num, $nbtotalofrecords, 
'object_'.
$object->picto, 0, $newcardbutton, 
'', $limit, 0, 0, 1);
 
  442$trackid = 
'int'.$object->id;
 
  443include DOL_DOCUMENT_ROOT.
'/core/tpl/massactions_pre.tpl.php';
 
  445$varpage = empty($contextpage) ? $_SERVER[
"PHP_SELF"] : $contextpage;
 
  446$selectedfields = ($form->multiSelectArrayWithCheckbox(
'selectedfields', $arrayfields, $varpage, 
getDolGlobalString(
'MAIN_CHECKBOX_LEFT_COLUMN'))); 
 
  447$selectedfields .= (count($arrayofmassactions) ? $form->showCheckAddButtons(
'checkforselect', 1) : 
'');
 
  449print 
'<div class="div-table-responsive">';
 
  450print 
'<table class="tagtable liste">'.
"\n";
 
  454print 
'<tr class="liste_titre_filter">';
 
  455if (!empty($arrayfields[
't.ref'][
'checked'])) {
 
  456  print 
'<td class="liste_titre">';
 
  457  print 
'<input type="text" class="flat" name="search_ref" value="'.$search_ref.
'" size="8">';
 
  460if (!empty($arrayfields[
'ty.label'][
'checked'])) {
 
  461  print 
'<td class="liste_titre">';
 
  462  print 
'<input type="text" class="flat" name="search_type" value="'.$search_type.
'" size="8">';
 
  465if (!empty($arrayfields[
't.address'][
'checked'])) {
 
  466  print 
'<td class="liste_titre">';
 
  467  print 
'<input type="text" class="flat" name="search_address" value="'.$search_address.
'" size="8">';
 
  470if (!empty($arrayfields[
't.zip'][
'checked'])) {
 
  471  print 
'<td class="liste_titre">';
 
  472  print 
'<input type="text" class="flat" name="search_zip" value="'.$search_zip.
'" size="8">';
 
  475if (!empty($arrayfields[
't.town'][
'checked'])) {
 
  476  print 
'<td class="liste_titre">';
 
  477  print 
'<input type="text" class="flat" name="search_town" value="'.$search_town.
'" size="8">';
 
  480if (!empty($arrayfields[
'st.nom'][
'checked'])) {
 
  481  print 
'<td class="liste_titre">';
 
  482  print 
'<input type="text" class="flat" name="search_state" value="'.$search_state.
'" size="8">';
 
  485if (!empty($arrayfields[
'co.label'][
'checked'])) {
 
  486  print 
'<td class="liste_titre">';
 
  487  print $form->select_country($search_country, 
'search_country', 
'', 0, 
'minwidth100imp maxwidth100');
 
  490if (!empty($arrayfields[
't.phone'][
'checked'])) {
 
  491  print 
'<td class="liste_titre">';
 
  492  print 
'<input type="text" class="flat" name="search_phone" value="'.$search_phone.
'" size="8">';
 
  495if (!empty($arrayfields[
't.email'][
'checked'])) {
 
  496  print 
'<td class="liste_titre">';
 
  497  print 
'<input type="text" class="flat" name="search_email" value="'.$search_email.
'" size="8">';
 
  500if (!empty($arrayfields[
't.max_users'][
'checked'])) {
 
  501  print 
'<td class="liste_titre">';
 
  502  print 
'<input type="text" class="flat" name="search_max_users" value="'.$search_max_users.
'" size="8">';
 
  505if (!empty($arrayfields[
't.url'][
'checked'])) {
 
  506  print 
'<td class="liste_titre">';
 
  507  print 
'<input type="text" class="flat" name="search_url" value="'.$search_url.
'" size="8">';
 
  511include DOL_DOCUMENT_ROOT.
'/core/tpl/extrafields_list_search_input.tpl.php';
 
  515  print 
'<td class="liste_titre center maxwidthsearch">';
 
  516  $searchpicto = $form->showFilterButtons();
 
  522$totalarray = array();
 
  523$totalarray[
'nbfield'] = 0;
 
  527print 
'<tr class="liste_titre">';
 
  528if (!empty($arrayfields[
't.ref'][
'checked'])) {
 
  529  print_liste_field_titre($arrayfields[
't.ref'][
'label'], $_SERVER[
"PHP_SELF"], 
"t.ref", 
"", $param, 
"", $sortfield, $sortorder);
 
  531if (!empty($arrayfields[
'ty.label'][
'checked'])) {
 
  532  print_liste_field_titre($arrayfields[
'ty.label'][
'label'], $_SERVER[
"PHP_SELF"], 
"ty.label", 
"", $param, 
"", $sortfield, $sortorder);
 
  534if (!empty($arrayfields[
't.address'][
'checked'])) {
 
  535  print_liste_field_titre($arrayfields[
't.address'][
'label'], $_SERVER[
"PHP_SELF"], 
"t.address", 
"", $param, 
"", $sortfield, $sortorder);
 
  537if (!empty($arrayfields[
't.zip'][
'checked'])) {
 
  538  print_liste_field_titre($arrayfields[
't.zip'][
'label'], $_SERVER[
"PHP_SELF"], 
"t.zip", 
"", $param, 
"", $sortfield, $sortorder);
 
  540if (!empty($arrayfields[
't.town'][
'checked'])) {
 
  541  print_liste_field_titre($arrayfields[
't.town'][
'label'], $_SERVER[
"PHP_SELF"], 
"t.town", 
"", $param, 
"", $sortfield, $sortorder);
 
  543if (!empty($arrayfields[
'st.nom'][
'checked'])) {
 
  544  print_liste_field_titre($arrayfields[
'st.nom'][
'label'], $_SERVER[
"PHP_SELF"], 
"st.nom", 
"", $param, 
"", $sortfield, $sortorder);
 
  546if (!empty($arrayfields[
'co.label'][
'checked'])) {
 
  547  print_liste_field_titre($arrayfields[
'co.label'][
'label'], $_SERVER[
"PHP_SELF"], 
"co.label", 
"", $param, 
"", $sortfield, $sortorder);
 
  549if (!empty($arrayfields[
't.phone'][
'checked'])) {
 
  550  print_liste_field_titre($arrayfields[
't.phone'][
'label'], $_SERVER[
"PHP_SELF"], 
"t.phone", 
"", $param, 
"", $sortfield, $sortorder);
 
  552if (!empty($arrayfields[
't.email'][
'checked'])) {
 
  553  print_liste_field_titre($arrayfields[
't.email'][
'label'], $_SERVER[
"PHP_SELF"], 
"t.email", 
"", $param, 
"", $sortfield, $sortorder);
 
  555if (!empty($arrayfields[
't.max_users'][
'checked'])) {
 
  556  print_liste_field_titre($arrayfields[
't.max_users'][
'label'], $_SERVER[
"PHP_SELF"], 
"t.max_users", 
"", $param, 
"", $sortfield, $sortorder);
 
  558if (!empty($arrayfields[
't.url'][
'checked'])) {
 
  559  print_liste_field_titre($arrayfields[
't.url'][
'label'], $_SERVER[
"PHP_SELF"], 
"t.url", 
"", $param, 
"", $sortfield, $sortorder);
 
  562include DOL_DOCUMENT_ROOT.
'/core/tpl/extrafields_list_search_title.tpl.php';
 
  565  print_liste_field_titre($selectedfields, $_SERVER[
"PHP_SELF"], 
"", 
'', 
'', 
'', $sortfield, $sortorder, 
'center maxwidthsearch ');
 
  572$savnbfield = $totalarray[
'nbfield'];
 
  573$totalarray = array();
 
  574$totalarray[
'nbfield'] = 0;
 
  575$imaxinloop = ($limit ? min($num, $limit) : $num);
 
  576while ($i < $imaxinloop) {
 
  577  $obj = $db->fetch_object($resql);
 
  578  $objectstatic->id = $obj->rowid;
 
  579  $objectstatic->ref = $obj->ref;
 
  580  $objectstatic->type_label = $obj->type_label;
 
  581  $objectstatic->address = $obj->address;
 
  582  $objectstatic->zip = $obj->zip;
 
  583  $objectstatic->town = $obj->town;
 
  584  $objectstatic->state = $obj->state_label;
 
  585  $objectstatic->country = $obj->country_label;
 
  586  $objectstatic->phone = $obj->phone;
 
  587  $objectstatic->email = $obj->email;
 
  588  $objectstatic->max_users = $obj->max_users;
 
  589  $objectstatic->url = $obj->url;
 
  591  print 
'<tr class="oddeven">';
 
  593  if (!empty($arrayfields[
't.ref'][
'checked'])) {
 
  594    print 
'<td>'.$objectstatic->getNomUrl(5).
'</td>';
 
  596      $totalarray[
'nbfield']++;
 
  600  if (!empty($arrayfields[
'ty.label'][
'checked'])) {
 
  601    print 
'<td>'.$objectstatic->type_label.
'</td>';
 
  603      $totalarray[
'nbfield']++;
 
  607  if (!empty($arrayfields[
't.address'][
'checked'])) {
 
  608    print 
'<td>'.$objectstatic->address.
'</td>';
 
  610      $totalarray[
'nbfield']++;
 
  614  if (!empty($arrayfields[
't.zip'][
'checked'])) {
 
  615    print 
'<td>'.$objectstatic->zip.
'</td>';
 
  617      $totalarray[
'nbfield']++;
 
  621  if (!empty($arrayfields[
't.town'][
'checked'])) {
 
  622    print 
'<td>'.$objectstatic->town.
'</td>';
 
  624      $totalarray[
'nbfield']++;
 
  628  if (!empty($arrayfields[
'st.nom'][
'checked'])) {
 
  629    print 
'<td>'.$objectstatic->state.
'</td>';
 
  631      $totalarray[
'nbfield']++;
 
  635  if (!empty($arrayfields[
'co.label'][
'checked'])) {
 
  636    print 
'<td>'.$objectstatic->country.
'</td>';
 
  638      $totalarray[
'nbfield']++;
 
  642  if (!empty($arrayfields[
't.phone'][
'checked'])) {
 
  643    print 
'<td>'.dol_print_phone($objectstatic->phone, 
'', 0, 0, 
'AC_TEL', 
" ", 
'phone').
'</td>';
 
  645      $totalarray[
'nbfield']++;
 
  649  if (!empty($arrayfields[
't.email'][
'checked'])) {
 
  650    print 
'<td>'.dol_print_email($objectstatic->email, 0, 0, 1, 0, 0, 1).
'</td>';
 
  652      $totalarray[
'nbfield']++;
 
  656  if (!empty($arrayfields[
't.max_users'][
'checked'])) {
 
  657    print 
'<td>'.$objectstatic->max_users.
'</td>';
 
  659      $totalarray[
'nbfield']++;
 
  663  if (!empty($arrayfields[
't.url'][
'checked'])) {
 
  664    print 
'<td>'.dol_print_url($objectstatic->url, 
'_blank', 32, 1).
'</td>';
 
  666      $totalarray[
'nbfield']++;
 
  670  include DOL_DOCUMENT_ROOT.
'/core/tpl/extrafields_list_print_fields.tpl.php';
 
  674    print 
'<td class="nowrap center">';
 
  675    if ($massactionbutton || $massaction) {   
 
  677      if (in_array($obj->rowid, $arrayofselected)) {
 
  680      print 
'<input id="cb'.$obj->rowid.
'" class="flat checkforselect" type="checkbox" name="toselect[]" value="'.$obj->rowid.
'"'.($selected ? 
' checked="checked"' : 
'').
'>';
 
  684      $totalarray[
'nbfield']++;
 
  693include DOL_DOCUMENT_ROOT.
'/core/tpl/list_print_total.tpl.php';
 
  698  foreach ($arrayfields as $key => $val) {
 
  699    if (!empty($val[
'checked'])) {
 
  703  print 
'<tr><td colspan="'.$colspan.
'"><span class="opacitymedium">'.$langs->trans(
"NoRecordFound").
'</span></td></tr>';
 
  708$parameters = array(
'arrayfields' => $arrayfields, 
'sql' => $sql);
 
  709$reshook = $hookmanager->executeHooks(
'printFieldListFooter', $parameters, $object, $action); 
 
  710print $hookmanager->resPrint;
 
  712print 
'</table>'.
"\n";
 
if( $user->socid > 0) if(! $user->hasRight('accounting', 'chartofaccount')) $object
if(!defined('NOREQUIRESOC')) if(!defined( 'NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined( 'NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined( 'NOREQUIREAJAX')) llxHeader()
Empty header.
img_picto($titlealt, $picto, $moreatt='', $pictoisfullpath=0, $srconly=0, $notitle=0, $alt='', $morecss='', $marginleftonlyshort=2)
Show picto whatever it's its name (generic function)
GETPOSTINT($paramname, $method=0)
Return the value of a $_GET or $_POST supervariable, converted into integer.
dolGetButtonTitle($label, $helpText='', $iconClass='fa fa-file', $url='', $id='', $status=1, $params=array())
Function dolGetButtonTitle : this kind of buttons are used in title in list.
natural_search($fields, $value, $mode=0, $nofirstand=0)
Generate natural SQL search string for a criteria (this criteria can be tested on one or several fiel...
getDolGlobalInt($key, $default=0)
Return a Dolibarr global constant int value.
dol_sort_array(&$array, $index, $order='asc', $natsort=0, $case_sensitive=0, $keepindex=0)
Advanced sort array by the value of a given key, which produces ascending (default) or descending out...
print_liste_field_titre($name, $file="", $field="", $begin="", $moreparam="", $moreattrib="", $sortfield="", $sortorder="", $prefix="", $tooltip="", $forcenowrapcolumntitle=0)
Show title line of an array.
print_barre_liste($title, $page, $file, $options='', $sortfield='', $sortorder='', $morehtmlcenter='', $num=-1, $totalnboflines='', $picto='generic', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limit=-1, $hideselectlimit=0, $hidenavigation=0, $pagenavastextinput=0, $morehtmlrightbeforearrow='')
Print a title with navigation controls for pagination.
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_buildpath($path, $type=0, $returnemptyifnotfound=0)
Return path of url or filesystem.
dol_print_error($db=null, $error='', $errors=null)
Displays error message system with all the information to facilitate the diagnosis and the escalation...
getDolGlobalString($key, $default='')
Return dolibarr global constant string value.
accessforbidden($message='', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Show a message to say access is forbidden and stop program.