From e19d0c9eeaeadd9c18b3fc39f3522c30db10a24f Mon Sep 17 00:00:00 2001 From: teleassist <30868208+teleassist@users.noreply.github.com> Date: Wed, 2 Dec 2020 09:07:24 +0100 Subject: [PATCH 1/9] Add translation Add translation for option TakeposNumpadForcePaymentLabels --- htdocs/langs/en_US/cashdesk.lang | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/htdocs/langs/en_US/cashdesk.lang b/htdocs/langs/en_US/cashdesk.lang index 549646ab110..c0245790e76 100644 --- a/htdocs/langs/en_US/cashdesk.lang +++ b/htdocs/langs/en_US/cashdesk.lang @@ -122,4 +122,5 @@ GiftReceipt=Gift receipt ModuleReceiptPrinterMustBeEnabled=Module Receipt printer must have been enabled first AllowDelayedPayment=Allow delayed payment PrintPaymentMethodOnReceipts=Print payment method on tickets|receipts -WeighingScale=Weighing scale \ No newline at end of file +WeighingScale=Weighing scale +TakeposNumpadForcePaymentLabels=Show text with icons of payment buttons of numpad From 7e9a12a2f8bef1f6947522654e1470661844f054 Mon Sep 17 00:00:00 2001 From: teleassist <30868208+teleassist@users.noreply.github.com> Date: Wed, 2 Dec 2020 09:19:18 +0100 Subject: [PATCH 2/9] Add TAKEPOS_NUMPAD_FORCE_PAYMENT_ICONS_LABELS Add option TAKEPOS_NUMPAD_FORCE_PAYMENT_ICONS_LABELS to show labels at the bottom of payment icons of the numpad --- htdocs/takepos/admin/setup.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/htdocs/takepos/admin/setup.php b/htdocs/takepos/admin/setup.php index 88911f10b7d..bd4c18bda0c 100644 --- a/htdocs/takepos/admin/setup.php +++ b/htdocs/takepos/admin/setup.php @@ -307,6 +307,13 @@ print ''; print ajax_constantonoff("TAKEPOS_NUMPAD_USE_PAYMENT_ICON", array(), $conf->entity, 0, 0, 1, 0); print "\n"; +// Numpad show labels for icons +print ''; +print $langs->trans('TakeposNumpadForcePaymentLabels'); +print ''; +print ajax_constantonoff("TAKEPOS_NUMPAD_FORCE_PAYMENT_ICONS_LABELS", array(), $conf->entity, 0, 0, 1, 0); +print "\n"; + // Direct Payment print ''; print $langs->trans('DirectPaymentButton'); From 0730cab90fd9357477c6aebfd9728f0e5becc31b Mon Sep 17 00:00:00 2001 From: teleassist <30868208+teleassist@users.noreply.github.com> Date: Wed, 2 Dec 2020 09:38:30 +0100 Subject: [PATCH 3/9] Add class for icons labels --- htdocs/takepos/css/pos.css.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/htdocs/takepos/css/pos.css.php b/htdocs/takepos/css/pos.css.php index 416980633ca..4b1f4c0bbb7 100644 --- a/htdocs/takepos/css/pos.css.php +++ b/htdocs/takepos/css/pos.css.php @@ -125,6 +125,10 @@ button.calcbutton2 { border-radius: 3px; } +button.calcbutton2 .iconwithlabel { + padding-bottom: 10px; +} + button.calcbutton3 { display: inline-block; position: relative; From dd2d5259de40db7803bdddf11c86b2b40f489d59 Mon Sep 17 00:00:00 2001 From: teleassist <30868208+teleassist@users.noreply.github.com> Date: Wed, 2 Dec 2020 09:46:53 +0100 Subject: [PATCH 4/9] Add icons labels for payment buttons Add labels to icons when TAKEPOS_NUMPAD_FORCE_PAYMENT_ICONS_LABELS is set --- htdocs/takepos/pay.php | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/htdocs/takepos/pay.php b/htdocs/takepos/pay.php index b0e745e2211..31acc4433c6 100644 --- a/htdocs/takepos/pay.php +++ b/htdocs/takepos/pay.php @@ -286,6 +286,7 @@ print ''; + if(!empty($conf->global->TAKEPOS_NUMPAD_FORCE_PAYMENT_ICONS_LABELS)) $payLabel = ' iconwithlabel'; + print ''; } else { print ''; } @@ -309,6 +311,7 @@ print ''; + if(!empty($conf->global->TAKEPOS_NUMPAD_FORCE_PAYMENT_ICONS_LABELS)) $payLabel = ' iconwithlabel'; + print ''; } else { $button = array_pop($action_buttons); print ''; @@ -333,6 +337,7 @@ print ''; + if(!empty($conf->global->TAKEPOS_NUMPAD_FORCE_PAYMENT_ICONS_LABELS)) $payLabel = ' iconwithlabel'; + print ''; } else { $button = array_pop($action_buttons); print ''; From 87ee62c2ff8c503069f62b816c9b9d475d4599d6 Mon Sep 17 00:00:00 2001 From: stickler-ci Date: Wed, 2 Dec 2020 08:54:33 +0000 Subject: [PATCH 5/9] Fixing style errors. --- htdocs/takepos/pay.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/takepos/pay.php b/htdocs/takepos/pay.php index 31acc4433c6..89b936bef6c 100644 --- a/htdocs/takepos/pay.php +++ b/htdocs/takepos/pay.php @@ -298,7 +298,7 @@ print ''; } else { print ''; @@ -323,7 +323,7 @@ print ''; } else { $button = array_pop($action_buttons); @@ -349,7 +349,7 @@ print ''; } else { $button = array_pop($action_buttons); From 62e3b5d214a0e559ecd0acf6c452969dcab9b1e6 Mon Sep 17 00:00:00 2001 From: teleassist Date: Thu, 3 Dec 2020 10:04:21 +0100 Subject: [PATCH 6/9] Revert "Add translation" This reverts commit e19d0c9eeaeadd9c18b3fc39f3522c30db10a24f. --- htdocs/langs/en_US/cashdesk.lang | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/htdocs/langs/en_US/cashdesk.lang b/htdocs/langs/en_US/cashdesk.lang index c0245790e76..549646ab110 100644 --- a/htdocs/langs/en_US/cashdesk.lang +++ b/htdocs/langs/en_US/cashdesk.lang @@ -122,5 +122,4 @@ GiftReceipt=Gift receipt ModuleReceiptPrinterMustBeEnabled=Module Receipt printer must have been enabled first AllowDelayedPayment=Allow delayed payment PrintPaymentMethodOnReceipts=Print payment method on tickets|receipts -WeighingScale=Weighing scale -TakeposNumpadForcePaymentLabels=Show text with icons of payment buttons of numpad +WeighingScale=Weighing scale \ No newline at end of file From 450b04c1ad14131d1185b1d230042ed453218349 Mon Sep 17 00:00:00 2001 From: teleassist Date: Thu, 3 Dec 2020 10:04:28 +0100 Subject: [PATCH 7/9] Revert "Add TAKEPOS_NUMPAD_FORCE_PAYMENT_ICONS_LABELS" This reverts commit 7e9a12a2f8bef1f6947522654e1470661844f054. --- htdocs/takepos/admin/setup.php | 7 ------- 1 file changed, 7 deletions(-) diff --git a/htdocs/takepos/admin/setup.php b/htdocs/takepos/admin/setup.php index bd4c18bda0c..88911f10b7d 100644 --- a/htdocs/takepos/admin/setup.php +++ b/htdocs/takepos/admin/setup.php @@ -307,13 +307,6 @@ print ''; print ajax_constantonoff("TAKEPOS_NUMPAD_USE_PAYMENT_ICON", array(), $conf->entity, 0, 0, 1, 0); print "\n"; -// Numpad show labels for icons -print ''; -print $langs->trans('TakeposNumpadForcePaymentLabels'); -print ''; -print ajax_constantonoff("TAKEPOS_NUMPAD_FORCE_PAYMENT_ICONS_LABELS", array(), $conf->entity, 0, 0, 1, 0); -print "\n"; - // Direct Payment print ''; print $langs->trans('DirectPaymentButton'); From f6adb6ae5530cda5e1e1910fbdf018de41defda7 Mon Sep 17 00:00:00 2001 From: teleassist <30868208+teleassist@users.noreply.github.com> Date: Thu, 3 Dec 2020 10:12:03 +0100 Subject: [PATCH 8/9] Update pay.php Always show labels with payment icons --- htdocs/takepos/pay.php | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/htdocs/takepos/pay.php b/htdocs/takepos/pay.php index 89b936bef6c..ab621a964b5 100644 --- a/htdocs/takepos/pay.php +++ b/htdocs/takepos/pay.php @@ -286,7 +286,6 @@ print ''; + print ''; } else { print ''; } @@ -311,7 +309,6 @@ print ''; + print ''; } else { $button = array_pop($action_buttons); print ''; @@ -337,7 +333,6 @@ print ''; + print ''; } else { $button = array_pop($action_buttons); print ''; From 1f58b49aea03418c9e3bcd65db5a613a300a0ca9 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 3 Dec 2020 14:31:39 +0100 Subject: [PATCH 9/9] No xml inside HTML --- htdocs/takepos/pay.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/htdocs/takepos/pay.php b/htdocs/takepos/pay.php index ab621a964b5..0d80eeffbc0 100644 --- a/htdocs/takepos/pay.php +++ b/htdocs/takepos/pay.php @@ -297,7 +297,7 @@ print ''; + print ''; } else { print ''; } @@ -320,7 +320,7 @@ print ''; + print ''; } else { $button = array_pop($action_buttons); print ''; @@ -344,7 +344,7 @@ print ''; + print ''; } else { $button = array_pop($action_buttons); print '';