diff --git a/admin/themes/default/template/controllers/access/helpers/form/form.tpl b/admin/themes/default/template/controllers/access/helpers/form/form.tpl index d3f2a73f8..7c5a71acc 100644 --- a/admin/themes/default/template/controllers/access/helpers/form/form.tpl +++ b/admin/themes/default/template/controllers/access/helpers/form/form.tpl @@ -107,6 +107,47 @@ } perfect_access_js_gestion(this, perm, id_tab, tabsize, tabnumber, table); + if (perm == 'kpi') { + $(table + ' .kpi.' + id_tab).prop('checked', !!enabled); + } + + $(table + ' tr.kpi-row').each(function() { + var kpiTabId = $(this).data('kpi-parent'); + var kpiProfile = $(this).data('kpi-profile'); + var $kpiInputs = $(this).find('input.ajaxPower.kpi'); + if (!$kpiInputs.length || $kpiInputs.first().data('kpi-editable') != 1) { return; } + // For perm=view, read state directly from action — jQuery 1.11 .attr() doesn't update .prop() + var parentEnabled = (perm == 'view' && (id_tab == kpiTabId || id_tab == -1)) + ? !!enabled + : $(table + ' input.view.' + kpiTabId).first().is(':checked'); + if (!parentEnabled) { + $kpiInputs.prop('checked', false).prop('disabled', true); + } else { + $kpiInputs.prop('disabled', false); + if (perm == 'all' && (id_tab == -1 || id_tab == kpiTabId)) { + $kpiInputs.prop('checked', !!enabled).first().trigger('change'); + } + if (perm == 'view' && (id_tab == kpiTabId || id_tab == -1) && !!enabled) { + $kpiInputs.prop('checked', true); + $.ajax({ + url: "{$link->getAdminLink('AdminAccess')|addslashes}", + cache: false, + data: { + ajaxMode: '1', + id_tab: kpiTabId, + id_profile: kpiProfile, + perm: 'kpi', + enabled: 1, + submitAddAccess: '1', + action: 'updateAccess', + ajax: '1', + token: '{getAdminToken tab='AdminAccess'}' + } + }); + } + } + }); + $.ajax({ url: "{$link->getAdminLink('AdminAccess')|addslashes}", cache: false, @@ -349,6 +390,32 @@ + {if !empty($tab.has_kpi)} +
Your {shop_name} login details
Here are your login details:Important Security Tips:
Order {order_name} - Awaiting payment
Order reference: {order_name}A new order has been generated on your behalf.
Please go on {order_link} to finalize the payment. - +Order {order_name} - Credit slip created
We have generated a credit slip in your name for order with the reference {order_name}. - +VOUCHER GENERATED
@@ -95,7 +95,7 @@ Voucher Code: {voucher_code} for an amount of {voucher_amount}.Product(s) now available for download
You have {nbProducts} product(s) now available for download using the following link(s):Your {shop_name} login information
@@ -93,7 +93,7 @@ Password: {passwd}Customer service - Forwarded discussion
@@ -91,7 +91,7 @@ Discussion history: {messages}Your customer account creation
@@ -91,7 +91,7 @@ E-mail address: {email}Order {order_name} - In transit
Your order with the reference {order_name} is currently in transit.You have received a new log alert
Warning: you have received a new log alert in your Back Office.Order canceled - {order_name}
Your order with the reference {order_name} has been canceled. - +Here are your order details:
@@ -112,7 +112,7 @@ Order reference: {order_name}Order {order_name} - Order changed
Your order with the reference {order_name} from {hotel_hotel_name} has been changed by the merchant. - +Order details
Order: {order_name} Placed on {date}Customer details
Name: {customer_name}Order details
Order: {order_name} Placed on {date}{l s='Hotel details'}:
@@ -9,5 +9,5 @@ {l s='Hotel Email'}: {$list['hotel_email']}Message from {shop_name}
@@ -90,7 +90,7 @@ You have received a new message from {shop_name} regarding booking with the reference {order_name}.Order details
Order: {order_reference} Placed on {order_date}Customer details
Customer name: {customer_name}Order details
Order: {order_reference} Placed on {order_date}Order details
Order: {order_reference} Placed on {order_date}Customer details
Customer name: {customer_name}Order details
Order: {order_reference} Placed on {order_date}Order details
Order: {order_reference} Placed on {order_date}Customer details
Customer name: {customer_name}Order details
Order: {order_reference} Placed on {order_date}Return #{id_order_return} - update
We have updated the progress on your return #{id_order_return}, the new status is: "{state_order_return}"Order details
Order: {order_name} Placed on {date}Customer details
Name: {customer_name}Order details
@@ -118,7 +118,7 @@ Payment: {payment}Order {order_name} - Payment processed
@@ -93,7 +93,7 @@ Total Booking Amount: {total_paid}Your new {shop_name} login details
E-mail address: {email}Password reset request for {shop_name}
@@ -91,7 +91,7 @@ Please note that this will change your current password.Order {order_name} - Payment processed
Your payment for order with the reference {order_name} was successfully processed. - +Order {order_name} - Payment processing error
There is a problem with your payment for {shop_name} order with the reference {order_name}. Please contact us at your earliest convenience.Order {order_name} - Processing
We are currently processing your {shop_name} order with the reference {order_name}. - +Order {order_name} - Refund processed
We have processed your {shop_name} refund for order with the reference {order_name}. - +Message from {contact_name}
Order {order_name} - Shipped
Your order with the reference {order_name} has been shipped.Order {order_name} - Voucher created
A voucher has been created in your name as a result of your order with the reference {order_name}.This is to inform you about the creation of a voucher.
Here is the code of your voucher: {voucher_num}{l s='Here are the bank details for your transfer:' mod='bankwire' lang=$lang}
@@ -35,7 +35,7 @@ {l s='Account details:' mod='bankwire' lang=$lang} {$bankwire_details}Newsletter subscription
@@ -94,7 +94,7 @@ Please note that the voucher will be valid on your first order. - +{l s='Here are the bank details for your check:' mod='cheque' lang=$lang}
@@ -34,7 +34,7 @@ {l s='Payable to the order of:' mod='cheque' lang=$lang} {$cheque_name}|
+ {if !empty($hotel_address)}
+ {l s='Hotel Detail' pdf='true'} + {$hotel_address} + {/if} + |
+ + |
+ {l s='Customer Detail' pdf='true'} + {if $invoice_address} + {$invoice_address} + {else} + {$customer->firstname} {$customer->lastname} + + {$customer->phone} + {/if} + |
+
| {l s='Payment Details' pdf='true'} | +||||
|---|---|---|---|---|
| {l s='Payment Method' pdf='true'} | +{l s='Payment Type' pdf='true'} | +{l s='Transaction ID' pdf='true'} | +{l s='Amount' pdf='true'} | +{l s='Payment Date' pdf='true'} | +
| {$payment->payment_method|default:'-'} | +{$payment->payment_type.name|default:'-'} | +{$payment->transaction_id|default:'-'} | +{displayPrice currency=$payment->id_currency price=$payment->amount} | +{dateFormat date=$payment->date_add full=true} | +
| + + {$addresses_tab} + + | +||||||||||||
| + | ||||||||||||
| + {$payment_info_tab} + | +||||||||||||
| + | ||||||||||||
+
+
|
+ ||||||||||||
| + | ||||||||||||
| + {$HOOK_DISPLAY_PDF} + | +||||||||||||