OrderSprinter 1.3.20

This commit is contained in:
Geno 2020-11-19 23:03:38 +01:00
parent 6e406d81c1
commit 748729a326
27 changed files with 269 additions and 123 deletions

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.3.19"); Database::setVersion($pdo,$prefix,"1.3.20");
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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -5,58 +5,71 @@
# #
Speisen = KBF = 1 Speisen = KBF = 1
Fastfood = KBF = 1 Fastfood = KBF = 1
Pommes; 3,00 Pommes; 3,00 # Bildnr: 1
Schnitzel; 4,00 Schnitzel; 4,00 # Bildnr: 1
Brötchen = KBF = 1
Camenbertbrötchen; 2,90 # Bildnr:4
Käsebrötchen; 2,90 # Bildnr: 7
3 Brötchen; 3,00 # Bildnr: 3
Vom Grill = KBF = 1 Vom Grill = KBF = 1
EL Greco 2 Personen; 26,00 # Kurzname:El Greco 2P; PreisB:20,00; PreisC:13,00 EL Greco 2 Personen; 26,00 # Kurzname:El Greco 2P; PreisB:20,00; PreisC:13,00 ; Bildnr: 1
EL Greco 1 Person; 14,00 # Kurzname:El Greco 1P EL Greco 1 Person; 14,00 # Kurzname:El Greco 1P ; Bildnr: 1
Fleisch-Gerichte = KBF = 1 Fleisch-Gerichte = KBF = 1
Lammkotelett; 13,00 # PreisB:11,00; PreisC:6,00 Lammkotelett; 13,00 # PreisB:11,00; PreisC:6,00 ; Bildnr: 1
Zigeuner/Jägerschnitzel; 10,00 # PreisB:9,00; PreisC:3,00 Zigeuner/Jägerschnitzel; 10,00 # PreisB:9,00; PreisC:3,00 ; Bildnr: 1
Suzukakia 4 Hacksteaks; 10,00 # Kurzname:Suzukakia 4H Suzukakia 4 Hacksteaks; 10,00 # Kurzname:Suzukakia 4H ; Bildnr: 1
Suzukakia 2 Hacksteaks; 10,00 # Kurzname:Suzukakia 2H Suzukakia 2 Hacksteaks; 10,00 # Kurzname:Suzukakia 2H ; Bildnr: 1
Souvlaki; 10,00 # ID:9 Souvlaki; 10,00 # ID:9 ; Bildnr: 1
Italienische Küche = KBF = 1 Italienische Küche = KBF = 1
Ital. Tagesspecial; 6,00 # Kurzname:Special Ital. Tagesspecial; 6,00 # Kurzname:Special ; Bildnr: 1
Pizza = KBF = 1 Pizza = KBF = 1
Siciliana = KBF = 1 Siciliana = KBF = 1
Pizza Siciliana klein; 7,00 # Kurzname:klein Pizza Siciliana klein; 7,00 # Kurzname:klein ; Bildnr: 1
Pizza Siciliana groß; 7,00 # Kurzname:groß Pizza Siciliana groß; 7,00 # Kurzname:groß; Bildnr: 1
Salami = KBF = 1 Salami = KBF = 1
Pizza Salami klein; 6,00 # Kurzname:klein Pizza Salami klein; 6,00 # Kurzname:klein; Bildnr: 1
Pizza Salami groß; 7,00 # Kurzname:groß Pizza Salami groß; 7,00 # Kurzname:groß; Bildnr: 1
Dessert = KBF = 1
Mohnkuchen; 1,50 # Bildnr: 8
Kuchen all; 1,50 # Bildnr: 1
Kategorie Selbstbedienung = F = 1 Kategorie Selbstbedienung = F = 1
Frühstücksbuffet; 8,00 Frühstücksbuffet; 8,00 # Bildnr: 1
Frühstücksbuffet + Kaffe; 12,00 Frühstücksbuffet + Kaffe; 12,00 # Bildnr: 1
Kategorie vorbereitet = BF = 1 Kategorie vorbereitet = BF = 1
Deserts; 2,00 Deserts; 2,00
Fertigprodukte; 1,00 Fertigprodukte; 1,00 # Bildnr: 1
Kategorie Nur Küche = KF = 1 Kategorie Nur Küche = KF = 1
Tischzubereitung Fisch; 2,00 Tischzubereitung Fisch; 2,00 # Bildnr: 6
Tischzubereitung Fleischmenü; 1,00 Tischzubereitung Fleischmenü; 1,00 # Bildnr: 1
Getränke = KBD = 1 Getränke = KBD = 1
Kaffee = KBD = 1 Kaffee = KBD = 1
Cappuchino; 2,50 Cappuchino; 2,50 # Bildnr: 9
Tasse Kaffee; 3,00 Tasse Kaffee; 3,00 # Bildnr: 9
Becher Kaffee; 3,50 Becher Kaffee; 3,50 # Bildnr: 2
Latte Macchiato; 3,00 Latte Macchiato; 3,00 # Bildnr: 9
Biere = KBD = 1 Biere = KBD = 1
Holsten; 1,00 # PreisB:1,00; PreisC:0,00 Holsten; 1,00 # PreisB:1,00; PreisC:0,00 ; Bildnr: 16
Warsteiner; 1,00 Warsteiner; 1,00 # Bildnr: 16
Becks Gold; 1,00 Becks Gold; 1,00 # Bildnr: 16
Alsterwasser; 1,00 Alsterwasser; 1,00 # Bildnr: 1
Softdrinks = KBD = 1 Softdrinks = KBD = 1
Coca-Cola; 2,00 Coca-Cola; 2,00 # Bildnr: 15
Fanta; 2,00 Fanta; 2,00 # Bildnr: 12
Sprite; 2,00 Sprite; 2,00 # Bildnr: 13
Eistee; 1,00 Eistee; 1,00 # Bildnr: 1
Kirschsaft; 1,00 # Bildnr: 14
Ohne Zucker = BD = 1 Ohne Zucker = BD = 1
Cola Zero; 2,00 Cola Zero; 2,00 # Bildnr: 1
Alkohol = KBD = 1
Schnaps; 10,00 # Bildnr: 11
Sekt ; 10,00 # Bildnr: 1
Wasser = KBD = 1 Wasser = KBD = 1
Apollinaris; 2,00 Apollinaris; 2,00 # Bildnr: 1
Stilles Wasser; 1,00 # Kurzname:still Stilles Wasser; 1,00 # Kurzname:still ; Bildnr: 1
Weine = KBD = 1 Weine = KBD = 1
Wein Lambrusco; 7,00 # Kurzname:Lambrusco Wein Lambrusco; 7,00 # Kurzname:Lambrusco ; Bildnr: 10
Wein trocken; 7,00 # Bildnr: 10
Wein lieboich; 6,00 # Bildnr: 1
# #
# Es folgen die Extras # Es folgen die Extras
!Sahne # 0,50 ; Tasse Kaffee , Becher Kaffee !Sahne # 0,50 ; Tasse Kaffee , Becher Kaffee

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<link rel="stylesheet" type="text/css" href="css/numfield.css?v=1.3.19"> <link rel="stylesheet" type="text/css" href="css/numfield.css?v=1.3.20">
<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" />
@ -215,7 +215,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.3.19"},500); setTimeout(function(){document.location.href = "install.html?v=1.3.20"},500);
} }
} }

View File

@ -725,7 +725,7 @@ $(document).ready(function() {
<tr id=updateline> <tr id=updateline>
<td>&nbsp;</td> <td>&nbsp;</td>
<td align=center> <td align=center>
<button id="updatebtn">Update -> 1.3.19</button> <button id="updatebtn">Update -> 1.3.20</button>
<span id="updateinprogresstxt" style="display:none;">Update... bitte warten.</span> <span id="updateinprogresstxt" style="display:none;">Update... bitte warten.</span>
</td> </td>
<td>&nbsp;</td> <td>&nbsp;</td>

View File

@ -2391,6 +2391,42 @@ return false;
} }
} }
function updateUserTable1319_1320($prefix, $version, $dbname) {
$pdo = $this->pdo;
try {
if ($version != "1.3.19") {
$ret = $this->updateUserTable1318_1319($prefix, $version, $dbname);
if (!$ret) {
echo "Version update v1.3.18 to 1.3.19 not successful.";
return false;
}
}
DbUtils::overrulePrefix($prefix);
$sql = "SHOW COLUMNS FROM %user% LIKE 'showplusminus'";
$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
$stmt->execute();
$result = $stmt->fetchAll();
if (count($result) == 0) {
$sql = "ALTER TABLE %user% ADD showplusminus INT(1) NULL AFTER preferimgmobile";
$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
$stmt->execute();
$sql = "UPDATE %user% SET showplusminus=?";
$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
$stmt->execute(array(1));
}
$this->updateVersion($pdo, '1.3.20');
return true;
} catch (PDOException $e) {
echo "Error in v1.3.19 to 1.3.20: $e";
return false;
}
}
function setVersion($prefix,$theVersion) { function setVersion($prefix,$theVersion) {
$pdo = $this->pdo; $pdo = $this->pdo;
@ -2518,7 +2554,7 @@ $this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VAL
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'billlanguage', $billlanguage)"); $this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'billlanguage', $billlanguage)");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'currency', '$currency')"); $this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'currency', '$currency')");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'receiptfontsize', '12')"); $this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'receiptfontsize', '12')");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'version', '1.3.19')"); $this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'version', '1.3.20')");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'paymentconfig', '0')"); $this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'paymentconfig', '0')");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'remoteaccesscode', null)"); $this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'remoteaccesscode', null)");
$this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'decpoint', '$decpoint')"); $this->basedb->doSQL($pdo,"INSERT INTO `%config%` (`id` , `name`, `setting`) VALUES (NULL , 'decpoint', '$decpoint')");
@ -2686,7 +2722,7 @@ $right_manager,$right_closing,$right_dash,$right_reservation,$right_rating,$lang
$md5adminpass = md5($adminpass); $md5adminpass = md5($adminpass);
$pdo = $this->pdo; $pdo = $this->pdo;
$userInsertSql = "INSERT INTO `%user%` (`id` , `username` , `userpassword`, `is_admin`, `right_waiter`,`right_kitchen`,`right_bar`,`right_supply`,`right_paydesk`,`right_statistics`,`right_bill`,`right_products`,`right_changeprice`,`right_customers`,`right_manager`,`right_closing`,`right_dash`,`right_reservation`,`right_rating`,`language`,`prefertablemap`,`keeptypelevel`,`extrasapplybtnpos`,`active`) VALUES (NULL,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,'1','1')"; $userInsertSql = "INSERT INTO `%user%` (`id` , `username` , `userpassword`, `is_admin`, `right_waiter`,`right_kitchen`,`right_bar`,`right_supply`,`right_paydesk`,`right_statistics`,`right_bill`,`right_products`,`right_changeprice`,`right_customers`,`right_manager`,`right_closing`,`right_dash`,`right_reservation`,`right_rating`,`language`,`prefertablemap`,`keeptypelevel`,`extrasapplybtnpos`,`showplusminus`,`preferimgdesk`,`preferimgmobile`,`active`) VALUES (NULL,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,'1','1','1','1','1')";
$stmt = $pdo->prepare(DbUtils::substTableAlias($userInsertSql)); $stmt = $pdo->prepare(DbUtils::substTableAlias($userInsertSql));
$stmt->execute(array($username,$md5adminpass,$is_admin,$right_waiter,$right_kitchen,$right_bar,$right_supply,$right_paydesk,$right_statistics,$right_bill,$right_products,$right_changeprice,$right_customers,$right_manager,$right_closing,$right_dash,$right_reservation,$right_rating,$lang,$prefertablemap,0)); $stmt->execute(array($username,$md5adminpass,$is_admin,$right_waiter,$right_kitchen,$right_bar,$right_supply,$right_paydesk,$right_statistics,$right_bill,$right_products,$right_changeprice,$right_customers,$right_manager,$right_closing,$right_dash,$right_reservation,$right_rating,$lang,$prefertablemap,0));
@ -2805,8 +2841,9 @@ return true;
} }
static function insertSampleMenu($pdo,$adminCl) { static function insertSampleMenu($pdo,$adminCl) {
Basedb::loadSampleProdImages($pdo);
$menu = file_get_contents("../customer/speisekarte.txt"); $menu = file_get_contents("../customer/speisekarte.txt");
$adminCl->fillSpeisekarteCore($pdo, $menu); $adminCl->fillSpeisekarteCore($pdo, $menu, false);
} }
function insertSample($level,$lang,$adminpass,$workflow,$timezone) { function insertSample($level,$lang,$adminpass,$workflow,$timezone) {
@ -2878,6 +2915,12 @@ $stmt->execute(array("logoimg",$logoimg));
self::insertSampleMenu($pdo,$adminCl); self::insertSampleMenu($pdo,$adminCl);
} }
if ($level == 1) {
$sql = "UPDATE %user% SET preferimgdesk=?,preferimgmobile=?";
$stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
$stmt->execute(array(0,0));
}
} }
} }
@ -2951,7 +2994,7 @@ $zones[] = $timezone_identifiers[$i];
} }
echo json_encode($zones); echo json_encode($zones);
} else if ($command == 'update') { } else if ($command == 'update') {
$installerVersion = "1.3.19"; $installerVersion = "1.3.20";
$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']);
@ -2982,7 +3025,7 @@ $supportedVersions = array("1.0.22","1.0.23","1.0.24","1.0.25","1.0.26","1.0.27"
"1.1.18","1.1.19","1.1.20","1.1.21","1.1.22","1.1.23","1.1.24","1.1.25","1.1.26","1.1.27","1.1.28","1.1.29","1.1.30", "1.1.18","1.1.19","1.1.20","1.1.21","1.1.22","1.1.23","1.1.24","1.1.25","1.1.26","1.1.27","1.1.28","1.1.29","1.1.30",
"1.2.0","1.2.1","1.2.2", "1.2.3", "1.2.4","1.2.5","1.2.6","1.2.7","1.2.8","1.2.9","1.2.10","1.2.11","1.2.12","1.2.13","1.2.14","1.2.15","1.2.16","1.2.17", "1.2.0","1.2.1","1.2.2", "1.2.3", "1.2.4","1.2.5","1.2.6","1.2.7","1.2.8","1.2.9","1.2.10","1.2.11","1.2.12","1.2.13","1.2.14","1.2.15","1.2.16","1.2.17",
"1.2.18","1.2.19","1.2.20","1.2.21","1.2.22","1.3.0","1.3.1","1.3.2","1.3.3","1.3.4","1.3.5","1.3.6","1.3.7","1.3.8","1.3.9","1.3.10","1.3.11","1.3.12", "1.2.18","1.2.19","1.2.20","1.2.21","1.2.22","1.3.0","1.3.1","1.3.2","1.3.3","1.3.4","1.3.5","1.3.6","1.3.7","1.3.8","1.3.9","1.3.10","1.3.11","1.3.12",
"1.3.13","1.3.14","1.3.15","1.3.16","1.3.17","1.3.18" "1.3.13","1.3.14","1.3.15","1.3.16","1.3.17","1.3.18","1.3.19"
); );
if (!in_array($version, $supportedVersions)) { if (!in_array($version, $supportedVersions)) {
@ -2990,7 +3033,7 @@ echo json_encode("Quellversion nicht unterstützt");
return; return;
} }
$ret = $admin->updateUserTable1318_1319($_POST['prefix'], $version, $_POST['db']); $ret = $admin->updateUserTable1319_1320($_POST['prefix'], $version, $_POST['db']);
if(session_id() == '') { if(session_id() == '') {
session_start(); session_start();
@ -3018,4 +3061,3 @@ echo json_encode("OK");
echo json_encode("ERROR"); echo json_encode("ERROR");
} }
} }
?>

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />
@ -1190,7 +1190,7 @@ function initRestoreFileUpload() {
} else { } else {
alert("Import war erfolgreich."); alert("Import war erfolgreich.");
setTimeout(function(){ setTimeout(function(){
document.location.href = "index.html?v=1.3.19"; document.location.href = "index.html?v=1.3.20";
},250); },250);
} }
}, },
@ -1711,9 +1711,9 @@ function handleUpdateCheckResult(answer) {
var millis=getMillis(); var millis=getMillis();
setTimeout(function(){ setTimeout(function(){
document.location.href = "install.html?v=1.3.19&mode=onlyupdate&n=" + millis; document.location.href = "install.html?v=1.3.20&mode=onlyupdate&n=" + millis;
},250); },250);
document.location.href = "install.html?v=1.3.19&mode=onlyupdate&n=" + millis; document.location.href = "install.html?v=1.3.20&mode=onlyupdate&n=" + millis;
} }
function handleUpdateReplace(answer) { function handleUpdateReplace(answer) {

File diff suppressed because one or more lines are too long

View File

@ -72,6 +72,7 @@ class Admin {
"setApplyExtrasBtnPos" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "setApplyExtrasBtnPos" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"setPreferimgdesk" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "setPreferimgdesk" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"setPreferimgmobile" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "setPreferimgmobile" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"setPrefershowplusminus" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"getOrderVolume" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "getOrderVolume" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"getButtonSizes" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "getButtonSizes" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"getPreferTableMap" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "getPreferTableMap" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
@ -80,6 +81,7 @@ class Admin {
"getApplyExtrasBtnPos" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "getApplyExtrasBtnPos" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"getPreferimgdesk" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "getPreferimgdesk" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"getPreferimgmobile" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "getPreferimgmobile" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"getPrefershowplusminus" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
"isInstalled" => array("loggedin" => 0, "isadmin" => 0, "rights" => null), "isInstalled" => array("loggedin" => 0, "isadmin" => 0, "rights" => null),
"isPrinterServerActive" => array("loggedin" => 1, "isadmin" => 0, "rights" => null), "isPrinterServerActive" => array("loggedin" => 1, "isadmin" => 0, "rights" => null),
@ -261,6 +263,10 @@ class Admin {
if ($this->isUserAlreadyLoggedInForPhp()) { if ($this->isUserAlreadyLoggedInForPhp()) {
$this->setPreferimgmobile($_POST['preferredvalue']); $this->setPreferimgmobile($_POST['preferredvalue']);
} }
} else if ($command == 'setPrefershowplusminus') {
if ($this->isUserAlreadyLoggedInForPhp()) {
$this->setShowplusminus($_POST['preferredvalue']);
}
} else if ($command == 'setKeepTypeLevel') { } else if ($command == 'setKeepTypeLevel') {
if ($this->isUserAlreadyLoggedInForPhp()) { if ($this->isUserAlreadyLoggedInForPhp()) {
$this->setKeepTypeLevel($_POST['keeptypelevel']); $this->setKeepTypeLevel($_POST['keeptypelevel']);
@ -293,6 +299,10 @@ class Admin {
if ($this->isUserAlreadyLoggedInForPhp()) { if ($this->isUserAlreadyLoggedInForPhp()) {
$this->getPreferimgmobile(); $this->getPreferimgmobile();
} }
} else if ($command == 'getPrefershowplusminus') {
if ($this->isUserAlreadyLoggedInForPhp()) {
$this->getShowplusminus();
}
} else if ($command == 'getKeepTypeLevel') { } else if ($command == 'getKeepTypeLevel') {
if ($this->isUserAlreadyLoggedInForPhp()) { if ($this->isUserAlreadyLoggedInForPhp()) {
$this->getKeepTypeLevel(); $this->getKeepTypeLevel();
@ -327,6 +337,7 @@ class Admin {
} }
} }
/*** /***
* Is the installation already done? Or was the html/php code overwritten, i.e. a new or updated version to install? * Is the installation already done? Or was the html/php code overwritten, i.e. a new or updated version to install?
*/ */
@ -723,7 +734,14 @@ class Admin {
function getPreferimgmobile() { function getPreferimgmobile() {
self::getUserValue('preferimgmobile', 0); self::getUserValue('preferimgmobile', 0);
} }
function getShowplusminus() {
$userid = $_SESSION['userid'];
$pdo = DbUtils::openDbAndReturnPdoStatic();
$sql = "SELECT IFNULL(showplusminus,0) AS result FROM %user% WHERE id=?";
$row = CommonUtils::getRowSqlObject($pdo, $sql, array($userid));
$pdo = null;
echo json_encode($row->result);
}
function getKeepTypeLevel() { function getKeepTypeLevel() {
self::getUserValue('keeptypelevel',1); self::getUserValue('keeptypelevel',1);
} }
@ -790,6 +808,12 @@ class Admin {
} }
self::setUserValue('preferimgmobile',$preferValue); self::setUserValue('preferimgmobile',$preferValue);
} }
function setShowplusminus($preferValue) {
if ($preferValue == 0) {
$preferValue = null;
}
self::setUserValue('showplusminus',$preferValue);
}
function setKeepTypeLevel($preferValue) { function setKeepTypeLevel($preferValue) {
self::setUserValue('keeptypelevel',$preferValue); self::setUserValue('keeptypelevel',$preferValue);
} }
@ -892,7 +916,7 @@ class Admin {
$right_changeprice = 0; $right_changeprice = 0;
$supplyRight = 0; $supplyRight = 0;
if ($userLoggedIn) { if ($userLoggedIn) {
$sql = "SELECT language,right_supply,right_changeprice,keeptypelevel,extrasapplybtnpos,right_paydesk,IFNULL(preferimgdesk,0) as preferimgdesk,IFNULL(preferimgmobile,0) as preferimgmobile FROM %user% WHERE id=?"; $sql = "SELECT language,right_supply,right_changeprice,keeptypelevel,extrasapplybtnpos,right_paydesk,IFNULL(preferimgdesk,0) as preferimgdesk,IFNULL(preferimgmobile,0) as preferimgmobile,IFNULL(showplusminus,0) as showplusminus FROM %user% WHERE id=?";
$stmt = $pdo->prepare(DbUtils::substTableAlias($sql)); $stmt = $pdo->prepare(DbUtils::substTableAlias($sql));
$stmt->execute(array($_SESSION['userid'])); $stmt->execute(array($_SESSION['userid']));
$row = $stmt->fetchObject(); $row = $stmt->fetchObject();
@ -913,7 +937,8 @@ class Admin {
"isUserLoggedIn" => 1, "isUserLoggedIn" => 1,
"jsonMenuItemsAndVersion" => $jsonMenuItems, "jsonMenuItemsAndVersion" => $jsonMenuItems,
"preferimgdesk" => $row->preferimgdesk, "preferimgdesk" => $row->preferimgdesk,
"preferimgmobile" => $row->preferimgmobile "preferimgmobile" => $row->preferimgmobile,
"showplusminus" => $row->showplusminus
); );
echo json_encode($retVal); echo json_encode($retVal);
} }
@ -1161,7 +1186,7 @@ class Admin {
$view = "preferences.html"; $view = "preferences.html";
} }
echo json_encode($view . "?v=1.3.19"); echo json_encode($view . "?v=1.3.20");
} }
} }
@ -1283,7 +1308,7 @@ class Admin {
echo json_encode($ret); echo json_encode($ret);
} }
public function fillSpeisekarteCore($pdo,$speisekarte) { public function fillSpeisekarteCore($pdo,$speisekarte,$doCleanProdImages = true) {
$sql = "DELETE FROM %extrasprods%"; $sql = "DELETE FROM %extrasprods%";
$stmt = $pdo->prepare($this->dbutils->resolveTablenamesInSqlString($sql)); $stmt = $pdo->prepare($this->dbutils->resolveTablenamesInSqlString($sql));
$stmt->execute(); $stmt->execute();
@ -1292,7 +1317,9 @@ class Admin {
$ret = $speisekartenHandler->manageSpeisekarte($pdo,$speisekarte); $ret = $speisekartenHandler->manageSpeisekarte($pdo,$speisekarte);
if ($doCleanProdImages) {
Products::cleanProdImagesTable($pdo); Products::cleanProdImagesTable($pdo);
}
return $ret; return $ret;
} }
@ -1366,27 +1393,27 @@ 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.3.19"); }; if ($_SESSION['right_waiter']) { $mainMenu[] = array("name" => $waitertxt[$lang], "link" => "waiter.html?v=1.3.20"); };
} else { } else {
if ($_SESSION['right_waiter']) { $mainMenu[] = array("name" => $waiterdesktxt[$lang], "link" => "waiterdesktop.php?v=1.3.19"); }; if ($_SESSION['right_waiter']) { $mainMenu[] = array("name" => $waiterdesktxt[$lang], "link" => "waiterdesktop.php?v=1.3.20"); };
} }
if ($_SESSION['right_kitchen']) { $mainMenu[] = array("name" => $kitchentxt[$lang], "link" => "kitchen.html?v=1.3.19"); }; if ($_SESSION['right_kitchen']) { $mainMenu[] = array("name" => $kitchentxt[$lang], "link" => "kitchen.html?v=1.3.20"); };
if ($_SESSION['right_bar']) { $mainMenu[] = array("name" => "Bar", "link" => "bar.html?v=1.3.19"); }; if ($_SESSION['right_bar']) { $mainMenu[] = array("name" => "Bar", "link" => "bar.html?v=1.3.20"); };
if ($_SESSION['right_supply']) { $mainMenu[] = array("name" => $supplytxt[$lang], "link" => "supplydesk.html?v=1.3.19"); }; if ($_SESSION['right_supply']) { $mainMenu[] = array("name" => $supplytxt[$lang], "link" => "supplydesk.html?v=1.3.20"); };
if ($_SESSION['modus'] == 0) { if ($_SESSION['modus'] == 0) {
if ($_SESSION['right_paydesk']) { $mainMenu[] = array("name" => $paydesktxt[$lang], "link" => "paydesk.html?v=1.3.19"); }; if ($_SESSION['right_paydesk']) { $mainMenu[] = array("name" => $paydesktxt[$lang], "link" => "paydesk.html?v=1.3.20"); };
} }
if ($_SESSION['right_statistics']) { $mainMenu[] = array("name" => $stattxt[$lang], "link" => "reports.html?v=1.3.19"); }; if ($_SESSION['right_statistics']) { $mainMenu[] = array("name" => $stattxt[$lang], "link" => "reports.html?v=1.3.20"); };
if ($_SESSION['right_bill']) { $mainMenu[] = array("name" => $bontxt[$lang], "link" => "bill.html?v=1.3.19"); }; if ($_SESSION['right_bill']) { $mainMenu[] = array("name" => $bontxt[$lang], "link" => "bill.html?v=1.3.20"); };
if ($_SESSION['right_products']) { $mainMenu[] = array("name" => $prodtxt[$lang], "link" => "products.html?v=1.3.19"); }; if ($_SESSION['right_products']) { $mainMenu[] = array("name" => $prodtxt[$lang], "link" => "products.html?v=1.3.20"); };
if ($_SESSION['right_reservation']) { $mainMenu[] = array("name" => $restxt[$lang], "link" => "reservation.html?v=1.3.19"); }; if ($_SESSION['right_reservation']) { $mainMenu[] = array("name" => $restxt[$lang], "link" => "reservation.html?v=1.3.20"); };
if ($_SESSION['right_rating']) { $mainMenu[] = array("name" => $ratingtxt[$lang], "link" => "rating.html?v=1.3.19"); }; if ($_SESSION['right_rating']) { $mainMenu[] = array("name" => $ratingtxt[$lang], "link" => "rating.html?v=1.3.20"); };
if ($_SESSION['right_customers']) { $mainMenu[] = array("name" => $customerstxt[$lang], "link" => "customers.html?v=1.3.19"); }; if ($_SESSION['right_customers']) { $mainMenu[] = array("name" => $customerstxt[$lang], "link" => "customers.html?v=1.3.20"); };
if ($_SESSION['right_dash']) { $mainMenu[] = array("name" => $dashtxt[$lang], "link" => "dash.php?v=1.3.19"); }; if ($_SESSION['right_dash']) { $mainMenu[] = array("name" => $dashtxt[$lang], "link" => "dash.php?v=1.3.20"); };
if ($_SESSION['right_manager'] || $_SESSION['is_admin'] || $_SESSION['right_closing']) { $mainMenu[] = array("name" => $admintxt[$lang], "link" => "manager.html?v=1.3.19"); }; if ($_SESSION['right_manager'] || $_SESSION['is_admin'] || $_SESSION['right_closing']) { $mainMenu[] = array("name" => $admintxt[$lang], "link" => "manager.html?v=1.3.20"); };
$mainMenu[] = array("name" => $settingtxt[$lang], "link" => "preferences.html?v=1.3.19"); $mainMenu[] = array("name" => $settingtxt[$lang], "link" => "preferences.html?v=1.3.20");
$mainMenu[] = array("name" => "Hilfe", "link" => "help.php?v=1.3.19"); $mainMenu[] = array("name" => "Hilfe", "link" => "help.php?v=1.3.20");
$mainMenu[] = array("name" => "Feedback", "link" => "feedback.html?v=1.3.19"); $mainMenu[] = array("name" => "Feedback", "link" => "feedback.html?v=1.3.20");
} }
$mainMenu[] = array("name" => $logout[$lang], "link" => "logout.php"); $mainMenu[] = array("name" => $logout[$lang], "link" => "logout.php");
@ -1394,7 +1421,7 @@ class Admin {
$waiterMessage = $this->getMessage(null, "waitermessage"); $waiterMessage = $this->getMessage(null, "waitermessage");
} }
$mainMenuAndVersion = array ("version" => "OrderSprinter 1.3.19", $mainMenuAndVersion = array ("version" => "OrderSprinter 1.3.20",
"user" => $currentUser, "user" => $currentUser,
"menu" => $mainMenu, "menu" => $mainMenu,
"waitermessage" => $waiterMessage, "waitermessage" => $waiterMessage,
@ -1616,6 +1643,9 @@ class Admin {
$lastId = $pdo->lastInsertId(); $lastId = $pdo->lastInsertId();
$sql = "UPDATE %user% SET showplusminus=? WHERE id=?";
CommonUtils::execSql($pdo, $sql, array(1,$lastId));
echo json_encode(array("status" => "OK")); echo json_encode(array("status" => "OK"));
} }
} }

View File

@ -168,6 +168,7 @@ class DbUtils {
array("col" => 'prefertablemap', "hist" => 0, "new" => null ,"default" => 1, "update" => null), array("col" => 'prefertablemap', "hist" => 0, "new" => null ,"default" => 1, "update" => null),
array("col" => 'preferimgdesk', "hist" => 0, "new" => null ,"default" => null, "update" => null), array("col" => 'preferimgdesk', "hist" => 0, "new" => null ,"default" => null, "update" => null),
array("col" => 'preferimgmobile', "hist" => 0, "new" => null ,"default" => null, "update" => null), array("col" => 'preferimgmobile', "hist" => 0, "new" => null ,"default" => null, "update" => null),
array("col" => 'showplusminus', "hist" => 0, "new" => null ,"default" => null, "update" => null),
array("col" => 'keeptypelevel', "hist" => 0, "new" => null ,"default" => 0, "update" => null), array("col" => 'keeptypelevel', "hist" => 0, "new" => null ,"default" => 0, "update" => null),
array("col" => 'extrasapplybtnpos', "hist" => 0, "new" => null ,"default" => 1, "update" => null) array("col" => 'extrasapplybtnpos', "hist" => 0, "new" => null ,"default" => 1, "update" => null)
); );

View File

@ -1205,6 +1205,11 @@ class Products {
} }
$src = imagecreatefromstring(file_get_contents($fn)); $src = imagecreatefromstring(file_get_contents($fn));
$dst = imagecreatetruecolor($width, $height); $dst = imagecreatetruecolor($width, $height);
imagealphablending($dst, false);
imagesavealpha($dst, true);
$transparent = imagecolorallocatealpha($dst, 255, 255, 255, 127);
imagefilledrectangle($dst, 0, 0, $width, $height, $transparent);
imagecopyresampled($dst, $src, 0, 0, 0, 0, $width, $height, $size[0], $size[1]); imagecopyresampled($dst, $src, 0, 0, 0, 0, $width, $height, $size[0], $size[1]);
imagedestroy($src); imagedestroy($src);
ob_start(); ob_start();

View File

@ -117,7 +117,7 @@ class Updater {
$infoFileLines = $infoFile["msg"]; $infoFileLines = $infoFile["msg"];
if (count($infoFileLines) > 1) { if (count($infoFileLines) > 1) {
$checkIfNewerVersion = self::isV2Newer('1.3.19',trim($infoFileLines[0])); $checkIfNewerVersion = self::isV2Newer('1.3.20',trim($infoFileLines[0]));
return array("status" => "OK","msg" => $infoFileLines[0],"url" => $url,"neweravailable" => ($checkIfNewerVersion ? 1 : 0)); return array("status" => "OK","msg" => $infoFileLines[0],"url" => $url,"neweravailable" => ($checkIfNewerVersion ? 1 : 0));
} else { } else {
return array("status" => "ERROR","msg" => "Info file not valid","url" => $url); return array("status" => "ERROR","msg" => "Info file not valid","url" => $url);

View File

@ -218,6 +218,7 @@ class Basedb {
`prefertablemap` INT(1) NULL, `prefertablemap` INT(1) NULL,
`preferimgdesk` INT(1) NULL, `preferimgdesk` INT(1) NULL,
`preferimgmobile` INT(1), `preferimgmobile` INT(1),
`showplusminus` INT(1),
`keeptypelevel` INT(1) NOT NULL, `keeptypelevel` INT(1) NOT NULL,
`extrasapplybtnpos` INT(1) NOT NULL, `extrasapplybtnpos` INT(1) NOT NULL,
`failedlogins` VARCHAR(20) NULL, `failedlogins` VARCHAR(20) NULL,
@ -867,7 +868,30 @@ class Basedb {
$this->createExtrasTable($pdo); $this->createExtrasTable($pdo);
$this->createExtrasprodsTable($pdo); $this->createExtrasprodsTable($pdo);
$this->createQueueExtrasTable($pdo); $this->createQueueExtrasTable($pdo);
}
public static function loadSampleProdImages($pdo) {
$sql = "UPDATE %products% SET prodimageid=?";
CommonUtils::execSql($pdo, $sql, array(null));
$sql = "DELETE FROM %prodimages%";
CommonUtils::execSql($pdo, $sql, null);
$sql = "ALTER TABLE %prodimages% AUTO_INCREMENT = 1";
CommonUtils::execSql($pdo, $sql, null);
$file = "../customer/prodimages.txt";
$handle = fopen ($file, "r");
$sql = "INSERT INTO %prodimages% (imgh,imgm,imgl) VALUES(?,?,?)";
while (!feof($handle)) {
$textline = trim(fgets($handle));
if ($textline != "") {
$parts = explode(';', $textline);
CommonUtils::execSql($pdo, $sql, array($parts[1],$parts[2],$parts[3]));
}
}
fclose ($handle);
} }
} }
?>

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />
@ -51,6 +51,7 @@ var PREF_TM_TEXT = ["Text-Buttons","Text buttons","botones con textos"];
var PREF_IMG_DESK = ["Produktbilder in Desktopansicht","Images in Desktop view","Imagenes en vista de desktop"]; var PREF_IMG_DESK = ["Produktbilder in Desktopansicht","Images in Desktop view","Imagenes en vista de desktop"];
var PREF_IMG_MOBILE = ["Produktbilder in Mobilansicht","Images in mobile view","Imagenes en vista de móviles"]; var PREF_IMG_MOBILE = ["Produktbilder in Mobilansicht","Images in mobile view","Imagenes en vista de móviles"];
var PREF_SHOW_PLUS_MINUS = ["Anzahl (+/-) in Mobilansicht","Amount (+/-) in mobile view","Ajustar numero en vista móvil"];
var PREF_NO = ["Nein","No","No"]; var PREF_NO = ["Nein","No","No"];
var PREF_YES = ["Ja","Yes","Si"]; var PREF_YES = ["Ja","Yes","Si"];
@ -73,6 +74,7 @@ var PREF_THEME_PALE = ["blass","pale","pálido"];
var PREF_THEME_HINT = ["Bitte beachten: Möglicherweise wirkt eine Änderung erst, wenn die jeweilige Ansicht im Internetbrowser erneut geladen wird (Reload-Button).", var PREF_THEME_HINT = ["Bitte beachten: Möglicherweise wirkt eine Änderung erst, wenn die jeweilige Ansicht im Internetbrowser erneut geladen wird (Reload-Button).",
"It may be necessary to press the reload button of a view to get the changed design to be applied.", "It may be necessary to press the reload button of a view to get the changed design to be applied.",
"Quizás es necesario reload las paginas despues de un cambio."]; "Quizás es necesario reload las paginas despues de un cambio."];
var PREF_IMG_ICON_DISPLAY = ["Bild-/Iconanzeige","Display of images/icons","Icons/Imagenes en las vistas"];
var l=0; var l=0;
@ -197,6 +199,8 @@ function setLanguage(lang) {
$("#preferthemetxt").html(PREF_THEME_TITEL[lang]); $("#preferthemetxt").html(PREF_THEME_TITEL[lang]);
$("#preferthemehint").html(PREF_THEME_HINT[lang]); $("#preferthemehint").html(PREF_THEME_HINT[lang]);
$("#preferimgtxt").html(PREF_IMG_ICON_DISPLAY[lang]);
initializeMainMenu("#modulemenu"); initializeMainMenu("#modulemenu");
binding(); binding();
} }
@ -234,10 +238,12 @@ function setPreferimgdesk() {
function setPreferimgmobile() { function setPreferimgmobile() {
doAjax("GET","php/contenthandler.php?module=admin&command=getPreferimgmobile",null,fillPreferimgmobile,"Keine Information über Bevorzugung Produktbilder in Mobilansicht"); doAjax("GET","php/contenthandler.php?module=admin&command=getPreferimgmobile",null,fillPreferimgmobile,"Keine Information über Bevorzugung Produktbilder in Mobilansicht");
} }
function setShowplusminus() {
doAjax("GET","php/contenthandler.php?module=admin&command=getPrefershowplusminus",null,fillPrefershowplusminus,"Keine Information über Bevorzugung Mengenangabe in Mobilansicht");
}
function setKeepTypeLevel() { function setKeepTypeLevel() {
doAjax("GET","php/contenthandler.php?module=admin&command=getKeepTypeLevel",null,fillKeepTypeLevel,"Keine Information über Bevorzugung Bestellnavigation"); doAjax("GET","php/contenthandler.php?module=admin&command=getKeepTypeLevel",null,fillKeepTypeLevel,"Keine Information über Bevorzugung Bestellnavigation");
} }
function setMobileTheme() { function setMobileTheme() {
doAjax("GET","php/contenthandler.php?module=admin&command=getMobileTheme",null,fillMobileTheme,null); doAjax("GET","php/contenthandler.php?module=admin&command=getMobileTheme",null,fillMobileTheme,null);
} }
@ -341,13 +347,16 @@ function fillPreferTableMap(preferTablemap) {
function fillPreferimgdesk(preferredVaue) { function fillPreferimgdesk(preferredVaue) {
$("#preferimgdeskbtnpart").html(createPreferImgPart(preferredVaue, "preferimgdesklabel", PREF_IMG_DESK[l])); $("#preferimgdeskbtnpart").html(createPreferImgPart(preferredVaue, "preferimgdesklabel", PREF_IMG_DESK[l]));
$("#preferimgdeskpartbox").trigger("create"); $("#preferimgpartbox").trigger("create");
} }
function fillPreferimgmobile(preferredVaue) { function fillPreferimgmobile(preferredVaue) {
$("#preferimgmobilebtnpart").html(createPreferImgPart(preferredVaue, "preferimgmobilelabel", PREF_IMG_MOBILE[l])); $("#preferimgmobilebtnpart").html(createPreferImgPart(preferredVaue, "preferimgmobilelabel", PREF_IMG_MOBILE[l]));
$("#preferimgmobilepartbox").trigger("create"); $("#preferimgpartbox").trigger("create");
}
function fillPrefershowplusminus(preferredVaue) {
$("#prefershowplusminusbtnpart").html(createPreferImgPart(preferredVaue, "prefershowplusminuslabel", PREF_SHOW_PLUS_MINUS[l]));
$("#preferimgpartbox").trigger("create");
} }
function fillKeepTypeLevel(preferKeepTypeLevel) { function fillKeepTypeLevel(preferKeepTypeLevel) {
$("#preferktlbtnpart").html(createPreferKTLPart(preferKeepTypeLevel, "preferktllabel", PREF_KTL[l])); $("#preferktlbtnpart").html(createPreferKTLPart(preferKeepTypeLevel, "preferktllabel", PREF_KTL[l]));
$("#preferktlpartbox").trigger("create"); $("#preferktlpartbox").trigger("create");
@ -438,17 +447,24 @@ function binding() {
$("#preferimgdesklabel").off('change').on('change', function(e) { $("#preferimgdesklabel").off('change').on('change', function(e) {
var newVal = $("#preferimgdesklabel").find(":selected").val(); var newVal = $("#preferimgdesklabel").find(":selected").val();
$("#preferimgdeskbtnpart").html(createPreferImgPart(newVal, "preferimgdesklabel", PREF_IMG_DESK[l])); $("#preferimgdeskbtnpart").html(createPreferImgPart(newVal, "preferimgdesklabel", PREF_IMG_DESK[l]));
$("#preferimgdeskpartbox").trigger("create"); $("#preferimgpartbox").trigger("create");
doAjax("POST","php/contenthandler.php?module=admin&command=setPreferimgdesk",{preferredvalue:newVal},handleGeneralAnswer,"Produktbilder Desktop"); doAjax("POST","php/contenthandler.php?module=admin&command=setPreferimgdesk",{preferredvalue:newVal},handleGeneralAnswer,"Produktbilder Desktop");
binding(); binding();
}); });
$("#preferimgmobilelabel").off('change').on('change', function(e) { $("#preferimgmobilelabel").off('change').on('change', function(e) {
var newVal = $("#preferimgmobilelabel").find(":selected").val(); var newVal = $("#preferimgmobilelabel").find(":selected").val();
$("#preferimgmobilebtnpart").html(createPreferImgPart(newVal, "preferimgmobilelabel", PREF_IMG_MOBILE[l])); $("#preferimgmobilebtnpart").html(createPreferImgPart(newVal, "preferimgmobilelabel", PREF_IMG_MOBILE[l]));
$("#preferimgmobilepartbox").trigger("create"); $("#preferimgpartbox").trigger("create");
doAjax("POST","php/contenthandler.php?module=admin&command=setPreferimgmobile",{preferredvalue:newVal},handleGeneralAnswer,"Produktbilder Mobil"); doAjax("POST","php/contenthandler.php?module=admin&command=setPreferimgmobile",{preferredvalue:newVal},handleGeneralAnswer,"Produktbilder Mobil");
binding(); binding();
}); });
$("#prefershowplusminuslabel").off('change').on('change', function(e) {
var newVal = $("#prefershowplusminuslabel").find(":selected").val();
$("#prefershowplusminusbtnpart").html(createPreferImgPart(newVal, "prefershowplusminuslabel", PREF_SHOW_PLUS_MINUS[l]));
$("#preferimgpartbox").trigger("create");
doAjax("POST","php/contenthandler.php?module=admin&command=setPrefershowplusminus",{preferredvalue:newVal},handleGeneralAnswer,"Mengenanwahlicons Mobil");
binding();
});
$("#preferktllabel").off('change').on('change', function(e) { $("#preferktllabel").off('change').on('change', function(e) {
var newVal = $("#preferktllabel").find(":selected").val(); var newVal = $("#preferktllabel").find(":selected").val();
@ -488,6 +504,7 @@ $(document).on("pageinit", "#pref-page", function () {
setApplyBtnPos(); setApplyBtnPos();
setPreferimgdesk(); setPreferimgdesk();
setPreferimgmobile(); setPreferimgmobile();
setShowplusminus();
binding(); binding();
}); });
@ -547,13 +564,11 @@ $(document).on("pageinit", "#pref-page", function () {
<div id="prefertmbtnpart"></div> <div id="prefertmbtnpart"></div>
</div> </div>
<div id="preferimgdeskpartbox" data-role="collapsible" data-collapsed="false" data-theme="e" data-content-theme="c" class="noprint"> <div id="preferimgpartbox" data-role="collapsible" data-collapsed="false" data-theme="e" data-content-theme="c" class="noprint">
<h3><span id="preferimgdesktxt">Bilder Desktopansicht</span></h3> <h3><span id="preferimgtxt">Bildanzeige</span></h3>
<div id="preferimgdeskbtnpart"></div> <div id="preferimgdeskbtnpart"></div>
</div>
<div id="preferimgmobilepartbox" data-role="collapsible" data-collapsed="false" data-theme="e" data-content-theme="c" class="noprint">
<h3><span id="preferimgmobiletxt">Bilder Mobilansicht</span></h3>
<div id="preferimgmobilebtnpart"></div> <div id="preferimgmobilebtnpart"></div>
<div id="prefershowplusminusbtnpart"></div>
</div> </div>
<div id="preferktlpartbox" data-role="collapsible" data-collapsed="false" data-theme="e" data-content-theme="c" class="noprint"> <div id="preferktlpartbox" data-role="collapsible" data-collapsed="false" data-theme="e" data-content-theme="c" class="noprint">

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />

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.3.19"> <link rel="stylesheet" type="text/css" href="css/bestformat.css?v=1.3.20">
<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" />

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long