// Merge branch 'development' of https://github.com/PrestaShop/PrestaShop into bootstrap

Conflicts:
	.gitignore
	admin-dev/themes/default/css/admin.css
	admin-dev/themes/default/template/controllers/categories/helpers/list/list_header.tpl
	admin-dev/themes/default/template/controllers/customers/helpers/list/list_header.tpl
	admin-dev/themes/default/template/controllers/modules/list.tpl
	admin-dev/themes/default/template/controllers/modules/page.tpl
	admin-dev/themes/default/template/controllers/modules/tab_module_line.tpl
	admin-dev/themes/default/template/controllers/orders/_documents.tpl
	admin-dev/themes/default/template/controllers/orders/_shipping.tpl
	admin-dev/themes/default/template/controllers/orders/helpers/view/view.tpl
	admin-dev/themes/default/template/controllers/payment/helpers/view/view.tpl
	admin-dev/themes/default/template/controllers/payment/restrictions.tpl
	admin-dev/themes/default/template/controllers/products/images.tpl
	admin-dev/themes/default/template/controllers/products/informations.tpl
	admin-dev/themes/default/template/header.tpl
	admin-dev/themes/default/template/helpers/form/form.tpl
	admin-dev/themes/default/template/helpers/modules_list/list.tpl
	classes/Tools.php
	controllers/admin/AdminCartRulesController.php
	controllers/admin/AdminProductsController.php
	css/admin.css
This commit is contained in:
Kevin Granger
2013-07-24 17:01:23 +02:00
603 changed files with 14577 additions and 11364 deletions
+45 -2
View File
@@ -37,7 +37,6 @@ $height = Tools::getValue('height');
$id_employee = Tools::getValue('id_employee');
$id_lang = Tools::getValue('id_lang');
if (!isset($cookie->id_employee) || !$cookie->id_employee || $cookie->id_employee != $id_employee)
die(Tools::displayError());
@@ -47,6 +46,51 @@ if (!Validate::isModuleName($module))
if (!Tools::file_exists_cache($module_path = dirname(__FILE__).'/../modules/'.$module.'/'.$module.'.php'))
die(Tools::displayError());
$shop_id = '';
Shop::setContext(Shop::CONTEXT_ALL);
if (Context::getContext()->cookie->shopContext)
{
$split = explode('-', Context::getContext()->cookie->shopContext);
if (count($split) == 2)
{
if ($split[0] == 'g')
{
if (Context::getContext()->employee->hasAuthOnShopGroup($split[1]))
Shop::setContext(Shop::CONTEXT_GROUP, $split[1]);
else
{
$shop_id = Context::getContext()->employee->getDefaultShopID();
Shop::setContext(Shop::CONTEXT_SHOP, $shop_id);
}
}
else if (Shop::getShop($split[1]) && Context::getContext()->employee->hasAuthOnShop($split[1]))
{
$shop_id = $split[1];
Shop::setContext(Shop::CONTEXT_SHOP, $shop_id);
}
else
{
$shop_id = Context::getContext()->employee->getDefaultShopID();
Shop::setContext(Shop::CONTEXT_SHOP, $shop_id);
}
}
}
// Check multishop context and set right context if need
if (Shop::getContext())
{
if (Shop::getContext() == Shop::CONTEXT_SHOP && !Shop::CONTEXT_SHOP)
Shop::setContext(Shop::CONTEXT_GROUP, Shop::getContextShopGroupID());
if (Shop::getContext() == Shop::CONTEXT_GROUP && !Shop::CONTEXT_GROUP)
Shop::setContext(Shop::CONTEXT_ALL);
}
// Replace existing shop if necessary
if (!$shop_id)
Context::getContext()->shop = new Shop(Configuration::get('PS_SHOP_DEFAULT'));
elseif (Context::getContext()->shop->id != $shop_id)
Context::getContext()->shop = new Shop($shop_id);
require_once($module_path);
$graph = new $module();
@@ -57,4 +101,3 @@ if ($option)
$graph->create($render, $type, $width, $height, $layers);
$graph->draw();
+4 -4
View File
@@ -30,14 +30,14 @@ echo ' </div>
<div id="footer">
<div style="float:left;margin-left:10px;padding-top:6px">
<a href="http://www.prestashop.com/" target="_blank" style="font-weight:700;color:#666666">PrestaShop&trade; '._PS_VERSION_.'</a><br />
<span style="font-size:10px">'.translate('Load time:').' '.number_format(microtime(true) - $timerStart, 3, '.', '').'s</span>
<span style="font-size:10px">'.Translate::getAdminTranslation('Load time:').' '.number_format(microtime(true) - $timerStart, 3, '.', '').'s</span>
</div>
<div style="float:right;height:40px;margin-right:10px;line-height:38px;vertical-align:middle">';
if (strtoupper(Context::getContext()->language->iso_code) == 'FR') echo '<span style="color: #812143; font-weight: bold;">Questions / Renseignements / Formations :</span> <strong>+33 (0)1.40.18.30.04</strong> de 09h &agrave; 18h ';
echo ' | <a href="http://www.prestashop.com/en/contact_us/" target="_blank" class="footer_link">'.translate('Contact').'</a>
| <a href="http://forge.prestashop.com" target="_blank" class="footer_link">'.translate('Bug Tracker').'</a>
| <a href="http://www.prestashop.com/forums/" target="_blank" class="footer_link">'.translate('Forum').'</a>
echo ' | <a href="http://www.prestashop.com/en/contact_us/" target="_blank" class="footer_link">'.Translate::getAdminTranslation('Contact').'</a>
| <a href="http://forge.prestashop.com" target="_blank" class="footer_link">'.Translate::getAdminTranslation('Bug Tracker').'</a>
| <a href="http://www.prestashop.com/forums/" target="_blank" class="footer_link">'.Translate::getAdminTranslation('Forum').'</a>
</div>
</div>
</div>
+16 -9
View File
@@ -223,8 +223,16 @@ function checkPSVersion()
return $upgrader->checkPSVersion();
}
/**
* Deprecated since > 1.5.4.1
* Use Translate::getAdminTranslation($string) instead
*
* @param string $string
*/
function translate($string)
{
Tools::displayAsDeprecated();
global $_LANGADM;
if (!is_array($_LANGADM))
return str_replace('"', '&quot;', $string);
@@ -233,7 +241,6 @@ function translate($string)
return str_replace('"', '&quot;', stripslashes($str));
}
/**
* Returns a new Tab object
*
@@ -461,7 +468,7 @@ function runAdminTab($tab, $ajaxMode = false)
echo '<div class="path_bar">
<div id="help-button" class="floatr" style="display: none; font-family: Verdana; font-size: 10px; margin-right: 4px; margin-top: 4px;">
</div>
<a href="?token='.Tools::getAdminToken($tab.intval(Tab::getIdFromClassName($tab)).(int)Context::getContext()->employee->id).'">'.translate('Back Office').'</a>
<a href="?token='.Tools::getAdminToken($tab.intval(Tab::getIdFromClassName($tab)).(int)Context::getContext()->employee->id).'">'.Translate::getAdminTranslation('Back Office').'</a>
'.$bread.'</div>';
if (!$ajaxMode && Shop::isFeatureActive() && Shop::getContext() != Shop::CONTEXT_ALL && Context::getContext()->controller->multishop_context != Shop::CONTEXT_ALL)
@@ -470,10 +477,10 @@ function runAdminTab($tab, $ajaxMode = false)
if (Shop::getContext() == Shop::CONTEXT_GROUP)
{
$shop_group = new ShopGroup((int)Shop::getContextShopGroupID());
printf(translate('You are configuring your store for group shop %s'), '<b>'.$shop_group->name.'</b>');
printf(Translate::getAdminTranslation('You are configuring your store for group shop %s'), '<b>'.$shop_group->name.'</b>');
}
elseif (Shop::getContext() == Shop::CONTEXT_SHOP)
printf(translate('You are configuring your store for shop %s'), '<b>'.Context::getContext()->shop->name.'</b>');
printf(Translate::getAdminTranslation('You are configuring your store for shop %s'), '<b>'.Context::getContext()->shop->name.'</b>');
echo '</div>';
}
if (Validate::isLoadedObject($adminObj))
@@ -546,8 +553,8 @@ function runAdminTab($tab, $ajaxMode = false)
// we can display the correct url
// die(Tools::jsonEncode(array(translate('Invalid security token'),$url)));
die(Tools::jsonEncode(translate('Invalid security token')));
// die(Tools::jsonEncode(array(Translate::getAdminTranslation('Invalid security token'),$url)));
die(Tools::jsonEncode(Translate::getAdminTranslation('Invalid security token')));
}
else
{
@@ -559,17 +566,17 @@ function runAdminTab($tab, $ajaxMode = false)
if (false === strpos($url, '?token=') AND false === strpos($url, '&token='))
$url .= '&token='.$adminObj->token;
$message = translate('Invalid security token');
$message = Translate::getAdminTranslation('Invalid security token');
echo '<html><head><title>'.$message.'</title></head><body style="font-family:Arial,Verdana,Helvetica,sans-serif;background-color:#EC8686">
<div style="background-color:#FAE2E3;border:1px solid #000000;color:#383838;font-weight:700;line-height:20px;margin:0 0 10px;padding:10px 15px;width:500px">
<img src="../img/admin/error2.png" style="margin:-4px 5px 0 0;vertical-align:middle">
'.$message.'
</div>';
echo '<a href="'.htmlentities($url).'" method="get" style="float:left;margin:10px">
<input type="button" value="'.Tools::htmlentitiesUTF8(translate('I understand the risks and I really want to display this page')).'" style="height:30px;margin-top:5px" />
<input type="button" value="'.Tools::htmlentitiesUTF8(Translate::getAdminTranslation('I understand the risks and I really want to display this page')).'" style="height:30px;margin-top:5px" />
</a>
<a href="index.php" method="get" style="float:left;margin:10px">
<input type="button" value="'.Tools::htmlentitiesUTF8(translate('Take me out of here!')).'" style="height:40px" />
<input type="button" value="'.Tools::htmlentitiesUTF8(Translate::getAdminTranslation('Take me out of here!')).'" style="height:40px" />
</a>
</body></html>';
die;
+48 -1
View File
@@ -50,6 +50,53 @@ if (!Validate::isModuleName($module))
if (!Tools::file_exists_cache($module_path = dirname(__FILE__).'/../modules/'.$module.'/'.$module.'.php'))
die(Tools::displayError());
$shop_id = '';
Shop::setContext(Shop::CONTEXT_ALL);
if (Context::getContext()->cookie->shopContext)
{
$split = explode('-', Context::getContext()->cookie->shopContext);
if (count($split) == 2)
{
if ($split[0] == 'g')
{
if (Context::getContext()->employee->hasAuthOnShopGroup($split[1]))
Shop::setContext(Shop::CONTEXT_GROUP, $split[1]);
else
{
$shop_id = Context::getContext()->employee->getDefaultShopID();
Shop::setContext(Shop::CONTEXT_SHOP, $shop_id);
}
}
else if (Shop::getShop($split[1]) && Context::getContext()->employee->hasAuthOnShop($split[1]))
{
$shop_id = $split[1];
Shop::setContext(Shop::CONTEXT_SHOP, $shop_id);
}
else
{
$shop_id = Context::getContext()->employee->getDefaultShopID();
Shop::setContext(Shop::CONTEXT_SHOP, $shop_id);
}
}
}
// Check multishop context and set right context if need
if (Shop::getContext())
{
if (Shop::getContext() == Shop::CONTEXT_SHOP && !Shop::CONTEXT_SHOP)
Shop::setContext(Shop::CONTEXT_GROUP, Shop::getContextShopGroupID());
if (Shop::getContext() == Shop::CONTEXT_GROUP && !Shop::CONTEXT_GROUP)
Shop::setContext(Shop::CONTEXT_ALL);
}
// Replace existing shop if necessary
if (!$shop_id)
Context::getContext()->shop = new Shop(Configuration::get('PS_SHOP_DEFAULT'));
elseif (Context::getContext()->shop->id != $shop_id)
Context::getContext()->shop = new Shop($shop_id);
require_once($module_path);
$grid = new $module();
@@ -59,4 +106,4 @@ if ($option)
$grid->setOption($option);
$grid->create($render, $type, $width, $height, $start, $limit, $sort, $dir);
$grid->render();
$grid->render();
+35 -35
View File
@@ -41,7 +41,7 @@ echo '
<link type="text/css" rel="stylesheet" href="'._PS_JS_DIR_.'jquery/plugins/cluetip/jquery.cluetip.css" />
<link type="text/css" rel="stylesheet" href="themes/'.Context::getContext()->employee->bo_theme.'/css/admin.css" />
<link type="text/css" rel="stylesheet" href="'._PS_JS_DIR_.'jquery/plugins/chosen/jquery.chosen.css" />
<title>PrestaShop&trade; - '.translate('Administration panel').'</title>
<title>PrestaShop&trade; - '.Translate::getAdminTranslation('Administration panel').'</title>
<script type="text/javascript">
var helpboxes = '.Configuration::get('PS_HELPBOX').';
var roundMode = '.Configuration::get('PS_PRICE_ROUND_MODE').';
@@ -78,7 +78,7 @@ echo '
html = "";
nb_notifs = 0;
$.each(json.order, function(property, value) {
html += "<li>'.translate('A new order has been made on your shop.').'<br />'.translate('Order number : ').'<strong>#" + parseInt(value.id_order) + "</strong><br />'.translate('Total : ').'<strong>" + value.total_paid_real + "</strong><br />'.translate('From : ').'<strong>" + value.customer_name + "</strong><br /><a href=\"index.php?tab=AdminOrders&token='.Tools::getAdminTokenLite('AdminOrders').'&vieworder&id_order=" + parseInt(value.id_order) + "\">'.translate('Click here to see that order').'</a></li>";
html += "<li>'.Translate::getAdminTranslation('A new order has been made on your shop.').'<br />'.Translate::getAdminTranslation('Order number : ').'<strong>#" + parseInt(value.id_order) + "</strong><br />'.Translate::getAdminTranslation('Total : ').'<strong>" + value.total_paid_real + "</strong><br />'.Translate::getAdminTranslation('From : ').'<strong>" + value.customer_name + "</strong><br /><a href=\"index.php?tab=AdminOrders&token='.Tools::getAdminTokenLite('AdminOrders').'&vieworder&id_order=" + parseInt(value.id_order) + "\">'.Translate::getAdminTranslation('Click here to see that order').'</a></li>";
});
if (html != "")
@@ -99,7 +99,7 @@ echo '
html = "";
nb_notifs = 0;
$.each(json.customer, function(property, value) {
html += "<li>'.translate('A new customer registered on your shop.').'<br />'.translate('Customer name : ').'<strong>" + value.customer_name + "</strong><br /><a href=\"index.php?tab=AdminCustomers&token='.Tools::getAdminTokenLite('AdminCustomers').'&viewcustomer&id_customer=" + parseInt(value.id_customer) + "\">'.translate('Click here to see that customer').'</a></li>";
html += "<li>'.Translate::getAdminTranslation('A new customer registered on your shop.').'<br />'.Translate::getAdminTranslation('Customer name : ').'<strong>" + value.customer_name + "</strong><br /><a href=\"index.php?tab=AdminCustomers&token='.Tools::getAdminTokenLite('AdminCustomers').'&viewcustomer&id_customer=" + parseInt(value.id_customer) + "\">'.Translate::getAdminTranslation('Click here to see that customer').'</a></li>";
});
if (html != "")
{
@@ -121,7 +121,7 @@ echo '
html = "";
nb_notifs = 0;
$.each(json.customer_message, function(property, value) {
html += "<li>'.translate('A new message posted on your shop.').'<br />'.translate('From : ').'<strong>" + value.customer_name + "</strong><br /><a href=\"index.php?tab=AdminCustomerThreads&token='.Tools::getAdminTokenLite('AdminCustomerThreads').'&viewcustomer_thread&id_customer_thread=" + parseInt(value.id_customer_thread) + "\">'.translate('Click here to see that message').'</a></li>";
html += "<li>'.Translate::getAdminTranslation('A new message posted on your shop.').'<br />'.Translate::getAdminTranslation('From : ').'<strong>" + value.customer_name + "</strong><br /><a href=\"index.php?tab=AdminCustomerThreads&token='.Tools::getAdminTokenLite('AdminCustomerThreads').'&viewcustomer_thread&id_customer_thread=" + parseInt(value.id_customer_thread) + "\">'.Translate::getAdminTranslation('Click here to see that message').'</a></li>";
});
if (html != "")
@@ -149,14 +149,14 @@ echo '
if (Shop::isFeatureActive())
{
if (Shop::getContext() == Shop::CONTEXT_ALL)
$youEditFieldFor = translate('A modification of this field will be applied for all shops');
$youEditFieldFor = Translate::getAdminTranslation('A modification of this field will be applied for all shops');
elseif (Shop::getContext() == Shop::CONTEXT_GROUP)
{
$shop_group = new ShopGroup((int)Shop::getContextShopGroupID());
$youEditFieldFor = sprintf(translate('A modification of this field will be applied for all shops of group %s'), '<b>'.$shop_group->name.'</b>');
$youEditFieldFor = sprintf(Translate::getAdminTranslation('A modification of this field will be applied for all shops of group %s'), '<b>'.$shop_group->name.'</b>');
}
else
$youEditFieldFor = sprintf(translate('A modification of this field will be applied for the shop %s'), '<b>'.Context::getContext()->shop->name.'</b>');
$youEditFieldFor = sprintf(Translate::getAdminTranslation('A modification of this field will be applied for the shop %s'), '<b>'.Context::getContext()->shop->name.'</b>');
echo 'hints.html(hints.html()+\'<br /><span class="red">'.addslashes($youEditFieldFor).'</span>\');';
}
@@ -202,10 +202,10 @@ echo ' var html = "";
{
echo '<div id="orders_notif" class="notifs"><span id="orders_notif_number_wrapper" class="number_wrapper"><span id="orders_notif_value">0</span></span>
<div id="orders_notif_wrapper" class="notifs_wrapper">
<h3>'.translate('Last orders').'</h3>
<p class="no_notifs">'.translate('No new orders has been made on your shop').'</p>
<h3>'.Translate::getAdminTranslation('Last orders').'</h3>
<p class="no_notifs">'.Translate::getAdminTranslation('No new orders has been made on your shop').'</p>
<ul id="list_orders_notif"></ul>
<p><a href="index.php?tab=AdminOrders&token='.Tools::getAdminTokenLite('AdminOrders').'">'.translate('Show all orders').'</a></p>
<p><a href="index.php?tab=AdminOrders&token='.Tools::getAdminTokenLite('AdminOrders').'">'.Translate::getAdminTranslation('Show all orders').'</a></p>
</div>
</div>';
}
@@ -213,10 +213,10 @@ echo ' var html = "";
{
echo '<div id="customers_notif" class="notifs notifs_alternate"><span id="customers_notif_number_wrapper" class="number_wrapper"><span id="customers_notif_value">0</span></span>
<div id="customers_notif_wrapper" class="notifs_wrapper">
<h3>'.translate('Last customers').'</h3>
<p class="no_notifs">'.translate('No new customers registered on your shop').'</p>
<h3>'.Translate::getAdminTranslation('Last customers').'</h3>
<p class="no_notifs">'.Translate::getAdminTranslation('No new customers registered on your shop').'</p>
<ul id="list_customers_notif"></ul>
<p><a href="index.php?tab=AdminCustomers&token='.Tools::getAdminTokenLite('AdminCustomers').'">'.translate('Show all customers').'</a></p>
<p><a href="index.php?tab=AdminCustomers&token='.Tools::getAdminTokenLite('AdminCustomers').'">'.Translate::getAdminTranslation('Show all customers').'</a></p>
</div>
</div>';
}
@@ -224,26 +224,26 @@ echo ' var html = "";
{
echo '<div id="customer_messages_notif" class="notifs"><span id="customer_messages_notif_number_wrapper" class="number_wrapper"><span id="customer_messages_notif_value">0</span></span>
<div id="customer_messages_notif_wrapper" class="notifs_wrapper">
<h3>'.translate('Last messages').'</h3>
<p class="no_notifs">'.translate('No new messages posted on your shop').'</p>
<h3>'.Translate::getAdminTranslation('Last messages').'</h3>
<p class="no_notifs">'.Translate::getAdminTranslation('No new messages posted on your shop').'</p>
<ul id="list_customer_messages_notif"></ul>
<p><a href="index.php?tab=AdminCustomerThreads&token='.Tools::getAdminTokenLite('AdminCustomerThreads').'">'.translate('Show all messages').'</a></p>
<p><a href="index.php?tab=AdminCustomerThreads&token='.Tools::getAdminTokenLite('AdminCustomerThreads').'">'.Translate::getAdminTranslation('Show all messages').'</a></p>
</div>
</div>';
}
echo '</div>
echo '</div>
<div id="employee_box">
<div id="employee_infos">
<div class="employee_name">'.translate('Welcome,').' <strong>'.Context::getContext()->employee->firstname.'&nbsp'.Context::getContext()->employee->lastname.'</strong></div>
<div class="employee_name">'.Translate::getAdminTranslation('Welcome,').' <strong>'.Context::getContext()->employee->firstname.'&nbsp'.Context::getContext()->employee->lastname.'</strong></div>
<div class="clear"></div>
<ul id="employee_links">
<li><a href="'.htmlentities(Context::getContext()->link->getAdminLink('AdminEmployees'), ENT_COMPAT, 'UTF-8').'&id_employee={$employee->id}&amp;updateemployee">'.translate('My preferences').'</a></li>
<li><a href="'.htmlentities(Context::getContext()->link->getAdminLink('AdminEmployees'), ENT_COMPAT, 'UTF-8').'&id_employee={$employee->id}&amp;updateemployee">'.Translate::getAdminTranslation('My preferences').'</a></li>
<li class="separator">&nbsp;</li>
<li><a id="header_logout" href="index.php?logout">'.translate('logout').'</a></li>
<li><a id="header_logout" href="index.php?logout">'.Translate::getAdminTranslation('logout').'</a></li>
</ul>';
if (defined(_PS_BASE_URL_))
echo '<a href="'._PS_BASE_URL_.'" id="header_foaccess" target="_blank" title="'.translate('View my shop').'">'.translate('View my shop').'</a>';
echo '<a href="'._PS_BASE_URL_.'" id="header_foaccess" target="_blank" title="'.Translate::getAdminTranslation('View my shop').'">'.Translate::getAdminTranslation('View my shop').'</a>';
echo '</div>
</div>
@@ -252,18 +252,18 @@ echo ' var html = "";
<form method="post" action="index.php?controller=AdminSearch&amp;token='.Tools::getAdminTokenLite('AdminSearch').'">
<input type="text" name="bo_query" id="bo_query" value="'.Tools::safeOutput(Tools::stripslashes(Tools::getValue('bo_query'))).'" />
<select name="bo_search_type" id="bo_search_type" class="chosen no-search">
<option value="0">'.translate('everywhere').'</option>
<option value="1" '.(Tools::getValue('bo_search_type') == 1 ? 'selected="selected"' : '').'>'.translate('catalog').'</option>
<optgroup label="'.translate('customers').':">
<option value="2" '.(Tools::getValue('bo_search_type') == 2 ? 'selected="selected"' : '').'>'.translate('by name').'</option>
<option value="6" '.(Tools::getValue('bo_search_type') == 6 ? 'selected="selected"' : '').'>'.translate('by ip address').'</option>
<option value="0">'.Translate::getAdminTranslation('everywhere').'</option>
<option value="1" '.(Tools::getValue('bo_search_type') == 1 ? 'selected="selected"' : '').'>'.Translate::getAdminTranslation('catalog').'</option>
<optgroup label="'.Translate::getAdminTranslation('customers').':">
<option value="2" '.(Tools::getValue('bo_search_type') == 2 ? 'selected="selected"' : '').'>'.Translate::getAdminTranslation('by name').'</option>
<option value="6" '.(Tools::getValue('bo_search_type') == 6 ? 'selected="selected"' : '').'>'.Translate::getAdminTranslation('by ip address').'</option>
</optgroup>
<option value="3" '.(Tools::getValue('bo_search_type') == 3 ? 'selected="selected"' : '').'>'.translate('orders').'</option>
<option value="4" '.(Tools::getValue('bo_search_type') == 4 ? 'selected="selected"' : '').'>'.translate('invoices').'</option>
<option value="5" '.(Tools::getValue('bo_search_type') == 5 ? 'selected="selected"' : '').'>'.translate('carts').'</option>
<option value="7" '.(Tools::getValue('bo_search_type') == 7 ? 'selected="selected"' : '').'>'.translate('modules').'</option>
<option value="3" '.(Tools::getValue('bo_search_type') == 3 ? 'selected="selected"' : '').'>'.Translate::getAdminTranslation('orders').'</option>
<option value="4" '.(Tools::getValue('bo_search_type') == 4 ? 'selected="selected"' : '').'>'.Translate::getAdminTranslation('invoices').'</option>
<option value="5" '.(Tools::getValue('bo_search_type') == 5 ? 'selected="selected"' : '').'>'.Translate::getAdminTranslation('carts').'</option>
<option value="7" '.(Tools::getValue('bo_search_type') == 7 ? 'selected="selected"' : '').'>'.Translate::getAdminTranslation('modules').'</option>
</select>
<input type="submit" id="bo_search_submit" class="button" value="'.translate('Search').'"/>
<input type="submit" id="bo_search_submit" class="button" value="'.Translate::getAdminTranslation('Search').'"/>
</form>
</div>
<div id="header_quick">
@@ -277,7 +277,7 @@ echo ' var html = "";
}
</script>
<select onchange="quickSelect(this);" id="quick_select">
<option value="0">'.translate('Quick Access').'</option>';
<option value="0">'.Translate::getAdminTranslation('Quick Access').'</option>';
foreach (QuickAccess::getQuickAccesses(Context::getContext()->language->id) AS $quick)
{
preg_match('/controller=(.+)(&.+)?$/', $quick['link'], $adminTab);
@@ -342,8 +342,8 @@ echo '
<div id="main">
<div id="content">'
.(file_exists(_PS_ADMIN_DIR_.'/../install') ? '<div style="background-color: #FFEBCC;border: 1px solid #F90;line-height: 20px;margin: 0px 0px 10px;padding: 10px 20px;">'
.translate('For security reasons, you must also:').' '.
translate('delete the /install folder').
.Translate::getAdminTranslation('For security reasons, you must also:').' '.
Translate::getAdminTranslation('delete the /install folder').
'</div>' : '').'
';
if(defined('_PS_MODE_DEV_') && _PS_MODE_DEV_)
@@ -352,7 +352,7 @@ echo '
if (Shop::isFeatureActive() && Context::getContext()->controller->multishop_context != Shop::CONTEXT_ALL)
{
echo '<div class="multishop_toolbar">
<span class="text_multishop">'.translate('Multistore configuration for').'</span>'.
<span class="text_multishop">'.Translate::getAdminTranslation('Multistore configuration for').'</span>'.
Helper::renderShopList();
echo '</div>';
}
+352 -15
View File
@@ -2,6 +2,10 @@
/*LIST*/
/*FORM*/
/*BUTTON*/
/*HEADER*/
/* Portrait orientation targeting */
/* Portrait orientation targeting */
/*MENU*/
/*SEPARATION*/
/*TABLE*/
/*UI ACCORDEON*/
@@ -23,10 +27,14 @@
/*TAB MODULES LIST*/
/******** ie7 ******/
/*MODULE POSITION*/
/*FOOTER*/
/*DASHBOARD*/
/******** CREATE AN ORDER **************/
/************** SCENE *****************/ }
#nobootstrap body {
font-family: Arial, Helvetica, sans-serif; }
#nobootstrap h1, #nobootstrap h2, #nobootstrap h3, #nobootstrap h4 {
font-family: Arial, Helvetica, sans-serif;
margin-bottom: .5em;
line-height: 1.4em; }
#nobootstrap h2 {
@@ -98,7 +106,11 @@
color: #123456;
margin: 2px;
padding: 2px; }
#nobootstrap .button, #nobootstrap .btn {
#nobootstrap .icon {
vertical-align: middle; }
#nobootstrap .icon-top {
vertical-align: top; }
#nobootstrap .button {
background: #e3e3e3 url("../img/bg-button-degrade.png") repeat-x scroll left top;
background: -moz-linear-gradient(center top, #f9f9f9, #e3e3e3) repeat scroll 0 0 transparent;
background: -webkit-gradient(linear, center top, center bottom, from(#f9f9f9), to(#e3e3e3)) repeat scroll 0 0 transparent;
@@ -116,22 +128,321 @@
vertical-align: middle;
white-space: nowrap;
text-shadow: 0 1px 0 #fff; }
#nobootstrap .button[disabled=disabled], #nobootstrap .btn[disabled=disabled] {
#nobootstrap .button[disabled=disabled] {
color: #8C8C8C; }
#nobootstrap .button.bt-icon, #nobootstrap .btn.bt-icon {
#nobootstrap .button.bt-icon {
display: inline-block;
margin-bottom: 7px; }
#nobootstrap .button.bt-icon span, #nobootstrap .btn.bt-icon span {
#nobootstrap .button.bt-icon span {
padding-left: 5px; }
#nobootstrap input.button[disabled=disabled]:hover, #nobootstrap input.btn[disabled=disabled]:hover {
#nobootstrap input.button[disabled=disabled]:hover {
background-color: #FFF6D3; }
#nobootstrap .button:hover, #nobootstrap .btn:hover {
#nobootstrap .button:hover {
border: 1px solid #939393; }
#nobootstrap .button:active, #nobootstrap .btn:active {
#nobootstrap .button:active {
border: 1px solid #939393; }
#nobootstrap .button.export-csv span, #nobootstrap .btn.export-csv {
#nobootstrap .button.export-csv span {
background: transparent url("../img/export-csv.png") no-repeat scroll left top;
padding: 1px 0 1px 20px; }
#nobootstrap #top_container {
margin: 0;
padding: 0; }
#nobootstrap #header {
background-color: #394049;
height: 90px; }
@media screen and (orientation: portrait) {
#nobootstrap #header {
min-width: 1250px; } }
@media screen and (orientation: landscape) {
#nobootstrap #header {
min-width: 1250px; } }
#nobootstrap #header #header_infos {
position: relative;
margin: 0;
padding: 0;
height: 60px; }
#nobootstrap #header #header_shopname {
float: left;
margin: 10px 15px 0 10px; }
#nobootstrap #header #employee_box {
float: right;
display: block; }
#nobootstrap #header #employee_infos {
display: block;
margin: 5px 15px 0 10px; }
#nobootstrap #header #employee_infos a {
color: #BABABA;
text-transform: capitalize;
margin-right: 5px; }
#nobootstrap #header #employee_infos a:hover {
color: #fff; }
#nobootstrap #header #employee_infos .employee_name {
float: left;
color: #fff;
padding: 0 20px 0 0; }
#nobootstrap #header .separator {
background: transparent url("../img/separator.png") no-repeat scroll center top;
height: 19px;
width: 16px;
margin-right: 5px; }
#nobootstrap #header ul#employee_links {
list-style: none;
display: block;
text-align: left; }
#nobootstrap #header ul#employee_links li {
display: inline;
line-height: 20px; }
#nobootstrap #header #header_infos #header_shopname span {
display: block;
font-size: 24px;
height: 28px;
overflow: hidden;
margin: 0;
color: #fff;
text-shadow: 0 1px 0 #000000; }
#nobootstrap #header #header_infos a#header_logout {
background: transparent url("../img/logout.png") no-repeat scroll left top;
padding-left: 20px;
color: #bababa; }
#nobootstrap #header #header_infos a#header_logout:hover {
color: #fff; }
#nobootstrap #header #header_infos #header_logout a span {
color: #bababa; }
#nobootstrap #header #header_infos #header_foaccess {
text-decoration: none;
color: #bababa; }
#nobootstrap #header #header_infos #header_foaccess a {
color: #bababa !important; }
#nobootstrap #header #header_infos a#header_foaccess:hover {
color: #fff; }
#nobootstrap #header #header_search {
background-color: #fff;
border: 2px solid #000;
float: left;
margin-top: 15px;
position: relative;
height: 25px;
box-shadow: 0 1px 0 #666666; }
#nobootstrap #header #header_search #bo_query {
font: 13px Arial,sans-serif;
float: left;
background: none repeat scroll 0 0 transparent;
border: none;
box-shadow: none;
padding: 5px 0px 5px 4px;
width: 160px; }
#nobootstrap #header #header_search #bo_search_type_chzn {
font-size: 13px;
float: left;
margin: 0 23px 0 0;
padding: 0 4px;
vertical-align: middle;
width: 80px !important;
height: 27px;
border: none; }
#nobootstrap #header #header_search #bo_search_type_chzn.chzn-container-single .chzn-single {
box-shadow: none;
border-radius: 0px;
border: none;
border-left: 1px dotted #ccc; }
#nobootstrap #header #header_search #bo_search_submit {
background: url("../img/icon-search2.png") no-repeat scroll center;
border: none;
width: 27px;
height: 25px;
float: left;
font-weight: normal;
margin: 0;
padding: 0;
cursor: pointer;
text-indent: -9999em;
position: absolute;
right: 0;
display: block;
border-left: 1px solid #3079ED;
border-radius: 0px;
/*hacking ie7font-size: 0!ie7; color: transparent!ie;*/ }
#nobootstrap #header #header_quick {
float: right;
display: block;
margin-top: 15px; }
#nobootstrap #header #header_quick #quick_select_chzn {
font-size: 13px;
margin: 0 10px 0 0;
padding: 0px 0 4px; }
#nobootstrap #header #header_myaccount {
background: url("../img/bg-lang.png") no-repeat;
display: block;
float: right;
height: 16px;
margin: 8px 1px 0 0;
width: 16px; }
#nobootstrap .path_bar {
display: none; }
#nobootstrap #notifs_icon_wrapper {
float: left;
position: relative;
margin: 15px 10px 0;
width: 95px; }
#nobootstrap .notifs {
float: left;
position: relative;
cursor: pointer;
margin: 0;
padding: 5px;
width: 18px;
height: 16px; }
#nobootstrap #orders_notif {
background: url("../img/notif_order.png") no-repeat center top; }
#nobootstrap #customers_notif {
background: url("../img/notif_customer.png") no-repeat center top; }
#nobootstrap #customer_messages_notif {
background: url("../img/notif_message.png") no-repeat center top; }
#nobootstrap #orders_notif.open_notifs,
#nobootstrap #customers_notif.open_notifs,
#nobootstrap #customer_messages_notif.open_notifs {
background-color: #FFFFFF;
border: 1px solid #000000;
position: relative;
display: block;
background-position: center bottom; }
#nobootstrap .number_wrapper {
color: white;
display: none;
font-size: 13px;
font-weight: bold;
position: absolute;
right: -8px;
top: -10px;
z-index: 101;
padding: 2px 5px; }
#nobootstrap .number_wrapper span {
background-color: #F03D25;
font-size: 11px;
display: block;
padding: 1px 3px;
border-color: -moz-use-text-color #DD3822 #DD3822;
border-radius: 2px 2px 2px 2px;
border-right: 1px solid #DD3822;
border-style: none solid solid;
border-width: 0 0px; }
#nobootstrap .notifs_wrapper {
background: none repeat scroll 0 0 #FFFFFF;
border: 1px solid #000;
border-top: none;
display: none;
cursor: auto;
position: absolute;
top: 25px;
left: -1px;
width: 300px;
padding: 10px;
color: black;
z-index: 9999; }
#nobootstrap .notifs_wrapper h3 {
font-size: 14px;
padding-bottom: 8px;
margin: 0;
border-bottom: 1px solid #E5E5E5; }
#nobootstrap .notifs_wrapper ul {
padding: 6px 0;
margin: 0; }
#nobootstrap .notifs_wrapper ul li {
text-decoration: none;
list-style: none;
font-size: 12px;
padding: 5px 0; }
#nobootstrap #header_infos .notifs_wrapper a {
font-weight: bold;
font-size: 11px;
color: black;
float: right; }
#nobootstrap .notifs_wrapper p {
font-size: 12px;
padding-top: 8px;
margin: 0;
border-top: 1px solid #E5E5E5; }
#nobootstrap .notifs_wrapper p.no_notifs {
border: none; }
#nobootstrap #header #menu {
background-color: #f8f8f8;
border-bottom: 1px solid #e5e5e5;
float: left;
line-height: normal;
margin: 0;
padding: 0;
width: 100%; }
#nobootstrap #header #menu li.maintab {
float: left;
height: 29px;
list-style: none;
list-style: none;
display: block;
border-left: 1px solid #fff;
border-right: 1px solid #ccc; }
#nobootstrap #header #menu li.submenu_size .title {
cursor: default;
color: #000;
display: block;
padding: 8px 3px 4px 0;
font-weight: normal;
font-size: 12px; }
#nobootstrap #header #menu li.submenu_size .title {
_display: inline;
_padding: 6px 5px 4px 0; }
#nobootstrap #header #menu li {
_height: 32px;
_padding-top: 3px; }
#nobootstrap #header #menu img {
display: inline;
padding: 0 3px 0 6px;
margin-top: -4px;
vertical-align: middle;
width: 16px;
height: 16px; }
#nobootstrap #header #menu li.active, #nobootstrap #header #menu li:hover {
background-position: 0 -38px;
white-space: nowrap; }
#nobootstrap #header #menu li:hover, #nobootstrap #header #menu li.active {
background-color: #49B2FF; }
#nobootstrap #header #menu li.maintab:hover, #nobootstrap #header #menu li.active {
border-left: 1px solid #49B2FF;
border-right: 1px solid #49B2FF; }
#nobootstrap #header #menu li.active a.title, #nobootstrap #header #menu li:hover a.title {
color: #fff;
text-shadow: -1px -1px 0 #3293D6; }
#nobootstrap #header #menu .withLeftBorder {
background: transparent url("../img/separator_subnav.png") no-repeat 0 5px; }
#nobootstrap #header #menu .submenu {
background: #f8f8f8;
clear: both;
margin: 0;
padding: 0;
border: 1px solid #d9d9d9;
z-index: 9999;
box-shadow: 1px 5px 5px #CCCCCC;
-moz-box-shadow: 1px 5px 10px #CCCCCC;
-webkit-box-shadow: 1px 5px 10px #CCCCCC; }
#nobootstrap #header #menu .submenu li {
list-style: none;
margin: 0;
padding: 0;
display: block;
min-width: 150px; }
#nobootstrap #header #menu .submenu li a {
font-size: 12px;
display: block;
padding: 5px 15px 5px 10px;
color: #666666;
border-top: 1px solid #fff;
border-bottom: 1px solid #ccc; }
#nobootstrap #header #menu .submenu li a:hover {
background-color: #eee;
text-shadow: 0 1px 0 #fff; }
#nobootstrap #header #menu .submenu li.active a {
color: #fff; }
#nobootstrap #header #menu .submenu li.active a:hover {
color: #666666; }
#nobootstrap .separation {
background-color: #ccc;
border-bottom: 1px solid #fff;
@@ -222,6 +533,7 @@
#nobootstrap .path_bar {
background-color: #E2EBEE;
border: 1px solid #999999;
font-family: Trebuchet,Arial,Helvetica,sans-serif;
font-size: 13px;
margin-bottom: 20px;
padding: 5px; }
@@ -230,6 +542,7 @@
#nobootstrap .cat_bar {
background-color: #F4E8CD;
border: 1px solid #999999;
font-family: Trebuchet,Arial,Helvetica,sans-serif;
font-size: 12px;
font-weight: 700;
margin-bottom: 20px;
@@ -344,6 +657,14 @@
#nobootstrap .toolbar-placeholder {
position: relative; }
#nobootstrap .toolbarBox {
background-color: #F8F8F8;
border: 1px solid #CCCCCC;
margin-bottom: 10px;
padding: 5px 0;
border-radius: 3px;
-moz-border-radius: 3px;
-webkit-border-radius: 3px;
-o-border-radius: 3px;
position: relative; }
#nobootstrap .toolbarBox .pageTitle {
margin-left: 10px;
@@ -389,7 +710,8 @@
float: none;
height: 32px;
margin: 0 auto;
width: 32px; }
width: 32px;
/*hacking ie7margin:0 !ie; position:relative !ie;*/ }
#nobootstrap .toolbarBox .process-icon-delete {
background-image: url("../img/process-icon-delete.png"); }
#nobootstrap .toolbarBox .process-icon-duplicate {
@@ -892,7 +1214,8 @@
font-weight: bold; }
#nobootstrap #statsContainer .blocStats .blocConversion {
display: block;
display: inline-table; }
display: inline-table;
min-height: 80px; }
#nobootstrap #moduleContainer {
margin-left: 220px;
padding: 13px 0 0 20px; }
@@ -996,7 +1319,7 @@
margin: 0;
white-space: nowrap;
overflow: auto;
height: 335px; }
height: 370px; }
#nobootstrap #modules_list_container_tab #modules_list_container_content li {
display: inline-block; }
#nobootstrap #modules_list_container_tab table tr th {
@@ -1050,7 +1373,7 @@
font-size: 10px;
color: #fff;
text-transform: uppercase;
padding: 2px 10px;
padding: 0 10px;
display: inline-block;
border-radius: 3px; }
#nobootstrap #modules_list_container_tab .row-actions-module {
@@ -1093,11 +1416,11 @@
border: none; }
#nobootstrap .default_modules_list_display_type #modules_list_container_content li table {
border: solid 1px #ccc;
height: 140px;
height: 105px;
width: 100%;
margin-bottom: 15px; }
margin-bottom: 10px; }
#nobootstrap #modules_list_container_tab ul li {
height: 140px; }
height: 105px; }
#nobootstrap .ie7 #modules_list_container_tab #modules_list_container_content li {
zoom: 1;
display: inline; }
@@ -1165,6 +1488,20 @@
margin: 0 1em 0 0.25em; }
#nobootstrap ul.listForm li {
padding-bottom: 3px; }
#nobootstrap #footer {
height: 40px;
font-size: 12px;
clear: both;
font-size: 0.9em;
color: #666666; }
#nobootstrap #footer .footerLeft {
float: left;
margin-left: 10px; }
#nobootstrap #footer .footerRight {
float: right;
margin-right: 10px; }
#nobootstrap #footer .footer_link, #nobootstrap #footer .footer_link:hover {
color: #268CCD; }
#nobootstrap .pageTitleHome {
font-size: 1.6em;
font-weight: normal;
@@ -302,7 +302,7 @@
{assign var=is_child value=true}
{assign var=result_accesses value=0}
<tr class="child-{$child.id_parent}">
<td{if !$is_child} class="bold"{/if}>{if $is_child} &raquo; {/if}<strong>{$child.name}</strong></td>
<td{if !$is_child} class="bold"{/if}>{if $is_child} &raquo; {/if}{$child.name}</td>
{foreach $perms as $perm}
{if $access_edit == 1}
<td>
@@ -27,13 +27,7 @@
{block name="label"}
{if $input.name == 'vat_number'}
{if $vat == 'is_applicable'}
<div id="vat_area" style="display: visible">
{else if $vat == 'management'}
<div id="vat_area" style="display: hidden">
{else}
<div style="display: none;">
{/if}
<div id="vat_area" style="display: visible">
{/if}
{if $input.type == 'text_customer' && !isset($customer)}
@@ -33,7 +33,7 @@
<li><i class="icon-home"></i>
{assign var=params_url value=""}
{else}
<li>{assign var=params_url value="&id_category={$category.id_category}&viewcategory"}
{assign var=params_url value="&id_category={$category.id_category|intval}&viewcategory"}
{/if}
{if $category.id_category == $categories_tree_current_id}
{$category.name}</li>
@@ -75,10 +75,10 @@
{if $key != 'deleteMode'}
{if is_array($value)}
{foreach $value as $val}
<input type="hidden" name="{$key}[]" value="{$val}" />
<input type="hidden" name="{$key|escape:'htmlall':'UTF-8'}[]" value="{$val|escape:'htmlall':'UTF-8'}" />
{/foreach}
{else}
<input type="hidden" name="{$key}" value="{$value}" />
<input type="hidden" name="{$key|escape:'htmlall':'UTF-8'}" value="{$value|escape:'htmlall':'UTF-8'}" />
{/if}
{/if}
{/foreach}
@@ -35,7 +35,7 @@
{/block}
{block name=leadin}
{if isset($delete_customer) && $delete_customer}
<form action="{$REQUEST_URI}" method="post">
<form action="{$REQUEST_URI|escape:'htmlall':'UTF-8'}" method="post">
<div class="alert alert-block">
<h2>{l s='How do you want to delete these customer(s)?'}</h2>
<p>{l s='There are two ways of deleting a customer. Please choose your preferred method.'}</p>
@@ -52,10 +52,10 @@
{foreach $POST as $key => $value}
{if is_array($value)}
{foreach $value as $val}
<input type="hidden" name="{$key}[]" value="{$val}" />
<input type="hidden" name="{$key|escape:'htmlall':'UTF-8'}[]" value="{$val|escape:'htmlall':'UTF-8'}" />
{/foreach}
{else}
<input type="hidden" name="{$key}" value="{$value}" />
<input type="hidden" name="{$key|escape:'htmlall':'UTF-8'}" value="{$value|escape:'htmlall':'UTF-8'}" />
{/if}
{/foreach}
<br /><input type="submit" class="button" value="{l s='Delete'}" />
@@ -106,63 +106,61 @@
if ($(this).attr('name') == 'category_reduction['+$('[name="id_category"]:checked').val()+']')
{
exist = true;
jAlert('{l s='This category already exists for this group.'}');
jAlert('{l s='This category already exists for this group.' js=1}');
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)
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)
{
if (jsonData.hasError)
{
var errors = '';
for(error in jsonData.errors)
//IE6 bug fix
if(error != 'indexOf')
errors += jsonData.errors[error] + "\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:'}'+jsonData.discount+'{l s='%'}</td><td><a href="#" onclick="deleteCategoryReduction('+jsonData.id_category+');"><img src="../img/admin/delete.gif"></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();
}
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:'}'+jsonData.discount+'{l s='%'}</td><td><a href="#" onclick="deleteCategoryReduction('+jsonData.id_category+');"><img src="../img/admin/delete.gif"></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');
collapseAllCategories();
$('#category_reduction_fancybox').val('0.00');
}
function initFancyBox()
{
$('[name="id_category"]:checked').removeAttr('checked');
collapseAllCategories();
$('#category_reduction_fancybox').val('0.00');
}
</script>
<div class="margin-form">
<a class="button" href="#group_discount_category_fancybox" id="group_discount_category">{l s='Add a category discount'}</a>
@@ -270,4 +268,4 @@
{else}
{$smarty.block.parent}
{/if}
{/block}
{/block}
@@ -50,14 +50,14 @@
console.log(truncateAuthorized);
if (truncateAuthorized)
{
if (!confirm('{l s='Are you sure that you would like to delete this' js=1}' + ' ' + $.trim($('#entity > option:selected').text().toLowerCase()) + '{l s='?' js=1}'))
if (!confirm('{l s='Are you sure that you would like to delete this' js=1}' + ' ' + $.trim($('#entity > option:selected').text().toLowerCase()) + '?'))
{
e.preventDefault();
}
}
else
{
jAlert('{l s='You do not have permission to delete here. When the multistore is enabled, only a SuperAdmin can delete all items before an import.'}');
jAlert('{l s='You do not have permission to delete here. When the multistore is enabled, only a SuperAdmin can delete all items before an import.' js=1}');
return false;
}
}
@@ -49,14 +49,14 @@
<form action="#" id="login_form" method="post">
<div class="field">
<label for="email">{l s='Email address:'}</label>
<input type="text" id="email" name="email" class="input email_field" value="{if isset($email)}{$email|escape:'htmlall':'UTF-8'}{/if}" />
<input type="text" id="email" name="email" class="input email_field" tabindex="1" value="{if isset($email)}{$email|escape:'htmlall':'UTF-8'}{/if}" />
</div>
<div class="field">
<label for="passwd">{l s='Password:'}</label>
<input id="passwd" type="password" name="passwd" class="input password_field" value="{if isset($password)}{$password}{/if}"/>
<input id="passwd" type="password" name="passwd" class="input password_field" tabindex="2" value="{if isset($password)}{$password}{/if}"/>
</div>
<div class="field">
<input type="submit" name="submitLogin" value="{l s='Log in'}" class="button fl margin-right-5" />
<input type="submit" name="submitLogin" value="{l s='Log in'}" tabindex="3" class="button fl margin-right-5" />
<p class="fl no-margin hide ajax-loader">
<img src="../img/loader.gif" alt="" />
</p>
@@ -92,8 +92,11 @@
{/if}
</dl>
</div>
{if isset($module->message)}<div class="alert">{$module->message}</div>{/if}
<p class="desc">{if isset($module->description) && $module->description ne ''}{l s='Description'} : {$module->description}{else}&nbsp;{/if}</p>
{if isset($module->message) && (!isset($module->type) || ($module->type != 'addonsMustHave' || $module->type !== 'addonsNative'))}<div class="alert">{$module->message}</div>{/if}
<div class="row-fluid">
{if !isset($module->not_on_disk)}
{$module->optionsHtml}
{if isset($module->preferences) && isset($module->preferences['favorite']) && $module->preferences['favorite'] == 1}
@@ -36,7 +36,6 @@
</ul>
</div>
{/if}
<div class="row">
<div class="col-lg-12">
<span class="pull-right">
@@ -50,7 +49,6 @@
</a>
</span>
</div>
<div id="container">
<!--start sidebar module-->
<div class="row-fluid">
@@ -83,4 +81,4 @@
</div>
</div>
</div>
</div>
</div>
@@ -77,9 +77,9 @@
{/if}
{if get_class($document) eq 'OrderInvoice'}
{if isset($document->is_delivery)}
#{Configuration::get('PS_DELIVERY_PREFIX', $current_id_lang)}{'%06d'|sprintf:$document->delivery_number}
#{Configuration::get('PS_DELIVERY_PREFIX', $current_id_lang, null, $order->id_shop)}{'%06d'|sprintf:$document->delivery_number}
{else}
{$document->getInvoiceNumberFormatted($current_id_lang)}
{$document->getInvoiceNumberFormatted($current_id_lang, $order->id_shop)}
{/if}
{elseif get_class($document) eq 'OrderSlip'}
#{Configuration::get('PS_CREDIT_SLIP_PREFIX', $current_id_lang)}{'%06d'|sprintf:$document->id}
@@ -123,7 +123,7 @@
{if !isset($document->is_delivery)}
<tr id="invoiceNote{$document->id}" style="display:none">
<td colspan="5">
<form action="{$current_index}&viewOrder&id_order={$order->id}&token={$smarty.get.token|escape:'htmlall':'UTF-8'}" method="post">
<form action="{$current_index}&viewOrder&id_order={$order->id}{if isset($smarty.get.token)}&token={$smarty.get.token|escape:'htmlall':'UTF-8'}{/if}" method="post">
<p>
<label for="editNote{$document->id}" class="t">{l s='Note'}</label>
<input type="hidden" name="id_order_invoice" value="{$document->id}" />
@@ -149,7 +149,7 @@
<td colspan="5" class="center">
<h4>{l s='No documents are available'}</h4>
{if isset($invoice_management_active) && $invoice_management_active}
<a class="btn btn-default" href="{$current_index}&viewOrder&submitGenerateInvoice&id_order={$order->id}&token={$smarty.get.token|escape:'htmlall':'UTF-8'}">
<a class="button" href="{$current_index}&viewOrder&submitGenerateInvoice&id_order={$order->id}{if isset($smarty.get.token)}&token={$smarty.get.token|escape:'htmlall':'UTF-8'}{/if}">{l s='Generate invoice'}</a>
<i class="icon-repeat"></i>
{l s='Generate invoice'}
</a>
@@ -158,4 +158,4 @@
</tr>
{/foreach}
</tbody>
</table>
</table>
@@ -22,14 +22,7 @@
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
<table class="table table-hover" width="100%" cellspacing="0" cellpadding="0" id="shipping_table">
<colgroup>
<col width="15%">
<col width="15%">
<col width="">
<col width="20%">
<col width="1%">
</colgroup>
<table class="table" id="shipping_table">
<thead>
<tr>
<th>
@@ -58,7 +51,7 @@
<td>{dateFormat date=$line.date_add full=true}</td>
<td>{$line.type}</td>
<td>{$line.carrier_name}</td>
<td>{$line.weight|string_format:"%.3f"} {Configuration::get('PS_WEIGHT_UNIT')}</td>
<td class="weight">{$line.weight|string_format:"%.3f"} {Configuration::get('PS_WEIGHT_UNIT')}</td>
<td class="center">
{if $order->getTaxCalculationMethod() == $smarty.const.PS_TAX_INC}
{displayPrice price=$line.shipping_cost_tax_incl currency=$currency->id}
@@ -90,4 +83,4 @@
</tr>
{/foreach}
</tbody>
</table>
</table>
@@ -33,8 +33,8 @@
var currencies = new Array();
var id_currency = '';
var id_lang = '';
var txt_show_carts = '{l s='Show carts and orders for this customer.' js='1'}';
var txt_hide_carts = '{l s='Hide carts and orders for this customer.' js='1'}';
var txt_show_carts = '{l s='Show carts and orders for this customer.' js=1}';
var txt_hide_carts = '{l s='Hide carts and orders for this customer.' js=1}';
var defaults_order_state = new Array();
var customization_errors = false;
var pic_dir = '{$pic_dir}';
@@ -100,7 +100,7 @@
$('#show_old_carts').click();
$('#payment_module_name').change();
$.ajaxSetup({ type:"post" });
$("#voucher").autocomplete('{$link->getAdminLink('AdminCartRules')|escape:'html'}', {
$("#voucher").autocomplete('{$link->getAdminLink('AdminCartRules')|addslashes}', {
minChars: 3,
max: 15,
width: 250,
@@ -468,7 +468,7 @@
$('#new_address').attr('href', address_link.replace(/id_customer=[0-9]+/, 'id_customer='+id_customer));
$.ajax({
type:"POST",
url : "{$link->getAdminLink('AdminCarts')|escape:'html'}",
url : "{$link->getAdminLink('AdminCarts')|addslashes}",
async: false,
dataType: "json",
data : {
@@ -27,7 +27,7 @@
{block name="override_tpl"}
<script type="text/javascript">
var admin_order_tab_link = "{$link->getAdminLink('AdminOrders')|escape:'html'}";
var admin_order_tab_link = "{$link->getAdminLink('AdminOrders')|addslashes}";
var id_order = {$order->id};
var id_lang = {$current_id_lang};
var id_currency = {$order->id_currency};
@@ -134,11 +134,9 @@
</label>
<div class="col-lg-10">
<select id="id_order_state" name="id_order_state">
{foreach from=$states item=state}
{if $state['id_order_state'] != $currentState->id}
<option value="{$state['id_order_state']}">{$state['name']|stripslashes}</option>
{/if}
{/foreach}
{foreach from=$states item=state}
<option value="{$state['id_order_state']}"{if $state['id_order_state'] == $currentState->id} selected="selected" disabled="disabled"{/if}>{$state['name']|stripslashes}</option>
{/foreach}
</select>
</div>
<input type="hidden" name="id_order" value="{$order->id}" />
@@ -561,7 +559,7 @@
<td>{displayPrice price=$payment->amount currency=$payment->id_currency}</td>
<td>
{if $invoice = $payment->getOrderInvoice($order->id)}
{$invoice->getInvoiceNumberFormatted($current_id_lang)}
{$invoice->getInvoiceNumberFormatted($current_id_lang, $order->id_shop)}
{else}
{l s='No invoice'}
{/if}
@@ -644,7 +642,7 @@
<td>
<select name="payment_invoice" id="payment_invoice">
{foreach from=$invoices_collection item=invoice}
<option value="{$invoice->id}" selected="selected">{$invoice->getInvoiceNumberFormatted($current_id_lang)}</option>
<option value="{$invoice->id}" selected="selected">{$invoice->getInvoiceNumberFormatted($current_id_lang, $order->id_shop)}</option>
{/foreach}
</select>
</td>
@@ -25,13 +25,12 @@
{extends file="helpers/view/view.tpl"}
{block name="override_tpl"}
{if !$shop_context}
<div class="alert alert-block">{l s='You have more than one shop and must select one to configure payment.'}</div>
{else}
{if !$shop_context}
<div class="alert alert-block">{l s='You have more than one shop and must select one to configure payment.'}</div>
{else}
{if isset($modules_list)}
{$modules_list}
{/if}
{if $display_restrictions}
<legend>{l s='Payment module restrictions'}</legend>
{foreach $lists as $list}
@@ -40,5 +39,5 @@
{else}
<div class="alert alert-block">{l s='No payment module installed'}</div>
{/if}
{/if}
{/block}
{/if}
{/block}
@@ -34,10 +34,10 @@
{if $module->active}
<th class="center">
{if $list['name_id'] != 'currency' || $module->currencies_mode == 'checkbox'}
<input type="hidden" id="checkedBox_{$list['name_id']}_{$module->name}" value="checked">
<input type="hidden" id="checkedBox_{$list['name_id']}_{$module->name}" value="checked"/>
<a href="javascript:checkPaymentBoxes('{$list['name_id']}', '{$module->name}')" style="text-decoration:none;">
{/if}
&nbsp;<img src="{$ps_base_uri}modules/{$module->name}/logo.gif" alt="{$module->name}" title="{$module->displayName}" />
&nbsp;<img src="{$ps_base_uri}modules/{$module->name}/logo.gif" alt="{$module->name}" title="{$module->displayName}"/>
{if $list['name_id'] != 'currency' || $module->currencies_mode == 'checkbox'}
</a>
{/if}
@@ -66,11 +66,9 @@
{$type = 'checkbox'}
{/if}
{if $type != 'null'}
<input type="checkbox" name="{$module->name}_{$list['name_id']}[]" value="{$item[$list['identifier']]}"
{if $item['check_list'][$key_module] == 'checked'}checked="checked"{/if}
/>
<input type="{$type}" name="{$module->name}_{$list['name_id']}[]" value="{$item[$list['identifier']]}" {if $item['check_list'][$key_module] == 'checked'}checked="checked"{/if}/>
{else}
--
<input type="hidden" name="{$module->name}_{$list['name_id']}[]" value="{$item[$list['identifier']]}"/>--
{/if}
</td>
{/if}
@@ -122,4 +120,4 @@
</button>
</p>
</fieldset>
</form>
</form>
@@ -78,7 +78,7 @@
<tr id="image_id">
<td style="padding: 4px;">
<a href="{$smarty.const._THEME_PROD_DIR_}image_path.jpg" class="fancybox">
<img src="{$smarty.const._THEME_PROD_DIR_}en-default-small_default.jpg" alt="image_id" title="image_id" />
<img src="{$smarty.const._THEME_PROD_DIR_}{$iso_lang}-default-small_default.jpg" alt="image_id" title="image_id" />
</a>
</td>
<td id="td_image_id" class="pointer dragHandle center positionImage">
@@ -291,41 +291,28 @@
{
doAdminAjax(
{
"action":"updateImagePosition",
"json":json,
"token" : "{/literal}{$token}{literal}",
"tab" : "AdminProducts",
"ajax" : 1
});
}
function delQueue(id)
{
$("#img" + id).fadeOut("slow");
$("#img" + id).remove();
}
function imageLine(id, path, position, cover, shops)
{
line = $("#lineType").html();
line = line.replace(/image_id/g, id);
line = line.replace(/en-default/g, path);
line = line.replace(/image_path/g, path);
line = line.replace(/image_position/g, position);
line = line.replace(/icon-check-empty/g, cover);
line = line.replace(/<tbody>/gi, "");
line = line.replace(/<\/tbody>/gi, "");
if (shops != false)
{
$.each(shops, function(key, value){
if (value == 1)
line = line.replace('id="' + key + '' + id + '"','id="' + key + '' + id + '" checked=checked');
});
line = $("#lineType").html();
line = line.replace(/image_id/g, id);
line = line.replace(/[a-z]{2}-default/g, path);
line = line.replace(/image_path/g, path);
line = line.replace(/image_position/g, position);
line = line.replace(/blank/g, cover);
line = line.replace(/<tbody>/gi, "");
line = line.replace(/<\/tbody>/gi, "");
if (shops != false)
{
$.each(shops, function(key, value){
if (value == 1)
line = line.replace('id="' + key + '' + id + '"','id="' + key + '' + id + '" checked=checked');
});
}
$("#imageList").append(line);
}
$("#imageList").append(line);
}
$('.fancybox').fancybox();
});
{/literal}
</script>
$('.fancybox').fancybox();
});
{/literal}
</script>
{/if}
@@ -43,7 +43,7 @@
$('document').ready( function() {
$(".check_product_name")
.autocomplete(
'{$link->getAdminLink('AdminProducts', true)|escape:'html'}', {
'{$link->getAdminLink('AdminProducts', true)|addslashes}', {
minChars: 3,
max: 10,
width: $(".check_product_name").width(),
@@ -90,7 +90,7 @@
var table = $('#selectTables select').val();
if (!table)
jAlert("{l s='Please choose a table.'}");
jAlert("{l s='Please choose a table.' js=1}");
else
AddRequestSql(table);
});
@@ -24,9 +24,9 @@
*}
<a href="{$href}" class="delete"
{if in_array($id_shop, $shops_having_dependencies)}
onclick="jAlert('{l s='You cannot delete this shop\'s (customer and/or order dependency)'}'); return false;"
onclick="jAlert('{l s='You cannot delete this shop\'s (customer and/or order dependency)' js=1}'); return false;"
{elseif isset($confirm)}
onclick="if (confirm('{$confirm}')){ return true; }else{ event.stopPropagation(); event.preventDefault();};"
onclick="if (confirm('{$confirm}')){ return true; } else { event.stopPropagation(); event.preventDefault();};"
{/if} title="{$action}">
<img src="../img/admin/delete.gif" alt="{$action}" />
</a>
@@ -138,7 +138,7 @@
// check if it's possible to add the product
if (product_infos == null || $('#cur_product_name').val() == '')
{
jAlert('{l s='Please select at least one product.'}');
jAlert('{l s='Please select at least one product.' js=1}');
return false;
}
+5 -3
View File
@@ -75,6 +75,8 @@
var token_admin_customer_threads = '{getAdminToken tab='AdminCustomerThreads' slashes=1}';
var currentIndex = '{$currentIndex}';
var default_language = '{$default_language|intval}';
var choose_language_translate = "{l s='Choose language' slashes=1}";
</script>
{/if}
@@ -201,7 +203,7 @@
</button>
</span>
</div>
<!-- // Search in section
<!-- //todo Search in section
<select name="bo_search_type" id="bo_search_type" class="chosen no-search">
<option value="0">{l s='everywhere'}</option>
<option value="1" {if {$search_type} == 1} selected="selected" {/if}>{l s='catalog'}</option>
@@ -251,7 +253,7 @@
<i class="icon-AdminDashboard"></i> {l s='Dashboard'}
</a>
</li>
{foreach $tabs AS $t}
{foreach $tabs as $t}
{if $t.active}
<li class="maintab {if $t.current}active{/if}" id="maintab{$t.id_tab}">
<a href="javascript:adminNav('#maintab{$t.id_tab}');" class="title">
@@ -289,4 +291,4 @@
<div class="multishop_toolbar">
<span class="text_multishop">{l s='Multistore configuration for'}</span> {$shop_list}
</div>
{/if}
{/if}
@@ -295,13 +295,20 @@
{/foreach}
{elseif $input.type == 'file'}
{if isset($input.display_image) && $input.display_image}
{if isset($fields_value.image) && $fields_value.image}
{if isset($fields_value[$input.name].image) && $fields_value[$input.name].image}
<div id="image">
<<<<<<< HEAD
{$fields_value.image}
<p align="center">{l s='File size'} {$fields_value.size}kb</p>
<a class="btn btn-default" href="{$current}&{$identifier}={$form_id}&token={$token}&deleteImage=1">
<i class="icon-trash"></i> {l s='Delete'}
=======
{$fields_value[$input.name].image}
<p align="center">{l s='File size'} {$fields_value[$input.name].size}kb</p>
<a href="{$current}&{$identifier}={$form_id}&token={$token}&deleteImage=1">
<img src="../img/admin/delete.gif" alt="{l s='Delete'}" /> {l s='Delete'}
>>>>>>> 6ac3f1133ae7547ff92964c47ec141c3ab5bf5c4
</a>
</div><br />
@@ -405,13 +412,13 @@
{/if}
</div>
{/foreach}
{hook h='displayAdminForm'}
{hook h='displayAdminForm' fieldset=$f}
{if isset($name_controller)}
{capture name=hookName assign=hookName}display{$name_controller|ucfirst}Form{/capture}
{hook h=$hookName}
{hook h=$hookName fieldset=$f}
{elseif isset($smarty.get.controller)}
{capture name=hookName assign=hookName}display{$smarty.get.controller|ucfirst|htmlentities}Form{/capture}
{hook h=$hookName}
{hook h=$hookName fieldset=$f}
{/if}
{elseif $key == 'submit'}
<div class="margin-form">
@@ -29,9 +29,18 @@
{if count($modules_list)}
<table border="0" cellpadding="0" cellspacing="5" class="table table-striped table-hover">
{counter start=1 assign="count"}
<<<<<<< HEAD
{foreach from=$modules_list item=module}
{include file='controllers/modules/tab_module_line.tpl' class_row={cycle values=",row alt"}}
{if $count %2 == 0}{/if}
=======
{foreach from=$modules_list item=module}
<div style="width:400px">{include file='controllers/modules/tab_module_line.tpl' class_row={cycle values=",row alt"}}</div>
{if $count %3 == 0}
</li>
<li>
{/if}
>>>>>>> 6ac3f1133ae7547ff92964c47ec141c3ab5bf5c4
{counter}
{/foreach}
</table>