28 require
'../main.inc.php';
30 require_once DOL_DOCUMENT_ROOT.
'/core/class/html.formfile.class.php';
33 $langs->loadLangs(array(
"bookcal@bookcal"));
35 $action =
GETPOST(
'action',
'aZ09');
42 $socid =
GETPOST(
'socid',
'int');
43 if (isset($user->socid) && $user->socid > 0) {
45 $socid = $user->socid;
66 llxHeader(
"", $langs->trans(
"BookCalArea"));
68 print
load_fiche_titre($langs->trans(
"BookCalArea"),
'',
'bookcal.png@bookcal');
70 print
'<div class="fichecenter"><div class="fichethirdleft">';
75 if ($user->rights->bookcal->availabilities->read && !empty($conf->bookcal->enabled)) {
76 $langs->load(
"orders");
78 $sql =
"SELECT rowid, `ref`, fk_soc, fk_project, description, note_public, note_private, date_creation, tms, fk_user_creat, fk_user_modif, last_main_doc, import_key, model_pdf, status, firstname, lastname, email, `start`, duration";
79 $sql .=
" FROM ". MAIN_DB_PREFIX .
'bookcal_booking';
84 $num = $db->num_rows(
$resql);
86 print
'<table class="noborder centpercent">';
87 print
'<tr class="liste_titre">';
88 print
'<th colspan="21">'.$langs->trans(
"Bookings").($num?
'<span class="badge marginleftonlyshort">'.$num.
'</span>':
'').
'</th></tr>';
93 <th colspan="3">id</th>
94 <th colspan="3">ref</th>
95 <th colspan="3">name</th>
96 <th colspan="3">date</th>
97 <th colspan="3">hour</th>
98 <th colspan="3">duration</th>
99 <th colspan="3">description</th>
104 $obj = $db->fetch_object(
$resql);
105 print
'<tr class="oddeven">';
107 $myobjectstatic->id=$obj->rowid;
108 $myobjectstatic->ref=$obj->ref;
109 $myobjectstatic->date = $obj->start;
110 $myobjectstatic->firstname = $obj->firstname;
111 $myobjectstatic->lastname = $obj->lastname;
112 $myobjectstatic->start = $obj->start;
113 $myobjectstatic->duration = $obj->duration;
114 $myobjectstatic->description = $obj->description;
117 print
'<td colspan="3" class="nowrap">' . $myobjectstatic->id .
"</td>";
118 print
'<td colspan="3" class="nowrap">' . $myobjectstatic->ref .
"</td>";
119 print
'<td colspan="3" class="nowrap">' . $myobjectstatic->firstname .
" " . $myobjectstatic->lastname .
"</td>";
120 print
'<td colspan="3" class="nowrap">' . $myobjectstatic->start .
"</td>";
121 print
'<td colspan="3" class="nowrap">' . $myobjectstatic->duration .
"</td>";
122 print
'<td colspan="3" class="nowrap">' . $myobjectstatic->description .
"</td>";
126 print
'<tr class="oddeven"><td colspan="3" class="opacitymedium">'.$langs->trans(
"NoOrder").
'</td></tr>';
128 print
"</table><br>";
139 print
'</div><div class="fichetwothirdright">';
142 $NBMAX = $conf->global->MAIN_SIZE_SHORTLIST_LIMIT;
143 $max = $conf->global->MAIN_SIZE_SHORTLIST_LIMIT;
195 print
'</div></div>';
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_print_error($db='', $error='', $errors=null)
Displays error message system with all the information to facilitate the diagnosis and the escalation...
dol_now($mode='auto')
Return date for now.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.