diff --git a/printserver/OrderSprinterPrintserver.exe b/printserver/OrderSprinterPrintserver.exe
index 3aa6d3c..878381d 100644
Binary files a/printserver/OrderSprinterPrintserver.exe and b/printserver/OrderSprinterPrintserver.exe differ
diff --git a/webapp/OrderSprinterPrintserver.exe b/webapp/OrderSprinterPrintserver.exe
index 3aa6d3c..878381d 100644
Binary files a/webapp/OrderSprinterPrintserver.exe and b/webapp/OrderSprinterPrintserver.exe differ
diff --git a/webapp/bar.html b/webapp/bar.html
index f534652..2f92989 100644
--- a/webapp/bar.html
+++ b/webapp/bar.html
@@ -5,7 +5,7 @@
-
+
diff --git a/webapp/bill.html b/webapp/bill.html
index bf8b07d..60bb076 100644
--- a/webapp/bill.html
+++ b/webapp/bill.html
@@ -5,7 +5,7 @@
-
+
@@ -67,6 +67,8 @@ var BILL_UPDATE = ["Aktualisieren","Update","Actualizar"];
var BILL_PRINT = ["Drucken","Print","Imprimir"];
var BILL_STORNO = ["Storno","Cancel","Contrapartida"];
var BILL_CLOSED = ["abgeschlossen","closed","cerrado"];
+var BILL_DO_HOST = ["Bewirtungsbeleg","Guest receipt","Tique de invitados"];
+var BILL_UNDO_HOST = ["Rückgängig Bewirtungsbeleg","Undo guest receipt","No tique de invitados"];
var BILL_TITLE = ["Kassenbons","Receipts","Tiques"];
var BILL_YES = ["Ja","Yes","Si"];
var BILL_NO = ["Nein","No","No"];
@@ -77,6 +79,9 @@ var BILL_NO_CANCEL_POSS = ["Der Stornovorgang ist fehlgeschlagen. Die wahrschein
"Contrapartida no fue posible. Probablemente el tique esta ya cerrado."];
var BILL_DATE = ["Datum","Date","Fecha"];
var BILL_STORNO_REASON = ["Stornogrund","Reason","Razón"];
+var BILL_TOGGLE_HOST = ["Der ursprüngliche Bon wurde storniert und mit geänderter Bewirtungseigenschaft neu angelegt. Er befindet sich an erster Stelle in der Bonliste.",
+ "Der original receipt was discarded and recreated with the changed guest receipt property. The new receipt is on top of the list",
+ "El tique original esta descartado y iniciado de nuevo en la forma modificada"];;
var lang = 0;
@@ -151,6 +156,14 @@ function cancelBill(jsonText) {
setTimeout(function(){location.reload()},1000);
}
+function changeHostBill(jsonText) {
+ if (jsonText.status != "OK") {
+ alert("Fehler " + jsonText.code + ": " + jsonText.msg);
+ return;
+ }
+ alert(BILL_TOGGLE_HOST[lang]);
+ setTimeout(function(){location.reload()},1000);
+}
function displayBillsWithContent (jsonContent) {
if (jsonContent.status != "OK") {
@@ -233,6 +246,19 @@ function displayBillsWithContent (jsonContent) {
doAjaxCancelBill(billid,$("#stornocode").val(),$("#stornoreason").val());
});
});
+
+ $(".changehostbuttons").off("click").on("click", function (e) {
+ var billid = this.id.split("_")[1];
+ var isNowHost = this.id.split("_")[2];
+ $("#stornocode").val("");
+ $("#stornoreason").val("");
+
+ var data = {
+ billid: billid,
+ isNowHost: isNowHost
+ };
+ doAjax("POST","php/contenthandler.php?module=bill&command=changeBillHost",data,changeHostBill,"Bonänderung abgebrochen");
+ });
});
}
@@ -262,10 +288,16 @@ function getBillWithId(id) {
var printbuttonid = 'print_' + id;
var cancelbuttonid = 'cancel_' + id;
+ var changehostbuttonid = 'changehost_' + id + "_" + entry.host;
var collapse_elem_id = 'collapse_' + id;
var printbutton = '' + BILL_PRINT[lang] + '';
var cancelButton = '' + BILL_STORNO[lang] + '';
+ var toggleHostTxt = BILL_DO_HOST[lang];
+ if (entry.host == 1) {
+ toggleHostTxt = BILL_UNDO_HOST[lang];
+ }
+ var changehostbutton = '' + toggleHostTxt + '';
var bi = entry.billcontent.billoverallinfo;
var date_time = bi.billday + "." + bi.billmonth + "." + bi.billyear + " " + bi.billhour + ":" + bi.billmin;
@@ -273,7 +305,7 @@ function getBillWithId(id) {
var txt = '
' + printbutton;
if (entry.isClosed == 0) {
// REM* bill is not closed - so can be printed AND cancelled
- txt += cancelButton + ' ' + content + '
';
+ txt += cancelButton + changehostbutton + ' ' + content + '';
} else {
// REM* bill is closed - only printing possible, no cancelling
txt += '
' + ' ' + content + '
';
diff --git a/webapp/customer/menulegend.txt b/webapp/customer/menulegend.txt
index 8b2e18b..0dafdff 100755
--- a/webapp/customer/menulegend.txt
+++ b/webapp/customer/menulegend.txt
@@ -51,7 +51,7 @@
# !Extraname (ID:8) # 12,34 ; (45),Langname eines Produkts,(49),(50)
# - Die ID-Angabe ist optional (kann weggelassen werden)
# - Der Wert 12,34 ist der Aufpreis
-# - Hinter dem Semikolo können Komma-getrennt Produte angegebenen werden, die
+# - Hinter dem Semikolon können Komma-getrennt Produkte angegebenen werden, die
# dieses Extra haben dürfen. Angabe entweder ID des Produkts in Klammern oder
# der Langname eines Produkts. (Gibt es den Langnamen mehrfach, wird das Extra
# auch mehrfach zugewiesen.)
diff --git a/webapp/customer/speisekarte.txt b/webapp/customer/speisekarte.txt
index 5a6c614..4b16936 100755
--- a/webapp/customer/speisekarte.txt
+++ b/webapp/customer/speisekarte.txt
@@ -33,7 +33,7 @@
# !Extraname (ID:8) # 12,34 ; (45),Langname eines Produkts,(49),(50)
# - Die ID-Angabe ist optional (kann weggelassen werden)
# - Der Wert 12,34 ist der Aufpreis
-# - Hinter dem Semikolo können Komma-getrennt Produte angegebenen werden, die
+# - Hinter dem Semikolon können Komma-getrennt Produkte angegebenen werden, die
# dieses Extra haben dürfen. Angabe entweder ID des Produkts in Klammern oder
# der Langname eines Produkts. (Gibt es den Langnamen mehrfach, wird das Extra
# auch mehrfach zugewiesen.)
diff --git a/webapp/feedback.html b/webapp/feedback.html
index e00b7c7..ed99f07 100644
--- a/webapp/feedback.html
+++ b/webapp/feedback.html
@@ -4,7 +4,7 @@
-
+
diff --git a/webapp/index.html b/webapp/index.html
index 6879c10..12fbee2 100644
--- a/webapp/index.html
+++ b/webapp/index.html
@@ -7,8 +7,8 @@
-
-
+
+
diff --git a/webapp/install.html b/webapp/install.html
index 356daa6..6f53eae 100644
--- a/webapp/install.html
+++ b/webapp/install.html
@@ -679,7 +679,7 @@ $(document).ready(function() {
-
+
diff --git a/webapp/install/installer.php b/webapp/install/installer.php
index eb100f9..8570447 100644
--- a/webapp/install/installer.php
+++ b/webapp/install/installer.php
@@ -579,7 +579,7 @@ $stmt->execute();
$sql = "UPDATE %user% SET keeptypelevel=?";
$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
-$stmt->execute(array(1));
+$stmt->execute(array(0));
$sql = "ALTER TABLE %user% MODIFY keeptypelevel INT(1) NOT NULL";
$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
@@ -802,6 +802,36 @@ return false;
}
}
+function updateUserTable1112_1113($prefix,$version) {
+$pdo = $this->pdo;
+try {
+if ($version != "1.1.12") {
+$ret = $this->updateUserTable1111_1112($prefix,$version);
+if (!$ret) {
+return false;
+}
+}
+
+$adminCl = new Admin();
+DbUtils::overrulePrefix($prefix);
+
+$sql = "ALTER TABLE %queue% ADD pricechanged INT(1) NULL AFTER anoption";
+$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
+$stmt->execute();
+$sql = "ALTER TABLE %queue% ADD togo INT(1) NULL AFTER pricechanged";
+$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
+$stmt->execute();
+$sql = "UPDATE %queue% SET pricechanged=?,togo=?";
+$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
+$stmt->execute(array(0,0));
+
+$this->updateVersion($pdo, '1.1.13');
+return true;
+} catch (PDOException $e) {
+return false;
+}
+}
+
function setVersion($prefix,$theVersion) {
$pdo = $this->pdo;
try {
@@ -873,7 +903,7 @@ $this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VAL
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'billlanguage', $billlanguage)");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'currency', '$currency')");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'receiptfontsize', '12')");
-$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'version', '1.1.12')");
+$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'version', '1.1.13')");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'paymentconfig', '0')");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'remoteaccesscode', null)");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'decpoint', '$decpoint')");
@@ -965,7 +995,7 @@ $pdo = $this->pdo;
$userInsertSql = "INSERT INTO `%user%` (`id` , `username` , `userpassword`, `is_admin`, `right_waiter`,`right_kitchen`,`right_bar`,`right_supply`,`right_paydesk`,`right_statistics`,`right_bill`,`right_products`,`right_changeprice`,`right_manager`,`right_reservation`,`right_rating`,`language`,`prefertablemap`,`keeptypelevel`,`extrasapplybtnpos`,`active`) VALUES (NULL,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,'1','1')";
$stmt = $pdo->prepare(DbUtils::substTableAlias($userInsertSql));
-$stmt->execute(array($username,$md5adminpass,$is_admin,$right_waiter,$right_kitchen,$right_bar,$right_supply,$right_paydesk,$right_statistics,$right_bill,$right_products,$right_changeprice,$right_manager,$right_reservation,$right_rating,$lang,$prefertablemap,1));
+$stmt->execute(array($username,$md5adminpass,$is_admin,$right_waiter,$right_kitchen,$right_bar,$right_supply,$right_paydesk,$right_statistics,$right_bill,$right_products,$right_changeprice,$right_manager,$right_reservation,$right_rating,$lang,$prefertablemap,0));
$newUserIdForHist = $pdo->lastInsertId();
@@ -1246,7 +1276,7 @@ return;
$supportedVersions = array("1.0.22","1.0.23","1.0.24","1.0.25","1.0.26","1.0.27","1.0.28","1.0.29",
"1.0.30","1.0.31","1.0.32","1.0.33","1.0.34","1.0.35","1.0.36","1.0.37","1.0.38","1.0.39",
"1.0.40","1.0.41","1.0.42","1.0.43",
-"1.1.0","1.1.1","1.1.2","1.1.3","1.1.4","1.1.5","1.1.6","1.1.7","1.1.8", "1.1.9","1.1.10","1.1.11"
+"1.1.0","1.1.1","1.1.2","1.1.3","1.1.4","1.1.5","1.1.6","1.1.7","1.1.8", "1.1.9","1.1.10","1.1.11","1.1.12"
);
if (!in_array($version, $supportedVersions)) {
@@ -1254,7 +1284,7 @@ echo json_encode("Quellversion nicht unterstützt");
return;
}
-$ret = $admin->updateUserTable1111_1112($_POST['prefix'], $version);
+$ret = $admin->updateUserTable1112_1113($_POST['prefix'], $version);
if(session_id() == '') {
session_start();
diff --git a/webapp/kitchen.html b/webapp/kitchen.html
index 3e668f4..eb5bc1f 100644
--- a/webapp/kitchen.html
+++ b/webapp/kitchen.html
@@ -5,7 +5,7 @@
-
+
diff --git a/webapp/manager.html b/webapp/manager.html
index 0f6e1b3..a2708bf 100644
--- a/webapp/manager.html
+++ b/webapp/manager.html
@@ -5,7 +5,7 @@
-
+
diff --git a/webapp/paydesk.html b/webapp/paydesk.html
index 394ce8f..d2dd84f 100644
--- a/webapp/paydesk.html
+++ b/webapp/paydesk.html
@@ -5,7 +5,7 @@
-
+
@@ -631,47 +631,15 @@ function generateListItem(theme,icon,id,content,classname) {
return li;
}
-function addAllToUnten(jsonContent,tablename) {
- $("#payall").off("click").on("click", function (e) {
- e.stopImmediatePropagation();
- e.preventDefault();
-
- var entryListForReceipt = [];
- $("#oben li a.info-go").each(function() {
-
- var id_in_jsonText = $(this).attr('id');
- var entry = {
- idx : id_in_jsonText,
- prodid: jsonContent[id_in_jsonText]["prodid"],
- queueid: jsonContent[id_in_jsonText]["id"],
- longname: jsonContent[id_in_jsonText]["longname"],
- price: jsonContent[id_in_jsonText]["price"],
- tax: jsonContent[id_in_jsonText]["tax"],
- extras: jsonContent[id_in_jsonText]["extras"],
- pricelevelname: jsonContent[id_in_jsonText]["pricelevelname"]
- };
- entryListForReceipt[entryListForReceipt.length] = entry;
- });
-
- $.each(entryListForReceipt, function (i, entry) {
- addToUnten(entry.prodid,entry.longname,entry.price,entry.tax,entry.pricelevelname,entry.extras,entry.idx);
-
- $("#oben li .info-go").each(function() {
- $(this).closest('li').remove().promise();
- });
-
- refreshList("#oben");
- });
- });
-
-}
-
function createHashOfPayableItem(aProd) {
var longname = aProd["longname"];
if (aProd["pricelevelname"] != "A") {
longname += " (" + aProd["pricelevelname"] + ")";
}
longname += " - " + (parseFloat(aProd["price"]).toFixed(2).replace(".",decpoint));
+ if (aProd["togo"] == 1) {
+ longname = "To-Go: " + longname;
+ }
var extratxt = createExtraParagraph(aProd["extras"]);
return toHtml(longname) + extratxt;
}
@@ -721,12 +689,12 @@ function clearUntenAndReceipt() {
//
// entry:
// [0]: prodid queueid longname price pricelevelname
-// REM* [2]: name, [3]: price, [4]: tax, [5] extras, [6]: pricelevel
+// REM* [2]: name, [3]: price, [4]: tax, [5]: togo, [6] extras, [7]: pricelevel
function addEntryOrIncreaseCount(arrayToFill,entry) {
var index=0;
var found = false;
- var combinedIdPricelevelPriceExtras = entry.prodid + "-" + entry.extras.join("_") + entry.price + "-" + entry.pricelevelname + "#" + entry.tax;
+ var combinedIdPricelevelPriceExtras = entry.prodid + "-" + entry.extras.join("_") + entry.price + "-" + entry.pricelevelname + "#" + entry.tax + "_" + entry.togo;
for (index=0;indexexecute(array($view,$userid));
}
echo json_encode(array("status" => "OK"));
+ } else {
+ echo json_encode(array("status" => "Error","msg" => "Benutzer nicht eingeloggt"));
}
}
@@ -1106,19 +1108,19 @@ class Admin {
$right_rating = $_SESSION['right_rating'];
if (!self::isOnlyRatingUser($rights, $right_rating, true)) {
- if ($_SESSION['right_waiter']) { $mainMenu[] = array("name" => $waitertxt[$lang], "link" => "waiter.html?v=1.1.12"); };
- if ($_SESSION['right_kitchen']) { $mainMenu[] = array("name" => $kitchentxt[$lang], "link" => "kitchen.html?v=1.1.12"); };
- if ($_SESSION['right_bar']) { $mainMenu[] = array("name" => "Bar", "link" => "bar.html?v=1.1.12"); };
- if ($_SESSION['right_supply']) { $mainMenu[] = array("name" => $supplytxt[$lang], "link" => "supplydesk.html?v=1.1.12"); };
+ if ($_SESSION['right_waiter']) { $mainMenu[] = array("name" => $waitertxt[$lang], "link" => "waiter.html?v=1.1.13"); };
+ if ($_SESSION['right_kitchen']) { $mainMenu[] = array("name" => $kitchentxt[$lang], "link" => "kitchen.html?v=1.1.13"); };
+ if ($_SESSION['right_bar']) { $mainMenu[] = array("name" => "Bar", "link" => "bar.html?v=1.1.13"); };
+ if ($_SESSION['right_supply']) { $mainMenu[] = array("name" => $supplytxt[$lang], "link" => "supplydesk.html?v=1.1.13"); };
if ($_SESSION['right_paydesk']) { $mainMenu[] = array("name" => $paydesktxt[$lang], "link" => "paydesk.html"); };
- if ($_SESSION['right_statistics']) { $mainMenu[] = array("name" => $stattxt[$lang], "link" => "reports.html?v=1.1.12"); };
- if ($_SESSION['right_bill']) { $mainMenu[] = array("name" => $bontxt[$lang], "link" => "bill.html?v=1.1.12"); };
- if ($_SESSION['right_products']) { $mainMenu[] = array("name" => $prodtxt[$lang], "link" => "products.html?v=1.1.12"); };
- if ($_SESSION['right_reservation']) { $mainMenu[] = array("name" => $restxt[$lang], "link" => "reservation.html?v=1.1.12"); };
- if ($_SESSION['right_rating']) { $mainMenu[] = array("name" => $ratingtxt[$lang], "link" => "rating.html?v=1.1.12"); };
- if ($_SESSION['right_manager'] || $_SESSION['is_admin']) { $mainMenu[] = array("name" => $admintxt[$lang], "link" => "manager.html?v=1.1.12"); };
- $mainMenu[] = array("name" => $settingtxt[$lang], "link" => "preferences.html?v=1.1.12");
- $mainMenu[] = array("name" => "Feedback", "link" => "feedback.html?v=1.1.12");
+ if ($_SESSION['right_statistics']) { $mainMenu[] = array("name" => $stattxt[$lang], "link" => "reports.html?v=1.1.13"); };
+ if ($_SESSION['right_bill']) { $mainMenu[] = array("name" => $bontxt[$lang], "link" => "bill.html?v=1.1.13"); };
+ if ($_SESSION['right_products']) { $mainMenu[] = array("name" => $prodtxt[$lang], "link" => "products.html?v=1.1.13"); };
+ if ($_SESSION['right_reservation']) { $mainMenu[] = array("name" => $restxt[$lang], "link" => "reservation.html?v=1.1.13"); };
+ if ($_SESSION['right_rating']) { $mainMenu[] = array("name" => $ratingtxt[$lang], "link" => "rating.html?v=1.1.13"); };
+ if ($_SESSION['right_manager'] || $_SESSION['is_admin']) { $mainMenu[] = array("name" => $admintxt[$lang], "link" => "manager.html?v=1.1.13"); };
+ $mainMenu[] = array("name" => $settingtxt[$lang], "link" => "preferences.html?v=1.1.13");
+ $mainMenu[] = array("name" => "Feedback", "link" => "feedback.html?v=1.1.13");
}
$mainMenu[] = array("name" => $logout[$lang], "link" => "logout.php");
@@ -1127,7 +1129,7 @@ class Admin {
$waiterMessage = $this->getMessage(null, "waitermessage");
}
// CAUTION: change version also in config.txt!!!
- $mainMenuAndVersion = array ("version" => "OrderSprinter 1.1.12",
+ $mainMenuAndVersion = array ("version" => "OrderSprinter 1.1.13",
"user" => $currentUser,
"menu" => $mainMenu,
"waitermessage" => $waiterMessage,
@@ -1199,7 +1201,7 @@ class Admin {
$userInsertSql = "INSERT INTO `%user%` (`id` , `username` , `userpassword`, `is_admin`, `right_waiter`,`right_kitchen`,`right_bar`,`right_supply`,`right_paydesk`,`right_statistics`,`right_bill`,`right_products`,`right_reservation`,`right_rating`,`right_changeprice`,`right_manager`,`language`,`receiptprinter`,`prefertablemap`,`keeptypelevel`,`extrasapplybtnpos`,`active`) VALUES (";
$userInsertSql .= " NULL, ?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?)";
$stmt = $pdo->prepare(DbUtils::substTableAlias($userInsertSql));
- $stmt->execute(array($username,$password_hash,$isAdmin,$rWaiter,$rKitchen,$rBar,$rSupply,$rPayDesk,$rStat,$rBill,$rProducts,$rReservation,$rRating,$rChangeprice,$rManager,$lang,1,1,1,1,1));
+ $stmt->execute(array($username,$password_hash,$isAdmin,$rWaiter,$rKitchen,$rBar,$rSupply,$rPayDesk,$rStat,$rBill,$rProducts,$rReservation,$rRating,$rChangeprice,$rManager,$lang,1,1,0,1,1));
$lastId = $pdo->lastInsertId();
diff --git a/webapp/php/bill.php b/webapp/php/bill.php
index 981ab79..01c5f16 100644
--- a/webapp/php/bill.php
+++ b/webapp/php/bill.php
@@ -107,11 +107,22 @@ class Bill {
return;
}
+ if ($command == 'changeBillHost') {
+ if ($this->hasCurrentUserPaydeskRights()) {
+ $pdo = DbUtils::openDbAndReturnPdoStatic();
+ $this->changeBillHost($pdo,$_POST['billid'],$_POST['isNowHost']);
+ } else {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_PAYDESK_NOT_AUTHOTRIZED, "msg" => ERROR_PAYDESK_NOT_AUTHOTRIZED_MSG));
+ }
+ return;
+ }
+
if ($this->hasCurrentUserBillRights()) {
if ($command == 'getLastBillsWithContent') {
$this->getLastBillsWithContent($_GET['day'],$_GET['month'],$_GET['year']);
} else if ($command == 'cancelBill') {
- $this->cancelBill($_POST['billid'],$_POST['stornocode'],$_POST['reason']);
+ $pdo = DbUtils::openDbAndReturnPdoStatic();
+ $this->cancelBill($pdo,$_POST['billid'],$_POST['stornocode'],$_POST['reason'],true,true,true);
}
} else {
echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_NOT_AUTHOTRIZED, "msg" => ERROR_BILL_NOT_AUTHOTRIZED_MSG));
@@ -284,15 +295,19 @@ class Bill {
}
// now get all products of this bill
- $sql = "select productname,price,%pricelevel%.name as pricelevelname,count(%queue%.productname) as count from %queue%,%pricelevel%,%billproducts% where %billproducts%.billid=? AND %billproducts%.queueid=%queue%.id AND %queue%.pricelevel = %pricelevel%.id group by productname,price,pricelevelname";
+ $sql = "select productname,price,%pricelevel%.name as pricelevelname,togo,count(%queue%.productname) as count from %queue%,%pricelevel%,%billproducts% where %billproducts%.billid=? AND %billproducts%.queueid=%queue%.id AND %queue%.pricelevel = %pricelevel%.id group by productname,price,pricelevelname,togo";
$stmt = $pdo->prepare($this->dbutils->resolveTablenamesInSqlString($sql));
$stmt->execute(array($billid));
$result = $stmt->fetchAll();
$prodarray = array();
foreach($result as $zeile) {
+ $productname = $zeile['productname'];
+ if ($zeile["togo"] == 1) {
+ $productname = "To-Go: " . $productname;
+ }
$prodarray[] = array("count" => $zeile['count'],
- "productname" => $zeile['productname'],
+ "productname" => $productname,
"pricelevel" => $zeile['pricelevelname'],
"price" => $sign . $zeile['price']
);
@@ -410,7 +425,7 @@ class Bill {
$commonUtils = new CommonUtils();
- $sql = "SELECT id,billdate,brutto,tableid,closingid,status FROM %bill% WHERE tableid >= '0' AND $whenClause ORDER BY billdate DESC ";
+ $sql = "SELECT id,billdate,brutto,tableid,closingid,status,host FROM %bill% WHERE tableid >= '0' AND $whenClause ORDER BY id DESC,billdate DESC ";
$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
$stmt->execute(array($startDate,$endDate));
$result = $stmt->fetchAll();
@@ -437,7 +452,8 @@ class Bill {
"brutto" => $zeile['brutto'],
"tablename" => $commonUtils->getTableNameFromId($pdo,$zeile['tableid']),
"billcontent" => $this->getBillWithId($pdo,$theId,$l,0),
- "isClosed" => $isClosed
+ "isClosed" => $isClosed,
+ "host" => $zeile['host']
);
$resultarray[] = $arr;
@@ -479,11 +495,99 @@ class Bill {
}
}
+ private function changeBillHost($pdo,$billid,$isNowHost) {
+ $sql = "SELECT host,closingid FROM %bill% WHERE id=?";
+ $stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
+ $stmt->execute(array($billid));
+ $row = $stmt->fetchObject();
+ if ($row->host != $isNowHost) {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_NOT_WO_HOST, "msg" => ERROR_BILL_NOT_WO_HOST_MSG));
+ return;
+ }
+ if (!is_null($row->closingid)) {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_ALREADY_CLOSED, "msg" => ERROR_BILL_ALREADY_CLOSED_MSG));
+ return;
+ }
+
+ $pdo->beginTransaction();
+
+ $sql = "SELECT queueid FROM %billproducts% WHERE billid=?";
+ $stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
+ $stmt->execute(array($billid));
+ $idsOfBill = $stmt->fetchAll();
+ $ids = array();
+ foreach($idsOfBill as $anId) {
+ $ids[] = $anId["queueid"];
+ }
+
+ $sql = "SELECT brutto,netto,tableid,paymentid,tax FROM %bill% WHERE id=?";
+ $stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
+ $stmt->execute(array($billid));
+ $row = $stmt->fetchObject();
+
+ $ok = $this->cancelBill($pdo, $billid, "", "OrderSprinter-Bewirtungseigenschaft", false, false, false);
+ if (!$ok) {
+ $pdo->rollBack();
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_CANCEL_IMOSSIBLE, "msg" => ERROR_BILL_CANCEL_IMOSSIBLE_MSG));
+ return;
+ }
+
+ $this->recreateBill($pdo, $ids, $row->brutto, $row->netto, $row->tableid, $row->paymentid, $row->tax, 1-$isNowHost);
+
+ $pdo->commit();
+
+ echo json_encode(array("status" => "OK", "code" => OK));
+ }
+
+ function recreateBill($pdo,$ids_array,$brutto,$netto,$tableid,$paymentId,$tax,$host) {
+
+ $userid = $this->getUserId();
+
+ // current time
+ date_default_timezone_set(DbUtils::getTimeZone());
+ $currentTime = date('Y-m-d H:i:s');
+
+ $billid = (-1);
+
+ // find highest bill id
+ $sql = "SELECT id from %bill% ORDER BY id DESC";
+ $stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
+ $stmt->execute();
+ $numberOfIds = $stmt->rowCount();
+ $row =$stmt->fetchObject();
+ $billid = intval($row->id)+1;
+ $commonUtils = new CommonUtils();
+ $commonUtils->setLastBillIdInWorkTable($pdo, $billid);
+
+ if (is_null($tableid)) {
+ $tableid = 0;
+ }
+
+ // now calculate the signature for the bill entry
+ $signature = $commonUtils->calcSignatureForBill($pdo,$currentTime, $brutto, $netto, '0.00', $userid);
+
+ $billInsertSql = "INSERT INTO `%bill%` (`id` , `billdate`,`brutto`,`netto`,`tableid`,`paymentid`,`userid`,`ref`,`tax`,`host`,`signature`) VALUES (?,?,?,?,?,?,?,NULL,NULL,?,?)";
+ $stmt = $pdo->prepare($this->dbutils->resolveTablenamesInSqlString($billInsertSql));
+ $stmt->execute(array($billid,$currentTime,$brutto,$netto,$tableid,$paymentId,$userid,$host,$signature));
+
+ // now declare them all to be paid:
+ for ($i=0;$iprepare(DbUtils::substTableAlias($updateSql));
+ $stmt->execute(array($currentTime,$billid,$queueid));
+
+ $billProdsSql = "INSERT INTO `%billproducts%` (`queueid`,`billid`) VALUES ( ?,?)";
+ $stmt = $pdo->prepare($this->dbutils->resolveTablenamesInSqlString($billProdsSql));
+ $stmt->execute(array($queueid,$billid));
+ }
+ }
+
/*
* Cancel a bill - set all queue items to not paid and drop the bill entry
*/
- private function cancelBill($billid,$stornocode,$reason) {
- $pdo = DbUtils::openDbAndReturnPdoStatic();
+ private function cancelBill($pdo,$billid,$stornocode,$reason,$doOwnTransaction,$doEcho,$checkStornoCode) {
// current time
date_default_timezone_set(DbUtils::getTimeZone());
$currentTime = date('Y-m-d H:i:s');
@@ -496,25 +600,35 @@ class Bill {
$numberOfVals = $row->countid;
if ($numberOfVals != 1) {
// stornocode not fixed
- echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_NOT_STORNO_CODE, "msg" => ERROR_BILL_NOT_STORNO_CODE_MSG));
- return;
+ if ($doEcho) {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_NOT_STORNO_CODE, "msg" => ERROR_BILL_NOT_STORNO_CODE_MSG));
+ }
+ return false;
}
$stornocodeInDb = $row->setting;
- if ($stornocode != $stornocodeInDb) {
- echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_WRONG_STORNO_CODE, "msg" => ERROR_BILL_WRONG_STORNO_CODE_MSG));
- return;
+ if ($checkStornoCode) {
+ if ($stornocode != $stornocodeInDb) {
+ if ($doEcho) {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_WRONG_STORNO_CODE, "msg" => ERROR_BILL_WRONG_STORNO_CODE_MSG));
+ }
+ return false;
+ }
}
if (!is_numeric($billid)) {
// this may be an attack...
- echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_WRONG_NUMERIC_VALUE, "msg" => ERROR_BILL_WRONG_NUMERIC_VALUE_MSG));
- return;
+ if ($doEcho) {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_WRONG_NUMERIC_VALUE, "msg" => ERROR_BILL_WRONG_NUMERIC_VALUE_MSG));
+ }
+ return false;
}
- // Do transactional cancel
- $pdo->beginTransaction();
+ // Do transactional cancel
+ if ($doOwnTransaction) {
+ $pdo->beginTransaction();
+ }
// is the bill already closed? In this case no cancel is allowed!
$sql = "SELECT brutto,netto,tax,tableid,closingid,status,paymentid FROM %bill% WHERE id=?";
@@ -536,31 +650,42 @@ class Bill {
if (!is_null($closingId) || ($status == 's') || ($status == 'x')) {
// no cancel possible anymore!
- $pdo->rollBack();
- if (($status == 's') || ($status == 'x')) {
- echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_ALREADY_CANCELLED, "msg" => ERROR_BILL_ALREADY_CANCELLED_MSG));
- } else {
- echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_ALREADY_CLOSED, "msg" => ERROR_BILL_ALREADY_CLOSED_MSG));
+ if ($doOwnTransaction) {
+ $pdo->rollBack();
}
-
- return;
+ if ($doEcho) {
+ if (($status == 's') || ($status == 'x')) {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_ALREADY_CANCELLED, "msg" => ERROR_BILL_ALREADY_CANCELLED_MSG));
+ } else {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_BILL_ALREADY_CLOSED, "msg" => ERROR_BILL_ALREADY_CLOSED_MSG));
+ }
+ }
+ return false;
}
// is bill correct with signature?
$commonUtils = new CommonUtils();
$correct = $commonUtils->verifyBill($pdo, $billid);
if (!$correct) {
- $pdo->rollBack();
- echo json_encode(array("status" => "ERROR", "code" => ERROR_INCONSISTENT_DB, "msg" => ERROR_INCONSISTENT_DB_MSG));
- return;
+ if ($doOwnTransaction) {
+ $pdo->rollBack();
+ }
+ if ($doEcho) {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_INCONSISTENT_DB, "msg" => ERROR_INCONSISTENT_DB_MSG));
+ }
+ return false;
}
// Test if it is allowed to insert new bill as storno bill or if manipulation has happened
$nextbillid = $this->testForNewBillIdAndUpdateWorkTable($pdo);
if ($nextbillid < 0) {
- echo json_encode(array("status" => "ERROR", "code" => ERROR_INCONSISTENT_DB, "msg" => ERROR_INCONSISTENT_DB_MSG));
- $pdo->rollBack();
- return;
+ if ($doEcho) {
+ echo json_encode(array("status" => "ERROR", "code" => ERROR_INCONSISTENT_DB, "msg" => ERROR_INCONSISTENT_DB_MSG));
+ }
+ if ($doOwnTransaction) {
+ $pdo->rollBack();
+ }
+ return false;
}
// 0. find the queueitems that are related to that bill
@@ -610,11 +735,15 @@ class Bill {
$stmt->execute(array($aQueueid,$refIdOfStornoEntry));
}
- $pdo->commit();
+ if ($doOwnTransaction) {
+ $pdo->commit();
+ }
// end of transactional cancel
- echo json_encode(array("status" => "OK", "code" => OK));
- return;
+ if ($doEcho) {
+ echo json_encode(array("status" => "OK", "code" => OK));
+ }
+ return true;
}
private function autoBackupPdfSummary($remoteaccesscode) {
@@ -780,6 +909,7 @@ class Bill {
}
$sql .= " AND %bill%.userid = %user%.id ";
$sql .= "ORDER BY billdate";
+
$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
if ($onlyClosingId == null) {
diff --git a/webapp/php/globals.php b/webapp/php/globals.php
index ae7781b..0205c5b 100644
--- a/webapp/php/globals.php
+++ b/webapp/php/globals.php
@@ -80,6 +80,11 @@ define ( 'PARSE_ERROR_MSG', 'Fehler beim Parsen');
define ( 'NUMBERFORMAT_ERROR', 27);
define ( 'NUMBERFORMAT_ERROR_MSG', 'Falsches Zahlenformat');
+define ( 'ERROR_BILL_NOT_WO_HOST', '28');
+define ( 'ERROR_BILL_NOT_WO_HOST_MSG', 'Bewirtungseigenschaft falsch');
+define ( 'ERROR_BILL_CANCEL_IMOSSIBLE', '7');
+define ( 'ERROR_BILL_CANCEL_IMOSSIBLE_MSG', 'Stornierung unmöglich');
+
define ( 'FOOD_PRINT_TYPE', 1);
define ( 'DRINK_PRINT_TYPE', 2);
define ( 'PAY_PRINT_TYPE', 3);
diff --git a/webapp/php/queuecontent.php b/webapp/php/queuecontent.php
index 6be8848..3ddeead 100644
--- a/webapp/php/queuecontent.php
+++ b/webapp/php/queuecontent.php
@@ -811,10 +811,17 @@ class QueueContent {
} else {
$price = $theChangedPrice;
}
+
+ // now check if the product is a togo article that might have been booked on a table
+ $togo = $aProd["togo"];
+
$tax = $normaltax;
if (is_null($theTableid)) {
$tax = $togotax;
}
+ if ($togo == 1) {
+ $tax = $togotax;
+ }
if (!is_null($row->tax)) {
$tax = $row->tax;
}
@@ -845,14 +852,14 @@ class QueueContent {
$ordertime = date('Y-m-d H:i:s');
$insertSql = "INSERT INTO `%queue%` (
- `id` , `tablenr`,`productid`,`pricelevel`,`price`,`tax`,`productname`,`ordertime`,`orderuser`,`anoption`,`readytime`,`delivertime`,`paidtime`,`billid`,`toremove`,`cooking`,`workprinted`)
+ `id` , `tablenr`,`productid`,`pricelevel`,`price`,`tax`,`productname`,`ordertime`,`orderuser`,`anoption`,`pricechanged`,`togo`,`readytime`,`delivertime`,`paidtime`,`billid`,`toremove`,`cooking`,`workprinted`)
VALUES (
- NULL , ?,?,?,?,?,?,?,?,?, '0000-00-00 00:00:00', '0000-00-00 00:00:00', NULL,NULL,'0',NULL,'0');";
+ NULL , ?,?,?,?,?,?,?,?,?,?,?, '0000-00-00 00:00:00', '0000-00-00 00:00:00', NULL,NULL,'0',NULL,'0');";
- $stmt = $pdo->prepare($this->dbutils->resolveTablenamesInSqlString($insertSql));
- $stmt->execute(array($theTableid,$productid,$currentPriceLevelId,$price,$tax,$productname,$ordertime,$_SESSION['userid'],$theOption));
+ $stmt = $pdo->prepare(DbUtils::substTableAlias($insertSql));
+ $stmt->execute(array($theTableid,$productid,$currentPriceLevelId,$price,$tax,$productname,$ordertime,$_SESSION['userid'],$theOption,($theChangedPrice == "NO" ? 0 : 1),$togo));
$queueid = $pdo->lastInsertId();
-
+
if (!is_null($extras) && ($extras != "")) {
for ($j=0;$jprepare(DbUtils::substTableAlias($sql));
foreach ($resultids as $anId) {
$stmt->execute(array($anId));
@@ -1032,6 +1039,9 @@ class QueueContent {
"id" =>$anId,
"longname" => $row->productname,
"option" => $row->anoption,
+ "pricechanged" => $row->pricechanged,
+ "togo" => $row->togo,
+ "price" => $row->price,
"extras" => $extras,
"isready" => $isReady,
"isPaid" => $isPaid,
@@ -1098,7 +1108,7 @@ class QueueContent {
function getJsonProductsOfTableToPay($tableid) {
$pdo = DbUtils::openDbAndReturnPdoStatic();
- $sql = "SELECT %queue%.id as id,longname,%queue%.price as price,%queue%.tax,%pricelevel%.name as pricelevelname,%products%.id as prodid
+ $sql = "SELECT %queue%.id as id,longname,%queue%.price as price,%queue%.tax,%pricelevel%.name as pricelevelname,%products%.id as prodid,%queue%.togo as togo
FROM %queue%
INNER JOIN %products% ON %queue%.productid = %products%.id
INNER JOIN %pricelevel% ON %queue%.pricelevel = %pricelevel%.id ";
@@ -1118,12 +1128,13 @@ class QueueContent {
$theTax = $zeile['tax'];
$thePriceLevelName = $zeile['pricelevelname'];
$longName = $zeile['longname'];
+ $togo = $zeile["togo"];
$queueid = $zeile['id'];
$extras = $this->getExtrasOfQueueItem($pdo,$queueid);
$prodId = $zeile['prodid'];
- $prodsToPay[] = array("id" => $queueid, "prodid" => $prodId, "longname" => $longName, "pricelevelname" => $thePriceLevelName, "price" => $thePrice, "tax" => $theTax, "extras" => $extras);
+ $prodsToPay[] = array("id" => $queueid, "prodid" => $prodId, "longname" => $longName, "pricelevelname" => $thePriceLevelName, "price" => $thePrice, "tax" => $theTax, "togo" => $togo, "extras" => $extras);
}
echo json_encode(array("status" => "OK", "msg" => $prodsToPay));
}
diff --git a/webapp/php/utilities/basedb.php b/webapp/php/utilities/basedb.php
index 4303722..565207a 100644
--- a/webapp/php/utilities/basedb.php
+++ b/webapp/php/utilities/basedb.php
@@ -495,6 +495,8 @@ class Basedb {
`ordertime` DATETIME NULL ,
`orderuser` INT(10) NOT NULL ,
`anoption` VARCHAR( 150 ) NULL ,
+ `pricechanged` INT(1) NULL ,
+ `togo` INT(1) NULL ,
`readytime` DATETIME NOT NULL,
`delivertime` DATETIME NULL,
`paidtime` DATETIME NULL,
diff --git a/webapp/preferences.html b/webapp/preferences.html
index ddd8315..b532020 100644
--- a/webapp/preferences.html
+++ b/webapp/preferences.html
@@ -5,7 +5,7 @@
-
+
diff --git a/webapp/products.html b/webapp/products.html
index 57721a9..c521416 100644
--- a/webapp/products.html
+++ b/webapp/products.html
@@ -7,7 +7,7 @@
-
+
diff --git a/webapp/rating.html b/webapp/rating.html
index 55b9ade..01d10c9 100644
--- a/webapp/rating.html
+++ b/webapp/rating.html
@@ -7,7 +7,7 @@
-
+
diff --git a/webapp/receiptutils.js b/webapp/receiptutils.js
index 04bb4f9..49c0015 100644
--- a/webapp/receiptutils.js
+++ b/webapp/receiptutils.js
@@ -92,7 +92,7 @@ function createReceiptFooterFromDbTaxes(lang, companyInfo,sum,taxes,decPoint) {
return footer;
}
-function generateOneProdLine(count,productname,price,pricelevelname,decPoint) {
+function generateOneProdLine(count,productname,price,pricelevelname,decPoint,togo) {
var priceStyle = 'style="border: solid black 0px;padding: 3px;text-align:right;vertical-align:bottom;"';
var noStyle = 'style="border: solid black 0px;padding: 3px;text-align:center;vertical-align:bottom;"';
@@ -101,6 +101,10 @@ function generateOneProdLine(count,productname,price,pricelevelname,decPoint) {
if (pricelevelname != "A") {
productname += " (" + pricelevelname + ")";
}
+ if (togo == 1) {
+ productname = "To-Go: " + productname;
+ }
+
var totalPrice = count * price;
var formattedTotal = totalPrice.toFixed(2).replace(".",decPoint);
@@ -134,10 +138,10 @@ function generateProdPart(decPoint,entryListForReceipt) {
var prodEntry = anEntry[1];
var productname = prodEntry.longname;
var price = prodEntry.price;
- var tax = prodEntry.tax;
+ var togo = prodEntry.togo;
var pricelevelname = prodEntry.pricelevelname;
- tablecontent += generateOneProdLine(count,productname,price,pricelevelname,decPoint);
+ tablecontent += generateOneProdLine(count,productname,price,pricelevelname,decPoint,togo);
}
return tablecontent;
}
diff --git a/webapp/reports.html b/webapp/reports.html
index 804d257..2792b2c 100644
--- a/webapp/reports.html
+++ b/webapp/reports.html
@@ -7,7 +7,7 @@
-
+
diff --git a/webapp/reservation.html b/webapp/reservation.html
index c68ea89..b591699 100644
--- a/webapp/reservation.html
+++ b/webapp/reservation.html
@@ -5,7 +5,7 @@
-
+
diff --git a/webapp/supplydesk.html b/webapp/supplydesk.html
index f2ac6ce..c9adc25 100644
--- a/webapp/supplydesk.html
+++ b/webapp/supplydesk.html
@@ -5,7 +5,7 @@
-
+
diff --git a/webapp/waiter.html b/webapp/waiter.html
index 047eaff..106d685 100644
--- a/webapp/waiter.html
+++ b/webapp/waiter.html
@@ -4,7 +4,7 @@
-
+
@@ -54,6 +54,8 @@ var W_FOOD_FOR = ["Speisen für","Food for","Comidas para"];
var W_DRINKS_FOR = ["Getränke für","Beverage for","Bebidas para"];
var W_ACT_NEW_ORD_EL = ["Aktion auswählen","Select action","Que acción?"];
var W_ACT_CHANGE = ["Ändern","Modify","Modificar"];
+var W_ACT_CHANGE_ALL = ["Alle Ändern","Modify all","Modificar todo"];
+var W_ACT_CHANGE_ONE = ["Einen Artikel ändern","Modify one item","Modificar un artículo"];
var W_APPLY = ["Anwenden","Apply","Aplicar"];
var W_CANCEL = ["Abbrechen","Cancel","Cancelar"];
var W_STILL_UNSENT_ORDERS = ["Es sind noch ungesendete Orders vorhanden!","There are unsent orders in the list","Hay elementos in la liste que no han enviados"];
@@ -81,6 +83,9 @@ var W_UNDELIVERED = ["nicht serviert (+ unbezahlt)","not served (and unpaid)","n
var W_MOVE_PRODS = ["Produkte verschieben","Move products","Productos a otra mesa"];
var W_NO_PRODS_SELECTED = ["Es wurden keine Produkte ausgewählt!","You have not chosen any products!","No ha seleccionado ningún producto!"];
+var CHANGE_ALL = 0;
+var CHANGE_ONE = 1
+
function Grouping(set,hashFct) {
// initialization during construction of class
this.set = set;
@@ -208,7 +213,8 @@ var groupedNewOrders = {
prodids: [],
extras: [],
origidxs: [],
- changedPrices: []
+ changedPrices: [],
+ togos: []
};
var levelOneType = 0; // first selectedtype under 0
@@ -313,7 +319,8 @@ function setLanguage(language) {
$("#actdiscount").html(discounttxt);
}
- $("#actionneworderconfirm").html(W_ACT_CHANGE[lang]);
+ $("#actionneworderconfirm_all").html(W_ACT_CHANGE_ALL[lang]);
+ $("#actionneworderconfirm_one").html(W_ACT_CHANGE_ONE[lang]);
$("#actionnewordercancel").html(W_CANCEL[lang]);
$("#select-comment").off("click").on("click", function (e) {
@@ -429,8 +436,7 @@ function generateSearchResults() {
e.preventDefault();
var prodid = this.id.split("_")[1];
selectedProdCount = getSearchProdCount(prodid);
- $("#searchField").val("");
- generateSearchResults();
+ clearSearchAndGoToHigherTypeIfExtrasOpen();
levelOneType = 0;
handleClickOnProd(prodid);
});
@@ -487,8 +493,7 @@ function initializeMainMenu(moduleEntries,menuid,user,version,forward) {
};
$(".modulebutton").off("click").on("click", function (e) {
var view = $(this).attr("href");
- doJsonAjax("POST","php/contenthandler.php?module=admin&command=setLastModuleOfUser",
- { view: view}, null, "Problem Benutzerdatenpflege");
+ doJsonAjaxAsync("POST","php/contenthandler.php?module=admin&command=setLastModuleOfUser",{ view: view}, null, "Problem Benutzerdatenpflege",false);
});
}
@@ -562,7 +567,7 @@ function hideMenuProd() {
});
}
-function addProductToQueueNoGuiUpdate(productid,option,extras,changedPrice) {
+function addProductToQueueNoGuiUpdate(productid,option,extras,changedPrice,togo) {
var prodprop = getProdProperties(productid);
var prodname = prodprop.name;
var prodprice = prodprop.price;
@@ -572,7 +577,8 @@ function addProductToQueueNoGuiUpdate(productid,option,extras,changedPrice) {
extras: extras,
prodid: productid,
price: prodprice,
- changedPrice : changedPrice
+ changedPrice : changedPrice,
+ togo: togo
};
for (var i=0;i";
}
var changedPrice = groupedNewOrders.changedPrices[i];
+ var togo = groupedNewOrders.togos[i];
var extrastxt = "";
var extras = groupedNewOrders.extras[i];
if ((extras != null ) && (extras != "")) {
@@ -644,10 +652,18 @@ function updateNewOrdersList() {
if (changedPrice != "NO") {
changedPrice = changedPrice.replace(".",decpoint);
- li += '