first commit
This commit is contained in:
36
admin-kalsport/themes/default/template/content-legacy.tpl
Normal file
36
admin-kalsport/themes/default/template/content-legacy.tpl
Normal file
@@ -0,0 +1,36 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<div id="ajax_confirmation" class="alert alert-success hide"></div>
|
||||
{* ajaxBox allows*}
|
||||
<div id="ajaxBox" style="display:none"></div>
|
||||
|
||||
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
{if isset($content)}
|
||||
{$content}
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
35
admin-kalsport/themes/default/template/content.tpl
Normal file
35
admin-kalsport/themes/default/template/content.tpl
Normal file
@@ -0,0 +1,35 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<div id="ajax_confirmation" class="alert alert-success hide"></div>
|
||||
{* ajaxBox allows*}
|
||||
<div id="ajaxBox" style="display:none"></div>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
{if isset($content)}
|
||||
{$content}
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,523 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
var id_tab_parentmodule = {$id_tab_parentmodule|intval};
|
||||
var id_tab_module = {$id_tab_module|intval};
|
||||
$('tr.child-'+id_tab_parentmodule+' > td > input.view.'+id_tab_module).change( function () {
|
||||
if (!$(this).prop('checked'))
|
||||
{
|
||||
$('#table_module_2 thead th:eq(1) input').trigger('click');
|
||||
if ($('#table_module_2 thead th:eq(1) input').prop('checked'))
|
||||
$('#table_module_2 thead th:eq(1) input').trigger('click');
|
||||
}
|
||||
});
|
||||
$('tr.child-'+id_tab_parentmodule+' > td > input.edit.'+id_tab_module).change( function () {
|
||||
if (!$(this).prop('checked'))
|
||||
{
|
||||
$('#table_module_2 thead th:eq(2) input').trigger('click');
|
||||
if ($('#table_module_2 thead th:eq(2) input').prop('checked'))
|
||||
$('#table_module_2 thead th:eq(2) input').trigger('click');
|
||||
}
|
||||
});
|
||||
|
||||
$('div.productTabs').find('a').each(function() {
|
||||
$(this).attr('href', '#');
|
||||
});
|
||||
$('div.productTabs a').click(function() {
|
||||
var id = $(this).attr('id');
|
||||
$('.nav-profile').removeClass('selected');
|
||||
$(this).addClass('selected active');
|
||||
$(this).siblings().removeClass('active');
|
||||
$('.tab-profile').hide()
|
||||
$('.'+id).show();
|
||||
});
|
||||
function getChildren(table, perm, parent, rel) {
|
||||
var kids = document.querySelectorAll(table+" [data-parent='"+parent+"'][data-type='"+perm+"']:not([data-rel='"+rel+"'])");
|
||||
for(var i=0; i<kids.length;i++)
|
||||
{
|
||||
if(kids[i].checked) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
return false;
|
||||
}
|
||||
$('.ajaxPower').change(function(){
|
||||
var tout = $(this).data('rel').split('||');
|
||||
var rel = $(this).data('rel');
|
||||
var id_tab = tout[0];
|
||||
var id_profile = tout[1];
|
||||
var perm = tout[2];
|
||||
var enabled = $(this).is(':checked')? 1 : 0;
|
||||
var tabsize = tout[3];
|
||||
var tabnumber = tout[4];
|
||||
var table = 'table#table_'+id_profile;
|
||||
var $parentRow = ($(this).parents('tr'));
|
||||
var classes = $parentRow.attr('class');
|
||||
var $permissionCheckbox = $(this);
|
||||
var targetPermissionType;
|
||||
var parent = $(this).attr('data-parent');
|
||||
if (parent != 0){
|
||||
var $parentelem = $(table + ' .ajaxPower.' + perm + '.' + parent);
|
||||
if(!$parentelem.is(':checked')){
|
||||
$parentelem.prop("checked", true).change();
|
||||
}else{
|
||||
if(!$(this).is(':checked') && !getChildren(table, perm, parent, rel))
|
||||
$parentelem.prop("checked", false).change();
|
||||
}
|
||||
}
|
||||
switch (true) {
|
||||
case $permissionCheckbox.hasClass('view'): targetPermissionType = '.view'; break;
|
||||
case $permissionCheckbox.hasClass('add'): targetPermissionType = '.add'; break;
|
||||
case $permissionCheckbox.hasClass('delete'): targetPermissionType = '.delete'; break;
|
||||
case $permissionCheckbox.hasClass('edit'): targetPermissionType = '.edit'; break;
|
||||
}
|
||||
if (enabled && classes) {
|
||||
var subject = 'child';
|
||||
var subjectIndex = classes.indexOf(subject);
|
||||
if (-1 !== subjectIndex) {
|
||||
var subjectIndexes = [];
|
||||
while (-1 !== subjectIndex) {
|
||||
subjectIndexes.push(subjectIndex);
|
||||
subjectIndex = classes.indexOf(subject, subjectIndex + 1);
|
||||
}
|
||||
subjectIndexes.pop();
|
||||
var classAttribute = subject + '-';
|
||||
var targetClass;
|
||||
var $parentPermissions;
|
||||
var $parentPermission;
|
||||
while (subjectIndexes.length > 0) {
|
||||
targetClass = new Array(subjectIndexes.length + 1).join(classAttribute);
|
||||
$parentPermissions = $parentRow.prevAll().filter(function (rowIndex, row) {
|
||||
return $(row).attr('class').match(new RegExp('^' + targetClass + '[0-9]'));
|
||||
});
|
||||
$parentPermission = $($parentPermissions[0]).find(targetPermissionType);
|
||||
if (!$parentPermission.prop('checked')) {
|
||||
$parentPermission.prop('checked', true);
|
||||
}
|
||||
subjectIndexes.pop();
|
||||
}
|
||||
var $topParent = $($parentRow.prevAll().filter('.parent')[0]).find(targetPermissionType);
|
||||
if (!$topParent.prop('checked')) {
|
||||
$topParent.prop('checked', true);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (perm == 'all' && $(this).parent().parent().hasClass('parent'))
|
||||
{
|
||||
if (enabled)
|
||||
$(this).parent().parent().parent().find('.child-'+id_tab+' input[type=checkbox]').attr('checked', 'checked');
|
||||
else
|
||||
$(this).parent().parent().parent().find('.child-'+id_tab+' input[type=checkbox]').removeAttr('checked');
|
||||
$.ajax({
|
||||
url: "{$link->getAdminLink('AdminAccess')|addslashes}",
|
||||
cache: false,
|
||||
data : {
|
||||
ajaxMode : '1',
|
||||
id_tab: id_tab,
|
||||
id_profile: id_profile,
|
||||
perm: perm,
|
||||
enabled: enabled,
|
||||
submitAddAccess: '1',
|
||||
addFromParent: '1',
|
||||
action: 'updateAccess',
|
||||
ajax: '1',
|
||||
token: '{getAdminToken tab='AdminAccess'}'
|
||||
},
|
||||
success : function(res,textStatus,jqXHR)
|
||||
{
|
||||
try {
|
||||
if (res == 'ok')
|
||||
showSuccessMessage("{l s='Update successful' d='Admin.Notifications.Success'}");
|
||||
else
|
||||
showErrorMessage("{l s='Unable to update settings.' d='Admin.Notifications.Error'}");
|
||||
} catch(e) {
|
||||
jAlert('Technical error');
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
perfect_access_js_gestion(this, perm, id_tab, tabsize, tabnumber, table);
|
||||
$.ajax({
|
||||
url: "{$link->getAdminLink('AdminAccess')|addslashes}",
|
||||
cache: false,
|
||||
data : {
|
||||
ajaxMode : '1',
|
||||
id_tab: id_tab,
|
||||
id_profile: id_profile,
|
||||
perm: perm,
|
||||
enabled: enabled,
|
||||
submitAddAccess: '1',
|
||||
action: 'updateAccess',
|
||||
ajax: '1',
|
||||
token: '{getAdminToken tab='AdminAccess'}'
|
||||
},
|
||||
success : function(res,textStatus,jqXHR)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (res == 'ok')
|
||||
showSuccessMessage("{l s='Update successful' d='Admin.Notifications.Success'}");
|
||||
else
|
||||
showErrorMessage("{l s='Unable to update settings.' d='Admin.Notifications.Error'}");
|
||||
}
|
||||
catch(e)
|
||||
{
|
||||
jAlert('Technical error');
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
$(".changeModuleAccess").change(function(){
|
||||
var tout = $(this).data('rel').split('||');
|
||||
var id_module = tout[0];
|
||||
var perm = tout[1];
|
||||
var id_profile = tout[2];
|
||||
var enabled = $(this).is(':checked') ? 1 : 0;
|
||||
var enabled_attr = $(this).is(':checked') ? true : false;
|
||||
var table = 'table#table_module_'+id_profile;
|
||||
if (id_module == -1)
|
||||
$(table+' .ajax-ma-'+perm).each(function(key, value) {
|
||||
$(this).attr("checked", enabled_attr);
|
||||
});
|
||||
else if (!enabled)
|
||||
$(table+' #ajax-ma-'+perm+'-master').each(function(key, value) {
|
||||
$(this).attr("checked", enabled_attr);
|
||||
});
|
||||
$.ajax({
|
||||
url: "{$link->getAdminLink('AdminAccess')|addslashes}",
|
||||
cache: false,
|
||||
data : {
|
||||
ajaxMode: '1',
|
||||
id_module: id_module,
|
||||
perm: perm,
|
||||
enabled: enabled,
|
||||
id_profile: id_profile,
|
||||
changeModuleAccess: '1',
|
||||
action: 'updateModuleAccess',
|
||||
ajax: '1',
|
||||
token: '{getAdminToken tab='AdminAccess'}'
|
||||
},
|
||||
success : function(res,textStatus,jqXHR)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (res == 'ok')
|
||||
showSuccessMessage("{l s='Update successful' d='Admin.Notifications.Success'}");
|
||||
else
|
||||
showErrorMessage("{l s='Unable to update settings.' d='Admin.Notifications.Error'}");
|
||||
}
|
||||
catch(e)
|
||||
{
|
||||
jAlert('Technical error');
|
||||
}
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
</script>
|
||||
{if $show_toolbar}
|
||||
{include file="toolbar.tpl" toolbar_btn=$toolbar_btn toolbar_scroll=$toolbar_scroll title=$title}
|
||||
<div class="leadin">{block name="leadin"}{/block}</div>
|
||||
{/if}
|
||||
<div class="row">
|
||||
<div class="productTabs col-lg-2">
|
||||
<div class="tab list-group">
|
||||
{foreach $profiles as $profile}
|
||||
<a class="list-group-item nav-profile {if $profile.id_profile == $current_profile}active{/if}"
|
||||
id="profile-{$profile.id_profile}"
|
||||
href="{$current|escape:'html':'UTF-8'}&token={$token|escape:'html':'UTF-8'}&id_profile={$profile.id_profile}">{$profile.name}</a>
|
||||
{/foreach}
|
||||
</div>
|
||||
</div>
|
||||
<form id="{$table}_form" class="defaultForm form-horizontal col-lg-10"
|
||||
action="{$current|escape:'html':'UTF-8'}&{$submit_action}=1&token={$token|escape:'html':'UTF-8'}"
|
||||
method="post" enctype="multipart/form-data">
|
||||
{if $form_id}
|
||||
<input type="hidden" name="{$identifier}" id="{$identifier}" value="{$form_id}"/>
|
||||
{/if}
|
||||
{assign var=tabsize value=count($tabs)}
|
||||
{foreach $tabs AS $tab}
|
||||
{if $tab.id_tab > $tabsize}
|
||||
{assign var=tabsize value=$tab.id_tab}
|
||||
{/if}
|
||||
{/foreach}
|
||||
{foreach $profiles as $profile}
|
||||
<div class="profile-{$profile.id_profile} tab-profile"
|
||||
style="display:{if $profile.id_profile != $current_profile}none{/if}">
|
||||
<div class="row">
|
||||
{if $profile.id_profile != $admin_profile}
|
||||
<div class="col-lg-6">
|
||||
<div class="panel">
|
||||
<h3>{l s='Menu' d='Admin.Advparameters.Feature'}</h3>
|
||||
<table class="table" id="table_{$profile.id_profile}">
|
||||
{assign var=enable_bulk_view value=true}
|
||||
{assign var=enable_bulk_add value=true}
|
||||
{assign var=enable_bulk_edit value=true}
|
||||
{assign var=enable_bulk_delete value=true}
|
||||
{assign var=enable_bulk_all value=true}
|
||||
<tbody>
|
||||
{if !count($tabs)}
|
||||
<tr>
|
||||
<td colspan="6">{l s='No menu' d='Admin.Advparameters.Feature'}</td>
|
||||
</tr>
|
||||
{else}
|
||||
{foreach $tabs AS $tab}
|
||||
{assign var=access value=$accesses[$profile.id_profile]}
|
||||
{assign var=result_accesses value=0}
|
||||
<tr class="parent">
|
||||
<td class="bold"> »<strong>{$tab.name}</strong></td>
|
||||
{assign var=has_all_rights value=true}
|
||||
{foreach $perms as $perm}
|
||||
{assign var=id_perm value=$id_perms[$perm]}
|
||||
{if $access_edit == 1 && $accesses[$employee_profile_id][$tab.id_tab][$perm]}
|
||||
<td>
|
||||
<input type="checkbox" data-id="{$id_perm}" data-parent="0" data-type="{$perm}"
|
||||
data-rel="{$access[$tab.id_tab]['id_tab']}||{$profile.id_profile}||{$perm}||{$tabsize}||{count($tabs)}"
|
||||
class="ajaxPower {$perm} {$access[$tab.id_tab]['id_tab']}"{if $access[$tab.id_tab][$perm] == 1} checked="checked"{/if}/>
|
||||
</td>
|
||||
{else}
|
||||
{assign var=has_all_rights value=false}
|
||||
{assign var=enable_bulk_view value=false}
|
||||
<td>
|
||||
<input type="checkbox"
|
||||
disabled="disabled"{if $access[$tab.id_tab][$perm] == 1} checked="checked"{/if}/>
|
||||
</td>
|
||||
{/if}
|
||||
{assign var=result_accesses value=$result_accesses + $access[$tab.id_tab][$perm]}
|
||||
{/foreach}
|
||||
<td>
|
||||
<input
|
||||
type="checkbox"{if $access_edit == 1 && $has_all_rights} data-id="4" data-parent="0" data-type="all" data-rel="{$access[$tab.id_tab]['id_tab']}||{$profile.id_profile}||all||{$tabsize}||{count($tabs)}" class="ajaxPower all {$access[$tab.id_tab]['id_tab']}"{else} class="all {$access[$tab.id_tab]['id_tab']}" disabled="disabled"{/if}{if $result_accesses == 4} checked="checked"{/if}/>
|
||||
</td>
|
||||
</tr>
|
||||
{if count($tab.children)}
|
||||
{foreach $tab.children AS $child}
|
||||
{if $child.id_parent === $tab.id_tab}
|
||||
{if isset($access[$child.id_tab])}
|
||||
{assign var=is_child value=true}
|
||||
{assign var=result_accesses value=0}
|
||||
<tr class="child-{$child.id_parent}">
|
||||
<td class="bold"> » {$child.name}</td>
|
||||
{assign var=has_all_rights value=true}
|
||||
{foreach $perms as $perm}
|
||||
{assign var=id_perm value=$id_perms[$perm]}
|
||||
{if $access_edit == 1 && $accesses[$employee_profile_id][$child.id_tab][$perm]}
|
||||
<td>
|
||||
<input type="checkbox" data-id="{$id_perm}" data-parent="{$child.id_parent}"
|
||||
data-type="{$perm}"
|
||||
data-rel="{$access[$child.id_tab]['id_tab']}||{$profile.id_profile}||{$perm}||{$tabsize}||{count($tabs)}"
|
||||
class="ajaxPower {$perm} {$access[$child.id_tab]['id_tab']}"{if $access[$child.id_tab][$perm] == 1} checked="checked"{/if}/>
|
||||
</td>
|
||||
{else}
|
||||
{assign var=has_all_rights value=false}
|
||||
{assign var=enable_bulk_add value=false}
|
||||
<td>
|
||||
<input type="checkbox"
|
||||
disabled="disabled"{if $access[$child.id_tab][$perm] == 1} checked="checked"{/if}/>
|
||||
</td>
|
||||
{/if}
|
||||
{assign var=result_accesses value=$result_accesses + $access[$child.id_tab][$perm]}
|
||||
{/foreach}
|
||||
<td>
|
||||
<input
|
||||
type="checkbox"{if $access_edit == 1 && $has_all_rights} data-id="4" data-parent="{$child.id_parent}" data-type="all" data-rel="{$access[$child.id_tab]['id_tab']}||{$profile.id_profile}||all||{$tabsize}||{count($tabs)}" class="ajaxPower all {$access[$child.id_tab]['id_tab']}"{else} class="all {$access[$child.id_tab]['id_tab']}" disabled="disabled"{/if}{if $result_accesses == 4} checked="checked"{/if}/>
|
||||
</td>
|
||||
</tr>
|
||||
{/if}
|
||||
|
||||
{if count($child.children)}
|
||||
{foreach $child.children AS $subChild}
|
||||
{if isset($access[$subChild.id_tab])}
|
||||
{assign var=is_child value=true}
|
||||
{assign var=result_accesses value=0}
|
||||
<tr class="child-child-{$subChild.id_parent}">
|
||||
<td class="bold"> » {$subChild.name}</td>
|
||||
{assign var=has_all_rights value=true}
|
||||
{foreach $perms as $perm}
|
||||
{assign var=id_perm value=$id_perms[$perm]}
|
||||
{if $access_edit == 1 && $accesses[$employee_profile_id][$subChild.id_tab][$perm]}
|
||||
<td>
|
||||
<input type="checkbox" data-id="{$id_perm}"
|
||||
data-parent="{$subChild.id_parent}" data-type="{$perm}"
|
||||
data-rel="{$access[$subChild.id_tab]['id_tab']}||{$profile.id_profile}||{$perm}||{$tabsize}||{count($tabs)}"
|
||||
class="ajaxPower {$perm} {$access[$subChild.id_tab]['id_tab']}"{if $access[$subChild.id_tab][$perm] == 1} checked="checked"{/if}/>
|
||||
</td>
|
||||
{else}
|
||||
{assign var=has_all_rights value=false}
|
||||
{assign var=enable_bulk_edit value=false}
|
||||
<td>
|
||||
<input type="checkbox"
|
||||
disabled="disabled"{if $access[$subChild.id_tab][$perm] == 1} checked="checked"{/if}/>
|
||||
</td>
|
||||
{/if}
|
||||
{assign var=result_accesses value=$result_accesses + $access[$subChild.id_tab][$perm]}
|
||||
{/foreach}
|
||||
<td>
|
||||
<input
|
||||
type="checkbox"{if $access_edit == 1 && $has_all_rights} data-id="4" data-parent="{$subChild.id_parent}" data-type="all" data-rel="{$access[$subChild.id_tab]['id_tab']}||{$profile.id_profile}||all||{$tabsize}||{count($tabs)}" class="ajaxPower all {$access[$subChild.id_tab]['id_tab']}"{else} class="all {$access[$subChild.id_tab]['id_tab']}" disabled="disabled"{/if}{if $result_accesses == 4} checked="checked"{/if}/>
|
||||
</td>
|
||||
</tr>
|
||||
{if count($subChild.children)}
|
||||
{foreach $subChild.children AS $subsubChild}
|
||||
{if isset($access[$subsubChild.id_tab])}
|
||||
{assign var=is_child value=true}
|
||||
{assign var=result_accesses value=0}
|
||||
<tr class="child-child-child-{$subsubChild.id_parent}">
|
||||
<td class="bold"> » {$subsubChild.name}</td>
|
||||
{assign var=has_all_rights value=true}
|
||||
{foreach $perms as $perm}
|
||||
{assign var=id_perm value=$id_perms[$perm]}
|
||||
{if $access_edit == 1 && $accesses[$employee_profile_id][$subsubChild.id_tab][$perm]}
|
||||
<td>
|
||||
<input type="checkbox" data-id="{$id_perm}"
|
||||
data-parent="{$subsubChild.id_parent}" data-type="{$perm}"
|
||||
data-rel="{$access[$subsubChild.id_tab]['id_tab']}||{$profile.id_profile}||{$perm}||{$tabsize}||{count($tabs)}"
|
||||
class="ajaxPower {$perm} {$access[$subsubChild.id_tab]['id_tab']}"{if $access[$subsubChild.id_tab][$perm] == 1} checked="checked"{/if}/>
|
||||
</td>
|
||||
{else}
|
||||
{assign var=has_all_rights value=false}
|
||||
{assign var=enable_bulk_delete value=false}
|
||||
<td>
|
||||
<input type="checkbox"
|
||||
disabled="disabled"{if $access[$subsubChild.id_tab][$perm] == 1} checked="checked"{/if}/>
|
||||
</td>
|
||||
{/if}
|
||||
{assign var=result_accesses value=$result_accesses + $access[$subsubChild.id_tab][$perm]}
|
||||
{/foreach}
|
||||
<td>
|
||||
<input
|
||||
type="checkbox"{if $access_edit == 1 && $has_all_rights} data-id="4" data-parent="{$subChild.id_parent}" data-type="all" data-rel="{$access[$subsubChild.id_tab]['id_tab']}||{$profile.id_profile}||all||{$tabsize}||{count($tabs)}" class="ajaxPower all {$access[$subsubChild.id_tab]['id_tab']}"{else} {assign var=enable_bulk_all value=false}class="all {$access[$subsubChild.id_tab]['id_tab']}" disabled="disabled"{/if}{if $result_accesses == 4} checked="checked"{/if}/>
|
||||
</td>
|
||||
</tr>
|
||||
{/if}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/foreach}
|
||||
{/if}
|
||||
</tbody>
|
||||
<thead>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th>
|
||||
<input type="checkbox" name="1"
|
||||
class="viewall ajaxPower"{if $access_edit == 1 && $enable_bulk_view} data-id="0" data-parent="0" data-type="view" data-rel="-1||{$profile.id_profile}||view||{$tabsize}||{count($tabs)}"{else} disabled="disabled"{/if}/>
|
||||
{l s='View' d='Admin.Actions'}
|
||||
</th>
|
||||
<th>
|
||||
<input type="checkbox" name="1"
|
||||
class="addall ajaxPower"{if $access_edit == 1 && $enable_bulk_add} data-id="1" data-parent="0" data-type="add" data-rel="-1||{$profile.id_profile}||add||{$tabsize}||{count($tabs)}"{else} disabled="disabled"{/if}/>
|
||||
{l s='Add' d='Admin.Actions'}
|
||||
</th>
|
||||
<th>
|
||||
<input type="checkbox" name="1"
|
||||
class="editall ajaxPower"{if $access_edit == 1 && $enable_bulk_edit} data-id="2" data-parent="0" data-type="edit" data-rel="-1||{$profile.id_profile}||edit||{$tabsize}||{count($tabs)}"{else} disabled="disabled"{/if}/>
|
||||
{l s='Edit' d='Admin.Actions'}
|
||||
</th>
|
||||
<th>
|
||||
<input type="checkbox" name="1"
|
||||
class="deleteall ajaxPower"{if $access_edit == 1 && $enable_bulk_delete} data-id="3" data-parent="0" data-type="delete" data-rel="-1||{$profile.id_profile}||delete||{$tabsize}||{count($tabs)}"{else} disabled="disabled"{/if}/>
|
||||
{l s='Delete' d='Admin.Actions'}
|
||||
</th>
|
||||
<th>
|
||||
<input type="checkbox" name="1"
|
||||
class="allall ajaxPower"{if $access_edit == 1 && $enable_bulk_all} data-id="4" data-parent="0" data-type="all" data-rel="-1||{$profile.id_profile}||all||{$tabsize}||{count($tabs)}"{else} disabled="disabled"{/if}/>
|
||||
{l s='All' d='Admin.Global'}
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
<div class="panel">
|
||||
<h3>{l s='Modules' d='Admin.Global'}</h3>
|
||||
<table class="table" id="table_module_{$profile.id_profile}">
|
||||
<tbody>
|
||||
{if !count($modules)}
|
||||
<tr>
|
||||
<td colspan="3">{l s='No module has been installed.' d='Admin.Notifications.Warning'}</td>
|
||||
</tr>
|
||||
{else}
|
||||
{assign var=enable_bulk_view value=true}
|
||||
{assign var=enable_bulk_configure value=true}
|
||||
{assign var=enable_bulk_uninstall value=true}
|
||||
{foreach from=$modules[$profile.id_profile] item=module key=k}
|
||||
<tr>
|
||||
<td>» {$module.name}</td>
|
||||
<td>
|
||||
<input type="checkbox"
|
||||
value="1"{if $module.view == true} checked="checked"{/if}{if $access_edit == 1 && $modules[$employee_profile_id][$k].view} class="ajax-ma-view changeModuleAccess" data-rel="{$module.id_module}||view||{$profile.id_profile}"{else}{assign var=enable_bulk_view value=false} class="ajax-ma-view" disabled="disabled"{/if}/>
|
||||
</td>
|
||||
<td>
|
||||
<input type="checkbox"
|
||||
value="1"{if $module.configure == true} checked="checked"{/if}{if $access_edit == 1 && $modules[$employee_profile_id][$k].configure} class="ajax-ma-configure changeModuleAccess" data-rel="{$module.id_module}||configure||{$profile.id_profile}"{else}{assign var=enable_bulk_configure value=false} class="ajax-ma-configure" disabled="disabled"{/if}/>
|
||||
</td>
|
||||
<td>
|
||||
<input type="checkbox"
|
||||
value="1"{if $module.uninstall == true} checked="checked"{/if}{if $access_edit == 1 && $modules[$employee_profile_id][$k].uninstall} class="ajax-ma-uninstall changeModuleAccess" data-rel="{$module.id_module}||uninstall||{$profile.id_profile}"{else}{assign var=enable_bulk_uninstall value=false} class="ajax-ma-uninstall" disabled="disabled"{/if}/>
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
{/if}
|
||||
</tbody>
|
||||
<thead>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th>
|
||||
<input
|
||||
type="checkbox"{if $access_edit == 1 && $enable_bulk_view} class="changeModuleAccess" data-rel="-1||view||{$profile.id_profile}"{else} disabled="disabled"{/if}/> {l s='View' d='Admin.Actions'}
|
||||
</th>
|
||||
<th>
|
||||
<input
|
||||
type="checkbox"{if $access_edit == 1 && $enable_bulk_configure} class="changeModuleAccess" data-rel="-1||configure||{$profile.id_profile}"{else} disabled="disabled"{/if}/> {l s='Configure' d='Admin.Actions'}
|
||||
</th>
|
||||
<th>
|
||||
<input
|
||||
type="checkbox"{if $access_edit == 1 && $enable_bulk_uninstall} class="changeModuleAccess" data-rel="-1||uninstall||{$profile.id_profile}"{else} disabled="disabled"{/if}/> {l s='Uninstall' d='Admin.Actions'}
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{else}
|
||||
<div class="col-lg-12">
|
||||
<div class="panel">
|
||||
{l s='Administrator permissions cannot be modified.' d='Admin.Advparameters.Notification'}
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
{/foreach}
|
||||
</form>
|
||||
</div>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,143 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
<script type="text/javascript">
|
||||
var attrs = new Array();
|
||||
attrs[0] = new Array(0, '---');
|
||||
|
||||
{foreach $attribute_js as $idgrp => $group}
|
||||
{assign var="row" value="attrs[{$idgrp}] = new Array(0, '---'"}
|
||||
|
||||
{foreach $group as $idattr => $attrname}
|
||||
{assign var="row" value="{$row}, {$idattr}, '{$attrname|escape}'"}
|
||||
{/foreach}
|
||||
|
||||
{assign var="row" value="{$row});"}
|
||||
{$row}
|
||||
{/foreach}
|
||||
|
||||
i18n_tax_exc = '{l s='Tax Excluded'} ';
|
||||
i18n_tax_inc = '{l s='Tax Included'} ';
|
||||
|
||||
var product_tax = '{$tax_rates}';
|
||||
function calcPrice(element, element_has_tax)
|
||||
{
|
||||
var element_price = element.val().replace(/,/g, '.');
|
||||
var other_element_price = 0;
|
||||
|
||||
if (!isNaN(element_price))
|
||||
{
|
||||
if (element_has_tax)
|
||||
other_element_price = ps_round(parseFloat(element_price / ((product_tax / 100) + 1)), 6);
|
||||
else
|
||||
other_element_price = ps_round(parseFloat(element_price * ((product_tax / 100) + 1)), 6);
|
||||
}
|
||||
|
||||
$('#related_to_'+element.attr('name')).val(other_element_price);
|
||||
}
|
||||
|
||||
$(document).ready(function() { $('.price_impact').each(function() { calcPrice($(this), false); }); });
|
||||
</script>
|
||||
|
||||
<div class="leadin">{block name="leadin"}{/block}</div>
|
||||
|
||||
{if $generate}<div class="alert alert-success clearfix">{l s='%d product(s) successfully created.' sprintf=[$combinations_size]}</div>{/if}
|
||||
<form enctype="multipart/form-data" method="post" id="generator" action="{$url_generator}">
|
||||
<div class="panel">
|
||||
<h3>
|
||||
<i class="icon-asterisk"></i>
|
||||
{l s='Attributes generator'}
|
||||
</h3>
|
||||
<div class="row">
|
||||
<div class="col-lg-3">
|
||||
<div class="form-group">
|
||||
<select multiple name="attributes[]" id="attribute_group" style="height: 500px">
|
||||
{foreach $attribute_groups as $k => $attribute_group}
|
||||
{if isset($attribute_js[$attribute_group['id_attribute_group']])}
|
||||
<optgroup name="{$attribute_group['id_attribute_group']}" id="{$attribute_group['id_attribute_group']}" label="{$attribute_group['name']|escape:'html':'UTF-8'}">
|
||||
{foreach $attribute_js[$attribute_group['id_attribute_group']] as $k => $v}
|
||||
<option name="{$k}" id="attr_{$k}" value="{$v|escape:'html':'UTF-8'}" title="{$v|escape:'html':'UTF-8'}">{$v|escape:'html':'UTF-8'}</option>
|
||||
{/foreach}
|
||||
</optgroup>
|
||||
{/if}
|
||||
{/foreach}
|
||||
</select>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<button type="button" class="btn btn-default" onclick="del_attr_multiple();"><i class="icon-minus-sign"></i> {l s='Delete' d='Admin.Actions'}</button>
|
||||
<button type="button" class="btn btn-default pull-right" onclick="add_attr_multiple();"><i class="icon-plus-sign"></i> {l s='Add' d='Admin.Actions'}</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-8 col-lg-offset-1">
|
||||
<div class="alert alert-info">{l s='The Combinations Generator is a tool that allows you to easily create a series of combinations by selecting the related attributes. For example, if you\'re selling t-shirts in three different sizes and two different colors, the generator will create six combinations for you.'}</div>
|
||||
|
||||
<div class="alert alert-info">{l s='You\'re currently generating combinations for the following product:'} <b>{$product_name|escape:'html':'UTF-8'}</b></div>
|
||||
|
||||
<div class="alert alert-info"><strong>{l s='Step 1: On the left side, select the attributes you want to use (Hold down the "Ctrl" key on your keyboard and validate by clicking on "%add_label%")' d='Admin.Catalog.Notification' sprintf=['%add_label%' => {l s='Add' d='Admin.Actions'}]}</strong></div>
|
||||
|
||||
{foreach $attribute_groups as $k => $attribute_group}
|
||||
{if isset($attribute_js[$attribute_group['id_attribute_group']])}
|
||||
<div class="row">
|
||||
<table class="table" style="display:none">
|
||||
<thead>
|
||||
<tr>
|
||||
<th id="tab_h1" class="fixed-width-md"><span class="title_box">{$attribute_group['name']|escape:'html':'UTF-8'}</span></th>
|
||||
<th id="tab_h2" colspan="2"><span class="title_box">{l s='Impact on the product price'} ({$currency_sign})</span></th>
|
||||
<th><span class="title_box">{l s='Impact on the product weight'} ({$weight_unit})</span></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody id="table_{$attribute_group['id_attribute_group']}" name="result_table">
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{if isset($attributes[$attribute_group['id_attribute_group']])}
|
||||
{foreach $attributes[$attribute_group['id_attribute_group']] AS $k => $attribute}
|
||||
<script type="text/javascript">
|
||||
$('#table_{$attribute_group['id_attribute_group']}').append(create_attribute_row({$k}, {$attribute_group['id_attribute_group']}, '{$attribute['attribute_name']|addslashes}', {$attribute['price']}, {$attribute['weight']}));
|
||||
toggle(getE('table_' + {$attribute_group['id_attribute_group']}).parentNode, true);
|
||||
</script>
|
||||
{/foreach}
|
||||
{/if}
|
||||
{/if}
|
||||
{/foreach}
|
||||
<div class="alert alert-info">{l s='Select a default quantity, and reference, for each combination the generator will create for this product.'}</div>
|
||||
<table class="table">
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>{l s='Default Quantity:'}</td>
|
||||
<td><input type="text" name="quantity" value="0" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>{l s='Default Reference:'}</td>
|
||||
<td><input type="text" name="reference" value="{$product_reference|escape:'html':'UTF-8'}" /></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
<div class="alert alert-info">{l s='Please click on "%generate_label%".' d='Admin.Catalog.Notification' sprintf=['%generate_label%' => {l s='Generate these combinations'}]}</div>
|
||||
<button type="submit" class="btn btn-default" name="generate"><i class="icon-random"></i> {l s='Generate these combinations'}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,95 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/form/form.tpl"}
|
||||
|
||||
{block name="input_row"}
|
||||
{if $input.type == 'color' || $input.name == 'texture' || $input.name == 'current_texture'}
|
||||
<div class="colorAttributeProperties"{if !$colorAttributeProperties} style="display: none;"{/if}>
|
||||
{/if}
|
||||
{$smarty.block.parent}
|
||||
{if $input.type == 'color' || $input.name == 'texture' || $input.name == 'current_texture'}
|
||||
</div>
|
||||
{/if}
|
||||
{if $input.name == 'name'}
|
||||
{hook h="displayAttributeForm" id_attribute=$form_id}
|
||||
{/if}
|
||||
{/block}
|
||||
|
||||
{block name="field"}
|
||||
{if $input.name == 'current_texture'}
|
||||
<div class="col-lg-8">
|
||||
{if isset($imageTextureExists) && $imageTextureExists}
|
||||
<img src="{$imageTexture}" alt="{l s='Texture' d='Admin.Catalog.Feature'}" class="img-thumbnail" />
|
||||
{else}
|
||||
<p class="form-control-static">{l s='None' d='Admin.Global'}</p>
|
||||
{/if}
|
||||
{if isset($imageTextureUrl) && $imageTextureUrl && isset($imageTextureExists) && $imageTextureExists}
|
||||
<p>
|
||||
<a class="btn btn-default" href="{$imageTextureUrl}">
|
||||
<i class="icon-trash"></i> {l s='Delete' d='Admin.Actions'}
|
||||
</a>
|
||||
</p>
|
||||
{/if}
|
||||
</div>
|
||||
{else}
|
||||
{$smarty.block.parent}
|
||||
{/if}
|
||||
{/block}
|
||||
|
||||
{block name="script"}
|
||||
var attributesGroups = {ldelim}{$strAttributesGroups}{rdelim};
|
||||
|
||||
var displayColorFieldsOption = function() {
|
||||
var val = $('#id_attribute_group').val();
|
||||
if (attributesGroups[val])
|
||||
$('.colorAttributeProperties').show();
|
||||
else
|
||||
$('.colorAttributeProperties').hide();
|
||||
};
|
||||
|
||||
displayColorFieldsOption();
|
||||
|
||||
$('#id_attribute_group').change(displayColorFieldsOption);
|
||||
|
||||
var shop_associations = {$fields[0]['form']['shop_associations']};
|
||||
var changeAssociationGroup = function()
|
||||
{
|
||||
var id_attribute_group = $('#id_attribute_group').val();
|
||||
$('.input_shop').each(function(k, item)
|
||||
{
|
||||
var id_shop = $(item).attr('shop_id');
|
||||
if (typeof shop_associations[id_attribute_group] != 'undefined' && $.inArray(id_shop, shop_associations[id_attribute_group]) > -1)
|
||||
$(item).attr('disabled', false);
|
||||
else
|
||||
{
|
||||
$(item).attr('disabled', true);
|
||||
$(item).attr('checked', false);
|
||||
}
|
||||
});
|
||||
};
|
||||
$('#id_attribute_group').change(changeAssociationGroup);
|
||||
changeAssociationGroup();
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,33 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/form/form.tpl"}
|
||||
|
||||
{block name="input_row"}
|
||||
{$smarty.block.parent}
|
||||
{if $input.name == 'public_name'}
|
||||
{hook h="displayAttributeGroupForm" id_attribute_group=$form_id}
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,33 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/list/list_header.tpl"}
|
||||
{block name=leadin}
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
$(location.hash).click();
|
||||
});
|
||||
</script>
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,63 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
{extends file="helpers/form/form.tpl"}
|
||||
{block name="script"}
|
||||
var string_price = '{l s='Will be applied when the price is' js=1 d='Admin.Shipping.Feature'}';
|
||||
var string_weight = '{l s='Will be applied when the weight is' js=1 d='Admin.Shipping.Feature'}';
|
||||
{/block}
|
||||
|
||||
{block name="field"}
|
||||
{if $input.name == 'zones'}
|
||||
<div class="ranges_not_follow warn" style="display:none">
|
||||
<label>{l s='Ranges are not correctly ordered:' d='Admin.Shipping.Notification'}</label>
|
||||
<a href="#" onclick="checkRangeContinuity(true); return false;" class="btn btn-default">{l s='Reordering' d='Admin.Shipping.Notification'}</a>
|
||||
</div>
|
||||
{include file='controllers/carrier_wizard/helpers/form/form_ranges.tpl'}
|
||||
|
||||
<div class="new_range">
|
||||
<a href="#" onclick="add_new_range();return false;" class="btn btn-default" id="add_new_range">{l s='Add new range' d='Admin.Shipping.Feature'}</a>
|
||||
</div>
|
||||
{/if}
|
||||
{if $input.name == 'logo'}
|
||||
<div class="col-lg-8">
|
||||
<input id="carrier_logo_input" class="hide" type="file" onchange="uploadCarrierLogo();" name="carrier_logo_input" />
|
||||
<input type="hidden" id="logo" name="logo" value="" />
|
||||
<div class="dummyfile input-group">
|
||||
<span class="input-group-addon"><i class="icon-file"></i></span>
|
||||
<input id="attachement_filename" type="text" name="filename" readonly="" />
|
||||
<span class="input-group-btn">
|
||||
<button id="attachement_fileselectbutton" type="button" name="submitAddAttachments" class="btn btn-default">
|
||||
<i class="icon-folder-open"></i> {l s='Choose a file' d='Admin.Actions'}
|
||||
</button>
|
||||
</span>
|
||||
</div>
|
||||
<p class="help-block">
|
||||
{l s='Format:' d='Admin.Shipping.Help'} JPG, GIF, PNG. {l s='Filesize:' d='Admin.Shipping.Help'} {$max_image_size|string_format:"%.2f"} {l s='MB max.' d='Admin.Shipping.Help'}
|
||||
{l s='Current size:' d='Admin.Shipping.Help'} <span id="carrier_logo_size">{l s='undefined' d='Admin.Shipping.Help'}</span>.
|
||||
</p>
|
||||
</div>
|
||||
{/if}
|
||||
{$smarty.block.parent}
|
||||
{/block}
|
||||
@@ -0,0 +1,131 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<script>var zones_nbr = {$zones|count +3} ; /*corresponds to the third input text (max, min and all)*/</script>
|
||||
<div id="zone_ranges" style="overflow:auto">
|
||||
<h4>{l s='Ranges' d='Admin.Shipping.Feature'}</h4>
|
||||
<table id="zones_table" class="table" style="max-width:100%">
|
||||
<tbody>
|
||||
<tr class="range_inf">
|
||||
<td class="range_type"></td>
|
||||
<td class="border_left border_bottom range_sign">>=</td>
|
||||
{foreach from=$ranges key=r item=range}
|
||||
<td class="border_bottom">
|
||||
<div class="input-group fixed-width-md">
|
||||
<span class="input-group-addon weight_unit">{$PS_WEIGHT_UNIT}</span>
|
||||
<span class="input-group-addon price_unit">{$currency_sign}</span>
|
||||
<input class="form-control" name="range_inf[{$range.id_range|intval}]" type="text" value="{$range.delimiter1|string_format:"%.6f"}" />
|
||||
</div>
|
||||
</td>
|
||||
{foreachelse}
|
||||
<td class="border_bottom">
|
||||
<div class="input-group fixed-width-md">
|
||||
<span class="input-group-addon weight_unit">{$PS_WEIGHT_UNIT}</span>
|
||||
<span class="input-group-addon price_unit">{$currency_sign}</span>
|
||||
<input name="form-control range_inf[{$range.id_range|intval}]" type="text" />
|
||||
</div>
|
||||
</td>
|
||||
{/foreach}
|
||||
</tr>
|
||||
<tr class="range_sup">
|
||||
<td class="range_type"></td>
|
||||
<td class="border_left range_sign"><</td>
|
||||
{foreach from=$ranges key=r item=range}
|
||||
<td class="range_data">
|
||||
<div class="input-group fixed-width-md">
|
||||
<span class="input-group-addon weight_unit">{$PS_WEIGHT_UNIT}</span>
|
||||
<span class="input-group-addon price_unit">{$currency_sign}</span>
|
||||
<input class="form-control" name="range_sup[{$range.id_range|intval}]" type="text" {if isset($form_id) && !$form_id} value="" {else} value="{if isset($change_ranges) && $range.id_range == 0} {else}{$range.delimiter2|string_format:"%.6f"}{/if}" {/if} autocomplete="off"/>
|
||||
</div>
|
||||
</td>
|
||||
{foreachelse}
|
||||
<td class="range_data_new">
|
||||
<div class="input-group fixed-width-md">
|
||||
<span class="input-group-addon weight_unit">{$PS_WEIGHT_UNIT}</span>
|
||||
<span class="input-group-addon price_unit">{$currency_sign}</span>
|
||||
<input class="form-control" name="range_sup[{$range.id_range|intval}]" type="text" autocomplete="off" />
|
||||
</div>
|
||||
</td>
|
||||
{/foreach}
|
||||
</tr>
|
||||
<tr class="fees_all">
|
||||
<td class="border_top border_bottom border_bold">
|
||||
<span class="fees_all" {if $ranges|count == 0}style="display:none" {/if}>All</span>
|
||||
</td>
|
||||
<td style="">
|
||||
<input type="checkbox" onclick="checkAllZones(this);" class="form-control">
|
||||
</td>
|
||||
{foreach from=$ranges key=r item=range}
|
||||
<td class="border_top border_bottom {if $range.id_range != 0} validated {/if}" >
|
||||
<div class="input-group fixed-width-md">
|
||||
<span class="input-group-addon currency_sign" {if $range.id_range == 0} style="display:none" {/if}>{$currency_sign}</span>
|
||||
<input class="form-control" type="text" {if isset($form_id) && !$form_id} disabled="disabled"{/if} {if $range.id_range == 0} style="display:none"{/if} autocomplete="off" />
|
||||
</div>
|
||||
</td>
|
||||
{foreachelse}
|
||||
<td class="border_top border_bottom">
|
||||
<div class="input-group fixed-width-md">
|
||||
<span class="input-group-addon currency_sign" style="display:none">{$currency_sign}</span>
|
||||
<input class="form-control" style="display:none" type="text" autocomplete="off" />
|
||||
</div>
|
||||
</td>
|
||||
{/foreach}
|
||||
</tr>
|
||||
{foreach from=$zones key=i item=zone}
|
||||
<tr class="fees" data-zoneid="{$zone.id_zone}">
|
||||
<td>
|
||||
<label for="zone_{$zone.id_zone}">{$zone.name}{if !$zone.active} <small>({l s='inactive' d='Admin.Shipping.Feature'})</small>{/if}</label>
|
||||
</td>
|
||||
<td class="zone">
|
||||
<input class="form-control input_zone" id="zone_{$zone.id_zone}" name="zone_{$zone.id_zone}" value="1" type="checkbox" {if isset($fields_value['zones'][$zone.id_zone]) && $fields_value['zones'][$zone.id_zone]} checked="checked"{/if}/>
|
||||
</td>
|
||||
{foreach from=$ranges key=r item=range}
|
||||
<td>
|
||||
<div class="input-group fixed-width-md">
|
||||
<span class="input-group-addon">{$currency_sign}</span>
|
||||
<input class="form-control" name="fees[{$zone.id_zone|intval}][{$range.id_range|intval}]" type="text"
|
||||
{if !isset($fields_value['zones'][$zone.id_zone]) || (isset($fields_value['zones'][$zone.id_zone]) && !$fields_value['zones'][$zone.id_zone])} disabled="disabled"{/if}
|
||||
|
||||
{if isset($price_by_range[$range.id_range][$zone.id_zone]) && $price_by_range[$range.id_range][$zone.id_zone] && isset($fields_value['zones'][$zone.id_zone]) && $fields_value['zones'][$zone.id_zone]} value="{$price_by_range[$range.id_range][$zone.id_zone]|string_format:'%.6f'}" {else} value="" {/if} />
|
||||
</div>
|
||||
</td>
|
||||
{/foreach}
|
||||
</tr>
|
||||
{/foreach}
|
||||
<tr class="delete_range">
|
||||
<td> </td>
|
||||
<td> </td>
|
||||
{foreach from=$ranges name=ranges key=r item=range}
|
||||
{if $smarty.foreach.ranges.first}
|
||||
<td> </td>
|
||||
{else}
|
||||
<td>
|
||||
<button class="btn btn-default">{l s='Delete' d='Admin.Actions'}</button>
|
||||
</td>
|
||||
{/if}
|
||||
{/foreach}
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,77 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/view/view.tpl"}
|
||||
{block name="override_tpl"}
|
||||
<script>
|
||||
var labelNext = '{$labels.next|addslashes}';
|
||||
var labelPrevious = '{$labels.previous|addslashes}';
|
||||
var labelFinish = '{$labels.finish|addslashes}';
|
||||
var labelDelete = '{l s='Delete' d='Admin.Actions' js=1}';
|
||||
var labelValidate = '{l s='Validate' js=1 d='Admin.Actions'}';
|
||||
var validate_url = '{$validate_url|addslashes}';
|
||||
var carrierlist_url = '{$carrierlist_url|addslashes}';
|
||||
var nbr_steps = {$wizard_steps.steps|count};
|
||||
var enableAllSteps = {if $enableAllSteps|intval == 1}true{else}false{/if};
|
||||
var need_to_validate = '{l s='Please validate the last range before creating a new one.' js=1 d='Admin.Shipping.Notification'}';
|
||||
var delete_range_confirm = '{l s='Are you sure to delete this range ?' js=1 d='Admin.Shipping.Notification'}';
|
||||
var currency_sign = '{$currency_sign}';
|
||||
var PS_WEIGHT_UNIT = '{$PS_WEIGHT_UNIT}';
|
||||
var invalid_range = '{l s='This range is not valid' js=1 d='Admin.Shipping.Notification'}';
|
||||
var overlapping_range = '{l s='Ranges are overlapping' js=1 d='Admin.Shipping.Notification'}';
|
||||
var range_is_overlapping = '{l s='Ranges are overlapping' js=1 d='Admin.Shipping.Notification'}';
|
||||
var select_at_least_one_zone = '{l s='Please select at least one zone' js=1 d='Admin.Shipping.Notification'}';
|
||||
var multistore_enable = '{$multistore_enable}';
|
||||
</script>
|
||||
|
||||
<div class="row">
|
||||
<div class="col-sm-2">
|
||||
{$logo_content}
|
||||
</div>
|
||||
<div class="col-sm-10">
|
||||
<div id="carrier_wizard" class="panel swMain">
|
||||
<ul class="steps nbr_steps_{$wizard_steps.steps|count}">
|
||||
{foreach from=$wizard_steps.steps key=step_nbr item=step}
|
||||
<li>
|
||||
<a href="#step-{$step_nbr + 1}">
|
||||
<span class="stepNumber">{$step_nbr + 1}</span>
|
||||
<span class="stepDesc">
|
||||
{$step.title}<br />
|
||||
{if isset($step.desc)}<small>{$step.desc}</small>{/if}
|
||||
</span>
|
||||
<span class="chevron"></span>
|
||||
</a>
|
||||
</li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
{foreach from=$wizard_contents.contents key=step_nbr item=content}
|
||||
<div id="step-{$step_nbr + 1}" class="step_container">
|
||||
{$content}
|
||||
</div>
|
||||
{/foreach}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
|
||||
header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT");
|
||||
|
||||
header("Cache-Control: no-store, no-cache, must-revalidate");
|
||||
header("Cache-Control: post-check=0, pre-check=0", false);
|
||||
header("Pragma: no-cache");
|
||||
|
||||
header("Location: ../");
|
||||
exit;
|
||||
@@ -0,0 +1,71 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
<div id="carrier_logo_block" class="panel">
|
||||
<div class="panel-heading">
|
||||
{l s='Logo' d='Admin.Global'}
|
||||
<div class="panel-heading-action">
|
||||
<a id="carrier_logo_remove" class="btn btn-default" {if !$carrier_logo}style="display:none"{/if} href="javascript:removeCarrierLogo();">
|
||||
<i class="icon-trash"></i>
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<img id="carrier_logo_img" src="{if $carrier_logo}{$carrier_logo}{else}../img/admin/carrier-default.jpg{/if}" class="img-thumbnail" alt=""/>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
var carrier_translation_undefined = '{l s='undefined' js=1 d='Admin.Shipping.Help'}';
|
||||
|
||||
function removeCarrierLogo()
|
||||
{
|
||||
if (confirm('{l s='Are you sure you want to delete the logo?' js=1 d='Admin.Shipping.Notification'}'))
|
||||
{
|
||||
$('#carrier_logo_img').attr('src', '../img/admin/carrier-default.jpg');
|
||||
$('#logo').val('null');
|
||||
$('#carrier_logo_remove').hide();
|
||||
}
|
||||
}
|
||||
|
||||
function uploadCarrierLogo() {
|
||||
$.ajaxFileUpload({
|
||||
url: 'ajax-tab.php?tab=AdminCarrierWizard&token={$token|addslashes}&action=uploadLogo',
|
||||
secureuri: false,
|
||||
fileElementId: 'carrier_logo_input',
|
||||
dataType: 'xml',
|
||||
success: function (data, status) {
|
||||
data = data.getElementsByTagName('return')[0];
|
||||
var message = data.getAttribute("message");
|
||||
if (data.getAttribute("result") == "success")
|
||||
{
|
||||
$('#carrier_logo_img').attr('src', message);
|
||||
$('#logo').val(message);
|
||||
$('#carrier_logo_remove').show();
|
||||
}
|
||||
else
|
||||
alert(message);
|
||||
}
|
||||
});
|
||||
}
|
||||
</script>
|
||||
@@ -0,0 +1,62 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
<script type="text/javascript">
|
||||
var summary_translation_undefined = '{l s='[undefined]' js=1}';
|
||||
var summary_translation_meta_informations = '{l s='This carrier is %1$s and the transit time is %2$s.' js=1 d='Admin.Shipping.Feature'}';
|
||||
var summary_translation_free = '{l s='free' js=1 d='Admin.Shipping.Feature'}';
|
||||
var summary_translation_paid = '{l s='not free' js=1 d='Admin.Shipping.Feature'}';
|
||||
var summary_translation_range = '{l s='This carrier can deliver orders from %1$s to %2$s.' js=1 d='Admin.Shipping.Feature'}';
|
||||
var summary_translation_range_limit = '{l s='If the order is out of range, the behavior is to %3$s.' js=1 d='Admin.Shipping.Feature'}';
|
||||
var summary_translation_shipping_cost = '{l s='The shipping cost is calculated %1$s and the tax rule %2$s will be applied.' js=1 d='Admin.Shipping.Feature'}';
|
||||
var summary_translation_price = '{l s='according to the price' js=1 d='Admin.Shipping.Feature'}';
|
||||
var summary_translation_weight = '{l s='according to the weight' js=1 d='Admin.Shipping.Feature'}';
|
||||
</script>
|
||||
|
||||
<div class="defaultForm">
|
||||
<div class="panel">
|
||||
<div class="panel-heading">{l s='Carrier name:' d='Admin.Shipping.Feature'} <strong id="summary_name"></strong></div>
|
||||
<div class="panel-body">
|
||||
<p id="summary_meta_informations"></p>
|
||||
<p id="summary_shipping_cost"></p>
|
||||
<p id="summary_range"></p>
|
||||
<div>
|
||||
{l s='This carrier will be proposed for those delivery zones:' d='Admin.Shipping.Feature'}
|
||||
<ul id="summary_zones"></ul>
|
||||
</div>
|
||||
<div>
|
||||
{l s='And it will be proposed for those client groups:' d='Admin.Shipping.Feature'}
|
||||
<ul id="summary_groups"></ul>
|
||||
</div>
|
||||
{if $is_multishop}
|
||||
<div>
|
||||
{l s='Finally, this carrier will be proposed in those shops:' d='Admin.Shipping.Feature'}
|
||||
<ul id="summary_shops"></ul>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
{$active_form}
|
||||
</div>
|
||||
@@ -0,0 +1,48 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
{extends file="helpers/form/form.tpl"}
|
||||
|
||||
{block name=script}
|
||||
// At the loading
|
||||
($("input[name='is_free']:checked").val() == 0) ? $('#shipping_costs_div').show('toggle'): $('#shipping_costs_div').hide();
|
||||
|
||||
$(document).on('change', "input[name='is_free']", function() {ldelim}
|
||||
($("input[name='is_free']:checked").val() == 0) ? $('#shipping_costs_div').show('toggle'): $('#shipping_costs_div').hide();
|
||||
{rdelim});
|
||||
{/block}
|
||||
|
||||
{block name="label"}
|
||||
{if $input.type == 'select' && $input.name == 'id_tax_rules_group'}
|
||||
<div id="shipping_costs_div" style="display:{if isset($fields_value.is_free) && $fields_value.is_free}none{else}block{/if}">
|
||||
{/if}
|
||||
{$smarty.block.parent}
|
||||
{/block}
|
||||
|
||||
{block name="field"}
|
||||
{$smarty.block.parent}
|
||||
{if $input.type == 'select' && $input.name == 'range_behavior'}
|
||||
</div>
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
|
||||
header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT");
|
||||
|
||||
header("Cache-Control: no-store, no-cache, must-revalidate");
|
||||
header("Cache-Control: post-check=0, pre-check=0", false);
|
||||
header("Pragma: no-cache");
|
||||
|
||||
header("Location: ../");
|
||||
exit;
|
||||
@@ -0,0 +1,41 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/list/list_content.tpl"}
|
||||
{block name="open_td"}
|
||||
<td
|
||||
{if isset($params.position)}
|
||||
id="td_{if !empty($id_category)}{$id_category}{else}0{/if}_{$tr.$identifier}"
|
||||
{/if}
|
||||
class="{if !$no_link}pointer{/if}
|
||||
{if isset($params.position) && $order_by == 'position' && $order_way != 'DESC'} dragHandle{/if}
|
||||
{if isset($params.align)} {$params.align}{/if}"
|
||||
{if (!isset($params.position) && !$no_link && !isset($params.remove_onclick))}
|
||||
{assign var="identifier_field" value=$identifier|escape:'html':'UTF-8'}
|
||||
onclick="document.location = '{$link->getAdminLink('AdminCarrierWizard', true, [], [$identifier_field => $tr.$identifier|escape:'html':'UTF-8'])|escape:'html':'UTF-8'}'">
|
||||
{else}
|
||||
>
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,37 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/list/list_footer.tpl"}
|
||||
{block name="after"}
|
||||
{if is_null($modules_list)}
|
||||
<div class="panel">
|
||||
<h3>{l s="Use one of our recommended carrier modules" d='Admin.Shipping.Feature'}</h3>
|
||||
<p>{l s="It seems there are no recommended carriers for your country." d='Admin.Shipping.Feature'}</p>
|
||||
<p><a href="https://www.prestashop.com/en/contact-us">{l s="Do you think there should be one? Let us know!" d='Admin.Shipping.Feature'}</a></p>
|
||||
</div>
|
||||
{else}
|
||||
{$modules_list}
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,36 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/list/list_header.tpl"}
|
||||
{block name="preTable"}
|
||||
{if $showHeaderAlert}
|
||||
<div class="alert alert-info">
|
||||
<p>{l s='Your online store needs to have a proper carrier registered in PrestaShop as soon as you start shipping your products. This means sending yours parcels using your local postal service, or having a contract with a private carrier which in turn will ship your parcels to your customers. In order to have PrestaShop suggest the most adequate carrier to your customers during their order checkout process, you need to register all the carriers with which you have chosen to work.' d='Admin.Shipping.Help'}</p>
|
||||
<p>{l s='PrestaShop comes with a number of carrier modules that you can activate. You can also buy carrier modules on the PrestaShop Addons marketplace. Recommended modules are listed below: install the module that matches your carrier, and configure it!' d='Admin.Shipping.Help'}</p>
|
||||
<p>{l s='If there is no existing module for your carrier, then you can register that carrier by hand using the information that it can provide you: shipping rates, regional zones, size and weight limits, etc. Click on the "%add_new_label%" button below to open the Carrier Wizard, which will help you register a new carrier in a few steps.' d='Admin.Shipping.Help' sprintf=['%add_new_label%' => {l s='Add new carrier' d='Admin.Shipping.Feature'}]}</p>
|
||||
<p>{l s='Note: DO NOT register a new carrier if there already exists a module for it! Using a module will be much faster and more accurate!' d='Admin.Shipping.Help'}</p>
|
||||
</div>
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,207 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Free shipping' d='Admin.Shipping.Feature'}</label>
|
||||
<div class="col-lg-9">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="free_shipping" id="free_shipping_on" value="1" {if $currentTab->getFieldValue($currentObject, 'free_shipping')|intval}checked="checked"{/if} />
|
||||
<label class="t" for="free_shipping_on">
|
||||
{l s='Yes' d='Admin.Global'}
|
||||
</label>
|
||||
<input type="radio" name="free_shipping" id="free_shipping_off" value="0" {if !$currentTab->getFieldValue($currentObject, 'free_shipping')|intval}checked="checked"{/if} />
|
||||
<label class="t" for="free_shipping_off">
|
||||
{l s='No' d='Admin.Global'}
|
||||
</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Apply a discount' d='Admin.Catalog.Feature'}</label>
|
||||
<div class="col-lg-9">
|
||||
<div class="radio">
|
||||
<label for="apply_discount_percent">
|
||||
<input type="radio" name="apply_discount" id="apply_discount_percent" value="percent" {if $currentTab->getFieldValue($currentObject, 'reduction_percent')|floatval > 0}checked="checked"{/if} />
|
||||
{l s='Percent (%)' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</div>
|
||||
<div class="radio">
|
||||
<label for="apply_discount_amount">
|
||||
<input type="radio" name="apply_discount" id="apply_discount_amount" value="amount" {if $currentTab->getFieldValue($currentObject, 'reduction_amount')|floatval > 0}checked="checked"{/if} />
|
||||
{l s='Amount' d='Admin.Global'}
|
||||
</label>
|
||||
</div>
|
||||
<div class="radio">
|
||||
<label for="apply_discount_off">
|
||||
<input type="radio" name="apply_discount" id="apply_discount_off" value="off" {if !$currentTab->getFieldValue($currentObject, 'reduction_amount')|floatval > 0 && !$currentTab->getFieldValue($currentObject, 'reduction_percent')|floatval > 0}checked="checked"{/if} />
|
||||
<i class="icon-remove color_danger"></i> {l s='None' d='Admin.Global'}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="apply_discount_percent_div" class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Value' d='Admin.Global'}</label>
|
||||
<div class="col-lg-9">
|
||||
<div class="input-group col-lg-2">
|
||||
<span class="input-group-addon">%</span>
|
||||
<input type="text" id="reduction_percent" class="input-mini" name="reduction_percent" value="{$currentTab->getFieldValue($currentObject, 'reduction_percent')|floatval}" />
|
||||
</div>
|
||||
<span class="help-block"><i class="icon-warning-sign"></i> {l s='Does not apply to the shipping costs' d='Admin.Catalog.Help'}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="apply_discount_amount_div" class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Amount' d='Admin.Global'}</label>
|
||||
<div class="col-lg-7">
|
||||
<div class="row">
|
||||
<div class="col-lg-4">
|
||||
<input type="text" id="reduction_amount" name="reduction_amount" value="{$currentTab->getFieldValue($currentObject, 'reduction_amount')|floatval}" onchange="this.value = this.value.replace(/,/g, '.');" />
|
||||
</div>
|
||||
<div class="col-lg-4">
|
||||
<select name="reduction_currency" >
|
||||
{foreach from=$currencies item='currency'}
|
||||
<option value="{$currency.id_currency|intval}" {if $currentTab->getFieldValue($currentObject, 'reduction_currency') == $currency.id_currency || (!$currentTab->getFieldValue($currentObject, 'reduction_currency') && $currency.id_currency == $defaultCurrency)}selected="selected"{/if}>{$currency.iso_code}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-lg-4">
|
||||
<select name="reduction_tax" >
|
||||
<option value="0" {if $currentTab->getFieldValue($currentObject, 'reduction_tax') == 0}selected="selected"{/if}>{l s='Tax excluded' d='Admin.Global'}</option>
|
||||
<option value="1" {if $currentTab->getFieldValue($currentObject, 'reduction_tax') == 1}selected="selected"{/if}>{l s='Tax included' d='Admin.Global'}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="apply_discount_to_div" class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Apply a discount to' d='Admin.Catalog.Feature'}</label>
|
||||
<div class="col-lg-7">
|
||||
<p class="radio">
|
||||
<label for="apply_discount_to_order">
|
||||
<input type="radio" name="apply_discount_to" id="apply_discount_to_order" value="order"{if $currentTab->getFieldValue($currentObject, 'reduction_product')|intval == 0} checked="checked"{/if} />
|
||||
{l s='Order (without shipping)' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</p>
|
||||
<p class="radio">
|
||||
<label for="apply_discount_to_product">
|
||||
<input type="radio" name="apply_discount_to" id="apply_discount_to_product" value="specific"{if $currentTab->getFieldValue($currentObject, 'reduction_product')|intval > 0} checked="checked"{/if} />
|
||||
{l s='Specific product' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</p>
|
||||
<p class="radio">
|
||||
<label for="apply_discount_to_cheapest">
|
||||
<input type="radio" name="apply_discount_to" id="apply_discount_to_cheapest" value="cheapest"{if $currentTab->getFieldValue($currentObject, 'reduction_product')|intval == -1} checked="checked"{/if} />
|
||||
{l s='Cheapest product' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</p>
|
||||
<p class="radio">
|
||||
<label for="apply_discount_to_selection">
|
||||
<input type="radio" name="apply_discount_to" id="apply_discount_to_selection" value="selection"{if $currentTab->getFieldValue($currentObject, 'reduction_product')|intval == -2} checked="checked"{/if}{if $product_rule_groups|@count == 0}disabled="disabled"{/if} />
|
||||
{l s='Selected product(s)' d='Admin.Catalog.Feature'}{if $product_rule_groups|@count == 0} <span id="apply_discount_to_selection_warning" class="text-muted clearfix"><i class="icon-warning-sign"></i> <a href="#" id="apply_discount_to_selection_shortcut">{l s='You must select some products before' d='Admin.Catalog.Notification'}</a></span>{/if}
|
||||
</label>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="apply_discount_to_product_div" class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Product' d='Admin.Global'}</label>
|
||||
<div class="col-lg-9">
|
||||
<div class="input-group col-lg-5">
|
||||
<input type="text" id="reductionProductFilter" name="reductionProductFilter" value="{$reductionProductFilter|escape:'html':'UTF-8'}" />
|
||||
<input type="hidden" id="reduction_product" name="reduction_product" value="{$currentTab->getFieldValue($currentObject, 'reduction_product')|intval}" />
|
||||
<span class="input-group-addon"><i class="icon-search"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="apply_discount_to_product_special" class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='If enabled, the voucher will not apply to products already on sale.'}">
|
||||
{l s='Exclude discounted products' d='Admin.Catalog.Feature'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="reduction_exclude_special" id="reduction_exclude_special_on" value="1"{if $currentTab->getFieldValue($currentObject, 'reduction_exclude_special')|intval} checked="checked"{/if}/>
|
||||
<label class="t" for="reduction_exclude_special_on">
|
||||
{l s='Yes' d='Admin.Global'}
|
||||
</label>
|
||||
<input type="radio" name="reduction_exclude_special" id="reduction_exclude_special_off" value="0"{if !$currentTab->getFieldValue($currentObject, 'reduction_exclude_special')|intval} checked="checked"{/if}/>
|
||||
<label class="t" for="reduction_exclude_special_off">
|
||||
{l s='No' d='Admin.Global'}
|
||||
</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Send a free gift' d='Admin.Catalog.Feature'}</label>
|
||||
<div class="col-lg-9">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="free_gift" id="free_gift_on" value="1" {if $currentTab->getFieldValue($currentObject, 'gift_product')|intval}checked="checked"{/if} />
|
||||
<label class="t" for="free_gift_on">
|
||||
{l s='Yes' d='Admin.Global'}
|
||||
</label>
|
||||
<input type="radio" name="free_gift" id="free_gift_off" value="0" {if !$currentTab->getFieldValue($currentObject, 'gift_product')|intval}checked="checked"{/if} />
|
||||
<label class="t" for="free_gift_off">
|
||||
{l s='No' d='Admin.Global'}
|
||||
</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="free_gift_div" class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Search a product' d='Admin.Catalog.Feature'}</label>
|
||||
<div class="col-lg-9">
|
||||
<div class="input-group col-lg-5">
|
||||
<input type="text" id="giftProductFilter" value="{$giftProductFilter}" />
|
||||
<span class="input-group-addon"><i class="icon-search"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="gift_products_found" {if $gift_product_select == ''}style="display:none"{/if}>
|
||||
<div id="gift_product_list" class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Matching products' d='Admin.Catalog.Feature'}</label>
|
||||
<div class="col-lg-5">
|
||||
<select name="gift_product" id="gift_product" onclick="displayProductAttributes();" class="control-form">
|
||||
{$gift_product_select}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div id="gift_attributes_list" class="form-group" {if !$hasAttribute}style="display:none"{/if}>
|
||||
<label class="control-label col-lg-3">{l s='Available combinations' d='Admin.Catalog.Feature'}</label>
|
||||
<div class="col-lg-5" id="gift_attributes_list_select">
|
||||
{$gift_product_attribute_select}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="gift_products_err" class="alert alert-warning" style="display:none"></div>
|
||||
@@ -0,0 +1,331 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='Optional: The cart rule will be available to everyone if you leave this field blank.' d='Admin.Catalog.Help'}">
|
||||
{l s='Limit to a single customer' d='Admin.Catalog.Feature'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<div class="input-group col-lg-12">
|
||||
<span class="input-group-addon"><i class="icon-user"></i></span>
|
||||
<input type="hidden" id="id_customer" name="id_customer" value="{$currentTab->getFieldValue($currentObject, 'id_customer')|intval}" />
|
||||
<input type="text" id="customerFilter" class="input-xlarge" name="customerFilter" value="{if $customerFilter}{$customerFilter|escape:'html':'UTF-8'}{elseif isset($smarty.post.customerFilter)}{$smarty.post.customerFilter|escape}{/if}" />
|
||||
<span class="input-group-addon"><i class="icon-search"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='The default period is one month.' d='Admin.Catalog.Help'}">
|
||||
{l s='Valid' d='Admin.Catalog.Feature'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<div class="row">
|
||||
<div class="col-lg-6">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon">{l s='From' d='Admin.Global'}</span>
|
||||
<input type="text" class="datepicker input-medium" name="date_from"
|
||||
value="{if $currentTab->getFieldValue($currentObject, 'date_from')}{$currentTab->getFieldValue($currentObject, 'date_from')|escape}{else}{$defaultDateFrom}{/if}" />
|
||||
<span class="input-group-addon"><i class="icon-calendar-empty"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon">{l s='To' d='Admin.Global'}</span>
|
||||
<input type="text" class="datepicker input-medium" name="date_to"
|
||||
value="{if $currentTab->getFieldValue($currentObject, 'date_to')}{$currentTab->getFieldValue($currentObject, 'date_to')|escape}{else}{$defaultDateTo}{/if}" />
|
||||
<span class="input-group-addon"><i class="icon-calendar-empty"></i></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='You can choose a minimum amount for the cart either with or without the taxes and shipping.' d='Admin.Catalog.Help'}">
|
||||
{l s='Minimum amount' d='Admin.Catalog.Feature'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<div class="row">
|
||||
<div class="col-lg-3">
|
||||
<input type="text" name="minimum_amount" value="{$currentTab->getFieldValue($currentObject, 'minimum_amount')|floatval}" />
|
||||
</div>
|
||||
<div class="col-lg-2">
|
||||
<select name="minimum_amount_currency">
|
||||
{foreach from=$currencies item='currency'}
|
||||
<option value="{$currency.id_currency|intval}"
|
||||
{if $currentTab->getFieldValue($currentObject, 'minimum_amount_currency') == $currency.id_currency
|
||||
|| (!$currentTab->getFieldValue($currentObject, 'minimum_amount_currency') && $currency.id_currency == $defaultCurrency)}
|
||||
selected="selected"
|
||||
{/if}
|
||||
>
|
||||
{$currency.iso_code}
|
||||
</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-lg-3">
|
||||
<select name="minimum_amount_tax">
|
||||
<option value="0" {if $currentTab->getFieldValue($currentObject, 'minimum_amount_tax') == 0}selected="selected"{/if}>{l s='Tax excluded' d='Admin.Global'}</option>
|
||||
<option value="1" {if $currentTab->getFieldValue($currentObject, 'minimum_amount_tax') == 1}selected="selected"{/if}>{l s='Tax included' d='Admin.Global'}</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-lg-4">
|
||||
<select name="minimum_amount_shipping">
|
||||
<option value="0" {if $currentTab->getFieldValue($currentObject, 'minimum_amount_shipping') == 0}selected="selected"{/if}>{l s='Shipping excluded' d='Admin.Catalog.Feature'}</option>
|
||||
<option value="1" {if $currentTab->getFieldValue($currentObject, 'minimum_amount_shipping') == 1}selected="selected"{/if}>{l s='Shipping included' d='Admin.Catalog.Feature'}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='The cart rule will be applied to the first "X" customers only.' d='Admin.Catalog.Help'}">
|
||||
{l s='Total available' d='Admin.Catalog.Feature'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<input class="form-control" type="text" name="quantity" value="{$currentTab->getFieldValue($currentObject, 'quantity')|intval}" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='A customer will only be able to use the cart rule "X" time(s).' d='Admin.Catalog.Help'}">
|
||||
{l s='Total available for each user' d='Admin.Catalog.Feature'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<input class="form-control" type="text" name="quantity_per_user" value="{$currentTab->getFieldValue($currentObject, 'quantity_per_user')|intval}" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
{l s='Restrictions' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
{if ($countries.unselected|@count) + ($countries.selected|@count) > 1}
|
||||
<p class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" id="country_restriction" name="country_restriction" value="1" {if $countries.unselected|@count}checked="checked"{/if} />
|
||||
{l s='Country selection' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</p>
|
||||
<span class="help-block">{l s='This restriction applies to the country of delivery.' d='Admin.Catalog.Help'}</span>
|
||||
<div id="country_restriction_div">
|
||||
<br />
|
||||
<table class="table">
|
||||
<tr>
|
||||
<td>
|
||||
<p>{l s='Unselected countries' d='Admin.Catalog.Feature'}</p>
|
||||
<select id="country_select_1" multiple>
|
||||
{foreach from=$countries.unselected item='country'}
|
||||
<option value="{$country.id_country|intval}"> {$country.name|escape}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<a id="country_select_add" class="btn btn-default btn-block clearfix">{l s='Add' d='Admin.Actions'} <i class="icon-arrow-right"></i></a>
|
||||
</td>
|
||||
<td>
|
||||
<p>{l s='Selected countries' d='Admin.Catalog.Feature'}</p>
|
||||
<select name="country_select[]" id="country_select_2" class="input-large" multiple>
|
||||
{foreach from=$countries.selected item='country'}
|
||||
<option value="{$country.id_country|intval}"> {$country.name|escape}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<a id="country_select_remove" class="btn btn-default btn-block clearfix"><i class="icon-arrow-left"></i> {l s='Remove' d='Admin.Actions'} </a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
{if ($carriers.unselected|@count) + ($carriers.selected|@count) > 1}
|
||||
<p class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" id="carrier_restriction" name="carrier_restriction" value="1" {if $carriers.unselected|@count}checked="checked"{/if} />
|
||||
{l s='Carrier selection' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</p>
|
||||
<div id="carrier_restriction_div">
|
||||
<br />
|
||||
<table class="table">
|
||||
<tr>
|
||||
<td>
|
||||
<p>{l s='Unselected carriers' d='Admin.Catalog.Feature'}</p>
|
||||
<select id="carrier_select_1" class="input-large" multiple>
|
||||
{foreach from=$carriers.unselected item='carrier'}
|
||||
<option value="{$carrier.id_reference|intval}"> {$carrier.name|escape}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<a id="carrier_select_add" class="btn btn-default btn-block clearfix" >{l s='Add' d='Admin.Actions'} <i class="icon-arrow-right"></i></a>
|
||||
</td>
|
||||
<td>
|
||||
<p>{l s='Selected carriers' d='Admin.Catalog.Feature'}</p>
|
||||
<select name="carrier_select[]" id="carrier_select_2" class="input-large" multiple>
|
||||
{foreach from=$carriers.selected item='carrier'}
|
||||
<option value="{$carrier.id_reference|intval}"> {$carrier.name|escape}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<a id="carrier_select_remove" class="btn btn-default btn-block clearfix"><i class="icon-arrow-left"></i> {l s='Remove' d='Admin.Actions'} </a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
{if ($groups.unselected|@count) + ($groups.selected|@count) > 1}
|
||||
<p class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" id="group_restriction" name="group_restriction" value="1" {if $groups.unselected|@count}checked="checked"{/if} />
|
||||
{l s='Customer group selection' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</p>
|
||||
<div id="group_restriction_div">
|
||||
<br />
|
||||
<table class="table">
|
||||
<tr>
|
||||
<td>
|
||||
<p>{l s='Unselected groups' d='Admin.Catalog.Feature'}</p>
|
||||
<select id="group_select_1" class="input-large" multiple>
|
||||
{foreach from=$groups.unselected item='group'}
|
||||
<option value="{$group.id_group|intval}"> {$group.name|escape}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<a id="group_select_add" class="btn btn-default btn-block clearfix" >{l s='Add' d='Admin.Actions'} <i class="icon-arrow-right"></i></a>
|
||||
</td>
|
||||
<td>
|
||||
<p>{l s='Selected groups' d='Admin.Catalog.Feature'}</p>
|
||||
<select name="group_select[]" class="input-large" id="group_select_2" multiple>
|
||||
{foreach from=$groups.selected item='group'}
|
||||
<option value="{$group.id_group|intval}"> {$group.name|escape}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<a id="group_select_remove" class="btn btn-default btn-block clearfix" ><i class="icon-arrow-left"></i> {l s='Remove' d='Admin.Actions'}</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
{if ($cart_rules.unselected|@count) + ($cart_rules.selected|@count) > 0}
|
||||
<p class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" id="cart_rule_restriction" name="cart_rule_restriction" value="1" {if $cart_rules.unselected|@count}checked="checked"{/if} />
|
||||
{l s='Compatibility with other cart rules' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</p>
|
||||
<div id="cart_rule_restriction_div">
|
||||
<br />
|
||||
<table class="table">
|
||||
<tr>
|
||||
<td>
|
||||
<p>{l s='Uncombinable cart rules' d='Admin.Catalog.Feature'}</p>
|
||||
<input id="cart_rule_select_1_filter" autocomplete="off" class="form-control uncombinable_search_filter" type="text" name="uncombinable_filter" placeholder="{l s='Search' d='Admin.Actions'}" value="">
|
||||
<select id="cart_rule_select_1" class="jscroll" multiple="">
|
||||
</select>
|
||||
<a class="jscroll-next btn btn-default btn-block clearfix" href="">{l s='Next' d='Admin.Global'}</a>
|
||||
<a id="cart_rule_select_add" class="btn btn-default btn-block clearfix">{l s='Add' d='Admin.Actions'} <i class="icon-arrow-right"></i></a>
|
||||
</td>
|
||||
<td>
|
||||
<p>{l s='Combinable cart rules' d='Admin.Catalog.Feature'}</p>
|
||||
<input id="cart_rule_select_2_filter" autocomplete="off" class="form-control combinable_search_filter" type="text" name="combinable_filter" placeholder="{l s='Search' d='Admin.Actions'}" value="">
|
||||
<select name="cart_rule_select[]" class="jscroll" id="cart_rule_select_2" multiple>
|
||||
</select>
|
||||
<a class="jscroll-next btn btn-default btn-block clearfix" href="">{l s='Next' d='Admin.Global'}</a>
|
||||
<a id="cart_rule_select_remove" class="btn btn-default btn-block clearfix" ><i class="icon-arrow-left"></i> {l s='Remove' d='Admin.Actions'}</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
<p class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" id="product_restriction" name="product_restriction" value="1" {if $product_rule_groups|@count}checked="checked"{/if} />
|
||||
{l s='Product selection' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</p>
|
||||
<div id="product_restriction_div">
|
||||
<br />
|
||||
<table id="product_rule_group_table" class="table">
|
||||
{foreach from=$product_rule_groups item='product_rule_group'}
|
||||
{$product_rule_group}
|
||||
{/foreach}
|
||||
</table>
|
||||
<a href="javascript:addProductRuleGroup();" class="btn btn-default ">
|
||||
<i class="icon-plus-sign"></i> {l s='Product selection' d='Admin.Catalog.Feature'}
|
||||
</a>
|
||||
</div>
|
||||
|
||||
{if ($shops.unselected|@count) + ($shops.selected|@count) > 1}
|
||||
<p class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" id="shop_restriction" name="shop_restriction" value="1" {if $shops.unselected|@count}checked="checked"{/if} />
|
||||
{l s='Shop selection' d='Admin.Catalog.Feature'}
|
||||
</label>
|
||||
</p>
|
||||
<div id="shop_restriction_div">
|
||||
<br/>
|
||||
<table class="table">
|
||||
<tr>
|
||||
<td>
|
||||
<p>{l s='Unselected shops' d='Admin.Catalog.Feature'}</p>
|
||||
<select id="shop_select_1" multiple>
|
||||
{foreach from=$shops.unselected item='shop'}
|
||||
<option value="{$shop.id_shop|intval}"> {$shop.name|escape}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<a id="shop_select_add" class="btn btn-default btn-block clearfix" >{l s='Add' d='Admin.Actions'} <i class="icon-arrow-right"></i></a>
|
||||
</td>
|
||||
<td>
|
||||
<p>{l s='Selected shops' d='Admin.Catalog.Feature'}</p>
|
||||
<select name="shop_select[]" id="shop_select_2" multiple>
|
||||
{foreach from=$shops.selected item='shop'}
|
||||
<option value="{$shop.id_shop|intval}"> {$shop.name|escape}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<a id="shop_select_remove" class="btn btn-default btn-block clearfix" ><i class="icon-arrow-left"></i> {l s='Remove' d='Admin.Actions'}</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,468 @@
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
function addProductRuleGroup() {
|
||||
$('#product_rule_group_table').show();
|
||||
product_rule_groups_counter += 1;
|
||||
product_rule_counters[product_rule_groups_counter] = 0;
|
||||
|
||||
$.get(
|
||||
'ajax-tab.php',
|
||||
{
|
||||
controller: 'AdminCartRules', token: currentToken, newProductRuleGroup: 1, product_rule_group_id: product_rule_groups_counter,
|
||||
},
|
||||
(content) => {
|
||||
if (content != '') $('#product_rule_group_table').append(content);
|
||||
},
|
||||
);
|
||||
}
|
||||
|
||||
function removeProductRuleGroup(id) {
|
||||
$(`#product_rule_group_${id}_tr`).remove();
|
||||
}
|
||||
|
||||
function addProductRule(product_rule_group_id) {
|
||||
product_rule_counters[product_rule_group_id] += 1;
|
||||
if ($(`#product_rule_type_${product_rule_group_id}`).val() != 0) {
|
||||
$.get(
|
||||
'ajax-tab.php',
|
||||
{
|
||||
controller: 'AdminCartRules', token: currentToken, newProductRule: 1, product_rule_type: $(`#product_rule_type_${product_rule_group_id}`).val(), product_rule_group_id, product_rule_id: product_rule_counters[product_rule_group_id],
|
||||
},
|
||||
(content) => {
|
||||
if (content != '') $(`#product_rule_table_${product_rule_group_id}`).append(content);
|
||||
},
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
function removeProductRule(product_rule_group_id, product_rule_id) {
|
||||
$(`#product_rule_${product_rule_group_id}_${product_rule_id}_tr`).remove();
|
||||
}
|
||||
|
||||
function toggleCartRuleFilter(id) {
|
||||
if ($(id).prop('checked')) $(`#${$(id).attr('id')}_div`).show(400);
|
||||
else $(`#${$(id).attr('id')}_div`).hide(200);
|
||||
}
|
||||
|
||||
function removeCartRuleOption(item) {
|
||||
const id = $(item).attr('id').replace('_remove', '');
|
||||
$(`#${id}_2 option:selected`).remove().appendTo(`#${id}_1`);
|
||||
}
|
||||
|
||||
function addCartRuleOption(item) {
|
||||
const id = $(item).attr('id').replace('_add', '');
|
||||
$(`#${id}_1 option:selected`).remove().appendTo(`#${id}_2`);
|
||||
}
|
||||
|
||||
function updateProductRuleShortDescription(item) {
|
||||
/** ***** For IE: put a product in condition on cart rules ****** */
|
||||
if (typeof String.prototype.trim !== 'function') {
|
||||
String.prototype.trim = function () {
|
||||
return this.replace(/^\s+|\s+$/g, '');
|
||||
};
|
||||
}
|
||||
|
||||
const id1 = $(item).attr('id').replace('_add', '').replace('_remove', '');
|
||||
const id2 = id1.replace('_select', '');
|
||||
const {length} = $(`#${id1}_2 option`);
|
||||
|
||||
if (length == 1) $(`#${id2}_match`).val($(`#${id1}_2 option`).first().text().trim());
|
||||
else $(`#${id2}_match`).val(length);
|
||||
}
|
||||
|
||||
window.restrictions = new Array('country', 'carrier', 'group', 'cart_rule', 'shop');
|
||||
|
||||
for (i in restrictions) {
|
||||
toggleCartRuleFilter($(`#${restrictions[i]}_restriction`));
|
||||
$(`#${restrictions[i]}_restriction`).change(function () { toggleCartRuleFilter(this); });
|
||||
$(`#${restrictions[i]}_select_remove`).click(function () { removeCartRuleOption(this); });
|
||||
$(`#${restrictions[i]}_select_add`).click(function () { addCartRuleOption(this); });
|
||||
}
|
||||
|
||||
toggleCartRuleFilter($('#product_restriction'));
|
||||
|
||||
$('#group_restriction').change(function () {
|
||||
$('#customerFilter').prop('disabled', $(this).prop('checked'));
|
||||
}).change();
|
||||
|
||||
$('#customerFilter').on('change keyup', function () {
|
||||
$('#group_restriction').prop('disabled', $(this).val() !== '');
|
||||
}).change();
|
||||
|
||||
$('#product_restriction').change(function () {
|
||||
toggleCartRuleFilter(this);
|
||||
|
||||
if ($(this).prop('checked')) {
|
||||
$('#apply_discount_to_selection').prop('disabled', false);
|
||||
$('#apply_discount_to_selection_warning').hide();
|
||||
} else {
|
||||
$('#apply_discount_to_selection').prop('disabled', true);
|
||||
$('#apply_discount_to_selection_warning').show();
|
||||
}
|
||||
});
|
||||
|
||||
$('#apply_discount_to_selection_shortcut').click((e) => {
|
||||
displayCartRuleTab('conditions');
|
||||
$('#product_restriction').focus();
|
||||
e.preventDefault();
|
||||
});
|
||||
|
||||
function toggleApplyDiscount(percent, amount, apply_to) {
|
||||
if (percent) {
|
||||
$('#apply_discount_percent_div').show(400);
|
||||
if ($('#apply_discount_to_product').prop('checked')) toggleApplyDiscountTo();
|
||||
$('#apply_discount_to_cheapest').show();
|
||||
$('*[for=apply_discount_to_cheapest]').show();
|
||||
$('#apply_discount_to_selection').show();
|
||||
$('*[for=apply_discount_to_selection]').show();
|
||||
$('#apply_discount_to_product_special').show(400);
|
||||
} else {
|
||||
$('#apply_discount_percent_div').hide(200);
|
||||
$('#reduction_percent').val('0');
|
||||
}
|
||||
|
||||
if (amount) {
|
||||
$('#apply_discount_amount_div').show(400);
|
||||
if ($('#apply_discount_to_product').prop('checked')) toggleApplyDiscountTo();
|
||||
$('#apply_discount_to_cheapest').hide();
|
||||
$('*[for=apply_discount_to_cheapest]').hide();
|
||||
$('#apply_discount_to_cheapest').prop('checked', false);
|
||||
$('#apply_discount_to_selection').hide();
|
||||
$('*[for=apply_discount_to_selection]').hide();
|
||||
$('#apply_discount_to_selection').prop('checked', false);
|
||||
$('#apply_discount_to_product_special').hide(200);
|
||||
} else {
|
||||
$('#apply_discount_amount_div').hide(200);
|
||||
$('#reduction_amount').val('0');
|
||||
|
||||
if ($('#apply_discount_off').prop('checked')) {
|
||||
$('#apply_discount_to_product').prop('checked', false);
|
||||
toggleApplyDiscountTo();
|
||||
}
|
||||
}
|
||||
|
||||
if (apply_to) $('#apply_discount_to_div').show(400);
|
||||
else {
|
||||
toggleApplyDiscountTo();
|
||||
$('#apply_discount_to_div').hide(200);
|
||||
}
|
||||
}
|
||||
|
||||
function toggleApplyDiscountTo() {
|
||||
if ($('#apply_discount_to_product').prop('checked')) $('#apply_discount_to_product_div').show(400);
|
||||
else {
|
||||
$('#apply_discount_to_product_div').hide(200);
|
||||
$('#reductionProductFilter').val('');
|
||||
if ($('#apply_discount_to_order').prop('checked')) $('#reduction_product').val('0');
|
||||
if ($('#apply_discount_to_cheapest').prop('checked')) $('#reduction_product').val('-1');
|
||||
if ($('#apply_discount_to_selection').prop('checked')) $('#reduction_product').val('-2');
|
||||
}
|
||||
}
|
||||
|
||||
function toggleGiftProduct() {
|
||||
if ($('#free_gift_on').prop('checked')) $('#free_gift_div').show(400);
|
||||
else {
|
||||
$('#gift_product').val('0');
|
||||
$('#giftProductFilter').val('');
|
||||
$('#free_gift_div').hide(200);
|
||||
}
|
||||
}
|
||||
|
||||
$('#apply_discount_percent').click(() => {
|
||||
toggleApplyDiscount(true, false, true);
|
||||
});
|
||||
if ($('#apply_discount_percent').prop('checked')) toggleApplyDiscount(true, false, true);
|
||||
|
||||
$('#apply_discount_amount').click(() => {
|
||||
toggleApplyDiscount(false, true, true);
|
||||
});
|
||||
if ($('#apply_discount_amount').prop('checked')) toggleApplyDiscount(false, true, true);
|
||||
|
||||
$('#apply_discount_off').click(() => {
|
||||
toggleApplyDiscount(false, false, false);
|
||||
});
|
||||
if ($('#apply_discount_off').prop('checked')) toggleApplyDiscount(false, false, false);
|
||||
|
||||
$('#apply_discount_to_order').click(() => {
|
||||
toggleApplyDiscountTo();
|
||||
},
|
||||
);
|
||||
if ($('#apply_discount_to_order').prop('checked')) toggleApplyDiscountTo();
|
||||
|
||||
$('#apply_discount_to_product').click(() => {
|
||||
toggleApplyDiscountTo();
|
||||
},
|
||||
);
|
||||
if ($('#apply_discount_to_product').prop('checked')) toggleApplyDiscountTo();
|
||||
|
||||
$('#apply_discount_to_cheapest').click(() => {
|
||||
toggleApplyDiscountTo();
|
||||
},
|
||||
);
|
||||
if ($('#apply_discount_to_cheapest').prop('checked')) toggleApplyDiscountTo();
|
||||
|
||||
$('#apply_discount_to_selection').click(() => {
|
||||
toggleApplyDiscountTo();
|
||||
},
|
||||
);
|
||||
if ($('#apply_discount_to_selection').prop('checked')) toggleApplyDiscountTo();
|
||||
|
||||
$('#free_gift_on').click(() => {
|
||||
toggleGiftProduct();
|
||||
},
|
||||
);
|
||||
$('#free_gift_off').click(() => {
|
||||
toggleGiftProduct();
|
||||
},
|
||||
);
|
||||
toggleGiftProduct();
|
||||
|
||||
// Main form submit
|
||||
$('#cart_rule_form').submit(() => {
|
||||
if ($('#customerFilter').val() == '') $('#id_customer').val('0');
|
||||
|
||||
for (i in restrictions) {
|
||||
if ($(`#${restrictions[i]}_select_1 option`).length == 0) $(`#${restrictions[i]}_restriction`).prop('checked', false);
|
||||
else {
|
||||
$(`#${restrictions[i]}_select_2 option`).each(function (i) {
|
||||
$(this).prop('selected', true);
|
||||
});
|
||||
}
|
||||
}
|
||||
|
||||
$('.product_rule_toselect option').each(function (i) {
|
||||
$(this).prop('selected', true);
|
||||
});
|
||||
});
|
||||
|
||||
$('#reductionProductFilter')
|
||||
.autocomplete(
|
||||
'ajax-tab.php', {
|
||||
minChars: 2,
|
||||
max: 50,
|
||||
width: 500,
|
||||
selectFirst: false,
|
||||
scroll: false,
|
||||
dataType: 'json',
|
||||
formatItem(data, i, max, value, term) {
|
||||
return value;
|
||||
},
|
||||
parse(data) {
|
||||
const mytab = new Array();
|
||||
|
||||
for (let i = 0; i < data.length; i++) mytab[mytab.length] = {data: data[i], value: (`${data[i].reference} ${data[i].name}`).trim()};
|
||||
|
||||
return mytab;
|
||||
},
|
||||
extraParams: {
|
||||
controller: 'AdminCartRules',
|
||||
token: currentToken,
|
||||
reductionProductFilter: 1,
|
||||
},
|
||||
},
|
||||
)
|
||||
.result((event, data, formatted) => {
|
||||
$('#reduction_product').val(data.id_product);
|
||||
$('#reductionProductFilter').val((`${data.reference} ${data.name}`).trim());
|
||||
});
|
||||
|
||||
$('#customerFilter')
|
||||
.autocomplete(
|
||||
'ajax-tab.php', {
|
||||
minChars: 2,
|
||||
max: 50,
|
||||
width: 500,
|
||||
selectFirst: false,
|
||||
scroll: false,
|
||||
dataType: 'json',
|
||||
formatItem(data, i, max, value, term) {
|
||||
return value;
|
||||
},
|
||||
parse(data) {
|
||||
const mytab = new Array();
|
||||
|
||||
for (let i = 0; i < data.length; i++) mytab[mytab.length] = {data: data[i], value: `${data[i].cname} (${data[i].email})`};
|
||||
|
||||
return mytab;
|
||||
},
|
||||
extraParams: {
|
||||
controller: 'AdminCartRules',
|
||||
token: currentToken,
|
||||
customerFilter: 1,
|
||||
},
|
||||
},
|
||||
)
|
||||
.result((event, data, formatted) => {
|
||||
$('#id_customer').val(data.id_customer);
|
||||
$('#customerFilter').val(`${data.cname} (${data.email})`);
|
||||
});
|
||||
|
||||
function displayCartRuleTab(tab) {
|
||||
$('.cart_rule_tab').hide();
|
||||
$('.tab-row.active').removeClass('active');
|
||||
$(`#cart_rule_${tab}`).show();
|
||||
$(`#cart_rule_link_${tab}`).parent().addClass('active');
|
||||
$('#currentFormTab').val(tab);
|
||||
}
|
||||
|
||||
$('.cart_rule_tab').hide();
|
||||
$('.tab-row.active').removeClass('active');
|
||||
$(`#cart_rule_${currentFormTab}`).show();
|
||||
$(`#cart_rule_link_${currentFormTab}`).parent().addClass('active');
|
||||
|
||||
window.date = new Date();
|
||||
window.hours = date.getHours();
|
||||
|
||||
if (hours < 10) hours = `0${hours}`;
|
||||
window.mins = date.getMinutes();
|
||||
|
||||
if (mins < 10) mins = `0${mins}`;
|
||||
window.secs = date.getSeconds();
|
||||
|
||||
if (secs < 10) secs = `0${secs}`;
|
||||
|
||||
$('.datepicker').datetimepicker({
|
||||
beforeShow(input, inst) {
|
||||
setTimeout(() => {
|
||||
inst.dpDiv.css({
|
||||
'z-index': 1031,
|
||||
});
|
||||
}, 0);
|
||||
},
|
||||
prevText: '',
|
||||
nextText: '',
|
||||
dateFormat: 'yy-mm-dd',
|
||||
// Define a custom regional settings in order to use PrestaShop translation tools
|
||||
currentText,
|
||||
closeText,
|
||||
ampm: false,
|
||||
amNames: ['AM', 'A'],
|
||||
pmNames: ['PM', 'P'],
|
||||
timeFormat: 'hh:mm:ss tt',
|
||||
timeSuffix: '',
|
||||
timeOnlyTitle,
|
||||
timeText,
|
||||
hourText,
|
||||
minuteText,
|
||||
});
|
||||
|
||||
$('#giftProductFilter').typeWatch({
|
||||
captureLength: 2,
|
||||
highlight: false,
|
||||
wait: 100,
|
||||
callback() { searchProducts(); },
|
||||
});
|
||||
|
||||
window.gift_product_search = $('#giftProductFilter').val();
|
||||
function searchProducts() {
|
||||
if ($('#giftProductFilter').val() == gift_product_search) return;
|
||||
gift_product_search = $('#giftProductFilter').val();
|
||||
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
headers: {'cache-control': 'no-cache'},
|
||||
url: `${'ajax-tab.php' + '?rand='}${new Date().getTime()}`,
|
||||
async: true,
|
||||
dataType: 'json',
|
||||
data: {
|
||||
controller: 'AdminCartRules',
|
||||
token: currentToken,
|
||||
action: 'searchProducts',
|
||||
product_search: $('#giftProductFilter').val(),
|
||||
},
|
||||
success(res) {
|
||||
let products_found = '';
|
||||
let attributes_html = '';
|
||||
stock = {};
|
||||
|
||||
if (res.found) {
|
||||
$('#gift_products_err').hide();
|
||||
$('#gift_products_found').show();
|
||||
$.each(res.products, function () {
|
||||
products_found += `<option value="${this.id_product}">${this.name}${this.combinations.length == 0 ? ` - ${this.formatted_price}` : ''}</option>`;
|
||||
|
||||
attributes_html += `<select class="id_product_attribute" id="ipa_${this.id_product}" name="ipa_${this.id_product}" style="display:none">`;
|
||||
$.each(this.combinations, function () {
|
||||
attributes_html += `<option ${this.default_on == 1 ? 'selected="selected"' : ''} value="${this.id_product_attribute}">${this.attributes} - ${this.formatted_price}</option>`;
|
||||
});
|
||||
attributes_html += '</select>';
|
||||
});
|
||||
|
||||
$('#gift_product_list #gift_product').html(products_found);
|
||||
$('#gift_attributes_list #gift_attributes_list_select').html(attributes_html);
|
||||
displayProductAttributes();
|
||||
} else {
|
||||
$('#products_found').hide();
|
||||
$('#products_err').html(res.notfound);
|
||||
$('#products_err').show();
|
||||
}
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
function displayProductAttributes() {
|
||||
if ($(`#ipa_${$('#gift_product option:selected').val()} option`).length === 0) $('#gift_attributes_list').hide();
|
||||
else {
|
||||
$('#gift_attributes_list').show();
|
||||
$('.id_product_attribute').hide();
|
||||
$(`#ipa_${$('#gift_product option:selected').val()}`).show();
|
||||
}
|
||||
}
|
||||
|
||||
$(document).ready(() => {
|
||||
$(window).keydown((event) => {
|
||||
if (event.keyCode == 13) {
|
||||
event.preventDefault();
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
if ($('#cart_rule_select_1').length > 0 && $('#cart_rule_select_2').length > 0) {
|
||||
$('#cart_rule_select_1').jscroll().data('jscrollapi').load_scroll(`${baseHref}&type=unselected&search=`);
|
||||
$('#cart_rule_select_2').jscroll().data('jscrollapi').load_scroll(`${baseHref}&type=selected&search=`);
|
||||
|
||||
$('.uncombinable_search_filter').typeWatch({
|
||||
captureLength: -1,
|
||||
highlight: true,
|
||||
wait: 500,
|
||||
callback(text) { combinable_filter('#cart_rule_select_1', text, 'unselected'); },
|
||||
});
|
||||
|
||||
$('.combinable_search_filter').typeWatch({
|
||||
captureLength: -1,
|
||||
highlight: true,
|
||||
wait: 500,
|
||||
callback(text) { combinable_filter('#cart_rule_select_2', text, 'selected'); },
|
||||
});
|
||||
}
|
||||
|
||||
displayProductAttributes();
|
||||
});
|
||||
|
||||
function combinable_filter(id_rule, search, type) {
|
||||
const href = `${baseHref}&type=${encodeURIComponent(type)}&search=${encodeURIComponent(search)}`;
|
||||
$(id_rule).jscroll().data('jscrollapi').load_scroll(href);
|
||||
}
|
||||
@@ -0,0 +1,89 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<div class="panel">
|
||||
<h3><i class="icon-tag"></i> {l s='Cart rule' d='Admin.Catalog.Feature'}</h3>
|
||||
<div class="productTabs">
|
||||
<ul class="tab nav nav-tabs">
|
||||
<li class="tab-row">
|
||||
<a class="tab-page" id="cart_rule_link_informations" href="javascript:displayCartRuleTab('informations');"><i class="icon-info"></i> {l s='Information' d='Admin.Catalog.Feature'}</a>
|
||||
</li>
|
||||
<li class="tab-row">
|
||||
<a class="tab-page" id="cart_rule_link_conditions" href="javascript:displayCartRuleTab('conditions');"><i class="icon-random"></i> {l s='Conditions' d='Admin.Catalog.Feature'}</a>
|
||||
</li>
|
||||
<li class="tab-row">
|
||||
<a class="tab-page" id="cart_rule_link_actions" href="javascript:displayCartRuleTab('actions');"><i class="icon-wrench"></i> {l s='Actions' d='Admin.Global'}</a>
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
<form action="{$currentIndex|escape}&token={$currentToken|escape}&addcart_rule" id="cart_rule_form" class="form-horizontal" method="post">
|
||||
{if $currentObject->id}<input type="hidden" name="id_cart_rule" value="{$currentObject->id|intval}" />{/if}
|
||||
<input type="hidden" id="currentFormTab" name="currentFormTab" value="informations" />
|
||||
<div id="cart_rule_informations" class="panel cart_rule_tab">
|
||||
{include file='controllers/cart_rules/informations.tpl'}
|
||||
</div>
|
||||
<div id="cart_rule_conditions" class="panel cart_rule_tab">
|
||||
{include file='controllers/cart_rules/conditions.tpl'}
|
||||
</div>
|
||||
<div id="cart_rule_actions" class="panel cart_rule_tab">
|
||||
{include file='controllers/cart_rules/actions.tpl'}
|
||||
</div>
|
||||
<button type="submit" class="btn btn-default pull-right" name="submitAddcart_rule" id="{$table|escape}_form_submit_btn">{l s='Save' d='Admin.Actions'}
|
||||
</button>
|
||||
<!--<input type="submit" value="{l s='Save and stay' d='Admin.Actions'}" class="button" name="submitAddcart_ruleAndStay" id="" />-->
|
||||
</form>
|
||||
|
||||
<script type="text/javascript">
|
||||
var product_rule_groups_counter = {if isset($product_rule_groups_counter)}{$product_rule_groups_counter|intval}{else}0{/if};
|
||||
var product_rule_counters = new Array();
|
||||
var currentToken = '{$currentToken|escape:'quotes'}';
|
||||
var currentFormTab = '{if isset($smarty.post.currentFormTab)}{$smarty.post.currentFormTab|escape:'html'}{else}informations{/if}';
|
||||
var currentText = '{l s='Now' js=1 d='Admin.Catalog.Feature'}';
|
||||
var closeText = '{l s='Done' js=1 d='Admin.Catalog.Feature'}';
|
||||
var timeOnlyTitle = '{l s='Choose Time' js=1 d='Admin.Catalog.Feature'}';
|
||||
var timeText = '{l s='Time' js=1 d='Admin.Catalog.Feature'}';
|
||||
var hourText = '{l s='Hour' js=1 d='Admin.Global'}';
|
||||
var minuteText = '{l s='Minute' js=1 d='Admin.Catalog.Feature'}';
|
||||
|
||||
var languages = new Array();
|
||||
{foreach from=$languages item=language key=k}
|
||||
languages[{$k}] = {
|
||||
id_lang: {$language.id_lang},
|
||||
iso_code: '{$language.iso_code|escape:'quotes'}',
|
||||
name: '{$language.name|escape:'quotes'}'
|
||||
};
|
||||
{/foreach}
|
||||
displayFlags(languages, {$id_lang_default});
|
||||
|
||||
{if isset($refresh_cart) }
|
||||
if (typeof window.parent.order_create !== "undefined") {
|
||||
window.parent.order_create.refreshCart();
|
||||
}
|
||||
window.parent.$.fancybox.close();
|
||||
{/if}
|
||||
|
||||
</script>
|
||||
<script type="text/javascript" src="themes/default/template/controllers/cart_rules/form.js"></script>
|
||||
{include file="footer_toolbar.tpl"}
|
||||
</div>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,34 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
{extends file="helpers/list/list_header.tpl"}
|
||||
{block name='override_header'}
|
||||
{if $submit_form_ajax}
|
||||
<script type="text/javascript">
|
||||
$('#voucher', window.parent.document).val('{$new_cart_rule->code|escape:'html':'UTF-8'}');
|
||||
parent.add_cart_rule({$new_cart_rule->id|intval});
|
||||
parent.$.fancybox.close();
|
||||
</script>
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,158 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3 required">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='This will be displayed in the cart summary, as well as on the invoice.' d='Admin.Catalog.Help'}">
|
||||
{l s='Name' d='Admin.Global'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-8">
|
||||
{foreach from=$languages item=language}
|
||||
{if $languages|count > 1}
|
||||
<div class="row">
|
||||
<div class="translatable-field lang-{$language.id_lang}" {if $language.id_lang != $id_lang_default}style="display:none"{/if}>
|
||||
<div class="col-lg-9">
|
||||
{/if}
|
||||
<input id="name_{$language.id_lang|intval}" type="text" name="name_{$language.id_lang|intval}" value="{$currentTab->getFieldValue($currentObject, 'name', $language.id_lang|intval)|escape:'html':'UTF-8'}">
|
||||
{if $languages|count > 1}
|
||||
</div>
|
||||
<div class="col-lg-2">
|
||||
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
|
||||
{$language.iso_code}
|
||||
<span class="caret"></span>
|
||||
</button>
|
||||
<ul class="dropdown-menu">
|
||||
{foreach from=$languages item=language}
|
||||
<li><a href="javascript:hideOtherLanguage({$language.id_lang});" tabindex="-1">{$language.name}</a></li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
{/foreach}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='For your eyes only. This will never be displayed to the customer.' d='Admin.Catalog.Help'}">
|
||||
{l s='Description' d='Admin.Global'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-8">
|
||||
<textarea name="description" rows="2" class="textarea-autosize">{$currentTab->getFieldValue($currentObject, 'description')|escape}</textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{{l s='This is the code users should enter to apply the voucher to a cart. Either create your own code or generate one by clicking on "%generate_label%".' d='Admin.Catalog.Help' sprintf=['%generate_label%' => {l s='Generate' d='Admin.Actions'}]}|escape:"html"}">
|
||||
{l s='Code' d='Admin.Global'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<div class="input-group col-lg-4">
|
||||
<input type="text" id="code" name="code" value="{$currentTab->getFieldValue($currentObject, 'code')|escape}" />
|
||||
<span class="input-group-btn">
|
||||
<a href="javascript:gencode(8);" class="btn btn-default"><i class="icon-random"></i> {l s='Generate' d='Admin.Actions'}</a>
|
||||
</span>
|
||||
</div>
|
||||
<span class="help-block">{l s='Caution! If you leave this field blank, the rule will automatically be applied to benefiting customers.' d='Admin.Catalog.Help'}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group" id="cart-rules-highlight"{if !$currentTab->getFieldValue($currentObject, 'code')} style="display: none;"{/if}>
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='If the voucher is not yet in the cart, it will be displayed in the cart summary.' d='Admin.Catalog.Help'}">
|
||||
{l s='Highlight' d='Admin.Catalog.Feature'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="highlight" id="highlight_on" value="1" {if $currentTab->getFieldValue($currentObject, 'highlight')|intval}checked="checked"{/if}/>
|
||||
<label for="highlight_on">{l s='Yes' d='Admin.Global'}</label>
|
||||
<input type="radio" name="highlight" id="highlight_off" value="0" {if !$currentTab->getFieldValue($currentObject, 'highlight')|intval}checked="checked"{/if} />
|
||||
<label for="highlight_off">{l s='No' d='Admin.Global'}</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='Only applicable if the voucher value is greater than the cart total.' d='Admin.Catalog.Help'}
|
||||
{l s='If you do not allow partial use, the voucher value will be lowered to the total order amount. If you allow partial use, however, a new voucher will be created with the remainder.' d='Admin.Catalog.Help'}">
|
||||
{l s='Partial use' d='Admin.Catalog.Feature'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="partial_use" id="partial_use_on" value="1" {if $currentTab->getFieldValue($currentObject, 'partial_use')|intval}checked="checked"{/if} />
|
||||
<label class="t" for="partial_use_on">{l s='Yes' d='Admin.Global'}</label>
|
||||
<input type="radio" name="partial_use" id="partial_use_off" value="0" {if !$currentTab->getFieldValue($currentObject, 'partial_use')|intval}checked="checked"{/if} />
|
||||
<label class="t" for="partial_use_off">{l s='No' d='Admin.Global'}</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
<span class="label-tooltip" data-toggle="tooltip"
|
||||
title="{l s='Cart rules are applied by priority. A cart rule with a priority of "1" will be processed before a cart rule with a priority of "2".' d='Admin.Catalog.Help'}">
|
||||
{l s='Priority' d='Admin.Global'}
|
||||
</span>
|
||||
</label>
|
||||
<div class="col-lg-1">
|
||||
<input type="text" class="input-mini" name="priority" value="{$currentTab->getFieldValue($currentObject, 'priority')|intval}" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Status' d='Admin.Global'}</label>
|
||||
<div class="col-lg-9">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="active" id="active_on" value="1" {if $currentTab->getFieldValue($currentObject, 'active')|intval}checked="checked"{/if} />
|
||||
<label class="t" for="active_on">{l s='Yes' d='Admin.Global'}</label>
|
||||
<input type="radio" name="active" id="active_off" value="0" {if !$currentTab->getFieldValue($currentObject, 'active')|intval}checked="checked"{/if} />
|
||||
<label class="t" for="active_off">{l s='No' d='Admin.Global'}</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
$(".textarea-autosize").autosize();
|
||||
$(document).ready(function() {
|
||||
$('#code').bind('keyup change', function() {
|
||||
$('#cart-rules-highlight').toggle($(this).val() !== "");
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@@ -0,0 +1,62 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<tr id="product_rule_{$product_rule_group_id|intval}_{$product_rule_id|intval}_tr">
|
||||
<td>
|
||||
<input type="hidden" name="product_rule_{$product_rule_group_id|intval}[]" value="{$product_rule_id}" />
|
||||
<input type="hidden" name="product_rule_{$product_rule_group_id|intval}_{$product_rule_id|intval}_type" value="{$product_rule_type|escape}" />
|
||||
{* Everything is on a single line in order to avoid a empty space between the [ ] and the word *}
|
||||
[{if $product_rule_type == 'products'}{l s='Products' d='Admin.Global'}{elseif $product_rule_type == 'categories'}{l s='Categories' d='Admin.Global'}{elseif $product_rule_type == 'manufacturers'}{l s='Brands' d='Admin.Global'}{elseif $product_rule_type == 'suppliers'}{l s='Suppliers' d='Admin.Global'}{elseif $product_rule_type == 'attributes'}{l s='Attributes' d='Admin.Global'}{/if}]
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" id="product_rule_{$product_rule_group_id|intval}_{$product_rule_id|intval}_match" value="" disabled="disabled" />
|
||||
</td>
|
||||
<td>
|
||||
<a class="btn btn-default" id="product_rule_{$product_rule_group_id|intval}_{$product_rule_id|intval}_choose_link" href="#product_rule_{$product_rule_group_id|intval}_{$product_rule_id|intval}_choose_content">
|
||||
<i class="icon-list-ul"></i>
|
||||
{l s='Choose' d='Admin.Actions'}
|
||||
</a>
|
||||
<div>
|
||||
<div id="product_rule_{$product_rule_group_id|intval}_{$product_rule_id|intval}_choose_content">
|
||||
{$product_rule_choose_content}
|
||||
</div>
|
||||
</div>
|
||||
</td>
|
||||
<td class="text-right">
|
||||
<a class="btn btn-default" href="javascript:removeProductRule({$product_rule_group_id|intval}, {$product_rule_id|intval});">
|
||||
<i class="icon-remove"></i>
|
||||
</a>
|
||||
</td>
|
||||
</tr>
|
||||
|
||||
<script type="text/javascript">
|
||||
$('#product_rule_{$product_rule_group_id|intval}_{$product_rule_id|intval}_choose_content').parent().hide();
|
||||
$("#product_rule_{$product_rule_group_id|intval}_{$product_rule_id|intval}_choose_link").fancybox({
|
||||
autoDimensions: false,
|
||||
autoSize: false,
|
||||
width: 900,
|
||||
autoHeight: true,
|
||||
});
|
||||
$(document).ready(function() { updateProductRuleShortDescription($('#product_rule_select_{$product_rule_group_id|intval}_{$product_rule_id|intval}_add')); });
|
||||
</script>
|
||||
@@ -0,0 +1,75 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<tr id="product_rule_group_{$product_rule_group_id|intval}_tr">
|
||||
<td>
|
||||
<a class="btn btn-default" href="javascript:removeProductRuleGroup({$product_rule_group_id|intval});">
|
||||
<i class="icon-remove text-danger"></i>
|
||||
</a>
|
||||
</td>
|
||||
<td>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-4">{l s='Number of products required in the cart to enjoy the discount:' d='Admin.Catalog.Feature'}</label>
|
||||
<div class="col-lg-1 pull-left">
|
||||
<input type="hidden" name="product_rule_group[]" value="{$product_rule_group_id|intval}" />
|
||||
<input class="form-control" type="text" name="product_rule_group_{$product_rule_group_id|intval}_quantity" value="{$product_rule_group_quantity|intval}" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="form-group">
|
||||
|
||||
<label class="control-label col-lg-4">{l s='Add a rule concerning'}</label>
|
||||
<div class="col-lg-4">
|
||||
<select class="form-control" id="product_rule_type_{$product_rule_group_id|intval}">
|
||||
<option value="">{l s='-- Choose --' d='Admin.Actions'}</option>
|
||||
<option value="products">{l s='Products' d='Admin.Global'}</option>
|
||||
<option value="attributes">{l s='Attributes' d='Admin.Global'}</option>
|
||||
<option value="categories">{l s='Categories' d='Admin.Global'}</option>
|
||||
<option value="manufacturers">{l s='Brands' d='Admin.Global'}</option>
|
||||
<option value="suppliers">{l s='Suppliers' d='Admin.Global'}</option>
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-lg-4">
|
||||
<a class="btn btn-default" href="javascript:addProductRule({$product_rule_group_id|intval});">
|
||||
<i class="icon-plus-sign"></i>
|
||||
{l s="Add" d='Admin.Actions'}
|
||||
</a>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
{l s='The product(s) are matching one of these:'}
|
||||
<table id="product_rule_table_{$product_rule_group_id|intval}" class="table table-bordered">
|
||||
{if isset($product_rules) && $product_rules|@count}
|
||||
{foreach from=$product_rules item='product_rule'}
|
||||
{$product_rule}
|
||||
{/foreach}
|
||||
{/if}
|
||||
</table>
|
||||
|
||||
</td>
|
||||
</tr>
|
||||
@@ -0,0 +1,58 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<div class="col-lg-12 bootstrap">
|
||||
<div class="col-lg-6">
|
||||
{l s='Unselected' d='Admin.Global'}
|
||||
<select multiple size="20" id="product_rule_select_{$product_rule_group_id|intval}_{$product_rule_id|intval}_1">
|
||||
{foreach from=$product_rule_itemlist.unselected item='item'}
|
||||
<option value="{$item.id|intval}" title="{$item.name|escape:'html':'UTF-8'}"> {$item.name|escape:'html':'UTF-8'}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<div class="clearfix"> </div>
|
||||
<a id="product_rule_select_{$product_rule_group_id|intval}_{$product_rule_id|intval}_add" class="btn btn-default btn-block" >
|
||||
{l s='Add' d='Admin.Actions'}
|
||||
<i class="icon-arrow-right"></i>
|
||||
</a>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
{l s='Selected' d='Admin.Global'}
|
||||
<select multiple size="20" name="product_rule_select_{$product_rule_group_id|intval}_{$product_rule_id|intval}[]" id="product_rule_select_{$product_rule_group_id|intval}_{$product_rule_id|intval}_2" class="product_rule_toselect" >
|
||||
{foreach from=$product_rule_itemlist.selected item='item'}
|
||||
<option value="{$item.id|intval}" title="{$item.name|escape:'html':'UTF-8'}"> {$item.name|escape:'html':'UTF-8'}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
<div class="clearfix"> </div>
|
||||
<a id="product_rule_select_{$product_rule_group_id}_{$product_rule_id}_remove" class="btn btn-default btn-block" >
|
||||
<i class="icon-arrow-left"></i>
|
||||
{l s='Remove' d='Admin.Actions'}
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
$('#product_rule_select_{$product_rule_group_id|intval}_{$product_rule_id|intval}_remove').click(function() { removeCartRuleOption(this); updateProductRuleShortDescription(this); });
|
||||
$('#product_rule_select_{$product_rule_group_id|intval}_{$product_rule_id|intval}_add').click(function() { addCartRuleOption(this); updateProductRuleShortDescription(this); });
|
||||
$(document).ready(function() { updateProductRuleShortDescription($('#product_rule_select_{$product_rule_group_id|intval}_{$product_rule_id|intval}_add')); });
|
||||
</script>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,224 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/view/view.tpl"}
|
||||
|
||||
{block name="override_tpl"}
|
||||
<div class="panel">
|
||||
{$kpi}
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-6">
|
||||
<div class="panel">
|
||||
<h3><i class="icon-user"></i> {l s='Customer information' d='Admin.Orderscustomers.Feature'}</h3>
|
||||
{if $customer->id}
|
||||
<a class="btn btn-default pull-right" href="mailto:{$customer->email}"><i class="icon-envelope"></i> {$customer->email}</a>
|
||||
<h2>
|
||||
{if $customer->id_gender == 1}
|
||||
<i class="icon-male"></i>
|
||||
{elseif $customer->id_gender == 2}
|
||||
<i class="icon-female"></i>
|
||||
{else}
|
||||
<i class="icon-question"></i>
|
||||
{/if}
|
||||
<a href="{$link->getAdminLink('AdminCustomers', true, [], ['id_customer' => $customer->id|intval, 'viewcustomer' => 1])|escape:'html':'UTF-8'}">{$customer->firstname} {$customer->lastname}</a></h2>
|
||||
<div class="form-horizontal">
|
||||
<div class="form-group">
|
||||
<label class="col-lg-3 control-label">{l s='Account registration date:' d='Admin.Orderscustomers.Feature'}</label>
|
||||
<div class="col-lg-3"><p class="form-control-static">{dateFormat date=$customer->date_add}</p></div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-lg-3 control-label">{l s='Valid orders placed:' d='Admin.Orderscustomers.Feature'}</label>
|
||||
<div class="col-lg-3"><p class="form-control-static">{$customer_stats.nb_orders}</p></div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-lg-3 control-label">{l s='Total spent since registration:' d='Admin.Orderscustomers.Feature'}</label>
|
||||
<div class="col-lg-3"><p class="form-control-static">{displayWtPriceWithCurrency price=$customer_stats.total_orders currency=$currency}</p></div>
|
||||
</div>
|
||||
</div>
|
||||
{else}
|
||||
<h2>{l s='Guest not registered' d='Admin.Orderscustomers.Feature'}</h2>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
<div class="panel">
|
||||
<h3><i class="icon-shopping-cart"></i> {l s='Order information' d='Admin.Orderscustomers.Feature'}</h3>
|
||||
{if $order->id}
|
||||
<h2><a href="{$link->getAdminLink('AdminOrders', true, [], ['id_order' => $order->id|intval, 'vieworder' => 1])|escape:'html':'UTF-8'}"> {l s='Order #%d' sprintf=[$order->id|string_format:"%06d"] d='Admin.Orderscustomers.Feature'}</a></h2>
|
||||
{l s='Made on:' d='Admin.Orderscustomers.Feature'} {dateFormat date=$order->date_add}
|
||||
{else}
|
||||
<h2>{l s='No order was created from this cart.' d='Admin.Orderscustomers.Feature'}</h2>
|
||||
{if $customer->id}
|
||||
<a class="btn btn-default" href="{$link->getAdminLink('AdminOrders', true, [], ['id_cart' => $cart->id|intval, 'addorder' => 1])|escape:'html':'UTF-8'}"><i class="icon-shopping-cart"></i> {l s='Create an order from this cart.' d='Admin.Orderscustomers.Feature'}</a>
|
||||
{/if}
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel">
|
||||
<h3><i class="icon-archive"></i> {l s='Cart summary' d='Admin.Orderscustomers.Feature'}</h3>
|
||||
<div class="row">
|
||||
<table class="table" id="orderProducts">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="fixed-width-xs"> </th>
|
||||
<th><span class="title_box">{l s='Product' d='Admin.Global'}</span></th>
|
||||
<th class="text-right fixed-width-md"><span class="title_box">{l s='Unit price' d='Admin.Global'}</span></th>
|
||||
<th class="text-center fixed-width-md"><span class="title_box">{l s='Quantity' d='Admin.Global'}</span></th>
|
||||
<th class="text-center fixed-width-sm"><span class="title_box">{l s='Stock' d='Admin.Global'}</span></th>
|
||||
<th class="text-right fixed-width-sm"><span class="title_box">{l s='Total' d='Admin.Global'}</span></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{foreach from=$products item='product'}
|
||||
{if $product['customizedDatas']}
|
||||
<tr>
|
||||
<td>{$product.image}</td>
|
||||
<td><a href="{$link->getAdminLink('AdminProducts', true, ['id_product' => $product.id_product, 'updateproduct' => 1])|escape:'html':'UTF-8'}">
|
||||
<span class="productName">{$product.name}</span>{if isset($product.attributes)}<br />{$product.attributes}{/if}<br />
|
||||
{if $product.reference}{l s='Ref:' d='Admin.Orderscustomers.Feature'} {$product.reference}{/if}
|
||||
{if $product.reference && $product.supplier_reference} / {$product.supplier_reference}{/if}
|
||||
</a>
|
||||
</td>
|
||||
<td class="text-right">{displayWtPriceWithCurrency price=$product.price_wt currency=$currency}</td>
|
||||
<td class="text-center">{$product.customizationQuantityTotal}</td>
|
||||
<td class="text-center">{$product.qty_in_stock}</td>
|
||||
<td class="text-right">{displayWtPriceWithCurrency price=$product.total_customization_wt currency=$currency}</td>
|
||||
</tr>
|
||||
|
||||
{foreach $product['customizedDatas'] as $customizationPerAddress}
|
||||
{foreach $customizationPerAddress as $customization}
|
||||
{if count($customizationPerAddress) == 1 && ((int)$customization.id_customization != (int)$product.id_customization)}{continue}{/if}
|
||||
<tr>
|
||||
<td colspan="2">
|
||||
{foreach from=$customization.datas key='type' item='datas'}
|
||||
{if $type == constant('Product::CUSTOMIZE_FILE')}
|
||||
<ul style="margin: 0; padding: 0; list-style-type: none;">
|
||||
{foreach from=$datas key='index' item='data'}
|
||||
<li style="display: inline; margin: 2px;">
|
||||
<a href="{$link->getAdminLink('AdminCarts', true, [], ['ajax' => 1, 'action' => 'customizationImage', 'img' => $data.value, 'name' => $order->id|intval|cat:'-file'|cat:$index])}" target="_blank" rel="noopener noreferrer nofollow">
|
||||
<img src="{$pic_dir}{$data.value}_small" alt="" /></a>
|
||||
</li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
{elseif $type == constant('Product::CUSTOMIZE_TEXTFIELD')}
|
||||
<div class="form-horizontal">
|
||||
{foreach from=$datas key='index' item='data'}
|
||||
<div class="form-group">
|
||||
<span class="control-label col-lg-3"><strong>{if $data.name}{$data.name}{else}{l s='Text #' d='Admin.Orderscustomers.Feature'}{$index}{/if}</strong></span>
|
||||
<div class="col-lg-9">
|
||||
<p class="form-control-static">{$data.value}</p>
|
||||
</div>
|
||||
</div>
|
||||
{/foreach}
|
||||
</div>
|
||||
{/if}
|
||||
{/foreach}
|
||||
</td>
|
||||
<td></td>
|
||||
<td class="text-center">{$customization.quantity}</td>
|
||||
<td></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
{/foreach}
|
||||
{/if}
|
||||
|
||||
{if !isset($product.customizationQuantityTotal) || $product.cart_quantity > $product.customizationQuantityTotal}
|
||||
<tr>
|
||||
<td>{$product.image}</td>
|
||||
<td>
|
||||
<a href="{$link->getAdminLink('AdminProducts', true, ['id_product' => $product.id_product, 'updateproduct' => 1])|escape:'html':'UTF-8'}">
|
||||
<span class="productName">{$product.name}</span>{if isset($product.attributes)}<br />{$product.attributes}{/if}<br />
|
||||
{if $product.reference}{l s='Ref:' d='Admin.Orderscustomers.Feature'} {$product.reference}{/if}
|
||||
{if $product.reference && $product.supplier_reference} / {$product.supplier_reference}{/if}
|
||||
</a>
|
||||
</td>
|
||||
<td class="text-right">{displayWtPriceWithCurrency price=$product.product_price currency=$currency}</td>
|
||||
<td class="text-center">{if isset($product.customizationQuantityTotal)}{math equation='x - y' x=$product.cart_quantity y=$product.customizationQuantityTotal|intval}{else}{math equation='x - y' x=$product.cart_quantity y=$product.customization_quantity|intval}{/if}</td>
|
||||
<td class="text-center">{$product.qty_in_stock}</td>
|
||||
<td class="text-right">{displayWtPriceWithCurrency price=$product.product_total currency=$currency}</td>
|
||||
</tr>
|
||||
{/if}
|
||||
{/foreach}
|
||||
<tr>
|
||||
<td colspan="5">{l s='Total cost of products:' d='Admin.Orderscustomers.Feature'}</td>
|
||||
<td class="text-right">{displayWtPriceWithCurrency price=$total_products currency=$currency}</td>
|
||||
</tr>
|
||||
{if $total_discounts != 0}
|
||||
<tr>
|
||||
<td colspan="5">{l s='Total value of vouchers:' d='Admin.Orderscustomers.Feature'}</td>
|
||||
<td class="text-right">{displayWtPriceWithCurrency price=$total_discounts currency=$currency}</td>
|
||||
</tr>
|
||||
{/if}
|
||||
{if $total_wrapping > 0}
|
||||
<tr>
|
||||
<td colspan="5">{l s='Total cost of gift wrapping:' d='Admin.Orderscustomers.Feature'}</td>
|
||||
<td class="text-right">{displayWtPriceWithCurrency price=$total_wrapping currency=$currency}</td>
|
||||
</tr>
|
||||
{/if}
|
||||
{if $cart->getOrderTotal(true, Cart::ONLY_SHIPPING) > 0}
|
||||
<tr>
|
||||
<td colspan="5">{l s='Total shipping costs:' d='Admin.Orderscustomers.Feature'}</td>
|
||||
<td class="text-right">{displayWtPriceWithCurrency price=$total_shipping currency=$currency}</td>
|
||||
</tr>
|
||||
{/if}
|
||||
<tr>
|
||||
<td colspan="5" class=" success"><strong>{l s='Total' d='Admin.Global'}</strong></td>
|
||||
<td class="text-right success"><strong>{displayWtPriceWithCurrency price=$total_price currency=$currency}</strong></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{if $discounts}
|
||||
<div class="clear"> </div>
|
||||
<div class="row">
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="fixed-width-xs"><img src="../img/admin/coupon.gif" alt="{l s='Discounts' d='Admin.Global'}" /></th>
|
||||
<th>{l s='Discount name'}</th>
|
||||
<th class="text-right fixed-width-md">{l s='Value' d='Admin.Global'}</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{foreach from=$discounts item='discount'}
|
||||
<tr>
|
||||
<td class="fixed-width-xs">{$discount.id_discount}</td>
|
||||
<td><a href="{$link->getAdminLink('AdminCartRules', true, [], ['id_cart_rule' => $discount.id_discount, 'updatecart_rule' => 1])|escape:'html':'UTF-8'}">{$discount.name}</a></td>
|
||||
<td class="text-right fixed-width-md">{if (float)$discount.value_real == 0 && (int)$discount.free_shipping == 1}{l s='Free shipping' d='Admin.Shipping.Feature'}{else}- {displayWtPriceWithCurrency price=$discount.value_real currency=$currency}{/if}</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{/if}
|
||||
<div class="clear"> </div>
|
||||
<div class="row alert alert-warning">
|
||||
{l s='For this particular customer group, prices are displayed as:' d='Admin.Orderscustomers.Notification'} <b>{if $tax_calculation_method == $smarty.const.PS_TAX_EXC}{l s='Tax excluded' d='Admin.Global'}{else}{l s='Tax included' d='Admin.Global'}{/if}</b>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,118 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
{extends file="helpers/form/form.tpl"}
|
||||
|
||||
{block name="field"}
|
||||
{if $input.type == 'address_layout'}
|
||||
<div class="col-lg-8">
|
||||
<div class="form-group">
|
||||
<div class="col-lg-4">
|
||||
<textarea id="ordered_fields" name="address_layout" style="height:150px;">{$input.address_layout}</textarea>
|
||||
</div>
|
||||
<div class="col-lg-8">
|
||||
{l s='Some countries require different elements than others. Click on the button below to get the valid default address format for this country.' d='Admin.International.Feature'}
|
||||
{$input.display_valid_fields}
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="{l s='This will restore your last registered address format.' d='Admin.International.Help'}" data-html="true"><a id="useLastDefaultLayout" href="javascript:void(0)" onclick="resetLayout('{$input.encoding_address_layout}', 'lastDefault');" class="btn btn-default">
|
||||
{l s='Use the last registered format' d='Admin.International.Feature'}</a></span>
|
||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="{l s='This will restore the default address format for this country.' d='Admin.International.Help'}" data-html="true"><a id="useDefaultLayoutSystem" href="javascript:void(0)" onclick="resetLayout('{$input.encoding_default_layout}', 'defaultSystem');" class="btn btn-default">
|
||||
{l s='Use the default format' d='Admin.International.Feature'}</a></span>
|
||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="{l s='This will restore your current address format.' d='Admin.International.Help'}" data-html="true"><a id="useCurrentLastModifiedLayout" href="javascript:void(0)" onclick="resetLayout(lastLayoutModified, 'currentModified')" class="btn btn-default">
|
||||
{l s='Use my current modified format' d='Admin.International.Feature'}</a></span>
|
||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="{l s='This will delete the current address format' d='Admin.International.Help'}" data-html="true"><a id="eraseCurrentLayout" href="javascript:void(0)" onclick="resetLayout('', 'erase');" class="btn btn-default">
|
||||
<i class="icon-eraser"></i> {l s='Clear format' d='Admin.International.Feature'}</a></span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{else}
|
||||
{$smarty.block.parent}
|
||||
{/if}
|
||||
{/block}
|
||||
|
||||
{block name="input_row"}
|
||||
{if $input.name == 'standardization'}
|
||||
<div class="form-group" id="TAASC" style="display: none;">
|
||||
<label for="{$input.name}" class="control-label col-lg-3">{$input.label}</label>
|
||||
<div class="col-lg-9">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="{$input.name}" id="{$input.name}_on" value="1" />
|
||||
<label for="{$input.name}_on">
|
||||
{l s='Yes' d='Admin.Global'}
|
||||
</label>
|
||||
<input type="radio" name="{$input.name}" id="{$input.name}_off" value="0" checked="checked" />
|
||||
<label for="{$input.name}_off">
|
||||
{l s='No' d='Admin.Global'}
|
||||
</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
</div>
|
||||
</div>
|
||||
{else}
|
||||
{$smarty.block.parent}
|
||||
{/if}
|
||||
{/block}
|
||||
|
||||
|
||||
{block name=script}
|
||||
|
||||
$(document).ready(function() {
|
||||
|
||||
$('.addPattern').click(function() {
|
||||
addFieldsToCursorPosition($(this).attr("id"))
|
||||
lastLayoutModified = $("#ordered_fields").val();
|
||||
});
|
||||
|
||||
$('#ordered_fields').keyup(function() {
|
||||
lastLayoutModified = $(this).val();
|
||||
});
|
||||
|
||||
$('#need_zip_code_on, #need_zip_code_off').change(function() {
|
||||
disableZipFormat();
|
||||
});
|
||||
|
||||
$('#iso_code').change(function() {
|
||||
disableTAASC();
|
||||
});
|
||||
disableTAASC();
|
||||
});
|
||||
|
||||
function addFieldsToCursorPosition(pattern) {
|
||||
$("#ordered_fields").replaceSelection(pattern + " ");
|
||||
}
|
||||
|
||||
function resetLayout(defaultLayout, type) {
|
||||
if (confirm("{l s='Are you sure you want to restore the default address format for this country?' js=1 d='Admin.International.Notification'}"))
|
||||
$("#ordered_fields").val(unescape(defaultLayout.replace(/\+/g, " ")));
|
||||
}
|
||||
|
||||
$('#custom-address-fields a').click(function (e) {
|
||||
e.preventDefault();
|
||||
$(this).tab('show')
|
||||
})
|
||||
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,189 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
</table>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-6">
|
||||
{if $bulk_actions && $has_bulk_actions}
|
||||
<div class="btn-group bulk-actions dropup">
|
||||
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
|
||||
{l s='Bulk actions' d='Admin.Global'} <span class="caret"></span>
|
||||
</button>
|
||||
<ul class="dropdown-menu">
|
||||
<li>
|
||||
<a href="#" onclick="javascript:checkDelBoxes($(this).closest('form').get(0), '{$list_id}Box[]', true);return false;">
|
||||
<i class="icon-check-sign"></i> {l s='Select all' d='Admin.Actions'}
|
||||
</a>
|
||||
</li>
|
||||
<li>
|
||||
<a href="#" onclick="javascript:checkDelBoxes($(this).closest('form').get(0), '{$list_id}Box[]', false);return false;">
|
||||
<i class="icon-check-empty"></i> {l s='Unselect all' d='Admin.Actions'}
|
||||
</a>
|
||||
</li>
|
||||
<li class="divider"></li>
|
||||
{foreach $bulk_actions as $key => $params}
|
||||
<li{if $params.text == 'divider'} class="divider"{/if}>
|
||||
{if $params.text != 'divider'}
|
||||
<a href="#" onclick="{if isset($params.confirm)}if (confirm('{$params.confirm}')){/if}sendBulkAction($(this).closest('form').get(0), 'submitBulk{$key}{$table}');">
|
||||
{if isset($params.icon)}<i class="{$params.icon}"></i>{/if} {$params.text}
|
||||
</a>
|
||||
{/if}
|
||||
</li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
{if !$simple_header && $list_total > $pagination[0]}
|
||||
<div class="col-lg-6">
|
||||
{* Choose number of results per page *}
|
||||
<div class="pagination">
|
||||
{l s='Display' d='Admin.Actions'}
|
||||
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
|
||||
{$selected_pagination}
|
||||
<i class="icon-caret-down"></i>
|
||||
</button>
|
||||
<ul class="dropdown-menu">
|
||||
{foreach $pagination AS $value}
|
||||
<li>
|
||||
<a href="javascript:void(0);" class="pagination-items-page" data-items="{$value|intval}" data-list-id="{$list_id}">{$value}</a>
|
||||
</li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
/ {$list_total} {l s='result(s)' d='Admin.Global'}
|
||||
<input type="hidden" id="{$list_id}-pagination-items-page" name="{$list_id}_pagination" value="{$selected_pagination|intval}" />
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
$('.pagination-items-page').on('click',function(e){
|
||||
e.preventDefault();
|
||||
$('#'+$(this).data("list-id")+'-pagination-items-page').val($(this).data("items")).closest("form").submit();
|
||||
});
|
||||
</script>
|
||||
<ul class="pagination pull-right">
|
||||
<li {if $page <= 1}class="disabled"{/if}>
|
||||
<a href="javascript:void(0);" class="pagination-link" data-page="1" data-list-id="{$list_id}">
|
||||
<i class="icon-double-angle-left"></i>
|
||||
</a>
|
||||
</li>
|
||||
<li {if $page <= 1}class="disabled"{/if}>
|
||||
<a href="javascript:void(0);" class="pagination-link" data-page="{$page - 1}" data-list-id="{$list_id}">
|
||||
<i class="icon-angle-left"></i>
|
||||
</a>
|
||||
</li>
|
||||
{assign p 0}
|
||||
{while $p++ < $total_pages}
|
||||
{if $p < $page-2}
|
||||
<li class="disabled">
|
||||
<a href="javascript:void(0);">…</a>
|
||||
</li>
|
||||
{assign p $page-3}
|
||||
{elseif $p > $page+2}
|
||||
<li class="disabled">
|
||||
<a href="javascript:void(0);">…</a>
|
||||
</li>
|
||||
{assign p $total_pages}
|
||||
{else}
|
||||
<li {if $p == $page}class="active"{/if}>
|
||||
<a href="javascript:void(0);" class="pagination-link" data-page="{$p}" data-list-id="{$list_id}">{$p}</a>
|
||||
</li>
|
||||
{/if}
|
||||
{/while}
|
||||
<li {if $page >= $total_pages}class="disabled"{/if}>
|
||||
<a href="javascript:void(0);" class="pagination-link" data-page="{$page + 1}" data-list-id="{$list_id}">
|
||||
<i class="icon-angle-right"></i>
|
||||
</a>
|
||||
</li>
|
||||
<li {if $page >= $total_pages}class="disabled"{/if}>
|
||||
<a href="javascript:void(0);" class="pagination-link" data-page="{$total_pages}" data-list-id="{$list_id}">
|
||||
<i class="icon-double-angle-right"></i>
|
||||
</a>
|
||||
</li>
|
||||
</ul>
|
||||
<script type="text/javascript">
|
||||
$('.pagination-link').on('click',function(e){
|
||||
e.preventDefault();
|
||||
|
||||
if (!$(this).parent().hasClass('disabled'))
|
||||
$('#submitFilter'+$(this).data("list-id")).val($(this).data("page")).closest("form").submit();
|
||||
});
|
||||
</script>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
{if isset($assign_zone)}
|
||||
<hr />
|
||||
<div class="row">
|
||||
<div class="col-lg-6">
|
||||
<div class="form-group col-lg-3">
|
||||
<select id="zone_to_affect" name="zone_to_affect" class="form-control">
|
||||
<option value="0">{l s='Zone' d='Admin.Global'}</option>
|
||||
{foreach $zones as $z}
|
||||
<option value="{$z['id_zone']}">{$z['name']}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</div>
|
||||
<div class="form-group col-lg-3">
|
||||
<input type="submit" class="btn btn-default pull-right" name="submitBulkAffectZone{$table}" value="{l s='Assign to a new zone' d='Admin.International.Feature'}" />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
{block name="footer"}
|
||||
{foreach from=$toolbar_btn item=btn key=k}
|
||||
{if $k == 'back'}
|
||||
{assign 'back_button' $btn}
|
||||
{break}
|
||||
{/if}
|
||||
{/foreach}
|
||||
{if isset($back_button)}
|
||||
<div class="panel-footer">
|
||||
<a id="desc-{$table}-{if isset($back_button.imgclass)}{$back_button.imgclass}{else}{$k}{/if}" class="btn btn-default{if isset($back_button.target) && $back_button.target} _blank{/if}"{if isset($back_button.href)} href="{$back_button.href|escape:'html':'UTF-8'}"{/if}{if isset($back_button.js) && $back_button.js} onclick="{$back_button.js}"{/if}>
|
||||
<i class="process-icon-back {if isset($back_button.class)}{$back_button.class}{/if}" ></i> <span {if isset($back_button.force_desc) && $back_button.force_desc == true } class="locked" {/if}>{$back_button.desc}</span>
|
||||
</a>
|
||||
</div>
|
||||
{/if}
|
||||
{/block}
|
||||
{if !$simple_header}
|
||||
<input type="hidden" name="token" value="{$token|escape:'html':'UTF-8'}" />
|
||||
</div>
|
||||
{else}
|
||||
</div>
|
||||
{/if}
|
||||
|
||||
{hook h='displayAdminListAfter'}
|
||||
{if isset($name_controller)}
|
||||
{capture name=hookName assign=hookName}display{$name_controller|ucfirst}ListAfter{/capture}
|
||||
{hook h=$hookName}
|
||||
{elseif isset($smarty.get.controller)}
|
||||
{capture name=hookName assign=hookName}display{$smarty.get.controller|ucfirst|htmlentities}ListAfter{/capture}
|
||||
{hook h=$hookName}
|
||||
{/if}
|
||||
|
||||
{block name="endForm"}
|
||||
</form>
|
||||
{/block}
|
||||
|
||||
{block name="after"}{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,89 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/list/list_header.tpl"}
|
||||
|
||||
{block name="leadin"}
|
||||
<div id="CustomerThreadContacts" class="row">
|
||||
{assign var=nb_categories value=count($categories)}
|
||||
{foreach $categories as $key => $val}
|
||||
|
||||
{assign var=total_thread value=0}
|
||||
{assign var=id_customer_thread value=0}
|
||||
|
||||
{foreach $contacts as $tmp => $tmp2}
|
||||
{if $val.id_contact == $tmp2.id_contact}
|
||||
{assign var=total_thread value=$tmp2.total}
|
||||
{assign var=id_customer_thread value=$tmp2.id_customer_thread}
|
||||
{/if}
|
||||
{/foreach}
|
||||
<div class="col-lg-3">
|
||||
<div class="panel">
|
||||
<div class="panel-heading">
|
||||
{$val.name}
|
||||
</div>
|
||||
{if $nb_categories < 6}
|
||||
<p>{$val.description}</p>
|
||||
{/if}
|
||||
{if $total_thread == 0}
|
||||
<span class="message-mail">{l s='No new messages' d='Admin.Orderscustomers.Feature'}</span>
|
||||
{else}
|
||||
<a href="{$currentIndex|escape:'html':'UTF-8'}&token={$token|escape:'html':'UTF-8'}&id_customer_thread={$id_customer_thread}&viewcustomer_thread" class="button">
|
||||
{$total_thread}
|
||||
{if $total_thread > 1}{l s='New messages' d='Admin.Orderscustomers.Feature'}{else}{l s='New message' d='Admin.Orderscustomers.Feature'}{/if}
|
||||
</a>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
{/foreach}
|
||||
<div class="col-lg-3">
|
||||
<div id="MeaningStatus" class="panel">
|
||||
<div class="panel-heading">
|
||||
{l s='Meaning of status' d='Admin.Orderscustomers.Feature'}
|
||||
</div>
|
||||
<ul class="list-unstyled">
|
||||
<li class="text-success"><i class="icon-circle"></i> {l s='Open' d='Admin.Orderscustomers.Feature'}</li>
|
||||
<li class="text-danger"><i class="icon-circle"></i> {l s='Closed' d='Admin.Orderscustomers.Feature'}</li>
|
||||
<li class="text-warning"><i class="icon-circle"></i> {l s='Pending 1' d='Admin.Orderscustomers.Feature'}</li>
|
||||
<li class="text-warning"><i class="icon-circle"></i> {l s='Pending 2' d='Admin.Orderscustomers.Feature'}</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-3">
|
||||
<div id="CustomerService" class="panel">
|
||||
<div class="panel-heading">
|
||||
{l s='Statistics' d='Admin.Orderscustomers.Feature'}
|
||||
</div>
|
||||
<ul class="list-unstyled">
|
||||
{assign var=count value=0}
|
||||
{foreach $params as $key => $val}
|
||||
{assign var=count value=$count+1}
|
||||
<li>{$key} <span class="badge">{$val}</span></li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,94 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
{extends file="helpers/options/options.tpl"}
|
||||
{block name="after"}
|
||||
{if $use_sync}
|
||||
<div class="panel">
|
||||
<legend>{l s='Sync' d='Admin.Orderscustomers.Feature'}</legend>
|
||||
<label>{l s='Run sync:' d='Admin.Orderscustomers.Feature'}</label>
|
||||
<div class="margin-form">
|
||||
<button class="btn" id="run_sync" onclick="run_sync();">{l s='Run sync' d='Admin.Orderscustomers.Feature'}</button>
|
||||
<p>{l s='Click to synchronize mail automatically' d='Admin.Orderscustomers.Feature'}</p>
|
||||
<div id="ajax_loader"></div>
|
||||
<div class="error" style="display:none" id="ajax_error"></div>
|
||||
<div class="alert" style="display:none" id="ajax_conf"></div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script type="text/javascript">
|
||||
var ajaxQueries = new Array();
|
||||
function run_sync()
|
||||
{
|
||||
$('#ajax_error').html('');
|
||||
$('#ajax_error').hide();
|
||||
$('#ajax_conf').html('');
|
||||
$('#ajax_conf').hide();
|
||||
for(i = 0; i < ajaxQueries.length; i++)
|
||||
ajaxQueries[i].abort();
|
||||
ajaxQueries = new Array();
|
||||
$('#ajax_loader').html('<img src="{$smarty.const._PS_ADMIN_IMG_}ajax-loader.gif">');
|
||||
ajaxQuery = $.ajax({
|
||||
type: "POST",
|
||||
url: "index.php",
|
||||
data: {
|
||||
ajax: "1",
|
||||
token: "{$token|escape:'html':'UTF-8'}",
|
||||
syncImapMail: "1",
|
||||
ajax:"1",
|
||||
action:"syncImap",
|
||||
tab:"AdminCustomerThreads"
|
||||
},
|
||||
dataType : "json",
|
||||
success: function(jsonData) {
|
||||
jsonError = '';
|
||||
if (jsonData.hasError)
|
||||
{
|
||||
for (i=0;i < jsonData.errors.length;i++)
|
||||
jsonError = jsonError+'<li>'+jsonData.errors[i]+'</li>';
|
||||
$('#ajax_error').html('<ul>'+jsonError+'</ul>');
|
||||
$('#ajax_error').fadeIn();
|
||||
}
|
||||
else
|
||||
{
|
||||
jsonError = '<li>{l s='Sync success'}</li>';
|
||||
for (i=0;i < jsonData.errors.length;i++)
|
||||
jsonError = jsonError+'<li>'+jsonData.errors[i]+'</li>';
|
||||
$('#ajax_conf').html('<ul>'+jsonError+'</ul>');
|
||||
$('#ajax_conf').fadeIn();
|
||||
}
|
||||
|
||||
$('#ajax_loader').html('');
|
||||
},
|
||||
error: function(XMLHttpRequest, textStatus, errorThrown)
|
||||
{
|
||||
jAlert("TECHNICAL ERROR: unable to sync.\n\nDetails:\nError thrown: " + XMLHttpRequest + "\n" + 'Text status: ' + textStatus);
|
||||
}
|
||||
});
|
||||
ajaxQueries.push(ajaxQuery);
|
||||
|
||||
};
|
||||
</script>
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,60 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{if !$message.id_employee}
|
||||
{assign var="type" value="customer"}
|
||||
{else}
|
||||
{assign var="type" value="employee"}
|
||||
{/if}
|
||||
|
||||
<div class="message-item{if $initial}-initial-body{/if}">
|
||||
{if !$initial}
|
||||
<div class="message-avatar">
|
||||
<div class="avatar-md">
|
||||
{if $type == 'customer'}
|
||||
<i class="icon-user icon-3x"></i>
|
||||
{else}
|
||||
{if isset($current_employee->firstname)}<img src="{$message.employee_image}" alt="{$current_employee->firstname|escape:'html':'UTF-8'}" />{/if}
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
<div class="message-body">
|
||||
{if !$initial}
|
||||
<h4 class="message-item-heading">
|
||||
<i class="icon-mail-reply text-muted"></i>
|
||||
{if $type == 'customer'}
|
||||
{$message.customer_name|escape:'html':'UTF-8'}
|
||||
{else}
|
||||
{$message.employee_name|escape:'html':'UTF-8'}
|
||||
{/if}
|
||||
</h4>
|
||||
{/if}
|
||||
<span class="message-date"> <i class="icon-calendar"></i> - {dateFormat date=$message.date_add full=0} - <i class="icon-time"></i> {$message.date_add|substr:11:5}</span>
|
||||
{if isset($message.file_name)} <span class="message-product"> <i class="icon-link"></i> <a href="{$message.file_name|escape:'html':'UTF-8'}" target="_blank" rel="noopener noreferrer nofollow">{l s="Attachment" d='Admin.Catalog.Feature'}</a></span>{/if}
|
||||
{if isset($message.product_name)} <span class="message-attachment"> <i class="icon-book"></i> <a href="{$message.product_link|escape:'html':'UTF-8'}" target="_blank" rel="noopener noreferrer nofollow">{l s="Product" d='Admin.Global'} {$message.product_name|escape:'html':'UTF-8'} </a></span>{/if}
|
||||
<p class="message-item-text">{$message.message|escape:'html':'UTF-8'|nl2br}</p>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,76 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<form action="{$link->getAdminLink('AdminCustomerThreads', true, [], ['id_customer_thread' => $id_customer_thread|intval, 'viewcustomer_thread' => 1])|escape:'html':'UTF-8'}" method="post" enctype="multipart/form-data" class="form-horizontal">
|
||||
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-hidden="true">
|
||||
<div class="modal-dialog">
|
||||
<div class="modal-content">
|
||||
<div class="modal-header">
|
||||
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
||||
<h4 class="modal-title">{l s="Forward this discussion" d='Admin.Orderscustomers.Feature'}</h4>
|
||||
</div>
|
||||
<div class="modal-body">
|
||||
<div class="row row-margin-bottom">
|
||||
<label class="control-label col-lg-6">{l s='Forward this discussion to an employee:' d='Admin.Orderscustomers.Feature'}</label>
|
||||
<div class="col-lg-3">
|
||||
<select name="id_employee_forward">
|
||||
<option value="-1">{l s='-- Choose --' d='Admin.Actions'}</option>
|
||||
{foreach $employees as $employee}
|
||||
<option value="{$employee.id_employee}"> {Tools::substr($employee.firstname, 0, 1)}. {$employee.lastname}</option>
|
||||
{/foreach}
|
||||
<option value="0">{l s='Someone else' d='Admin.Orderscustomers.Feature'}</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div id="message_forward_email" class="row row-margin-bottom" style="display:none">
|
||||
<label class="control-label col-lg-3">{l s='Email' d='Admin.Global'}</label>
|
||||
<div class="col-lg-3">
|
||||
<input type="email" name="email" />
|
||||
</div>
|
||||
</div>
|
||||
<div id="message_forward" style="display:none;">
|
||||
<div class="row row-margin-bottom">
|
||||
<label class="control-label col-lg-3">{l s='Comment:' d='Admin.Orderscustomers.Feature'}</label>
|
||||
<div class="col-lg-7">
|
||||
<textarea name="message_forward" rows="6">{l s='You can add a comment here.' d='Admin.Orderscustomers.Help'}</textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="modal-footer">
|
||||
<button type="button" class="btn btn-default" data-dismiss="modal">{l s="Close"}</button>
|
||||
<button type="submit" class="btn btn-primary" name="submitForward" disabled="disabled"><i class="icon-mail-forward"></i> {l s="Forward" d='Admin.Orderscustomers.Feature'}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
<script type="text/javascript">
|
||||
$("select[name='id_employee_forward']").on('change', function() {
|
||||
if ($(this).val() != '-1')
|
||||
$("button[name='submitForward']").prop('disabled', false);
|
||||
else
|
||||
$("button[name='submitForward']").prop('disabled', 'disabled');
|
||||
});
|
||||
</script>
|
||||
@@ -0,0 +1,39 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<article class="timeline-item{if isset($timeline_item.alt)} alt{/if}">
|
||||
<div class="timeline-caption">
|
||||
<div class="timeline-panel arrow arrow-{$timeline_item.arrow}">
|
||||
<span class="timeline-icon" style="background-color:{$timeline_item.background_color|escape:'html':'UTF-8'};">
|
||||
<i class="{$timeline_item.icon}"></i>
|
||||
</span>
|
||||
<span class="timeline-date"><i class="icon-calendar"></i> {dateFormat date=$timeline_item.date full=0} - <i class="icon-time"></i> {$timeline_item.date|substr:11:5}</span>
|
||||
{if isset($timeline_item.id_order)}<a class="badge" href="#">{l s="Order #" d='Admin.Orderscustomers.Feature'}{$timeline_item.id_order|intval}</a><br/>{/if}
|
||||
<span>{$timeline_item.content|nl2br}</span>
|
||||
{if isset($timeline_item.see_more_link)}
|
||||
<br/><br/><a href="{$timeline_item.see_more_link|escape:'html':'UTF-8'}" class="btn btn-default _blank">{l s="See more" d='Admin.Orderscustomers.Feature'}</a>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
</article>
|
||||
@@ -0,0 +1,184 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/view/view.tpl"}
|
||||
{block name="override_tpl"}
|
||||
{include file="./modal.tpl" }
|
||||
<div class="panel">
|
||||
<div class="panel-heading">
|
||||
<i class="icon-comments"></i>
|
||||
{l s="Thread" d='Admin.Orderscustomers.Feature'}: <span class="badge">#{$id_customer_thread|intval}</span>
|
||||
{if isset($next_thread) && $next_thread}
|
||||
<a class="btn btn-default pull-right" href="{$next_thread.href|escape:'html':'UTF-8'}">
|
||||
{$next_thread.name} <i class="icon-forward"></i>
|
||||
</a>
|
||||
{/if}
|
||||
</div>
|
||||
<div class="well">
|
||||
<form action="{$link->getAdminLink('AdminCustomerThreads', true, [], ['id_customer_thread' => $id_customer_thread|intval, 'viewcustomer_thread' => 1])|escape:'html':'UTF-8'}" method="post" enctype="multipart/form-data" class="form-horizontal">
|
||||
{foreach $actions as $action}
|
||||
<button class="btn btn-default" name="{$action.name|escape:'html':'UTF-8'}" value="{$action.value|intval}">
|
||||
{if isset($action.icon)}<i class="{$action.icon|escape:'html':'UTF-8'}"></i>{/if}{$action.label}
|
||||
</button>
|
||||
{/foreach}
|
||||
<button class="btn btn-default" type="button" data-toggle="modal" data-target="#myModal">
|
||||
{l s="Forward this discussion to another employee" d='Admin.Orderscustomers.Feature'}
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="message-item-initial media">
|
||||
<a href="{if isset($customer->id)}{$link->getAdminLink('AdminCustomers', true, [], ['id_customer' => $customer->id|intval, 'viewcustomer' => 1])|escape:'html':'UTF-8'}{else}#{/if}" class="avatar-lg pull-left"><i class="icon-user icon-3x"></i></a>
|
||||
<div class="media-body">
|
||||
<div class="row">
|
||||
<div class="col-sm-6">
|
||||
{if isset($customer->firstname)}
|
||||
<h2>
|
||||
<a href="{$link->getAdminLink('AdminCustomers', true, [], ['id_customer' => $customer->id|intval, 'viewcustomer' => 1])|escape:'html':'UTF-8'}">
|
||||
{$customer->firstname|escape:'html':'UTF-8'} {$customer->lastname|escape:'html':'UTF-8'} <small>({$customer->email|escape:'html':'UTF-8'})</small>
|
||||
</a>
|
||||
</h2>
|
||||
{else}
|
||||
<h2>{$thread->email|escape:'html':'UTF-8'}</h2>
|
||||
{/if}
|
||||
{if isset($contact) && trim($contact) != ''}
|
||||
<span>{l s="To:" d='Admin.Orderscustomers.Feature'} </span><span class="badge">{$contact|escape:'html':'UTF-8'}</span>
|
||||
{/if}
|
||||
</div>
|
||||
{if isset($customer->firstname)}
|
||||
<div class="col-sm-6">
|
||||
<p>
|
||||
{if $count_ok}
|
||||
{l s='[1]%count%[/1] order(s) validated for a total amount of [2]%total%[/2]' html=true sprintf=['%count%' => $count_ok, '%total%' => $total_ok, '[1]' => '<span class="badge">', '[/1]' => '</span>', '[2]' => '<span class="badge badge-success">', '[/2]' => '</span>'] d='Admin.Orderscustomers.Feature'}
|
||||
{else}
|
||||
{l s="No orders validated for the moment" d='Admin.Orderscustomers.Feature'}
|
||||
{/if}
|
||||
</p>
|
||||
<p class="text-muted">{l s="Customer since: %s" sprintf=[{dateFormat date=$customer->date_add full=0}] d='Admin.Orderscustomers.Feature'}</p>
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-sm-12">
|
||||
{if !$first_message.id_employee}
|
||||
{include file="./message.tpl" message=$first_message initial=true}
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
{foreach $messages as $message}
|
||||
{include file="./message.tpl" message=$message initial=false}
|
||||
{/foreach}
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel">
|
||||
<h3 id="reply-form-title">{l s="Your answer to" d='Admin.Orderscustomers.Feature'} {if isset($customer->firstname)}{$customer->firstname|escape:'html':'UTF-8'} {$customer->lastname|escape:'html':'UTF-8'} {else} {$thread->email}{/if}</h3>
|
||||
<form action="{$link->getAdminLink('AdminCustomerThreads', true, [], ['id_customer_thread' => $thread->id|intval, 'viewcustomer_thread' => 1])|escape:'html':'UTF-8'}" method="post" enctype="multipart/form-data" class="form-horizontal">
|
||||
<div class="row">
|
||||
<div class="media">
|
||||
<div class="pull-left">
|
||||
<span class="avatar-md">{if isset($current_employee->firstname)}<img src="{$current_employee->getImage()}" alt="">{/if}</span>
|
||||
</div>
|
||||
<div class="media-body">
|
||||
<textarea id="reply_message" cols="30" rows="7" name="reply_message">{$PS_CUSTOMER_SERVICE_SIGNATURE|escape:'html':'UTF-8'}</textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel-footer">
|
||||
<!--
|
||||
<button type="button" class="btn btn-default dropdown-toggle" data-toggle="dropdown">
|
||||
<i class="icon-magic icon-2x"></i><br>
|
||||
{l s="Choose a template"}
|
||||
</button>
|
||||
-->
|
||||
<button class="btn btn-default pull-right" name="submitReply"><i class="process-icon-mail-reply"></i> {l s="Send"}</button>
|
||||
<input type="hidden" name="id_customer_thread" value="{$thread->id|intval}" />
|
||||
<input type="hidden" name="msg_email" value="{$thread->email}" />
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
{if count($timeline_items)}
|
||||
<div class="panel" id="orders-and-messages-block">
|
||||
<h3>
|
||||
<i class="icon-clock-o"></i>
|
||||
{l s="Orders and messages timeline" d='Admin.Orderscustomers.Feature'}
|
||||
</h3>
|
||||
<div class="timeline">
|
||||
{foreach $timeline_items as $dates}
|
||||
{foreach from=$dates key=date item=timeline_item}
|
||||
{include file="controllers/customer_threads/helpers/view/timeline_item.tpl" timeline_item=$timeline_item}
|
||||
{/foreach}
|
||||
{/foreach}
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
<script type="text/javascript">
|
||||
var timer;
|
||||
$(document).ready(function(){
|
||||
$('select[name=id_employee_forward]').change(function(){
|
||||
if ($(this).val() >= 0)
|
||||
$('#message_forward').show(400);
|
||||
else
|
||||
$('#message_forward').hide(200);
|
||||
if ($(this).val() == 0)
|
||||
$('#message_forward_email').show(200);
|
||||
else
|
||||
$('#message_forward_email').hide(200);
|
||||
});
|
||||
$('textarea[name=message_forward]').click(function(){
|
||||
if($(this).val() == '{l s='You can add a comment here.'}')
|
||||
{
|
||||
$(this).val('');
|
||||
}
|
||||
});
|
||||
timer = setInterval("markAsRead()", 3000);
|
||||
});
|
||||
|
||||
function markAsRead()
|
||||
{
|
||||
$.ajax({
|
||||
type: 'POST',
|
||||
url: 'ajax-tab.php',
|
||||
async: true,
|
||||
dataType: 'json',
|
||||
data: {
|
||||
controller: 'AdminCustomerThreads',
|
||||
action: 'markAsRead',
|
||||
token : '{$token|escape:'html':'UTF-8'}',
|
||||
id_thread: {$id_customer_thread}
|
||||
}
|
||||
});
|
||||
clearInterval(timer);
|
||||
timer = null;
|
||||
}
|
||||
</script>
|
||||
|
||||
{/block}
|
||||
|
||||
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,200 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{if !$email}
|
||||
<div class="panel">
|
||||
<h3>
|
||||
{if !empty($message.employee_name)}
|
||||
<i>{$employee_avatar}</i>
|
||||
({$message.employee_name}) - {$PS_SHOP_NAME}
|
||||
{else}
|
||||
<i class="icon-user"></i>
|
||||
{if !empty($message.id_customer)}
|
||||
<a href="index.php?tab=AdminCustomers&id_customer={$message.id_customer}&viewcustomer&token={getAdminToken tab='AdminCustomers'}" title="{l s='View customer' d='Admin.Orderscustomers.Feature'}">
|
||||
{$message.customer_name}
|
||||
</a>
|
||||
{else}
|
||||
{$message.email}
|
||||
{/if}
|
||||
{/if}
|
||||
</h3>
|
||||
<div class="infoCustomer">
|
||||
{if !empty($message.id_customer) && empty($message.id_employee)}
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Customer ID:' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd>
|
||||
<a href="index.php?tab=AdminCustomers&id_customer={$message.id_customer}&viewcustomer&token={getAdminToken tab='AdminCustomers'}" title="{l s='View customer' d='Admin.Orderscustomers.Feature'}">
|
||||
{$message.id_customer} <i class="icon-search"></i>
|
||||
</a>
|
||||
</dd>
|
||||
</dl>
|
||||
{/if}
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Sent on:' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd>{$message.date_add} </dd>
|
||||
</dl>
|
||||
{if empty($message.id_employee)}
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Browser:' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd>{$message.user_agent} </dd>
|
||||
</dl>
|
||||
{/if}
|
||||
{if !empty($message.file_name) && $file_name}
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='File attachment' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd>
|
||||
<a href="index.php?tab=AdminCustomerThreads&id_customer_thread={$message.id_customer_thread}&viewcustomer_thread&token={getAdminToken tab='AdminCustomerThreads'}&filename={$message.file_name}"
|
||||
title="{l s='View file' d='Admin.Orderscustomers.Feature'}">
|
||||
<i class="icon-search"></i>
|
||||
</a>
|
||||
</dd>
|
||||
</dl>
|
||||
{/if}
|
||||
{if !empty($message.id_order) && $is_valid_order_id && empty($message.id_employee)}
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Order #' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd><a href="index.php?tab=AdminOrders&id_order={$message.id_order}&vieworder&token={getAdminToken tab='AdminOrders'}" title="{l s='View order' d='Admin.Orderscustomers.Feature'}">{$message.id_order} <img src="../img/admin/search.gif" alt="{l s='View' d='Admin.Actions'}" /></a>
|
||||
</dd>
|
||||
</dl>
|
||||
{/if}
|
||||
{if !empty($message.id_product) && empty($message.id_employee)}
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Product #' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd><a href="{$link->getAdminLink('AdminProducts', true, ['id_product' => $message.id_product, 'updateproduct' => '1'])|escape:'html':'UTF-8'}" title="{l s='View order' d='Admin.Orderscustomers.Feature'}">{$message.id_product} <img src="../img/admin/search.gif" alt="{l s='View' d='Admin.Actions'}" /></a></dd>
|
||||
</dl>
|
||||
{/if}
|
||||
|
||||
<form class="form-inline" action="{$current|escape:'html':'UTF-8'}&token={$token|escape:'html':'UTF-8'}&id_customer_thread={$message.id_customer_thread}&viewcustomer_thread" method="post" >
|
||||
<input type="hidden" name="id_customer_message" value="{$message.id_customer_message}" />
|
||||
<div class="form-group">
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Subject:' d='Admin.Global'}</dt>
|
||||
<dd>
|
||||
<select name="id_contact" class="fixed-width-lg" onchange="this.form.submit();">
|
||||
{foreach $contacts as $contact}
|
||||
<option value="{$contact.id_contact}" {if $contact.id_contact == $message.id_contact}selected="selected"{/if}>
|
||||
{$contact.name}
|
||||
</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</dd>
|
||||
</dl>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
{else}
|
||||
<div class="infoEmployee">
|
||||
{if $id_employee}
|
||||
<a class="btn btn-default pull-right" href="{$thread_url}">
|
||||
{l s='View this thread' d='Admin.Orderscustomers.Feature'}
|
||||
</a>
|
||||
{/if}
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Sent by:' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd>
|
||||
{if !empty($message.customer_name)}
|
||||
{$message.customer_name} ({$message.email})
|
||||
{else}
|
||||
{$message.email}
|
||||
{/if}
|
||||
</dd>
|
||||
</dl>
|
||||
|
||||
{if !empty($message.id_customer) && empty($message.id_employee)}
|
||||
<!--<dl class="dl-horizontal">
|
||||
<dt>{l s='Customer ID:'}</dt>
|
||||
<dd>{$message.id_customer}</dd>
|
||||
</dl>-->
|
||||
{/if}
|
||||
|
||||
{if !empty($message.id_order) && empty($message.id_employee)}
|
||||
<!--<dl class="dl-horizontal">
|
||||
<dt>{l s='Order #'}:</dt>
|
||||
<dd>{$message.id_order}</dd>
|
||||
</dl>-->
|
||||
{/if}
|
||||
|
||||
{if !empty($message.id_product) && empty($message.id_employee)}
|
||||
<!--<dl class="dl-horizontal">
|
||||
<dt>{l s='Product #'}:</dt>
|
||||
<dd>{$message.id_product}</dd>
|
||||
</dl>-->
|
||||
{/if}
|
||||
|
||||
<!--<dl class="dl-horizontal">
|
||||
<dt>{l s='Subject:'}</dt>
|
||||
<dd>{$message.subject}</dd>
|
||||
</dl>-->
|
||||
{/if}
|
||||
{if !$email}
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Thread ID:' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd>{$message.id_customer_thread}</dd>
|
||||
</dl>
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Message ID:' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd>{$message.id_customer_message}</dd>
|
||||
</dl>
|
||||
{/if}
|
||||
<dl class="dl-horizontal">
|
||||
<dt>{l s='Message:' d='Admin.Orderscustomers.Feature'}</dt>
|
||||
<dd>{$message.message|escape:'html':'UTF-8'|nl2br}</dd>
|
||||
</dl>
|
||||
</div>
|
||||
{if !$email}
|
||||
</div>
|
||||
{if empty($message.id_employee)}
|
||||
<div class="panel">
|
||||
<button class="btn btn-default"
|
||||
onclick="$('#reply_to_{$message.id_customer_message}').show(500); $(this).parent().hide();">
|
||||
<i class="icon-mail-reply"></i> {l s='Reply to this message' d='Admin.Orderscustomers.Feature'}
|
||||
</button>
|
||||
</div>
|
||||
{/if}
|
||||
<div id="reply_to_{$message.id_customer_message}" style="display: none;">
|
||||
<div class="panel">
|
||||
<form action="{$current|escape:'html':'UTF-8'}&token={getAdminToken tab='AdminCustomerThreads'}&id_customer_thread={$message.id_customer_thread|intval}&viewcustomer_thread=1" method="post" enctype="multipart/form-data" class="form-horizontal">
|
||||
<div class="panel-heading">
|
||||
{l s='Please type your reply below:' d='Admin.Orderscustomers.Feature'}
|
||||
</div>
|
||||
<div class="row row-margin-bottom">
|
||||
<textarea class="col-lg-12" rows="6" name="reply_message">{$PS_CUSTOMER_SERVICE_SIGNATURE}</textarea>
|
||||
</div>
|
||||
<div class="row">
|
||||
<p class="pull-right">{l s='Your reply will be sent to:' d='Admin.Orderscustomers.Feature'} {$message.email}</p>
|
||||
</div>
|
||||
<div class="row row-margin-bottom">
|
||||
<input type="file" name="joinFile"/>
|
||||
</div>
|
||||
<div class="row">
|
||||
<button type="submit" class="btn btn-default" name="submitReply">
|
||||
<i class="icon-check"></i> {l s='Send my reply' d='Admin.Orderscustomers.Feature'}</button>
|
||||
<input type="hidden" name="id_customer_thread" value="{$message.id_customer_thread|intval}" />
|
||||
<input type="hidden" name="msg_email" value="{$message.email}" />
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
{/if}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,120 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<script>
|
||||
var dashboard_ajax_url = '{$link->getAdminLink('AdminDashboard')}';
|
||||
var adminstats_ajax_url = '{$link->getAdminLink('AdminStats')}';
|
||||
var no_results_translation = '{l s='No result' js=1}';
|
||||
var dashboard_use_push = '{$dashboard_use_push|intval}';
|
||||
var read_more = '{l s='Read more' js=1}';
|
||||
</script>
|
||||
|
||||
<div id="dashboard">
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
{if $warning}
|
||||
<div class="alert alert-warning">{$warning}</div>
|
||||
{/if}
|
||||
<div id="calendar" class="panel">
|
||||
<form action="{$action|escape}" method="post" id="calendar_form" name="calendar_form" class="form-inline">
|
||||
<div class="btn-group">
|
||||
<button type="button" name="submitDateDay" class="btn btn-default submitDateDay{if isset($preselect_date_range) && $preselect_date_range == 'day'} active{/if}">
|
||||
{l s='Day' d='Admin.Global'}
|
||||
</button>
|
||||
<button type="button" name="submitDateMonth" class="btn btn-default submitDateMonth{if (!isset($preselect_date_range) || !$preselect_date_range) || (isset($preselect_date_range) && $preselect_date_range == 'month')} active{/if}">
|
||||
{l s='Month' d='Admin.Global'}
|
||||
</button>
|
||||
<button type="button" name="submitDateYear" class="btn btn-default submitDateYear{if isset($preselect_date_range) && $preselect_date_range == 'year'} active{/if}">
|
||||
{l s='Year' d='Admin.Global'}
|
||||
</button>
|
||||
<button type="button" name="submitDateDayPrev" class="btn btn-default submitDateDayPrev{if isset($preselect_date_range) && $preselect_date_range == 'prev-day'} active{/if}">
|
||||
{l s='Day' d='Admin.Global'}-1
|
||||
</button>
|
||||
<button type="button" name="submitDateMonthPrev" class="btn btn-default submitDateMonthPrev{if isset($preselect_date_range) && $preselect_date_range == 'prev-month'} active{/if}">
|
||||
{l s='Month' d='Admin.Global'}-1
|
||||
</button>
|
||||
<button type="button" name="submitDateYearPrev" class="btn btn-default submitDateYearPrev{if isset($preselect_date_range) && $preselect_date_range == 'prev-year'} active{/if}">
|
||||
{l s='Year' d='Admin.Global'}-1
|
||||
</button>
|
||||
<!--
|
||||
<button type="submit" name="submitDateRealTime" class="hide btn btn-default submitDateRealTime {if $dashboard_use_push}active{/if}" value="{!$dashboard_use_push|intval}">
|
||||
{l s='Real Time'}
|
||||
</button> -->
|
||||
</div>
|
||||
<input type="hidden" name="datepickerFrom" id="datepickerFrom" value="{$date_from|escape}" class="form-control">
|
||||
<input type="hidden" name="datepickerTo" id="datepickerTo" value="{$date_to|escape}" class="form-control">
|
||||
<input type="hidden" name="preselectDateRange" id="preselectDateRange" value="{if isset($preselect_date_range)}{$preselect_date_range|escape:'html'}{/if}" class="form-control">
|
||||
<div class="form-group pull-right">
|
||||
<button id="datepickerExpand" class="btn btn-default" type="button">
|
||||
<i class="icon-calendar-empty"></i>
|
||||
<span class="hidden-xs">
|
||||
{l s='From' d='Admin.Global'}
|
||||
<strong class="text-info" id="datepicker-from-info">{$date_from|escape}</strong>
|
||||
{l s='To' d='Admin.Global'}
|
||||
<strong class="text-info" id="datepicker-to-info">{$date_to|escape}</strong>
|
||||
<strong class="text-info" id="datepicker-diff-info"></strong>
|
||||
</span>
|
||||
<i class="icon-caret-down"></i>
|
||||
</button>
|
||||
</div>
|
||||
{$calendar}
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-md-4 col-lg-3" id="hookDashboardZoneOne">
|
||||
{$hookDashboardZoneOne}
|
||||
</div>
|
||||
<div class="col-md-8 col-lg-7" id="hookDashboardZoneTwo">
|
||||
{$hookDashboardZoneTwo}
|
||||
<div id="dashaddons" class="row-margin-bottom">
|
||||
<a href="https://addons.prestashop.com/en/209-dashboards?utm_source=back-office&utm_medium=dashboard&utm_campaign=back-office-{$lang_iso|upper}&utm_content={if $host_mode}cloud{else}download{/if}" target="_blank" rel="noopener noreferrer nofollow">
|
||||
<i class="icon-plus"></i> {l s='Add more dashboard modules' d='Admin.Dashboard.Feature'}
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-md-12 col-lg-2">
|
||||
<section class="dash_news panel">
|
||||
<h3><i class="icon-rss"></i> {l s='PrestaShop News' d='Admin.Dashboard.Feature'}</h3>
|
||||
<div class="dash_news_content"></div>
|
||||
<div class="text-center"><h4><a href="http://www.prestashop.com/blog/" onclick="return !window.open(this.href);">{l s='Find more news' d='Admin.Dashboard.Feature'}</a></h4></div>
|
||||
</section>
|
||||
<section id="dash_version" class="visible-lg">
|
||||
<iframe style="overflow:hidden;border:none" src="{$new_version_url|escape:'html':'UTF-8'}" ></iframe>
|
||||
</section>
|
||||
<section class="dash_links panel">
|
||||
<h3><i class="icon-link"></i> {l s="We stay by your side!" d='Admin.Dashboard.Feature'}</h3>
|
||||
<dl>
|
||||
<dt><a href="{$help_center_link}" target="_blank" rel="noopener noreferrer nofollow">{l s="Help Center" d='Admin.Global'}</a></dt>
|
||||
<dd>{l s="Documentation, support, experts, training... PrestaShop and all of its community are here to guide you" d='Admin.Dashboard.Feature'}</dd>
|
||||
</dl>
|
||||
<dl>
|
||||
<dt><a href="https://addons.prestashop.com?utm_source=back-office&utm_medium=links&utm_campaign=addons-{$lang_iso}&utm_content=download17" target="_blank" rel="noopener noreferrer nofollow">{l s="PrestaShop Marketplace" d='Admin.Dashboard.Feature'}</a></dt>
|
||||
<dd>{l s="Traffic, conversion rate, customer loyalty... Increase your sales with all of the PrestaShop modules and themes" d='Admin.Dashboard.Feature'}</dd>
|
||||
</dl>
|
||||
</section>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,32 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
{extends file="helpers/form/form.tpl"}
|
||||
|
||||
{block name="input_row"}
|
||||
{$smarty.block.parent}
|
||||
{if $input.name == 'value'}
|
||||
{hook h="displayFeatureValueForm" id_feature_value=$feature_value->id|intval}
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,32 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
{extends file="helpers/form/form.tpl"}
|
||||
|
||||
{block name="input_row"}
|
||||
{$smarty.block.parent}
|
||||
{if $input.name == 'name'}
|
||||
{hook h="displayFeatureForm" id_feature=$form_id}
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,221 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/form/form.tpl"}
|
||||
|
||||
{block name="label"}
|
||||
{if $input['type'] == 'modules'}
|
||||
<div {if !$form_id}class="hide"{/if}>
|
||||
<label class="control-label col-lg-3">{l s='Authorized modules:' d='Admin.Shopparameters.Feature'}</label>
|
||||
</div>
|
||||
{elseif $input['type'] == 'group_discount_category'}
|
||||
<div {if !$form_id}class="hide"{/if}>
|
||||
{$smarty.block.parent}
|
||||
</div>
|
||||
{else}
|
||||
{$smarty.block.parent}
|
||||
{/if}
|
||||
{/block}
|
||||
|
||||
{block name="field"}
|
||||
{if $input['type'] == 'group_discount_category'}
|
||||
<div {if !$form_id}class="hide"{/if}>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
$("#group_discount_category").fancybox({
|
||||
beforeLoad: function () {
|
||||
$('#group_discount_category_fancybox').show();
|
||||
$('#group_discount_category_fancybox .tree-panel-heading-controls').css('margin', '-40px 0px 20px');
|
||||
$('#group_discount_category_fancybox .form-horizontal').css('padding', '10px');
|
||||
initFancyBox();
|
||||
},
|
||||
beforeClose: function () {
|
||||
$('#group_discount_category_fancybox').hide();
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
function deleteCategoryReduction(id_category)
|
||||
{
|
||||
$('#group_discount_category_table tr#'+id_category).fadeOut('slow', function () {
|
||||
$(this).remove();
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
function addCategoryReduction()
|
||||
{
|
||||
exist = false;
|
||||
$('.category_reduction').each( function () {
|
||||
if ($(this).attr('name') == 'category_reduction['+$('[name="id_category"]:checked').val()+']')
|
||||
{
|
||||
exist = true;
|
||||
jAlert('{l s='This category already exists for this group.' js=1 d='Admin.Shopparameters.Feature'}');
|
||||
return false;
|
||||
}
|
||||
});
|
||||
|
||||
if (exist)
|
||||
return;
|
||||
$.ajax({
|
||||
type:"POST",
|
||||
url: "ajax-tab.php",
|
||||
async: true,
|
||||
dataType: "json",
|
||||
data : {
|
||||
ajax: "1",
|
||||
token: "{getAdminToken tab='AdminGroups'}",
|
||||
controller: "AdminGroups",
|
||||
action: "addCategoryReduction",
|
||||
category_reduction: $('#category_reduction_fancybox').val() ,
|
||||
id_category: $('[name="id_category"]:checked').val()
|
||||
},
|
||||
success : function(jsonData) {
|
||||
if (jsonData.hasError)
|
||||
{
|
||||
var errors = '';
|
||||
for (error in jsonData.errors)
|
||||
//IE6 bug fix
|
||||
if (error != 'indexOf')
|
||||
errors += $('<div />').html(jsonData.errors[error]).text() + "\n";
|
||||
jAlert(errors);
|
||||
}
|
||||
else
|
||||
{
|
||||
$('#group_discount_category_table').append('<tr class="alt_row" id="'+jsonData.id_category+'"><td>'+jsonData.catPath+'</td><td>{l s='Discount' d='Admin.Global'}' + ' ' + jsonData.discount+'{l s='%'}</td><td><a href="#" onclick="deleteCategoryReduction('+jsonData.id_category+');" class="btn btn-default"><i class="icon-trash"></i> {l s='Delete' d='Admin.Actions'}</a></td></tr>');
|
||||
var input_hidden = document.createElement("input");
|
||||
input_hidden.setAttribute('type', 'hidden');
|
||||
input_hidden.setAttribute('value', jsonData.discount);
|
||||
input_hidden.setAttribute('name', 'category_reduction['+jsonData.id_category+']');
|
||||
input_hidden.setAttribute('class', 'category_reduction');
|
||||
|
||||
$('#group_discount_category_table tr#'+jsonData.id_category+' > td:last').append(input_hidden);
|
||||
$.fancybox.close();
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
function initFancyBox()
|
||||
{
|
||||
$('[name="id_category"]:checked').removeAttr('checked');
|
||||
$('#category_reduction_fancybox').val('0.00');
|
||||
}
|
||||
</script>
|
||||
|
||||
<div class="col-lg-8">
|
||||
<a class="btn btn-default" href="#group_discount_category_fancybox" id="group_discount_category">{l s='Add a category discount' d='Admin.Shopparameters.Feature'}</a>
|
||||
<table class="table" id="group_discount_category_table">
|
||||
{foreach $input['values'] key=key item=category }
|
||||
<tr class="alt_row" id="{$category.id_category}">
|
||||
<td>{$category.path}</td>
|
||||
<td>{l s='Discount: %.2f%%' sprintf=[$category.reduction] d='Admin.Shopparameters.Feature'}</td>
|
||||
<td>
|
||||
<a href="#" onclick="deleteCategoryReduction({$category.id_category});"class="btn btn-default">
|
||||
<i class="icon-trash"></i> {l s='Delete' d='Admin.Actions'}
|
||||
</a>
|
||||
<input type="hidden" class="category_reduction" name="category_reduction[{$category.id_category}]" value="{$category.reduction}">
|
||||
</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
</table>
|
||||
</div>
|
||||
<div id="group_discount_category_fancybox" class="bootstrap" style="display:none" >
|
||||
<div class="panel">
|
||||
<div class="panel-heading">
|
||||
<i class="icon-group"></i> {l s='New group category discount' d='Admin.Shopparameters.Feature'}
|
||||
</div>
|
||||
{$categoryTreeView}
|
||||
<div class="form-horizontal">
|
||||
<div class="alert alert-info">{l s='Caution: The discount applied to a category does not stack with the overall reduction but instead replaces it.' d='Admin.Shopparameters.Notification'}</div>
|
||||
<div class="alert alert-warning">{l s='Only products that have this category as the default category will be affected.' d='Admin.Shopparameters.Notification'}</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3" for="category_reduction_fancybox">{l s='Discount (%):' d='Admin.Shopparameters.Feature'}</label>
|
||||
<div class="col-lg-9">
|
||||
<input type="text" name="category_reduction_fancybox" id="category_reduction_fancybox" value="0.00" class="form-control" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-lg-12">
|
||||
<button type="button" onclick="addCategoryReduction();" class="btn btn-default pull-right">{l s='Add' d='Admin.Actions'}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
{elseif $input['type'] == 'modules'}
|
||||
<div {if !$form_id}class="hide"{/if}>
|
||||
<script type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
$('#authorized-modules').find('[value="0"]').click(function() {
|
||||
$(this).parent().parent().find('input[type=hidden]').attr('name', 'modulesBoxUnauth[]');
|
||||
});
|
||||
|
||||
$('#authorized-modules').find('[value="1"]').click(function() {
|
||||
$(this).parent().parent().find('input[type=hidden]').attr('name', 'modulesBoxAuth[]');
|
||||
});
|
||||
});
|
||||
</script>
|
||||
|
||||
<div class="col-lg-9" id="authorized-modules">
|
||||
{foreach $input['values']['auth_modules'] key=key item=module }
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-4"><img src="../modules/{$module->name|escape:'html':'UTF-8'}/logo.png" height="16" width="16" alt="{$module->displayName|escape:'html':'UTF-8'}" /> {$module->displayName|escape:'html':'UTF-8'}</label>
|
||||
<div class="input-group col-lg-8">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="{$module->name|escape:'html':'UTF-8'}" id="{$module->name|escape:'html':'UTF-8'}_on" value="1" checked="checked"/>
|
||||
<label for="{$module->name|escape:'html':'UTF-8'}_on">{l s='Yes' d='Admin.Global'}</label>
|
||||
<input type="radio" name="{$module->name|escape:'html':'UTF-8'}" id="{$module->name|escape:'html':'UTF-8'}_off" value="0"/>
|
||||
<label for="{$module->name|escape:'html':'UTF-8'}_off">{l s='No' d='Admin.Global'}</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
<input type="hidden" name="modulesBoxAuth[]" value="{$module->id|intval}"/>
|
||||
</div>
|
||||
</div>
|
||||
{/foreach}
|
||||
{foreach $input['values']['unauth_modules'] key=key item=module }
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-4"><img src="../modules/{$module->name|escape:'html':'UTF-8'}/logo.png" height="16" width="16" alt="{$module->displayName|escape:'html':'UTF-8'}"/> {$module->displayName|escape:'html':'UTF-8'}</label>
|
||||
<div class="input-group col-lg-8">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="{$module->name|escape:'html':'UTF-8'}" id="{$module->name|escape:'html':'UTF-8'}_on" value="1"/>
|
||||
<label for="{$module->name|escape:'html':'UTF-8'}_on">{l s='Yes' d='Admin.Global'}</label>
|
||||
<input type="radio" name="{$module->name|escape:'html':'UTF-8'}" id="{$module->name|escape:'html':'UTF-8'}_off" value="0" checked="checked"/>
|
||||
<label for="{$module->name|escape:'html':'UTF-8'}_off">{l s='No' d='Admin.Global'}</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
<input type="hidden" name="modulesBoxUnauth[]" value="{$module->id|intval}"/>
|
||||
</div>
|
||||
</div>
|
||||
{/foreach}
|
||||
</div>
|
||||
</div>
|
||||
{else}
|
||||
{$smarty.block.parent}
|
||||
{/if}
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,109 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<div class="panel">
|
||||
{if isset($header)}{$header}{/if}
|
||||
{if isset($nodes)}
|
||||
<ul id="{$id|escape:'html':'UTF-8'}" class="cattree tree">
|
||||
{$nodes}
|
||||
</ul>
|
||||
{/if}
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
var currentToken="{$token|@addslashes}";
|
||||
{if isset($use_checkbox) && $use_checkbox == true}
|
||||
function checkAllAssociatedCategories($tree)
|
||||
{
|
||||
$tree.find(":input[type=checkbox]").each(
|
||||
function()
|
||||
{
|
||||
$(this).prop("checked", true);
|
||||
$(this).parent().addClass("tree-selected");
|
||||
}
|
||||
);
|
||||
}
|
||||
|
||||
function uncheckAllAssociatedCategories($tree)
|
||||
{
|
||||
$tree.find(":input[type=checkbox]").each(
|
||||
function()
|
||||
{
|
||||
$(this).prop("checked", false);
|
||||
$(this).parent().removeClass("tree-selected");
|
||||
}
|
||||
);
|
||||
}
|
||||
{/if}
|
||||
{if isset($use_search) && $use_search == true}
|
||||
$("#{$id|escape:'html':'UTF-8'}-categories-search").bind("typeahead:selected", function(obj, datum) {
|
||||
$("#{$id|escape:'html':'UTF-8'}").find(":input").each(
|
||||
function()
|
||||
{
|
||||
if ($(this).val() == datum.id_category)
|
||||
{
|
||||
$(this).prop("checked", true);
|
||||
$(this).parent().addClass("tree-selected");
|
||||
$(this).parents("ul.tree").each(
|
||||
function()
|
||||
{
|
||||
$(this).children().children().children(".icon-folder-close")
|
||||
.removeClass("icon-folder-close")
|
||||
.addClass("icon-folder-open");
|
||||
$(this).show();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
);
|
||||
});
|
||||
{/if}
|
||||
$(document).ready(function () {
|
||||
$("#{$id|escape:'html':'UTF-8'}").tree("collapseAll");
|
||||
|
||||
{if isset($selected_categories)}
|
||||
{assign var=imploded_selected_categories value='","'|implode:$selected_categories}
|
||||
var selected_categories = new Array("{$imploded_selected_categories}");
|
||||
|
||||
$("#{$id|escape:'html':'UTF-8'}").find(":input").each(
|
||||
function()
|
||||
{
|
||||
if ($.inArray($(this).val(), selected_categories) != -1)
|
||||
{
|
||||
$(this).prop("checked", true);
|
||||
$(this).parent().addClass("tree-selected");
|
||||
$(this).parents("ul.tree").each(
|
||||
function()
|
||||
{
|
||||
$(this).children().children().children(".icon-folder-close")
|
||||
.removeClass("icon-folder-close")
|
||||
.addClass("icon-folder-open");
|
||||
$(this).show();
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
);
|
||||
{/if}
|
||||
});
|
||||
</script>
|
||||
@@ -0,0 +1,34 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<li class="tree-folder">
|
||||
<span class="tree-folder-name{if isset($node['disabled']) && $node['disabled'] == true} tree-folder-name-disable{/if}">
|
||||
<input type="radio" name="id_category" value="{$node['id_category']}"{if isset($node['disabled']) && $node['disabled'] == true} disabled="disabled"{/if} />
|
||||
<i class="icon-folder-close"></i>
|
||||
<label class="tree-toggler">{$node['name']|escape:'html':'UTF-8'}</label>
|
||||
</span>
|
||||
<ul class="tree">
|
||||
{$children}
|
||||
</ul>
|
||||
</li>
|
||||
@@ -0,0 +1,31 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<li class="tree-item{if isset($node['disabled']) && $node['disabled'] == true} tree-item-disable{/if}">
|
||||
<span class="tree-item-name">
|
||||
<input type="radio" name="id_category" value="{$node['id_category']}"{if isset($node['disabled']) && $node['disabled'] == true} disabled="disabled"{/if} />
|
||||
<i class="tree-dot"></i>
|
||||
<label class="tree-toggler">{$node['name']}</label>
|
||||
</span>
|
||||
</li>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,87 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
{extends file="helpers/view/view.tpl"}
|
||||
|
||||
{block name="override_tpl"}
|
||||
<div class="row">
|
||||
<div class="col-lg-6">
|
||||
<div class="panel">
|
||||
<h3><i class="icon-group"></i> {l s='Group information' d='Admin.Shopparameters.Feature'}</h3>
|
||||
<h2><i class="icon-group"></i> {$group->name[$language->id]}</h2>
|
||||
<div class="form-horizontal">
|
||||
<div class="form-group">
|
||||
<label class="col-lg-3 control-label">{l s='Discount:'}</label>
|
||||
<div class="col-lg-3"><p class="form-control-static">{l s='Discount: %.2f%%' sprintf=[$group->reduction] d='Admin.Shopparameters.Feature'}</p></div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-lg-3 control-label">{l s='Price display method:' d='Admin.Shopparameters.Feature'}</label>
|
||||
<div class="col-lg-3"><p class="form-control-static">{if $group->price_display_method}
|
||||
{l s='Tax excluded' d='Admin.Global'}
|
||||
{else}
|
||||
{l s='Tax included' d='Admin.Global'}
|
||||
{/if}</p></div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="col-lg-3 control-label">{l s='Show prices:' d='Admin.Shopparameters.Feature'}</label>
|
||||
<div class="col-lg-3"><p class="form-control-static">{if $group->show_prices}{l s='Yes' d='Admin.Global'}{else}{l s='No' d='Admin.Global'}{/if}</p></div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
<div class="panel">
|
||||
<h3><i class="icon-dollar"></i> {l s='Current category discount' d='Admin.Shopparameters.Feature'}</h3>
|
||||
{if !$categorieReductions}
|
||||
<div class="alert alert-warning">{l s='None' d='Admin.Global'}</div>
|
||||
{else}
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th><span class="title_box">{l s='Category' d='Admin.Global'}</span></th>
|
||||
<th><span class="title_box">{l s='Discount' d='Admin.Global'}</span></th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{foreach $categorieReductions key=key item=category }
|
||||
<tr class="alt_row">
|
||||
<td>{$category.path}</td>
|
||||
<td>{l s='Discount: %.2f%%' sprintf=[$category.reduction] d='Admin.Shopparameters.Feature'}</td>
|
||||
</tr>
|
||||
{/foreach}
|
||||
<tbody>
|
||||
</table>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-12">
|
||||
<h2>{l s='Members of this customer group' d='Admin.Shopparameters.Feature'}</h2>
|
||||
<p>{l s='Limited to the first 100 customers.' d='Admin.Shopparameters.Feature'} {l s='Please use filters to narrow your search.' d='Admin.Shopparameters.Feature'}</p>
|
||||
{$customerList}
|
||||
</div>
|
||||
</div>
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,132 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
|
||||
<div class="alert alert-danger">
|
||||
{l s='By default, all images settings are already installed in your store. Do not delete them, you will need it!' d='Admin.Design.Help'}
|
||||
</div>
|
||||
|
||||
{if isset($content)}
|
||||
{$content}
|
||||
{/if}
|
||||
|
||||
{if isset($display_move) && $display_move}
|
||||
<form action="{$current|escape:'html':'UTF-8'}&token={$token|escape:'html':'UTF-8'}" method="post" class="form-horizontal">
|
||||
<div class="panel">
|
||||
<h3>
|
||||
<i class="icon-picture"></i>
|
||||
{l s='Move images' d='Admin.Design.Feature'}
|
||||
</h3>
|
||||
<div class="alert alert-warning">
|
||||
<p>{l s='You can choose to keep your images stored in the previous system. There\'s nothing wrong with that.' d='Admin.Design.Notification'}</p>
|
||||
<p>{l s='You can also decide to move your images to the new storage system. In this case, click on the "%move_images_label%" button below. Please be patient. This can take several minutes.' d='Admin.Design.Notification' sprintf=['%move_images_label%' => {l s='Move images' d='Admin.Design.Feature'}]}</p>
|
||||
</div>
|
||||
<div class="alert alert-info">
|
||||
{l s='After moving all of your product images, set the "Use the legacy image filesystem" option above to "No" for best performance.' d='Admin.Design.Notification'}
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="col-lg-12 pull-right">
|
||||
<button type="submit" name="submitMoveImages{$table}" class="btn btn-default pull-right" onclick="return confirm('{l s='Are you sure?' d='Admin.Notifications.Warning'}');"><i class="process-icon-cogs"></i> {l s='Move images' d='Admin.Design.Feature'}</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{/if}
|
||||
|
||||
{if isset($display_regenerate)}
|
||||
|
||||
<form class="form-horizontal" action="{$current|escape:'html':'UTF-8'}&token={$token|escape:'html':'UTF-8'}" method="post">
|
||||
<div class="panel">
|
||||
<h3>
|
||||
<i class="icon-picture"></i>
|
||||
{l s='Regenerate thumbnails' d='Admin.Design.Feature'}
|
||||
</h3>
|
||||
|
||||
<div class="alert alert-warning">
|
||||
{l s='Be careful! Depending on the options selected, former manually uploaded thumbnails might be erased and replaced by automatically generated thumbnails.' d='Admin.Design.Notification'}<br />
|
||||
{l s='Also, regenerating thumbnails for all existing images can take several minutes, please be patient.' d='Admin.Design.Notification'}
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Select an image' d='Admin.Design.Feature'}</label>
|
||||
<div class="col-lg-9">
|
||||
<select name="type" onchange="changeFormat(this)">
|
||||
<option value="all">{l s='All' d='Admin.Global'}</option>
|
||||
{foreach $types AS $k => $type}
|
||||
<option value="{$k}">{$type}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{foreach $types AS $k => $type}
|
||||
<div class="form-group second-select format_{$k}" style="display:none;">
|
||||
<label class="control-label col-lg-3">{l s='Select a format' d='Admin.Design.Feature'}</label>
|
||||
<div class="col-lg-9 margin-form">
|
||||
<select name="format_{$k}">
|
||||
<option value="all">{l s='All' d='Admin.Global'}</option>
|
||||
{foreach $formats[$k] AS $format}
|
||||
<option value="{$format['id_image_type']}">{$format['name']}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
{/foreach}
|
||||
<script>
|
||||
function changeFormat(elt)
|
||||
{ldelim}
|
||||
$('.second-select').hide();
|
||||
$('.format_' + $(elt).val()).show();
|
||||
{rdelim}
|
||||
</script>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">
|
||||
{l s='Erase previous images' d='Admin.Design.Feature'}
|
||||
</label>
|
||||
<div class="col-lg-9">
|
||||
<span class="switch prestashop-switch fixed-width-lg">
|
||||
<input type="radio" name="erase" id="erase_on" value="1">
|
||||
<label for="erase_on" class="radioCheck">
|
||||
{l s='Yes' d='Admin.Global'}
|
||||
</label>
|
||||
<input type="radio" name="erase" id="erase_off" value="0" checked="checked">
|
||||
<label for="erase_off" class="radioCheck">
|
||||
{l s='No' d='Admin.Global'}
|
||||
</label>
|
||||
<a class="slide-button btn"></a>
|
||||
</span>
|
||||
<p class="help-block">
|
||||
{l s='Select "No" only if your server timed out and you need to resume the regeneration.' html=1 d='Admin.Design.Help'}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel-footer">
|
||||
<button type="submit" name="submitRegenerate{$table}" class="btn btn-default pull-right" onclick="return confirm('{l s='Are you sure?' d='Admin.Notifications.Warning'}');">
|
||||
<i class="process-icon-cogs"></i> {l s='Regenerate thumbnails' d='Admin.Design.Feature'}
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
{/if}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,146 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
{extends file="helpers/view/view.tpl"}
|
||||
{block name="override_tpl"}
|
||||
<script type="text/javascript">
|
||||
var errorEmpty = '{l s='Please name your data matching configuration in order to save it.' js=1}';
|
||||
var current = 0;
|
||||
function showTable(nb) {
|
||||
$('#btn_left').disabled = null;
|
||||
$('#btn_right').disabled = null;
|
||||
if (nb <= 0) {
|
||||
nb = 0;
|
||||
$('#btn_left').disabled = 'true';
|
||||
}
|
||||
if (nb >= {$nb_table} - 1) {
|
||||
nb = {$nb_table} - 1;
|
||||
$('#btn_right').disabled = 'true';
|
||||
}
|
||||
$('#table' + current).hide();
|
||||
current = nb;
|
||||
$('#table' + current).show();
|
||||
}
|
||||
$(document).ready(function() {
|
||||
var btn_save_import = $('span[class~="process-icon-save-import"]').parent();
|
||||
var btn_submit_import = $('#import');
|
||||
if (btn_save_import.length > 0 && btn_submit_import.length > 0) {
|
||||
btn_submit_import.closest('.form-group').hide();
|
||||
btn_save_import.find('span').removeClass('process-icon-save-import');
|
||||
btn_save_import.find('span').addClass('process-icon-save');
|
||||
btn_save_import.click(function(){
|
||||
btn_submit_import.before('<input type="hidden" name="' + btn_submit_import.attr("name") + '" value="1" />');
|
||||
$('#import_form').submit();
|
||||
});
|
||||
}
|
||||
showTable(current);
|
||||
});
|
||||
</script>
|
||||
<div id="container-customer" class="panel">
|
||||
<h3><i class="icon-list-alt"></i> {l s='Match your data'}</h3>
|
||||
<div class="alert alert-info">
|
||||
<p>{l s='Please match each column of your source file to one of the destination columns.'}</p>
|
||||
</div>
|
||||
<div class="form-horizontal">
|
||||
<div class="form-group" {if !$import_matchs}style="display:none"{/if}>
|
||||
<label class="control-label col-lg-3">{l s='Load a data matching configuration'}</label>
|
||||
<div id="selectDivImportMatchs" class="col-lg-7">
|
||||
<select id="valueImportMatchs">
|
||||
{foreach $import_matchs as $match}
|
||||
<option id="{$match.id_import_match}" value="{$match.match}">{$match.name}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</div>
|
||||
<div class="col-lg-2">
|
||||
<a id="loadImportMatchs" href="#" class="btn btn-default"><i class="icon-cogs"></i> {l s='Load'}</a>
|
||||
<a id="deleteImportMatchs" href="#" class="btn btn-default"><i class="icon-remove"></i> {l s='Delete' d='Admin.Actions'}</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3" for="newImportMatchs">{l s='Save your data matching configuration'}</label>
|
||||
<div class="col-lg-7">
|
||||
<input type="text" name="newImportMatchs" id="newImportMatchs" />
|
||||
</div>
|
||||
<div class="col-lg-2">
|
||||
<a id="saveImportMatchs" class="btn btn-default" href="#"><i class="icon-save"></i> {l s='Save' d='Admin.Actions'}</a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="error_duplicate_type" class="alert alert-warning" style="display:none;">
|
||||
{l s='Two columns cannot have the same type of values'}
|
||||
</div>
|
||||
<div id="required_column" class="alert alert-warning" style="display:none;">
|
||||
{l s='This column must be set:'} <span id="missing_column"> </span>
|
||||
</div>
|
||||
<form action="{$current|escape:'html':'UTF-8'}&token={$token|escape:'html':'UTF-8'}" method="post" id="import_form" name="import_form" class="form-horizontal">
|
||||
<input type="hidden" name="csv" value="{$fields_value.csv}" />
|
||||
<input type="hidden" name="regenerate" value="{$fields_value.regenerate}" />
|
||||
<input type="hidden" name="entity" value="{$fields_value.entity}" />
|
||||
<input type="hidden" name="iso_lang" value="{$fields_value.iso_lang}" />
|
||||
<input type="hidden" name="sendemail" value="{$fields_value.sendemail}" />
|
||||
{if $fields_value.truncate}
|
||||
<input type="hidden" name="truncate" value="1" />
|
||||
{/if}
|
||||
{if $fields_value.forceIDs}
|
||||
<input type="hidden" name="forceIDs" value="1" />
|
||||
{/if}
|
||||
{if $fields_value.match_ref}
|
||||
<input type="hidden" name="match_ref" value="1" />
|
||||
{/if}
|
||||
<input type="hidden" name="separator" value="{$fields_value.separator}" />
|
||||
<input type="hidden" name="multiple_value_separator" value="{$fields_value.multiple_value_separator}" />
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3" for="skip">{l s='Rows to skip'}</label>
|
||||
<div class="col-lg-9">
|
||||
<input class="fixed-width-sm" type="text" name="skip" id="skip" value="1" />
|
||||
<p class="help-block">{l s='Indicate how many of the first rows of your file should be skipped when importing the data. For instance set it to 1 if the first row of your file contains headers.'}</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="col-lg-12">
|
||||
{section name=nb_i start=0 loop=$nb_table step=1}
|
||||
{assign var=i value=$smarty.section.nb_i.index}
|
||||
{$data.$i}
|
||||
{/section}
|
||||
<button id="btn_left" type="button" class="btn btn-default pull-left" onclick="showTable(current - 1);">
|
||||
<i class="icon-chevron-sign-left"></i>
|
||||
</button>
|
||||
<button id="btn_right" type="button" class="btn btn-default pull-right" onclick="showTable(current + 1);">
|
||||
<i class="icon-chevron-sign-right"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="panel-footer">
|
||||
<button type="button" class="btn btn-default" onclick="window.history.back();">
|
||||
<i class="process-icon-cancel text-danger"></i>
|
||||
{l s='Cancel' d='Admin.Actions'}
|
||||
</button>
|
||||
<button id="import" name="import" type="submit" onclick="return (validateImportation(new Array({$res})));" class="btn btn-default pull-right">
|
||||
<i class="process-icon-ok text-success"></i>
|
||||
{l s='Import' d='Admin.Actions'}
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
{/block}
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../../');
|
||||
exit;
|
||||
@@ -0,0 +1,112 @@
|
||||
{**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*}
|
||||
<div class="modal-body">
|
||||
<div class="alert alert-warning" id="import_details_stop" style="display:none;">
|
||||
{l s="Aborting, please wait..." d="Admin.Advparameters.Notification"}
|
||||
</div>
|
||||
<p id="import_details_progressing">
|
||||
{l s="Importing your data..." d="Admin.Advparameters.Notification"}
|
||||
</p>
|
||||
<div class="alert alert-success" id="import_details_finished" style="display:none;">
|
||||
{l s="Data imported!" d="Admin.Advparameters.Notification"}
|
||||
<br/>
|
||||
{l s="Look at your listings to make sure it's all there as you wished." d="Admin.Advparameters.Notification"}
|
||||
</div>
|
||||
<div id="import_messages_div" style="max-height:250px; overflow:auto;">
|
||||
<div class="alert alert-danger" id="import_details_error" style="display:none;">
|
||||
{l s="Errors occurred:" d="Admin.Advparameters.Notification"}<br/><ul></ul>
|
||||
</div>
|
||||
<div class="alert alert-warning" id="import_details_post_limit" style="display:none;">
|
||||
{l s="Warning, the current import may require a PHP setting update, to allow more data to be transferred. If the current import stops before the end, you should increase your PHP \"post_max_size\" setting to [1]%size%[/1]MB at least, and try again." sprintf=[
|
||||
'[1]' => '<span id="import_details_post_limit_value">',
|
||||
'%size%' => '16MB',
|
||||
'[/1]' => '</span>'
|
||||
] d="Admin.Advparameters.Notification"}
|
||||
</div>
|
||||
<div class="alert alert-warning" id="import_details_warning" style="display:none;">
|
||||
{l s="Some errors were detected. Please check the details:" d="Admin.Advparameters.Notification"}<br/><ul></ul>
|
||||
</div>
|
||||
<div class="alert alert-info" id="import_details_info" style="display:none;">
|
||||
{l s="We made the following adjustments:" d="Admin.Advparameters.Notification"}<br/><ul></ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="import_validate_div" style="margin-top:17px;">
|
||||
<div class="pull-right" id="import_validation_details" default-value="{l s="Validating data..." d="Admin.Advparameters.Notification"}">
|
||||
|
||||
</div>
|
||||
<div class="progress active progress-striped" style="display: block; width: 100%">
|
||||
<div class="progress-bar progress-bar-info" role="progressbar" style="width: 0%" id="validate_progressbar_done">
|
||||
<span>{l s="[1]%percentage%[/1]% validated" sprintf=[
|
||||
'[1]' => '<span id="validate_progression_done">',
|
||||
'%percentage%' => '0',
|
||||
'[/1]' => '</span>'
|
||||
] d="Admin.Advparameters.Notification"}
|
||||
</span>
|
||||
</div>
|
||||
<div class="progress-bar progress-bar-info" role="progressbar" id="validate_progressbar_next" style="opacity: 0.5 ;width: 0%">
|
||||
<span class="sr-only">{l s="Processing next page..." d="Admin.Advparameters.Notification"}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="import_progress_div" style="display:none;">
|
||||
<div class="pull-right" id="import_progression_details" default-value="{l s="Importing your data..." d="Admin.Advparameters.Notification"}">
|
||||
|
||||
</div>
|
||||
<div class="progress active progress-striped" style="display: block; width: 100%">
|
||||
<div class="progress-bar progress-bar-info" role="progressbar" style="width: 0%" id="import_progressbar_done2">
|
||||
<span>{l s="Linking accessories..." d="Admin.Advparameters.Notification"}</span>
|
||||
</div>
|
||||
<div class="progress-bar progress-bar-success" role="progressbar" style="width: 0%" id="import_progressbar_done">
|
||||
<span>{l s="[1]%size%[/1]% imported" sprintf=[
|
||||
'[1]' => '<span id="import_progression_done">',
|
||||
'%size%' => '0',
|
||||
'[/1]' => '</span>'
|
||||
] d="Admin.Advparameters.Notification"}
|
||||
</span>
|
||||
</div>
|
||||
<div class="progress-bar progress-bar-success progress-bar-stripes active" role="progressbar" id="import_progressbar_next" style="opacity: 0.5 ;width: 0%">
|
||||
<span class="sr-only">{l s="Processing next page..." d="Admin.Advparameters.Notification"}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="modal-footer">
|
||||
<div class="input-group pull-right">
|
||||
<button type="button" class="btn btn-primary" tabindex="-1" id="import_continue_button" style="display: none;">
|
||||
{l s="Ignore warnings and continue?" d="Admin.Advparameters.Notification"}
|
||||
</button>
|
||||
|
||||
<button type="button" class="btn btn-default" tabindex="-1" id="import_stop_button">
|
||||
{l s="Abort import" d="Admin.Advparameters.Notification"}
|
||||
</button>
|
||||
|
||||
<button type="button" class="btn btn-success" data-dismiss="modal" tabindex="-1" id="import_close_button" style="display: none;">
|
||||
{l s="Close" d="Admin.Actions"}
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
35
admin-kalsport/themes/default/template/controllers/index.php
Normal file
35
admin-kalsport/themes/default/template/controllers/index.php
Normal file
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/**
|
||||
* Copyright since 2007 PrestaShop SA and Contributors
|
||||
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Open Software License (OSL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.md.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* https://opensource.org/licenses/OSL-3.0
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to https://devdocs.prestashop.com/ for more information.
|
||||
*
|
||||
* @author PrestaShop SA and Contributors <contact@prestashop.com>
|
||||
* @copyright Since 2007 PrestaShop SA and Contributors
|
||||
* @license https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
|
||||
*/
|
||||
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
header('Last-Modified: '.gmdate('D, d M Y H:i:s').' GMT');
|
||||
|
||||
header('Cache-Control: no-store, no-cache, must-revalidate');
|
||||
header('Cache-Control: post-check=0, pre-check=0', false);
|
||||
header('Pragma: no-cache');
|
||||
|
||||
header('Location: ../../../../../');
|
||||
exit;
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user