27 if (!defined(
'NOLOGIN')) {
30 if (!defined(
'NOCSRFCHECK')) {
31 define(
"NOCSRFCHECK", 1);
33 if (!defined(
'NOIPCHECK')) {
34 define(
'NOIPCHECK',
'1');
36 if (!defined(
'NOBROWSERNOTIF')) {
37 define(
'NOBROWSERNOTIF',
'1');
43 $entity = (!empty($_GET[
'entity']) ? (int) $_GET[
'entity'] : (!empty($_POST[
'entity']) ? (int) $_POST[
'entity'] : 1));
44 if (is_numeric($entity)) {
45 define(
"DOLENTITY", $entity);
49 require
'../../main.inc.php';
50 require_once DOL_DOCUMENT_ROOT.
'/core/lib/company.lib.php';
51 require_once DOL_DOCUMENT_ROOT.
'/core/lib/payments.lib.php';
52 require_once DOL_DOCUMENT_ROOT.
'/core/lib/files.lib.php';
53 require_once DOL_DOCUMENT_ROOT.
'/core/lib/functions2.lib.php';
54 require_once DOL_DOCUMENT_ROOT.
'/product/class/product.class.php';
57 $langs->loadLangs(array(
"main",
"other",
"dict",
"bills",
"companies",
"errors",
"members",
"paybox",
"propal",
"commercial"));
63 $action =
GETPOST(
'action',
'aZ09');
64 $cancel =
GETPOST(
'cancel',
'alpha');
65 $confirm =
GETPOST(
'confirm',
'alpha');
68 $refusepropal =
GETPOST(
'refusepropal',
'alpha');
69 $message =
GETPOST(
'message',
'aZ09');
78 $suffix =
GETPOST(
"suffix",
'aZ09');
79 $source =
GETPOST(
"source",
'alpha');
80 $ref = $REF =
GETPOST(
"ref",
'alpha');
88 if (!empty($refusepropal)) {
89 $action =
"refusepropal";
95 $urlwithroot = DOL_MAIN_URL_ROOT;
99 $SECUREKEY =
GETPOST(
"securekey");
101 if (!empty($source)) {
102 $urlok .=
'source='.urlencode($source).
'&';
103 $urlko .=
'source='.urlencode($source).
'&';
106 $urlok .=
'ref='.urlencode($REF).
'&';
107 $urlko .=
'ref='.urlencode($REF).
'&';
109 if (!empty($SECUREKEY)) {
110 $urlok .=
'securekey='.urlencode($SECUREKEY).
'&';
111 $urlko .=
'securekey='.urlencode($SECUREKEY).
'&';
113 if (!empty($entity)) {
114 $urlok .=
'entity='.urlencode($entity).
'&';
115 $urlko .=
'entity='.urlencode($entity).
'&';
117 $urlok = preg_replace(
'/&$/',
'', $urlok);
118 $urlko = preg_replace(
'/&$/',
'', $urlko);
120 $creditor = $mysoc->name;
125 if ($source && !$ref) {
132 if ($source ==
'proposal') {
134 } elseif ($source ==
'contract') {
136 } elseif ($source ==
'fichinter') {
139 if (!
dol_verifyHash($securekeyseed.$type.$ref.(isModEnabled(
'multicompany') ? $entity :
''), $SECUREKEY,
'0')) {
143 if ($source ==
'proposal') {
144 require_once DOL_DOCUMENT_ROOT.
'/comm/propal/class/propal.class.php';
145 $object =
new Propal($db);
146 $result= $object->fetch(0, $ref,
'', $entity);
147 } elseif ($source ==
'contract') {
148 require_once DOL_DOCUMENT_ROOT.
'/contrat/class/contrat.class.php';
150 $result= $object->fetch(0, $ref);
151 } elseif ($source ==
'fichinter') {
152 require_once DOL_DOCUMENT_ROOT.
'/fichinter/class/fichinter.class.php';
154 $result= $object->fetch(0, $ref);
164 if ($action ==
'confirm_refusepropal' && $confirm ==
'yes') {
167 $sql =
"UPDATE ".MAIN_DB_PREFIX.
"propal";
168 $sql .=
" SET fk_statut = ".((int) $object::STATUS_NOTSIGNED).
", note_private = '".$db->escape($object->note_private).
"', date_signature='".$db->idate(
dol_now()).
"'";
169 $sql .=
" WHERE rowid = ".((int) $object->id);
172 $resql = $db->query($sql);
180 $message =
'refused';
182 if (method_exists($object,
'call_trigger')) {
184 $user =
new User($db);
185 $user->fetch($object->user_valid_id);
186 $object->context = array(
'closedfromonlinesignature' =>
'closedfromonlinesignature');
187 $result = $object->call_trigger(
'PROPAL_CLOSE_REFUSED', $user);
196 $object->fetch(0, $ref);
206 if (!empty($conf->global->MAIN_SIGN_CSS_URL)) {
207 $head =
'<link rel="stylesheet" type="text/css" href="'.$conf->global->MAIN_SIGN_CSS_URL.
'?lang='.$langs->defaultlang.
'">'.
"\n";
210 $conf->dol_hide_topmenu = 1;
211 $conf->dol_hide_leftmenu = 1;
213 $replacemainarea = (empty($conf->dol_hide_leftmenu) ?
'<div>' :
'').
'<div>';
214 llxHeader($head, $langs->trans(
"OnlineSignature"),
'',
'', 0, 0,
'',
'',
'',
'onlinepaymentbody', $replacemainarea, 1);
216 if ($action ==
'refusepropal') {
217 print
$form->formconfirm($_SERVER[
"PHP_SELF"].
'?ref='.urlencode($ref).
'&securekey='.urlencode($SECUREKEY).(
isModEnabled(
'multicompany')?
'&entity='.$entity:
''), $langs->trans(
'RefusePropal'), $langs->trans(
'ConfirmRefusePropal', $object->ref),
'confirm_refusepropal',
'',
'', 1);
221 if (!empty($source) && in_array($ref, array(
'member_ref',
'contractline_ref',
'invoice_ref',
'order_ref',
'proposal_ref',
''))) {
222 $langs->load(
"errors");
223 dol_print_error_email(
'BADREFINONLINESIGNFORM', $langs->trans(
"ErrorBadLinkSourceSetButBadValueForRef", $source, $ref));
230 print
'<span id="dolpaymentspan"></span>'.
"\n";
231 print
'<div class="center">'.
"\n";
232 print
'<form id="dolpaymentform" class="center" name="paymentform" action="'.$_SERVER[
"PHP_SELF"].
'" method="POST">'.
"\n";
233 print
'<input type="hidden" name="token" value="'.newToken().
'">'.
"\n";
234 print
'<input type="hidden" name="action" value="dosign">'.
"\n";
235 print
'<input type="hidden" name="tag" value="'.GETPOST(
"tag",
'alpha').
'">'.
"\n";
236 print
'<input type="hidden" name="suffix" value="'.GETPOST(
"suffix",
'alpha').
'">'.
"\n";
237 print
'<input type="hidden" name="securekey" value="'.$SECUREKEY.
'">'.
"\n";
238 print
'<input type="hidden" name="entity" value="'.$entity.
'" />';
239 print
'<input type="hidden" name="page_y" value="" />';
241 print
'<!-- Form to sign -->'.
"\n";
243 print
'<table id="dolpublictable" summary="Payment form" class="center">'.
"\n";
247 $logosmall = $mysoc->logo_small;
248 $logo = $mysoc->logo;
249 $paramlogo =
'ONLINE_SIGN_LOGO_'.$suffix;
250 if (!empty($conf->global->$paramlogo)) {
251 $logosmall = $conf->global->$paramlogo;
252 } elseif (!empty($conf->global->ONLINE_SIGN_LOGO)) {
253 $logosmall = $conf->global->ONLINE_SIGN_LOGO;
259 if (!empty($logosmall) && is_readable($conf->mycompany->dir_output.
'/logos/thumbs/'.$logosmall)) {
260 $urllogo = DOL_URL_ROOT.
'/viewimage.php?modulepart=mycompany&entity='.$conf->entity.
'&file='.urlencode(
'logos/thumbs/'.$logosmall);
261 $urllogofull = $dolibarr_main_url_root.
'/viewimage.php?modulepart=mycompany&entity='.$conf->entity.
'&file='.urlencode(
'logos/thumbs/'.$logosmall);
262 } elseif (!empty($logo) && is_readable($conf->mycompany->dir_output.
'/logos/'.$logo)) {
263 $urllogo = DOL_URL_ROOT.
'/viewimage.php?modulepart=mycompany&entity='.$conf->entity.
'&file='.urlencode(
'logos/'.$logo);
264 $urllogofull = $dolibarr_main_url_root.
'/viewimage.php?modulepart=mycompany&entity='.$conf->entity.
'&file='.urlencode(
'logos/'.$logo);
268 print
'<div class="backgreypublicpayment">';
269 print
'<div class="logopublicpayment">';
270 print
'<img id="dolpaymentlogo" src="'.$urllogo.
'"';
273 if (empty($conf->global->MAIN_HIDE_POWERED_BY)) {
274 print
'<div class="poweredbypublicpayment opacitymedium right"><a class="poweredbyhref" href="https://www.dolibarr.org?utm_medium=website&utm_source=poweredby" target="dolibarr" rel="noopener">'.$langs->trans(
"PoweredBy").
'<br><img class="poweredbyimg" src="'.DOL_URL_ROOT.
'/theme/dolibarr_logo.svg" width="80px"></a></div>';
278 if ($source ==
'proposal' && !empty($conf->global->PROPOSAL_IMAGE_PUBLIC_SIGN)) {
279 print
'<div class="backimagepublicproposalsign">';
280 print
'<img id="idPROPOSAL_IMAGE_PUBLIC_INTERFACE" src="'.$conf->global->PROPOSAL_IMAGE_PUBLIC_SIGN.
'">';
286 if (!empty($conf->global->ONLINE_SIGN_NEWFORM_TEXT)) {
288 if (preg_match(
'/^\((.*)\)$/', $conf->global->ONLINE_SIGN_NEWFORM_TEXT, $reg)) {
289 $text .= $langs->trans($reg[1]).
"<br>\n";
291 $text .= $conf->global->ONLINE_SIGN_NEWFORM_TEXT.
"<br>\n";
293 $text =
'<tr><td align="center"><br>'.$text.
'<br></td></tr>'.
"\n";
296 if ($source ==
'proposal') {
297 $text .=
'<tr><td class="textpublicpayment"><br><strong>'.$langs->trans(
"WelcomeOnOnlineSignaturePageProposal", $mysoc->name).
'</strong></td></tr>'.
"\n";
298 $text .=
'<tr><td class="textpublicpayment opacitymedium">'.$langs->trans(
"ThisScreenAllowsYouToSignDocFromProposal", $creditor).
'<br><br></td></tr>'.
"\n";
299 } elseif ($source ==
'contract') {
300 $text .=
'<tr><td class="textpublicpayment"><br><strong>'.$langs->trans(
"WelcomeOnOnlineSignaturePageContract", $mysoc->name).
'</strong></td></tr>'.
"\n";
301 $text .=
'<tr><td class="textpublicpayment opacitymedium">'.$langs->trans(
"ThisScreenAllowsYouToSignDocFromContract", $creditor).
'<br><br></td></tr>'.
"\n";
302 } elseif ($source ==
'fichinter') {
303 $text .=
'<tr><td class="textpublicpayment"><br><strong>'.$langs->trans(
"WelcomeOnOnlineSignaturePageFichinter", $mysoc->name).
'</strong></td></tr>'.
"\n";
304 $text .=
'<tr><td class="textpublicpayment opacitymedium">'.$langs->trans(
"ThisScreenAllowsYouToSignDocFromFichinter", $creditor).
'<br><br></td></tr>'.
"\n";
310 print
'<tr><td align="center">';
311 print
'<table with="100%" id="tablepublicpayment">';
312 if ($source ==
'proposal') {
313 print
'<tr><td align="left" colspan="2" class="opacitymedium">'.$langs->trans(
"ThisIsInformationOnDocumentToSignProposal").
' :</td></tr>'.
"\n";
314 } elseif ($source ==
'contract') {
315 print
'<tr><td align="left" colspan="2" class="opacitymedium">'.$langs->trans(
"ThisIsInformationOnDocumentToSignContract").
' :</td></tr>'.
"\n";
316 } elseif ($source ==
'fichinter') {
317 print
'<tr><td align="left" colspan="2" class="opacitymedium">'.$langs->trans(
"ThisIsInformationOnDocumentToSignFichinter").
' :</td></tr>'.
"\n";
323 if ($source ==
'proposal') {
325 $langs->load(
"proposal");
327 $result = $object->fetch_thirdparty($object->socid);
330 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"Creditor");
331 print
'</td><td class="CTableRow2">';
332 print
img_picto(
'',
'company',
'class="pictofixedwidth"');
333 print
'<b>'.$creditor.
'</b>';
334 print
'<input type="hidden" name="creditor" value="'.$creditor.
'">';
335 print
'</td></tr>'.
"\n";
338 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"ThirdParty");
339 print
'</td><td class="CTableRow2">';
340 print
img_picto(
'',
'company',
'class="pictofixedwidth"');
341 print
'<b>'.$object->thirdparty->name.
'</b>';
342 print
'</td></tr>'.
"\n";
345 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"Amount");
346 print
'</td><td class="CTableRow2">';
347 print
'<b>'.price($object->total_ttc, 0, $langs, 1, -1, -1, $conf->currency).
'</b>';
348 print
'</td></tr>'.
"\n";
351 $text =
'<b>'.$langs->trans(
"SignatureProposalRef", $object->ref).
'</b>';
352 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"Designation");
353 print
'</td><td class="CTableRow2">'.$text;
355 $last_main_doc_file = $object->last_main_doc;
357 if ($object->status == $object::STATUS_VALIDATED) {
358 if (empty($last_main_doc_file) || !
dol_is_file(DOL_DATA_ROOT.
'/'.$object->last_main_doc)) {
361 $defaulttemplate =
'';
362 $object->generateDocument($defaulttemplate, $langs);
365 $directdownloadlink = $object->getLastMainDocLink(
'proposal');
366 if ($directdownloadlink) {
367 print
'<br><a href="'.$directdownloadlink.
'">';
368 print
img_mime($object->last_main_doc,
'');
369 print $langs->trans(
"DownloadDocument").
'</a>';
372 if ($object->status == $object::STATUS_NOTSIGNED) {
373 $directdownloadlink = $object->getLastMainDocLink(
'proposal');
374 if ($directdownloadlink) {
375 print
'<br><a href="'.$directdownloadlink.
'">';
376 print
img_mime($last_main_doc_file,
'');
377 print $langs->trans(
"DownloadDocument").
'</a>';
379 } elseif ($object->status == $object::STATUS_SIGNED || $object->status == $object::STATUS_BILLED) {
380 if (preg_match(
'/_signed-(\d+)/', $last_main_doc_file)) {
381 $last_main_doc_file_not_signed = preg_replace(
'/_signed-(\d+)/',
'', $last_main_doc_file);
384 $datefilenotsigned =
dol_filemtime($last_main_doc_file_not_signed);
386 if (empty($datefilenotsigned) || $datefilesigned > $datefilenotsigned) {
387 $directdownloadlink = $object->getLastMainDocLink(
'proposal');
388 if ($directdownloadlink) {
389 print
'<br><a href="'.$directdownloadlink.
'">';
390 print
img_mime($object->last_main_doc,
'');
391 print $langs->trans(
"DownloadDocument").
'</a>';
398 print
'<input type="hidden" name="source" value="'.GETPOST(
"source",
'alpha').
'">';
399 print
'<input type="hidden" name="ref" value="'.$object->ref.
'">';
400 print
'</td></tr>'.
"\n";
401 } elseif ($source ==
'contract') {
403 $langs->load(
"contract");
405 $result = $object->fetch_thirdparty($object->socid);
408 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"Proposer");
409 print
'</td><td class="CTableRow2">';
410 print
img_picto(
'',
'company',
'class="pictofixedwidth"');
411 print
'<b>'.$creditor.
'</b>';
412 print
'<input type="hidden" name="creditor" value="'.$creditor.
'">';
413 print
'</td></tr>'.
"\n";
416 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"ThirdParty");
417 print
'</td><td class="CTableRow2">';
418 print
img_picto(
'',
'company',
'class="pictofixedwidth"');
419 print
'<b>'.$object->thirdparty->name.
'</b>';
420 print
'</td></tr>'.
"\n";
423 $text =
'<b>'.$langs->trans(
"SignatureContractRef", $object->ref).
'</b>';
424 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"Designation");
425 print
'</td><td class="CTableRow2">'.$text;
427 $last_main_doc_file = $object->last_main_doc;
429 if (empty($last_main_doc_file) || !
dol_is_file(DOL_DATA_ROOT.
'/'.$object->last_main_doc)) {
432 $defaulttemplate =
'';
433 $object->generateDocument($defaulttemplate, $langs);
436 $directdownloadlink = $object->getLastMainDocLink(
'contract');
437 if ($directdownloadlink) {
438 print
'<br><a href="'.$directdownloadlink.
'">';
439 print
img_mime($object->last_main_doc,
'');
440 if ($message ==
"signed") {
441 print $langs->trans(
"DownloadSignedDocument").
'</a>';
443 print $langs->trans(
"DownloadDocument").
'</a>';
448 print
'<input type="hidden" name="source" value="'.GETPOST(
"source",
'alpha').
'">';
449 print
'<input type="hidden" name="ref" value="'.$object->ref.
'">';
450 print
'</td></tr>'.
"\n";
451 } elseif ($source ==
'fichinter') {
453 $langs->load(
"fichinter");
455 $result = $object->fetch_thirdparty($object->socid);
457 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"Proposer");
458 print
'</td><td class="CTableRow2">';
459 print
img_picto(
'',
'company',
'class="pictofixedwidth"');
460 print
'<b>'.$creditor.
'</b>';
461 print
'<input type="hidden" name="creditor" value="'.$creditor.
'">';
462 print
'</td></tr>'.
"\n";
465 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"ThirdParty");
466 print
'</td><td class="CTableRow2">';
467 print
img_picto(
'',
'company',
'class="pictofixedwidth"');
468 print
'<b>'.$object->thirdparty->name.
'</b>';
469 print
'</td></tr>'.
"\n";
472 $text =
'<b>'.$langs->trans(
"SignatureFichinterRef", $object->ref).
'</b>';
473 print
'<tr class="CTableRow2"><td class="CTableRow2">'.$langs->trans(
"Designation");
474 print
'</td><td class="CTableRow2">'.$text;
476 $last_main_doc_file = $object->last_main_doc;
478 if (empty($last_main_doc_file) || !
dol_is_file(DOL_DATA_ROOT.
'/'.$object->last_main_doc)) {
481 $defaulttemplate =
'';
482 $object->generateDocument($defaulttemplate, $langs);
485 $directdownloadlink = $object->getLastMainDocLink(
'fichinter');
486 if ($directdownloadlink) {
487 print
'<br><a href="'.$directdownloadlink.
'">';
488 print
img_mime($object->last_main_doc,
'');
489 if ($message ==
"signed") {
490 print $langs->trans(
"DownloadSignedDocument").
'</a>';
492 print $langs->trans(
"DownloadDocument").
'</a>';
497 print
'<input type="hidden" name="source" value="'.GETPOST(
"source",
'alpha').
'">';
498 print
'<input type="hidden" name="ref" value="'.$object->ref.
'">';
499 print
'</td></tr>'.
"\n";
503 if (!$found && !$mesg) {
504 $mesg = $langs->transnoentitiesnoconv(
"ErrorBadParameters");
508 print
'<tr><td class="center" colspan="2"><br><div class="warning">'.dol_escape_htmltag($mesg).
'</div></td></tr>'.
"\n";
511 print
'</table>'.
"\n";
514 if ($action !=
'dosign') {
515 if ($found && !$error) {
524 print
'</td></tr>'.
"\n";
525 print
'<tr><td class="center">';
528 if ($action ==
"dosign" && empty($cancel)) {
529 print
'<div class="tablepublicpayment">';
530 print
'<input type="button" class="buttonDelete small" id="clearsignature" value="'.$langs->trans(
"ClearSignature").
'">';
531 print
'<div id="signature" style="border:solid;"></div>';
534 print
'<input type="button" class="button" id="signbutton" value="'.$langs->trans(
"Sign").
'">';
535 print
'<input type="submit" class="button" name="cancel" value="'.$langs->trans(
"Cancel").
'">';
538 print
'<script language="JavaScript" type="text/javascript" src="'.DOL_URL_ROOT.
'/includes/jquery/plugins/jSignature/jSignature.js"></script>
539 <script type="text/javascript">
540 $(document).ready(function() {
541 $("#signature").jSignature({ color:"#000", lineWidth:4, '.(empty($conf->dol_optimize_smallscreen) ?
'' :
'width: 280, ' ).
'height: 180});
543 $("#signature").on("change",function(){
544 $("#clearsignature").css("display","");
545 $("#signbutton").attr("disabled",false);
546 if(!$._data($("#signbutton")[0], "events")){
547 $("#signbutton").on("click",function(){
548 console.log("We click on button sign");
549 $("#signbutton").val(\''.
dol_escape_js($langs->transnoentities(
'PleaseBePatient')).
'\');
550 var signature = $(
"#signature").jSignature(
"getData",
"image");
553 url:
"'.DOL_URL_ROOT.'/core/ajax/onlineSign.php",
556 "action" :
"importSignature",
557 "token" : \
''.newToken().
'\',
558 "signaturebase64" : signature,
559 "ref" : \
''.dol_escape_js($REF).
'\',
560 "securekey" : \
''.dol_escape_js($SECUREKEY).
'\',
561 "mode" : \
''.dol_escape_htmltag($source).
'\',
562 "entity" : \
''.dol_escape_htmltag($entity).
'\',
564 success:
function(response) {
565 if(response ==
"success"){
566 console.log(
"Success on saving signature");
567 window.location.replace(
"'.$_SERVER["PHP_SELF
"].'?ref='.urlencode($ref).'&source='.urlencode($source).'&message=signed&securekey='.urlencode($SECUREKEY).(isModEnabled('multicompany')?'&entity='.$entity:'').'");
569 console.error(response);
577 $(
"#clearsignature").on(
"click",
function(){
578 $(
"#signature").jSignature(
"clear");
579 $(
"#signbutton").attr(
"disabled",
true);
582 $(
"#signbutton").attr(
"disabled",
true);
586 if ($source == 'proposal
') {
587 if ($object->status == $object::STATUS_SIGNED) {
589 if ($message == 'signed') {
590 print '<span
class=
"ok">
'.$langs->trans("PropalSigned").'</span>
';
592 print '<span
class=
"ok">
'.$langs->trans("PropalAlreadySigned").'</span>
';
594 } elseif ($object->status == $object::STATUS_NOTSIGNED) {
596 if ($message == 'refused
') {
597 print '<span
class=
"ok">
'.$langs->trans("PropalRefused").'</span>
';
599 print '<span
class=
"warning">
'.$langs->trans("PropalAlreadyRefused").'</span>
';
602 print '<input
type=
"submit" class=
"butAction small wraponsmartphone marginbottomonly marginleftonly marginrightonly reposition" value=
"'.$langs->trans("SignPropal
").'">
';
603 print '<input
name=
"refusepropal" type=
"submit" class=
"butActionDelete small wraponsmartphone marginbottomonly marginleftonly marginrightonly reposition" value=
"'.$langs->trans("RefusePropal
").'">
';
605 } elseif ($source == 'contract
') {
606 if ($message == 'signed') {
607 print '<span
class=
"ok">
'.$langs->trans("ContractSigned").'</span>
';
609 print '<input
type=
"submit" class=
"butAction small wraponsmartphone marginbottomonly marginleftonly marginrightonly reposition" value=
"'.$langs->trans("SignContract
").'">
';
611 } elseif ($source == 'fichinter
') {
612 if ($message == 'signed') {
613 print '<span
class=
"ok">
'.$langs->trans("FichinterSigned").'</span>
';
615 print '<input
type=
"submit" class=
"butAction small wraponsmartphone marginbottomonly marginleftonly marginrightonly reposition" value=
"'.$langs->trans("SignFichinter
").'">
';
619 print '</td></tr>
'."\n";
620 print '</table>
'."\n";
621 print '</form>
'."\n";
626 htmlPrintOnlinePaymentFooter($mysoc, $langs);
628 llxFooter('', 'public');
if(!defined('NOREQUIRESOC')) if(!defined('NOREQUIRETRAN')) if(!defined('NOTOKENRENEWAL')) if(!defined('NOREQUIREMENU')) if(!defined('NOREQUIREHTML')) if(!defined('NOREQUIREAJAX')) llxHeader()
Empty header.
Class to manage contracts.
Class to manage interventions.
Class to manage proposals.
Class to manage Dolibarr users.
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.
dol_filemtime($pathoffile)
Return time of a file.
dol_is_file($pathoffile)
Return if path is a file.
dol_escape_htmltag($stringtoescape, $keepb=0, $keepn=0, $noescapetags='', $escapeonlyhtmltags=0)
Returns text escaped for inclusion in HTML alt or title tags, or into values of HTML input fields.
setEventMessages($mesg, $mesgs, $style='mesgs', $messagekey='')
Set event messages in dol_events session object.
dol_now($mode='auto')
Return date for now.
img_mime($file, $titlealt='', $morecss='')
Show MIME img of a file.
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_escape_js($stringtoescape, $mode=0, $noescapebackslashn=0)
Returns text escaped for inclusion into javascript code.
GETPOST($paramname, $check='alphanohtml', $method=0, $filter=null, $options=null, $noreplace=0)
Return value of a param into GET or POST supervariable.
dol_print_error_email($prefixcode, $errormessage='', $errormessages=array(), $morecss='error', $email='')
Show a public email and error code to contact if technical error.
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.
if(preg_match('/crypted:/i', $dolibarr_main_db_pass)||!empty($dolibarr_main_db_encrypted_pass)) $conf db type
$conf db name
Only used if Module[ID]Name translation string is not found.
dol_verifyHash($chain, $hash, $type='0')
Compute a hash and compare it to the given one For backward compatibility reasons,...
httponly_accessforbidden($message=1, $http_response_code=403, $stringalreadysanitized=0)
Show a message to say access is forbidden and stop program.