29require
'../../main.inc.php';
30require_once DOL_DOCUMENT_ROOT.
'/core/lib/prelevement.lib.php';
31require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
32require_once DOL_DOCUMENT_ROOT.
'/compta/prelevement/class/ligneprelevement.class.php';
33require_once DOL_DOCUMENT_ROOT.
'/compta/prelevement/class/bonprelevement.class.php';
34require_once DOL_DOCUMENT_ROOT.
'/compta/bank/class/account.class.php';
45$langs->loadLangs(array(
'banks',
'categories',
'bills',
'companies',
'withdrawals'));
48$action =
GETPOST(
'action',
'aZ09');
58$sortfield =
GETPOST(
'sortfield',
'aZ09comma');
59$sortorder =
GETPOST(
'sortorder',
'aZ09comma');
61if (empty($page) || $page == -1) {
64$offset = $limit * $page;
69 $sortfield =
'pl.rowid';
78include DOL_DOCUMENT_ROOT.
'/core/actions_fetchobject.inc.php';
80$hookmanager->initHooks(array(
'directdebitprevcard',
'globalcard',
'directdebitprevlist'));
85$salaryBonPl =
$object->checkIfSalaryBonPrelevement();
88if ($type ==
'bank-transfer') {
89 $result =
restrictedArea($user,
'paymentbybanktransfer',
'',
'',
'');
91 $permissiontoadd = $user->hasRight(
'paymentbybanktransfer',
'create');
92 $permissiontosend = $user->hasRight(
'paymentbybanktransfer',
'send');
93 $permissiontocreditdebit = $user->hasRight(
'paymentbybanktransfer',
'debit');
94 $permissiontodelete = $user->hasRight(
'paymentbybanktransfer',
'read');
98 $permissiontoadd = $user->hasRight(
'prelevement',
'bons',
'creer');
99 $permissiontosend = $user->hasRight(
'prelevement',
'bons',
'send');
100 $permissiontocreditdebit = $user->hasRight(
'prelevement',
'bons',
'credit');
101 $permissiontodelete = $user->hasRight(
'prelevement',
'bons',
'read');
109$parameters = array(
'socid' => $socid);
110$reshook = $hookmanager->executeHooks(
'doActions', $parameters,
$object, $action);
115if (empty($reshook)) {
116 if ($action ==
'setbankaccount' && $permissiontoadd) {
124 if ($action ==
'setdate_trans' && $permissiontosend) {
125 $result =
$object->setValueFrom(
'date_trans', $date_trans,
'',
null,
'date');
131 if ($action ==
'infotrans' && $permissiontosend) {
132 require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
158 header(
"Location: card.php?id=".
$id.
"&error=$error");
164 if ($action ==
'setinfocredit' && $permissiontocreditdebit) {
167 if ((
$object->type !=
'bank-transfer' &&
$object->statut == BonPrelevement::STATUS_CREDITED) || (
$object->type ==
'bank-transfer' &&
$object->statut == BonPrelevement::STATUS_DEBITED)) {
171 $error =
$object->set_infocredit($user, $dt, ($salaryBonPl ?
'salary' :
''));
179 if ($action ==
'reopen' && $permissiontocreditdebit) {
181 $res =
$object->setStatut(BonPrelevement::STATUS_TRANSFERED);
187 if ($action ==
'confirm_delete' && $permissiontodelete) {
191 if ($savtype ==
'bank-transfer') {
192 header(
"Location: ".DOL_URL_ROOT.
'/compta/paymentbybanktransfer/index.php');
194 header(
"Location: ".DOL_URL_ROOT.
'/compta/prelevement/index.php');
206$form =
new Form($db);
208llxHeader(
'', $langs->trans(
"WithdrawalsReceipts"));
210if (($id > 0 || $ref) &&
$object->id <= 0) {
214if ($id > 0 || $ref) {
216 print
dol_get_fiche_head($head,
'prelevement', $langs->trans(
"WithdrawalsReceipts"), -1,
'payment');
218 if (
GETPOST(
'error',
'alpha') !=
'') {
219 print
'<div class="error">'.$object->getErrorString(
GETPOST(
'error',
'alpha')).
'</div>';
222 $linkback =
'<a href="'.DOL_URL_ROOT.
'/compta/prelevement/orders_list.php?restore_lastsearch_values=1'.(
$object->type !=
'bank-transfer' ?
'' :
'&type=bank-transfer').
'">'.$langs->trans(
"BackToList").
'</a>';
224 dol_banner_tab(
$object,
'ref', $linkback, 1,
'ref',
'ref');
226 print
'<div class="fichecenter">';
227 print
'<div class="underbanner clearboth"></div>';
228 print
'<table class="border centpercent tableforfield">';
231 print
'<tr><td class="titlefieldcreate">'.$langs->trans(
"Date").
'</td><td>'.
dol_print_date(
$object->datec,
'day').
'</td></tr>';
233 print
'<tr><td>'.$langs->trans(
"Amount").
'</td><td><span class="amount">'.
price(
$object->amount).
'</span></td></tr>';
236 if (!empty(
$object->date_trans)) {
237 $muser =
new User($db);
238 $muser->fetch(
$object->user_trans);
242 print
'<table class="nobordernopadding centpercent"><tr><td>';
243 print $langs->trans(
'TransData');
245 if ($action !=
'editdate_trans' && $permissiontosend) {
246 print
'<td class="right"><a class="editfielda" href="'.$_SERVER[
"PHP_SELF"].
'?action=editdate_trans&token='.
newToken().
'&id='.
$object->id.
'">'.
img_edit($langs->trans(
'SetTransDate'), 1).
'</a></td>';
248 print
'</tr></table>';
250 if ($action ==
'editdate_trans' && $permissiontosend) {
251 print
'<form name="setdate_trans" action="'.$_SERVER[
"PHP_SELF"].
'?id='.
$object->id.
'" method="post">';
252 print
'<input type="hidden" name="token" value="'.newToken().
'">';
253 print
'<input type="hidden" name="action" value="setdate_trans">';
254 print $form->selectDate(
$object->date_trans ?
$object->date_trans : -1,
'date_trans', 0, 0, 0,
"setdate_trans");
255 print
'<input type="submit" class="button button-edit smallpaddingimp valign middle" value="'.$langs->trans(
'Modify').
'">';
259 print
' <span class="opacitymedium">'.$langs->trans(
"By").
'</span> '.$muser->getNomUrl(-1).
'</td>';
265 print
'<tr><td>'.$langs->trans(
"TransMetod").
'</td><td>';
271 if (!empty(
$object->date_credit)) {
272 print
'<tr><td>'.$langs->trans(
'CreditDate').
'</td><td>';
281 print
'<div class="underbanner clearboth"></div>';
282 print
'<table class="border centpercent tableforfield">';
286 $fk_bank_account =
$object->fk_bank_account;
287 if (empty($fk_bank_account)) {
290 if ($fk_bank_account > 0) {
291 $result = $acc->fetch($fk_bank_account);
295 $labelofbankfield =
"BankToReceiveWithdraw";
296 if (
$object->type ==
'bank-transfer') {
297 $labelofbankfield =
'BankToPayCreditTransfer';
300 $caneditbank = $permissiontoadd;
301 if (
$object->status != $object::STATUS_DRAFT) {
313 print
'<tr><td class="titlefieldcreate">';
314 print
'<table class="nobordernopadding centpercent"><tr><td class="nowrap">';
315 print $form->textwithpicto($langs->trans(
"BankAccount"), $langs->trans($labelofbankfield));
317 if (($action !=
'editbankaccount') && $caneditbank) {
318 print
'<td class="right"><a class="editfielda" href="'.$_SERVER[
"PHP_SELF"].
'?action=editfkbankaccount&token='.
newToken().
'&id='.
$object->id.
'">'.
img_edit($langs->trans(
'SetBankAccount'), 1).
'</a></td>';
320 print
'</tr></table>';
322 if ($action ==
'editfkbankaccount') {
323 $form->formSelectAccount($_SERVER[
'PHP_SELF'].
'?id='.
$object->id, (
string) $fk_bank_account,
'fk_bank_account', 0);
325 $form->formSelectAccount($_SERVER[
'PHP_SELF'].
'?id='.
$object->id, (
string) $fk_bank_account,
'none');
331 print
'<tr><td class="titlefieldcreate">';
332 $labelfororderfield =
'WithdrawalFile';
333 if (
$object->type ==
'bank-transfer') {
334 $labelfororderfield =
'CreditTransferFile';
336 print $langs->trans($labelfororderfield).
'</td><td>';
338 $modulepart =
'prelevement';
339 if (
$object->type ==
'bank-transfer') {
340 $modulepart =
'paymentbybanktransfer';
343 if (isModEnabled(
'multicompany')) {
344 $labelentity =
$conf->entity;
345 $relativepath =
'receipts/'.$object->ref.
'-'.$labelentity.
'.xml';
347 if ($type !=
'bank-transfer') {
348 $dir =
$conf->prelevement->dir_output;
350 $dir =
$conf->paymentbybanktransfer->dir_output;
353 $relativepath =
'receipts/'.$object->ref.
'.xml';
356 $relativepath =
'receipts/'.$object->ref.
'.xml';
359 print
'<a data-ajax="false" href="'.DOL_URL_ROOT.
'/document.php?type=text/plain&modulepart='.$modulepart.
'&file='.urlencode($relativepath).
'">'.$relativepath;
360 print
img_picto(
'',
'download',
'class="paddingleft"');
365 $parameters = array();
366 $reshook = $hookmanager->executeHooks(
'formObjectOptions', $parameters,
$object, $action);
367 print $hookmanager->resPrint;
379 if ($action ==
'delete') {
380 $formconfirm = $form->formconfirm($_SERVER[
"PHP_SELF"].
'?id='.
$object->id, $langs->trans(
'Delete'), $langs->trans(
'ConfirmDeleteObject'),
'confirm_delete',
'', 0, 1);
393 if (empty(
$object->date_trans) && (($user->hasRight(
'prelevement',
'bons',
'send') &&
$object->type !=
'bank-transfer') || ($user->hasRight(
'paymentbybanktransfer',
'send') &&
$object->type ==
'bank-transfer')) && $action ==
'settransmitted') {
394 print
'<form method="post" name="userfile" action="card.php?id='.$object->id.
'" enctype="multipart/form-data">';
395 print
'<input type="hidden" name="token" value="'.newToken().
'">';
396 print
'<input type="hidden" name="action" value="infotrans">';
397 print
'<table class="noborder centpercent">';
398 print
'<tr class="liste_titre">';
399 print
'<td colspan="3">'.$langs->trans(
"NotifyTransmision").
'</td></tr>';
400 print
'<tr class="oddeven"><td>'.$langs->trans(
"TransData").
'</td><td>';
401 print $form->selectDate(
'',
'', 0, 0, 0,
"userfile", 1, 1);
403 print
'<tr class="oddeven"><td>'.$langs->trans(
"TransMetod").
'</td><td>';
404 print $form->selectarray(
"methode",
$object->methodes_trans);
407 print
'<div class="center"><input type="submit" class="button" value="'.dol_escape_htmltag($langs->trans(
"SetToStatusSent")).
'"></div>';
412 if (
$object->status == BonPrelevement::STATUS_TRANSFERED && (($user->hasRight(
'prelevement',
'bons',
'credit') &&
$object->type !=
'bank-transfer') || ($user->hasRight(
'paymentbybanktransfer',
'debit') &&
$object->type ==
'bank-transfer')) && $action ==
'setcredited') {
413 $btnLabel = (
$object->type ==
'bank-transfer') ? $langs->trans(
"ClassDebited") : $langs->trans(
"ClassCredited");
414 print
'<form name="infocredit" method="post" action="card.php?id='.$object->id.
'">';
415 print
'<input type="hidden" name="token" value="'.newToken().
'">';
416 print
'<input type="hidden" name="action" value="setinfocredit">';
417 print
'<table class="noborder centpercent">';
418 print
'<tr class="liste_titre">';
419 print
'<td colspan="3">'.$langs->trans(
"NotifyCredit").
'</td></tr>';
420 print
'<tr class="oddeven"><td>'.$langs->trans(
'CreditDate').
'</td><td>';
421 print $form->selectDate(-1,
'', 0, 0, 0,
"infocredit", 1, 1, 0,
'',
'', array(array(
'adddateof' =>
$object->date_trans,
'labeladddateof' => $langs->transnoentitiesnoconv(
'TransData'))));
424 print
'<br><div class="center"><span class="opacitymedium">'.$langs->trans(
"ThisWillAlsoAddPaymentOnInvoice").
'</span></div>';
425 print
'<div class="center"><input type="submit" class="button" value="'.dol_escape_htmltag($btnLabel).
'"></div>';
431 if ($action !=
'settransmitted' && $action !=
'setcredited') {
432 print
"\n".
'<div class="tabsAction">'.
"\n";
433 $parameters = array();
434 $reshook = $hookmanager->executeHooks(
'addMoreActionsButtons', $parameters,
$object, $action);
435 if (empty($reshook)) {
436 if (empty(
$object->date_trans)) {
437 if (
$object->type ==
'bank-transfer') {
438 print
dolGetButtonAction($langs->trans(
"SetToStatusSent"),
'',
'default',
'card.php?action=settransmitted&token='.newToken().
'&id='.
$object->id,
'', $user->hasRight(
'paymentbybanktransfer',
'send'));
440 print
dolGetButtonAction($langs->trans(
"SetToStatusSent"),
'',
'default',
'card.php?action=settransmitted&token='.newToken().
'&id='.
$object->id,
'', $user->hasRight(
'prelevement',
'bons',
'send'));
444 if (
$object->status == BonPrelevement::STATUS_TRANSFERED) {
445 if (
$object->type ==
'bank-transfer') {
446 print
dolGetButtonAction($langs->trans(
"ClassDebited"),
'',
'default',
'card.php?action=setcredited&token='.newToken().
'&id='.
$object->id,
'', $user->hasRight(
'paymentbybanktransfer',
'debit'));
448 print
dolGetButtonAction($langs->trans(
"ClassCredited"),
'',
'default',
'card.php?action=setcredited&token='.newToken().
'&id='.
$object->id,
'', $user->hasRight(
'prelevement',
'bons',
'credit'));
453 if (
$object->status == BonPrelevement::STATUS_DEBITED ||
$object->status == BonPrelevement::STATUS_CREDITED) {
454 if (
$object->type ==
'bank-transfer') {
455 print
dolGetButtonAction($langs->trans(
"ReOpen"),
'',
'default',
'card.php?action=reopen&token='.newToken().
'&id='.
$object->id,
'', $user->hasRight(
'paymentbybanktransfer',
'debit'));
457 print
dolGetButtonAction($langs->trans(
"ReOpen"),
'',
'default',
'card.php?action=reopen&token='.newToken().
'&id='.
$object->id,
'', $user->hasRight(
'prelevement',
'bons',
'credit'));
462 if (
$object->type ==
'bank-transfer') {
463 print
dolGetButtonAction($langs->trans(
"Delete"),
'',
'delete',
'card.php?action=delete&token='.newToken().
'&id='.
$object->id,
'', $user->hasRight(
'paymentbybanktransfer',
'create'));
465 print
dolGetButtonAction($langs->trans(
"Delete"),
'',
'delete',
'card.php?action=delete&token='.newToken().
'&id='.
$object->id,
'', $user->hasRight(
'prelevement',
'bons',
'creer'));
476 $sql =
"SELECT pl.rowid, pl.statut, pl.amount, pl.fk_user,";
477 $sql .=
" u.rowid as socid, u.login as name";
478 $sql .=
" FROM ".MAIN_DB_PREFIX.
"prelevement_lignes as pl";
479 $sql .=
", ".MAIN_DB_PREFIX.
"prelevement_bons as pb";
480 $sql .=
", ".MAIN_DB_PREFIX.
"user as u";
481 $sql .=
" WHERE pl.fk_prelevement_bons = ".((int) $id);
482 $sql .=
" AND pl.fk_prelevement_bons = pb.rowid";
483 $sql .=
" AND pb.entity = ".((int)
$conf->entity);
484 $sql .=
" AND pl.fk_user = u.rowid";
486 $sql .=
" AND u.rowid = ".((int) $socid);
488 $sql .= $db->order($sortfield, $sortorder);
490 $sql =
"SELECT pl.rowid, pl.statut, pl.amount,";
491 $sql .=
" s.rowid as socid, s.nom as name";
492 $sql .=
" FROM ".MAIN_DB_PREFIX.
"prelevement_lignes as pl";
493 $sql .=
", ".MAIN_DB_PREFIX.
"prelevement_bons as pb";
494 $sql .=
", ".MAIN_DB_PREFIX.
"societe as s";
495 $sql .=
" WHERE pl.fk_prelevement_bons = ".((int) $id);
496 $sql .=
" AND pl.fk_prelevement_bons = pb.rowid";
497 $sql .=
" AND pb.entity = ".((int)
$conf->entity);
498 $sql .=
" AND pl.fk_soc = s.rowid";
500 $sql .=
" AND s.rowid = ".((int) $socid);
502 $sql .= $db->order($sortfield, $sortorder);
505 $nbtotalofrecords =
'';
507 $result = $db->query($sql);
508 $nbtotalofrecords = $db->num_rows($result);
509 if (($page * $limit) > $nbtotalofrecords) {
516 $sql .= $db->plimit($limit + 1, $offset);
518 $result = $db->query($sql);
521 $num = $db->num_rows($result);
524 $urladd =
"&id=".urlencode((
string) (
$id));
525 if ($limit > 0 && $limit !=
$conf->liste_limit) {
526 $urladd .=
'&limit='.((int) $limit);
529 print
'<form method="POST" action="'.$_SERVER [
'PHP_SELF'].
'" name="search_form">'.
"\n";
530 print
'<input type="hidden" name="token" value="'.newToken().
'"/>';
531 print
'<input type="hidden" name="id" value="'.$id.
'"/>';
532 print
'<input type="hidden" name="socid" value="'.$socid.
'"/>';
534 print
'<input type="hidden" name="page" value="'.$page.
'"/>';
536 if (!empty($limit)) {
537 print
'<input type="hidden" name="limit" value="'.$limit.
'"/>';
539 if (!empty($sortfield)) {
540 print
'<input type="hidden" name="sortfield" value="'.$sortfield.
'"/>';
542 if (!empty($sortorder)) {
543 print
'<input type="hidden" name="sortorder" value="'.$sortorder.
'"/>';
546 print_barre_liste($langs->trans(
"Lines"), $page, $_SERVER[
"PHP_SELF"], $urladd, $sortfield, $sortorder,
'', $num, $nbtotalofrecords,
'', 0,
'',
'', $limit);
548 print
'<div class="div-table-responsive-no-min">';
549 print
'<table class="noborder liste centpercent">';
550 print
'<tr class="liste_titre">';
552 print_liste_field_titre((!$salaryBonPl ?
"ThirdParty" :
"Employee"), $_SERVER[
"PHP_SELF"],
"s.nom",
'', $urladd,
'', $sortfield, $sortorder);
553 print_liste_field_titre(
"Amount", $_SERVER[
"PHP_SELF"],
"pl.amount",
"", $urladd,
'class="right"', $sortfield, $sortorder);
559 while ($i < min($num, $limit)) {
560 $obj = $db->fetch_object($result);
562 print
'<tr class="oddeven">';
566 print
'<a class="valignmiddle" href="'.DOL_URL_ROOT.
'/compta/prelevement/line.php?id='.$obj->rowid.
'&type='.
$object->type.
'&token='.
newToken().
'">';
567 print $ligne->LibStatut($obj->statut, 2);
568 print
'<span class="paddingleft">'.$obj->rowid.
'</span>';
571 $thirdparty =
new Societe($db);
572 $thirdparty->fetch($obj->socid);
573 $name = $thirdparty->getNomUrl(1);
575 $userSalary =
new User($db);
576 $userSalary->fetch($obj->fk_user);
577 $name = $userSalary->getNomUrl(-1);
579 print
'<td class="tdoverflowmax150">';
583 print
'<td class="right"><span class="amount">'.price($obj->amount).
"</span></td>\n";
585 print
'<td class="right">';
587 if ($obj->statut == 3) {
588 print
'<span class="error">'.$langs->trans(
"StatusRefused").
'</span>';
590 if (
$object->statut == BonPrelevement::STATUS_CREDITED) {
591 if ($obj->statut == LignePrelevement::STATUS_CREDITED) {
592 if ($user->hasRight(
'prelevement',
'bons',
'credit')) {
594 print
'<a href="line.php?action=rejet&type='.$object->type.
'&id='.$obj->rowid.
'&token='.
newToken().
'">'.$langs->trans(
"StandingOrderReject").
'</a>';
606 $total += $obj->amount;
614 print
'<tr class="liste_total">';
615 print
'<td>'.$langs->trans(
"Total").
'</td>';
616 print
'<td> </td>';
617 print
'<td class="right">';
618 if (empty($offset) && $num <= $limit) {
620 if ($total !=
$object->amount) {
621 print
img_warning($langs->trans(
"TotalAmountOfdirectDebitOrderDiffersFromSumOfLines"));
626 print
'<td> </td>';
$id
Support class for third parties, contacts, members, users or resources.
if( $user->socid > 0) if(! $user->hasRight('accounting', 'chartofaccount')) $object
llxFooter($comment='', $zone='private', $disabledoutputofmessages=0)
Empty footer.
if(!defined('NOREQUIRESOC')) if(!defined( 'NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined( 'NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined( 'NOREQUIREAJAX')) llxHeader($head='', $title='', $help_url='', $target='', $disablejs=0, $disablehead=0, $arrayofjs='', $arrayofcss='', $morequerystring='', $morecssonbody='', $replacemainareaby='', $disablenofollow=0, $disablenoindex=0)
Empty header.
Class to manage bank accounts.
Class to manage withdrawal receipts.
Class to manage withdrawals.
Class to manage third parties objects (customers, suppliers, prospects...)
Class to manage Dolibarr users.
dol_is_file($pathoffile)
Return if path is a file.
recordNotFound($message='', $printheader=1, $printfooter=1, $showonlymessage=0, $params=null)
Displays an error page when a record is not found.
dol_mktime($hour, $minute, $second, $month, $day, $year, $gm='auto', $check=1)
Return a timestamp date built from detailed information (by default a local PHP server timestamp) Rep...
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='', $noduplicate=0, $attop=0)
Set event messages in dol_events session object.
print_liste_field_titre($name, $file="", $field="", $begin="", $param="", $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, $selectlimitsuffix=0, $hidenavigation=0, $pagenavastextinput=0, $morehtmlrightbeforearrow='')
Print a title with navigation controls for pagination.
img_picto($titlealt, $picto, $moreatt='', $pictoisfullpath=0, $srconly=0, $notitle=0, $alt='', $morecss='', $marginleftonlyshort=2, $allowothertags=array())
Show picto whatever it's its name (generic function)
img_warning($titlealt='default', $moreatt='', $morecss='pictowarning')
Show warning logo.
GETPOSTINT($paramname, $method=0)
Return the value of a $_GET or $_POST supervariable, converted into integer.
dol_get_fiche_head($links=array(), $active='', $title='', $notab=0, $picto='', $pictoisfullpath=0, $morehtmlright='', $morecss='', $limittoshow=0, $moretabssuffix='', $dragdropfile=0, $morecssdiv='')
Show tabs of a record.
price2num($amount, $rounding='', $option=0)
Function that return a number with universal decimal format (decimal separator is '.
dol_get_fiche_end($notab=0)
Return tab footer of a card.
price($amount, $form=0, $outlangs='', $trunc=1, $rounding=-1, $forcerounding=-1, $currency_code='')
Function to format a value into an amount for visual output Function used into PDF and HTML pages.
getDolGlobalInt($key, $default=0)
Return a Dolibarr global constant int value.
dol_print_date($time, $format='', $tzoutput='auto', $outputlangs=null, $encodetooutput=false)
Output date in a string format according to outputlangs (or langs if not defined).
newToken()
Return the value of token currently saved into session with name 'newtoken'.
dolGetButtonAction($label, $text='', $actionType='default', $url='', $id='', $userRight=1, $params=array())
Function dolGetButtonAction.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
dol_clone($object, $native=2)
Create a clone of instance of object (new instance with same value for each properties) With native =...
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 a Dolibarr global constant string value.
img_edit($titlealt='default', $float=0, $other='')
Show logo edit/modify fiche.
global $conf
The following vars must be defined: $type2label $form $conf, $lang, The following vars may also be de...
prelevement_prepare_head(BonPrelevement $object)
Prepare array with list of tabs.
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.