* Copyright (C) 2011 Laurent Destailleur * Copyright (C) 2012 Marcos García * Copyright (C) 2018 Andreu Bisquerra * Copyright (C) 2019 Josep Lluís Amador * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 3 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ /** * \file htdocs/takepos/floors.php * \ingroup takepos * \brief Page to show a receipt. */ require '../main.inc.php'; // Load $user and permissions include_once DOL_DOCUMENT_ROOT.'/compta/facture/class/facture.class.php'; $langs->loadLangs(array("main", "cashdesk")); $place = (GETPOST('place', 'int') > 0 ? GETPOST('place', 'int') : 0); // $place is id of table for Ba or Restaurant $posnb = (GETPOST('posnb', 'int') > 0 ? GETPOST('posnb', 'int') : 0); // $posnb is id of POS $facid=GETPOST('facid', 'int'); /* * View */ top_httphead('text/html'); if ($place > 0) { $sql="SELECT rowid FROM ".MAIN_DB_PREFIX."facture where ref='(PROV-POS-".$place.")'"; $resql = $db->query($sql); $obj = $db->fetch_object($resql); if ($obj) { $facid=$obj->rowid; } } $object=new Facture($db); $object->fetch($facid); // IMPORTANT: This file is sended to 'Takepos Printing' application. Keep basic file. No external files as css, js... If you need images use absolute path. ?>
'.$mysoc->name.'';?>

global->TAKEPOS_HEADER)) { $newfreetext=make_substitutions($conf->global->TAKEPOS_HEADER, $substitutionarray); echo $newfreetext; } ?>

trans('Date')." ".dol_print_date($object->date, 'day').'
'; if ($mysoc->country_code == 'ES') print "Factura simplificada "; print $object->ref; ?>


lines as $line) { ?>
trans("Label"); ?> trans("Qty"); ?> trans("Price"); ?> trans("TotalTTC"); ?>
product_label)) echo $line->product_label; else echo $line->description;?> qty;?> total_ttc/$line->qty;?> total_ttc);?>

global->TAKEPOS_TICKET_VAT_GROUPPED):?> lines as $line) { if(!array_key_exists($line->tva_tx, $vat_groups)){ $vat_groups[$line->tva_tx] = 0; } $vat_groups[$line->tva_tx] += $line->total_tva; } foreach($vat_groups as $key => $val){ ?>
trans("TotalHT");?> total_ht, 1, '', 1, - 1, - 1, $conf->currency)."\n";?>
trans("VAT").' '.vatrate($key, 1);?> 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";?>



global->TAKEPOS_FOOTER)) { $newfreetext=make_substitutions($conf->global->TAKEPOS_FOOTER, $substitutionarray); echo $newfreetext; } ?>