OrderSprinter 1.6.3

This commit is contained in:
Geno 2020-11-19 23:14:02 +01:00
parent 023ea7dc39
commit d42b9913e2
48 changed files with 305 additions and 168 deletions

View File

@ -58,3 +58,7 @@
top:0;bottom:0;margin:auto;position:absolute; top:0;bottom:0;margin:auto;position:absolute;
height:70px; height:70px;
} }
.emphasisForDeletion {
color: red;
font-weight: bold;
}

View File

@ -9,8 +9,8 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" href="css/gueststyle.css?v=1.6.2" /> <link rel="stylesheet" href="css/gueststyle.css?v=1.6.3" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/orderstyle.min.css?v=1.6.2" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/orderstyle.min.css?v=1.6.3" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-1.11.3.min.js"></script> <script src="php/3rdparty/jquery-1.11.3.min.js"></script>
@ -98,15 +98,12 @@
<p>Sollen noch weitere Speisen oder Getränke bestellt werden? <p>Sollen noch weitere Speisen oder Getränke bestellt werden?
<div id="askformoreyesno" style="display:none;"> <div id="askformoreyesno" style="display:none;">
<div class="ui-grid-a"> <button type="submit" data-theme="d" data-icon="back" id="askformorenobtn">Abbrechen</button>
<div class="ui-block-a"><button type="submit" data-theme="d" data-icon="back" id="askformorenobtn">Nein</button></div> <button type="submit" data-theme="f" data-icon="plus" id="askformoreyesbtn">Bestellung erweitern</button>
<div class="ui-block-b"><button type="submit" data-theme="f" data-icon="check" id="askformoreyesbtn">Ja</button></div> <button type="submit" data-theme="f" data-icon="check" id="sendordersbtn">Bestellung abschicken</button>
</div><!-- /grid-a -->
</div>
<div id="askformoreonlyyes" style="display:none;">
<button type="submit" data-theme="f" data-icon="check" id="askformoreyesbtn2">Ja</button>
</div> </div>
<br><br>
<p><p>Dies sind die für eine Bestellung ausgewählten Artikel. Mit einem Klick auf einen Artikel in der Liste kann dieser wieder <span class="emphasisForDeletion">entfernt</span> werden.
<p><div id="orderslist"></div> <p><div id="orderslist"></div>
@ -118,7 +115,7 @@
<div data-role="footer" data-theme="b" id="thefooter1"> <div data-role="footer" data-theme="b" id="thefooter1">
<div class="ui-grid-a"> <div class="ui-grid-a">
<div class="ui-block-a">&nbsp;&nbsp;OrderSprinter</div> <div class="ui-block-a">&nbsp;&nbsp;OrderSprinter</div>
<div class="ui-block-b grid_right" id="versioninfo">1.6.2&nbsp;&nbsp;</div> <div class="ui-block-b grid_right" id="versioninfo">1.6.3&nbsp;&nbsp;</div>
</div><!-- /grid-a --> </div><!-- /grid-a -->
</div> </div>
</div> </div>

View File

@ -114,10 +114,10 @@ if (isset($_POST['code'])) {
} else { } else {
echo "<html>"; echo "<html>";
echo "<head><title>Installation Gastsystem</title>"; echo "<head><title>Installation Gastsystem</title>";
echo '<link rel="stylesheet" type="text/css" href="css/gueststyle.css?v=1.6.2">'; echo '<link rel="stylesheet" type="text/css" href="css/gueststyle.css?v=1.6.3">';
echo "</head>"; echo "</head>";
echo "<body><div class=surround>"; echo "<body><div class=surround>";
echo "<span class=headerline>Installation OrderSprinter-Gastsystem 1.6.2</span><br><br>"; echo "<span class=headerline>Installation OrderSprinter-Gastsystem 1.6.3</span><br><br>";
echo "<form action='install.php' method='post'><input class=installfield name=code id=code type=text placeholder='Installationscode' />"; echo "<form action='install.php' method='post'><input class=installfield name=code id=code type=text placeholder='Installationscode' />";
echo "<br><input type=submit value='Installation starten' class=installbtn />"; echo "<br><input type=submit value='Installation starten' class=installbtn />";
echo "</form></div></html>"; echo "</form></div></html>";

File diff suppressed because one or more lines are too long

View File

@ -6,16 +6,20 @@ defined('DB') || define ( 'DB','mysql' );
require_once 'ossystem.php'; require_once 'ossystem.php';
class Queue { class Queue {
public static function putintoqueue($pdo,$prodid,$tableid,$tablecode,$dailycode) { public static function putintoqueue($pdo,$ordertime,$tableid,$tablecode,$dailycode,$orders) {
$timezone = DbUtils::getConfigItem($pdo, "timezone", "Europe/Berlin"); $timezone = DbUtils::getConfigItem($pdo, "timezone", "Europe/Berlin");
date_default_timezone_set($timezone); date_default_timezone_set($timezone);
$ordertime = date('Y-m-d H:i:s'); $ordertime = date('Y-m-d H:i:s');
if (DB == "mysql") { if (DB == "mysql") {
$pdo->beginTransaction(); $pdo->beginTransaction();
$sql = "INSERT INTO %queue% (date,prodid,tableid,tablecode,dailycode) VALUES(?,?,?,?,?)"; $sql = "INSERT INTO %queue% (date,prodid,tableid,tablecode,dailycode) VALUES(?,?,?,?,?)";
DbUtils::execSql($pdo, $sql, array($ordertime,$prodid,$tableid,$tablecode,$dailycode)); foreach($orders as $anOrder) {
$pdo->commit(); $prodid = $anOrder["prodid"];
DbUtils::log("Added product with id $prodid to mysql queue table"); DbUtils::execSql($pdo, $sql, array($ordertime,$prodid,$tableid,$tablecode,$dailycode));
$pdo->commit();
DbUtils::log("Added product with id $prodid to mysql queue table");
}
return array("status" => "OK"); return array("status" => "OK");
} else { } else {
$filename = dirname(__FILE__) . '/../db/' . QUEUE_FILE; $filename = dirname(__FILE__) . '/../db/' . QUEUE_FILE;
@ -25,9 +29,12 @@ class Queue {
$queueItemsFileContent = file_get_contents($filename); $queueItemsFileContent = file_get_contents($filename);
$queueItems = json_decode($queueItemsFileContent,true); $queueItems = json_decode($queueItemsFileContent,true);
} }
$queueItems[] = array("date" => $ordertime,"prodid" => $prodid,"tableid" => $tableid, "tablecode" => $tablecode, "dailycode" => $dailycode); foreach($orders as $anOrder) {
file_put_contents($filename, json_encode($queueItems)); $prodid = $anOrder["prodid"];
DbUtils::log("Add product with id $prodid to file queue"); $queueItems[] = array("date" => $ordertime,"prodid" => $prodid,"tableid" => $tableid, "tablecode" => $tablecode, "dailycode" => $dailycode);
file_put_contents($filename, json_encode($queueItems));
DbUtils::log("Add product with id $prodid to file queue");
}
return array("status" => "OK"); return array("status" => "OK");
} catch (Exception $ex) { } catch (Exception $ex) {
return array("status" => "ERROR","msg" => $ex->getMessage()); return array("status" => "ERROR","msg" => $ex->getMessage());
@ -47,7 +54,7 @@ if (isset($_GET["command"])) {
switch ($command) { switch ($command) {
case "putintoqueue": case "putintoqueue":
$ret = Queue::putintoqueue($pdo,$_POST["prodid"],$_POST["tableid"],$_POST["tablecode"],$_POST["dailycode"]); $ret = Queue::putintoqueue($pdo,$_POST["ordertime"],$_POST["tableid"],$_POST["tablecode"],$_POST["dailycode"],$_POST["orders"]);
echo json_encode($ret); echo json_encode($ret);
break; break;

View File

@ -85,7 +85,7 @@ class Installer {
} }
Database::dropTables($pdo); Database::dropTables($pdo);
Database::createEmptyTables($pdo, $prefix); Database::createEmptyTables($pdo, $prefix);
Database::setVersion($pdo,$prefix,"1.6.2"); Database::setVersion($pdo,$prefix,"1.6.3");
Database::setAccessPassword($pdo,$prefix,$adminpass); Database::setAccessPassword($pdo,$prefix,$adminpass);
Database::setRefreshRate($pdo,$prefix,"5"); // default: 5 times per hour Database::setRefreshRate($pdo,$prefix,"5"); // default: 5 times per hour
return array("status" => "OK","msg" => "Installation successful"); return array("status" => "OK","msg" => "Installation successful");

Binary file not shown.

View File

@ -5,7 +5,7 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -13,8 +13,8 @@
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<script src="kitchenbar.js?v=1.6.2"></script> <script src="kitchenbar.js?v=1.6.3"></script>
<style> <style>
#tableWithEntriesToCook,#tableWithCookedEntries,#headertableToCook #tableWithEntriesToCook,#tableWithCookedEntries,#headertableToCook

File diff suppressed because one or more lines are too long

View File

@ -7,7 +7,7 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -23,7 +23,7 @@
<link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" /> <link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" />
<script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script> <script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script>
<script src="php/3rdparty/jqueryui1-11-4/jquery-ui-i18n.min.js"></script> <script src="php/3rdparty/jqueryui1-11-4/jquery-ui-i18n.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<script src="elements/customers.js"></script> <script src="elements/customers.js"></script>
</head> </head>

View File

@ -4,7 +4,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="css/ospage.css" /> <link rel="stylesheet" href="css/ospage.css" />
@ -17,7 +17,7 @@
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<script src="receiptutils.js"></script> <script src="receiptutils.js"></script>
<script src="elements/dash.js"></script> <script src="elements/dash.js"></script>
<script src="php/3rdparty/Chart.bundle.min.js"></script> <script src="php/3rdparty/Chart.bundle.min.js"></script>

View File

@ -163,7 +163,7 @@ function Groundplan() {
$("#createtableqrcodesbtn").off("click").on("click", function (e) { $("#createtableqrcodesbtn").off("click").on("click", function (e) {
e.stopImmediatePropagation(); e.stopImmediatePropagation();
e.preventDefault(); e.preventDefault();
window.open("php/contenthandler.php?module=roomtables&command=tableqrcodes&v=1.6.2",'_blank'); window.open("php/contenthandler.php?module=roomtables&command=tableqrcodes&v=1.6.3",'_blank');
}); });
this.bindRoomChanges(); this.bindRoomChanges();

View File

@ -4,7 +4,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -12,7 +12,7 @@
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<script src="kitchenbar.js"></script> <script src="kitchenbar.js"></script>
<style> <style>

View File

@ -9,8 +9,8 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" type="text/css" href="css/numfield.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/numfield.css?v=1.6.3">
<link rel="stylesheet" href="php/3rdparty/orderstyle/orderstyle.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/orderstyle.min.css" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -18,7 +18,7 @@
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
</head> </head>
<body> <body>

BIN
webapp/img/oops.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

View File

@ -9,8 +9,8 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" type="text/css" href="css/numfield.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/numfield.css?v=1.6.3">
<link rel="stylesheet" href="php/3rdparty/orderstyle/orderstyle.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/orderstyle.min.css" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -18,7 +18,7 @@
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
</head> </head>
<body> <body>
@ -132,6 +132,7 @@ function displayLoginOrLogoutMask(jsonContent) {
// user needs to log in! // user needs to log in!
$("#passwordfield").val(""); $("#passwordfield").val("");
$("#logoutarea").hide(); $("#logoutarea").hide();
setTimeout(function(){document.location.href = "index.html?v=1.6.3"},250);
} }
} }
@ -231,7 +232,7 @@ function handleResultOfInstallCheck(is_installed) {
if (is_installed == "Yes") { if (is_installed == "Yes") {
useInstallation(); useInstallation();
} else { } else {
setTimeout(function(){document.location.href = "install.html?v=1.6.2"},500); setTimeout(function(){document.location.href = "install.html?v=1.6.3"},500);
} }
} }
@ -256,12 +257,21 @@ function handleCompanyInfo(answer) {
} }
function useInstallation() { function useInstallation() {
initializeMainMenu("#modulemenu"); var urlsuffix = urlsuffix = location.search;
hideMenu(); if (urlsuffix.indexOf('a=') >= 0) {
askAndFillUserList(); var authInfo = getUrlGetParameter(urlsuffix,"a=");
isUserAlreadyLoggedIn(); var parts = authInfo.split("_");
binding(); var hash = parts[0];
askForCompanyInfo(); var userid = parts[1];
tryAuthenticate(userid,hash,2);
} else {
initializeMainMenu("#modulemenu");
hideMenu();
askAndFillUserList();
isUserAlreadyLoggedIn();
binding();
askForCompanyInfo();
}
} }
$(document).on("pageinit", "#index-page", function () { $(document).on("pageinit", "#index-page", function () {
@ -285,11 +295,11 @@ $(document).on("pageinit", "#index-page", function () {
<div data-role="content"> <div data-role="content">
<p><div id="toplogolocation" style="text-align: center;display:none;"><img src="php/contenthandler.php?module=printqueue&command=getLogoAsPngWithAlphaChannel&v=1.6.2&style=always" style="max-height:150px;"/></div> <p><div id="toplogolocation" style="text-align: center;display:none;"><img src="php/contenthandler.php?module=printqueue&command=getLogoAsPngWithAlphaChannel&v=1.6.3&style=always" style="max-height:150px;"/></div>
<div data-role="collapsible" data-content-theme="c" data-collapsed="false" data-theme="e" id="loginmask"> <div data-role="collapsible" data-content-theme="c" data-collapsed="false" data-theme="e" id="loginmask">
<H2>Anmelden</H2> <H2>Anmelden</H2>
<p><div id="middlelogolocation" style="text-align: left;padding-left: 80px;padding-right:80px;display:none;"><img src="php/contenthandler.php?module=printqueue&command=getLogoAsPngWithAlphaChannel&v=1.6.2&style=always" style="max-height:150px;"/></div> <p><div id="middlelogolocation" style="text-align: left;padding-left: 80px;padding-right:80px;display:none;"><img src="php/contenthandler.php?module=printqueue&command=getLogoAsPngWithAlphaChannel&v=1.6.3&style=always" style="max-height:150px;"/></div>
<form method="post"> <form method="post">
<table border=0> <table border=0>

View File

@ -915,7 +915,7 @@ El servicio web OrderSprinter no requiere una conexión a Internet. Sin embargo,
<tr id=updateline> <tr id=updateline>
<td>&nbsp;</td> <td>&nbsp;</td>
<td align=center> <td align=center>
<button id="updatebtn">Update -> 1.6.2</button> <button id="updatebtn">Update -> 1.6.3</button>
<span id="updateinprogresstxt" style="display:none;"><img id="installprogressindicator" src="php/3rdparty/images/ajax-loader.gif" alt="Progress indication" style="display:none;"/> Update... bitte warten.</span> <span id="updateinprogresstxt" style="display:none;"><img id="installprogressindicator" src="php/3rdparty/images/ajax-loader.gif" alt="Progress indication" style="display:none;"/> Update... bitte warten.</span>
</td> </td>
<td>&nbsp;</td> <td>&nbsp;</td>

View File

@ -455,7 +455,7 @@ return;
} }
set_time_limit(60*30); set_time_limit(60*30);
$installerVersion = "1.6.2"; $installerVersion = "1.6.3";
$admin = new InstallAdmin(); $admin = new InstallAdmin();
$pdo = $admin->openDbAndReturnPdo($_POST['host'],$_POST['db'],$_POST['user'],$_POST['password']); $pdo = $admin->openDbAndReturnPdo($_POST['host'],$_POST['db'],$_POST['user'],$_POST['password']);

View File

@ -5,7 +5,7 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -13,8 +13,8 @@
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<script src="kitchenbar.js?v=1.6.2"></script> <script src="kitchenbar.js?v=1.6.3"></script>
<style> <style>
#tableWithEntriesToCook,#tableWithCookedEntries,#headertableToCook #tableWithEntriesToCook,#tableWithCookedEntries,#headertableToCook

View File

@ -5,7 +5,7 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -13,10 +13,10 @@
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-1.11.3.min.js"></script> <script src="php/3rdparty/jquery-1.11.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<script src="elements/tablemap.js?v=1.6.2"></script> <script src="elements/tablemap.js?v=1.6.3"></script>
<script src="elements/roommap.js?v=1.6.2"></script> <script src="elements/roommap.js?v=1.6.3"></script>
<script src="elements/groundplan.js?v=1.6.2"></script> <script src="elements/groundplan.js?v=1.6.3"></script>
<link href="php/3rdparty/hayageek_uploadfile.css" rel="stylesheet"> <link href="php/3rdparty/hayageek_uploadfile.css" rel="stylesheet">
<script src="php/3rdparty/hayageek_jquery_uploadfile.js"></script> <script src="php/3rdparty/hayageek_jquery_uploadfile.js"></script>
@ -170,9 +170,9 @@ var MAN_DIGI_PRINTWORK_HINT = ["Sollen Arbeitsbon erstellt werden, wenn in der K
var MAN_PRINT_AND_QUEUE_HINT = ["Wird dieser Wert auf 'ja' gesetzt, so werden die Druckaufträge im digitalen Workflow zusätzlich auf Arbeitsbons ausgedruckt.", var MAN_PRINT_AND_QUEUE_HINT = ["Wird dieser Wert auf 'ja' gesetzt, so werden die Druckaufträge im digitalen Workflow zusätzlich auf Arbeitsbons ausgedruckt.",
"If this setting is set to 'yes' in the digital workflow the orders are additionally printed.", "If this setting is set to 'yes' in the digital workflow the orders are additionally printed.",
"Si el valor esta 'si', orders van a ser imprimidos también en el modo digital."]; "Si el valor esta 'si', orders van a ser imprimidos también en el modo digital."];
var MAN_CASH_HINT = ["Ist Schnellkasse aktiviert, werden alle Bestellungen mit der Übermittlung an den Server als bar bezahlt deklariert.", var MAN_CASH_HINT = ["Ist Schnellkasse aktiviert, werden alle Bestellungen mit der Übermittlung an den Server als bar bezahlt deklariert. Ist die Einstellung 'Erzwinge Bondruck' aktiviert, so wird stets ein Kassenbon gedruckt.",
"If quick cash is activated every order will be declared as paid by cash automatically.", "If quick cash is activated every order will be declared as paid by cash automatically. If the setting 'Force print of receipt' is enabled, a receipt is printed everytime.",
"Si configurado Factura rapida cada order va a ser declarada pagada."]; "Si configurado Factura rapida cada order va a ser declarada pagada. Si la configuración 'Siempre imprimir factura' esta activada, una factura va a imprimido con cada factura rapida."];
var MAN_RETURN_TO_ORDER_HINT = ["Wird der Wert auf 'ja' gesetzt, so wechselt die Desktopansicht automatisch wieder in den Bestellmodus über, nachdem ein ausgewählter Tisch komplett abgerechnet oder im Kassenmodus auf einen leeren Tisch geklickt wurde.", var MAN_RETURN_TO_ORDER_HINT = ["Wird der Wert auf 'ja' gesetzt, so wechselt die Desktopansicht automatisch wieder in den Bestellmodus über, nachdem ein ausgewählter Tisch komplett abgerechnet oder im Kassenmodus auf einen leeren Tisch geklickt wurde.",
"If this value is set to 'true' the mode of the desktop view automatically returns to the ordering after all products of the selected table are marked paid or an empty table was selected.", "If this value is set to 'true' the mode of the desktop view automatically returns to the ordering after all products of the selected table are marked paid or an empty table was selected.",
"Si es 'si' el modus vuelve a ordenar despues de declarar todos los productos de la mesa estado pagado o si el usario ha seleccionado una mesa vacia."]; "Si es 'si' el modus vuelve a ordenar despues de declarar todos los productos de la mesa estado pagado o si el usario ha seleccionado una mesa vacia."];
@ -410,7 +410,7 @@ var MAN_DBLOG = ["Debug-Logging","Debug logging","Debug logging"];
var MAN_SHOWTRANSFERBTNS = ["'Bestellung senden'- und/oder 'Arbeitsbon'-Button einblenden","Show buttons for send orders and/or work receipts","Mostrar botones para transmitir ordenes"]; var MAN_SHOWTRANSFERBTNS = ["'Bestellung senden'- und/oder 'Arbeitsbon'-Button einblenden","Show buttons for send orders and/or work receipts","Mostrar botones para transmitir ordenes"];
var MAN_PRINT_EXTRAS = ["Extras auf Kassenbon","Print extras on receipts","Imprimir extras en tiquet"]; var MAN_PRINT_EXTRAS = ["Extras auf Kassenbon","Print extras on receipts","Imprimir extras en tiquet"];
var MAN_PRINT_EXTRAS_HINT = ["Hinweis: Extras auf Kassenbon erst ab Printserverversion 1.4.17 möglich.","Hint: Extras on receipt require printserver version 1.4.17+","Nota: Imprimir extras exije printserver 1.4.17+"]; var MAN_PRINT_EXTRAS_HINT = ["Hinweis: Extras auf Kassenbon erst ab Printserverversion 1.4.17 möglich.","Hint: Extras on receipt require printserver version 1.4.17+","Nota: Imprimir extras exije printserver 1.4.17+"];
var MAN_FORCE_PRINT = ["Erzwinge Bondruck","Force print of receipt","Siempre imprimir tique"]; var MAN_FORCE_PRINT = ["Erzwinge Bondruck","Force print of receipt","Siempre imprimir factura"];
var MAN_PRICE_IN_LIST = ["Preisangabe neben Produkt","List price next to product","Mostrar precio en lista de productos"]; var MAN_PRICE_IN_LIST = ["Preisangabe neben Produkt","List price next to product","Mostrar precio en lista de productos"];
var MAN_GUEST_JOB_PRINT = ["Gastbestelljob drucken","Print guest order","Imprimir orden de remote"]; var MAN_GUEST_JOB_PRINT = ["Gastbestelljob drucken","Print guest order","Imprimir orden de remote"];
var MAN_GUEST_JOB_PRINT_HINT = ["Wird der Gastbestelljob nicht gedruckt, so durchläuft er die digitalen Workflowansichten Küche/Bar/Bereitstellung je nach Konfiguration der Produktkategorie. Im anderen Fall wird ein Arbeitsbon gedruckt.","If the guest order job is not printed, it passes through the digital workflow views Kitchen/Bar/Provision depending on the configuration of the product category. Otherwise, a receipt is printed.","Si el trabajo de pedido de invitados no se imprime, pasa a través de las vistas de flujo de trabajo digital Cocina/Bar/Provisión en función de la configuración de la categoría de producto. De lo contrario, se imprimirá un recibo."]; var MAN_GUEST_JOB_PRINT_HINT = ["Wird der Gastbestelljob nicht gedruckt, so durchläuft er die digitalen Workflowansichten Küche/Bar/Bereitstellung je nach Konfiguration der Produktkategorie. Im anderen Fall wird ein Arbeitsbon gedruckt.","If the guest order job is not printed, it passes through the digital workflow views Kitchen/Bar/Provision depending on the configuration of the product category. Otherwise, a receipt is printed.","Si el trabajo de pedido de invitados no se imprime, pasa a través de las vistas de flujo de trabajo digital Cocina/Bar/Provisión en función de la configuración de la categoría de producto. De lo contrario, se imprimirá un recibo."];
@ -1710,7 +1710,7 @@ function initRestoreFileUpload() {
} else { } else {
alert("Import war erfolgreich."); alert("Import war erfolgreich.");
setTimeout(function(){ setTimeout(function(){
document.location.href = "index.html?v=1.6.2"; document.location.href = "index.html?v=1.6.3";
},250); },250);
} }
}, },
@ -2194,38 +2194,38 @@ function binding() {
$("#backup_btn").off("click").on("click", function (e) { $("#backup_btn").off("click").on("click", function (e) {
e.stopImmediatePropagation(); e.stopImmediatePropagation();
e.preventDefault(); e.preventDefault();
window.location.href = "php/contenthandler.php?module=admin&command=backup&type=configuration&v=1.6.2"; window.location.href = "php/contenthandler.php?module=admin&command=backup&type=configuration&v=1.6.3";
}); });
$("#backup_btnall").off("click").on("click", function (e) { $("#backup_btnall").off("click").on("click", function (e) {
e.stopImmediatePropagation(); e.stopImmediatePropagation();
e.preventDefault(); e.preventDefault();
window.location.href = "php/contenthandler.php?module=admin&command=backup&type=all&v=1.6.2"; window.location.href = "php/contenthandler.php?module=admin&command=backup&type=all&v=1.6.3";
}); });
$("#backup_btnalllogs").off("click").on("click", function (e) { $("#backup_btnalllogs").off("click").on("click", function (e) {
e.stopImmediatePropagation(); e.stopImmediatePropagation();
e.preventDefault(); e.preventDefault();
window.location.href = "php/contenthandler.php?module=admin&command=backup&type=alllogs&v=1.6.2"; window.location.href = "php/contenthandler.php?module=admin&command=backup&type=alllogs&v=1.6.3";
}); });
$("#backup_btnftpall").off("click").on("click", function (e) { $("#backup_btnftpall").off("click").on("click", function (e) {
e.stopImmediatePropagation(); e.stopImmediatePropagation();
e.preventDefault(); e.preventDefault();
showProgressPopup(); showProgressPopup();
doAjax("GET","php/contenthandler.php?module=admin&command=ftpbackup&type=all&v=1.6.2",null,handleFtpResult,null); doAjax("GET","php/contenthandler.php?module=admin&command=ftpbackup&type=all&v=1.6.3",null,handleFtpResult,null);
}); });
$("#backup_debugdata").off("click").on("click", function (e) { $("#backup_debugdata").off("click").on("click", function (e) {
e.stopImmediatePropagation(); e.stopImmediatePropagation();
e.preventDefault(); e.preventDefault();
window.open("php/contenthandler.php?module=admin&command=backup&type=debugdata&v=1.6.2",'_blank'); window.open("php/contenthandler.php?module=admin&command=backup&type=debugdata&v=1.6.3",'_blank');
}); });
$("#backupguests_btn").off("click").on("click", function (e) { $("#backupguests_btn").off("click").on("click", function (e) {
e.stopImmediatePropagation(); e.stopImmediatePropagation();
e.preventDefault(); e.preventDefault();
window.location.href = "php/contenthandler.php?module=admin&command=backup&type=confandguests&v=1.6.2"; window.location.href = "php/contenthandler.php?module=admin&command=backup&type=confandguests&v=1.6.3";
}); });
$("#golive").off("click").on("click", function (e) { $("#golive").off("click").on("click", function (e) {
@ -2406,7 +2406,7 @@ function updateOneSingleFile() {
setTimeout(function(){ setTimeout(function(){
$("#sliderarea").hide(); $("#sliderarea").hide();
var millis=getMillis(); var millis=getMillis();
document.location.href = "install.html?v=1.6.2&mode=onlyupdate&n=" + millis; document.location.href = "install.html?v=1.6.3&mode=onlyupdate&n=" + millis;
},250); },250);
} }
} }

9
webapp/nfclogin.php Normal file
View File

@ -0,0 +1,9 @@
<?php
if(session_id() == '') {
session_start();
session_destroy();
}
$arg = $_GET["a"];
header('Location: index.html?a=' . $arg);

File diff suppressed because one or more lines are too long

View File

@ -529,7 +529,6 @@ class Admin {
return; return;
} }
$sql = "SELECT *,%user%.id as id FROM %user%,%roles% WHERE %user%.id=? AND active='1' AND %user%.roleid=%roles%.id"; $sql = "SELECT *,%user%.id as id FROM %user%,%roles% WHERE %user%.id=? AND active='1' AND %user%.roleid=%roles%.id";
$result = CommonUtils::fetchSqlAll($pdo, $sql, array($userid)); $result = CommonUtils::fetchSqlAll($pdo, $sql, array($userid));
@ -544,11 +543,18 @@ class Admin {
// password_verify requires PHP > 5.5, so let's use MD5 instead // password_verify requires PHP > 5.5, so let's use MD5 instead
// (it is no banking software...) // (it is no banking software...)
if (md5($password) == $pass_hash) { $passHashToCheck = md5($password);
if ($modus == 2) {
$passHashToCheck = $password;
}
if ($passHashToCheck == $pass_hash) {
$authenticated = true; $authenticated = true;
} }
} }
if ($modus == 2) {
$modus = CommonUtils::getConfigValue($pdo, "defaultview", 0);
}
if ($authenticated) { if ($authenticated) {
date_default_timezone_set(DbUtils::getTimeZone()); date_default_timezone_set(DbUtils::getTimeZone());
$now = getdate(); $now = getdate();
@ -1437,7 +1443,7 @@ class Admin {
$view = "preferences.html"; $view = "preferences.html";
} }
echo json_encode($view . "?v=1.6.2"); echo json_encode($view . "?v=1.6.3");
} }
} }
@ -1658,31 +1664,31 @@ class Admin {
if (!self::isOnlyRatingUser($rights, $right_rating, true)) { if (!self::isOnlyRatingUser($rights, $right_rating, true)) {
if ($_SESSION['modus'] == 0) { if ($_SESSION['modus'] == 0) {
if ($_SESSION['right_waiter']) { $mainMenu[] = array("name" => $waitertxt[$lang], "link" => "waiter.html?v=1.6.2"); } if ($_SESSION['right_waiter']) { $mainMenu[] = array("name" => $waitertxt[$lang], "link" => "waiter.html?v=1.6.3"); }
} else { } else {
if ($_SESSION['right_waiter']) { $mainMenu[] = array("name" => $waiterdesktxt[$lang], "link" => "waiterdesktop.php?v=1.6.2"); } if ($_SESSION['right_waiter']) { $mainMenu[] = array("name" => $waiterdesktxt[$lang], "link" => "waiterdesktop.php?v=1.6.3"); }
} }
if ($_SESSION['right_kitchen']) { $mainMenu[] = array("name" => $kitchentxt[$lang], "link" => "kitchen.html?v=1.6.2"); } if ($_SESSION['right_kitchen']) { $mainMenu[] = array("name" => $kitchentxt[$lang], "link" => "kitchen.html?v=1.6.3"); }
if ($_SESSION['right_bar']) { $mainMenu[] = array("name" => "Bar", "link" => "bar.html?v=1.6.2"); } if ($_SESSION['right_bar']) { $mainMenu[] = array("name" => "Bar", "link" => "bar.html?v=1.6.3"); }
if ($_SESSION['right_supply']) { $mainMenu[] = array("name" => $supplytxt[$lang], "link" => "supplydesk.html?v=1.6.2"); } if ($_SESSION['right_supply']) { $mainMenu[] = array("name" => $supplytxt[$lang], "link" => "supplydesk.html?v=1.6.3"); }
if ($_SESSION['modus'] == 0) { if ($_SESSION['modus'] == 0) {
if ($_SESSION['right_paydesk']) { $mainMenu[] = array("name" => $paydesktxt[$lang], "link" => "paydesk.html?v=1.6.2"); } if ($_SESSION['right_paydesk']) { $mainMenu[] = array("name" => $paydesktxt[$lang], "link" => "paydesk.html?v=1.6.3"); }
} }
if ($_SESSION['right_statistics']) { $mainMenu[] = array("name" => $stattxt[$lang], "link" => "reports.html?v=1.6.2"); } if ($_SESSION['right_statistics']) { $mainMenu[] = array("name" => $stattxt[$lang], "link" => "reports.html?v=1.6.3"); }
if ($_SESSION['right_bill']) { $mainMenu[] = array("name" => $bontxt[$lang], "link" => "bill.html?v=1.6.2"); } if ($_SESSION['right_bill']) { $mainMenu[] = array("name" => $bontxt[$lang], "link" => "bill.html?v=1.6.3"); }
if ($_SESSION['right_products']) { $mainMenu[] = array("name" => $prodtxt[$lang], "link" => "products.html?v=1.6.2"); } if ($_SESSION['right_products']) { $mainMenu[] = array("name" => $prodtxt[$lang], "link" => "products.html?v=1.6.3"); }
if ($_SESSION['right_reservation']) { $mainMenu[] = array("name" => $restxt[$lang], "link" => "reservation.html?v=1.6.2"); } if ($_SESSION['right_reservation']) { $mainMenu[] = array("name" => $restxt[$lang], "link" => "reservation.html?v=1.6.3"); }
if ($_SESSION['right_tasks'] || $_SESSION['right_tasksmanagement']) { $mainMenu[] = array("name" => $taskstxt[$lang], "link" => "tasks.html?v=1.6.2"); } if ($_SESSION['right_tasks'] || $_SESSION['right_tasksmanagement']) { $mainMenu[] = array("name" => $taskstxt[$lang], "link" => "tasks.html?v=1.6.3"); }
if ($_SESSION['right_rating']) { $mainMenu[] = array("name" => $ratingtxt[$lang], "link" => "rating.html?v=1.6.2"); } if ($_SESSION['right_rating']) { $mainMenu[] = array("name" => $ratingtxt[$lang], "link" => "rating.html?v=1.6.3"); }
if ($_SESSION['right_customers']) { $mainMenu[] = array("name" => $customerstxt[$lang], "link" => "customers.html?v=1.6.2"); } if ($_SESSION['right_customers']) { $mainMenu[] = array("name" => $customerstxt[$lang], "link" => "customers.html?v=1.6.3"); }
if ($_SESSION['right_pickups']) { $mainMenu[] = array("name" => $pickupstxt[$lang], "link" => "pickups.html?v=1.6.2"); } if ($_SESSION['right_pickups']) { $mainMenu[] = array("name" => $pickupstxt[$lang], "link" => "pickups.html?v=1.6.3"); }
if ($_SESSION['right_dash']) { $mainMenu[] = array("name" => $dashtxt[$lang], "link" => "dash.php?v=1.6.2"); } if ($_SESSION['right_dash']) { $mainMenu[] = array("name" => $dashtxt[$lang], "link" => "dash.php?v=1.6.3"); }
if ($_SESSION['right_manager'] || $_SESSION['is_admin'] || $_SESSION['right_closing']) { $mainMenu[] = array("name" => $admintxt[$lang], "link" => "manager.html?v=1.6.2"); } if ($_SESSION['right_manager'] || $_SESSION['is_admin'] || $_SESSION['right_closing']) { $mainMenu[] = array("name" => $admintxt[$lang], "link" => "manager.html?v=1.6.3"); }
$mainMenu[] = array("name" => $settingtxt[$lang], "link" => "preferences.html?v=1.6.2"); $mainMenu[] = array("name" => $settingtxt[$lang], "link" => "preferences.html?v=1.6.3");
if ($_SESSION['right_timetracking'] || $_SESSION['right_timemanager']) { $mainMenu[] = array("name" => $timetrackingtxt[$lang], "link" => "timetracking.html?v=1.6.2"); } if ($_SESSION['right_timetracking'] || $_SESSION['right_timemanager']) { $mainMenu[] = array("name" => $timetrackingtxt[$lang], "link" => "timetracking.html?v=1.6.3"); }
$mainMenu[] = array("name" => "Hilfe", "link" => "help.php?v=1.6.2"); $mainMenu[] = array("name" => "Hilfe", "link" => "help.php?v=1.6.3");
$mainMenu[] = array("name" => "Feedback", "link" => "feedback.html?v=1.6.2"); $mainMenu[] = array("name" => "Feedback", "link" => "feedback.html?v=1.6.3");
} }
$mainMenu[] = array("name" => $logout[$lang], "link" => "logout.php"); $mainMenu[] = array("name" => $logout[$lang], "link" => "logout.php");

View File

@ -469,4 +469,12 @@ class CommonUtils {
return $imagedata; return $imagedata;
} }
public static function getFirstSqlQuery($pdo,$sql,$params,$default) {
$result = self::fetchSqlAll($pdo, $sql, $params);
if (count($result) > 0) {
return $result[0]["value"];
} else {
return $default;
}
}
} }

View File

@ -878,7 +878,7 @@ class Customers {
$txt = "<head>"; $txt = "<head>";
$txt .= "<title>" . self::$CUS_OVERVIEW[$lang] . "</title>"; $txt .= "<title>" . self::$CUS_OVERVIEW[$lang] . "</title>";
$txt .= '<meta http-equiv="content-type" content="text/html; charset=utf-8">'; $txt .= '<meta http-equiv="content-type" content="text/html; charset=utf-8">';
$txt .= '<link rel="stylesheet" type="text/css" href="../css/guestreport.css?v=1.6.2">'; $txt .= '<link rel="stylesheet" type="text/css" href="../css/guestreport.css?v=1.6.3">';
$txt .= "</head>"; $txt .= "</head>";
return $txt; return $txt;
} }

View File

@ -27,7 +27,7 @@ if (isset($_POST["cmd"])) {
if (strlen($status) > 150) { if (strlen($status) > 150) {
$status = substr($status, 0,149); $status = substr($status, 0,149);
} }
$version = "1.6.2"; $version = "1.6.3";
$arr = array("cmd" => $cmd,"fct" => $fct, "xhr" => $xhr,"errormsg" => $errormsg,"status" => $status,"version" => $version,"phpversion" => $phpversion); $arr = array("cmd" => $cmd,"fct" => $fct, "xhr" => $xhr,"errormsg" => $errormsg,"status" => $status,"version" => $version,"phpversion" => $phpversion);
} else { } else {

View File

@ -372,10 +372,16 @@ class PrintQueue {
public static function internalQueueReceiptPrintjob($pdo,$billid,$recprinter) { public static function internalQueueReceiptPrintjob($pdo,$billid,$recprinter) {
try { try {
CommonUtils::log($pdo, "PRINTQUEUE", "Insert bill with id=$billid for printer=$printer into queue."); CommonUtils::log($pdo, "PRINTQUEUE", "Insert bill with id=$billid for printer=$recprinter into queue.");
$printInsertSql = "INSERT INTO `%printjobs%` (`content`,`type`,`printer`) VALUES (?,?,?)"; $printInsertSql = "INSERT INTO `%printjobs%` (`content`,`type`,`printer`) VALUES (?,?,?)";
CommonUtils::execSql($pdo, $printInsertSql, array((string)($billid),self::$RECEIPT,$recprinter)); CommonUtils::execSql($pdo, $printInsertSql, array((string)($billid),self::$RECEIPT,$recprinter));
$addPrinter = CommonUtils::getConfigValue($pdo, 'addreceipttoprinter', null);
if (!is_null($addPrinter)) {
CommonUtils::execSql($pdo, $printInsertSql, array((string)($billid),self::$RECEIPT,$addPrinter));
}
} catch (Exception $ex) { } catch (Exception $ex) {
return array("status" => "ERROR","msg" => $ex->getMessage()); return array("status" => "ERROR","msg" => $ex->getMessage());
} }

View File

@ -10,6 +10,9 @@ class QueueContent {
var $commonUtils; var $commonUtils;
var $userrights; var $userrights;
public static $INTERNAL_CALL_NO = false;
public static $INTERNAL_CALL_YES = true;
public static $lastSettingOfDisplayMode = 'all'; public static $lastSettingOfDisplayMode = 'all';
function __construct() { function __construct() {
@ -114,7 +117,7 @@ class QueueContent {
$this->getJsonProductsOfTableToPay($_GET['tableid']); $this->getJsonProductsOfTableToPay($_GET['tableid']);
} else if ($command == 'declarePaidCreateBillReturnBillId') { } else if ($command == 'declarePaidCreateBillReturnBillId') {
$pdo = DbUtils::openDbAndReturnPdoStatic(); $pdo = DbUtils::openDbAndReturnPdoStatic();
$this->declarePaidCreateBillReturnBillId($pdo,$_POST['ids'],$_POST['tableid'],$_POST['paymentid'],$_POST['declareready'],$_POST['host'],false,$_POST['reservationid'],$_POST['guestinfo'],$_POST['intguestid'],null,null); $this->declarePaidCreateBillReturnBillId($pdo,$_POST['ids'],$_POST['tableid'],$_POST['paymentid'],$_POST['declareready'],$_POST['host'],self::$INTERNAL_CALL_NO,$_POST['reservationid'],$_POST['guestinfo'],$_POST['intguestid'],null,null);
} else { } else {
echo "Command not supported."; echo "Command not supported.";
} }
@ -1095,7 +1098,7 @@ class QueueContent {
$pdo->commit(); $pdo->commit();
$billid = $this->declarePaidCreateBillReturnBillId($pdo, $queueid, 0, 1, 1, 0, true, '', '', '',$userid); $billid = $this->declarePaidCreateBillReturnBillId($pdo, $queueid, 0, 1, 1, 0, self::$INTERNAL_CALL_YES, '', '', '',$userid);
if ($printer >= 0) { if ($printer >= 0) {
PrintQueue::internalQueueReceiptPrintjob($pdo, $billid, $printer); PrintQueue::internalQueueReceiptPrintjob($pdo, $billid, $printer);
@ -1310,7 +1313,15 @@ class QueueContent {
$generalQuickcash = CommonUtils::getConfigValue($pdo, "cashenabled", 1); $generalQuickcash = CommonUtils::getConfigValue($pdo, "cashenabled", 1);
if (($generalQuickcash == 1) || ($quickcash == 1)) { if (($generalQuickcash == 1) || ($quickcash == 1)) {
$idStr = join(',',$insertedQueueIdsTotal); $idStr = join(',',$insertedQueueIdsTotal);
$this->declarePaidCreateBillReturnBillId($pdo,$idStr, $theTableid, 1, 0, 0, true,'','','',null); $billid = $this->declarePaidCreateBillReturnBillId($pdo,$idStr, $theTableid, 1, 0, 0, self::$INTERNAL_CALL_YES,'','','',null);
$forceprint = CommonUtils::getConfigValue($pdo, 'forceprint', 0);
if ($forceprint == 1) {
if(session_id() == '') {
session_start();
}
$recprinter = $_SESSION['receiptprinter'];
PrintQueue::internalQueueReceiptPrintjob($pdo, $billid, $recprinter);
}
} }
if ($doPrint == 1) { if ($doPrint == 1) {
@ -1436,12 +1447,6 @@ class QueueContent {
} }
$cashenabled = CommonUtils::getConfigValue($pdo, "cashenabled", 1);
if ($cashenabled == 0) {
$idStr = join(',',$insertedQueueIds);
$this->declarePaidCreateBillReturnBillId($pdo,$idStr, $theTableid, 1, 0, 0, true,'','','',null);
}
if ($doPrint == 1) { if ($doPrint == 1) {
$this->doWorkPrint($pdo,$theTableid,$insertedQueueIds,'Gastbestellung','s', $_SESSION['language']); $this->doWorkPrint($pdo,$theTableid,$insertedQueueIds,'Gastbestellung','s', $_SESSION['language']);
} }
@ -2174,11 +2179,9 @@ class QueueContent {
$tableid = 0; $tableid = 0;
} }
if (!$calledInternally) { $sql = "INSERT INTO %records% (date,userid,tableid,action) VALUES(?,?,?,?)";
$sql = "INSERT INTO %records% (date,userid,tableid,action) VALUES(?,?,?,?)"; CommonUtils::execSql($pdo, $sql, array($currentTime,$userid,($tableid == 0 ? null : $tableid),T_BILL));
CommonUtils::execSql($pdo, $sql, array($currentTime,$userid,($tableid == 0 ? null : $tableid),T_BILL)); $recordid = $pdo->lastInsertId();
$recordid = $pdo->lastInsertId();
}
$idlist = join("','",$ids_array); $idlist = join("','",$ids_array);
$sql = "SELECT SUM(price) as brutto,ROUND(SUM(price/(1 + %queue%.tax/100.0)),6) as netto FROM %queue% WHERE id IN ('$idlist')"; $sql = "SELECT SUM(price) as brutto,ROUND(SUM(price/(1 + %queue%.tax/100.0)),6) as netto FROM %queue% WHERE id IN ('$idlist')";
@ -2209,10 +2212,8 @@ class QueueContent {
$stmt = $pdo->prepare($this->dbutils->resolveTablenamesInSqlString($billProdsSql)); $stmt = $pdo->prepare($this->dbutils->resolveTablenamesInSqlString($billProdsSql));
$stmt->execute(array($queueid,$billid)); $stmt->execute(array($queueid,$billid));
if (!$calledInternally) { $sql = "INSERT INTO %recordsqueue% (recordid,queueid) VALUES(?,?)";
$sql = "INSERT INTO %recordsqueue% (recordid,queueid) VALUES(?,?)"; CommonUtils::execSql($pdo, $sql, array($recordid,$queueid));
CommonUtils::execSql($pdo, $sql, array($recordid,$queueid));
}
} }
} }
Hotelinterface::insertIntoHsin($pdo,$billid); Hotelinterface::insertIntoHsin($pdo,$billid);

View File

@ -155,7 +155,7 @@ class Reservation {
$txt = "<html><head>"; $txt = "<html><head>";
$txt .= "<title>Reservierungsübersicht</title>"; $txt .= "<title>Reservierungsübersicht</title>";
$txt .= '<meta http-equiv="content-type" content="text/html; charset=utf-8">'; $txt .= '<meta http-equiv="content-type" content="text/html; charset=utf-8">';
$txt .= '<link rel="stylesheet" type="text/css" href="../css/bestformat.css?v=1.6.2">'; $txt .= '<link rel="stylesheet" type="text/css" href="../css/bestformat.css?v=1.6.3">';
$txt .= "</head>"; $txt .= "</head>";
$txt .= "<body>"; $txt .= "<body>";
$txt .= "<h1>Reservierungsübersicht für $day.$month.$year</h1><p>"; $txt .= "<h1>Reservierungsübersicht für $day.$month.$year</h1><p>";

View File

@ -523,8 +523,8 @@ class Roomtables {
return $result; return $result;
} }
private static function createSingleQRCode($guesturl,$tablename,$tableid,$code,$addOnText,$guestqrsize,$guestqrfontsize) { private static function createSingleQRCode($guesturl,$tablename,$tableid,$code,$addOnText,$guestqrsize,$guestqrfontsize,$version) {
$arg = $guesturl . '/index.php?code=' . $code . "_" . $tableid; $arg = $guesturl . '/index.php?code=' . $code . "_" . $tableid . "_" . $version;
$txt = '<div style="width:' . $guestqrsize . 'px;text-align:center;">'; $txt = '<div style="width:' . $guestqrsize . 'px;text-align:center;">';
$txt .= 'Tisch: ' . $tablename . '<br>'; $txt .= 'Tisch: ' . $tablename . '<br>';
if (!is_null($code) && ($code != '')) { if (!is_null($code) && ($code != '')) {
@ -537,7 +537,7 @@ class Roomtables {
return $txt; return $txt;
} }
private static function createQrCodeForTables($pdo,$guesturl,$addOnText,$guestqrsize,$guestqrfontsize) { private static function createQrCodeForTables($pdo,$guesturl,$addOnText,$guestqrsize,$guestqrfontsize,$version) {
$maxCols = round(500.0/($guestqrsize + 20)); $maxCols = round(500.0/($guestqrsize + 20));
$allTables = self::getTablesForGuestsystem($pdo); $allTables = self::getTablesForGuestsystem($pdo);
$txt = '<table class="qrcodes">'; $txt = '<table class="qrcodes">';
@ -549,7 +549,7 @@ class Roomtables {
if ($col == 0) { if ($col == 0) {
$txt .= "<tr>"; $txt .= "<tr>";
} }
$txt .= '<td>' . self::createSingleQRCode($guesturl, $tablename, $tableid, $code, $addOnText, $guestqrsize, $guestqrfontsize); $txt .= '<td>' . self::createSingleQRCode($guesturl, $tablename, $tableid, $code, $addOnText, $guestqrsize, $guestqrfontsize,$version);
$col++; $col++;
if ($col == $maxCols) { if ($col == $maxCols) {
$col = 0; $col = 0;
@ -567,6 +567,10 @@ class Roomtables {
header( "Content-Type: text/html; charset=utf8" ); header( "Content-Type: text/html; charset=utf8" );
$pdo = DbUtils::openDbAndReturnPdoStatic(); $pdo = DbUtils::openDbAndReturnPdoStatic();
$version = CommonUtils::getConfigValue($pdo, 'version', "0.0.0");
$version = str_replace(".","",$version);
$guestUrl = CommonUtils::getConfigValue($pdo, 'guesturl', ''); $guestUrl = CommonUtils::getConfigValue($pdo, 'guesturl', '');
if (CommonUtils::strEndsWith($guestUrl, "/")) { if (CommonUtils::strEndsWith($guestUrl, "/")) {
@ -594,12 +598,12 @@ class Roomtables {
$txt = "<html><head>"; $txt = "<html><head>";
$txt .= "<title>Tisch QR-Codes für die Gastbestellung</title>"; $txt .= "<title>Tisch QR-Codes für die Gastbestellung</title>";
$txt .= '<meta http-equiv="content-type" content="text/html; charset=utf-8">'; $txt .= '<meta http-equiv="content-type" content="text/html; charset=utf-8">';
$txt .= '<link rel="stylesheet" type="text/css" href="../css/bestformat.css?v=1.6.2">'; $txt .= '<link rel="stylesheet" type="text/css" href="../css/bestformat.css?v=1.6.3">';
$txt .= "</head>"; $txt .= "</head>";
$txt .= "<body>"; $txt .= "<body>";
$txt .= "<h1>Tisch QR-Codes für die Gastbestellung</h1><p>"; $txt .= "<h1>Tisch QR-Codes für die Gastbestellung</h1><p>";
$txt .= self::createQrCodeForTables($pdo,$guestUrl,$guestqrtext,$guestqrsize,$guestqrfontsize); $txt .= self::createQrCodeForTables($pdo,$guestUrl,$guestqrtext,$guestqrsize,$guestqrfontsize,$version);
$txt .= "</body></html>"; $txt .= "</body></html>";
echo $txt; echo $txt;
} }

View File

@ -75,11 +75,11 @@ class Demodata {
$queueidsOfGuest = implode(',',self::createDemoForGuest($pdo, $secondDayOfPreviosMonth . " 22:13:00",$users,$prods,1,$queue)); $queueidsOfGuest = implode(',',self::createDemoForGuest($pdo, $secondDayOfPreviosMonth . " 22:13:00",$users,$prods,1,$queue));
if (!is_null($queueidsOfGuest)) { if (!is_null($queueidsOfGuest)) {
$billToIgnore = $queue->declarePaidCreateBillReturnBillId($pdo,$queueidsOfGuest,$tables[0]["id"],8,1,0,true,'',$cust["name"],$cust["id"],$users[0]["id"],$secondDayOfPreviosMonth . " 22:14:00"); $billToIgnore = $queue->declarePaidCreateBillReturnBillId($pdo,$queueidsOfGuest,$tables[0]["id"],8,1,0,QueueContent::$INTERNAL_CALL_YES,'',$cust["name"],$cust["id"],$users[0]["id"],$secondDayOfPreviosMonth . " 22:14:00");
} }
$queueidsOfGuest = implode(',',self::createDemoForGuest($pdo, $secondDayOfPreviosMonth . " 22:14:00",$users,$prods,2,$queue)); $queueidsOfGuest = implode(',',self::createDemoForGuest($pdo, $secondDayOfPreviosMonth . " 22:14:00",$users,$prods,2,$queue));
if (!is_null($queueidsOfGuest)) { if (!is_null($queueidsOfGuest)) {
$billid = $queue->declarePaidCreateBillReturnBillId($pdo,$queueidsOfGuest,$tables[0]["id"],8,1,0,true,'',$cust2["name"],$cust2["id"],$users[0]["id"],$secondDayOfPreviosMonth . " 22:15:00"); $billid = $queue->declarePaidCreateBillReturnBillId($pdo,$queueidsOfGuest,$tables[0]["id"],8,1,0,QueueContent::$INTERNAL_CALL_YES,'',$cust2["name"],$cust2["id"],$users[0]["id"],$secondDayOfPreviosMonth . " 22:15:00");
$customers->payOrUnpay($pdo, $billid, $users[0]["id"], 1, 1, false, "Demo Gast-Bezahlung"); $customers->payOrUnpay($pdo, $billid, $users[0]["id"], 1, 1, false, "Demo Gast-Bezahlung");
} }
$dateOfClosing = $thirdDayOfPreviosMonth . " 23:55:00"; $dateOfClosing = $thirdDayOfPreviosMonth . " 23:55:00";
@ -111,7 +111,7 @@ class Demodata {
} }
$queueidsOfGuest = implode(',',self::createDemoForGuest($pdo, $today . " 22:13:00",$users,$prods,2,$queue)); $queueidsOfGuest = implode(',',self::createDemoForGuest($pdo, $today . " 22:13:00",$users,$prods,2,$queue));
if (!is_null($queueidsOfGuest)) { if (!is_null($queueidsOfGuest)) {
$queue->declarePaidCreateBillReturnBillId($pdo,$queueidsOfGuest,$tables[0]["id"],8,1,0,true,'',$cust["name"],$cust["id"],$users[0]["id"],$today . " 22:14:00"); $queue->declarePaidCreateBillReturnBillId($pdo,$queueidsOfGuest,$tables[0]["id"],8,1,0,QueueContent::$INTERNAL_CALL_YES,'',$cust["name"],$cust["id"],$users[0]["id"],$today . " 22:14:00");
} }
echo json_encode(array("status" => "OK")); echo json_encode(array("status" => "OK"));
@ -237,7 +237,7 @@ class Demodata {
} }
private static function createBillOfTable($pdo,$queue,$tablequeueids,$tableid,$paymentid,$userid,$datetime) { private static function createBillOfTable($pdo,$queue,$tablequeueids,$tableid,$paymentid,$userid,$datetime) {
$billid = $queue->declarePaidCreateBillReturnBillId($pdo,$tablequeueids,$tableid,$paymentid,1,0,true,'','','',$userid,$datetime); $billid = $queue->declarePaidCreateBillReturnBillId($pdo,$tablequeueids,$tableid,$paymentid,1,0,QueueContent::$INTERNAL_CALL_YES,'','','',$userid,$datetime);
return $billid; return $billid;
} }

View File

@ -2,12 +2,44 @@
error_reporting(E_ERROR); error_reporting(E_ERROR);
require_once (__DIR__. '/../3rdparty/phpqrcode.php'); require_once (__DIR__. '/../3rdparty/phpqrcode.php');
require_once (__DIR__. '/../commonutils.php');
class OsQrcode { class OsQrcode {
public static function createQrCodeForLink($text) { public static function createQrCodeForLink($text) {
QRcode::png($text); QRcode::png($text);
} }
public static function createUserLgin() {
if(session_id() == '') {
session_start();
}
$userid = $_SESSION['userid'];
$pdo = DbUtils::openDbAndReturnPdoStatic();
$serverurl = CommonUtils::getConfigValue($pdo, 'serverurl', null);
if (is_null($serverurl)) {
header('Content-Type: image/png');
readfile(__DIR__. '/../../img/oops.png');
return;
}
$lastchar = substr($serverurl, -1);
if ($lastchar == "/") {
$serverurl = substr($serverurl, 0, strlen($serverurl) - 1);
}
$sql = "SELECT userpassword as value FROM %user% WHERE id=?";
$passhash = CommonUtils::getFirstSqlQuery($pdo, $sql, array($userid),null);
if (is_null($passhash)) {
header('Content-Type: image/png');
readfile(__DIR__. '/../../img/oops.png');
return;
} else {
$text = $serverurl . "/nfclogin.php?a=" . $passhash . "_" . $userid . "v=1.6.3";
QRcode::png($text);
}
}
} }
$cmd = $_GET["cmd"]; $cmd = $_GET["cmd"];
@ -17,6 +49,9 @@ switch($cmd) {
case "link": case "link":
OsQrcode::createQrCodeForLink($arg); OsQrcode::createQrCodeForLink($arg);
break; break;
case "userlogin":
OsQrcode::createUserLgin();
break;
default: default:
break; break;
} }

View File

@ -1321,6 +1321,10 @@ class Version {
} }
} }
public static function upd_1602_1603($pdo, $prefix, $dbname) {
return array(true);
}
public static $updateOrder = array( public static $updateOrder = array(
"1.3.0" => array("upd_1300_1301","1.3.1"), "1.3.0" => array("upd_1300_1301","1.3.1"),
"1.3.1" => array("upd_1301_1302","1.3.2"), "1.3.1" => array("upd_1301_1302","1.3.2"),
@ -1404,7 +1408,8 @@ class Version {
"1.5.32" => array("upd_1532_1533","1.5.33"), "1.5.32" => array("upd_1532_1533","1.5.33"),
"1.5.33" => array("upd_1533_1600","1.6.0"), "1.5.33" => array("upd_1533_1600","1.6.0"),
"1.6.0" => array("upd_1600_1601","1.6.1"), "1.6.0" => array("upd_1600_1601","1.6.1"),
"1.6.1" => array("upd_1601_1602","1.6.2") "1.6.1" => array("upd_1601_1602","1.6.2"),
"1.6.2" => array("upd_1602_1603","1.6.3")
); );
public static function runUpdateProcess($pdo,$prefix, $dbname, $untilVersion,$checkValidVersion) { public static function runUpdateProcess($pdo,$prefix, $dbname, $untilVersion,$checkValidVersion) {

View File

@ -5,7 +5,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -13,7 +13,7 @@
<script src="php/3rdparty/jquery-1.11.3.min.js"></script> <script src="php/3rdparty/jquery-1.11.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" /> <link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" />
<script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script> <script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script>

View File

@ -5,7 +5,7 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -13,7 +13,7 @@
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-1.11.3.min.js"></script> <script src="php/3rdparty/jquery-1.11.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
</head> </head>
@ -86,9 +86,15 @@ var PREF_CALC_PREF = ["Bevorzugter Wechselgeldrechnermodus","Preferred change mo
var PREF_CALC_NONE_TXT = ["Kein Wechselgeldrechner","No calculator","Ningún calculador de cambio"]; var PREF_CALC_NONE_TXT = ["Kein Wechselgeldrechner","No calculator","Ningún calculador de cambio"];
var PREF_CALC_TIP_TXT = ["Angabe extra Trinkg.","Do Tip separate","Propina individual"]; var PREF_CALC_TIP_TXT = ["Angabe extra Trinkg.","Do Tip separate","Propina individual"];
var PREF_CALC_TOTAL_TXT = ["Angabe inkl.Trinkg.","Do Tip incl.","Propina incl."]; var PREF_CALC_TOTAL_TXT = ["Angabe inkl.Trinkg.","Do Tip incl.","Propina incl."];
var PREF_NFC_SERVER_URL_FAILED = ["Da die Webserver-Adresse in der Konfiguration nicht oder inkorrekt angegeben wurde, kann kein QR-Code/NFC für das Einloggen per virtuellem Kellnerschloss angezeigt werden.","Since the web server address was not or incorrectly specified in the configuration, no QR code/NFC can be displayed for logging in using the virtual waiter lock.","Dado que la dirección del servidor web no se especificó o se especificó incorrectamente en la configuración, no se puede mostrar ningún código QR/NFC para iniciar sesión utilizando la cerradura de servidor virtual."];
var PREF_NFC_SERVER_LOCALHOST = ["Da die Webserver-Adresse offenbar ein localhost enthält, ist ein Einloggen per QR-Code/NFC nur auf dem Server möglich.","Since the web server address obviously contains a localhost, logging in using QR code/NFC is only possible on the server.", "Dado que la dirección del servidor web contiene obviamente un localhost, sólo es posible iniciar sesión utilizando el código QR/NFC en el servidor."];
var PREF_NFC_LOGIN = ["Über diesen QR-Code kann man sich einloggen. Wenn der Link dieses QR-Codes auf ein NFC-Tag (z.B. als Schlüsselbund-Anhänger) übertragen wird, hat man so ein physisches Kellnerschloss.","You can log in using this QR code. If the link of this QR code is transferred to an NFC tag (e.g. as a keychain pendant), you have a physical waiter lock.","Puede iniciar sesión utilizando este código QR. Si el enlace de este código QR se transfiere a una etiqueta NFC (por ejemplo, como un llavero colgante), tiene una cerradura física de camarero."];
var PREF_WAITERSLOCK = ["Kellnerschloss","Waiter lock","Cerradure física de camarero"];
var l=0; var l=0;
var serverurl = "";
function doAjaxPasswordChange(oldPass,newPass,errorMsg) { function doAjaxPasswordChange(oldPass,newPass,errorMsg) {
var data = { var data = {
oldPass: oldPass, oldPass: oldPass,
@ -109,6 +115,7 @@ function insertGeneralConfigItems(configResult) {
$("#pref-page").data("quickcash",values.quickcash); $("#pref-page").data("quickcash",values.quickcash);
$("#pref-page").data("userlanguage",values.userlanguage); $("#pref-page").data("userlanguage",values.userlanguage);
serverurl = values.serverurl;
setLanguage(values.userlanguage); setLanguage(values.userlanguage);
} else { } else {
setTimeout(function(){document.location.href = "index.html"},250); // not logged in setTimeout(function(){document.location.href = "index.html"},250); // not logged in
@ -224,14 +231,33 @@ function setLanguage(lang) {
$("#preferimgtxt").html(PREF_IMG_ICON_DISPLAY[lang]); $("#preferimgtxt").html(PREF_IMG_ICON_DISPLAY[lang]);
$("#prefermisctxt").html(PREF_MISC[lang]); $("#prefermisctxt").html(PREF_MISC[lang]);
$("#waiterslock").html(PREF_WAITERSLOCK[lang]);
initializeMainMenu("#modulemenu"); initializeMainMenu("#modulemenu");
binding(); binding();
updateQRNFC();
}
function updateQRNFC() {
if ((serverurl == null) || (serverurl == "")) {
$("#nfcinfotxt").html(PREF_NFC_SERVER_URL_FAILED[l]);
} else {
var d = new Date();
var dStamp = d.getTime()
$("#qrnfcimg").html('<img src="php/utilities/osqrcode.php?cmd=userlogin&d=' + dStamp + '" style="width: 135px;">');
if (serverurl.indexOf("localhost") < 0) {
$("#nfcinfotxt").html(PREF_NFC_LOGIN[l]);
} else {
$("#nfcinfotxt").html(PREF_NFC_SERVER_LOCALHOST[l]);
}
}
} }
function changePassword(jsonContent) { function changePassword(jsonContent) {
if (jsonContent == "OK") { if (jsonContent == "OK") {
$("#passwordchangedpopup").popup( "open", {transition: 'flip'} ); $("#passwordchangedpopup").popup( "open", {transition: 'flip'} );
updateQRNFC();
} else { } else {
$("#passwordnotchangedpopup").popup( "open", {transition: 'flip'} ); $("#passwordnotchangedpopup").popup( "open", {transition: 'flip'} );
} }
@ -633,7 +659,7 @@ $(document).on("pageinit", "#pref-page", function () {
</div><!-- /panel --> </div><!-- /panel -->
<div data-role="header" data-theme="b" data-position="fixed" id="theheader" class="noprint" style="background-color:black;"> <div data-role="header" data-theme="b" data-position="fixed" id="theheader" class="noprint" style="background-color:black;">
<h1><span id=prefheader></span></span><span id="username"></span></h1> <h1><span id=prefheader></span><span id="username"></span></h1>
<div data-type="horizontal" style="top:0px;position:absolute;float:right;z-index:10;display:inline;" align="right" class="ui-btn-right"> <div data-type="horizontal" style="top:0px;position:absolute;float:right;z-index:10;display:inline;" align="right" class="ui-btn-right">
<a href="#" data-role="button" data-icon="arrow-d" data-ajax="false" id="menuswitch">Hauptmenü</a> <a href="#" data-role="button" data-icon="arrow-d" data-ajax="false" id="menuswitch">Hauptmenü</a>
</div> </div>
@ -646,6 +672,12 @@ $(document).on("pageinit", "#pref-page", function () {
<span id=oldpassword>Altes Passwort:</span><input type="password" name="oldpassword" id="oldpass"/><br /> <span id=oldpassword>Altes Passwort:</span><input type="password" name="oldpassword" id="oldpass"/><br />
<span id=newpassword>Neues Passwort:</span><input type="password" name="newpassword" id="newpass"/><br /> <span id=newpassword>Neues Passwort:</span><input type="password" name="newpassword" id="newpass"/><br />
<div id="changepassbtnpart"></div> <div id="changepassbtnpart"></div>
<div id="nfc" data-role="collapsible" data-collapsed="true" data-theme="f" data-content-theme="c" class="noprint">
<h3><span id="waiterslock">Kellnerschloss</span></h3>
<p /><div id="qrnfcimg"></div>
<p /><span id="nfcinfotxt"></span>
</div>
</form> </form>
</div> <!-- Benutzerpasswort --> </div> <!-- Benutzerpasswort -->

View File

@ -7,16 +7,16 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<script src="elements/product.js?v=1.6.2"></script> <script src="elements/product.js?v=1.6.3"></script>
<script src="elements/extra.js?v=1.6.2"></script> <script src="elements/extra.js?v=1.6.3"></script>
<link href="php/3rdparty/hayageek_uploadfile.css" rel="stylesheet"> <link href="php/3rdparty/hayageek_uploadfile.css" rel="stylesheet">
<script src="php/3rdparty/hayageek_jquery_uploadfile.js"></script> <script src="php/3rdparty/hayageek_jquery_uploadfile.js"></script>
</head> </head>

View File

@ -4,7 +4,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="css/ospage.css" /> <link rel="stylesheet" href="css/ospage.css" />
<link rel="stylesheet" href="css/tablepanel.css" /> <link rel="stylesheet" href="css/tablepanel.css" />
@ -15,7 +15,7 @@
<script src="php/3rdparty/jquery-2.2.4.min.js"></script> <script src="php/3rdparty/jquery-2.2.4.min.js"></script>
<script src="php/3rdparty/jqueryui1-12-0/jquery-ui.min.js"></script> <script src="php/3rdparty/jqueryui1-12-0/jquery-ui.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<script> <script>

View File

@ -7,14 +7,14 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
</head> </head>
<body> <body>

View File

@ -7,14 +7,14 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<script src="elements/rating.js"></script> <script src="elements/rating.js"></script>
</head> </head>

View File

@ -5,7 +5,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -13,9 +13,9 @@
<script src="php/3rdparty/jquery-1.11.3.min.js"></script> <script src="php/3rdparty/jquery-1.11.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script>
<script src="elements/tablemap.js"></script> <script src="elements/tablemap.js"></script>
<script src="elements/reservation.js?v=1.6.2"></script> <script src="elements/reservation.js?v=1.6.3"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" /> <link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" />
<script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script> <script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script>
@ -562,7 +562,7 @@ function bindCancelButtn() {
var year = date.getFullYear(); var year = date.getFullYear();
var dateStr = year + "-" + month + "-" + day; var dateStr = year + "-" + month + "-" + day;
setTimeout(function(){document.location.href = "reservation.html?v=1.6.2&date=" + dateStr;},500); setTimeout(function(){document.location.href = "reservation.html?v=1.6.3&date=" + dateStr;},500);
}); });
} }

View File

@ -14,7 +14,7 @@
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
</head> </head>
<body> <body>
@ -30,7 +30,7 @@ var SUM_REASON = ["Grund","Reason","Razón"];
var SUM_CANCEL_ITEM = ["Stornierung","Cancellation","Revocación"]; var SUM_CANCEL_ITEM = ["Stornierung","Cancellation","Revocación"];
var SUM_CANCELLATION_OK = ["Die Zahlung wurde in OrderSprinter storniert.","The payment was cancelled in OrderSprinter.","El pago se canceló en OrderSprinter."]; var SUM_CANCELLATION_OK = ["Die Zahlung wurde in OrderSprinter storniert.","The payment was cancelled in OrderSprinter.","El pago se canceló en OrderSprinter."];
var nextpage = "paydesk.html?version=1.6.2"; var nextpage = "paydesk.html?version=1.6.3";
var lang; var lang;
@ -84,10 +84,10 @@ function setLanguage(language) {
if (nextPage == "p") { if (nextPage == "p") {
$("#nextpagebtntxt").html(SUM_TO_PAYMENT[lang]); $("#nextpagebtntxt").html(SUM_TO_PAYMENT[lang]);
nextpage = "paydesk.html?t=" + tableid + "&version=1.6.2"; nextpage = "paydesk.html?t=" + tableid + "&version=1.6.3";
} else { } else {
$("#nextpagebtntxt").html(SUM_TO_ORDER[lang]); $("#nextpagebtntxt").html(SUM_TO_ORDER[lang]);
nextpage = "waiter.html?version=1.6.2"; nextpage = "waiter.html?version=1.6.3";
} }
var txt = "<table class='viewtable'>"; var txt = "<table class='viewtable'>";

View File

@ -5,7 +5,7 @@
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -13,7 +13,7 @@
<link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" /> <link rel="stylesheet" href="php/3rdparty/jquery.mobile-1.4.0.min.css" type="text/css" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script> <script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<style> <style>
#tableWithPreparedProds,#tableWithDeliveredEntries,#headertableToCook #tableWithPreparedProds,#tableWithDeliveredEntries,#headertableToCook

View File

@ -5,7 +5,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -13,7 +13,7 @@
<script src="php/3rdparty/jquery-1.11.3.min.js"></script> <script src="php/3rdparty/jquery-1.11.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" /> <link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" />
<script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script> <script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script>

View File

@ -5,7 +5,7 @@
<meta name="viewport" content="width=device-width, initial-scale=1"> <meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="content-type" content="text/html; charset=utf-8"> <meta http-equiv="content-type" content="text/html; charset=utf-8">
<meta name="author" content="Stefan Pichel"> <meta name="author" content="Stefan Pichel">
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.2"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.6.3">
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" /> <link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
<link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" /> <link rel="stylesheet" href="php/3rdparty/orderstyle/jquery.mobile.icons.min.css" />
@ -13,7 +13,7 @@
<script src="php/3rdparty/jquery-1.11.3.min.js"></script> <script src="php/3rdparty/jquery-1.11.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script> <script src="php/3rdparty/jquery.mobile-1.4.5.min.js"></script>
<script src="utilities.js?v=1.6.2"></script> <script src="utilities.js?v=1.6.3"></script>
<link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" /> <link rel="stylesheet" href="php/3rdparty/jqueryui1-11-4/jquery-ui.min.css" />
<script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script> <script src="php/3rdparty/jqueryui1-11-4/jquery-ui.min.js"></script>

View File

@ -350,6 +350,19 @@ function pad(num, size) {
return s.substr(s.length-size); return s.substr(s.length-size);
} }
function getUrlGetParameter(urlsuffix,paramMarker) {
var tid = '';
var urlParts = urlsuffix.split(/&|\?/);
for (var i=0;i<urlParts.length;i++) {
var aPart = urlParts[i];
if (aPart.indexOf(paramMarker) == 0) {
var parts = aPart.split("=");
tid = parts[1];
}
}
return tid;
}
var g_units_arr = [ var g_units_arr = [
{ text: "Stück", value: 0, id: "piece", longtext: "Stück"}, { text: "Stück", value: 0, id: "piece", longtext: "Stück"},
{ text: "Eingabe", value: 1, id: "input", longtext: "Preiseingabe"}, { text: "Eingabe", value: 1, id: "input", longtext: "Preiseingabe"},

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long