|
@@ -135,13 +135,13 @@ discard block |
|
|
block discarded – undo |
135
|
135
|
if ($invoiceid > 0) { |
136
|
136
|
$ret = $invoice->fetch($invoiceid); |
137
|
137
|
} else { |
138
|
|
- $ret = $invoice->fetch('', '(PROV-POS'. (isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : '') .'-'.$place.')'); |
|
138
|
+ $ret = $invoice->fetch('', '(PROV-POS'.(isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : '').'-'.$place.')'); |
139
|
139
|
} |
140
|
140
|
if ($ret > 0) { |
141
|
141
|
$placeid = $invoice->id; |
142
|
142
|
} |
143
|
143
|
|
144
|
|
-$constforcompanyid = 'CASHDESK_ID_THIRDPARTY'. (isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : ''); |
|
144
|
+$constforcompanyid = 'CASHDESK_ID_THIRDPARTY'.(isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : ''); |
145
|
145
|
|
146
|
146
|
$soc = new Societe($db); |
147
|
147
|
if ($invoice->socid > 0) { |
|
@@ -162,8 +162,8 @@ discard block |
|
|
block discarded – undo |
162
|
162
|
* Actions |
163
|
163
|
*/ |
164
|
164
|
|
165
|
|
-$parameters=array(); |
166
|
|
-$reshook=$hookmanager->executeHooks('doActions', $parameters, $invoice, $action); // Note that $action and $object may have been modified by some hooks |
|
165
|
+$parameters = array(); |
|
166
|
+$reshook = $hookmanager->executeHooks('doActions', $parameters, $invoice, $action); // Note that $action and $object may have been modified by some hooks |
167
|
167
|
if ($reshook < 0) { |
168
|
168
|
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); |
169
|
169
|
} |
|
@@ -178,9 +178,9 @@ discard block |
|
|
block discarded – undo |
178
|
178
|
$bankaccount = GETPOSTINT('accountid'); |
179
|
179
|
} else { |
180
|
180
|
if ($pay == 'LIQ') { |
181
|
|
- $bankaccount = getDolGlobalInt('CASHDESK_ID_BANKACCOUNT_CASH'.$_SESSION["takeposterminal"]); // For backward compatibility |
|
181
|
+ $bankaccount = getDolGlobalInt('CASHDESK_ID_BANKACCOUNT_CASH'.$_SESSION["takeposterminal"]); // For backward compatibility |
182
|
182
|
} elseif ($pay == "CHQ") { |
183
|
|
- $bankaccount = getDolGlobalInt('CASHDESK_ID_BANKACCOUNT_CHEQUE'.$_SESSION["takeposterminal"]); // For backward compatibility |
|
183
|
+ $bankaccount = getDolGlobalInt('CASHDESK_ID_BANKACCOUNT_CHEQUE'.$_SESSION["takeposterminal"]); // For backward compatibility |
184
|
184
|
} else { |
185
|
185
|
$accountname = "CASHDESK_ID_BANKACCOUNT_".$pay.$_SESSION["takeposterminal"]; |
186
|
186
|
$bankaccount = getDolGlobalInt($accountname); |
|
@@ -240,9 +240,9 @@ discard block |
|
|
block discarded – undo |
240
|
240
|
$savconst = getDolGlobalString('STOCK_CALCULATE_ON_BILL'); |
241
|
241
|
|
242
|
242
|
if (isModEnabled('productbatch') && !getDolGlobalInt('CASHDESK_FORCE_DECREASE_STOCK')) { |
243
|
|
- $conf->global->STOCK_CALCULATE_ON_BILL = 0; // To not change the stock (not yet compatible with batch management) |
|
243
|
+ $conf->global->STOCK_CALCULATE_ON_BILL = 0; // To not change the stock (not yet compatible with batch management) |
244
|
244
|
} else { |
245
|
|
- $conf->global->STOCK_CALCULATE_ON_BILL = 1; // To force the change of stock |
|
245
|
+ $conf->global->STOCK_CALCULATE_ON_BILL = 1; // To force the change of stock |
246
|
246
|
} |
247
|
247
|
|
248
|
248
|
$constantforkey = 'CASHDESK_ID_WAREHOUSE'.$_SESSION["takeposterminal"]; |
|
@@ -316,7 +316,7 @@ discard block |
|
|
block discarded – undo |
316
|
316
|
} |
317
|
317
|
// Update stock for batch products |
318
|
318
|
if (isModEnabled('productbatch')) { |
319
|
|
- require_once DOL_DOCUMENT_ROOT . "/product/stock/class/mouvementstock.class.php"; |
|
319
|
+ require_once DOL_DOCUMENT_ROOT."/product/stock/class/mouvementstock.class.php"; |
320
|
320
|
$constantforkey = 'CASHDESK_ID_WAREHOUSE'.$_SESSION["takeposterminal"]; |
321
|
321
|
foreach ($invoice->lines as $line) { |
322
|
322
|
if ($line->batch && $line->fk_warehouse > 0) { |
|
@@ -338,7 +338,7 @@ discard block |
|
|
block discarded – undo |
338
|
338
|
$creditnote->socid = $invoice->socid; |
339
|
339
|
$creditnote->date = dol_now(); |
340
|
340
|
$creditnote->module_source = 'takepos'; |
341
|
|
- $creditnote->pos_source = isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : '' ; |
|
341
|
+ $creditnote->pos_source = isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : ''; |
342
|
342
|
$creditnote->type = Facture::TYPE_CREDIT_NOTE; |
343
|
343
|
$creditnote->fk_facture_source = $placeid; |
344
|
344
|
//$creditnote->remise_absolue = $invoice->remise_absolue; |
|
@@ -489,9 +489,9 @@ discard block |
|
|
block discarded – undo |
489
|
489
|
// If we add a line and no invoice yet, we create the invoice |
490
|
490
|
if (($action == "addline" || $action == "freezone") && $placeid == 0 && ($user->hasRight('takepos', 'run') || defined('INCLUDE_PHONEPAGE_FROM_PUBLIC_PAGE'))) { |
491
|
491
|
$invoice->socid = getDolGlobalInt($constforcompanyid); |
492
|
|
- $invoice->date = dol_now('tzuserrel'); // We use the local date, only the day will be saved. |
|
492
|
+ $invoice->date = dol_now('tzuserrel'); // We use the local date, only the day will be saved. |
493
|
493
|
$invoice->module_source = 'takepos'; |
494
|
|
- $invoice->pos_source = isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : '' ; |
|
494
|
+ $invoice->pos_source = isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : ''; |
495
|
495
|
$invoice->entity = !empty($_SESSION["takeposinvoiceentity"]) ? $_SESSION["takeposinvoiceentity"] : $conf->entity; |
496
|
496
|
|
497
|
497
|
if ($invoice->socid <= 0) { |
|
@@ -533,7 +533,7 @@ discard block |
|
|
block discarded – undo |
533
|
533
|
$batch = GETPOST('batch', 'alpha'); |
534
|
534
|
|
535
|
535
|
if (!empty($batch)) { |
536
|
|
- $action="setbatch"; |
|
536
|
+ $action = "setbatch"; |
537
|
537
|
} else { |
538
|
538
|
$nbofsuggested = 0; |
539
|
539
|
$prod->load_stock('warehouseopen'); |
|
@@ -553,7 +553,7 @@ discard block |
|
|
block discarded – undo |
553
|
553
|
echo "}"; |
554
|
554
|
echo "</script>"; |
555
|
555
|
|
556
|
|
- if ($nbofsuggested>0) { |
|
556
|
+ if ($nbofsuggested > 0) { |
557
|
557
|
echo "<center>".$langs->trans("SearchIntoBatch").": <b> $nbofsuggested </b></center><br><table>"; |
558
|
558
|
foreach ($prod->stock_warehouse[getDolGlobalString($constantforkey)]->detail_batch as $dbatch) { // $dbatch is instance of Productbatch |
559
|
559
|
$batchStock = + $dbatch->qty; // To get a numeric |
|
@@ -614,7 +614,7 @@ discard block |
|
|
block discarded – undo |
614
|
614
|
if (getDolGlobalString('TAKEPOS_GROUP_SAME_PRODUCT')) { |
615
|
615
|
foreach ($invoice->lines as $line) { |
616
|
616
|
if ($line->product_ref == $prod->ref) { |
617
|
|
- if ($line->special_code==4) { |
|
617
|
+ if ($line->special_code == 4) { |
618
|
618
|
continue; |
619
|
619
|
} // If this line is sended to printer create new line |
620
|
620
|
// check if qty in stock |
|
@@ -664,7 +664,7 @@ discard block |
|
|
block discarded – undo |
664
|
664
|
|
665
|
665
|
// complete line by hook |
666
|
666
|
$parameters = array('prod' => $prod, 'line' => $line); |
667
|
|
- $reshook=$hookmanager->executeHooks('completeTakePosAddLine', $parameters, $invoice, $action); // Note that $action and $line may have been modified by some hooks |
|
667
|
+ $reshook = $hookmanager->executeHooks('completeTakePosAddLine', $parameters, $invoice, $action); // Note that $action and $line may have been modified by some hooks |
668
|
668
|
if ($reshook < 0) { |
669
|
669
|
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); |
670
|
670
|
} |
|
@@ -719,7 +719,7 @@ discard block |
|
|
block discarded – undo |
719
|
719
|
|
720
|
720
|
if ($action == "addnote" && ($user->hasRight('takepos', 'run') || defined('INCLUDE_PHONEPAGE_FROM_PUBLIC_PAGE'))) { |
721
|
721
|
$desc = GETPOST('addnote', 'alpha'); |
722
|
|
- if ($idline==0) { |
|
722
|
+ if ($idline == 0) { |
723
|
723
|
$invoice->update_note($desc, '_public'); |
724
|
724
|
} else { |
725
|
725
|
foreach ($invoice->lines as $line) { |
|
@@ -852,7 +852,7 @@ discard block |
|
|
block discarded – undo |
852
|
852
|
} |
853
|
853
|
if (!$permissiontoupdateline) { |
854
|
854
|
dol_htmloutput_errors($langs->trans("NotEnoughPermissions", "TakePos").' - No permission to updateprice', null, 1); |
855
|
|
- } elseif (getDolGlobalInt('TAKEPOS_CHANGE_PRICE_HT') == 1) { |
|
855
|
+ } elseif (getDolGlobalInt('TAKEPOS_CHANGE_PRICE_HT') == 1) { |
856
|
856
|
$result = $invoice->updateline($line->id, $line->desc, $number, $line->qty, $line->remise_percent, $line->date_start, $line->date_end, $line->tva_tx, $line->localtax1_tx, $line->localtax2_tx, 'HT', $line->info_bits, $line->product_type, $line->fk_parent_line, 0, $line->fk_fournprice, $line->pa_ht, $line->label, $line->special_code, $line->array_options, $line->situation_percent, $line->fk_unit); |
857
|
857
|
} else { |
858
|
858
|
$result = $invoice->updateline($line->id, $line->desc, $number, $line->qty, $line->remise_percent, $line->date_start, $line->date_end, $line->tva_tx, $line->localtax1_tx, $line->localtax2_tx, 'TTC', $line->info_bits, $line->product_type, $line->fk_parent_line, 0, $line->fk_fournprice, $line->pa_ht, $line->label, $line->special_code, $line->array_options, $line->situation_percent, $line->fk_unit); |
|
@@ -914,7 +914,7 @@ discard block |
|
|
block discarded – undo |
914
|
914
|
$invoice->fetch($placeid); |
915
|
915
|
} |
916
|
916
|
|
917
|
|
- if ($action=="setbatch" && ($user->hasRight('takepos', 'run') || defined('INCLUDE_PHONEPAGE_FROM_PUBLIC_PAGE'))) { |
|
917
|
+ if ($action == "setbatch" && ($user->hasRight('takepos', 'run') || defined('INCLUDE_PHONEPAGE_FROM_PUBLIC_PAGE'))) { |
918
|
918
|
$constantforkey = 'CASHDESK_ID_WAREHOUSE'.$_SESSION["takeposterminal"]; |
919
|
919
|
$sql = "UPDATE ".MAIN_DB_PREFIX."facturedet set batch=".$db->escape($batch).", fk_warehouse=".getDolGlobalString($constantforkey)." where rowid=".((int) $idoflineadded); |
920
|
920
|
$db->query($sql); |
|
@@ -1061,7 +1061,7 @@ discard block |
|
|
block discarded – undo |
1061
|
1061
|
} |
1062
|
1062
|
$sectionwithinvoicelink .= '</span><br>'; |
1063
|
1063
|
if (getDolGlobalInt('TAKEPOS_PRINT_INVOICE_DOC_INSTEAD_OF_RECEIPT')) { |
1064
|
|
- $sectionwithinvoicelink .= ' <a target="_blank" class="button" href="' . DOL_URL_ROOT . '/document.php?token=' . newToken() . '&modulepart=facture&file=' . $invoice->ref . '/' . $invoice->ref . '.pdf">Invoice</a>'; |
|
1064
|
+ $sectionwithinvoicelink .= ' <a target="_blank" class="button" href="'.DOL_URL_ROOT.'/document.php?token='.newToken().'&modulepart=facture&file='.$invoice->ref.'/'.$invoice->ref.'.pdf">Invoice</a>'; |
1065
|
1065
|
} elseif (getDolGlobalString('TAKEPOS_PRINT_METHOD') == "takeposconnector") { |
1066
|
1066
|
if (getDolGlobalString('TAKEPOS_PRINT_SERVER') && filter_var($conf->global->TAKEPOS_PRINT_SERVER, FILTER_VALIDATE_URL) == true) { |
1067
|
1067
|
$sectionwithinvoicelink .= ' <button id="buttonprint" type="button" onclick="TakeposConnector('.$placeid.')">'.$langs->trans('PrintTicket').'</button>'; |
|
@@ -1100,7 +1100,7 @@ discard block |
|
|
block discarded – undo |
1100
|
1100
|
if ((getDolGlobalString('TAKEPOS_PHONE_BASIC_LAYOUT') == 1 && $conf->browser->layout == 'phone') || defined('INCLUDE_PHONEPAGE_FROM_PUBLIC_PAGE')) { |
1101
|
1101
|
$title = 'TakePOS - Dolibarr '.DOL_VERSION; |
1102
|
1102
|
if (getDolGlobalString('MAIN_APPLICATION_TITLE')) { |
1103
|
|
- $title = 'TakePOS - ' . getDolGlobalString('MAIN_APPLICATION_TITLE'); |
|
1103
|
+ $title = 'TakePOS - '.getDolGlobalString('MAIN_APPLICATION_TITLE'); |
1104
|
1104
|
} |
1105
|
1105
|
$head = '<meta name="apple-mobile-web-app-title" content="TakePOS"/> |
1106
|
1106
|
<meta name="apple-mobile-web-app-capable" content="yes"> |
|
@@ -1124,7 +1124,7 @@ discard block |
|
|
block discarded – undo |
1124
|
1124
|
<script type="text/javascript"> |
1125
|
1125
|
var selectedline=0; |
1126
|
1126
|
var selectedtext=""; |
1127
|
|
-<?php if ($action=="valid") { |
|
1127
|
+<?php if ($action == "valid") { |
1128
|
1128
|
echo "var place=0;"; |
1129
|
1129
|
}?> // Set to default place after close sale |
1130
|
1130
|
var placeid=<?php echo($placeid > 0 ? $placeid : 0); ?>; |
|
@@ -1325,7 +1325,7 @@ discard block |
|
|
block discarded – undo |
1325
|
1325
|
if ($contactid > 0) { |
1326
|
1326
|
$contact = new Contact($db); |
1327
|
1327
|
$contact->fetch($contactid); |
1328
|
|
- $s .= " - " . $contact->getFullName($langs); |
|
1328
|
+ $s .= " - ".$contact->getFullName($langs); |
1329
|
1329
|
} |
1330
|
1330
|
} |
1331
|
1331
|
} |
|
@@ -1386,10 +1386,10 @@ discard block |
|
|
block discarded – undo |
1386
|
1386
|
$s = ''; |
1387
|
1387
|
|
1388
|
1388
|
$idwarehouse = 0; |
1389
|
|
- $constantforkey = 'CASHDESK_NO_DECREASE_STOCK'. (isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : ''); |
|
1389
|
+ $constantforkey = 'CASHDESK_NO_DECREASE_STOCK'.(isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : ''); |
1390
|
1390
|
if (isModEnabled('stock')) { |
1391
|
1391
|
if (getDolGlobalString($constantforkey) != "1") { |
1392
|
|
- $constantforkey = 'CASHDESK_ID_WAREHOUSE'. (isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : ''); |
|
1392
|
+ $constantforkey = 'CASHDESK_ID_WAREHOUSE'.(isset($_SESSION["takeposterminal"]) ? $_SESSION["takeposterminal"] : ''); |
1393
|
1393
|
$idwarehouse = getDolGlobalString($constantforkey); |
1394
|
1394
|
if ($idwarehouse > 0) { |
1395
|
1395
|
$s = '<span class="small">'; |
|
@@ -1536,8 +1536,8 @@ discard block |
|
|
block discarded – undo |
1536
|
1536
|
} |
1537
|
1537
|
|
1538
|
1538
|
// Complete header by hook |
1539
|
|
-$parameters=array(); |
1540
|
|
-$reshook=$hookmanager->executeHooks('completeTakePosInvoiceHeader', $parameters, $invoice, $action); // Note that $action and $object may have been modified by some hooks |
|
1539
|
+$parameters = array(); |
|
1540
|
+$reshook = $hookmanager->executeHooks('completeTakePosInvoiceHeader', $parameters, $invoice, $action); // Note that $action and $object may have been modified by some hooks |
1541
|
1541
|
if ($reshook < 0) { |
1542
|
1542
|
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); |
1543
|
1543
|
} |
|
@@ -1548,16 +1548,16 @@ discard block |
|
|
block discarded – undo |
1548
|
1548
|
print '<td class="linecolqty right">'.$langs->trans('Qty').'</td>'; |
1549
|
1549
|
if (getDolGlobalString('TAKEPOS_SHOW_HT')) { |
1550
|
1550
|
print '<td class="linecolht right nowraponall">'; |
1551
|
|
- print '<span class="opacitymedium small">' . $langs->trans('TotalHTShort') . '</span><br>'; |
|
1551
|
+ print '<span class="opacitymedium small">'.$langs->trans('TotalHTShort').'</span><br>'; |
1552
|
1552
|
// In phone version only show when it is invoice page |
1553
|
1553
|
if (empty($mobilepage) || $mobilepage == "invoice") { |
1554
|
|
- print '<span id="linecolht-span-total" style="font-size:1.3em; font-weight: bold;">' . price($invoice->total_ht, 1, '', 1, -1, -1, $conf->currency) . '</span>'; |
|
1554
|
+ print '<span id="linecolht-span-total" style="font-size:1.3em; font-weight: bold;">'.price($invoice->total_ht, 1, '', 1, -1, -1, $conf->currency).'</span>'; |
1555
|
1555
|
if (isModEnabled('multicurrency') && $_SESSION["takeposcustomercurrency"] != "" && $conf->currency != $_SESSION["takeposcustomercurrency"]) { |
1556
|
1556
|
//Only show customer currency if multicurrency module is enabled, if currency selected and if this currency selected is not the same as main currency |
1557
|
|
- include_once DOL_DOCUMENT_ROOT . '/multicurrency/class/multicurrency.class.php'; |
|
1557
|
+ include_once DOL_DOCUMENT_ROOT.'/multicurrency/class/multicurrency.class.php'; |
1558
|
1558
|
$multicurrency = new MultiCurrency($db); |
1559
|
1559
|
$multicurrency->fetch(0, $_SESSION["takeposcustomercurrency"]); |
1560
|
|
- print '<br><span id="linecolht-span-total" style="font-size:0.9em; font-style:italic;">(' . price($invoice->total_ht * $multicurrency->rate->rate) . ' ' . $_SESSION["takeposcustomercurrency"] . ')</span>'; |
|
1560
|
+ print '<br><span id="linecolht-span-total" style="font-size:0.9em; font-style:italic;">('.price($invoice->total_ht * $multicurrency->rate->rate).' '.$_SESSION["takeposcustomercurrency"].')</span>'; |
1561
|
1561
|
} |
1562
|
1562
|
} |
1563
|
1563
|
print '</td>'; |
|
@@ -1698,8 +1698,8 @@ discard block |
|
|
block discarded – undo |
1698
|
1698
|
$htmlsupplements[$line->fk_parent_line] .= '</td>'; |
1699
|
1699
|
|
1700
|
1700
|
// complete line by hook |
1701
|
|
- $parameters=array('line' => $line); |
1702
|
|
- $reshook=$hookmanager->executeHooks('completeTakePosInvoiceParentLine', $parameters, $invoice, $action); // Note that $action and $object may have been modified by some hooks |
|
1701
|
+ $parameters = array('line' => $line); |
|
1702
|
+ $reshook = $hookmanager->executeHooks('completeTakePosInvoiceParentLine', $parameters, $invoice, $action); // Note that $action and $object may have been modified by some hooks |
1703
|
1703
|
if ($reshook < 0) { |
1704
|
1704
|
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); |
1705
|
1705
|
} |
|
@@ -1748,7 +1748,7 @@ discard block |
|
|
block discarded – undo |
1748
|
1748
|
} |
1749
|
1749
|
} |
1750
|
1750
|
if (getDolGlobalInt('TAKEPOS_SHOW_PRODUCT_REFERENCE') == 1) { |
1751
|
|
- $htmlforlines .= $form->textwithpicto($line->product_label ? '<b>' . $line->product_ref . '</b> - ' . $line->product_label : dolGetFirstLineOfText($line->desc, 1), $tooltiptext); |
|
1751
|
+ $htmlforlines .= $form->textwithpicto($line->product_label ? '<b>'.$line->product_ref.'</b> - '.$line->product_label : dolGetFirstLineOfText($line->desc, 1), $tooltiptext); |
1752
|
1752
|
} elseif (getDolGlobalInt('TAKEPOS_SHOW_PRODUCT_REFERENCE') == 2) { |
1753
|
1753
|
$htmlforlines .= $form->textwithpicto($line->product_ref ? '<b>'.$line->product_ref.'<b>' : dolGetFirstLineOfText($line->desc, 1), $tooltiptext); |
1754
|
1754
|
} else { |
|
@@ -1794,8 +1794,8 @@ discard block |
|
|
block discarded – undo |
1794
|
1794
|
$htmlforlines .= '</td>'; |
1795
|
1795
|
|
1796
|
1796
|
// complete line by hook |
1797
|
|
- $parameters=array('line' => $line); |
1798
|
|
- $reshook=$hookmanager->executeHooks('completeTakePosInvoiceLine', $parameters, $invoice, $action); // Note that $action and $object may have been modified by some hooks |
|
1797
|
+ $parameters = array('line' => $line); |
|
1798
|
+ $reshook = $hookmanager->executeHooks('completeTakePosInvoiceLine', $parameters, $invoice, $action); // Note that $action and $object may have been modified by some hooks |
1799
|
1799
|
if ($reshook < 0) { |
1800
|
1800
|
setEventMessages($hookmanager->error, $hookmanager->errors, 'errors'); |
1801
|
1801
|
} |
|
@@ -1895,7 +1895,7 @@ discard block |
|
|
block discarded – undo |
1895
|
1895
|
if (($action == "valid" || $action == "history") && $invoice->type != Facture::TYPE_CREDIT_NOTE && !getDolGlobalString('TAKEPOS_NO_CREDITNOTE')) { |
1896
|
1896
|
print '<button id="buttonprint" type="button" onclick="ModalBox(\'ModalCreditNote\')">'.$langs->trans('CreateCreditNote').'</button>'; |
1897
|
1897
|
if (getDolGlobalInt('TAKEPOS_PRINT_INVOICE_DOC_INSTEAD_OF_RECEIPT')) { |
1898
|
|
- print ' <a target="_blank" class="button" href="' . DOL_URL_ROOT . '/document.php?token=' . newToken() . '&modulepart=facture&file=' . $invoice->ref . '/' . $invoice->ref . '.pdf">Invoice</a>'; |
|
1898
|
+ print ' <a target="_blank" class="button" href="'.DOL_URL_ROOT.'/document.php?token='.newToken().'&modulepart=facture&file='.$invoice->ref.'/'.$invoice->ref.'.pdf">Invoice</a>'; |
1899
|
1899
|
} |
1900
|
1900
|
} |
1901
|
1901
|
|