diff --git a/htdocs/langs/en_US/cashdesk.lang b/htdocs/langs/en_US/cashdesk.lang
index c7d7dd95cb7..b755a388f5b 100644
--- a/htdocs/langs/en_US/cashdesk.lang
+++ b/htdocs/langs/en_US/cashdesk.lang
@@ -117,3 +117,5 @@ HideCategoryImages=Hide Category Images
HideProductImages=Hide Product Images
NumberOfLinesToShow=Number of lines of images to show
DefineTablePlan=Define tables plan
+GiftReceiptButton=Gift receipt button
+GiftReceipt=Gift receipt
diff --git a/htdocs/takepos/admin/setup.php b/htdocs/takepos/admin/setup.php
index 830e5d203d3..22355c70d9d 100644
--- a/htdocs/takepos/admin/setup.php
+++ b/htdocs/takepos/admin/setup.php
@@ -365,6 +365,13 @@ print '
';
print ajax_constantonoff("TAKEPOS_CONTROL_CASH_OPENING", array(), $conf->entity, 0, 0, 1, 0);
print " | \n";
+// Gift receipt
+print '| ';
+print $langs->trans('GiftReceiptButton');
+print ' | ';
+print ajax_constantonoff("TAKEPOS_GIFT_RECEIPT", array(), $conf->entity, 0, 0, 1, 0);
+print " |
\n";
+
// Numbering module
//print '';
//print $langs->trans("BillsNumberingModule");
diff --git a/htdocs/takepos/invoice.php b/htdocs/takepos/invoice.php
index c6b7bb2c734..aee36f9ddfc 100644
--- a/htdocs/takepos/invoice.php
+++ b/htdocs/takepos/invoice.php
@@ -597,6 +597,9 @@ if ($action == "valid" || $action == "history")
$sectionwithinvoicelink .= ' ';
} else {
$sectionwithinvoicelink .= ' ';
+ if ($conf->global->TAKEPOS_GIFT_RECEIPT) {
+ $sectionwithinvoicelink .= ' ';
+ }
}
if ($conf->global->TAKEPOS_EMAIL_TEMPLATE_INVOICE > 0)
{
@@ -700,8 +703,8 @@ function SendTicket(id)
$.colorbox({href:"send.php?facid="+id, width:"70%", height:"30%", transition:"none", iframe:"true", title:"trans("SendTicket"); ?>"});
}
-function Print(id){
- $.colorbox({href:"receipt.php?facid="+id, width:"40%", height:"90%", transition:"none", iframe:"true", title:"trans("PrintTicket"); ?>"});
}
diff --git a/htdocs/takepos/receipt.php b/htdocs/takepos/receipt.php
index 1da92de8827..99000c278de 100644
--- a/htdocs/takepos/receipt.php
+++ b/htdocs/takepos/receipt.php
@@ -34,6 +34,8 @@ $place = (GETPOST('place', 'aZ09') ? GETPOST('place', 'aZ09') : 0); // $place is
$facid = GETPOST('facid', 'int');
+$gift = GETPOST('gift', 'int');
+
if (empty($user->rights->takepos->run)) {
accessforbidden();
}
@@ -125,8 +127,8 @@ if ($conf->global->TAKEPOS_SHOW_CUSTOMER)
|
| trans("Label"); ?> |
trans("Qty"); ?> |
- trans("Price"); ?> |
- trans("TotalTTC"); ?> |
+ trans("Price"); ?> |
+ trans("TotalTTC"); ?> |
@@ -140,8 +142,8 @@ if ($conf->global->TAKEPOS_SHOW_CUSTOMER)
else echo $line->description; ?>
qty; ?> |
- total_ttc / $line->qty, 'MT'), 1); ?> |
- total_ttc, 1); ?> |
+ total_ttc / $line->qty, 'MT'), 1); ?> |
+ total_ttc, 1); ?> |
global->TAKEPOS_SHOW_CUSTOMER)
- | trans("TotalHT"); ?> |
- total_ht, 1, '', 1, - 1, - 1, $conf->currency)."\n"; ?> |
+ trans("TotalHT"); ?> |
+ total_ht, 1, '', 1, - 1, - 1, $conf->currency)."\n"; ?> |
global->TAKEPOS_TICKET_VAT_GROUPPED) {
$vat_groups = array();
@@ -166,18 +168,18 @@ if ($conf->global->TAKEPOS_SHOW_CUSTOMER)
foreach ($vat_groups as $key => $val) {
?>
- | trans("VAT").' '.vatrate($key, 1); ?> |
- currency)."\n"; ?> |
+ trans("VAT").' '.vatrate($key, 1); ?> |
+ currency)."\n"; ?> |
- | trans("TotalVAT").' | '.price($object->total_tva, 1, '', 1, - 1, - 1, $conf->currency)."\n"; ?> |
+ trans("TotalVAT").' | '.price($object->total_tva, 1, '', 1, - 1, - 1, $conf->currency)."\n"; ?> |
- | trans("TotalTTC").' | '.price($object->total_ttc, 1, '', 1, - 1, - 1, $conf->currency)."\n"; ?> |
+ trans("TotalTTC").' | '.price($object->total_ttc, 1, '', 1, - 1, - 1, $conf->currency)."\n"; ?> |