ordersprinter/webapp/paydesk.html

227 lines
67 KiB
HTML
Raw Normal View History

2020-11-19 22:47:44 +01:00
<html>
<head>
<title>Ansicht Kasse</title>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="content-type" content="text/html; charset=utf-8">
2020-11-19 22:48:24 +01:00
<meta name="author" content="Stefan Pichel">
2020-11-19 22:47:44 +01:00
2020-11-19 23:12:43 +01:00
<link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.5.27">
2020-11-19 23:02:42 +01:00
<link rel="stylesheet" href="php/contenthandler.php?module=admin&command=getmobilecss" />
2020-11-19 22:47:44 +01:00
<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" />
<script src="php/3rdparty/jquery-2.0.3.min.js"></script>
<script src="php/3rdparty/jquery.mobile-1.4.0.min.js"></script>
2020-11-19 23:00:09 +01:00
<script>
2020-11-19 23:12:43 +01:00
var CALC_NONE=0;var CALC_TOTAL=1;var CALC_TIP=2;var lang=0;var receiptfontsize=12;var paymentconfig=0;var decpoint=".";var currency="";var osroombtnsize=0;var ostablebtnsize=0;var osprodbtnsize=0;var preferimgmobile=0;var hasRooms=true;var cameFromOrdering=0;var billbrutto=0;var billnetto=0;var prodsToPayList=[];var prodsToPayListGrouping=[];var payTable="";var prodsOnReceiptList=[];var prodsOnReceiptListGrouping=[];var calcmodus=CALC_TOTAL;var workflowconfig=0;var digigopaysetready=1;var onlyReceiptShown=0;var prodsToPayList=null;var restaurantmode=1;var sumupforcard=0;var affiliatekey="";var appid="";var serverurl="";function initializeMainMenu(a){$.ajax({type:"GET",dataType:"json",url:"php/contenthandler.php?module=admin&command=getJsonMenuItemsAndVersion",async:false,success:function(c){$("#versioninfo").html(c.version+"&nbsp;");if(c.loggedin==1){$("#loggedinuser").html("&nbsp;"+c.user);var b='<li data-role="list-divider" data-theme="b" data-role="heading">Hauptmenü</li>';$.each(c.menu,function(g,f){var e=f.name;var h=f.link;if((e!="Abmelden")&&(e!="Log out")&&(e!="Adios")){b+='<li data-theme="e"><a href="'+h+'" target="_top" class="modulebutton">'+e+"</a></li>"}else{b+='<li data-theme="e"><a href="'+h+'" target="_top">'+e+"</a></li>"}});$(a).empty().append(b).promise().done(function(){$(a).listview("refresh")});$("#menuswitch").show()}else{$("#menuswitch").hide()}},error:function(b){alert("Kommunikationsproblem zum Server bei Modulabfrage!")}});$(".modulebutton").off("click").on("click",function(c){var b=$(this).attr("href");doAjax("POST","php/contenthandler.php?module=admin&command=setLastModuleOfUser",{view:b},null,"Problem Benutzerdatenpflege")});intervalGetPrinterStatus(5);intervalCheckConnection(2)}function intervalGetPrinterStatus(b){doAjax("GET","php/contenthandler.php?module=admin&command=isPrinterServerActive",null,setPrinterStatus,null,true);var a=setInterval(function(){doAjax("GET","php/contenthandler.php?module=admin&command=isPrinterServerActive",null,setPrinterStatus,null,true)},b*1000)}function setPrinterStatus(a){if(a.status==="OK"){if(a.msg===0){$(".printerstatus").show()}else{$(".printerstatus").hide()}if(a.tasksforme===1){$(".tasksstatus").show()}else{$(".tasksstatus").hide()}return}$(".printerstatus").hide()}function hideMenu(){$("#modulepanel").panel("close");$("#menuswitch").off("click").on("click",function(a){$("#menuswitch").trigger("mouseout");a.stopImmediatePropagation();a.preventDefault();$("#modulepanel").panel("open")})}function refreshList(a){if($(a).hasClass("ui-listview")){$(a).listview("refresh")}else{$(a).trigger("create")}}function doAjax(a,b,f,e,c,g){if(typeof g==="undefined"){g=false}$.ajax({type:a,url:b,dataType:"json",data:f,async:g,success:function(h){if(e!=null){e(h)}},error:function(m,h,i){if(b!="php/debug.php"){var k={cmd:b,fct:e.name,xhr:m.responseText,errormsg:c,status:h};var o=getMillis();if(c!=null){if($(".connectionstatus").is(":visible")){alert("Kommunikation zum Server ist unterbrochen!")}else{var l=c+i+" ("+b+")";alert("Kommunikationsfehler zum Server: "+l+" - In der Feedbackansicht lässt sich ein Fehlerprotokoll an den Anbieter übermitteln.");doAjax("POST","php/debug.php?n="+o,k,null,true)}}}}})}function doAjaxAsync(a,b,e,c){$.ajax({type:a,url:b,dataType:"json",data:e,async:true,success:function(f){if(c!=null){c(f)}},error:function(k,f,g){if(b!="php/debug.php"){var h={cmd:b,fct:c.name,xhr:k.responseText,errormsg:errorMsg,status:f};var l=getMillis();if(errorMsg!=null){if($(".connectionstatus").is(":visible")){alert("Kommunikation zum Server ist unterbrochen!")}else{var i=errorMsg+g+" ("+b+")";alert("Kommunikationsfehler zum Server: "+i+" - In der Feedbackansicht lässt sich ein Fehlerprotokoll an den Anbieter übermitteln.");doAjax("POST","php/debug.php?n="+l,h,null,true)}}}}})}function doAjaxTransmitData(a,b,g,f,e,c){$.ajax({type:a,url:b,dataType:"json",data:g,async:false,success:function(h){if(f!=null){f(h,c)}},error:function(l,h,i){if(e!=null){var k=e+", Status: "+h+", Error:"+i+", Msg: "+l.responseText+" ("+b+")";alert("Kommunikationsfehler zum Server: "+k+"
2020-11-19 23:00:09 +01:00
2020-11-19 22:47:44 +01:00
</head>
<body>
<style>
@media screen
{
.receipttable {width: 70%; background-color: #cccccc;}
}
@media print
{
.receipttable,#partToPrint {width: 100%;};
}
@media print
{
2020-11-19 23:12:07 +01:00
#thefooter,#theheader,#modulemenu,#oben,#ops,#untenarea,#payWithoutPrint,#paybuttongroup,#hostbuttongroup {display: none;}
2020-11-19 22:47:44 +01:00
}
</style>
2020-11-19 23:11:29 +01:00
<div data-role="page" id="info-page" data-theme="c">
2020-11-19 22:47:44 +01:00
<div data-role="panel" id="modulepanel" data-position="right" data-display="overlay">
<ul data-role="listview" id="modulemenu" data-divider-theme="a" data-inset="true">
2020-11-19 23:02:16 +01:00
<li data-role="list-divider" data-theme="b" data-role="heading">Hauptmenü</li>
2020-11-19 22:47:44 +01:00
</ul>
</div><!-- /panel -->
2020-11-19 23:11:29 +01:00
<div data-role="header" data-theme="b" data-position="fixed" id="theheader" style="background-color:black;">
2020-11-19 23:11:33 +01:00
<h1><span id="paydesktitle">Kasse</span> <img src="img/connection.png" class="connectionstatus" style="display:none;" /> <img src="img/printerstatus.png" class="printerstatus" style="display:none;" /> <img src="img/tasksstatus.png" class="tasksstatus" style="display:none;" /></h1>
2020-11-19 22:47:44 +01:00
<div data-type="horizontal" style="top:0px;position:absolute;float:right;z-index:10;display:inline;" align="right" class="ui-btn-right">
2020-11-19 23:02:16 +01:00
<a href="#" data-role="button" data-icon="arrow-d" data-ajax="false" id="menuswitch">Hauptmenü</a>
2020-11-19 22:47:44 +01:00
</div>
<div data-type="horizontal" style="top:10px;position:absolute;float:right;z-index:10;display:inline;" align="left" class="ui-btn-left">
<a href="#" data-role="button" data-icon="arrow-l" data-ajax="false" id="startpaypage"></a>
</div>
</div>
<div data-role="content" id="contentpart">
2020-11-19 23:12:07 +01:00
<ul data-role="listview" id="ops" data-divider-theme="a" data-inset="true">
<li data-role="list-divider" data-theme="b" data-role="heading" id="opssel">Ops</li>
</ul>
2020-11-19 22:47:44 +01:00
<ul data-role="listview" id="oben" data-divider-theme="a" data-inset="true">
<li data-role="list-divider" data-theme="b" data-role="heading" id="roomsel">Raumauswahl</li>
</ul>
<div id="tablemapcontent" style="display:none;">
<div style="background-color:black;"><span id=tableselimmaptxt style="font-weight:bold;font-size:20px;color:white;">Tischauswahl</span>:</div>
<div id=tablemapcontent style="position: relative;width:100%;">
<img id="mapimgpart" style="width:100%;position: relative;left: 0;top: 0;" src=img/empty-room.png />
<div id=tableoverlay></div>
</div>
</div>
<div id=togoarea>
<ul data-role="listview" id="tables-list-togo" data-divider-theme="a" data-inset="true">
</ul>
</div>
<ul data-role="listview" id="cashactions" data-divider-theme="a" data-inset="true">
</ul>
<ul data-role="listview" id="navactions" data-divider-theme="a" data-inset="true">
<li data-role="list-divider" data-theme="b" data-role="heading"><span id="navtitle">Navigation</span></li>
<li data-theme="e"><a href="waiter.html" id="navtoorder" target="_top"><span id="nav2order">Bestellansicht</span></a></li>
</ul>
<div id="untenarea">
<ul data-role="listview" id="unten" data-divider-theme="a" data-inset="true">
<li data-role="list-divider" data-theme="b" data-role="heading">
Inhalt Kassenbon: <p id="priceinreceipt">0,00 Euro</p>
</li>
</ul>
</div>
<div data-role="controlgroup" data-type="horizontal" id="paybuttongroup">
<a href="#" data-role="button" data-theme="b" data-icon="check" id="payWithoutPrint"><span id="OnlyPayTxt">Nur Zahlung</span></a>
<a href="#" data-role="button" data-theme="b" data-icon="grid" id="payWithPrint"><span id="payprinttxt">Bondruck</span></a>
</div>
2020-11-19 23:12:00 +01:00
<div data-role="controlgroup" data-type="horizontal" id="hostbuttongroup" style="display:none;">
2020-11-19 23:03:38 +01:00
<a href="#" data-role="button" data-theme="b" data-icon="delete" id="hostbutton">Bewirtungsbeleg</a>
2020-11-19 22:47:44 +01:00
</div>
<div id="partForSaveInBill"> <!-- This part will be saved into bill in db -->
<div id=partToPrint>
<table id="receiptpart" class="receipttable" border=0 style="table-layout: fixed;"></table>
</div>
</div> <!-- end of partForSaveInBill -->
</div>
2020-11-19 23:11:29 +01:00
<div data-role="footer" data-theme="b" id="thefooter" style="background-color:black;">
2020-11-19 22:47:44 +01:00
<div class="ui-grid-a">
<div class="ui-block-a userinfo" id="loggedinuser"></div>
<div class="ui-block-b grid_right" id="versioninfo"></div>
</div><!-- /grid-a -->
</div> <!-- footer -->
</div>
<!-- Dialog page -->
<div data-role="dialog" id="paymentdialog" data-title="Zahlungsart">
<div data-role="content">
2020-11-19 23:00:58 +01:00
<div id='calcarea' style='display:none;'>
<h3><span id="payway">Zahlungsart</span></h3>
<p>
<div>
<form>
2020-11-19 23:12:02 +01:00
<div id="totalpricearea" style="display:none;height:70px;font-size:40px;text-align:center;vertical-align: middle;">Test</div>
<table id ="calculatorarea" style="border: 1px solid black;display:none;width:100%;">
2020-11-19 23:00:58 +01:00
<tr>
<td><span id=topaytxt>Zahlen: </span><td><i><b><span id=topayval>0,00</span></b></i>
2020-11-19 23:12:02 +01:00
<td>&nbsp;<td><span id=haspaidtxt>Bezahlt: </span><td style="width:100px;color:yellow;"><input type="text" id="haspaid" value="" data-mini="true" placeholder="" />
2020-11-19 23:00:58 +01:00
</tr><tr>
<td><span id="rettxt">Zurück: </span><td><i><b><span id="topayback" style="background-color:#ffff99;">0,00</span></b></i><span id=curtopay2></span></td>
2020-11-19 23:12:02 +01:00
<td>&nbsp;<td><span id=tiptxt>Trinkg.: </span><td style="width:100px;color:yellow;"><input type="text" id="tipfield" value="" data-mini="true" placeholder="" />
2020-11-19 23:00:58 +01:00
</tr>
<tr>
2020-11-19 23:12:02 +01:00
<td colspan=5><button id="calcreturnbtn" type="submit" data-theme="b"><span id="calcreturn">Berechne</span></button>
2020-11-19 23:00:58 +01:00
</tr>
</table>
</form>
</div>
</div>
<div id='paymentarea' style='display:none;'>
<p><b><span id="choosepayway">Auswahl der Zahlungsart</span></b></p>
<div id=paymentlist>
<a href="#" class="sure-do" data-role="button" data-theme="b" data-rel="back">Ja</a>
</div>
</div>
</div>
<div id='hotelroomarea' style='display:none;'>
<p>
<div data-role="content">
<h3><span id="hotelroomtitle">Hotelzimmer / Gast wählen</span></h3>
<p>
<form>
<div id='hotelroomfoundguest'></div><br>
<div id='roomselectionarea'><select id='hotelroomselection'></select><br></div>
<input id='roomguesttextfield' type="text" placeholder='Zimmer oder Gast' /><br>
<a href="#" class="sure-do" data-role="button" data-theme="f" data-rel="back" id="paym_hotel">Auf Zimmer schreiben</a>
<button id='cancelhotelroomselection' type='submit' data-theme='d'><span id='cancelroomselectiontxt'>Abbrechen</span></button>
</form>
</div>
</div>
2020-11-19 22:47:44 +01:00
</div>
2020-11-19 23:00:58 +01:00
2020-11-19 22:47:44 +01:00
<!-- Dialog page -->
<div data-role="dialog" id="sure" data-title="Entfernen?">
<div data-role="content">
<h3>Zahlungsart</h3>
<a href="#" class="sure-do" data-role="button" data-theme="b" data-rel="back">Ja</a>
<a href="#" class="sure-do" data-role="button" data-theme="b" data-rel="back">Wert2</a>
<a href="#" data-role="button" data-theme="c" data-rel="back">Nein</a>
</div>
</div>
<!-- Dialog page for cash insert -->
<div data-role="dialog" id="cashinsertdialog" data-title="Kassenaktion">
<div data-role="content">
<h3><span id="cashtakeintxt">Bareinlage in die Kasse</span></h3>
2020-11-19 23:00:18 +01:00
<input type="text" id="remarkin" value="" data-mini="true" placeholder="Bemerkung">
2020-11-19 22:52:25 +01:00
<label for="moneyToInsert"><span id="amounttxt">Betrag:</span></label>
2020-11-19 22:47:44 +01:00
<input type="text" id="moneyToInsert" value="" data-mini="true">
<div id=paymentlistcash>
<a href="#" class="sure-do" data-role="button" data-theme="b" data-rel="back"><span id="putinact">Einlegen</span></a>
<a href="#" data-role="button" data-theme="d" data-rel="back" id="cash_insert_cancel"><span id="canceltxt">Abbruch</span></a>
</div>
</div>
</div>
<!-- Dialog page for cash insert -->
<div data-role="dialog" id="cashtakeoutdialog" data-title="Kassenaktion">
<div data-role="content">
<h3><span id="cashtakeouttxt">Barentnahme aus der Kasse</span></h3>
2020-11-19 23:00:18 +01:00
<input type="text" id="remarkout" value="" data-mini="true" placeholder="Bemerkung">
2020-11-19 22:52:25 +01:00
<label for="moneyToTakeOut"><span id="amounttxt2">Betrag:</span></label>
2020-11-19 22:47:44 +01:00
<input type="text" id="moneyToTakeOut" value="" data-mini="true">
<div id=paymentlist>
<a href="#" class="sure-do" data-role="button" data-theme="b" data-rel="back"><span id="takeoutact">Entnehmen</span></a>
<a href="#" data-role="button" data-theme="d" data-rel="back" id="cash_takeout_cancel">Abbruch</a>
</div>
</div>
</div>
<div data-role="dialog" id="cashoverviewinfo" name="cashoverviewinfo" data-overlay-theme="a" style="max-width:70%;" class="ui-corner-all">
<div data-role="content">
<h3><span id="cashoverviewtxt">Übersicht Kellnerkasse</span></h3>
<p><span id="overviewdetails">Diese Übersicht enthält die Bewirtungseinnahme durch den Kellner seit der letzten Tageslosung sowie
als weiteren Wert den Kassenstand unter Berücksichtigung der eigenen Eingaben und Entnahmen.</span><p>
2020-11-19 23:02:57 +01:00
<p><i><span id="cashsum">Bewirtungseinnahmen:</span></i>
<p><span id=cashbyguests></span></p>
2020-11-19 23:12:39 +01:00
<p><i>Ein-/Auslagen:</i> <b><span id="onlycashsum"></span></b> <span class="currencyplaceholder"></span>
2020-11-19 23:12:37 +01:00
<p><i><span id="includeowncash">inkl. eigener Kassen-Eingaben/Entnahmen:</span></i> <b><span id=cashtotal></span></b> <span class="currencyplaceholder"></span><p>
2020-11-19 22:47:44 +01:00
<a href="#" data-role="button" data-theme="d" data-rel="back" id="cash_overview_ok">OK</a>
</div>
</div> <!-- popup -->
<div data-role="dialog" id="nocashitems" name="nocashitems" data-overlay-theme="a" style="max-width:70%;" class="ui-corner-all">
<div data-role="content">
<h3><span id="noelementstxt">Keine Rechnungselemente</span></h3>
<p><span id="noelementsdetailstxt">Es wurden keine abrechenbaren Produkte festgelegt (der Bon ist leer!).</span><p>
<a href="#" data-role="button" data-theme="d" data-rel="back" id="nocashitems_ok">OK</a>
</div>
</div> <!-- popup nocashitems -->
</body>
</html>