Merge branch 'bootstrap' of https://github.com/PrestaShop/PrestaShop into bootstrap
This commit is contained in:
+28
-7
@@ -16,13 +16,14 @@
|
||||
- bMancone
|
||||
- bumbu
|
||||
- Burhan
|
||||
- Cédric Mouleyre
|
||||
- Caleydon Media
|
||||
- cam.lafit
|
||||
- Captain FLAM
|
||||
- Captain-FLAM
|
||||
- ccauw
|
||||
- Cédric Mouleyre
|
||||
- ChristopheBoucaut
|
||||
- CINS
|
||||
- cippest
|
||||
- cmouleyre
|
||||
- Corentin Delcourt
|
||||
@@ -34,42 +35,50 @@
|
||||
- David Gasperoni
|
||||
- Davy Rolink
|
||||
- djfm
|
||||
- dlage
|
||||
- dMetzger
|
||||
- (d)oekia
|
||||
- Dragan Skrbic
|
||||
- DrÿSs'
|
||||
- dreammeup
|
||||
- DrySs
|
||||
- DrÿSs
|
||||
- DrÿSs'
|
||||
- dSevere
|
||||
- Edouard Gaulué
|
||||
- emily-d
|
||||
- Fabio Chelly
|
||||
- fBrignoli
|
||||
- fram
|
||||
- Francois Gaillard
|
||||
- François Gaillard
|
||||
- Fran?s Gaillard
|
||||
- fSerny
|
||||
- Gabriel Schwardy
|
||||
- gBrunier
|
||||
- gCharmes
|
||||
- gPoulain
|
||||
- gr4devel
|
||||
- Grégoire Bélorgey
|
||||
- Gregory Roussac
|
||||
- gRoussac
|
||||
- Guillaume DELOINCE
|
||||
- ha99y
|
||||
- hAitmansour
|
||||
- Ha!*!*y
|
||||
- indesign47
|
||||
- inem0o
|
||||
- ivancasasempere
|
||||
- Jérôme Nadaud
|
||||
- jBreux
|
||||
- jeckyl
|
||||
- jeromenadaud
|
||||
- Jerome Nadaud
|
||||
- Jérôme Nadaud
|
||||
- jessylenne
|
||||
- jmCollin
|
||||
- jObregon
|
||||
- Jonathan Danse
|
||||
- joseantgv
|
||||
- Julien
|
||||
- Kevin Granger
|
||||
- kpodemski
|
||||
- Krystian Podemski
|
||||
@@ -77,8 +86,11 @@
|
||||
- lCherifi
|
||||
- ldecoker
|
||||
- lLefevre
|
||||
- LOIC ROSSET ltd
|
||||
- makk1ntosh
|
||||
- marcinsz101
|
||||
- Marco Cervellin
|
||||
- matiasiglesias
|
||||
- Mats Rynge
|
||||
- MatthieuB
|
||||
- Maxence
|
||||
@@ -101,32 +113,39 @@
|
||||
- PhpMadman
|
||||
- Pierre
|
||||
- Piotr Kaczor
|
||||
- Piotr Moćko
|
||||
- Piotr Mocko
|
||||
- PrestaEdit
|
||||
- prestarocket
|
||||
- Prestaspirit
|
||||
- pxls
|
||||
- Rémi Gaillard
|
||||
- Raphaël Malié
|
||||
- raulgundin
|
||||
- Rémi Gaillard
|
||||
- rGaillard
|
||||
- Rimas Kudelis
|
||||
- rMalie
|
||||
- rMontagne
|
||||
- romainberger
|
||||
- root
|
||||
- runningz
|
||||
- Sébastien
|
||||
- Sébastien Bocahu
|
||||
- sagaradonis
|
||||
- Samy Rabih
|
||||
- Sarah Lorenzini
|
||||
- Seb
|
||||
- Sébastien
|
||||
- Sébastien Bocahu
|
||||
- Seynaeve
|
||||
- Shagshag
|
||||
- sjousse
|
||||
- sLorenzini
|
||||
- smartdatasoft
|
||||
- soufyan
|
||||
- soware
|
||||
- Staging
|
||||
- sThiebaut
|
||||
- Sylvain WITMEYER
|
||||
- tDidierjean
|
||||
- unknown
|
||||
- vAugagneur
|
||||
- vChabot
|
||||
- Vincent Augagneur
|
||||
@@ -138,3 +157,5 @@
|
||||
- Xavier
|
||||
- Xavier POITAU
|
||||
- Yoozio
|
||||
- zimmi1
|
||||
|
||||
|
||||
@@ -27,6 +27,9 @@
|
||||
$timer_start = microtime(true);
|
||||
define('_PS_ADMIN_DIR_', getcwd());
|
||||
|
||||
if (!defined('PS_ADMIN_DIR'))
|
||||
define('PS_ADMIN_DIR', _PS_ADMIN_DIR_);
|
||||
|
||||
require(_PS_ADMIN_DIR_.'/../config/config.inc.php');
|
||||
require(_PS_ADMIN_DIR_.'/functions.php');
|
||||
|
||||
|
||||
+6
-3
@@ -49,9 +49,12 @@ try
|
||||
AdminTab::$currentIndex = $currentIndex;
|
||||
|
||||
$iso = $context->language->iso_code;
|
||||
include(_PS_TRANSLATIONS_DIR_.$iso.'/errors.php');
|
||||
include(_PS_TRANSLATIONS_DIR_.$iso.'/fields.php');
|
||||
include(_PS_TRANSLATIONS_DIR_.$iso.'/admin.php');
|
||||
if (file_exists(_PS_TRANSLATIONS_DIR_.$iso.'/errors.php'))
|
||||
include(_PS_TRANSLATIONS_DIR_.$iso.'/errors.php');
|
||||
if (file_exists(_PS_TRANSLATIONS_DIR_.$iso.'/fields.php'))
|
||||
include(_PS_TRANSLATIONS_DIR_.$iso.'/fields.php');
|
||||
if (file_exists(_PS_TRANSLATIONS_DIR_.$iso.'/admin.php'))
|
||||
include(_PS_TRANSLATIONS_DIR_.$iso.'/admin.php');
|
||||
|
||||
/* Server Params */
|
||||
$protocol_link = (Configuration::get('PS_SSL_ENABLED')) ? 'https://' : 'http://';
|
||||
|
||||
@@ -9565,6 +9565,54 @@ textarea {
|
||||
.ladda-button[data-size=xl] .ladda-label {
|
||||
font-size: 1.5em; }
|
||||
|
||||
/* line 1, admin-theme/_admin-login.sass */
|
||||
#login-panel {
|
||||
margin: 0 auto;
|
||||
width: 420px; }
|
||||
/* line 5, admin-theme/_admin-login.sass */
|
||||
#login-panel .flip-container {
|
||||
height: 500px;
|
||||
-webkit-perspective: 1000px;
|
||||
-moz-perspective: 1000px;
|
||||
-ms-perspective: 1000px;
|
||||
-o-perspective: 1000px;
|
||||
perspective: 1000px; }
|
||||
/* line 8, admin-theme/_admin-login.sass */
|
||||
#login-panel .flip-container.flip .flipper {
|
||||
-webkit-transform: rotateY(180deg);
|
||||
-moz-transform: rotateY(180deg);
|
||||
-ms-transform: rotateY(180deg);
|
||||
-o-transform: rotateY(180deg);
|
||||
transform: rotateY(180deg); }
|
||||
/* line 13, admin-theme/_admin-login.sass */
|
||||
#login-panel .flipper {
|
||||
-webkit-transition-duration: 0.6s;
|
||||
transition-duration: 0.6s;
|
||||
-webkit-transform-style: preserve-3d;
|
||||
-moz-transform-style: preserve-3d;
|
||||
-ms-transform-style: preserve-3d;
|
||||
-o-transform-style: preserve-3d;
|
||||
transform-style: preserve-3d;
|
||||
position: relative; }
|
||||
/* line 18, admin-theme/_admin-login.sass */
|
||||
#login-panel .front, #login-panel .back {
|
||||
-webkit-backface-visibility: hidden;
|
||||
-moz-backface-visibility: hidden;
|
||||
backface-visibility: hidden;
|
||||
position: absolute;
|
||||
top: 0;
|
||||
left: 0; }
|
||||
/* line 24, admin-theme/_admin-login.sass */
|
||||
#login-panel .front {
|
||||
z-index: 2; }
|
||||
/* line 27, admin-theme/_admin-login.sass */
|
||||
#login-panel .back {
|
||||
-webkit-transform: rotateY(180deg);
|
||||
-moz-transform: rotateY(180deg);
|
||||
-ms-transform: rotateY(180deg);
|
||||
-o-transform: rotateY(180deg);
|
||||
transform: rotateY(180deg); }
|
||||
|
||||
/* line 1, admin-theme/_admin-carrier-wizard.sass */
|
||||
#carrier_wizard {
|
||||
position: relative;
|
||||
|
||||
@@ -106,8 +106,8 @@ fieldset > .row
|
||||
@import "admin-theme/ladda"
|
||||
@import "admin-theme/ladda-theme"
|
||||
|
||||
|
||||
//page specific
|
||||
@import "admin-theme/admin-login"
|
||||
@import "admin-theme/admin-carrier-wizard"
|
||||
@import "admin-theme/admin-modules"
|
||||
@import "admin-theme/admin-dashboard"
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
#login-panel
|
||||
margin: 0 auto
|
||||
width: 420px
|
||||
|
||||
.flip-container
|
||||
height: 500px
|
||||
@include perspective(1000px)
|
||||
&.flip .flipper
|
||||
@include rotateY(180deg)
|
||||
|
||||
.flip-container, .front, .back
|
||||
|
||||
.flipper
|
||||
@include transition-duration(0.6s)
|
||||
@include transform-style(preserve-3d)
|
||||
position: relative
|
||||
|
||||
.front, .back
|
||||
@include backface-visibility(hidden)
|
||||
position: absolute
|
||||
top: 0
|
||||
left: 0
|
||||
|
||||
.front
|
||||
z-index: 2
|
||||
|
||||
.back
|
||||
@include rotateY(180deg)
|
||||
@@ -24,11 +24,7 @@
|
||||
// Picker object
|
||||
var Datepicker = function(element, options){
|
||||
this.element = $(element);
|
||||
|
||||
if (typeof options.dates != 'undefined')
|
||||
DPGlobal.dates = options.dates;
|
||||
|
||||
this.format = DPGlobal.parseFormat(options.format||this.element.data('date-format')||'Y-m-d');
|
||||
this.format = DPGlobal.parseFormat(options.format||this.element.data('date-format')||'mm/dd/yyyy');
|
||||
this.picker = $(DPGlobal.template).appendTo(this.element).show()
|
||||
.on({
|
||||
click: $.proxy(this.click, this),
|
||||
@@ -287,7 +283,7 @@
|
||||
$(".start-selected").removeClass("start-selected");
|
||||
target.addClass("start-selected");
|
||||
start = target.data("val");
|
||||
$("#date-start").val(DPGlobal.formatDate(new Date(start), DPGlobal.parseFormat('Y-m-d')));
|
||||
$("#date-start").val(start);
|
||||
if(!switched) {click = 1;} else {click = 2;}
|
||||
if(!switched){
|
||||
$("#date-end").val(null).focus().addClass("input-selected");
|
||||
@@ -300,7 +296,7 @@
|
||||
$(".end-selected").removeClass("end-selected");
|
||||
target.addClass("end-selected");
|
||||
end = target.data("val");
|
||||
$("#date-end").val(DPGlobal.formatDate(new Date(end), DPGlobal.parseFormat('Y-m-d')));
|
||||
$("#date-end").val(end);
|
||||
click = 2;
|
||||
$("#date-end").removeClass("input-selected").addClass("input-complete");
|
||||
//this.range();
|
||||
@@ -357,14 +353,14 @@
|
||||
//switch
|
||||
if (start && over < start ){
|
||||
end = start;
|
||||
$("#date-end").val(DPGlobal.formatDate(new Date(start), DPGlobal.parseFormat('Y-m-d'))).removeClass("input-selected");
|
||||
$("#date-end").val(start).removeClass("input-selected");
|
||||
$("#date-start").val(null).focus().addClass("input-selected");
|
||||
$("#datepicker .start-selected").removeClass("start-selected").addClass("end-selected");
|
||||
start = null;
|
||||
switched = true;
|
||||
} else if (end && over > end ){
|
||||
start = end;
|
||||
$("#date-start").val(DPGlobal.formatDate(new Date(end), DPGlobal.parseFormat('Y-m-d'))).removeClass("input-selected");
|
||||
$("#date-start").val(end).removeClass("input-selected");
|
||||
$("#date-end").val(null).focus().addClass("input-selected");
|
||||
$("#datepicker .end-selected").removeClass("end-selected").addClass("start-selected");
|
||||
end = null;
|
||||
@@ -489,12 +485,10 @@
|
||||
date.setMonth(val - 1);
|
||||
break;
|
||||
case 'yy':
|
||||
case 'y':
|
||||
year = 2000 + val;
|
||||
date.setFullYear(2000 + val);
|
||||
break;
|
||||
case 'yyyy':
|
||||
case 'Y':
|
||||
year = val;
|
||||
date.setFullYear(val);
|
||||
break;
|
||||
@@ -509,12 +503,10 @@
|
||||
d: date.getDate(),
|
||||
m: date.getMonth() + 1,
|
||||
yy: date.getFullYear().toString().substring(2),
|
||||
y: date.getFullYear().toString().substring(2),
|
||||
yyyy: date.getFullYear(),
|
||||
Y: date.getFullYear()
|
||||
yyyy: date.getFullYear()
|
||||
};
|
||||
val.d = (val.d < 10 ? '0' : '') + val.d;
|
||||
val.m = (val.m < 10 ? '0' : '') + val.m;
|
||||
val.dd = (val.d < 10 ? '0' : '') + val.d;
|
||||
val.mm = (val.m < 10 ? '0' : '') + val.m;
|
||||
var date = [];
|
||||
for (var i=0, cnt = format.parts.length; i < cnt; i++) {
|
||||
date.push(val[format.parts[i]]);
|
||||
|
||||
@@ -112,11 +112,11 @@
|
||||
<li>
|
||||
{l s='Newsletter:'} {if $customer->newsletter}
|
||||
<span class="label label-success">
|
||||
<i class="icon-check-sign"></i> {l s='Yes'}
|
||||
<i class="icon-check-sign"></i> {l s='Registered'}
|
||||
</span>
|
||||
{else}
|
||||
<span class="label label-warning">
|
||||
<i class="icon-ban-circle"></i> {l s='No'}
|
||||
<i class="icon-ban-circle"></i> {l s='Unregistered'}
|
||||
</span>
|
||||
{/if}
|
||||
</li>
|
||||
@@ -125,19 +125,23 @@
|
||||
{if $customer->optin}
|
||||
<span class="label label-success">
|
||||
<i class="icon-check-sign"></i>
|
||||
{l s='Yes'}
|
||||
{l s='Registered'}
|
||||
</span>
|
||||
{else}
|
||||
<span class="label label-warning">
|
||||
<i class="icon-ban-circle"></i>
|
||||
{l s='No'}
|
||||
{l s='Unregistered'}
|
||||
</span>
|
||||
{/if}
|
||||
</li>
|
||||
<li>
|
||||
{l s='Age:'}
|
||||
{$customer_stats['age']}
|
||||
{if isset($customer->birthday['age'])}({$customer_birthday}){else}{l s='Unknown'}{/if}</li>
|
||||
{if isset($customer->birthday)}
|
||||
{$customer_stats['age']} {l s='years old'} ({l s='Birth date:'} {$customer_birthday})
|
||||
{else}
|
||||
{l s='Unknown'}
|
||||
{/if}
|
||||
</li>
|
||||
<li>
|
||||
{l s='Last update:'}
|
||||
<span>{$last_update}</span>
|
||||
@@ -147,12 +151,12 @@
|
||||
{if $customer->active}
|
||||
<span class="label label-success">
|
||||
<i class="icon-check-sign"></i>
|
||||
{l s='Yes'}
|
||||
{l s='Active'}
|
||||
</span>
|
||||
{else}
|
||||
<span class="label label-warning">
|
||||
<i class="icon-ban-circle"></i>
|
||||
{l s='No'}
|
||||
{l s='Inactive'}
|
||||
</span>
|
||||
{/if}
|
||||
</li>
|
||||
@@ -193,11 +197,11 @@
|
||||
<div class="row">
|
||||
<div class="col-lg-6">
|
||||
<i class="icon-ok-circle icon-big"></i>
|
||||
{l s='Valid orders:'} <span class="badge badge-success">{$count_ok}</span> {l s='for'} {$total_ok}
|
||||
{l s='Valid orders:'} <span class="label label-success">{$count_ok}</span> {l s='for'} {$total_ok}
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
<i class="icon-exclamation-sign icon-big"></i>
|
||||
{l s='Invalid orders:'} <span class="badge badge-warning">{$count_ko}</span>
|
||||
{l s='Invalid orders:'} <span class="label label-danger">{$count_ko}</span>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -76,6 +76,8 @@
|
||||
</fieldset>
|
||||
</div>
|
||||
<div class="col-lg-12">
|
||||
<h2>{l s='Members of this customer group'}</h2>
|
||||
<p>{l s='Limited to the first 100 customers.'} {l s='Please use filters to narrow your search.'}</p>
|
||||
{$customerList}
|
||||
</div>
|
||||
{/block}
|
||||
@@ -71,37 +71,60 @@
|
||||
{if count($files_to_import)}
|
||||
<select name="csv">
|
||||
{foreach $files_to_import AS $filename}
|
||||
<option value="{$filename}"{if $csv_selected == $filename} selected="selected"{/if}>{$filename}</option>
|
||||
<option value="{$filename}"{if $csv_selected == $filename} selected="selected"{/if}>{$filename|escape:'htmlall':'UTF-8'}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
{/if}
|
||||
|
||||
|
||||
<a href="#upload_file_import" id="upload_file_import_link" class="btn btn-default">
|
||||
<i class="icon-plus-sign-alt"></i>
|
||||
{l s='Upload'}
|
||||
</a>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<p class="alert alert-info col-lg-offset-3">
|
||||
<a href="#" onclick="$('#sample_files_import').slideToggle(); return false;">
|
||||
{l s='Click to view our sample import csv files.'}
|
||||
</a>
|
||||
</p>
|
||||
<div id="sample_files_import" style="display:none" class="list-group">
|
||||
<a class="list-group-item" href="../docs/csv_import/categories_import.csv">{l s='Sample Categories file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/products_import.csv">{l s='Sample Products file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/combinations_import.csv">{l s='Sample Combinations file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/customers_import.csv">{l s='Sample Customers file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/addresses_import.csv">{l s='Sample Addresses file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/manufacturers_import.csv">{l s='Sample Manufacturers file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/suppliers_import.csv">{l s='Sample Suppliers file'}</a>
|
||||
{if $PS_ADVANCED_STOCK_MANAGEMENT}
|
||||
<a class="list-group-item" href="../docs/csv_import/supply_orders_import.csv">{l s='Supply Orders sample file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/supply_orders_details_import.csv">{l s='Supply Orders Details sample file'}</a>
|
||||
{/if}
|
||||
<div class="col-lg-6">
|
||||
<p class="alert alert-info">
|
||||
<a href="#" onclick="$('#sample_files_import').slideToggle(); return false;">
|
||||
{l s='Click to view our sample import csv files.'}
|
||||
</a>
|
||||
</p>
|
||||
<div id="sample_files_import" style="display:none" class="list-group">
|
||||
<a class="list-group-item" href="../docs/csv_import/categories_import.csv" target="_blank">{l s='Sample Categories file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/products_import.csv" target="_blank">{l s='Sample Products file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/combinations_import.csv" target="_blank">{l s='Sample Combinations file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/customers_import.csv" target="_blank">{l s='Sample Customers file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/addresses_import.csv" target="_blank">{l s='Sample Addresses file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/manufacturers_import.csv" target="_blank">{l s='Sample Manufacturers file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/suppliers_import.csv" target="_blank">{l s='Sample Suppliers file'}</a>
|
||||
{if $PS_ADVANCED_STOCK_MANAGEMENT}
|
||||
<a class="list-group-item" href="../docs/csv_import/supply_orders_import.csv" target="_blank">{l s='Supply Orders sample file'}</a>
|
||||
<a class="list-group-item" href="../docs/csv_import/supply_orders_details_import.csv" target="_blank">{l s='Supply Orders Details sample file'}</a>
|
||||
{/if}
|
||||
</div>
|
||||
</div>
|
||||
<div class="col-lg-6">
|
||||
<p class="alert alert-info">
|
||||
<a href="#" onclick="$('#csv_files_import').slideToggle(); return false;">
|
||||
{l s='Click to view your csv files.'}
|
||||
</a>
|
||||
</p>
|
||||
|
||||
<ul id="csv_files_import" style="display:none;">
|
||||
{foreach $files_to_import AS $filename}
|
||||
<li>
|
||||
<a href="{$current}&token={$token}&csvfilename={$filename|@base64_encode}">{$filename}</a>
|
||||
<a href="{$current}&token={$token}&csvfilename={$filename|@base64_encode}&delete=1" class="btn btn-default">
|
||||
<i class="icon-trash"></i> {l s='Delete'}
|
||||
</a>
|
||||
</li>
|
||||
{/foreach}
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='What kind of entity would you like to import?'} </label>
|
||||
<div class="col-lg-6">
|
||||
@@ -140,14 +163,14 @@
|
||||
<label class="control-label col-lg-3">{l s='Field separator'} </label>
|
||||
<div class="col-lg-6 input-group">
|
||||
<span class="input-group-addon">{l s='e.g. '}"1; Ipod; 129.90; 5"</span>
|
||||
<input type="text" size="2" value=";" name="separator"/>
|
||||
<input type="text" size="2" value="{if isset($separator_selected)}{$separator_selected|escape:'htmlall':'UTF-8'}{else};{/if}" name="separator"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label col-lg-3">{l s='Multiple value separator'} </label>
|
||||
<div class="col-lg-6 input-group">
|
||||
<span class="input-group-addon">{l s='e.g. '}"Ipod; red.jpg, blue.jpg, green.jpg; 129.90"</span>
|
||||
<input type="text" size="2" value="," name="multiple_value_separator"/>
|
||||
<input type="text" size="2" value="{if isset($multiple_value_separator_selected)}{$multiple_value_separator_selected|escape:'htmlall':'UTF-8'}{else},{/if}" name="multiple_value_separator"/>
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
@@ -172,7 +195,6 @@
|
||||
<input name="regenerate" id="regenerate" type="checkbox" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="form-group">
|
||||
<label for="forceIDs" class="control-label col-lg-3">
|
||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="{l s='If you don\'t use this option, all ID\'s will be auto-incremented.'}">
|
||||
@@ -263,7 +285,7 @@
|
||||
else
|
||||
{
|
||||
$(".import_supply_orders_details").hide();
|
||||
$('input[name=multiple_value_separator]').val(',');
|
||||
$('input[name=multiple_value_separator]').val('{if isset($multiple_value_separator_selected)}{$multiple_value_separator_selected}{else},{/if}');
|
||||
}
|
||||
if ($("#entity > option:selected").val() == 1)
|
||||
$("label[for=match_ref], #match_ref, label[for=regenerate], #regenerate").show();
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
{extends file="helpers/view/view.tpl"}
|
||||
{block name="override_tpl"}
|
||||
<script type="text/javascript">
|
||||
var errorEmpty = '{l s='Please name your matching configuration to save.' js='1'}';
|
||||
var errorEmpty = '{l s='Please name your matching configuration to save.' js=1}';
|
||||
var token = '{$token}';
|
||||
var current = 0;
|
||||
function showTable(nb)
|
||||
@@ -126,4 +126,4 @@
|
||||
</table>
|
||||
</form>
|
||||
</div>
|
||||
{/block}
|
||||
{/block}
|
||||
|
||||
@@ -28,16 +28,14 @@
|
||||
var label_errors = '{l s='errors'}';
|
||||
var label_error = '{l s='error'}';
|
||||
</script>
|
||||
|
||||
<div id="container">
|
||||
<div class="row">
|
||||
<div id="login" class="col-md-4 col-md-offset-4 panel">
|
||||
<div id="login-panel">
|
||||
<div id="login-header" class="panel">
|
||||
<h1 class="text-center">
|
||||
<img width="40px" src="data:image/svg+xml;base64,PD94bWwgdmVyc2lvbj0iMS4wIiBlbmNvZGluZz0idXRmLTgiPz4NCjwhLS0gR2VuZXJhdG9yOiBBZG9iZSBJbGx1c3RyYXRvciAxNi4wLjAsIFNWRyBFeHBvcnQgUGx1Zy1JbiAuIFNWRyBWZXJzaW9uOiA2LjAwIEJ1aWxkIDApICAtLT4NCjwhRE9DVFlQRSBzdmcgUFVCTElDICItLy9XM0MvL0RURCBTVkcgMS4xLy9FTiIgImh0dHA6Ly93d3cudzMub3JnL0dyYXBoaWNzL1NWRy8xLjEvRFREL3N2ZzExLmR0ZCI+DQo8c3ZnIHZlcnNpb249IjEuMSIgaWQ9IkxheWVyXzEiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyIgeG1sbnM6eGxpbms9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkveGxpbmsiIHg9IjBweCIgeT0iMHB4Ig0KCSB3aWR0aD0iNjEycHgiIGhlaWdodD0iNzkycHgiIHZpZXdCb3g9IjAgMCA2MTIgNzkyIiBzdHlsZT0iZW5hYmxlLWJhY2tncm91bmQ6bmV3IDAgMCA2MTIgNzkyOyIgeG1sOnNwYWNlPSJwcmVzZXJ2ZSI+DQo8cGF0aCBkPSJNMjA0LDg2Yy0zNiwyMy00Nyw2MS00MiwxMjBsLTI3LDNDMTMxLDE0NywxNjEsOTgsMjA0LDg2eiBNMjQ1LDc4YzY0LDgsMTAwLDM1LDExNSwxMDVsLTE2OSwyMEMxODUsMTQwLDE5OSwxMDUsMjQ1LDc4eg0KCSBNMjgwLDY0YzcyLDAsMTIwLDI1LDEzNSwxMTJsLTI3LDNDMzc1LDExMiwzNDEsNzYsMjgwLDY0eiBNNDQyLDE3NEM0MjksNTQsMzE0LDE5LDI0MCw1NmMtODMtMi0xNDAsNzMtMTMzLDE1N2wtOTYsMTBsNTgsNTUwDQoJbDI2MS0yNmMtNDctNTMtMTAwLTEzMy0xMjQtMTUyYy0yNy0yMy0zMC0zMS0yMy00NWMxMi0xNCwyNC0xMiw0NSw0bDQ4LDM3bDcsMzZsMTQtMWwtMzctMjMxYy00LTI0LDEtMzUsMTktNDBjMTgtMiwyNyw3LDMxLDM0DQoJbDIzLDE0MWwxOC0yYy03LTUwLTMtNTcsMTctNjJjMTktMywyOCwxMCwzNSw2NGwxNy0xYy01LTUwLTEtNTcsMTktNjBjMjItMSwyNSwxMiwzMiw2NWwxNiwyYy00LTQwLTQtNTEsMTgtNTNjMjEsMCwyNSwxNCwzMSw1OA0KCWMxNSwxMDAsMTMsMTU0LTYsMTgzbDcyLTdsLTU4LTU1NUw0NDIsMTc0eiIvPg0KPC9zdmc+DQo="/>
|
||||
PRESTASHOP
|
||||
PRESTASHOP
|
||||
</h1>
|
||||
<h4 class="text-center">{$shop_name}</h4>
|
||||
<hr/>
|
||||
<h4 class="text-center">{$shop_name}</h4>
|
||||
<div id="error" class="hide alert alert-danger">
|
||||
{if isset($errors)}
|
||||
<h4>
|
||||
@@ -53,104 +51,112 @@
|
||||
</ol>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
{if isset($warningSslMessage)}
|
||||
<div class="alert alert-warning">{$warningSslMessage}</div>
|
||||
{/if}
|
||||
</div>
|
||||
<div class="flip-container">
|
||||
<div class="flipper">
|
||||
<div class="front panel">
|
||||
{if !isset($wrong_folder_name) && !isset($wrong_install_name)}
|
||||
<form action="#" id="login_form" method="post">
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="email">{l s='Email address'}</label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon"><i class="icon-envelope"></i></span>
|
||||
<input
|
||||
name="email"
|
||||
type="text"
|
||||
id="email"
|
||||
class="form-control"
|
||||
value="{if isset($email)}{$email|escape:'htmlall':'UTF-8'}{/if}"
|
||||
autofocus="autofocus"
|
||||
tabindex="1"
|
||||
placeholder="test@example.com" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<a href="#" class="show-forgot-password pull-right" >
|
||||
{l s='Lost password'}…
|
||||
</a>
|
||||
<label class="control-label" for="passwd">
|
||||
{l s='Password'}
|
||||
</label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon"><i class="icon-key"></i></span>
|
||||
<input
|
||||
name="passwd"
|
||||
type="password"
|
||||
id="passwd"
|
||||
class="form-control"
|
||||
value="{if isset($password)}{$password}{/if}"
|
||||
tabindex="2"
|
||||
placeholder="{l s='Password'}" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="checkbox">
|
||||
<label for="stay_logged_in">
|
||||
<input name="stay_logged_in" type="checkbox" id="stay_logged_in" value="1" tabindex="3"/>
|
||||
{l s='Keep me logged in'}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<hr/>
|
||||
<div class="panel-footer">
|
||||
<button name="submitLogin" type="submit" tabindex="4" class="btn btn-default btn-lg btn-block ladda-button" data-style="slide-up" data-spinner-color="black" >
|
||||
<span class="ladda-label">
|
||||
<i class="icon-ok text-success"></i>
|
||||
{l s='Log in'}
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
<input type="hidden" name="redirect" id="redirect" value="{$redirect}"/>
|
||||
</form>
|
||||
</div>
|
||||
|
||||
{if !isset($wrong_folder_name) && !isset($wrong_install_name)}
|
||||
<form action="#" id="login_form" method="post">
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="email">{l s='Email address'}</label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon"><i class="icon-envelope"></i></span>
|
||||
<input
|
||||
name="email"
|
||||
type="text"
|
||||
id="email"
|
||||
class="form-control"
|
||||
value="{if isset($email)}{$email|escape:'htmlall':'UTF-8'}{/if}"
|
||||
autofocus="autofocus"
|
||||
tabindex="1"
|
||||
placeholder="test@example.com" />
|
||||
</div>
|
||||
<div class="back panel">
|
||||
<form action="#" id="forgot_password_form" method="post" class="hide">
|
||||
<div class="alert alert-info">
|
||||
<h4 class="text-center">
|
||||
<i class="icon-exclamation-sign"></i>
|
||||
{l s='Forgot your password?'}
|
||||
</h4>
|
||||
<p>{l s='In order to receive your access code by email, please enter the address you provided during the registration process.'}</p>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="email_forgot">
|
||||
{l s='Email address'}
|
||||
</label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon"><i class="icon-envelope"></i></span>
|
||||
<input
|
||||
type="text"
|
||||
name="email_forgot"
|
||||
id="email_forgot"
|
||||
class="form-control"
|
||||
autofocus="autofocus"
|
||||
tabindex="1"
|
||||
placeholder="test@example.com" />
|
||||
</div>
|
||||
</div>
|
||||
<hr/>
|
||||
<div class="panel-footer">
|
||||
<button href="#" class="btn btn-default show-login-form" tabindex="3">
|
||||
<i class="icon-caret-left"></i>
|
||||
{l s='Back to login'}
|
||||
</button>
|
||||
<button class="btn btn-default pull-right" name="submitLogin" type="submit" tabindex="2">
|
||||
<i class="icon-ok text-success"></i>
|
||||
{l s='Send'}
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<a href="#" class="show-forgot-password pull-right" >
|
||||
{l s='Lost password'}…
|
||||
</a>
|
||||
<label class="control-label" for="passwd">
|
||||
{l s='Password'}
|
||||
</label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon"><i class="icon-key"></i></span>
|
||||
<input
|
||||
name="passwd"
|
||||
type="password"
|
||||
id="passwd"
|
||||
class="form-control"
|
||||
value="{if isset($password)}{$password}{/if}"
|
||||
tabindex="2"
|
||||
placeholder="{l s='Password'}" />
|
||||
</div>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<div class="checkbox">
|
||||
<label for="stay_logged_in">
|
||||
<input name="stay_logged_in" type="checkbox" id="stay_logged_in" value="1" tabindex="3"/>
|
||||
{l s='Keep me logged in'}
|
||||
</label>
|
||||
</div>
|
||||
</div>
|
||||
<hr/>
|
||||
<div class="form-group">
|
||||
<button name="submitLogin" type="submit" tabindex="4" class="btn btn-default btn-lg btn-block ladda-button" data-style="slide-up" data-spinner-color="black" >
|
||||
<span class="ladda-label">
|
||||
<i class="icon-ok text-success"></i>
|
||||
{l s='Log in'}
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
<input type="hidden" name="redirect" id="redirect" value="{$redirect}"/>
|
||||
</form>
|
||||
|
||||
<form action="#" id="forgot_password_form" method="post" class="hide">
|
||||
<div class="alert alert-info">
|
||||
<h4 class="text-center">
|
||||
<i class="icon-exclamation-sign"></i>
|
||||
{l s='Forgot your password?'}
|
||||
</h4>
|
||||
<p>{l s='In order to receive your access code by email, please enter the address you provided during the registration process.'}</p>
|
||||
</div>
|
||||
<div class="form-group">
|
||||
<label class="control-label" for="email_forgot">
|
||||
{l s='Email address'}
|
||||
</label>
|
||||
<div class="input-group">
|
||||
<span class="input-group-addon"><i class="icon-envelope"></i></span>
|
||||
<input
|
||||
type="text"
|
||||
name="email_forgot"
|
||||
id="email_forgot"
|
||||
class="form-control"
|
||||
autofocus="autofocus"
|
||||
tabindex="1"
|
||||
placeholder="test@example.com" />
|
||||
</div>
|
||||
</div>
|
||||
<hr/>
|
||||
<div class="form-group">
|
||||
<button href="#" class="btn btn-default show-login-form" tabindex="3">
|
||||
<i class="icon-caret-left text-danger"></i>
|
||||
{l s='Back to login'}
|
||||
</button>
|
||||
<button class="btn btn-default pull-right" name="submitLogin" type="submit" tabindex="2">
|
||||
<i class="icon-ok text-success"></i>
|
||||
{l s='Send'}
|
||||
</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
{else}
|
||||
<div class="col-lg-12">
|
||||
<div class="alert alert-danger">
|
||||
<p>{l s='For security reasons, you cannot connect to the Back Office until after you have:'}</p>
|
||||
<ul>
|
||||
{if isset($wrong_install_name) && $wrong_install_name == true}
|
||||
@@ -168,27 +174,25 @@
|
||||
</div>
|
||||
{/if}
|
||||
</div>
|
||||
|
||||
<div class="col-md-4 col-md-offset-4">
|
||||
<p class="text-center text-muted">
|
||||
<a href="http://www.prestashop.com">
|
||||
© PrestaShop 2005-{$smarty.now|date_format:"%Y"} - All rights reserved.
|
||||
</a>
|
||||
</p>
|
||||
<p class="text-center">
|
||||
<a class="link-social link-twitter" href="#" title="Twitter">
|
||||
<i class="icon-twitter"></i>
|
||||
</a>
|
||||
<a class="link-social link-facebook" href="#" title="Facebook">
|
||||
<i class="icon-facebook"></i>
|
||||
</a>
|
||||
<a class="link-social link-github" href="#" title="Github">
|
||||
<i class="icon-github"></i>
|
||||
</a>
|
||||
<a class="link-social link-google" href="#" title="Google">
|
||||
<i class="icon-google-plus"></i>
|
||||
</a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div id="login-footer">
|
||||
<p class="text-center text-muted">
|
||||
<a href="http://www.prestashop.com">
|
||||
© PrestaShop 2005-{$smarty.now|date_format:"%Y"} - All rights reserved.
|
||||
</a>
|
||||
</p>
|
||||
<p class="text-center">
|
||||
<a class="link-social link-twitter" href="#" title="Twitter">
|
||||
<i class="icon-twitter"></i>
|
||||
</a>
|
||||
<a class="link-social link-facebook" href="#" title="Facebook">
|
||||
<i class="icon-facebook"></i>
|
||||
</a>
|
||||
<a class="link-social link-github" href="#" title="Github">
|
||||
<i class="icon-github"></i>
|
||||
</a>
|
||||
<a class="link-social link-google" href="#" title="Google">
|
||||
<i class="icon-google-plus"></i>
|
||||
</a>
|
||||
</p>
|
||||
</div>
|
||||
@@ -104,7 +104,7 @@
|
||||
{$module->description}
|
||||
{/if}
|
||||
</p>
|
||||
{if isset($module->message) && (!isset($module->type) || ($module->type != 'addonsMustHave' || $module->type !== 'addonsNative'))}<div class="alert alert-success">{$module->message}</div>{/if}
|
||||
{if isset($module->message) && (empty($module->name) !== false) && (!isset($module->type) || ($module->type != 'addonsMustHave' || $module->type !== 'addonsNative'))}<div class="alert alert-success">{$module->message}</div>{/if}
|
||||
</div>
|
||||
</td>
|
||||
<td>
|
||||
|
||||
@@ -64,7 +64,7 @@
|
||||
</span>
|
||||
{/if}
|
||||
</td>
|
||||
{if $display_warehouse}<td>{$product.warehouse_name|escape:'htmlall':'UTF-8'}</td>{/if}
|
||||
{if $display_warehouse}<td align="center">{$product.warehouse_name|escape:'htmlall':'UTF-8'}</td>{/if}
|
||||
{if ($order->hasBeenPaid())}
|
||||
<td class="productQuantity">
|
||||
{$product['product_quantity_refunded']}
|
||||
|
||||
@@ -38,6 +38,11 @@
|
||||
var defaults_order_state = new Array();
|
||||
var customization_errors = false;
|
||||
var pic_dir = '{$pic_dir}';
|
||||
var currency_format = 5;
|
||||
var currency_sign = '';
|
||||
var currency_blank = false;
|
||||
var priceDisplayPrecision = 2;
|
||||
|
||||
{foreach from=$defaults_order_state key='module' item='id_order_state'}
|
||||
defaults_order_state['{$module}'] = '{$id_order_state}';
|
||||
{/foreach}
|
||||
@@ -505,7 +510,6 @@
|
||||
}
|
||||
displaySummary(res);
|
||||
resetBind();
|
||||
updateCurrencySign();
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -652,11 +656,12 @@
|
||||
var id_product = Number(this.id_product);
|
||||
var id_product_attribute = Number(this.id_product_attribute);
|
||||
cart_quantity[Number(this.id_product)+'_'+Number(this.id_product_attribute)+'_'+Number(this.id_customization)] = this.cart_quantity;
|
||||
cart_content += '<tr><td><img src="'+this.image_link+'" title="'+this.name+'" /></td><td>'+this.name+'<br />'+this.attributes_small+'</td><td>'+this.reference+'</td><td><input type="text" size="7" rel="'+this.id_product+'_'+this.id_product_attribute+'" class="product_unit_price" value="'+this.price+'" /> <span class="currency_sign"></span></td><td>';
|
||||
cart_content += '<tr><td><img src="'+this.image_link+'" title="'+this.name+'" /></td><td>'+this.name+'<br />'+this.attributes_small+'</td><td>'+this.reference+'</td><td><input type="text" size="7" rel="'+this.id_product+'_'+this.id_product_attribute+'" class="product_unit_price" value="' + formatCurrency(parseFloat(this.price.replace(',', '.')), currency_format, currency_sign, currency_blank) + '" /></td><td>';
|
||||
cart_content += (!this.id_customization ? '<div style="float:left;"><a href="#" class="increaseqty_product" rel="'+this.id_product+'_'+this.id_product_attribute+'_'+(this.id_customization ? this.id_customization : 0)+'" ><img src="../img/admin/up.gif" /></a><br /><a href="#" class="decreaseqty_product" rel="'+this.id_product+'_'+this.id_product_attribute+'_'+(this.id_customization ? this.id_customization : 0)+'"><img src="../img/admin/down.gif" /></a></div>' : '');
|
||||
cart_content += (!this.id_customization ? '<div style="float:left;"><input type="text" rel="'+this.id_product+'_'+this.id_product_attribute+'_'+(this.id_customization ? this.id_customization : 0)+'" class="cart_quantity" size="2" value="'+this.cart_quantity+'" />' : '');
|
||||
cart_content += (!this.id_customization ? '<a href="#" class="delete_product" rel="delete_'+this.id_product+'_'+this.id_product_attribute+'_'+(this.id_customization ? this.id_customization : 0)+'" ><img src="../img/admin/delete.gif" /></a></div>' : '');
|
||||
cart_content += '</td><td>'+this.total+' <span class="currency_sign"></span></td></tr>';
|
||||
cart_content += '</td><td>' + formatCurrency(parseFloat(this.total.replace(',', '.')), currency_format, currency_sign, currency_blank) + '</td></tr>';
|
||||
|
||||
if (this.id_customization && this.id_customization != 0)
|
||||
{
|
||||
$.each(this.customized_datas[this.id_product][this.id_product_attribute][id_address_delivery], function() {
|
||||
@@ -712,6 +717,11 @@
|
||||
|
||||
function displaySummary(jsonSummary)
|
||||
{
|
||||
currency_format = jsonSummary.currency.format;
|
||||
currency_sign = jsonSummary.currency.sign;
|
||||
currency_blank = jsonSummary.currency.blank;
|
||||
priceDisplayPrecision = jsonSummary.currency.decimals ? 2 : 0;
|
||||
|
||||
updateCartProducts(jsonSummary.summary.products, jsonSummary.summary.gift_products, jsonSummary.cart.id_address_delivery);
|
||||
updateCartVouchers(jsonSummary.summary.discounts);
|
||||
updateAddressesList(jsonSummary.addresses, jsonSummary.cart.id_address_delivery, jsonSummary.cart.id_address_invoice);
|
||||
@@ -737,20 +747,19 @@
|
||||
$('#free_shipping').removeAttr('checked');
|
||||
|
||||
$('#gift_message').html(jsonSummary.cart.gift_message);
|
||||
if(!changed_shipping_price)
|
||||
$('#shipping_price').html('<b>'+jsonSummary.summary.total_shipping+'</b>');
|
||||
if (!changed_shipping_price)
|
||||
$('#shipping_price').html('<b>' + formatCurrency(parseFloat(jsonSummary.summary.total_shipping), currency_format, currency_sign, currency_blank) + '</b>');
|
||||
shipping_price_selected_carrier = jsonSummary.summary.total_shipping;
|
||||
|
||||
$('#total_vouchers').html(jsonSummary.summary.total_discounts_tax_exc);
|
||||
$('#total_shipping').html(jsonSummary.summary.total_shipping_tax_exc);
|
||||
$('#total_taxes').html(jsonSummary.summary.total_tax);
|
||||
$('#total_without_taxes').html(jsonSummary.summary.total_price_without_tax);
|
||||
$('#total_with_taxes').html(jsonSummary.summary.total_price);
|
||||
$('#total_products').html(jsonSummary.summary.total_products);
|
||||
|
||||
$('#total_vouchers').html(formatCurrency(parseFloat(jsonSummary.summary.total_discounts_tax_exc.replace(',', '.')), currency_format, currency_sign, currency_blank));
|
||||
$('#total_shipping').html(formatCurrency(parseFloat(jsonSummary.summary.total_shipping_tax_exc.replace(',', '.')), currency_format, currency_sign, currency_blank));
|
||||
$('#total_taxes').html(formatCurrency(parseFloat(jsonSummary.summary.total_tax.replace(',', '.')), currency_format, currency_sign, currency_blank));
|
||||
$('#total_without_taxes').html(formatCurrency(parseFloat(jsonSummary.summary.total_price_without_tax.replace(',', '.')), currency_format, currency_sign, currency_blank));
|
||||
$('#total_with_taxes').html(formatCurrency(parseFloat(jsonSummary.summary.total_price.replace(',', '.')), currency_format, currency_sign, currency_blank));
|
||||
$('#total_products').html(formatCurrency(parseFloat(jsonSummary.summary.total_products.replace(',', '.')), currency_format, currency_sign, currency_blank));
|
||||
id_currency = jsonSummary.cart.id_currency;
|
||||
$('#id_currency option').removeAttr('selected');
|
||||
$('#id_currency option[value="'+id_currency+'"]').attr('selected', true);
|
||||
updateCurrencySign();
|
||||
id_lang = jsonSummary.cart.id_lang;
|
||||
$('#id_lang option').removeAttr('selected');
|
||||
$('#id_lang option[value="'+id_lang+'"]').attr('selected', true);
|
||||
@@ -778,21 +787,21 @@
|
||||
qty: qty,
|
||||
id_customer: id_customer,
|
||||
id_cart: id_cart,
|
||||
},
|
||||
},
|
||||
success : function(res)
|
||||
{
|
||||
displaySummary(res);
|
||||
var errors = '';
|
||||
if(res.errors.length)
|
||||
{
|
||||
$.each(res.errors, function() {
|
||||
errors += this+'<br />';
|
||||
});
|
||||
$('#products_err').show();
|
||||
}
|
||||
else
|
||||
$('#products_err').hide();
|
||||
$('#products_err').html(errors);
|
||||
displaySummary(res);
|
||||
var errors = '';
|
||||
if (res.errors.length)
|
||||
{
|
||||
$.each(res.errors, function() {
|
||||
errors += this + '<br />';
|
||||
});
|
||||
$('#products_err').show();
|
||||
}
|
||||
else
|
||||
$('#products_err').hide();
|
||||
$('#products_err').html(errors);
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -888,11 +897,6 @@
|
||||
});
|
||||
}
|
||||
|
||||
function updateCurrencySign()
|
||||
{
|
||||
$('.currency_sign').html(currencies[id_currency]);
|
||||
}
|
||||
|
||||
function sendMailToCustomer()
|
||||
{
|
||||
$.ajax({
|
||||
@@ -925,11 +929,33 @@
|
||||
var addresses_invoice_options = '';
|
||||
var address_invoice_detail = '';
|
||||
var address_delivery_detail = '';
|
||||
var delivery_address_edit_link = '';
|
||||
var invoice_address_edit_link = '';
|
||||
|
||||
$.each(addresses, function() {
|
||||
if (this.id_address == id_address_invoice)
|
||||
address_invoice_detail = this.company+' '+this.firstname+' '+this.lastname+'<br />'+this.address1+'<br />'+this.address2+'<br />'+this.postcode+' '+this.city+' '+this.country;
|
||||
{
|
||||
address_invoice_detail = this.company+' '+this.firstname+' '+this.lastname+'<br />'+this.address1+'<br />'+this.address2+'<br />'+this.postcode+' '+this.city;
|
||||
|
||||
if (this.state != null)
|
||||
address_invoice_detail += ' '+this.state;
|
||||
|
||||
address_invoice_detail += '</br>'+this.country;
|
||||
|
||||
invoice_address_edit_link = "{$link->getAdminLink('AdminAddresses')}&id_address="+this.id_address+"&updateaddress&realedit=1&liteDisplaying=1&submitFormAjax=1#";
|
||||
}
|
||||
|
||||
if(this.id_address == id_address_delivery)
|
||||
address_delivery_detail = this.company+' '+this.firstname+' '+this.lastname+'<br />'+this.address1+'<br />'+this.address2+'<br />'+this.postcode+' '+this.city+' '+this.country;
|
||||
{
|
||||
address_delivery_detail = this.company+' '+this.firstname+' '+this.lastname+'<br />'+this.address1+'<br />'+this.address2+'<br />'+this.postcode+' '+this.city;
|
||||
|
||||
if (this.state != null)
|
||||
address_delivery_detail += ' '+this.state;
|
||||
|
||||
address_delivery_detail += '</br>'+this.country;
|
||||
|
||||
delivery_address_edit_link = "{$link->getAdminLink('AdminAddresses')}&id_address="+this.id_address+"&updateaddress&realedit=1&liteDisplaying=1&submitFormAjax=1#";
|
||||
}
|
||||
|
||||
addresses_delivery_options += '<option value="'+this.id_address+'" '+(this.id_address == id_address_delivery ? 'selected="selected"' : '')+'>'+this.alias+'</option>';
|
||||
addresses_invoice_options += '<option value="'+this.id_address+'" '+(this.id_address == id_address_invoice ? 'selected="selected"' : '')+'>'+this.alias+'</option>';
|
||||
@@ -949,6 +975,8 @@
|
||||
$('#id_address_invoice').html(addresses_invoice_options);
|
||||
$('#address_delivery_detail').html(address_delivery_detail);
|
||||
$('#address_invoice_detail').html(address_invoice_detail);
|
||||
$('#edit_delivery_address').attr('href', delivery_address_edit_link);
|
||||
$('#edit_invoice_address').attr('href', invoice_address_edit_link);
|
||||
}
|
||||
|
||||
function updateAddresses()
|
||||
@@ -992,7 +1020,7 @@
|
||||
</a>
|
||||
</div>
|
||||
<label class="control-label col-lg-3">
|
||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="{l s='Search a customer by tapping the first letters of his/her name'}">
|
||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="{l s='Search a customer by typping the first letters of his/her name'}">
|
||||
{l s='Search customers'}
|
||||
</span>
|
||||
</label>
|
||||
@@ -1013,7 +1041,7 @@
|
||||
</h3>
|
||||
<div class="row">
|
||||
<label class="control-label col-lg-3">
|
||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="{l s='Search a product by tapping the first letters of his/her name.'}">
|
||||
<span title="" data-toggle="tooltip" class="label-tooltip" data-original-title="{l s='Search a product by typping the first letters of his/her name.'}">
|
||||
{l s='Search for a product'}
|
||||
</span>
|
||||
</label>
|
||||
@@ -1132,7 +1160,7 @@
|
||||
<i class="icon-folder-close"></i>
|
||||
{l s='Carts'}
|
||||
</h4>
|
||||
<table cellspacing="0" cellpadding="0" class="table width5">
|
||||
<table cellspacing="0" cellpadding="0" class="table width5">
|
||||
<colgroup>
|
||||
<col width="10">
|
||||
<col width="200">
|
||||
@@ -1204,7 +1232,6 @@
|
||||
<input type="text" id="voucher" value="" />
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="margin-form">
|
||||
<table cellspacing="0" cellpadding="0" class="table" id="voucher_list">
|
||||
<thead>
|
||||
@@ -1278,7 +1305,7 @@
|
||||
{l s='Shipping price:'}
|
||||
</label>
|
||||
<div class="col-lg-6">
|
||||
<span id="shipping_price" name="shipping_price"></span> <span class="currency_sign"></span>
|
||||
<span id="shipping_price" name="shipping_price"></span>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
@@ -1311,12 +1338,12 @@
|
||||
<div class="row">
|
||||
<div id="cart_summary" class="col-lg-12">
|
||||
<ul class="nav navbar-nav">
|
||||
<li><span>{l s='Total products:'}</span> <span id="total_products"></span><span class="currency_sign"></span> |</li>
|
||||
<li><span>{l s='Total vouchers:'}</span> <span id="total_vouchers"></span><span class="currency_sign"></span> |</li>
|
||||
<li><span>{l s='Total shipping:'}</span> <span id="total_shipping"></span><span class="currency_sign"></span> |</li>
|
||||
<li><span>{l s='Total taxes:'}</span> <span id="total_taxes"></span><span class="currency_sign"></span> |</li>
|
||||
<li><span>{l s='Total without taxes:'}</span> <span id="total_without_taxes"></span><span class="currency_sign"></span> |</li>
|
||||
<li><span>{l s='Total with taxes'}</span> <span id="total_with_taxes"></span><span class="currency_sign"></span></li>
|
||||
<li><span>{l s='Total products:'}</span> <span id="total_products"></span></li>
|
||||
<li><span>{l s='Total vouchers:'}</span> <span id="total_vouchers"></span></li>
|
||||
<li><span>{l s='Total shipping:'}</span> <span id="total_shipping"></span></li>
|
||||
<li><span>{l s='Total taxes:'}</span> <span id="total_taxes"></span></li>
|
||||
<li><span>{l s='Total without taxes:'}</span> <span id="total_without_taxes"></span></li>
|
||||
<li><span>{l s='Total with taxes'}</span> <span id="total_with_taxes"></span></li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
+1
-1
@@ -42,7 +42,7 @@
|
||||
<div class="col-lg-8">
|
||||
<select id="id_category" name="id_category">
|
||||
{foreach from=$categories item='category'}
|
||||
<option value="{$category.id_category}">{$category.name}</option>
|
||||
<option value="{$category.id_category|intval}">({$category.id_category|intval}) {$category.name}</option>
|
||||
{/foreach}
|
||||
</select>
|
||||
</div>
|
||||
|
||||
@@ -68,17 +68,8 @@
|
||||
</div>
|
||||
<script type="text/javascript">
|
||||
$(function() {
|
||||
var translated_dates = {
|
||||
days: ["{l s='Sunday'}", "{l s='Monday'}", "{l s='Tuesday'}", "{l s='Wednesday'}", "{l s='Thursday'}", "{l s='Friday'}", "{l s='Saturday'}", "{l s='Sunday'}"],
|
||||
daysShort: ["{l s='Sun'}", "{l s='Mon'}", "{l s='Tue'}", "{l s='Wed'}", "{l s='Thu'}", "{l s='Fri'}", "{l s='Sat'}", "{l s='Sun'}"],
|
||||
daysMin: ["{l s='Su'}", "{l s='Mo'}", "{l s='Tu'}", "{l s='We'}", "{l s='Th'}", "{l s='Fr'}", "{l s='Sa'}", "{l s='Su'}"],
|
||||
months: ["{l s='January'}", "{l s='February'}", "{l s='March'}", "{l s='April'}", "{l s='May'}", "{l s='June'}", "{l s='July'}", "{l s='August'}", "{l s='September'}", "{l s='October'}", "{l s='November'}", "{l s='December'}"],
|
||||
monthsShort: ["{l s='Jan'}", "{l s='Feb'}", "{l s='Mar'}", "{l s='Apr'}", "{l s='May'}", "{l s='Jun'}", "{l s='Jul'}", "{l s='Aug'}", "{l s='Sep'}", "{l s='Oct'}", "{l s='Nov'}", "{l s='Dec'}"]
|
||||
}
|
||||
{literal}
|
||||
$('.datepicker1').datepicker({"dates": translated_dates, "weekStart": 1});
|
||||
$('.datepicker2').datepicker({"dates": translated_dates, "weekStart": 1});
|
||||
{/literal}
|
||||
$('.datepicker1').datepicker();
|
||||
$('.datepicker2').datepicker();
|
||||
$("#date-start").focus().addClass("input-selected");
|
||||
});
|
||||
</script>
|
||||
@@ -360,7 +360,6 @@
|
||||
{/if}
|
||||
{elseif $input.type == 'radio'}
|
||||
{foreach $input.values as $value}
|
||||
|
||||
<div class="radio {if isset($input.class)}"{$input.class}"{/if}">
|
||||
<label>
|
||||
<input type="radio" name="{$input.name}" id="{$value.id}" value="{$value.value|escape:'htmlall':'UTF-8'}"
|
||||
|
||||
+11
-7
@@ -340,6 +340,7 @@ class CartCore extends ObjectModel
|
||||
'.($filter == CartRule::FILTER_ACTION_SHIPPING ? 'AND free_shipping = 1' : '').'
|
||||
'.($filter == CartRule::FILTER_ACTION_GIFT ? 'AND gift_product != 0' : '').'
|
||||
'.($filter == CartRule::FILTER_ACTION_REDUCTION ? 'AND (reduction_percent != 0 OR reduction_amount != 0)' : '')
|
||||
.' ORDER by cr.priority ASC'
|
||||
);
|
||||
Cache::store($cache_key, $result);
|
||||
}
|
||||
@@ -429,7 +430,7 @@ class CartCore extends ObjectModel
|
||||
product_shop.`available_for_order`, product_shop.`price`, product_shop.`active`, product_shop.`unity`, product_shop.`unit_price_ratio`,
|
||||
stock.`quantity` AS quantity_available, p.`width`, p.`height`, p.`depth`, stock.`out_of_stock`, p.`weight`,
|
||||
p.`date_add`, p.`date_upd`, IFNULL(stock.quantity, 0) as quantity, pl.`link_rewrite`, cl.`link_rewrite` AS category,
|
||||
CONCAT(cp.`id_product`, IFNULL(cp.`id_product_attribute`, 0), IFNULL(cp.`id_address_delivery`, 0)) AS unique_id, cp.id_address_delivery,
|
||||
CONCAT(LPAD(cp.`id_product`, 10, 0), LPAD(IFNULL(cp.`id_product_attribute`, 0), 10, 0), IFNULL(cp.`id_address_delivery`, 0)) AS unique_id, cp.id_address_delivery,
|
||||
product_shop.`wholesale_price`, product_shop.advanced_stock_management, ps.product_supplier_reference supplier_reference');
|
||||
|
||||
// Build FROM
|
||||
@@ -1260,7 +1261,7 @@ class CartCore extends ObjectModel
|
||||
return true;
|
||||
}
|
||||
|
||||
public static function getTotalCart($id_cart, $use_tax_display = false, $type = CART::BOTH)
|
||||
public static function getTotalCart($id_cart, $use_tax_display = false, $type = Cart::BOTH)
|
||||
{
|
||||
$cart = new Cart($id_cart);
|
||||
if (!Validate::isLoadedObject($cart))
|
||||
@@ -1676,6 +1677,7 @@ class CartCore extends ObjectModel
|
||||
$warehouse_count_by_address[$product['id_address_delivery']][$warehouse['id_warehouse']]++;
|
||||
}
|
||||
}
|
||||
unset($product);
|
||||
|
||||
arsort($warehouse_count_by_address);
|
||||
|
||||
@@ -1693,9 +1695,12 @@ class CartCore extends ObjectModel
|
||||
$id_warehouse = 0;
|
||||
foreach ($warehouse_count_by_address[$product['id_address_delivery']] as $id_war => $val)
|
||||
{
|
||||
$product['carrier_list'] = array_merge($product['carrier_list'], Carrier::getAvailableCarrierList(new Product($product['id_product']), $id_war, $product['id_address_delivery'], null, $this));
|
||||
if (in_array((int)$id_war, $product['warehouse_list']) && $id_warehouse == 0)
|
||||
$id_warehouse = (int)$id_war;
|
||||
if (in_array((int)$id_war, $product['warehouse_list']))
|
||||
{
|
||||
$product['carrier_list'] = array_merge($product['carrier_list'], Carrier::getAvailableCarrierList(new Product($product['id_product']), $id_war, $product['id_address_delivery'], null, $this));
|
||||
if (!$id_warehouse)
|
||||
$id_warehouse = (int)$id_war;
|
||||
}
|
||||
}
|
||||
|
||||
if (!isset($grouped_by_warehouse[$product['id_address_delivery']]['in_stock'][$id_warehouse]))
|
||||
@@ -1714,6 +1719,7 @@ class CartCore extends ObjectModel
|
||||
|
||||
$grouped_by_warehouse[$product['id_address_delivery']][$key][$id_warehouse][] = $product;
|
||||
}
|
||||
unset($product);
|
||||
|
||||
// Step 3 : grouped product from grouped_by_warehouse by available carriers
|
||||
$grouped_by_carriers = array();
|
||||
@@ -1732,7 +1738,6 @@ class CartCore extends ObjectModel
|
||||
{
|
||||
if (!isset($grouped_by_carriers[$id_address_delivery][$key][$id_warehouse]))
|
||||
$grouped_by_carriers[$id_address_delivery][$key][$id_warehouse] = array();
|
||||
|
||||
foreach ($product_list as $product)
|
||||
{
|
||||
$package_carriers_key = implode(',', $product['carrier_list']);
|
||||
@@ -1797,7 +1802,6 @@ class CartCore extends ObjectModel
|
||||
);
|
||||
$package_list[$id_address_delivery][$key][$id_warehouse][$id_carrier]['carrier_list'] =
|
||||
array_intersect($package_list[$id_address_delivery][$key][$id_warehouse][$id_carrier]['carrier_list'], $data['carrier_list']);
|
||||
|
||||
$package_list[$id_address_delivery][$key][$id_warehouse][$id_carrier]['product_list'] =
|
||||
array_merge($package_list[$id_address_delivery][$key][$id_warehouse][$id_carrier]['product_list'], $data['product_list']);
|
||||
|
||||
|
||||
@@ -105,8 +105,9 @@ class CategoryCore extends ObjectModel
|
||||
'position' => array('type' => self::TYPE_INT),
|
||||
'date_add' => array('type' => self::TYPE_DATE, 'validate' => 'isDate'),
|
||||
'date_upd' => array('type' => self::TYPE_DATE, 'validate' => 'isDate'),
|
||||
'name' => array('type' => self::TYPE_STRING, 'lang' => true, 'validate' => 'isCatalogName', 'required' => true, 'size' => 64),
|
||||
'link_rewrite' => array('type' => self::TYPE_STRING, 'lang' => true, 'validate' => 'isLinkRewrite', 'required' => true, 'size' => 64),
|
||||
// Lang fields
|
||||
'name' => array('type' => self::TYPE_STRING, 'lang' => true, 'validate' => 'isCatalogName', 'required' => true, 'size' => 128),
|
||||
'link_rewrite' => array('type' => self::TYPE_STRING, 'lang' => true, 'validate' => 'isLinkRewrite', 'required' => true, 'size' => 128),
|
||||
'description' => array('type' => self::TYPE_HTML, 'lang' => true, 'validate' => 'isCleanHtml'),
|
||||
'meta_title' => array('type' => self::TYPE_STRING, 'lang' => true, 'validate' => 'isGenericName', 'size' => 128),
|
||||
'meta_description' => array('type' => self::TYPE_STRING, 'lang' => true, 'validate' => 'isGenericName', 'size' => 255),
|
||||
|
||||
@@ -188,8 +188,9 @@ class CurrencyCore extends ObjectModel
|
||||
4 => array('left' => '', 'right' => &$formated_strings['right']),
|
||||
5 => array('left' => '', 'right' => &$formated_strings['right'])
|
||||
);
|
||||
|
||||
return ($formats[$this->format][$side]);
|
||||
if (isset($formats[$this->format][$side]))
|
||||
return ($formats[$this->format][$side]);
|
||||
return $this->sign;
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
+34
-24
@@ -128,34 +128,44 @@ class FeatureValueCore extends ObjectModel
|
||||
return $tab['value'];
|
||||
}
|
||||
|
||||
public static function addFeatureValueImport($id_feature, $name)
|
||||
public static function addFeatureValueImport($id_feature, $value, $id_product = null, $id_lang = null)
|
||||
{
|
||||
$rq = Db::getInstance()->executeS('
|
||||
SELECT fv.`id_feature_value`
|
||||
FROM '._DB_PREFIX_.'feature_value fv
|
||||
LEFT JOIN '._DB_PREFIX_.'feature_value_lang fvl
|
||||
ON (fvl.`id_feature_value` = fv.`id_feature_value`)
|
||||
WHERE `value` = \''.pSQL($name).'\'
|
||||
AND fv.`id_feature` = '.(int)$id_feature.'
|
||||
GROUP BY fv.`id_feature_value` LIMIT 1
|
||||
');
|
||||
|
||||
if (!isset($rq[0]['id_feature_value']) || !$id_feature_value = (int)$rq[0]['id_feature_value'])
|
||||
if (!is_null($id_product) && $id_product)
|
||||
{
|
||||
// Feature doesn't exist, create it
|
||||
$feature_value = new FeatureValue();
|
||||
$id_feature_value = Db::getInstance()->getValue('
|
||||
SELECT `id_feature_value`
|
||||
FROM '._DB_PREFIX_.'feature_product
|
||||
WHERE `id_feature` = '.(int)$id_feature.'
|
||||
AND `id_product` = '.(int)$id_product);
|
||||
|
||||
$languages = Language::getLanguages();
|
||||
foreach ($languages as $language)
|
||||
$feature_value->value[$language['id_lang']] = strval($name);
|
||||
|
||||
$feature_value->id_feature = (int)$id_feature;
|
||||
$feature_value->custom = 1;
|
||||
$feature_value->add();
|
||||
|
||||
return (int)$feature_value->id;
|
||||
if ($id_feature_value && !is_null($id_lang) && $id_lang)
|
||||
Db::getInstance()->execute('
|
||||
UPDATE '._DB_PREFIX_.'feature_value_lang
|
||||
SET `value` = \''.pSQL($value).'\'
|
||||
WHERE `id_feature_value` = '.(int)$id_feature_value.'
|
||||
AND `id_lang` = '.(int)$id_lang);
|
||||
}
|
||||
return (int)$id_feature_value;
|
||||
else
|
||||
$id_feature_value = Db::getInstance()->getValue('
|
||||
SELECT fv.`id_feature_value`
|
||||
FROM '._DB_PREFIX_.'feature_value fv
|
||||
LEFT JOIN '._DB_PREFIX_.'feature_value_lang fvl ON (fvl.`id_feature_value` = fv.`id_feature_value`)
|
||||
WHERE `value` = \''.pSQL($value).'\'
|
||||
AND fv.`id_feature` = '.(int)$id_feature.'
|
||||
GROUP BY fv.`id_feature_value`');
|
||||
|
||||
if ($id_feature_value)
|
||||
return (int)$id_feature_value;
|
||||
|
||||
// Feature doesn't exist, create it
|
||||
$feature_value = new FeatureValue();
|
||||
$feature_value->id_feature = (int)$id_feature;
|
||||
$feature_value->custom = 0;
|
||||
foreach (Language::getLanguages() as $language)
|
||||
$feature_value->value[$language['id_lang']] = $value;
|
||||
$feature_value->add();
|
||||
|
||||
return (int)$feature_value->id;
|
||||
}
|
||||
|
||||
public function add($autodate = true, $nullValues = false)
|
||||
|
||||
+19
-2
@@ -316,6 +316,23 @@ class GroupCore extends ObjectModel
|
||||
|
||||
return $groups[$id_group];
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Light back office search for Group
|
||||
*
|
||||
* @param integer $id_lang Language ID
|
||||
* @param string $query Searched string
|
||||
* @param boolean $unrestricted allows search without lang and includes first group and exact match
|
||||
* @return array Corresponding groupes
|
||||
*/
|
||||
public static function searchByName($id_lang, $query)
|
||||
{
|
||||
return Db::getInstance()->getRow('
|
||||
SELECT g.*, gl.*
|
||||
FROM `'._DB_PREFIX_.'group` g
|
||||
LEFT JOIN `'._DB_PREFIX_.'group_lang` gl
|
||||
ON (g.`id_group` = gl.`id_group`)
|
||||
WHERE `name` LIKE \''.pSQL($query).'\'
|
||||
');
|
||||
}
|
||||
}
|
||||
@@ -137,6 +137,7 @@ class GroupReductionCore extends ObjectModel
|
||||
SELECT `reduction`
|
||||
FROM `'._DB_PREFIX_.'product_group_reduction_cache`
|
||||
WHERE `id_product` = '.(int)$id_product.' AND `id_group` = '.(int)$id_group);
|
||||
// Should return string (decimal in database) and not a float
|
||||
return self::$reduction_cache[$id_product.'-'.$id_group];
|
||||
}
|
||||
|
||||
|
||||
+1
-1
@@ -316,7 +316,7 @@ class HookCore extends ObjectModel
|
||||
if (Validate::isLoadedObject($context->country))
|
||||
$sql->where('(h.name = "displayPayment" AND (SELECT id_country FROM '._DB_PREFIX_.'module_country mc WHERE mc.id_module = m.id_module AND id_country = '.(int)$context->country->id.' AND id_shop = '.(int)$context->shop->id.' LIMIT 1) = '.(int)$context->country->id.')');
|
||||
if (Validate::isLoadedObject($context->currency))
|
||||
$sql->where('(h.name = "displayPayment" AND (SELECT id_currency FROM '._DB_PREFIX_.'module_currency mcr WHERE mcr.id_module = m.id_module AND id_currency IN ('.(int)$context->currency->id.', -2) LIMIT 1) IN ('.(int)$context->currency->id.', -2))');
|
||||
$sql->where('(h.name = "displayPayment" AND (SELECT id_currency FROM '._DB_PREFIX_.'module_currency mcr WHERE mcr.id_module = m.id_module AND id_currency IN ('.(int)$context->currency->id.', -1, -2) LIMIT 1) IN ('.(int)$context->currency->id.', -1, -2))');
|
||||
}
|
||||
if (Validate::isLoadedObject($context->shop))
|
||||
$sql->where('hm.id_shop = '.(int)$context->shop->id);
|
||||
|
||||
@@ -737,7 +737,7 @@ class LanguageCore extends ObjectModel
|
||||
'/en-default-'.ImageType::getFormatedName('small').'.jpg',
|
||||
'/en-default-'.ImageType::getFormatedName('scene').'.jpg'
|
||||
);
|
||||
|
||||
|
||||
foreach (array(_PS_CAT_IMG_DIR_, _PS_MANU_IMG_DIR_, _PS_PROD_IMG_DIR_, _PS_SUPP_IMG_DIR_) as $to)
|
||||
foreach ($files_copy as $file)
|
||||
@copy(dirname(__FILE__).'/../img/l'.$file, $to.str_replace('/en', '/'.$iso_code, $file));
|
||||
|
||||
+28
-13
@@ -133,36 +133,46 @@ class MailCore
|
||||
{
|
||||
foreach ($to as $key => $addr)
|
||||
{
|
||||
$to_name = null;
|
||||
$addr = trim($addr);
|
||||
if (!Validate::isEmail($addr))
|
||||
{
|
||||
Tools::dieOrLog(Tools::displayError('Error: invalid e-mail address'), $die);
|
||||
return false;
|
||||
}
|
||||
|
||||
if (is_array($to_name))
|
||||
{
|
||||
if ($to_name && is_array($to_name) && Validate::isGenericName($to_name[$key]))
|
||||
$to_name = $to_name[$key];
|
||||
}
|
||||
if ($to_name == null)
|
||||
$to_name = $addr;
|
||||
/* Encode accentuated chars */
|
||||
if (function_exists('mb_encode_mimeheader'))
|
||||
$to_list->addTo($addr, mb_encode_mimeheader($to_name, 'utf-8'));
|
||||
|
||||
if ($to_name == null || $to_name == $addr)
|
||||
$to_name = '';
|
||||
else
|
||||
$to_list->addTo($addr, self::mimeEncode($to_name));
|
||||
{
|
||||
if (function_exists('mb_encode_mimeheader'))
|
||||
$to_name = mb_encode_mimeheader($to_name, 'utf-8');
|
||||
else
|
||||
$to_name = self::mimeEncode($to_name);
|
||||
}
|
||||
|
||||
$to_list->addTo($addr, $to_name);
|
||||
}
|
||||
$to_plugin = $to[0];
|
||||
} else {
|
||||
/* Simple recipient, one address */
|
||||
$to_plugin = $to;
|
||||
if ($to_name == null)
|
||||
$to_name = $to;
|
||||
if (function_exists('mb_encode_mimeheader'))
|
||||
$to_list->addTo($to, mb_encode_mimeheader($to_name, 'utf-8'));
|
||||
if ($to_name == null || $to_name == $to)
|
||||
$to_name = '';
|
||||
else
|
||||
$to_list->addTo($to, self::mimeEncode($to_name));
|
||||
{
|
||||
if (function_exists('mb_encode_mimeheader'))
|
||||
$to_name = mb_encode_mimeheader($to_name, 'utf-8');
|
||||
else
|
||||
$to_name = self::mimeEncode($to_name);
|
||||
}
|
||||
|
||||
$to_list->addTo($to, $to_name);
|
||||
}
|
||||
if(isset($bcc)) {
|
||||
$to_list->addBcc($bcc);
|
||||
@@ -235,8 +245,13 @@ class MailCore
|
||||
include_once($template_path.$iso.'/lang.php');
|
||||
else if ($module_name && file_exists($theme_path.'mails/'.$iso.'/lang.php'))
|
||||
include_once($theme_path.'mails/'.$iso.'/lang.php');
|
||||
else
|
||||
else if (file_exists(_PS_MAIL_DIR_.$iso.'/lang.php'))
|
||||
include_once(_PS_MAIL_DIR_.$iso.'/lang.php');
|
||||
else
|
||||
{
|
||||
Tools::dieOrLog(Tools::displayError('Error - The lang file is missing for :').' '.$iso, $die);
|
||||
return false;
|
||||
}
|
||||
|
||||
/* Create mail and attach differents parts */
|
||||
$message = new Swift_Message('['.Configuration::get('PS_SHOP_NAME', null, null, $id_shop).'] '.$subject);
|
||||
|
||||
@@ -399,6 +399,8 @@ abstract class PaymentModuleCore extends Module
|
||||
} // end foreach ($products)
|
||||
|
||||
$cart_rules_list = '';
|
||||
$total_reduction_value_ti = 0;
|
||||
$total_reduction_value_tex = 0;
|
||||
foreach ($cart_rules as $cart_rule)
|
||||
{
|
||||
$package = array('id_carrier' => $order->id_carrier, 'id_address' => $order->id_address_delivery, 'products' => $order->product_list);
|
||||
@@ -419,7 +421,8 @@ abstract class PaymentModuleCore extends Module
|
||||
** THEN
|
||||
** The voucher is cloned with a new value corresponding to the remainder
|
||||
*/
|
||||
if (count($order_list) == 1 && $values['tax_incl'] > $order->total_products_wt && $cart_rule['obj']->partial_use == 1 && $cart_rule['obj']->reduction_amount > 0)
|
||||
|
||||
if (count($order_list) == 1 && $values['tax_incl'] > ($order->total_products_wt - $total_reduction_value_ti) && $cart_rule['obj']->partial_use == 1 && $cart_rule['obj']->reduction_amount > 0)
|
||||
{
|
||||
// Create a new voucher from the original
|
||||
$voucher = new CartRule($cart_rule['obj']->id); // We need to instantiate the CartRule without lang parameter to allow saving it
|
||||
@@ -432,9 +435,9 @@ abstract class PaymentModuleCore extends Module
|
||||
|
||||
// Set the new voucher value
|
||||
if ($voucher->reduction_tax)
|
||||
$voucher->reduction_amount = $values['tax_incl'] - $order->total_products_wt - ($voucher->free_shipping == 1 ? $order->total_shipping_tax_incl : 0);
|
||||
$voucher->reduction_amount = $values['tax_incl'] - ($order->total_products_wt - $total_reduction_value_ti) - ($voucher->free_shipping == 1 ? $order->total_shipping_tax_incl : 0);
|
||||
else
|
||||
$voucher->reduction_amount = $values['tax_excl'] - $order->total_products - ($voucher->free_shipping == 1 ? $order->total_shipping_tax_excl : 0);
|
||||
$voucher->reduction_amount = $values['tax_excl'] - ($order->total_products - $total_reduction_value_tex) - ($voucher->free_shipping == 1 ? $order->total_shipping_tax_excl : 0);
|
||||
|
||||
$voucher->id_customer = $order->id_customer;
|
||||
$voucher->quantity = 1;
|
||||
@@ -466,7 +469,10 @@ abstract class PaymentModuleCore extends Module
|
||||
|
||||
$values['tax_incl'] -= $values['tax_incl'] - $order->total_products_wt;
|
||||
$values['tax_excl'] -= $values['tax_excl'] - $order->total_products;
|
||||
|
||||
}
|
||||
$total_reduction_value_ti += $values['tax_incl'];
|
||||
$total_reduction_value_tex += $values['tax_excl'];
|
||||
|
||||
$order->addCartRule($cart_rule['obj']->id, $cart_rule['obj']->name, $values, 0, $cart_rule['obj']->free_shipping);
|
||||
|
||||
|
||||
+21
-8
@@ -519,6 +519,17 @@ class ProductCore extends ObjectModel
|
||||
if (!Validate::isLoadedObject($customer))
|
||||
die(Tools::displayError());
|
||||
self::$_taxCalculationMethod = Group::getPriceDisplayMethod((int)$customer->id_default_group);
|
||||
$cur_cart = Context::getContext()->cart;
|
||||
$id_address = 0;
|
||||
if (Validate::isLoadedObject($cur_cart))
|
||||
$id_address = (int)$cur_cart->{Configuration::get('PS_TAX_ADDRESS_TYPE')};
|
||||
$address_infos = Address::getCountryAndState($id_address);
|
||||
|
||||
if (self::$_taxCalculationMethod != PS_TAX_EXC
|
||||
&& !empty($address_infos['vat_number'])
|
||||
&& $address_infos['id_country'] != Configuration::get('VATNUMBER_COUNTRY')
|
||||
&& Configuration::get('VATNUMBER_MANAGEMENT'))
|
||||
self::$_taxCalculationMethod = PS_TAX_EXC;
|
||||
}
|
||||
else
|
||||
self::$_taxCalculationMethod = Group::getPriceDisplayMethod(Group::getCurrent()->id);
|
||||
@@ -1368,8 +1379,8 @@ class ProductCore extends ObjectModel
|
||||
}
|
||||
|
||||
$product_supplier->product_supplier_reference = pSQL($supplier_reference);
|
||||
$product_supplier->product_supplier_price_te = (float)$price;
|
||||
$product_supplier->id_currency = (int)$id_currency;
|
||||
$product_supplier->product_supplier_price_te = !is_null($price) ? (float)$price : (float)$product_supplier->product_supplier_price_te;
|
||||
$product_supplier->id_currency = !is_null($id_currency) ? (int)$id_currency : (int)$product_supplier->id_currency;
|
||||
$product_supplier->save();
|
||||
}
|
||||
}
|
||||
@@ -2509,7 +2520,7 @@ class ProductCore extends ObjectModel
|
||||
$id_state = 0;
|
||||
$zipcode = 0;
|
||||
|
||||
if (!$id_address)
|
||||
if (!$id_address && Validate::isLoadedObject($cur_cart))
|
||||
$id_address = $cur_cart->{Configuration::get('PS_TAX_ADDRESS_TYPE')};
|
||||
|
||||
if ($id_address)
|
||||
@@ -2720,8 +2731,7 @@ class ProductCore extends ObjectModel
|
||||
if ($use_group_reduction)
|
||||
{
|
||||
$reduction_from_category = GroupReduction::getValueForProduct($id_product, $id_group);
|
||||
|
||||
if (!empty($reduction_from_category) && (float)$reduction_from_category == 0)
|
||||
if ($reduction_from_category !== false)
|
||||
$price -= $price * (float)$reduction_from_category;
|
||||
else // apply group reduction if there is no group reduction for this category
|
||||
$price *= ((100 - Group::getReductionByIdGroup($id_group)) / 100);
|
||||
@@ -3052,7 +3062,7 @@ class ProductCore extends ObjectModel
|
||||
|
||||
$check_stock = !Configuration::get('PS_DISP_UNAVAILABLE_ATTR');
|
||||
if (!$res = Db::getInstance()->executeS('
|
||||
SELECT pa.id_product, a.color, pac.id_product_attribute,'.($check_stock ? 'SUM(IF(stock.quantity > 0, 1, 0)' : '').') qty
|
||||
SELECT pa.id_product, a.color, pac.id_product_attribute, '.($check_stock ? 'SUM(IF(stock.quantity > 0, 1, 0))' : '0').' qty
|
||||
FROM '._DB_PREFIX_.'product_attribute pa
|
||||
'.Shop::addSqlAssociation('product_attribute', 'pa').
|
||||
($check_stock ? Product::sqlStock('pa', 'pa') : '').'
|
||||
@@ -3193,8 +3203,9 @@ class ProductCore extends ObjectModel
|
||||
LEFT JOIN `'._DB_PREFIX_.'manufacturer` m ON (p.`id_manufacturer`= m.`id_manufacturer`)
|
||||
'.Product::sqlStock('p', 0).'
|
||||
WHERE `id_product_1` = '.(int)$this->id.
|
||||
($active ? ' AND product_shop.`active` = 1' : '').'
|
||||
($active ? ' AND product_shop.`active` = 1 AND product_shop.`visibility` != \'none\'' : '').'
|
||||
GROUP BY product_shop.id_product';
|
||||
|
||||
if (!$result = Db::getInstance(_PS_USE_SQL_SLAVE_)->executeS($sql))
|
||||
return false;
|
||||
foreach ($result as &$row)
|
||||
@@ -3346,7 +3357,7 @@ class ProductCore extends ObjectModel
|
||||
$context = Context::getContext();
|
||||
|
||||
$sql = new DbQuery();
|
||||
$sql->select('p.`id_product`, pl.`name`, p.`active`, p.`reference`, m.`name` AS manufacturer_name, stock.`quantity`, product_shop.advanced_stock_management, p.`customizable`');
|
||||
$sql->select('p.`id_product`, pl.`name`, p.`ean13`, p.`upc`, p.`active`, p.`reference`, m.`name` AS manufacturer_name, stock.`quantity`, product_shop.advanced_stock_management, p.`customizable`');
|
||||
$sql->from('category_product', 'cp');
|
||||
$sql->leftJoin('product', 'p', 'p.`id_product` = cp.`id_product`');
|
||||
$sql->join(Shop::addSqlAssociation('product', 'p'));
|
||||
@@ -3357,6 +3368,8 @@ class ProductCore extends ObjectModel
|
||||
$sql->leftJoin('manufacturer', 'm', 'm.`id_manufacturer` = p.`id_manufacturer`');
|
||||
|
||||
$where = 'pl.`name` LIKE \'%'.pSQL($query).'%\'
|
||||
OR p.`ean13` LIKE \'%'.pSQL($query).'%\'
|
||||
OR p.`upc` LIKE \'%'.pSQL($query).'%\'
|
||||
OR p.`reference` LIKE \'%'.pSQL($query).'%\'
|
||||
OR p.`supplier_reference` LIKE \'%'.pSQL($query).'%\'
|
||||
OR p.`id_product` IN (SELECT id_product FROM '._DB_PREFIX_.'product_supplier sp WHERE `product_supplier_reference` LIKE \'%'.pSQL($query).'%\')';
|
||||
|
||||
@@ -103,7 +103,7 @@ class ProductSaleCore
|
||||
LEFT JOIN `'._DB_PREFIX_.'tax` t ON (t.`id_tax` = tr.`id_tax`)
|
||||
'.Product::sqlStock('p').'
|
||||
WHERE product_shop.`active` = 1
|
||||
AND p.`visibility` != \'none\'
|
||||
AND product_shop.`visibility` != \'none\'
|
||||
AND p.`id_product` IN (
|
||||
SELECT cp.`id_product`
|
||||
FROM `'._DB_PREFIX_.'category_group` cg
|
||||
@@ -158,7 +158,7 @@ class ProductSaleCore
|
||||
ON cl.`id_category` = product_shop.`id_category_default`
|
||||
AND cl.`id_lang` = '.(int)$id_lang.Shop::addSqlRestrictionOnLang('cl').'
|
||||
WHERE product_shop.`active` = 1
|
||||
AND p.`visibility` != \'none\'
|
||||
AND product_shop.`visibility` != \'none\'
|
||||
AND p.`id_product` IN (
|
||||
SELECT cp.`id_product`
|
||||
FROM `'._DB_PREFIX_.'category_group` cg
|
||||
|
||||
+17
-15
@@ -139,21 +139,22 @@ class ReferrerCore extends ObjectModel
|
||||
}
|
||||
|
||||
$sql = 'SELECT COUNT(DISTINCT cs.id_connections_source) AS visits,
|
||||
COUNT(DISTINCT cs.id_connections) as visitors,
|
||||
COUNT(DISTINCT c.id_guest) as uniqs,
|
||||
COUNT(DISTINCT cp.time_start) as pages
|
||||
FROM '._DB_PREFIX_.'referrer_cache rc
|
||||
LEFT JOIN '._DB_PREFIX_.'referrer r ON rc.id_referrer = r.id_referrer
|
||||
LEFT JOIN '._DB_PREFIX_.'referrer_shop rs ON r.id_referrer = rs.id_referrer
|
||||
LEFT JOIN '._DB_PREFIX_.'connections_source cs ON rc.id_connections_source = cs.id_connections_source
|
||||
LEFT JOIN '._DB_PREFIX_.'connections c ON cs.id_connections = c.id_connections
|
||||
LEFT JOIN '._DB_PREFIX_.'connections_page cp ON cp.id_connections = c.id_connections
|
||||
'.$join.'
|
||||
WHERE cs.date_add BETWEEN '.ModuleGraph::getDateBetween($employee).'
|
||||
'.Shop::addSqlRestriction(false, 'rs').'
|
||||
'.Shop::addSqlRestriction(false, 'c').'
|
||||
AND rc.id_referrer = '.(int)$this->id
|
||||
.$where;
|
||||
COUNT(DISTINCT cs.id_connections) as visitors,
|
||||
COUNT(DISTINCT c.id_guest) as uniqs,
|
||||
COUNT(DISTINCT cp.time_start) as pages
|
||||
FROM '._DB_PREFIX_.'referrer_cache rc
|
||||
LEFT JOIN '._DB_PREFIX_.'referrer r ON rc.id_referrer = r.id_referrer
|
||||
LEFT JOIN '._DB_PREFIX_.'referrer_shop rs ON r.id_referrer = rs.id_referrer
|
||||
LEFT JOIN '._DB_PREFIX_.'connections_source cs ON rc.id_connections_source = cs.id_connections_source
|
||||
LEFT JOIN '._DB_PREFIX_.'connections c ON cs.id_connections = c.id_connections
|
||||
LEFT JOIN '._DB_PREFIX_.'connections_page cp ON cp.id_connections = c.id_connections
|
||||
'.$join.'
|
||||
WHERE 1'.
|
||||
((isset($employee->stats_date_from) && isset($employee->stats_date_from))? ' AND cs.date_add BETWEEN \''.pSQL($employee->stats_date_from).' 00:00:00\' AND \''.pSQL($employee->stats_date_to).' 23:59:59\'' : '').
|
||||
Shop::addSqlRestriction(false, 'rs').
|
||||
Shop::addSqlRestriction(false, 'c').
|
||||
' AND rc.id_referrer = '.(int)$this->id.
|
||||
$where;
|
||||
return Db::getInstance(_PS_USE_SQL_SLAVE_)->getRow($sql);
|
||||
}
|
||||
|
||||
@@ -314,6 +315,7 @@ class ReferrerCore extends ObjectModel
|
||||
FROM '._DB_PREFIX_.'referrer r
|
||||
LEFT JOIN '._DB_PREFIX_.'connections_source cs ON ('.self::$_join.')
|
||||
WHERE id_referrer = '.(int)$row['id_referrer'].'
|
||||
AND id_connections_source IS NOT NULL
|
||||
)');
|
||||
}
|
||||
}
|
||||
|
||||
@@ -169,7 +169,8 @@ class SpecificPriceCore extends ObjectModel
|
||||
|
||||
$priority = SpecificPrice::getPriority($id_product);
|
||||
foreach (array_reverse($priority) as $k => $field)
|
||||
$select .= ' IF (`'.bqSQL($field).'` = '.(int)$$field.', '.pow(2, $k + 1).', 0) + ';
|
||||
if (!empty($field))
|
||||
$select .= ' IF (`'.bqSQL($field).'` = '.(int)$$field.', '.pow(2, $k + 1).', 0) + ';
|
||||
|
||||
return rtrim($select, ' +').') AS `score`';
|
||||
}
|
||||
@@ -228,7 +229,7 @@ class SpecificPriceCore extends ObjectModel
|
||||
(`to` = \'0000-00-00 00:00:00\' OR \''.$now.'\' <= `to`)
|
||||
)
|
||||
AND id_cart IN (0, '.(int)$id_cart.')'.
|
||||
(($real_quantity != 0 && !Configuration::get('PS_QTY_DISCOUNT_ON_COMBINATION')) ? ' AND IF(`from_quantity` > 1, `from_quantity`, 0) <= IF(id_product_attribute=0,'.(int)$quantity.' ,'.(int)$real_quantity.')' : 'AND `from_quantity` <= '.(int)$real_quantity).'
|
||||
(($real_quantity != 0 && !Configuration::get('PS_QTY_DISCOUNT_ON_COMBINATION')) ? ' AND IF(`from_quantity` > 1, `from_quantity`, 0) <= IF(id_product_attribute=0,'.(int)$quantity.' ,'.(int)$real_quantity.')' : 'AND `from_quantity` <= '.max(1, (int)$real_quantity)).'
|
||||
ORDER BY `id_product_attribute` DESC, `from_quantity` DESC, `id_specific_price_rule` ASC, `score` DESC');
|
||||
}
|
||||
return self::$_specificPriceCache[$key];
|
||||
@@ -301,7 +302,7 @@ class SpecificPriceCore extends ObjectModel
|
||||
if (!isset($last_quantity[(int)$specific_price['id_product_attribute']]))
|
||||
$last_quantity[(int)$specific_price['id_product_attribute']] = $specific_price['from_quantity'];
|
||||
elseif ($last_quantity[(int)$specific_price['id_product_attribute']] == $specific_price['from_quantity'])
|
||||
break;
|
||||
continue;
|
||||
|
||||
$last_quantity[(int)$specific_price['id_product_attribute']] = $specific_price['from_quantity'];
|
||||
if ($specific_price['from_quantity'] > 1)
|
||||
|
||||
@@ -183,7 +183,7 @@ class SpecificPriceRuleCore extends ObjectModel
|
||||
|
||||
if ($conditions_group)
|
||||
{
|
||||
$where .= ' AND (';
|
||||
$where .= ' AND ((';
|
||||
foreach ($conditions_group as $id_condition_group => $condition_group)
|
||||
{
|
||||
$fields = array(
|
||||
@@ -235,7 +235,7 @@ class SpecificPriceRuleCore extends ObjectModel
|
||||
|
||||
$where = rtrim($where, ' AND ').') OR (';
|
||||
}
|
||||
$where = rtrim($where, 'OR (');
|
||||
$where = rtrim($where, 'OR (').')';
|
||||
}
|
||||
if ($products && count($products))
|
||||
$where .= ' AND p.id_product IN ('.implode(', ', array_map('intval', $products)).')';
|
||||
@@ -267,7 +267,7 @@ class SpecificPriceRuleCore extends ObjectModel
|
||||
public static function applyRuleToProduct($id_rule, $id_product, $id_product_attribute = null)
|
||||
{
|
||||
$rule = new SpecificPriceRule((int)$id_rule);
|
||||
if (!Validate::isLoadedObject($rule))
|
||||
if (!Validate::isLoadedObject($rule) || !$id_product)
|
||||
return false;
|
||||
|
||||
$specific_price = new SpecificPrice();
|
||||
|
||||
+17
-15
@@ -40,7 +40,7 @@ class TagCore extends ObjectModel
|
||||
'primary' => 'id_tag',
|
||||
'fields' => array(
|
||||
'id_lang' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedId', 'required' => true),
|
||||
'name' => array('type' => self::TYPE_STRING, 'validate' => 'isGenericName', 'required' => true),
|
||||
'name' => array('type' => self::TYPE_STRING, 'validate' => 'isGenericName', 'required' => true, 'size' => 32),
|
||||
),
|
||||
);
|
||||
|
||||
@@ -100,22 +100,24 @@ class TagCore extends ObjectModel
|
||||
$tag_list = array_filter(array_unique(array_map('trim', preg_split('#\\'.$separator.'#', $tag_list, null, PREG_SPLIT_NO_EMPTY))));
|
||||
|
||||
$list = array();
|
||||
foreach ($tag_list as $tag)
|
||||
{
|
||||
if (!Validate::isGenericName($tag))
|
||||
return false;
|
||||
$tag_obj = new Tag(null, trim($tag), (int)$id_lang);
|
||||
|
||||
/* Tag does not exist in database */
|
||||
if (!Validate::isLoadedObject($tag_obj))
|
||||
if (is_array($tag_list))
|
||||
foreach ($tag_list as $tag)
|
||||
{
|
||||
$tag_obj->name = trim($tag);
|
||||
$tag_obj->id_lang = (int)$id_lang;
|
||||
$tag_obj->add();
|
||||
if (!Validate::isGenericName($tag))
|
||||
return false;
|
||||
$tag = trim(substr($tag, 0, self::$definition['fields']['name']['size']));
|
||||
$tag_obj = new Tag(null, $tag, (int)$id_lang);
|
||||
|
||||
/* Tag does not exist in database */
|
||||
if (!Validate::isLoadedObject($tag_obj))
|
||||
{
|
||||
$tag_obj->name = $tag;
|
||||
$tag_obj->id_lang = (int)$id_lang;
|
||||
$tag_obj->add();
|
||||
}
|
||||
if (!in_array($tag_obj->id, $list))
|
||||
$list[] = $tag_obj->id;
|
||||
}
|
||||
if (!in_array($tag_obj->id, $list))
|
||||
$list[] = $tag_obj->id;
|
||||
}
|
||||
$data = '';
|
||||
foreach ($list as $tag)
|
||||
$data .= '('.(int)$tag.','.(int)$id_product.'),';
|
||||
|
||||
+31
-2
@@ -494,6 +494,20 @@ class ToolsCore
|
||||
if (($is_negative = ($price < 0)))
|
||||
$price *= -1;
|
||||
$price = Tools::ps_round($price, $c_decimals);
|
||||
|
||||
/*
|
||||
* If the language is RTL and the selected currency format contains spaces as thousands separator
|
||||
* then the number will be printed in reverse since the space is interpreted as separating words.
|
||||
* To avoid this we replace the currency format containing a space with the one containing a comma (,) as thousand
|
||||
* separator when the language is RTL.
|
||||
*
|
||||
* TODO: This is not ideal, a currency format should probably be tied to a language, not to a currency.
|
||||
*/
|
||||
if(($c_format == 2) && ($context->language->is_rtl == 1))
|
||||
{
|
||||
$c_format = 4;
|
||||
}
|
||||
|
||||
switch ($c_format)
|
||||
{
|
||||
/* X 0,000.00 */
|
||||
@@ -512,9 +526,9 @@ class ToolsCore
|
||||
case 4:
|
||||
$ret = number_format($price, $c_decimals, '.', ',').$blank.$c_char;
|
||||
break;
|
||||
/* 0 000.00 X Added for the switzerland currency */
|
||||
/* X 0'000.00 Added for the switzerland currency */
|
||||
case 5:
|
||||
$ret = number_format($price, $c_decimals, '.', ' ').$blank.$c_char;
|
||||
$ret = $c_char.$blank.number_format($price, $c_decimals, '.', "'");
|
||||
break;
|
||||
}
|
||||
if ($is_negative)
|
||||
@@ -705,6 +719,21 @@ class ToolsCore
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete file
|
||||
*
|
||||
* @param string File path
|
||||
* @param array Excluded files
|
||||
*/
|
||||
public static function deleteFile($file, $exclude_files = array())
|
||||
{
|
||||
if (isset($exclude_files) && !is_array($exclude_files))
|
||||
$exclude_files = array($exclude_files);
|
||||
|
||||
if (file_exists($file) && is_file($file) && array_search(basename($file), $exclude_files) === FALSE)
|
||||
unlink($file);
|
||||
}
|
||||
|
||||
/**
|
||||
* Clear smarty cache folders
|
||||
|
||||
@@ -680,8 +680,8 @@ class AdminControllerCore extends Controller
|
||||
'export_precontent' => "\xEF\xBB\xBF",
|
||||
'export_headers' => $headers,
|
||||
'export_content' => $content
|
||||
));
|
||||
|
||||
)
|
||||
);
|
||||
$this->layout = 'layout-export.tpl';
|
||||
}
|
||||
|
||||
@@ -720,7 +720,7 @@ class AdminControllerCore extends Controller
|
||||
$this->redirect_after = self::$currentIndex.'&conf=1&token='.$this->token;
|
||||
$this->errors[] = Tools::displayError('An error occurred during deletion.');
|
||||
if ($res)
|
||||
Logger::addLog(sprintf($this->l('%s deletion'), $this->className), 1, null, $this->className, (int)$this->object->id, true, (int)$this->context->employee->id);
|
||||
Logger::addLog(sprintf($this->l('%s deletion', 'AdminTab', false, false), $this->className), 1, null, $this->className, (int)$this->object->id, true, (int)$this->context->employee->id);
|
||||
}
|
||||
}
|
||||
else
|
||||
@@ -771,7 +771,7 @@ class AdminControllerCore extends Controller
|
||||
/* voluntary do affectation here */
|
||||
elseif (($_POST[$this->identifier] = $this->object->id) && $this->postImage($this->object->id) && !count($this->errors) && $this->_redirect)
|
||||
{
|
||||
Logger::addLog(sprintf($this->l('%s addition'), $this->className), 1, null, $this->className, (int)$this->object->id, true, (int)$this->context->employee->id);
|
||||
Logger::addLog(sprintf($this->l('%s addition', 'AdminTab', false, false), $this->className), 1, null, $this->className, (int)$this->object->id, true, (int)$this->context->employee->id);
|
||||
$parent_id = (int)Tools::getValue('id_parent', 1);
|
||||
$this->afterAdd($this->object);
|
||||
$this->updateAssoShop($this->object->id);
|
||||
@@ -868,10 +868,10 @@ class AdminControllerCore extends Controller
|
||||
$this->redirect_after = self::$currentIndex.'&'.$this->identifier.'='.$parent_id.'&conf=4&token='.$this->token;
|
||||
|
||||
// Default behavior (save and back)
|
||||
if (empty($this->redirect_after))
|
||||
if (empty($this->redirect_after) && $this->redirect_after !== false)
|
||||
$this->redirect_after = self::$currentIndex.($parent_id ? '&'.$this->identifier.'='.$object->id : '').'&conf=4&token='.$this->token;
|
||||
}
|
||||
Logger::addLog(sprintf($this->l('%s edition'), $this->className), 1, null, $this->className, (int)$object->id, true, (int)$this->context->employee->id);
|
||||
Logger::addLog(sprintf($this->l('%s edition', 'AdminTab', false, false), $this->className), 1, null, $this->className, (int)$object->id, true, (int)$this->context->employee->id);
|
||||
}
|
||||
else
|
||||
$this->errors[] = Tools::displayError('An error occurred while updating an object.').
|
||||
@@ -2296,6 +2296,7 @@ class AdminControllerCore extends Controller
|
||||
*/
|
||||
public function getList($id_lang, $order_by = null, $order_way = null, $start = 0, $limit = null, $id_lang_shop = false)
|
||||
{
|
||||
|
||||
if (!isset($this->list_id))
|
||||
$this->list_id = $this->table;
|
||||
|
||||
@@ -2350,12 +2351,20 @@ class AdminControllerCore extends Controller
|
||||
$order_by = $this->fields_list[$order_by]['order_key'];
|
||||
|
||||
/* Determine offset from current page */
|
||||
|
||||
|
||||
if ((isset($_POST['submitFilter'.$this->list_id]) ||
|
||||
isset($_POST['submitFilter'.$this->list_id.'_x']) ||
|
||||
isset($_POST['submitFilter'.$this->list_id.'_y'])) &&
|
||||
!empty($_POST['submitFilter'.$this->list_id]) &&
|
||||
is_numeric($_POST['submitFilter'.$this->list_id]))
|
||||
$start = ((int)$_POST['submitFilter'.$this->list_id] - 1) * $limit;
|
||||
elseif (empty($start) && isset($this->context->cookie->{$this->list_id.'_start'}) && Tools::isSubmit('export'.$this->table))
|
||||
$start = $this->context->cookie->{$this->list_id.'_start'};
|
||||
else
|
||||
$start = 0;
|
||||
|
||||
$this->context->cookie->{$this->list_id.'_start'} = $start;
|
||||
|
||||
/* Cache */
|
||||
$this->_lang = (int)$id_lang;
|
||||
@@ -2425,8 +2434,6 @@ class AdminControllerCore extends Controller
|
||||
$having_clause .= $this->_having.' ';
|
||||
}
|
||||
|
||||
|
||||
|
||||
$this->_listsql = '
|
||||
SELECT SQL_CALC_FOUND_ROWS
|
||||
'.($this->_tmpTableFilter ? ' * FROM (SELECT ' : '');
|
||||
@@ -2611,7 +2618,12 @@ class AdminControllerCore extends Controller
|
||||
$class_name = $this->className;
|
||||
|
||||
$object = new $class_name();
|
||||
$definition = ObjectModel::getDefinition($class_name);
|
||||
|
||||
if (method_exists($this, 'getValidationRules'))
|
||||
$definition = $this->getValidationRules();
|
||||
else
|
||||
$definition = ObjectModel::getDefinition($class_name);
|
||||
|
||||
$default_language = new Language((int)Configuration::get('PS_LANG_DEFAULT'));
|
||||
|
||||
foreach ($definition['fields'] as $field => $def)
|
||||
@@ -2643,8 +2655,27 @@ class AdminControllerCore extends Controller
|
||||
$this->errors[$field] = $error;
|
||||
}
|
||||
|
||||
|
||||
/* Overload this method for custom checking */
|
||||
$this->_childValidation();
|
||||
|
||||
/* Checking for multilingual fields validity */
|
||||
if (isset($rules['validateLang']) && is_array($rules['validateLang']))
|
||||
foreach ($rules['validateLang'] as $field_lang => $function)
|
||||
foreach ($languages as $language)
|
||||
if (($value = Tools::getValue($field_lang.'_'.$language['id_lang'])) !== false && !empty($value))
|
||||
{
|
||||
if (Tools::strtolower($function) == 'iscleanhtml' && Configuration::get('PS_ALLOW_HTML_IFRAME'))
|
||||
$res = Validate::$function($value, true);
|
||||
else
|
||||
$res = Validate::$function($value);
|
||||
if (!$res)
|
||||
$this->errors[$field_lang.'_'.$language['id_lang']] = sprintf(
|
||||
Tools::displayError('The %1$s field (%2$s) is invalid.'),
|
||||
call_user_func(array($class_name, 'displayFieldName'), $field_lang, $class_name),
|
||||
$language['name']
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -2921,7 +2952,7 @@ class AdminControllerCore extends Controller
|
||||
}
|
||||
|
||||
if ($delete_ok)
|
||||
Logger::addLog(sprintf($this->l('%s deletion'), $this->className), 1, null, $this->className, (int)$to_delete->id, true, (int)$this->context->employee->id);
|
||||
Logger::addLog(sprintf($this->l('%s deletion', 'AdminTab', false, false), $this->className), 1, null, $this->className, (int)$to_delete->id, true, (int)$this->context->employee->id);
|
||||
else
|
||||
$this->errors[] = sprintf(Tools::displayError('Can\'t delete #%d'), $id);
|
||||
}
|
||||
|
||||
@@ -334,12 +334,14 @@ abstract class ControllerCore
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
$plugin_path = Media::getJqueryPluginPath($name, $folder);
|
||||
|
||||
if(!empty($plugin_path['css']))
|
||||
$this->addCSS($plugin_path['css']);
|
||||
if(!empty($plugin_path['js']))
|
||||
$this->addJS($plugin_path['js']);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -251,6 +251,8 @@ class FrontControllerCore extends Controller
|
||||
$this->context->cart = $cart;
|
||||
CartRule::autoAddToCart($this->context);
|
||||
}
|
||||
else
|
||||
$this->context->cart = $cart;
|
||||
|
||||
/* get page name to display it in body id */
|
||||
|
||||
@@ -325,7 +327,7 @@ class FrontControllerCore extends Controller
|
||||
'currencies' => Currency::getCurrencies(),
|
||||
'languages' => $languages,
|
||||
'meta_language' => implode('-', $meta_language),
|
||||
'priceDisplay' => Product::getTaxCalculationMethod(),
|
||||
'priceDisplay' => Product::getTaxCalculationMethod((int)$this->context->cookie->id_customer),
|
||||
'add_prod_display' => (int)Configuration::get('PS_ATTRIBUTE_CATEGORY_DISPLAY'),
|
||||
'shop_name' => Configuration::get('PS_SHOP_NAME'),
|
||||
'roundMode' => (int)Configuration::get('PS_PRICE_ROUND_MODE'),
|
||||
@@ -579,6 +581,9 @@ class FrontControllerCore extends Controller
|
||||
header('HTTP/1.1 503 temporarily overloaded');
|
||||
|
||||
$this->context->smarty->assign($this->initLogoAndFavicon());
|
||||
$this->context->smarty->assign(array(
|
||||
'HOOK_MAINTENANCE' => Hook::exec('displayMaintenance', array()),
|
||||
));
|
||||
|
||||
$template_dir = ($this->context->getMobileDevice() == true ? _PS_THEME_MOBILE_DIR_ : _PS_THEME_DIR_);
|
||||
$this->smartyOutputContent($template_dir.'maintenance.tpl');
|
||||
@@ -1152,7 +1157,7 @@ class FrontControllerCore extends Controller
|
||||
|
||||
protected function addColorsToProductList(&$products)
|
||||
{
|
||||
if (!count($products))
|
||||
if (!is_array($products) || !count($products))
|
||||
return;
|
||||
|
||||
$products_need_cache = array();
|
||||
|
||||
@@ -60,7 +60,7 @@ class ModuleFrontControllerCore extends FrontController
|
||||
elseif (Tools::file_exists_cache($this->getTemplatePath().$template))
|
||||
$this->template = $this->getTemplatePath().$template;
|
||||
else
|
||||
throw new PrestaShopException("Template '$template'' not found");
|
||||
throw new PrestaShopException("Template '$template' not found");
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
class HelperCore
|
||||
{
|
||||
public $currentIndex;
|
||||
public $table;
|
||||
public $table = 'configuration';
|
||||
public $identifier;
|
||||
public $token;
|
||||
public $toolbar_btn;
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
|
||||
class HelperCalendarCore extends Helper
|
||||
{
|
||||
const DEFAULT_DATE_FORMAT = 'Y-m-d';
|
||||
const DEFAULT_DATE_FORMAT = 'dd-mm-yyyy';
|
||||
|
||||
private $_actions;
|
||||
private $_compare_date_from;
|
||||
|
||||
@@ -37,8 +37,6 @@ class HelperFormCore extends Helper
|
||||
|
||||
/** @var array values of form fields */
|
||||
public $fields_value = array();
|
||||
|
||||
public $table = 'configuration';
|
||||
public $name_controller = '';
|
||||
|
||||
/** @var string if not null, a title will be added on that list */
|
||||
|
||||
@@ -453,10 +453,10 @@ class HelperListCore extends Helper
|
||||
self::$cache_lang['Delete'] = $this->l('Delete', 'Helper');
|
||||
|
||||
if (!array_key_exists('DeleteItem', self::$cache_lang))
|
||||
self::$cache_lang['DeleteItem'] = $this->l('Delete selected item?', 'Helper');
|
||||
self::$cache_lang['DeleteItem'] = $this->l('Delete selected item?', 'Helper', false, false);
|
||||
|
||||
if (!array_key_exists('Name', self::$cache_lang))
|
||||
self::$cache_lang['Name'] = $this->l('Name:', 'Helper');
|
||||
self::$cache_lang['Name'] = $this->l('Name:', 'Helper', false, false);
|
||||
|
||||
if (!is_null($name))
|
||||
$name = '\n\n'.self::$cache_lang['Name'].' '.$name;
|
||||
|
||||
@@ -1736,7 +1736,7 @@ abstract class ModuleCore
|
||||
{
|
||||
Tools::enableCache();
|
||||
if ($cache_id === null)
|
||||
$cache_id = Module::getCacheId($this->name);
|
||||
$cache_id = $this->name;
|
||||
Tools::clearCache(Context::getContext()->smarty, $this->getTemplatePath($template), $cache_id, $compile_id);
|
||||
Tools::restoreCacheSettings();
|
||||
}
|
||||
@@ -2088,7 +2088,7 @@ abstract class ModuleCore
|
||||
|
||||
// Remplacer la ligne de declaration par "remove"
|
||||
foreach ($override_file as $line_number => &$line_content)
|
||||
if (preg_match('/(public|private|protected)\s+(static\s+)?\$'.$property->getName().'/i', $line_content))
|
||||
if (preg_match('/(public|private|protected|const)\s+(static\s+)?(\$)?'.$property->getName().'/i', $line_content))
|
||||
{
|
||||
$line_content = '#--remove--#';
|
||||
break;
|
||||
|
||||
+78
-24
@@ -1086,6 +1086,41 @@ class OrderCore extends ObjectModel
|
||||
');
|
||||
}
|
||||
|
||||
public static function setLastInvoiceNumber($order_invoice_id, $id_shop)
|
||||
{
|
||||
if (!$order_invoice_id)
|
||||
return false;
|
||||
|
||||
$number = Configuration::get('PS_INVOICE_START_NUMBER', null, null, $id_shop);
|
||||
// If invoice start number has been set, you clean the value of this configuration
|
||||
if ($number)
|
||||
Configuration::updateValue('PS_INVOICE_START_NUMBER', false, false, null, $id_shop);
|
||||
|
||||
$sql = 'UPDATE `'._DB_PREFIX_.'order_invoice` SET number =';
|
||||
|
||||
if ($number)
|
||||
$sql .= (int)$number;
|
||||
else
|
||||
$sql .= '(SELECT new_number FROM (SELECT (MAX(`number`) + 1) AS new_number
|
||||
FROM `'._DB_PREFIX_.'order_invoice`) AS result)';
|
||||
|
||||
$sql .=' WHERE `id_order_invoice` = '.(int)$order_invoice_id;
|
||||
|
||||
return Db::getInstance()->execute($sql);
|
||||
}
|
||||
|
||||
public function getInvoiceNumber($order_invoice_id)
|
||||
{
|
||||
if (!$order_invoice_id)
|
||||
return false;
|
||||
|
||||
return Db::getInstance()->getValue('
|
||||
SELECT `number`
|
||||
FROM `'._DB_PREFIX_.'order_invoice`
|
||||
WHERE `id_order_invoice` = '.(int)$order_invoice_id
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* This method allows to generate first invoice of the current order
|
||||
*/
|
||||
@@ -1095,13 +1130,7 @@ class OrderCore extends ObjectModel
|
||||
{
|
||||
$order_invoice = new OrderInvoice();
|
||||
$order_invoice->id_order = $this->id;
|
||||
$order_invoice->number = Configuration::get('PS_INVOICE_START_NUMBER', null, null, $this->id_shop);
|
||||
// If invoice start number has been set, you clean the value of this configuration
|
||||
if ($order_invoice->number)
|
||||
Configuration::updateValue('PS_INVOICE_START_NUMBER', false, false, null, $this->id_shop);
|
||||
else
|
||||
$order_invoice->number = Order::getLastInvoiceNumber() + 1;
|
||||
|
||||
$order_invoice->number = 0;
|
||||
$invoice_address = new Address((int)$this->id_address_invoice);
|
||||
$carrier = new Carrier((int)$this->id_carrier);
|
||||
$tax_calculator = $carrier->getTaxCalculator($invoice_address);
|
||||
@@ -1120,6 +1149,7 @@ class OrderCore extends ObjectModel
|
||||
|
||||
// Save Order invoice
|
||||
$order_invoice->add();
|
||||
$this->setLastInvoiceNumber($order_invoice->id, $this->id_shop);
|
||||
|
||||
$order_invoice->saveCarrierTaxCalculator($tax_calculator->getTaxesAmount($order_invoice->total_shipping_tax_excl));
|
||||
|
||||
@@ -1175,11 +1205,46 @@ class OrderCore extends ObjectModel
|
||||
|
||||
// Keep it for backward compatibility, to remove on 1.6 version
|
||||
$this->invoice_date = $order_invoice->date_add;
|
||||
$this->invoice_number = $order_invoice->number;
|
||||
$this->invoice_number = $this->getInvoiceNumber($order_invoice->id);
|
||||
$this->update();
|
||||
}
|
||||
}
|
||||
|
||||
public function setDeliveryNumber($order_invoice_id, $id_shop)
|
||||
{
|
||||
if (!$order_invoice_id)
|
||||
return false;
|
||||
|
||||
$number = Configuration::get('PS_DELIVERY_NUMBER', null, null, $id_shop);
|
||||
// If invoice start number has been set, you clean the value of this configuration
|
||||
if ($number)
|
||||
Configuration::updateValue('PS_DELIVERY_NUMBER', false, false, null, $id_shop);
|
||||
|
||||
$sql = 'UPDATE `'._DB_PREFIX_.'order_invoice` SET delivery_number =';
|
||||
|
||||
if ($number)
|
||||
$sql .= (int)$number;
|
||||
else
|
||||
$sql .= '(SELECT new_number FROM (SELECT (MAX(`delivery_number`) + 1) AS new_number
|
||||
FROM `'._DB_PREFIX_.'order_invoice`) AS result)';
|
||||
|
||||
$sql .=' WHERE `id_order_invoice` = '.(int)$order_invoice_id;
|
||||
|
||||
return Db::getInstance()->execute($sql);
|
||||
}
|
||||
|
||||
public function getDeliveryNumber($order_invoice_id)
|
||||
{
|
||||
if (!$order_invoice_id)
|
||||
return false;
|
||||
|
||||
return Db::getInstance()->getValue('
|
||||
SELECT `delivery_number`
|
||||
FROM `'._DB_PREFIX_.'order_invoice`
|
||||
WHERE `id_order_invoice` = '.(int)$order_invoice_id
|
||||
);
|
||||
}
|
||||
|
||||
public function setDelivery()
|
||||
{
|
||||
// Get all invoice
|
||||
@@ -1188,24 +1253,14 @@ class OrderCore extends ObjectModel
|
||||
{
|
||||
if ($order_invoice->delivery_number)
|
||||
continue;
|
||||
|
||||
$number = (int)Configuration::get('PS_DELIVERY_NUMBER', null, null, $this->id_shop);
|
||||
if (!$number)
|
||||
{
|
||||
//if delivery number is not set or wrong, we set a default one.
|
||||
Configuration::updateValue('PS_DELIVERY_NUMBER', 1, false, null, $this->id_shop);
|
||||
$number = 1;
|
||||
}
|
||||
|
||||
// Set delivery number on invoice
|
||||
$order_invoice->delivery_number = $number;
|
||||
$order_invoice->delivery_number = 0;
|
||||
$order_invoice->delivery_date = date('Y-m-d H:i:s');
|
||||
// Update Order Invoice
|
||||
$order_invoice->update();
|
||||
|
||||
// Keep for backward compatibility
|
||||
$this->delivery_number = $number;
|
||||
Configuration::updateValue('PS_DELIVERY_NUMBER', $number + 1, false, null, $this->id_shop);
|
||||
$this->setDeliveryNumber($order_invoice->id, $this->id_shop);
|
||||
$this->delivery_number = $this->getDeliveryNumber($order_invoice->id);
|
||||
}
|
||||
|
||||
// Keep it for backward compatibility, to remove on 1.6 version
|
||||
@@ -1890,10 +1945,9 @@ class OrderCore extends ObjectModel
|
||||
}
|
||||
|
||||
/**
|
||||
* Return a unique reference like : GWJTHMZUN#2
|
||||
* Return id of carrier
|
||||
*
|
||||
* With multishipping, order reference are the same for all orders made with the same cart
|
||||
* in this case this method suffix the order reference by a # and the order number
|
||||
* Get id of the carrier used in order
|
||||
*
|
||||
* @since 1.5.5.0
|
||||
*/
|
||||
|
||||
@@ -243,7 +243,7 @@ class OrderInvoiceCore extends ObjectModel
|
||||
WHERE od.`id_order` = '.(int)$this->id_order.'
|
||||
AND od.`id_order_invoice` = '.(int)$this->id.'
|
||||
AND od.`tax_computation_method` = '.(int)TaxCalculator::ONE_AFTER_ANOTHER_METHOD
|
||||
);
|
||||
) || Configuration::get('PS_INVOICE_TAXES_BREAKDOWN');
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -301,7 +301,7 @@ class OrderInvoiceCore extends ObjectModel
|
||||
{
|
||||
// sum by order details in order to retrieve real taxes rate
|
||||
$taxes_infos = Db::getInstance()->executeS('
|
||||
SELECT odt.`id_order_detail`, t.`rate` AS `name`, SUM(od.`total_price_tax_excl`) AS total_price_tax_excl, SUM(t.`rate`) AS rate, SUM(`total_amount`) AS `total_amount`, od.`ecotax`, od.`ecotax_tax_rate`, od.`product_quantity`
|
||||
SELECT odt.`id_order_detail`, t.`rate` AS `name`, od.`total_price_tax_excl` AS total_price_tax_excl, SUM(t.`rate`) AS rate, SUM(`total_amount`) AS `total_amount`, od.`ecotax`, od.`ecotax_tax_rate`, od.`product_quantity`
|
||||
FROM `'._DB_PREFIX_.'order_detail_tax` odt
|
||||
LEFT JOIN `'._DB_PREFIX_.'tax` t ON (t.`id_tax` = odt.`id_tax`)
|
||||
LEFT JOIN `'._DB_PREFIX_.'order_detail` od ON (od.`id_order_detail` = odt.`id_order_detail`)
|
||||
@@ -466,7 +466,7 @@ class OrderInvoiceCore extends ObjectModel
|
||||
FROM `'._DB_PREFIX_.'order_invoice` oi
|
||||
LEFT JOIN `'._DB_PREFIX_.'orders` o ON (o.`id_order` = oi.`id_order`)
|
||||
WHERE DATE_ADD(oi.delivery_date, INTERVAL -1 DAY) <= \''.pSQL($date_to).'\'
|
||||
AND oi.date_add >= \''.pSQL($date_from).'\'
|
||||
AND oi.delivery_date >= \''.pSQL($date_from).'\'
|
||||
'.Shop::addSqlRestriction(Shop::SHARE_ORDER, 'o').'
|
||||
ORDER BY oi.delivery_date ASC
|
||||
');
|
||||
|
||||
@@ -49,7 +49,7 @@ class OrderPaymentCore extends ObjectModel
|
||||
'id_currency' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedId', 'required' => true),
|
||||
'amount' => array('type' => self::TYPE_FLOAT, 'validate' => 'isNegativePrice', 'required' => true),
|
||||
'payment_method' => array('type' => self::TYPE_STRING, 'validate' => 'isGenericName'),
|
||||
'conversion_rate' => array('type' => self::TYPE_INT, 'validate' => 'isFloat'),
|
||||
'conversion_rate' => array('type' => self::TYPE_FLOAT, 'validate' => 'isFloat'),
|
||||
'transaction_id' => array('type' => self::TYPE_STRING, 'validate' => 'isAnything', 'size' => 254),
|
||||
'card_number' => array('type' => self::TYPE_STRING, 'validate' => 'isAnything', 'size' => 254),
|
||||
'card_brand' => array('type' => self::TYPE_STRING, 'validate' => 'isAnything', 'size' => 254),
|
||||
|
||||
@@ -90,7 +90,7 @@ class HTMLTemplateDeliverySlipCore extends HTMLTemplate
|
||||
*/
|
||||
public function getFilename()
|
||||
{
|
||||
return Configuration::get('PS_DELIVERY_PREFIX', Context::getContext()->language->id, null, $this->order->id_shop).sprintf('%06d', $this->order->invoice_number).'.pdf';
|
||||
return Configuration::get('PS_DELIVERY_PREFIX', Context::getContext()->language->id, null, $this->order->id_shop).sprintf('%06d', $this->order->delivery_number).'.pdf';
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -1187,7 +1187,8 @@ class WebserviceRequestCore
|
||||
else
|
||||
{
|
||||
$object = new $this->resourceConfiguration['retrieveData']['className']();
|
||||
if ($object->isMultiShopField($this->resourceConfiguration['fields'][$fieldName]['sqlId']))
|
||||
$assoc = Shop::getAssoTable($this->resourceConfiguration['retrieveData']['table']);
|
||||
if ($assoc !== false && $assoc['type'] == 'shop' && ($object->isMultiShopField($this->resourceConfiguration['fields'][$fieldName]['sqlId']) || $fieldName == 'id'))
|
||||
$table_alias = 'multi_shop_'.$this->resourceConfiguration['retrieveData']['table'];
|
||||
else
|
||||
$table_alias = '';
|
||||
|
||||
@@ -37,7 +37,7 @@ if (!Tools::getSafeModeStatus())
|
||||
$smarty->setConfigDir(_PS_SMARTY_DIR_.'configs');
|
||||
$smarty->caching = false;
|
||||
$smarty->force_compile = (Configuration::get('PS_SMARTY_FORCE_COMPILE') == _PS_SMARTY_FORCE_COMPILE_) ? true : false;
|
||||
$smarty->compile_check = (Configuration::get('PS_SMARTY_FORCE_COMPILE') <= _PS_SMARTY_CHECK_COMPILE_) ? true : false;
|
||||
$smarty->compile_check = (Configuration::get('PS_SMARTY_FORCE_COMPILE') >= _PS_SMARTY_CHECK_COMPILE_) ? true : false;
|
||||
|
||||
// Production mode
|
||||
$smarty->debugging = false;
|
||||
|
||||
@@ -300,6 +300,9 @@ class AdminAddressesControllerCore extends AdminController
|
||||
|
||||
public function processSave()
|
||||
{
|
||||
if (Tools::getValue('submitFormAjax'))
|
||||
$this->redirect_after = false;
|
||||
|
||||
// Transform e-mail in id_customer for parent processing
|
||||
if (Validate::isEmail(Tools::getValue('email')))
|
||||
{
|
||||
|
||||
@@ -245,7 +245,7 @@ class AdminAttributesGroupsControllerCore extends AdminController
|
||||
'input' => array(
|
||||
array(
|
||||
'type' => 'select',
|
||||
'label' => $this->l('Attribute type:'),
|
||||
'label' => $this->l('Attribute group:'),
|
||||
'name' => 'id_attribute_group',
|
||||
'required' => true,
|
||||
'options' => array(
|
||||
@@ -253,7 +253,7 @@ class AdminAttributesGroupsControllerCore extends AdminController
|
||||
'id' => 'id_attribute_group',
|
||||
'name' => 'name'
|
||||
),
|
||||
'hint' => $this->l('Choose the type of the attribute')
|
||||
'hint' => $this->l('Choose the group of the attribute')
|
||||
),
|
||||
array(
|
||||
'type' => 'text',
|
||||
|
||||
@@ -237,16 +237,16 @@ class AdminBackupControllerCore extends AdminController
|
||||
$date = date('Y-m-d H:i:s', $timestamp);
|
||||
$age = time() - $timestamp;
|
||||
if ($age < 3600)
|
||||
$age = '< 1 '.$this->l('Hour');
|
||||
$age = '< 1 '.$this->l('Hour', 'AdminTab', false, false);
|
||||
else if ($age < 86400)
|
||||
{
|
||||
$age = floor($age / 3600);
|
||||
$age = $age.' '.(($age == 1) ? $this->l('Hour') : $this->l('Hours'));
|
||||
$age = $age.' '.(($age == 1) ? $this->l('Hour', 'AdminTab', false, false) : $this->l('Hours', 'AdminTab', false, false));
|
||||
}
|
||||
else
|
||||
{
|
||||
$age = floor($age / 86400);
|
||||
$age = $age.' '.(($age == 1) ? $this->l('Day') : $this->l('Days'));
|
||||
$age = $age.' '.(($age == 1) ? $this->l('Day') : $this->l('Days', 'AdminTab', false, false));
|
||||
}
|
||||
$size = filesize(_PS_ADMIN_DIR_.'/backups/'.$file);
|
||||
$this->_list[] = array(
|
||||
|
||||
@@ -612,7 +612,7 @@ class AdminCarrierWizardControllerCore extends AdminController
|
||||
}
|
||||
}
|
||||
else
|
||||
$this->validateRules('AdminCarrierWizardControllerCore');
|
||||
$this->validateRules();
|
||||
}
|
||||
|
||||
if (count($this->errors))
|
||||
@@ -756,6 +756,11 @@ class AdminCarrierWizardControllerCore extends AdminController
|
||||
$this->updateAssoShop((int)$new_carrier->id);
|
||||
$this->duplicateLogo((int)$new_carrier->id, (int)$current_carrier->id);
|
||||
$this->changeGroups((int)$new_carrier->id);
|
||||
|
||||
//Copy default carrier
|
||||
if (Configuration::get('PS_CARRIER_DEFAULT') == $current_carrier->id)
|
||||
Configuration::updateValue('PS_CARRIER_DEFAULT', (int)$new_carrier->id);
|
||||
|
||||
// Call of hooks
|
||||
Hook::exec('actionCarrierUpdate', array(
|
||||
'id_carrier' => (int)$current_carrier->id,
|
||||
@@ -867,7 +872,7 @@ class AdminCarrierWizardControllerCore extends AdminController
|
||||
return $return;
|
||||
}
|
||||
|
||||
public static function getValidationRules()
|
||||
public function getValidationRules()
|
||||
{
|
||||
$step_number = Tools::getValue('step_number');
|
||||
|
||||
@@ -887,20 +892,12 @@ class AdminCarrierWizardControllerCore extends AdminController
|
||||
array_splice($step_fields, 1, 0, $multistore_field);
|
||||
}
|
||||
|
||||
$rules = Carrier::getValidationRules('Carrier');
|
||||
|
||||
foreach ($rules as $key_r => $rule)
|
||||
foreach ($rule as $key_f => $field)
|
||||
{
|
||||
if (in_array($key_r, array('required', 'requiredLang')))
|
||||
{
|
||||
if(!in_array($field, $step_fields[$step_number]))
|
||||
unset($rules[$key_r][$key_f]);
|
||||
}
|
||||
else if(!in_array($key_f, $step_fields[$step_number]))
|
||||
unset($rules[$key_r][$key_f]);
|
||||
}
|
||||
return $rules;
|
||||
$definition = ObjectModel::getDefinition('Carrier');
|
||||
foreach ($definition['fields'] as $field => $def)
|
||||
if (!in_array($field, $step_fields[$step_number]))
|
||||
unset($definition['fields'][$field]);
|
||||
|
||||
return $definition;
|
||||
}
|
||||
|
||||
public static function displayFieldName($field)
|
||||
|
||||
@@ -416,7 +416,7 @@ class AdminCartsControllerCore extends AdminController
|
||||
{
|
||||
if (Validate::isMessage($message_content))
|
||||
{
|
||||
$message->message = htmlentities($message_content, ENT_COMPAT, 'UTF-8');
|
||||
$message->message = $message_content;
|
||||
$message->id_cart = (int)$this->context->cart->id;
|
||||
$message->id_customer = (int)$this->context->cart->id_customer;
|
||||
$message->save();
|
||||
@@ -699,18 +699,21 @@ class AdminCartsControllerCore extends AdminController
|
||||
$free_shipping = true;
|
||||
break;
|
||||
}
|
||||
return array('summary' => $this->getCartSummary(),
|
||||
'delivery_option_list' => $this->getDeliveryOptionList(),
|
||||
'cart' => $this->context->cart,
|
||||
'addresses' => $this->context->customer->getAddresses((int)$this->context->cart->id_lang),
|
||||
'id_cart' => $id_cart,
|
||||
'order_message' => $message_content,
|
||||
'link_order' => $this->context->link->getPageLink(
|
||||
'order', false,
|
||||
(int)$this->context->cart->id_lang,
|
||||
'step=3&recover_cart='.$id_cart.'&token_cart='.md5(_COOKIE_KEY_.'recover_cart_'.$id_cart)),
|
||||
'free_shipping' => (int)$free_shipping
|
||||
);
|
||||
return array(
|
||||
'summary' => $this->getCartSummary(),
|
||||
'delivery_option_list' => $this->getDeliveryOptionList(),
|
||||
'cart' => $this->context->cart,
|
||||
'currency' => new Currency($this->context->cart->id_currency),
|
||||
'addresses' => $this->context->customer->getAddresses((int)$this->context->cart->id_lang),
|
||||
'id_cart' => $id_cart,
|
||||
'order_message' => $message_content,
|
||||
'link_order' => $this->context->link->getPageLink(
|
||||
'order', false,
|
||||
(int)$this->context->cart->id_lang,
|
||||
'step=3&recover_cart='.$id_cart.'&token_cart='.md5(_COOKIE_KEY_.'recover_cart_'.$id_cart)
|
||||
),
|
||||
'free_shipping' => (int)$free_shipping
|
||||
);
|
||||
}
|
||||
|
||||
public function initToolbar()
|
||||
|
||||
@@ -147,7 +147,7 @@ class AdminCurrenciesControllerCore extends AdminController
|
||||
array('key' => 2, 'name' => '0 000,00X ('.$this->l('as with Euros').')'),
|
||||
array('key' => 3, 'name' => 'X0.000,00'),
|
||||
array('key' => 4, 'name' => '0,000.00X'),
|
||||
array('key' => 5, 'name' => '0 000.00X') // Added for the switzerland currency
|
||||
array('key' => 5, 'name' => 'X0\'000.00') // Added for the switzerland currency
|
||||
),
|
||||
'name' => 'name',
|
||||
'id' => 'key'
|
||||
|
||||
@@ -149,9 +149,27 @@ class AdminFeaturesControllerCore extends AdminController
|
||||
);
|
||||
|
||||
$this->_where = sprintf('AND `id_feature` = %d', (int)$id);
|
||||
self::$currentIndex = self::$currentIndex.'&id_feature='.(int)$id.'&viewfeature';
|
||||
$this->processFilter();
|
||||
return parent::renderList();
|
||||
|
||||
// get list and force no limit clause in the request
|
||||
$this->getList($this->context->language->id, 'id_feature_value', 'ASC');
|
||||
|
||||
// Render list
|
||||
$helper = new HelperList();
|
||||
$helper->actions = $this->actions;
|
||||
$helper->no_link = true;
|
||||
$helper->shopLinkType = '';
|
||||
$helper->identifier = $this->identifier;
|
||||
$helper->toolbar_scroll = false;
|
||||
$helper->currentIndex = self::$currentIndex;
|
||||
$helper->token = $this->token;
|
||||
$helper->table = $this->table;
|
||||
$helper->simple_header = true;
|
||||
$helper->show_toolbar = false;
|
||||
$helper->bulk_actions = $this->bulk_actions;
|
||||
$content = $helper->generateList($this->_list, $this->fields_list);
|
||||
|
||||
echo Tools::jsonEncode(array('use_parent_structure' => false, 'data' => $content));
|
||||
exit;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -206,7 +206,7 @@ class AdminGroupsControllerCore extends AdminController
|
||||
$this->list_id = 'customer_group';
|
||||
$this->actions = array();
|
||||
$this->bulk_actions = false;
|
||||
$this->no_link = true;
|
||||
$this->list_no_link = true;
|
||||
$this->fields_list = (array(
|
||||
'id_customer' => array('title' => $this->l('ID'), 'align' => 'center', 'filter_key' => 'c!id_customer', 'class' => 'fixed-width-xs'),
|
||||
'id_gender' => array('title' => $this->l('Titles'), 'icon' => $genders_icon, 'list' => $genders),
|
||||
|
||||
@@ -220,8 +220,16 @@ class AdminImportControllerCore extends AdminController
|
||||
'ean13' => array('label' => $this->l('EAN13')),
|
||||
'upc' => array('label' => $this->l('UPC')),
|
||||
'ecotax' => array('label' => $this->l('Ecotax')),
|
||||
'width' => array('label' => $this->l('Width')),
|
||||
'height' => array('label' => $this->l('Height')),
|
||||
'depth' => array('label' => $this->l('Depth')),
|
||||
'weight' => array('label' => $this->l('Weight')),
|
||||
'quantity' => array('label' => $this->l('Quantity')),
|
||||
'minimal_quantity' => array('label' => $this->l('Minimal quantity')),
|
||||
'visibility' => array('label' => $this->l('Visibility')),
|
||||
'additional_shipping_cost' => array('label' => $this->l('Additional shipping cost')),
|
||||
'unity' => array('label' => $this->l('Unity')),
|
||||
'unit_price_ratio' => array('label' => $this->l('Unit price ratio')),
|
||||
'description_short' => array('label' => $this->l('Short description')),
|
||||
'description' => array('label' => $this->l('Description')),
|
||||
'tags' => array('label' => $this->l('Tags (x,y,z...)')),
|
||||
@@ -232,6 +240,7 @@ class AdminImportControllerCore extends AdminController
|
||||
'available_now' => array('label' => $this->l('Text when in stock')),
|
||||
'available_later' => array('label' => $this->l('Text when backorder allowed')),
|
||||
'available_for_order' => array('label' => $this->l('Available for order (0 = No, 1 = Yes)')),
|
||||
'available_date' => array('label' => $this->l('Product available date')),
|
||||
'date_add' => array('label' => $this->l('Product creation date')),
|
||||
'show_price' => array('label' => $this->l('Show price (0 = No, 1 = Yes)')),
|
||||
'image' => array('label' => $this->l('Image URLs (x,y,z...)')),
|
||||
@@ -241,6 +250,11 @@ class AdminImportControllerCore extends AdminController
|
||||
'features' => array('label' => $this->l('Feature(Name:Value:Position)')),
|
||||
'online_only' => array('label' => $this->l('Available online only (0 = No, 1 = Yes)')),
|
||||
'condition' => array('label' => $this->l('Condition')),
|
||||
'customizable' => array('label' => $this->l('Customizable (0 = No, 1 = Yes)')),
|
||||
'uploadable_files' => array('label' => $this->l('Uploadable files (0 = No, 1 = Yes)')),
|
||||
'text_fields' => array('label' => $this->l('Text fields (0 = No, 1 = Yes)')),
|
||||
'out_of_stock' => array('label' => $this->l('Out_of_stock')),
|
||||
'advanced_stock_management' => array('label' => $this->l('Advanced stock management')),
|
||||
'shop' => array(
|
||||
'label' => $this->l('ID / Name of shop'),
|
||||
'help' => $this->l('Ignore this field if you don\'t use the Multistore tool. If you leave this field empty, the default shop will be used.'),
|
||||
@@ -251,15 +265,28 @@ class AdminImportControllerCore extends AdminController
|
||||
'id_category' => array((int)Configuration::get('PS_HOME_CATEGORY')),
|
||||
'id_category_default' => (int)Configuration::get('PS_HOME_CATEGORY'),
|
||||
'active' => '1',
|
||||
'width' => 0.000000,
|
||||
'height' => 0.000000,
|
||||
'depth' => 0.000000,
|
||||
'weight' => 0.000000,
|
||||
'visibility' => 'both',
|
||||
'additional_shipping_cost' => 0.00,
|
||||
'unit_price_ratio' => 0.000000,
|
||||
'quantity' => 0,
|
||||
'minimal_quantity' => 1,
|
||||
'price' => 0,
|
||||
'id_tax_rules_group' => 0,
|
||||
'description_short' => array((int)Configuration::get('PS_LANG_DEFAULT') => ''),
|
||||
'link_rewrite' => array((int)Configuration::get('PS_LANG_DEFAULT') => ''),
|
||||
'online_only' => 0,
|
||||
'condition' => 'new',
|
||||
'available_date' => date('Y-m-d'),
|
||||
'date_add' => date('Y-m-d H:i:s'),
|
||||
'condition' => 'new',
|
||||
'customizable' => 0,
|
||||
'uploadable_files' => 0,
|
||||
'text_fields' => 0,
|
||||
'out_of_stock' => '2',
|
||||
'advanced_stock_management' => '0',
|
||||
);
|
||||
break;
|
||||
|
||||
@@ -279,6 +306,7 @@ class AdminImportControllerCore extends AdminController
|
||||
'firstname' => array('label' => $this->l('First Name *')),
|
||||
'newsletter' => array('label' => $this->l('Newsletter (0/1)')),
|
||||
'optin' => array('label' => $this->l('Opt-in (0/1)')),
|
||||
'group' => array('label' => $this->l('Groupe Name')),
|
||||
'id_shop' => array(
|
||||
'label' => $this->l('ID / Name of shop'),
|
||||
'help' => $this->l('Ignore this field if you don\'t use the Multistore tool. If you leave this field empty, the default shop will be used.'),
|
||||
@@ -294,6 +322,7 @@ class AdminImportControllerCore extends AdminController
|
||||
case $this->entities[$this->l('Addresses')]:
|
||||
//Overwrite required_fields
|
||||
$this->required_fields = array(
|
||||
'alias',
|
||||
'lastname',
|
||||
'firstname',
|
||||
'address1',
|
||||
@@ -308,7 +337,7 @@ class AdminImportControllerCore extends AdminController
|
||||
'id' => array('label' => $this->l('ID')),
|
||||
'alias' => array('label' => $this->l('Alias *')),
|
||||
'active' => array('label' => $this->l('Active (0/1)')),
|
||||
'customer_email' => array('label' => $this->l('Customer email')),
|
||||
'customer_email' => array('label' => $this->l('Customer email *')),
|
||||
'id_customer' => array('label' => $this->l('Customer ID:')),
|
||||
'manufacturer' => array('label' => $this->l('Manufacturer')),
|
||||
'supplier' => array('label' => $this->l('Supplier')),
|
||||
@@ -317,7 +346,7 @@ class AdminImportControllerCore extends AdminController
|
||||
'firstname' => array('label' => $this->l('First Name *')),
|
||||
'address1' => array('label' => $this->l('Address 1 *')),
|
||||
'address2' => array('label' => $this->l('Address 2')),
|
||||
'postcode' => array('label' => $this->l('Postal code / Zipcode*')),
|
||||
'postcode' => array('label' => $this->l('Postal code / Zipcode *')),
|
||||
'city' => array('label' => $this->l('City *')),
|
||||
'country' => array('label' => $this->l('Country *')),
|
||||
'state' => array('label' => $this->l('State')),
|
||||
@@ -427,12 +456,8 @@ class AdminImportControllerCore extends AdminController
|
||||
|
||||
}
|
||||
|
||||
$this->separator = strval(trim(Tools::getValue('separator', ';')));
|
||||
|
||||
if (is_null(Tools::getValue('multiple_value_separator')) || trim(Tools::getValue('multiple_value_separator')) == '')
|
||||
$this->multiple_value_separator = ',';
|
||||
else
|
||||
$this->multiple_value_separator = Tools::getValue('multiple_value_separator');
|
||||
$this->separator = substr(strval(trim(Tools::getValue('separator', ';'))), 0, 1);
|
||||
$this->multiple_value_separator = substr(strval(trim(Tools::getValue('multiple_value_separator', ','))), 0, 1);
|
||||
|
||||
parent::__construct();
|
||||
}
|
||||
@@ -470,14 +495,26 @@ class AdminImportControllerCore extends AdminController
|
||||
if (isset($this->entities[$this->l(Tools::ucfirst(Tools::getValue('import_type')))]))
|
||||
{
|
||||
$entity_selected = $this->entities[$this->l(Tools::ucfirst(Tools::getValue('import_type')))];
|
||||
$this->context->cookie->entity_selected = $entity_selected;
|
||||
$this->context->cookie->entity_selected = (int)$entity_selected;
|
||||
}
|
||||
elseif (isset($this->context->cookie->entity_selected))
|
||||
$entity_selected = (int)$this->context->cookie->entity_selected;
|
||||
|
||||
|
||||
$csv_selected = '';
|
||||
if (isset($this->context->cookie->csv_selected))
|
||||
$csv_selected = pSQL($this->context->cookie->csv_selected);
|
||||
$csv_selected = base64_decode($this->context->cookie->csv_selected);
|
||||
|
||||
$id_lang_selected = '';
|
||||
if (isset($this->context->cookie->iso_lang_selected) && $this->context->cookie->iso_lang_selected)
|
||||
$id_lang_selected = (int)Language::getIdByIso(base64_decode($this->context->cookie->iso_lang_selected));
|
||||
|
||||
$separator_selected = $this->multiple_value_separator;
|
||||
if (isset($this->context->cookie->separator_selected) && $this->context->cookie->separator_selected)
|
||||
$separator_selected = base64_decode($this->context->cookie->separator_selected);
|
||||
|
||||
$multiple_value_separator_selected = $this->separator;
|
||||
if (isset($this->context->cookie->multiple_value_separator_selected) && $this->context->cookie->multiple_value_separator_selected)
|
||||
$multiple_value_separator_selected = base64_decode($this->context->cookie->multiple_value_separator_selected);
|
||||
|
||||
$this->tpl_form_vars = array(
|
||||
'module_confirmation' => (Tools::getValue('import')) && (isset($this->warnings) && !count($this->warnings)),
|
||||
@@ -485,9 +522,11 @@ class AdminImportControllerCore extends AdminController
|
||||
'entities' => $this->entities,
|
||||
'entity_selected' => $entity_selected,
|
||||
'csv_selected' => $csv_selected,
|
||||
'separator_selected' => $separator_selected,
|
||||
'multiple_value_separator_selected' => $multiple_value_separator_selected,
|
||||
'files_to_import' => $files_to_import,
|
||||
'languages' => Language::getLanguages(false),
|
||||
'id_language' => $this->context->language->id,
|
||||
'id_language' => ($id_lang_selected) ? $id_lang_selected : $this->context->language->id,
|
||||
'available_fields' => $this->getAvailableFields(),
|
||||
'truncateAuthorized' => (Shop::isFeatureActive() && $this->context->employee->isSuperAdmin()) || !Shop::isFeatureActive(),
|
||||
'PS_ADVANCED_STOCK_MANAGEMENT' => Configuration::get('PS_ADVANCED_STOCK_MANAGEMENT'),
|
||||
@@ -512,10 +551,11 @@ class AdminImportControllerCore extends AdminController
|
||||
for ($i = 0; $i < $nb_table; $i++)
|
||||
$data[$i] = $this->generateContentTable($i, $nb_column, $handle, $this->separator);
|
||||
|
||||
if ($entity_selected = (int)Tools::getValue('entity'))
|
||||
$this->context->cookie->entity_selected = $entity_selected;
|
||||
if ($csv_selected = Tools::getValue('csv'))
|
||||
$this->context->cookie->csv_selected = $csv_selected;
|
||||
$this->context->cookie->entity_selected = (int)Tools::getValue('entity');
|
||||
$this->context->cookie->iso_lang_selected = base64_encode(Tools::getValue('iso_lang'));
|
||||
$this->context->cookie->separator_selected = base64_encode(Tools::getValue('separator'));
|
||||
$this->context->cookie->multiple_value_separator_selected = base64_encode(Tools::getValue('multiple_value_separator'));
|
||||
$this->context->cookie->csv_selected = base64_encode(Tools::getValue('csv'));
|
||||
|
||||
$this->tpl_view_vars = array(
|
||||
'import_matchs' => Db::getInstance()->executeS('SELECT * FROM '._DB_PREFIX_.'import_match'),
|
||||
@@ -574,18 +614,13 @@ class AdminImportControllerCore extends AdminController
|
||||
// Header
|
||||
for ($i = 0; $i < $nb_column; $i++)
|
||||
if (MAX_COLUMNS * (int)$current_table <= $i && (int)$i < MAX_COLUMNS * ((int)$current_table + 1))
|
||||
$html .= '<th width:"'.(900 / MAX_COLUMNS).'" valign="top">
|
||||
<select onchange="askFeatureName(this, '.$i.');"
|
||||
style="width: '.(900 / MAX_COLUMNS).'px;"
|
||||
$html .= '<th style="width: '.(900 / MAX_COLUMNS).'px; vertical-align: top; padding: 4px">
|
||||
<select style="width: '.(900 / MAX_COLUMNS).'px;"
|
||||
id="type_value['.$i.']"
|
||||
name="type_value['.$i.']"
|
||||
class="type_value">
|
||||
'.$this->getTypeValuesOptions($i).'
|
||||
</select>
|
||||
<div id="features_'.$i.'" style="display: none;">
|
||||
<input style="width: 90px" type="text" name="" id="feature_name_'.$i.'">
|
||||
<input type="button" value="ok" onclick="replaceFeature($(\'#feature_name_'.$i.'\').attr(\'name\'), '.$i.');">
|
||||
</div>
|
||||
</th>';
|
||||
$html .= '</tr>';
|
||||
|
||||
@@ -675,7 +710,8 @@ class AdminImportControllerCore extends AdminController
|
||||
$fd = fopen($uniqid_path, 'r');
|
||||
$tab = fgetcsv($fd, MAX_LINE_SIZE, $separator);
|
||||
fclose($fd);
|
||||
unlink($uniqid_path);
|
||||
if (file_exists($uniqid_path))
|
||||
@unlink($uniqid_path);
|
||||
}
|
||||
|
||||
if (empty($tab) || (!is_array($tab)))
|
||||
@@ -873,6 +909,9 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->receiveTab();
|
||||
$handle = $this->openCsvFile();
|
||||
$default_language_id = (int)Configuration::get('PS_LANG_DEFAULT');
|
||||
$id_lang = Language::getIdByIso(Tools::getValue('iso_lang'));
|
||||
if (!Validate::isUnsignedId($id_lang))
|
||||
$id_lang = $default_language_id;
|
||||
AdminImportController::setLocale();
|
||||
for ($current_line = 0; $line = fgetcsv($handle, MAX_LINE_SIZE, $this->separator); $current_line++)
|
||||
{
|
||||
@@ -919,8 +958,8 @@ class AdminImportControllerCore extends AdminController
|
||||
$category_to_create = new Category();
|
||||
$category_to_create->name = AdminImportController::createMultiLangField($category->parent);
|
||||
$category_to_create->active = 1;
|
||||
$category_link_rewrite = Tools::link_rewrite($category_to_create->name[$default_language_id]);
|
||||
$category_to_create->link_rewrite = $category_link_rewrite;
|
||||
$category_link_rewrite = Tools::link_rewrite($category_to_create->name[$id_lang]);
|
||||
$category_to_create->link_rewrite = AdminImportController::createMultiLangField($category_link_rewrite);
|
||||
$category_to_create->id_parent = Configuration::get('PS_HOME_CATEGORY'); // Default parent is home for unknown category to create
|
||||
if (($field_error = $category_to_create->validateFields(UNFRIENDLY_ERROR, true)) === true &&
|
||||
($lang_field_error = $category_to_create->validateFieldsLang(UNFRIENDLY_ERROR, true)) === true && $category_to_create->add())
|
||||
@@ -930,7 +969,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$category_to_create->name[$default_language_id],
|
||||
(isset($category_to_create->id) ? $category_to_create->id : 'null')
|
||||
(isset($category_to_create->id) && !empty($category_to_create->id))? $category_to_create->id : 'null'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -963,7 +1002,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->warnings[] = sprintf(
|
||||
Tools::displayError('Rewrite link for %1$s (ID: %2$s) was re-written as %3$s.'),
|
||||
$bak,
|
||||
(isset($info['id']) ? $info['id'] : 'null'),
|
||||
(isset($info['id']) && !empty($info['id']))? $info['id'] : 'null',
|
||||
$category->link_rewrite[$default_language_id]
|
||||
);
|
||||
$res = false;
|
||||
@@ -1011,8 +1050,8 @@ class AdminImportControllerCore extends AdminController
|
||||
{
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
(isset($info['name']) ? Tools::safeOutput($info['name']) : 'No Name'),
|
||||
(isset($info['id']) ? Tools::safeOutput($info['id']) : 'No ID')
|
||||
(isset($info['name']) && !empty($info['name']))? Tools::safeOutput($info['name']) : 'No Name',
|
||||
(isset($info['id']) && !empty($info['id']))? Tools::safeOutput($info['id']) : 'No ID'
|
||||
);
|
||||
$error_tmp = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').Db::getInstance()->getMsgError();
|
||||
if ($error_tmp != '')
|
||||
@@ -1056,6 +1095,9 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->receiveTab();
|
||||
$handle = $this->openCsvFile();
|
||||
$default_language_id = (int)Configuration::get('PS_LANG_DEFAULT');
|
||||
$id_lang = Language::getIdByIso(Tools::getValue('iso_lang'));
|
||||
if (!Validate::isUnsignedId($id_lang))
|
||||
$id_lang = $default_language_id;
|
||||
AdminImportController::setLocale();
|
||||
$shop_ids = Shop::getCompleteListOfShopsID();
|
||||
for ($current_line = 0; $line = fgetcsv($handle, MAX_LINE_SIZE, $this->separator); $current_line++)
|
||||
@@ -1066,13 +1108,23 @@ class AdminImportControllerCore extends AdminController
|
||||
|
||||
if (Tools::getValue('forceIDs') && isset($info['id']) && (int)$info['id'])
|
||||
$product = new Product((int)$info['id']);
|
||||
else
|
||||
elseif (Tools::getValue('match_ref') && array_key_exists('reference', $info))
|
||||
{
|
||||
if (array_key_exists('id', $info) && (int)$info['id'] && Product::existsInDatabase((int)$info['id'], 'product'))
|
||||
$product = new Product((int)$info['id']);
|
||||
else
|
||||
$product = new Product();
|
||||
$datas = Db::getInstance()->getRow('
|
||||
SELECT p.`id_product`
|
||||
FROM `'._DB_PREFIX_.'product` p
|
||||
'.Shop::addSqlAssociation('product', 'p').'
|
||||
WHERE p.`reference` = "'.pSQL($info['reference']).'"
|
||||
');
|
||||
if (isset($datas['id_product']) && $datas['id_product'])
|
||||
$product = new Product((int)$datas['id_product']);
|
||||
else
|
||||
$product = new Product();
|
||||
}
|
||||
elseif (array_key_exists('id', $info) && (int)$info['id'] && Product::existsInDatabase((int)$info['id'], 'product'))
|
||||
$product = new Product((int)$info['id']);
|
||||
else
|
||||
$product = new Product();
|
||||
|
||||
if (array_key_exists('id', $info) && (int)$info['id'] && Product::existsInDatabase((int)$info['id'], 'product'))
|
||||
{
|
||||
@@ -1137,7 +1189,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$manufacturer->name,
|
||||
(isset($manufacturer->id) ? $manufacturer->id : 'null')
|
||||
(isset($manufacturer->id) && !empty($manufacturer->id))? $manufacturer->id : 'null'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -1168,7 +1220,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$supplier->name,
|
||||
(isset($supplier->id) ? $supplier->id : 'null')
|
||||
(isset($supplier->id) && !empty($supplier->id))? $supplier->id : 'null'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -1214,7 +1266,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$category_to_create->name[$default_language_id],
|
||||
(isset($category_to_create->id) ? $category_to_create->id : 'null')
|
||||
(isset($category_to_create->id) && !empty($category_to_create->id))? $category_to_create->id : 'null'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -1246,7 +1298,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$category_to_create->name[$default_language_id],
|
||||
(isset($category_to_create->id) ? $category_to_create->id : 'null')
|
||||
(isset($category_to_create->id) && !empty($category_to_create->id))? $category_to_create->id : 'null'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -1257,14 +1309,14 @@ class AdminImportControllerCore extends AdminController
|
||||
}
|
||||
|
||||
$product->id_category_default = isset($product->id_category[0]) ? (int)$product->id_category[0] : '';
|
||||
|
||||
$link_rewrite = (is_array($product->link_rewrite) && count($product->link_rewrite)) ? trim($product->link_rewrite[$default_language_id]) : '';
|
||||
|
||||
$link_rewrite = (is_array($product->link_rewrite) && isset($product->link_rewrite[$id_lang])) ? trim($product->link_rewrite[$id_lang]) : '';
|
||||
|
||||
$valid_link = Validate::isLinkRewrite($link_rewrite);
|
||||
|
||||
if ((isset($product->link_rewrite[$default_language_id]) && empty($product->link_rewrite[$default_language_id])) || !$valid_link)
|
||||
if ((isset($product->link_rewrite[$id_lang]) && empty($product->link_rewrite[$id_lang])) || !$valid_link)
|
||||
{
|
||||
$link_rewrite = Tools::link_rewrite($product->name[$default_language_id]);
|
||||
$link_rewrite = Tools::link_rewrite($product->name[$id_lang]);
|
||||
if ($link_rewrite == '')
|
||||
$link_rewrite = 'friendly-url-autogeneration-failed';
|
||||
}
|
||||
@@ -1272,18 +1324,20 @@ class AdminImportControllerCore extends AdminController
|
||||
if (!$valid_link)
|
||||
$this->warnings[] = sprintf(
|
||||
Tools::displayError('Rewrite link for %1$s (ID: %2$s) was re-written as %3$s.'),
|
||||
$product->name[$default_language_id],
|
||||
(isset($info['id']) ? $info['id'] : 'null'),
|
||||
$product->name[$id_lang],
|
||||
(isset($info['id']) && !empty($info['id']))? $info['id'] : 'null',
|
||||
$link_rewrite
|
||||
);
|
||||
|
||||
$product->link_rewrite = AdminImportController::createMultiLangField($link_rewrite);
|
||||
if (!Tools::getValue('match_ref') || !(is_array($product->link_rewrite) && count($product->link_rewrite) && !empty($product->link_rewrite[$id_lang])))
|
||||
$product->link_rewrite = AdminImportController::createMultiLangField($link_rewrite);
|
||||
|
||||
// replace the value of separator by coma
|
||||
if ($this->multiple_value_separator != ',')
|
||||
foreach ($product->meta_keywords as &$meta_keyword)
|
||||
if (!empty($meta_keyword))
|
||||
$meta_keyword = str_replace($this->multiple_value_separator, ',', $meta_keyword);
|
||||
if (is_array($product->meta_keywords))
|
||||
foreach ($product->meta_keywords as &$meta_keyword)
|
||||
if (!empty($meta_keyword))
|
||||
$meta_keyword = str_replace($this->multiple_value_separator, ',', $meta_keyword);
|
||||
|
||||
// Convert comma into dot for all floating values
|
||||
foreach (Product::$definition['fields'] as $key => $array)
|
||||
@@ -1309,7 +1363,7 @@ class AdminImportControllerCore extends AdminController
|
||||
SELECT product_shop.`date_add`, p.`id_product`
|
||||
FROM `'._DB_PREFIX_.'product` p
|
||||
'.Shop::addSqlAssociation('product', 'p').'
|
||||
WHERE p.`reference` = "'.$product->reference.'"
|
||||
WHERE p.`reference` = "'.pSQL($product->reference).'"
|
||||
');
|
||||
$product->id = (int)$datas['id_product'];
|
||||
$product->date_add = pSQL($datas['date_add']);
|
||||
@@ -1355,8 +1409,8 @@ class AdminImportControllerCore extends AdminController
|
||||
{
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
(isset($info['name']) ? Tools::safeOutput($info['name']) : 'No Name'),
|
||||
(isset($info['id']) ? Tools::safeOutput($info['id']) : 'No ID')
|
||||
(isset($info['name']) && !empty($info['name']))? Tools::safeOutput($info['name']) : 'No Name',
|
||||
(isset($info['id']) && !empty($info['id']))? Tools::safeOutput($info['id']) : 'No ID'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -1365,7 +1419,7 @@ class AdminImportControllerCore extends AdminController
|
||||
else
|
||||
{
|
||||
// Product supplier
|
||||
if (isset($product->id_supplier) && isset($product->supplier_reference))
|
||||
if (isset($product->id_supplier) && property_exists($product, 'supplier_reference'))
|
||||
{
|
||||
$id_product_supplier = ProductSupplier::getIdByProductAndSupplier((int)$product->id, 0, (int)$product->id_supplier);
|
||||
if ($id_product_supplier)
|
||||
@@ -1382,31 +1436,67 @@ class AdminImportControllerCore extends AdminController
|
||||
}
|
||||
|
||||
// SpecificPrice (only the basic reduction feature is supported by the import)
|
||||
if ((isset($info['reduction_price']) && $info['reduction_price'] > 0) || (isset($info['reduction_percent']) && $info['reduction_percent'] > 0))
|
||||
{
|
||||
$specific_price = new SpecificPrice();
|
||||
$specific_price->id_product = (int)$product->id;
|
||||
// @todo multishop specific price import
|
||||
$specific_price->id_shop = $this->context->shop->id;
|
||||
$specific_price->id_currency = 0;
|
||||
$specific_price->id_country = 0;
|
||||
$specific_price->id_group = 0;
|
||||
$specific_price->price = -1;
|
||||
$specific_price->id_customer = 0;
|
||||
$specific_price->from_quantity = 1;
|
||||
$specific_price->reduction = (isset($info['reduction_price']) && $info['reduction_price']) ? $info['reduction_price'] : $info['reduction_percent'] / 100;
|
||||
$specific_price->reduction_type = (isset($info['reduction_price']) && $info['reduction_price']) ? 'amount' : 'percentage';
|
||||
$specific_price->from = (isset($info['reduction_from']) && Validate::isDate($info['reduction_from'])) ? $info['reduction_from'] : '0000-00-00 00:00:00';
|
||||
$specific_price->to = (isset($info['reduction_to']) && Validate::isDate($info['reduction_to'])) ? $info['reduction_to'] : '0000-00-00 00:00:00';
|
||||
if (!$specific_price->add())
|
||||
$this->addProductWarning(Tools::safeOutput($info['name']), $product->id, $this->l('Discount is invalid'));
|
||||
}
|
||||
if (!Shop::isFeatureActive())
|
||||
$info['shop'] = 1;
|
||||
elseif (!isset($info['shop']) || empty($info['shop']))
|
||||
$info['shop'] = implode($this->multiple_value_separator, Shop::getContextListShopID());
|
||||
|
||||
// Get shops for each attributes
|
||||
$info['shop'] = explode($this->multiple_value_separator, $info['shop']);
|
||||
|
||||
$id_shop_list = array();
|
||||
foreach ($info['shop'] as $shop)
|
||||
if (!is_numeric($shop))
|
||||
$id_shop_list[] = (int)Shop::getIdByName($shop);
|
||||
else
|
||||
$id_shop_list[] = $shop;
|
||||
|
||||
if ((isset($info['reduction_price']) && $info['reduction_price'] > 0) || (isset($info['reduction_percent']) && $info['reduction_percent'] > 0))
|
||||
foreach($id_shop_list as $id_shop)
|
||||
{
|
||||
$specific_price = SpecificPrice::getSpecificPrice($product->id, $id_shop, 0, 0, 0, 1, 0, 0, 0, 0);
|
||||
|
||||
if (is_array($specific_price) && isset($specific_price['id_specific_price']))
|
||||
$specific_price = new SpecificPrice((int)$specific_price['id_specific_price']);
|
||||
else
|
||||
$specific_price = new SpecificPrice();
|
||||
$specific_price->id_product = (int)$product->id;
|
||||
$specific_price->id_specific_price_rule = 0;
|
||||
$specific_price->id_shop = $id_shop;
|
||||
$specific_price->id_currency = 0;
|
||||
$specific_price->id_country = 0;
|
||||
$specific_price->id_group = 0;
|
||||
$specific_price->price = -1;
|
||||
$specific_price->id_customer = 0;
|
||||
$specific_price->from_quantity = 1;
|
||||
$specific_price->reduction = (isset($info['reduction_price']) && $info['reduction_price']) ? $info['reduction_price'] : $info['reduction_percent'] / 100;
|
||||
$specific_price->reduction_type = (isset($info['reduction_price']) && $info['reduction_price']) ? 'amount' : 'percentage';
|
||||
$specific_price->from = (isset($info['reduction_from']) && Validate::isDate($info['reduction_from'])) ? $info['reduction_from'] : '0000-00-00 00:00:00';
|
||||
$specific_price->to = (isset($info['reduction_to']) && Validate::isDate($info['reduction_to'])) ? $info['reduction_to'] : '0000-00-00 00:00:00';
|
||||
if (!$specific_price->save())
|
||||
$this->addProductWarning(Tools::safeOutput($info['name']), $product->id, $this->l('Discount is invalid'));
|
||||
}
|
||||
|
||||
if (isset($product->tags) && !empty($product->tags))
|
||||
{
|
||||
if (isset($product->id) && $product->id)
|
||||
{
|
||||
$tags = Tag::getProductTags($product->id);
|
||||
if (is_array($tags) && count($tags))
|
||||
{
|
||||
if (!empty($product->tags))
|
||||
$product->tags = explode($this->multiple_value_separator, $product->tags);
|
||||
if (is_array($product->tags) && count($product->tags))
|
||||
{
|
||||
foreach ($product->tags as $key => $tag)
|
||||
$product->tags[$key] = trim($tag);
|
||||
$tags[$id_lang] = $product->tags;
|
||||
$product->tags = $tags;
|
||||
}
|
||||
}
|
||||
}
|
||||
// Delete tags for this id product, for no duplicating error
|
||||
Tag::deleteTagsForProduct($product->id);
|
||||
|
||||
if (!is_array($product->tags))
|
||||
{
|
||||
$product->tags = AdminImportController::createMultiLangField($product->tags);
|
||||
@@ -1498,7 +1588,7 @@ class AdminImportControllerCore extends AdminController
|
||||
if(!empty($feature_name) && !empty($feature_value))
|
||||
{
|
||||
$id_feature = Feature::addFeatureImport($feature_name, $position);
|
||||
$id_feature_value = FeatureValue::addFeatureValueImport($id_feature, $feature_value);
|
||||
$id_feature_value = FeatureValue::addFeatureValueImport($id_feature, $feature_value, $product->id, $id_lang);
|
||||
Product::addFeatureProductImport($product->id, $id_feature, $id_feature_value);
|
||||
}
|
||||
}
|
||||
@@ -1759,8 +1849,9 @@ class AdminImportControllerCore extends AdminController
|
||||
null,
|
||||
$id_shop_list
|
||||
);
|
||||
|
||||
$id_product_attribute_update = true;
|
||||
if (isset($info['supplier_reference']) && !empty($info['supplier_reference']))
|
||||
$product->addSupplierReference($product->id_supplier, $id_product_attribute, $info['supplier_reference']);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1786,8 +1877,10 @@ class AdminImportControllerCore extends AdminController
|
||||
(int)$info['minimal_quantity'],
|
||||
$id_shop_list
|
||||
);
|
||||
if (isset($info['supplier_reference']) && !empty($info['supplier_reference']))
|
||||
$product->addSupplierReference($product->id_supplier, $id_product_attribute, $info['supplier_reference']);
|
||||
}
|
||||
|
||||
|
||||
// fills our attributes array, in order to add the attributes to the product_attribute afterwards
|
||||
if(isset($attributes[$group.'_'.$attribute]))
|
||||
$attributes_to_add[] = (int)$attributes[$group.'_'.$attribute];
|
||||
@@ -1831,6 +1924,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$customer_exist = false;
|
||||
$this->receiveTab();
|
||||
$handle = $this->openCsvFile();
|
||||
$default_language_id = (int)Configuration::get('PS_LANG_DEFAULT');
|
||||
AdminImportController::setLocale();
|
||||
for ($current_line = 0; $line = fgetcsv($handle, MAX_LINE_SIZE, $this->separator); $current_line++)
|
||||
{
|
||||
@@ -1863,6 +1957,26 @@ class AdminImportControllerCore extends AdminController
|
||||
unset($customer_groups[$key]);
|
||||
}
|
||||
|
||||
// Group Importation
|
||||
if (isset($info['group']) && !empty($info['group']))
|
||||
{
|
||||
if (!isset($customer_groups))
|
||||
$customer_groups = array();
|
||||
|
||||
$myGroup = Group::searchByName($default_language_id, $info['group']);
|
||||
|
||||
if (!$myGroup)
|
||||
{
|
||||
$myGroup = new Group();
|
||||
$myGroup->name = Array($default_language_id => $info['group']);
|
||||
$myGroup->price_display_method = 1;
|
||||
$myGroup->add();
|
||||
$myGroup = Group::searchByName($default_language_id, $info['group']);
|
||||
}
|
||||
if (isset($myGroup['0']['id_group']))
|
||||
$customer_groups[] = $myGroup['0']['id_group'];
|
||||
}
|
||||
|
||||
AdminImportController::arrayWalk($info, array('AdminImportController', 'fillInfo'), $customer);
|
||||
|
||||
if ($customer->passwd)
|
||||
@@ -1962,7 +2076,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$info['email'],
|
||||
(isset($info['id']) ? $info['id'] : 'null')
|
||||
(isset($info['id']) && !empty($info['id']))? $info['id'] : 'null'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -2059,7 +2173,7 @@ class AdminImportControllerCore extends AdminController
|
||||
Tools::displayError('%1$s does not exist in database %2$s (ID: %3$s) cannot be saved'),
|
||||
Db::getInstance()->getMsgError(),
|
||||
$address->customer_email,
|
||||
(isset($info['id']) ? $info['id'] : 'null')
|
||||
(isset($info['id']) && !empty($info['id']))? $info['id'] : 'null'
|
||||
);
|
||||
}
|
||||
else
|
||||
@@ -2108,7 +2222,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = Db::getInstance()->getMsgError().' '.sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$manufacturer->name,
|
||||
(isset($manufacturer->id) ? $manufacturer->id : 'null')
|
||||
(isset($manufacturer->id) && !empty($manufacturer->id))? $manufacturer->id : 'null'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -2129,7 +2243,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = Db::getInstance()->getMsgError().' '.sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$supplier->name,
|
||||
(isset($supplier->id) ? $supplier->id : 'null')
|
||||
(isset($supplier->id) && !empty($supplier->id))? $supplier->id : 'null'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -2158,7 +2272,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$info['alias'],
|
||||
(isset($info['id']) ? $info['id'] : 'null')
|
||||
(isset($info['id']) && !empty($info['id']))? $info['id'] : 'null'
|
||||
);
|
||||
}
|
||||
}
|
||||
@@ -2175,7 +2289,7 @@ class AdminImportControllerCore extends AdminController
|
||||
$this->errors[] = sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
$info['alias'],
|
||||
(isset($info['id']) ? $info['id'] : 'null')
|
||||
(isset($info['id']) && !empty($info['id']))? $info['id'] : 'null'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -2245,8 +2359,8 @@ class AdminImportControllerCore extends AdminController
|
||||
{
|
||||
$this->errors[] = Db::getInstance()->getMsgError().' '.sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
(isset($info['name']) ? Tools::safeOutput($info['name']) : 'No Name'),
|
||||
(isset($info['id']) ? Tools::safeOutput($info['id']) : 'No ID')
|
||||
(isset($info['name']) && !empty($info['name']))? Tools::safeOutput($info['name']) : 'No Name',
|
||||
(isset($info['id']) && !empty($info['id']))? Tools::safeOutput($info['id']) : 'No ID'
|
||||
);
|
||||
$this->errors[] = ($field_error !== true ? $field_error : '').(isset($lang_field_error) && $lang_field_error !== true ? $lang_field_error : '').
|
||||
Db::getInstance()->getMsgError();
|
||||
@@ -2292,8 +2406,8 @@ class AdminImportControllerCore extends AdminController
|
||||
if (!$res)
|
||||
$this->errors[] = Db::getInstance()->getMsgError().' '.sprintf(
|
||||
Tools::displayError('%1$s (ID: %2$s) cannot be saved'),
|
||||
(isset($info['name']) ? Tools::safeOutput($info['name']) : 'No Name'),
|
||||
(isset($info['id']) ? Tools::safeOutput($info['id']) : 'No ID')
|
||||
(isset($info['name']) && !empty($info['name']))? Tools::safeOutput($info['name']) : 'No Name',
|
||||
(isset($info['id']) && !empty($info['id']))? Tools::safeOutput($info['id']) : 'No ID'
|
||||
);
|
||||
else
|
||||
{
|
||||
@@ -2551,13 +2665,9 @@ class AdminImportControllerCore extends AdminController
|
||||
|
||||
protected static function usortFiles($a, $b)
|
||||
{
|
||||
$a = strrev(substr(strrev($a), 0, 14));
|
||||
$b = strrev(substr(strrev($b), 0, 14));
|
||||
|
||||
if ($a == $b)
|
||||
return 0;
|
||||
|
||||
return ($a < $b) ? 1 : -1;
|
||||
return ($b < $a) ? 1 : -1;
|
||||
}
|
||||
|
||||
protected function openCsvFile()
|
||||
@@ -2602,37 +2712,37 @@ class AdminImportControllerCore extends AdminController
|
||||
unlink(_PS_CAT_IMG_DIR_.$d);
|
||||
break;
|
||||
case $this->entities[$this->l('Products')]:
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_shop');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'feature_product');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_lang');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'category_product');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_tag');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'image');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'image_lang');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'image_shop');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'specific_price');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'specific_price_priority');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_carrier');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'cart_product');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'compare_product');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_shop`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'feature_product`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_lang`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'category_product`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_tag`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'image`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'image_lang`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'image_shop`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'specific_price`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'specific_price_priority`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_carrier`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'cart_product`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'compare_product`');
|
||||
if (count(Db::getInstance()->executeS('SHOW TABLES LIKE \''._DB_PREFIX_.'favorite_product\' '))) //check if table exist
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'favorite_product');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_attachment');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_country_tax');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_download');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_group_reduction_cache');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_sale');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_supplier');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'scene_products');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'warehouse_product_location');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'stock');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'stock_available');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'stock_mvt');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'customization');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'customization_field');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'supply_order_detail');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'attribute_impact');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'favorite_product`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_attachment`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_country_tax`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_download`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_group_reduction_cache`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_sale`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_supplier`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'scene_products`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'warehouse_product_location`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'stock`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'stock_available`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'stock_mvt`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'customization`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'customization_field`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'supply_order_detail`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'attribute_impact`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_attribute`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_attribute_shop`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_attribute_combination`');
|
||||
@@ -2643,7 +2753,7 @@ class AdminImportControllerCore extends AdminController
|
||||
break;
|
||||
case $this->entities[$this->l('Combinations')]:
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'attribute`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'attribute_impact');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'attribute_impact`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'attribute_lang`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'attribute_group`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'attribute_group_lang`');
|
||||
@@ -2653,26 +2763,26 @@ class AdminImportControllerCore extends AdminController
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_attribute_shop`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_attribute_combination`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'product_attribute_image`');
|
||||
Db::getInstance()->execute('DELETE FROM `'._DB_PREFIX_.'stock_available` WHERE id_product_attribute !=0');
|
||||
Db::getInstance()->execute('DELETE FROM `'._DB_PREFIX_.'stock_available` WHERE id_product_attribute != 0');
|
||||
break;
|
||||
case $this->entities[$this->l('Customers')]:
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'customer');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'customer`');
|
||||
break;
|
||||
case $this->entities[$this->l('Addresses')]:
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'address');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'address`');
|
||||
break;
|
||||
case $this->entities[$this->l('Manufacturers')]:
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'manufacturer');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'manufacturer_lang');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'manufacturer_shop');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'manufacturer`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'manufacturer_lang`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'manufacturer_shop`');
|
||||
foreach (scandir(_PS_MANU_IMG_DIR_) as $d)
|
||||
if (preg_match('/^[0-9]+(\-(.*))?\.jpg$/', $d))
|
||||
unlink(_PS_MANU_IMG_DIR_.$d);
|
||||
break;
|
||||
case $this->entities[$this->l('Suppliers')]:
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'supplier');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'supplier_lang');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'supplier_shop');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'supplier`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'supplier_lang`');
|
||||
Db::getInstance()->execute('TRUNCATE TABLE `'._DB_PREFIX_.'supplier_shop`');
|
||||
foreach (scandir(_PS_SUPP_IMG_DIR_) as $d)
|
||||
if (preg_match('/^[0-9]+(\-(.*))?\.jpg$/', $d))
|
||||
unlink(_PS_SUPP_IMG_DIR_.$d);
|
||||
@@ -2701,6 +2811,7 @@ class AdminImportControllerCore extends AdminController
|
||||
|
||||
if (Tools::isSubmit('submitFileUpload'))
|
||||
{
|
||||
$path = _PS_ADMIN_DIR_.'/import/'.date('Ymdhis').'-';
|
||||
if (isset($_FILES['file']) && !empty($_FILES['file']['error']))
|
||||
{
|
||||
switch ($_FILES['file']['error'])
|
||||
@@ -2726,13 +2837,18 @@ class AdminImportControllerCore extends AdminController
|
||||
break;
|
||||
}
|
||||
}
|
||||
else if (!file_exists($_FILES['file']['tmp_name']) ||
|
||||
!@move_uploaded_file($_FILES['file']['tmp_name'], _PS_ADMIN_DIR_.'/import/'.date('Ymdhis').'-'.$_FILES['file']['name']))
|
||||
elseif (!preg_match('/.*\.csv$/i', $_FILES['file']['name']))
|
||||
$this->errors[] = Tools::displayError('The extension of your file should be .csv.');
|
||||
elseif (!file_exists($_FILES['file']['tmp_name']) ||
|
||||
!@move_uploaded_file($_FILES['file']['tmp_name'], $path.$_FILES['file']['name']))
|
||||
$this->errors[] = $this->l('An error occurred while uploading / copying the file.');
|
||||
else
|
||||
{
|
||||
@chmod($path.$_FILES['file']['name'], 0664);
|
||||
Tools::redirectAdmin(self::$currentIndex.'&token='.Tools::getValue('token').'&conf=18');
|
||||
}
|
||||
}
|
||||
else if (Tools::getValue('import'))
|
||||
elseif (Tools::getValue('import'))
|
||||
{
|
||||
// Check if the CSV file exist
|
||||
if (Tools::getValue('csv'))
|
||||
@@ -2787,16 +2903,50 @@ class AdminImportControllerCore extends AdminController
|
||||
|
||||
if ($import_type !== false)
|
||||
{
|
||||
$log_message = sprintf($this->l('%s import'), $import_type);
|
||||
$log_message = sprintf($this->l('%s import', 'AdminTab', false, false), $import_type);
|
||||
if (Tools::getValue('truncate'))
|
||||
$log_message .= ' '.$this->l('with truncate');
|
||||
$log_message .= ' '.$this->l('with truncate', 'AdminTab', false, false);
|
||||
Logger::addLog($log_message, 1, null, $import_type, null, true, (int)$this->context->employee->id);
|
||||
}
|
||||
}
|
||||
else
|
||||
$this->errors[] = $this->l('You must upload a file in order to proceed to the next step');
|
||||
}
|
||||
|
||||
elseif ($filename = Tools::getValue('csvfilename'))
|
||||
{
|
||||
$filename = base64_decode($filename);
|
||||
$file = _PS_ADMIN_DIR_.'/import/'.basename($filename);
|
||||
if (realpath(dirname($file)) != _PS_ADMIN_DIR_.DIRECTORY_SEPARATOR.'import')
|
||||
exit();
|
||||
if (!empty($filename))
|
||||
{
|
||||
$bName = basename($filename);
|
||||
if ($delete = Tools::getValue('delete') && file_exists($file))
|
||||
@unlink($file);
|
||||
elseif (file_exists($file))
|
||||
{
|
||||
$bName = explode('.', $bName);
|
||||
$bName = strtolower($bName[count($bName) - 1]);
|
||||
$mimeTypes = array('csv' => 'text/csv');
|
||||
|
||||
if (isset($mimeTypes[$bName]))
|
||||
$mimeType = $mimeTypes[$bName];
|
||||
else
|
||||
$mimeType = 'application/octet-stream';
|
||||
if (ob_get_level())
|
||||
ob_end_clean();
|
||||
|
||||
header('Content-Transfer-Encoding: binary');
|
||||
header('Content-Type: '.$mimeType);
|
||||
header('Content-Length: '.filesize($file));
|
||||
header('Content-Disposition: attachment; filename="'.$filename.'"');
|
||||
$fp = fopen($file, 'rb');
|
||||
while (is_resource($fp) && !feof($fp))
|
||||
echo fgets($fp, 16384);
|
||||
exit;
|
||||
}
|
||||
}
|
||||
}
|
||||
parent::postProcess();
|
||||
}
|
||||
|
||||
|
||||
@@ -43,6 +43,12 @@ class AdminInvoicesControllerCore extends AdminController
|
||||
'cast' => 'intval',
|
||||
'type' => 'bool'
|
||||
),
|
||||
'PS_INVOICE_TAXES_BREAKDOWN' => array(
|
||||
'title' => $this->l('Enable the breakdown of taxes on the invoice:'),
|
||||
'desc' => $this->l('Show a breakdown of taxes by tax rate on the invoice when there are several taxes combined'),
|
||||
'cast' => 'intval',
|
||||
'type' => 'bool'
|
||||
),
|
||||
'PS_INVOICE_PREFIX' => array(
|
||||
'title' => $this->l('Invoice prefix:'),
|
||||
'desc' => $this->l('Prefix used for invoice name (e.g. IN00001)'),
|
||||
|
||||
@@ -36,7 +36,7 @@ class AdminLogsControllerCore extends AdminController
|
||||
|
||||
$this->fields_list = array(
|
||||
'id_log' => array('title' => $this->l('ID'), 'align' => 'center', 'class' => 'fixed-width-xs'),
|
||||
'employee' => array('title' => $this->l('Employee'), 'align' => 'center'),
|
||||
'employee' => array('title' => $this->l('Employee'), 'align' => 'center', 'havingFilter' => true),
|
||||
'severity' => array('title' => $this->l('Severity (1-4)'), 'align' => 'center', 'class' => 'fixed-width-xs'),
|
||||
'message' => array('title' => $this->l('Message')),
|
||||
'object_type' => array('title' => $this->l('Object type'), 'class' => 'fixed-width-sm'),
|
||||
@@ -81,7 +81,6 @@ class AdminLogsControllerCore extends AdminController
|
||||
);
|
||||
unset($this->toolbar_btn['new']);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
?>
|
||||
|
||||
@@ -652,7 +652,7 @@ class AdminModulesControllerCore extends AdminController
|
||||
$this->errors[] = $this->l('Module not found');
|
||||
elseif ($key == 'install' && $this->tabAccess['add'] !== '1')
|
||||
$this->errors[] = Tools::displayError('You do not have permission to install this module.');
|
||||
elseif ($key == 'uninstall' && ($this->tabAccess['delete'] !== '1' || !$module->getPermission('configure')))
|
||||
elseif ($key == 'delete' && ($this->tabAccess['delete'] !== '1' || !$module->getPermission('configure')))
|
||||
$this->errors[] = Tools::displayError('You do not have permission to delete this module.');
|
||||
elseif ($key == 'configure' && ($this->tabAccess['edit'] !== '1' || !$module->getPermission('configure') || !Module::isInstalled(urldecode($name))))
|
||||
$this->errors[] = Tools::displayError('You do not have permission to configure this module.');
|
||||
|
||||
@@ -430,7 +430,7 @@ class AdminOrdersControllerCore extends AdminController
|
||||
$customer_message = new CustomerMessage();
|
||||
$customer_message->id_customer_thread = $customer_thread->id;
|
||||
$customer_message->id_employee = (int)$this->context->employee->id;
|
||||
$customer_message->message = htmlentities(Tools::getValue('message'), ENT_COMPAT, 'UTF-8');
|
||||
$customer_message->message = Tools::getValue('message');
|
||||
$customer_message->private = Tools::getValue('visibility');
|
||||
|
||||
if (!$customer_message->add())
|
||||
|
||||
@@ -630,7 +630,7 @@ class AdminProductsControllerCore extends AdminController
|
||||
{
|
||||
$id_category = (int)Tools::getValue('id_category');
|
||||
$category_url = empty($id_category) ? '' : '&id_category='.(int)$id_category;
|
||||
Logger::addLog(sprintf($this->l('%s deletion'), $this->className), 1, null, $this->className, (int)$object->id, true, (int)$this->context->employee->id);
|
||||
Logger::addLog(sprintf($this->l('%s deletion', 'AdminTab', false, false), $this->className), 1, null, $this->className, (int)$object->id, true, (int)$this->context->employee->id);
|
||||
$this->redirect_after = self::$currentIndex.'&conf=1&token='.$this->token.$category_url;
|
||||
}
|
||||
else
|
||||
@@ -729,7 +729,7 @@ class AdminProductsControllerCore extends AdminController
|
||||
if (!count($this->errors))
|
||||
{
|
||||
if ($product->delete())
|
||||
Logger::addLog(sprintf($this->l('%s deletion'), $this->className), 1, null, $this->className, (int)$product->id, true, (int)$this->context->employee->id);
|
||||
Logger::addLog(sprintf($this->l('%s deletion', 'AdminTab', false, false), $this->className), 1, null, $this->className, (int)$product->id, true, (int)$this->context->employee->id);
|
||||
else
|
||||
$success = false;
|
||||
}
|
||||
@@ -1714,7 +1714,7 @@ class AdminProductsControllerCore extends AdminController
|
||||
|
||||
if ($this->object->add())
|
||||
{
|
||||
Logger::addLog(sprintf($this->l('%s addition'), $this->className), 1, null, $this->className, (int)$this->object->id, true, (int)$this->context->employee->id);
|
||||
Logger::addLog(sprintf($this->l('%s addition', 'AdminTab', false, false), $this->className), 1, null, $this->className, (int)$this->object->id, true, (int)$this->context->employee->id);
|
||||
$this->addCarriers();
|
||||
$this->updateAccessories($this->object);
|
||||
$this->updatePackItems($this->object);
|
||||
@@ -1836,7 +1836,7 @@ class AdminProductsControllerCore extends AdminController
|
||||
|
||||
if ($object->update())
|
||||
{
|
||||
Logger::addLog(sprintf($this->l('%s edition'), $this->className), 1, null, $this->className, (int)$this->object->id, true, (int)$this->context->employee->id);
|
||||
Logger::addLog(sprintf($this->l('%s edition', 'AdminTab', false, false), $this->className), 1, null, $this->className, (int)$this->object->id, true, (int)$this->context->employee->id);
|
||||
if (in_array($this->context->shop->getContext(), array(Shop::CONTEXT_SHOP, Shop::CONTEXT_ALL)))
|
||||
{
|
||||
if ($this->isTabSubmitted('Shipping'))
|
||||
|
||||
@@ -597,24 +597,28 @@ class AdminTranslationsControllerCore extends AdminController
|
||||
if (preg_match('#^translations\/'.$iso_code.'\/tabs.php#Ui', $file['filename'], $matches) && Validate::isLanguageIsoCode($iso_code))
|
||||
{
|
||||
// Include array width new translations tabs
|
||||
$tabs = array();
|
||||
if (Tools::file_exists_cache(_PS_ROOT_DIR_.DIRECTORY_SEPARATOR.$file['filename']))
|
||||
$tabs = include_once(_PS_ROOT_DIR_.DIRECTORY_SEPARATOR.$file['filename']);
|
||||
|
||||
foreach ($tabs as $class_name => $translations)
|
||||
$_TABS = array();
|
||||
clearstatcache();
|
||||
if (file_exists(_PS_ROOT_DIR_.DIRECTORY_SEPARATOR.$file['filename']))
|
||||
include_once(_PS_ROOT_DIR_.DIRECTORY_SEPARATOR.$file['filename']);
|
||||
|
||||
if (count($_TABS))
|
||||
{
|
||||
// Get instance of this tab by class name
|
||||
$tab = Tab::getInstanceFromClassName($class_name);
|
||||
//Check if class name exists
|
||||
if (isset($tab->class_name) && !empty($tab->class_name))
|
||||
foreach ($_TABS as $class_name => $translations)
|
||||
{
|
||||
$id_lang = Language::getIdByIso($iso_code);
|
||||
$tab->name[(int)$id_lang] = $translations;
|
||||
// Get instance of this tab by class name
|
||||
$tab = Tab::getInstanceFromClassName($class_name);
|
||||
//Check if class name exists
|
||||
if (isset($tab->class_name) && !empty($tab->class_name))
|
||||
{
|
||||
$id_lang = Language::getIdByIso($iso_code);
|
||||
$tab->name[(int)$id_lang] = $translations;
|
||||
|
||||
if (!Validate::isGenericName($tab->name[(int)$id_lang]))
|
||||
$errors[] = sprintf(Tools::displayError('Tab "%s" is not valid'), $tab->name[(int)$id_lang]);
|
||||
else
|
||||
$tab->update();
|
||||
if (!Validate::isGenericName($tab->name[(int)$id_lang]))
|
||||
$errors[] = sprintf(Tools::displayError('Tab "%s" is not valid'), $tab->name[(int)$id_lang]);
|
||||
else
|
||||
$tab->update();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1085,7 +1089,7 @@ class AdminTranslationsControllerCore extends AdminController
|
||||
{
|
||||
case 'front':
|
||||
// Parsing file in Front office
|
||||
$regex = '/\{l\s*s=(?|\'('._PS_TRANS_PATTERN_.')\'|"('._PS_TRANS_PATTERN_.')")(\s*sprintf=.*)?(\s*js=1)?\s*\}/U';
|
||||
$regex = '/\{l\s*s=[\'\"]'._PS_TRANS_PATTERN_.'[\'\"](\s*sprintf=.*)?(\s*js=1)?\s*\}/U';
|
||||
break;
|
||||
|
||||
case 'back':
|
||||
@@ -1095,7 +1099,7 @@ class AdminTranslationsControllerCore extends AdminController
|
||||
else if ($type_file == 'specific')
|
||||
$regex = '/Translate::getAdminTranslation\(\''._PS_TRANS_PATTERN_.'\'\)/U';
|
||||
else
|
||||
$regex = '/\{l\s*s\s*=(?|\''._PS_TRANS_PATTERN_.'\'|"'._PS_TRANS_PATTERN_.'")(\s*sprintf=.*)?(\s*js=1)?(\s*slashes=1)?\s*\}/U';
|
||||
$regex = '/\{l\s*s\s*=[\'\"]'._PS_TRANS_PATTERN_.'[\'\"](\s*sprintf=.*)?(\s*js=1)?(\s*slashes=1)?\s*\}/U';
|
||||
break;
|
||||
|
||||
case 'errors':
|
||||
@@ -1109,7 +1113,10 @@ class AdminTranslationsControllerCore extends AdminController
|
||||
$regex = '/->l\(\''._PS_TRANS_PATTERN_.'\'(, ?\'(.+)\')?(, ?(.+))?\)/U';
|
||||
else
|
||||
// In tpl file look for something that should contain mod='module_name' according to the documentation
|
||||
$regex = '/\{l\s*s=(?|\''._PS_TRANS_PATTERN_.'\'|"'._PS_TRANS_PATTERN_.'").*\s+mod=\''.$module_name.'\'.*\}/U';
|
||||
$regex = array(
|
||||
'/\{l\s*s=\''._PS_TRANS_PATTERN_.'\'.*\s+mod=\''.$module_name.'\'.*\}/U',
|
||||
'/\{l\s*s=\"'._PS_TRANS_PATTERN_.'\".*\s+mod=\''.$module_name.'\'.*\}/U'
|
||||
);
|
||||
break;
|
||||
|
||||
case 'pdf':
|
||||
@@ -1117,11 +1124,21 @@ class AdminTranslationsControllerCore extends AdminController
|
||||
if ($type_file == 'php')
|
||||
$regex = '/HTMLTemplate.*::l\(\''._PS_TRANS_PATTERN_.'\'[\)|\,]/U';
|
||||
else
|
||||
$regex = '/\{l\s*s=(?|\''._PS_TRANS_PATTERN_.'\'|"'._PS_TRANS_PATTERN_.'")(\s*sprintf=.*)?(\s*js=1)?(\s*pdf=\'true\')?\s*\}/U';
|
||||
$regex = '/\{l\s*s=[\'\"]'._PS_TRANS_PATTERN_.'[\'\"](\s*sprintf=.*)?(\s*js=1)?(\s*pdf=\'true\')?\s*\}/U';
|
||||
break;
|
||||
}
|
||||
|
||||
preg_match_all($regex, $content, $matches);
|
||||
if (is_array($regex))
|
||||
{
|
||||
$matches = array(1 => array());
|
||||
foreach ($regex as $regex_row)
|
||||
{
|
||||
preg_match_all($regex_row, $content, $matches2);
|
||||
$matches[1] = array_merge($matches[1], $matches2[1]);
|
||||
}
|
||||
}
|
||||
else
|
||||
preg_match_all($regex, $content, $matches);
|
||||
|
||||
return $matches[1];
|
||||
}
|
||||
@@ -1499,7 +1516,7 @@ class AdminTranslationsControllerCore extends AdminController
|
||||
if ($module_name)
|
||||
$path = str_replace('{module}', $module_name, $path);
|
||||
if (!file_exists($path) && !mkdir($path, 0777, true))
|
||||
throw new PrestaShopException(sprintf(Tools::displayError('Directory "%s" cannot be created'), dirname($file_path)));
|
||||
throw new PrestaShopException(sprintf(Tools::displayError('Directory "%s" cannot be created'), dirname($path)));
|
||||
file_put_contents($path.$mail_name.'.'.$type_content, $content);
|
||||
}
|
||||
else
|
||||
|
||||
@@ -94,8 +94,6 @@ class OrderControllerCore extends ParentOrderController
|
||||
*/
|
||||
public function initContent()
|
||||
{
|
||||
global $isVirtualCart;
|
||||
|
||||
parent::initContent();
|
||||
|
||||
if (Tools::isSubmit('ajax') && Tools::getValue('method') == 'updateExtraCarrier')
|
||||
@@ -117,7 +115,7 @@ class OrderControllerCore extends ParentOrderController
|
||||
}
|
||||
|
||||
if ($this->nbProducts)
|
||||
$this->context->smarty->assign('virtual_cart', $isVirtualCart);
|
||||
$this->context->smarty->assign('virtual_cart', $this->context->cart->isVirtualCart());
|
||||
|
||||
// 4 steps to the order
|
||||
switch ((int)$this->step)
|
||||
@@ -225,12 +223,11 @@ class OrderControllerCore extends ParentOrderController
|
||||
*/
|
||||
public function autoStep()
|
||||
{
|
||||
global $isVirtualCart;
|
||||
|
||||
if ($this->step >= 2 && (!$this->context->cart->id_address_delivery || !$this->context->cart->id_address_invoice))
|
||||
Tools::redirect('index.php?controller=order&step=1');
|
||||
|
||||
if ($this->step > 2 && !$isVirtualCart && count($this->context->cart->getDeliveryOptionList()) == 0)
|
||||
if ($this->step > 2 && !$this->context->cart->isVirtualCart() && count($this->context->cart->getDeliveryOptionList()) == 0)
|
||||
Tools::redirect('index.php?controller=order&step=2');
|
||||
|
||||
$delivery = new Address((int)$this->context->cart->id_address_delivery);
|
||||
|
||||
@@ -26,6 +26,8 @@
|
||||
|
||||
class OrderDetailControllerCore extends FrontController
|
||||
{
|
||||
public $php_self = 'order-detail';
|
||||
|
||||
public $auth = true;
|
||||
public $authRedirection = 'history';
|
||||
public $ssl = true;
|
||||
|
||||
@@ -40,7 +40,7 @@ class OrderOpcControllerCore extends ParentOrderController
|
||||
parent::init();
|
||||
|
||||
if ($this->nbProducts)
|
||||
$this->context->smarty->assign('virtual_cart', false);
|
||||
$this->context->smarty->assign('virtual_cart', $this->context->cart->isVirtualCart());
|
||||
|
||||
$this->context->smarty->assign('is_multi_address_delivery', $this->context->cart->isMultiAddressDelivery() || ((int)Tools::getValue('multi-shipping') == 1));
|
||||
$this->context->smarty->assign('open_multishipping_fancybox', (int)Tools::getValue('multi-shipping') == 1);
|
||||
|
||||
@@ -56,8 +56,6 @@ class ParentOrderControllerCore extends FrontController
|
||||
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
|
||||
|
||||
$this->nbProducts = $this->context->cart->nbProducts();
|
||||
|
||||
global $isVirtualCart;
|
||||
|
||||
if (!$this->context->customer->isLogged(true) && $this->context->getMobileDevice() && Tools::getValue('step'))
|
||||
Tools::redirect($this->context->link->getPageLink('authentication', true, (int)$this->context->language->id, $params));
|
||||
|
||||
@@ -23,6 +23,200 @@ International Registred Trademark & Property of PrestaShop SA
|
||||
|
||||
Release Notes for PrestaShop 1.5
|
||||
--------------------------------
|
||||
####################################
|
||||
# v1.5.6.0 - (2013-10-07) #
|
||||
####################################
|
||||
|
||||
Fixed bugs:
|
||||
|
||||
[-] Installer : added the missing default tab in the employee
|
||||
[-] INSTALLER : Fix bug #PSCFV-8289 bad orders vouchers total after update
|
||||
[-] INSTALLER: Wrong SQL query for PS_LEGACY_IMAGES to 0
|
||||
[-] INSTALLER: short_description for PREFIX_manufacturer_lang is now type TEXT
|
||||
[-] INSTALLER : Fix infinite loop when order message has additional ampersand
|
||||
[-] INSTALLER : Fix fatal error in upgrade, could not load configuration class
|
||||
[-] INSTALLER : no update value in fix_download_product_feature_active
|
||||
[-] INSTALLER : Fix fatal error when upgrading
|
||||
|
||||
[-] FO : isVirtualCart was forced to false
|
||||
[-] FO: Fix display of quantity discounts on product pages if the customer is allowable for multiple discount for the same quantity #PSCFV-10580
|
||||
[-] FO: packages should be splitted with advanced stock management when carrier is not associated to multiple warehouse
|
||||
[-] FO : Fix #PSCFV-10480 again, css fix
|
||||
[-] FO : Fix #PSCFV-10480 again css fix
|
||||
[-] FO : Fix bug #PSCFV-10478 could not see auto added cart rule voucher on product page
|
||||
[-] FO: Fix #PSCFV-10461
|
||||
[-] FO : Fix bug #PSCFV-10328 Set country currency if defined when geolocated
|
||||
[-] FO: Fix Product::getAttributesGroups() minimal_quantity/weight/available_date should be multishop
|
||||
[-] FO : replace ucfirst by ucwords for the customer firstname #PSCFV-10396
|
||||
[-] FO : 301 Redirect /iso_lang to /iso_lang/ url
|
||||
[-] FO : Fix bug #PSCFV-8917 taxes calculation when changing delivery address
|
||||
[-] FO: Fix SSL links on domain_ssl instead domain
|
||||
[-] FO : fixed chinese search with multiple symbols #PSCFV-10322
|
||||
[-] FO : Partial fix of adding gift on cart rule on the same entity in the cart rule
|
||||
[-] FO : Fix bug #PSCFV-10118 quantity not updated when cart rules give the same product as gift
|
||||
[-] FO : fixed bug when is virtual cart on OPC carriers is no longer displayed
|
||||
[-] FO : FixBug when route id is empty
|
||||
|
||||
[-] BO : Bug fix - Modules confirmation messages
|
||||
[-] BO : Retro compat, PS_ADMIN_DIR not defined //bad commit sorry
|
||||
[-] BO : Employee's default_tab may not exists, switching to AdminOrders
|
||||
[-] BO : Retro compat, PS_ADMIN_DIR not defined
|
||||
[-] BO : AdminImport add combinations available fields
|
||||
[-] BO : AdminImport add adresses required fields
|
||||
[-] BO : Fix bug #PSCFV-9323 supplier_reference can be unset
|
||||
[-] BO : Fix bug #PSCFV-10064, could not import feature in multilang, thanks @E.Bigfoot
|
||||
[-] BO : Fix bug #PSCFV-10064, could not import deature in multilang, thanks @E.Bigfoot
|
||||
[-] BO : Remove dead code in AdminImport
|
||||
[-] BO : FixBug #PSCFV-10558 - Invalid HTML markup.
|
||||
[-] BO : Fix bug #PSCFV-8389 duplicates is SpecificPrice table
|
||||
[-] BO : AdminImport, tables are not truncated
|
||||
[-] BO : managed decimal format in BO orders
|
||||
[-] BO : Fix bug #PSCFV-5060 could not import supplier_combinations in combinations import
|
||||
[-] BO : Fix #PSCFV-6482 could not import tags in deiffrent languages
|
||||
[-] BO : fixed currency format on order creation
|
||||
[-] Bo : Fix again #PSCFV-10474 again, not deleting start page after import
|
||||
[-] Bo : Fix again #PSCFV-10474 coul not export more than 300 products
|
||||
[-] BO: Fix total without tax in breakdown taxes when taxes are combined #PSCFV-10394 on the invoices
|
||||
[-] BO: translation mismatch Here is a form to edit the values in the group, we do not need here "attribute type".
|
||||
[-] BO : AdminImport, not matching by ref for updating
|
||||
[-] BO: Fix #PSCFV-10488 filter by employee on logs tab
|
||||
[-] BO : FixBig #PSCFV-10442 - Members Cutomer Group list
|
||||
[-] BO : Could not import empty linkrewrite for products and not matching refs
|
||||
[-] BO : Sort import files in select
|
||||
[-] BO : Remove duplicate sql insert in setProductOutOfStock in monoshop
|
||||
[-] BO : Fix #PSCFV-10501 Remove fatal error
|
||||
[-] BO : Fix bug #PSCFV-9675 could not import non existent parent category
|
||||
[-] BO : Bad entity pre selected in AdminImport
|
||||
[-] BO : Fix bug #PSCFV-10483, could not import other language product link_rewrite
|
||||
[-] BO: Fix data validation when iframe is allowed on some entities like CMS
|
||||
[-] BO : Fix Bug For new Fancy Box events
|
||||
[-] BO : fixed the redirection to a 404 page when loging in in the updater
|
||||
[-] BO : Bad input radio names
|
||||
[-] BO : Issue with domready on adminImport
|
||||
[-] BO : do not reaffect import_type for categories
|
||||
[-] BO: Bad id for multishop checkbox on admin products - weird bug with active flag #PSCFV-9935
|
||||
[-] BO : Fix proces and save buttons for Modules and AdminControllers
|
||||
[-] Bo : Modules 'save' button not active
|
||||
[-] BO : Fix bug #PSCFV-8214 import entity pre selected
|
||||
[-] BO : Fix bugPSCFV-10249 images copy when unix path
|
||||
[-] BO : limited the number of customers displayed in the group view to 100 in order to avoid memory usage error
|
||||
[-] BO : FixBug #PSCFV-9900 Double quote escape problem in delete button link
|
||||
[-] BO : Could not order in AdminStatuses by ID or template
|
||||
[-] BO : Fix bug #PSCFV-8407 can not customize feature column name if needed
|
||||
[-] BO : quote badly decoded in customerThreads
|
||||
[-] BO : Fix Bug #PSCFV-10331 check all from list
|
||||
[-] BO : Customer message twice encoded
|
||||
[-] BO : Fix bug, orders states not ordered by order state name
|
||||
[-] BO : Bug fix - Encoding & tips of the day
|
||||
[-] BO : Do not copy link_rewrite from title if cms already has one
|
||||
[-] BO : Small changes when creating vouchers in back office orders
|
||||
[-] BO: Fix out of stock creation with multishop and stock sharing
|
||||
[-] BO: Fix preview url with multishop
|
||||
[-] BO : Fix possible Uncaught exception 'ReflectionException' when viewing AdminMeta
|
||||
[-] BO : FixBug PSCFV-10331 - Tax rules Pagination
|
||||
[-] BO : Display the old image system migration tool if product images are in _PS_PROD_IMG_DIR_
|
||||
[-] BO : ini_get('safe_mode') can return false
|
||||
[-] BO : AdminModulesController - Bug fix, $params was not set
|
||||
[-] BO : Fix #PSCFV-9906 could not register search engines keywords
|
||||
[-] BO : Fix pull request #665
|
||||
[-] BO : Fix error returned when first import of a localisation pack
|
||||
[-] BO : FixBug #PSCFV-10213 check product/attribute id - Thanks F. Cespedes
|
||||
[-] BO: Fix fatal error on customer edition when email is not valid
|
||||
[-] BO : fixed bug when try to add jquery from ajax.googleapis.com in BO
|
||||
[-] BO : FixBug Url rewrite preview when user have a different language from shop
|
||||
[-] BO : fixed bug with multistore context on carrier wizard
|
||||
|
||||
[-] Classes : Bug fix - FrontController, mobile & JS minifier fixed
|
||||
|
||||
[-] CORE : #PSCFV-10389 Avoid eventual empty Specific Price Rule
|
||||
[-] CORE : Fix bug #PSCFV-10179 Duplicate specific price records when updating a product
|
||||
[-] CORE : Cart rules not ordered by priority for PaymentModule
|
||||
[-] CORE : Partial fix bug #PSCFV-10534 bad total_products_wt calculated without other cart rules
|
||||
[-] CORE : Could not add too long tags
|
||||
[-] CORE : Missing tag max size
|
||||
[-] CORE : Partial fix for #PSCFV-10482 getCacheId is different in back office
|
||||
[-] CORE : Fix bug #PSCFV-10471 Cart item count problem, unique_id grouping error for id_product and id_product_attribute
|
||||
[-] CORE : #PSCFV-10461 customer group in getPriceStatic, pull request https://github.com/kpodemski/kp-PrestaShop/commit/361ebc72e09d00463bb7a7b7af670e3235ab6a5a
|
||||
[-] Core: Set a remote addr with php-cli #PSCFV-10372
|
||||
[-] CORE : Could not add several cart rules
|
||||
[-] CORE : Fix bug #PSCFV-10040 Notice: Undefined index: unifunc && Fatal error: Function name must be a string on some PHP version with empty cache folder and smarty cache enabled
|
||||
[-] CORE: Fix for field length and type regarding https://github.com/PrestaShop/PrestaShop/pull/678
|
||||
[-] CORE : Remove PHP Warning: file_put_contents on modules config.xml
|
||||
[-] CORE : fixed bug #PSCFV-10175 - No virtuel download email send after accepted payment
|
||||
|
||||
[-] MO : Blocklayered - Fix empty fancy box after template edit
|
||||
[-] MO : FixBug #10460 - UTF8 bug on accented URL
|
||||
[-] MO : Blockcart, wrong tbody
|
||||
[-] MO : Fix buig #PSCFV-10480 Blockcart too long cart_block_product_name
|
||||
[-] MO : FixBug #PNM-1683 - Treeview problem
|
||||
[-] MO: Fix time of smarty cache invalidation
|
||||
[-] MO : PNM-1715 - Bug fix accented chars & ajax-cart
|
||||
[-] MO : Editorial could not delete image
|
||||
[-] MO : Fixed a bug when displaying textures Corrections links texture image in the blocklayered
|
||||
[-] MO : carriercompare fixed bug, override template's files in theme. Ticket #PNM-1691
|
||||
[-] MO : Statsdata, exception on duplicate entry
|
||||
[-] MO: Fix unifunc smarty errors if module is displayed on multiplehook without cache
|
||||
[-] MO : fix bug #PSCFV-9906 again, bad url parsing
|
||||
[-] MO: Fix blocklayered sort by quantity #PSCFV-10300
|
||||
|
||||
[-] WS: Fix order by on id field on multishop entities
|
||||
[-] WS: Fix entities retrieve for some cases
|
||||
[-] WS: 404 error should be returned if a multishop entity does not exists #PSCFV-10229
|
||||
[-] WS: Bad xlink for tax_rules_group in product
|
||||
|
||||
[-] PDF : Report of https://github.com/enumag/PrestaShop/commit/9c939cceadebd58ad390fb4f108816e3c17c0275
|
||||
|
||||
[-] LO: Argeninian localization
|
||||
|
||||
Improved/changed features:
|
||||
|
||||
[*] Project : Orders should rely only on ps_order_cart_rule
|
||||
|
||||
[*] Installer : added file check in order to check if everyhting has been successfuly uploaded
|
||||
|
||||
[*] FO: Allow to enable SSL on all the pages
|
||||
[*] FO : removed extra slash and point
|
||||
|
||||
[*] BO : AdminImport, retrieve separators and lang selected
|
||||
[*] BO : Add category id in AdminSpecificPriceRule
|
||||
[*] BO: Allow to breakdown the taxes when they are computed
|
||||
[*] BO : AdminImport, remove csv files
|
||||
[*] BO : Adminimport, check csv download path
|
||||
[*] BO : Add csv file download in AdminImport
|
||||
[*] BO : improved automatic language creation
|
||||
[*] BO : Set import entity in cookie (#PSCFV-8214)
|
||||
[*] BO: sort modules name in Stats
|
||||
|
||||
[*] CORE : Increasing the length of link_rewrite & name in Category.php In database this fields have varchar(128) so let's give the user full size of fields
|
||||
[*] CORE : bad else if in getTemplatePath
|
||||
[*] CORE : Refactoring Tools::copy() as copy with context > PHP 5.3
|
||||
[*] Core: don't re-generate the class_index.php file if a class is not known to avoid misuse of class_exists()
|
||||
|
||||
[*] MO : MailAlerts : Add SQL update script for v2.5
|
||||
[*] MO : MailAlerts : multishop/multilang full compatibility Customers will receive alerts based on the real context of the moment they subscribed to the alert (sho, theme & language) SQL update table : `ps_mailalert_customer_oos` ========================================= ALTER TABLE `ps_mailalert_customer_oos` ADD `id_lang` INT( 10 ) UNSIGNED NOT NULL , DROP PRIMARY KEY , ADD PRIMARY KEY ( `id_customer` , `customer_email` , `id_product` , `id_product_attribute` , `id_shop` ) ;
|
||||
|
||||
[*] LO : Removed 'Miss' from the default genders because too country specific
|
||||
[*] LO : Use single quote as thousands separator for CHF currency
|
||||
|
||||
Added Features:
|
||||
|
||||
[+] FO : add getManufacturer() to ManufacturerControllerCore Add getManufacturer() to ManufacturerControllerCore to access the protected manufacturer instance of the controller.
|
||||
|
||||
[+] BO : add TinyMCE editor for supplier descrpition in AdminManufacturerSupplier
|
||||
[+] BO : add TinyMCE editor for short and long descrpition in AdminManufacturerController
|
||||
[+] BO : Improve mod rewrite check
|
||||
|
||||
[+] MO : add link to all manufacturer page and the feature to show All Suppliers
|
||||
[+] MO : add the option to show all Manufacturer Add the option to show all Manufacturer in blocktopmenu module.
|
||||
[+] MO : Mailalerts - Add Total tax paid to order confirmation
|
||||
|
||||
[+] TR : Added Indonesian installer
|
||||
|
||||
[+] LO : Completed Traditional Chinese Installer
|
||||
[+] LO : Added Bengali installer
|
||||
[+] LO: Added Traditional Chinese installer
|
||||
|
||||
|
||||
####################################
|
||||
# v1.5.5.0 - (2013-08-22) #
|
||||
####################################
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
"id";"Alias*";"Active (0/1)";"Customer e-mail";"Customer ID";"Manufacturer";"Supplier";"Company";"Lastname*";"Firstname*";"Address 1*";"Address 2";"Postcode* / Zipcode*";"City*";"Country*";"State";"Other";"Phone";"Mobile Phone";"VAT number"
|
||||
"id";"Alias*";"Active (0/1)";"Customer e-mail*";"Customer ID";"Manufacturer";"Supplier";"Company";"Lastname*";"Firstname*";"Address 1*";"Address 2";"Postcode* / Zipcode*";"City*";"Country*";"State";"Other";"Phone";"Mobile Phone";"VAT number"
|
||||
1;"My Adress";1;"pub@prestashop.com";1;;;;"Doe";"John";"16, Main street";"2nd floor";75000;"PARIS ";"France";;;140138844;;
|
||||
2;"My work";1;"pub@prestashop.com";1;;;"My Company";"Doe";"John";"535, Baker street";;13000;"Marseile";"France";;;235445588;;
|
||||
3;"My work";0;;;"Apple Computer, Inc";;;"Jobs";"Steve";"1 Infinite Loop";;95014;"CUPERTINO";"United States";"California";;"(800) 275-2273";;
|
||||
|
||||
|
@@ -1,2 +1,4 @@
|
||||
1; Capacity:select:0, Color:color:1; 16Go:0, Bleu:1
|
||||
1; Capacity:select:0, Color:color:1; 16Go:0, Red:1
|
||||
Id_product*;Group*;Attribute*;Supplier_reference;Reference;Ean13;Upc;Wholesale price;Impact on price;Ecotax;Quantity;Minimal quantity;Impact on weight;Default (0 = No, 1 = Yes);Image position;Image URL;Delete existing images (0 = No, 1 = Yes);ID / Name of shop
|
||||
1;Capacity:select:0, Color:color:1;16Go:0, Bleu:1;Ref suppplier 1;Ref 1;1234567891234;123456789123;0;None;0.000000;10;1;None;0;1;http://youdomain.com/img.jpg;0;1
|
||||
1;Capacity:select:0, Color:color:1;16Go:0, Red:1;Ref suppplier 2;Ref 2;1234567891235;123456789124;0;None;0.000000;10;1;None;0;2;http://youdomain.com/img.jpg;0;1
|
||||
|
||||
|
||||
|
@@ -1,3 +1,3 @@
|
||||
id;Active (0/1);Name*;Categories (x,y,z,...);Price tax excl. Or Price tax excl;Tax rules id;Wholesale price;On sale (0/1);Discount amount;Discount percent;Discount from (yyy-mm-dd);Discount to (yyy-mm-dd);Reference #;Supplier reference #;Supplier;Manufacturer;EAN13;UPC;Ecotax;Weight;Quantity;Short description;Description;Tags (x,y,z,...);Meta-title;Meta-keywords;Meta-description;URL rewritten;Text when in-stock;Text if back-order allowed;Available for order (0 = No, 1 = Yes);Product creation date;Show price (0 = No, 1 = Yes);Image URLs (x,y,z,...);Delete existing images (0 = No, 1 = Yes);Feature (Name:Value:Position);Available online only (0 = No, 1 = Yes);Condition (new,used,refurbished);ID / Name of shop
|
||||
1;1;iPod Nano;Home, iPods;49;1;;1;;;;;92458844;54778855;AppleStore;Apple Computer, Inc;;;;0.5;800;New design. New features. Now i….;Curved ahead of the curve. For those about to rock, we give you nine amazing colors. But that's only part of the story. Feel the curved, all-aluminum and glass de...;apple, ipod, nano;;;;ipod-nano;In stock;Out stock;1;;1;http://youdomain.com/img.jpg, http://yourdomain.com/img1.jpg;1;;0;new;1
|
||||
2;1;iPod shuffle;Home, iPods;66.05;1;79;1;;;;;92458845;54778855;AppleStore;Apple Computer, Inc;;;;0;500;iPod shuffle, the world’s most wearabl….;;ipod, shuffle;;;;ipod-shuffle;In stock;Out stock;1;;1;http://youdomain.com/img25.jpg, http://yourdomain.com/img30.jpg;1;;0;new;1
|
||||
ID;Active (0/1);Name*;Categories (x,y,z,…);Price tax excl. Or Price tax excl;Tax rules id;Wholesale price;On sale (0/1);Discount amount;Discount percent;Discount from (yyy-mm-dd);Discount to (yyy-mm-dd);Reference #;Supplier reference #;Supplier;Manufacturer;EAN13;UPC;Ecotax;Width;Height;Depth;Weight;Quantity;Minimum quantity;Visibility;Additional shipping cost;Unity;Unity price ratio;Short description;Description;Tags (x,y,z,...);Meta-title;Meta-keywords;Meta-description;URL rewritten;Text when in-stock;Text if back-order allowed;Available for order (0 = No, 1 = Yes);Product available date;Product creation date;Show price (0 = No, 1 = Yes);Image URLs (x,y,z,...);Delete existing images (0 = No, 1 = Yes);Feature (Name:Value:Position);Available online only (0 = No, 1 = Yes);Condition (new,used,refurbished);Customizable;File fields;Text fields;Out of stock;Advanced stock management;ID / Name of shop
|
||||
1;1;iPod Nano;Home, iPods;49;1;40;0;;;;;92458844;54778855;AppleStore;Apple Computer, Inc;5605055055056;560505505555;0;0,1;0,2;0,3;0.5;800;1;both;0.00;;0.00;New design. New features. Now i….;Curved ahead of the curve. For those about to rock, we give you nine amazing colors. But that's only part of the story. Feel the curved, all-aluminum and glass de...;apple, ipod, nano;Meta title;Meta keywords;Meta description;ipod-nano;In stock;Out stock;1;;;1;http://youdomain.com/img.jpg, http://yourdomain.com/img1.jpg;0;Music:Rock:1;0;new;0;0;0;2;0;1
|
||||
2;1;iPod shuffle;Home, iPods;66.05;1;50;0;;;;;92458845;54778855;AppleStore;Apple Computer, Inc;5605055055057;560505505556;0;0,1;0,2;0,3;0.5;800;1;both;0.00;;0.00;iPod shuffle, the world’s most wearabl….;You want listen to music;ipod, shuffle;Meta title;Meta keywords;Meta description;ipod-shuffle;In stock;Out stock;1;;;1;http://youdomain.com/img25.jpg, http://yourdomain.com/img30.jpg;0;Music:Blues:2;0;new;0;0;0;2;0;1
|
||||
|
||||
|
+2
-2
@@ -21,8 +21,8 @@ needs please refer to http://www.prestashop.com for more information.
|
||||
@license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
||||
International Registered Trademark & Property of PrestaShop SA
|
||||
|
||||
NAME: Prestashop 1.5.5.0
|
||||
VERSION: 1.5.5.0
|
||||
NAME: Prestashop 1.5.6.0
|
||||
VERSION: 1.5.6.0
|
||||
|
||||
VORBEREITUNG
|
||||
===========
|
||||
|
||||
+2
-2
@@ -21,8 +21,8 @@ needs please refer to http://www.prestashop.com for more information.
|
||||
@license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
||||
International Registered Trademark & Property of PrestaShop SA
|
||||
|
||||
NAME: Prestashop 1.5.5.0
|
||||
VERSION: 1.5.5.0
|
||||
NAME: Prestashop 1.5.6.0
|
||||
VERSION: 1.5.6.0
|
||||
|
||||
PREPARATION
|
||||
===========
|
||||
|
||||
+2
-2
@@ -21,8 +21,8 @@ needs please refer to http://www.prestashop.com for more information.
|
||||
@license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
||||
International Registered Trademark & Property of PrestaShop SA
|
||||
|
||||
NAME: Prestashop 1.5.5.0
|
||||
VERSION: 1.5.5.0
|
||||
NAME: Prestashop 1.5.6.0
|
||||
VERSION: 1.5.6.0
|
||||
|
||||
PREPARACI�N
|
||||
===========
|
||||
|
||||
+2
-2
@@ -21,8 +21,8 @@ needs please refer to http://www.prestashop.com for more information.
|
||||
@license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
||||
International Registered Trademark & Property of PrestaShop SA
|
||||
|
||||
NAME: Prestashop 1.5.5.0
|
||||
VERSION: 1.5.5.0
|
||||
NAME: Prestashop 1.5.6.0
|
||||
VERSION: 1.5.6.0
|
||||
|
||||
PREPARATION
|
||||
===========
|
||||
|
||||
+2
-2
@@ -21,8 +21,8 @@ needs please refer to http://www.prestashop.com for more information.
|
||||
@license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
||||
International Registered Trademark & Property of PrestaShop SA
|
||||
|
||||
NAME: Prestashop 1.5.5.0
|
||||
VERSION: 1.5.5.0
|
||||
NAME: Prestashop 1.5.6.0
|
||||
VERSION: 1.5.6.0
|
||||
|
||||
PREPARAZIONE
|
||||
===========
|
||||
|
||||
@@ -689,7 +689,7 @@ Country</value>
|
||||
<value>7700</value>
|
||||
</configuration>
|
||||
<configuration id="PS_VERSION_DB" name="PS_VERSION_DB">
|
||||
<value>1.5.5.0</value>
|
||||
<value>1.5.6.0</value>
|
||||
</configuration>
|
||||
<configuration id="PS_BASE_DISTANCE_UNIT" name="PS_BASE_DISTANCE_UNIT">
|
||||
<value>m</value>
|
||||
@@ -701,7 +701,7 @@ Country</value>
|
||||
<value>localhost</value>
|
||||
</configuration>
|
||||
<configuration id="PS_INSTALL_VERSION" name="PS_INSTALL_VERSION">
|
||||
<value>1.5.5.0</value>
|
||||
<value>1.5.6.0</value>
|
||||
</configuration>
|
||||
<configuration id="PS_SHOP_NAME" name="PS_SHOP_NAME">
|
||||
<value>PrestaShop</value>
|
||||
|
||||
@@ -6,6 +6,5 @@
|
||||
<entities>
|
||||
<gender id="1" type="0"/>
|
||||
<gender id="2" type="1"/>
|
||||
<gender id="3" type="1"/>
|
||||
</entities>
|
||||
</entity_gender>
|
||||
|
||||
@@ -13,6 +13,9 @@
|
||||
<hook id="actionValidateOrder" live_edit="0">
|
||||
<name>actionValidateOrder</name><title>New orders</title><description/>
|
||||
</hook>
|
||||
<hook id="displayMaintenance" live_edit="0">
|
||||
<name>displayMaintenance</name><title>Maintenance Page</title><description>This hook displays new elements on the maintenance page</description>
|
||||
</hook>
|
||||
<hook id="actionPaymentConfirmation" live_edit="0">
|
||||
<name>actionPaymentConfirmation</name><title>Payment confirmation</title><description>This hook displays new elements after the payment is validated</description>
|
||||
</hook>
|
||||
|
||||
@@ -804,145 +804,145 @@
|
||||
<state id="YO" id_country="ID" id_zone="Asia" iso_code="YO" tax_behavior="0" active="1">
|
||||
<name>Yogyakarta</name>
|
||||
</state>
|
||||
<state id="23" id_country="JP" id_zone="Asia" iso_code="23" tax_behavior="0" active="1">
|
||||
<state id="JP-23" id_country="JP" id_zone="Asia" iso_code="23" tax_behavior="0" active="1">
|
||||
<name>Aichi</name>
|
||||
</state>
|
||||
<state id="05" id_country="JP" id_zone="Asia" iso_code="05" tax_behavior="0" active="1">
|
||||
<state id="JP-05" id_country="JP" id_zone="Asia" iso_code="05" tax_behavior="0" active="1">
|
||||
<name>Akita</name>
|
||||
</state>
|
||||
<state id="02" id_country="JP" id_zone="Asia" iso_code="02" tax_behavior="0" active="1">
|
||||
<state id="JP-02" id_country="JP" id_zone="Asia" iso_code="02" tax_behavior="0" active="1">
|
||||
<name>Aomori</name>
|
||||
</state>
|
||||
<state id="12" id_country="JP" id_zone="Asia" iso_code="12" tax_behavior="0" active="1">
|
||||
<state id="JP-12" id_country="JP" id_zone="Asia" iso_code="12" tax_behavior="0" active="1">
|
||||
<name>Chiba</name>
|
||||
</state>
|
||||
<state id="38" id_country="JP" id_zone="Asia" iso_code="38" tax_behavior="0" active="1">
|
||||
<state id="JP-38" id_country="JP" id_zone="Asia" iso_code="38" tax_behavior="0" active="1">
|
||||
<name>Ehime</name>
|
||||
</state>
|
||||
<state id="18" id_country="JP" id_zone="Asia" iso_code="18" tax_behavior="0" active="1">
|
||||
<state id="JP-18" id_country="JP" id_zone="Asia" iso_code="18" tax_behavior="0" active="1">
|
||||
<name>Fukui</name>
|
||||
</state>
|
||||
<state id="40" id_country="JP" id_zone="Asia" iso_code="40" tax_behavior="0" active="1">
|
||||
<state id="JP-40" id_country="JP" id_zone="Asia" iso_code="40" tax_behavior="0" active="1">
|
||||
<name>Fukuoka</name>
|
||||
</state>
|
||||
<state id="07" id_country="JP" id_zone="Asia" iso_code="07" tax_behavior="0" active="1">
|
||||
<state id="JP-07" id_country="JP" id_zone="Asia" iso_code="07" tax_behavior="0" active="1">
|
||||
<name>Fukushima</name>
|
||||
</state>
|
||||
<state id="21" id_country="JP" id_zone="Asia" iso_code="21" tax_behavior="0" active="1">
|
||||
<state id="JP-21" id_country="JP" id_zone="Asia" iso_code="21" tax_behavior="0" active="1">
|
||||
<name>Gifu</name>
|
||||
</state>
|
||||
<state id="10" id_country="JP" id_zone="Asia" iso_code="10" tax_behavior="0" active="1">
|
||||
<state id="JP-10" id_country="JP" id_zone="Asia" iso_code="10" tax_behavior="0" active="1">
|
||||
<name>Gunma</name>
|
||||
</state>
|
||||
<state id="34" id_country="JP" id_zone="Asia" iso_code="34" tax_behavior="0" active="1">
|
||||
<state id="JP-34" id_country="JP" id_zone="Asia" iso_code="34" tax_behavior="0" active="1">
|
||||
<name>Hiroshima</name>
|
||||
</state>
|
||||
<state id="01" id_country="JP" id_zone="Asia" iso_code="01" tax_behavior="0" active="1">
|
||||
<state id="JP-01" id_country="JP" id_zone="Asia" iso_code="01" tax_behavior="0" active="1">
|
||||
<name>Hokkaido</name>
|
||||
</state>
|
||||
<state id="28" id_country="JP" id_zone="Asia" iso_code="28" tax_behavior="0" active="1">
|
||||
<state id="JP-28" id_country="JP" id_zone="Asia" iso_code="28" tax_behavior="0" active="1">
|
||||
<name>Hyogo</name>
|
||||
</state>
|
||||
<state id="08" id_country="JP" id_zone="Asia" iso_code="08" tax_behavior="0" active="1">
|
||||
<state id="JP-08" id_country="JP" id_zone="Asia" iso_code="08" tax_behavior="0" active="1">
|
||||
<name>Ibaraki</name>
|
||||
</state>
|
||||
<state id="17" id_country="JP" id_zone="Asia" iso_code="17" tax_behavior="0" active="1">
|
||||
<state id="JP-17" id_country="JP" id_zone="Asia" iso_code="17" tax_behavior="0" active="1">
|
||||
<name>Ishikawa</name>
|
||||
</state>
|
||||
<state id="03" id_country="JP" id_zone="Asia" iso_code="03" tax_behavior="0" active="1">
|
||||
<state id="JP-03" id_country="JP" id_zone="Asia" iso_code="03" tax_behavior="0" active="1">
|
||||
<name>Iwate</name>
|
||||
</state>
|
||||
<state id="37" id_country="JP" id_zone="Asia" iso_code="37" tax_behavior="0" active="1">
|
||||
<state id="JP-37" id_country="JP" id_zone="Asia" iso_code="37" tax_behavior="0" active="1">
|
||||
<name>Kagawa</name>
|
||||
</state>
|
||||
<state id="46" id_country="JP" id_zone="Asia" iso_code="46" tax_behavior="0" active="1">
|
||||
<state id="JP-46" id_country="JP" id_zone="Asia" iso_code="46" tax_behavior="0" active="1">
|
||||
<name>Kagoshima</name>
|
||||
</state>
|
||||
<state id="14" id_country="JP" id_zone="Asia" iso_code="14" tax_behavior="0" active="1">
|
||||
<state id="JP-14" id_country="JP" id_zone="Asia" iso_code="14" tax_behavior="0" active="1">
|
||||
<name>Kanagawa</name>
|
||||
</state>
|
||||
<state id="39" id_country="JP" id_zone="Asia" iso_code="39" tax_behavior="0" active="1">
|
||||
<state id="JP-39" id_country="JP" id_zone="Asia" iso_code="39" tax_behavior="0" active="1">
|
||||
<name>Kochi</name>
|
||||
</state>
|
||||
<state id="43" id_country="JP" id_zone="Asia" iso_code="43" tax_behavior="0" active="1">
|
||||
<state id="JP-43" id_country="JP" id_zone="Asia" iso_code="43" tax_behavior="0" active="1">
|
||||
<name>Kumamoto</name>
|
||||
</state>
|
||||
<state id="26" id_country="JP" id_zone="Asia" iso_code="26" tax_behavior="0" active="1">
|
||||
<state id="JP-26" id_country="JP" id_zone="Asia" iso_code="26" tax_behavior="0" active="1">
|
||||
<name>Kyoto</name>
|
||||
</state>
|
||||
<state id="24" id_country="JP" id_zone="Asia" iso_code="24" tax_behavior="0" active="1">
|
||||
<state id="JP-24" id_country="JP" id_zone="Asia" iso_code="24" tax_behavior="0" active="1">
|
||||
<name>Mie</name>
|
||||
</state>
|
||||
<state id="04" id_country="JP" id_zone="Asia" iso_code="04" tax_behavior="0" active="1">
|
||||
<state id="JP-04" id_country="JP" id_zone="Asia" iso_code="04" tax_behavior="0" active="1">
|
||||
<name>Miyagi</name>
|
||||
</state>
|
||||
<state id="45" id_country="JP" id_zone="Asia" iso_code="45" tax_behavior="0" active="1">
|
||||
<state id="JP-45" id_country="JP" id_zone="Asia" iso_code="45" tax_behavior="0" active="1">
|
||||
<name>Miyazaki</name>
|
||||
</state>
|
||||
<state id="20" id_country="JP" id_zone="Asia" iso_code="20" tax_behavior="0" active="1">
|
||||
<state id="JP-20" id_country="JP" id_zone="Asia" iso_code="20" tax_behavior="0" active="1">
|
||||
<name>Nagano</name>
|
||||
</state>
|
||||
<state id="42" id_country="JP" id_zone="Asia" iso_code="42" tax_behavior="0" active="1">
|
||||
<state id="JP-42" id_country="JP" id_zone="Asia" iso_code="42" tax_behavior="0" active="1">
|
||||
<name>Nagasaki</name>
|
||||
</state>
|
||||
<state id="29" id_country="JP" id_zone="Asia" iso_code="29" tax_behavior="0" active="1">
|
||||
<state id="JP-29" id_country="JP" id_zone="Asia" iso_code="29" tax_behavior="0" active="1">
|
||||
<name>Nara</name>
|
||||
</state>
|
||||
<state id="15" id_country="JP" id_zone="Asia" iso_code="15" tax_behavior="0" active="1">
|
||||
<state id="JP-15" id_country="JP" id_zone="Asia" iso_code="15" tax_behavior="0" active="1">
|
||||
<name>Niigata</name>
|
||||
</state>
|
||||
<state id="44" id_country="JP" id_zone="Asia" iso_code="44" tax_behavior="0" active="1">
|
||||
<state id="JP-44" id_country="JP" id_zone="Asia" iso_code="44" tax_behavior="0" active="1">
|
||||
<name>Oita</name>
|
||||
</state>
|
||||
<state id="33" id_country="JP" id_zone="Asia" iso_code="33" tax_behavior="0" active="1">
|
||||
<state id="JP-33" id_country="JP" id_zone="Asia" iso_code="33" tax_behavior="0" active="1">
|
||||
<name>Okayama</name>
|
||||
</state>
|
||||
<state id="47" id_country="JP" id_zone="Asia" iso_code="47" tax_behavior="0" active="1">
|
||||
<state id="JP-47" id_country="JP" id_zone="Asia" iso_code="47" tax_behavior="0" active="1">
|
||||
<name>Okinawa</name>
|
||||
</state>
|
||||
<state id="27" id_country="JP" id_zone="Asia" iso_code="27" tax_behavior="0" active="1">
|
||||
<state id="JP-27" id_country="JP" id_zone="Asia" iso_code="27" tax_behavior="0" active="1">
|
||||
<name>Osaka</name>
|
||||
</state>
|
||||
<state id="41" id_country="JP" id_zone="Asia" iso_code="41" tax_behavior="0" active="1">
|
||||
<state id="JP-41" id_country="JP" id_zone="Asia" iso_code="41" tax_behavior="0" active="1">
|
||||
<name>Saga</name>
|
||||
</state>
|
||||
<state id="11" id_country="JP" id_zone="Asia" iso_code="11" tax_behavior="0" active="1">
|
||||
<state id="JP-11" id_country="JP" id_zone="Asia" iso_code="11" tax_behavior="0" active="1">
|
||||
<name>Saitama</name>
|
||||
</state>
|
||||
<state id="25" id_country="JP" id_zone="Asia" iso_code="25" tax_behavior="0" active="1">
|
||||
<state id="JP-25" id_country="JP" id_zone="Asia" iso_code="25" tax_behavior="0" active="1">
|
||||
<name>Shiga</name>
|
||||
</state>
|
||||
<state id="32" id_country="JP" id_zone="Asia" iso_code="32" tax_behavior="0" active="1">
|
||||
<state id="JP-32" id_country="JP" id_zone="Asia" iso_code="32" tax_behavior="0" active="1">
|
||||
<name>Shimane</name>
|
||||
</state>
|
||||
<state id="22" id_country="JP" id_zone="Asia" iso_code="22" tax_behavior="0" active="1">
|
||||
<state id="JP-22" id_country="JP" id_zone="Asia" iso_code="22" tax_behavior="0" active="1">
|
||||
<name>Shizuoka</name>
|
||||
</state>
|
||||
<state id="09" id_country="JP" id_zone="Asia" iso_code="09" tax_behavior="0" active="1">
|
||||
<state id="JP-09" id_country="JP" id_zone="Asia" iso_code="09" tax_behavior="0" active="1">
|
||||
<name>Tochigi</name>
|
||||
</state>
|
||||
<state id="36" id_country="JP" id_zone="Asia" iso_code="36" tax_behavior="0" active="1">
|
||||
<state id="JP-36" id_country="JP" id_zone="Asia" iso_code="36" tax_behavior="0" active="1">
|
||||
<name>Tokushima</name>
|
||||
</state>
|
||||
<state id="13" id_country="JP" id_zone="Asia" iso_code="13" tax_behavior="0" active="1">
|
||||
<state id="JP-13" id_country="JP" id_zone="Asia" iso_code="13" tax_behavior="0" active="1">
|
||||
<name>Tokyo</name>
|
||||
</state>
|
||||
<state id="31" id_country="JP" id_zone="Asia" iso_code="31" tax_behavior="0" active="1">
|
||||
<state id="JP-31" id_country="JP" id_zone="Asia" iso_code="31" tax_behavior="0" active="1">
|
||||
<name>Tottori</name>
|
||||
</state>
|
||||
<state id="16" id_country="JP" id_zone="Asia" iso_code="16" tax_behavior="0" active="1">
|
||||
<state id="JP-16" id_country="JP" id_zone="Asia" iso_code="16" tax_behavior="0" active="1">
|
||||
<name>Toyama</name>
|
||||
</state>
|
||||
<state id="30" id_country="JP" id_zone="Asia" iso_code="30" tax_behavior="0" active="1">
|
||||
<state id="JP-30" id_country="JP" id_zone="Asia" iso_code="30" tax_behavior="0" active="1">
|
||||
<name>Wakayama</name>
|
||||
</state>
|
||||
<state id="06" id_country="JP" id_zone="Asia" iso_code="06" tax_behavior="0" active="1">
|
||||
<state id="JP-06" id_country="JP" id_zone="Asia" iso_code="06" tax_behavior="0" active="1">
|
||||
<name>Yamagata</name>
|
||||
</state>
|
||||
<state id="35" id_country="JP" id_zone="Asia" iso_code="35" tax_behavior="0" active="1">
|
||||
<state id="JP-35" id_country="JP" id_zone="Asia" iso_code="35" tax_behavior="0" active="1">
|
||||
<name>Yamaguchi</name>
|
||||
</state>
|
||||
<state id="19" id_country="JP" id_zone="Asia" iso_code="19" tax_behavior="0" active="1">
|
||||
<state id="JP-19" id_country="JP" id_zone="Asia" iso_code="19" tax_behavior="0" active="1">
|
||||
<name>Yamanashi</name>
|
||||
</state>
|
||||
</entities>
|
||||
|
||||
@@ -170,7 +170,7 @@
|
||||
<access id="access_3_58" id_profile="Logistician" id_tab="Tax_Rules" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_3_59" id_profile="Logistician" id_tab="Taxes" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_3_60" id_profile="Logistician" id_tab="Translations" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_3_61" id_profile="Logistician" id_tab="Modules_1" view="1" add="1" edit="1" delete="1"/>
|
||||
<access id="access_3_61" id_profile="Logistician" id_tab="Modules_1" view="1" add="0" edit="1" delete="0"/>
|
||||
<access id="access_3_62" id_profile="Logistician" id_tab="Modules_Themes_Catalog" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_3_63" id_profile="Logistician" id_tab="Positions" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_3_64" id_profile="Logistician" id_tab="Payment" view="0" add="0" edit="0" delete="0"/>
|
||||
@@ -372,7 +372,7 @@
|
||||
<access id="access_5_58" id_profile="Salesman" id_tab="Tax_Rules" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_5_59" id_profile="Salesman" id_tab="Taxes" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_5_60" id_profile="Salesman" id_tab="Translations" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_5_61" id_profile="Salesman" id_tab="Modules_1" view="1" add="1" edit="1" delete="1"/>
|
||||
<access id="access_5_61" id_profile="Salesman" id_tab="Modules_1" view="1" add="0" edit="1" delete="0"/>
|
||||
<access id="access_5_62" id_profile="Salesman" id_tab="Modules_Themes_Catalog" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_5_63" id_profile="Salesman" id_tab="Positions" view="0" add="0" edit="0" delete="0"/>
|
||||
<access id="access_5_64" id_profile="Salesman" id_tab="Payment" view="0" add="0" edit="0" delete="0"/>
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_attribute>
|
||||
<attribute id="2GB">
|
||||
<name>2GB</name>
|
||||
</attribute>
|
||||
<attribute id="4GB">
|
||||
<name>4GB</name>
|
||||
</attribute>
|
||||
<attribute id="Metal">
|
||||
<name>Metal</name>
|
||||
</attribute>
|
||||
<attribute id="Blue">
|
||||
<name>Blue</name>
|
||||
</attribute>
|
||||
<attribute id="Pink">
|
||||
<name>Pink</name>
|
||||
</attribute>
|
||||
<attribute id="Green">
|
||||
<name>Green</name>
|
||||
</attribute>
|
||||
<attribute id="Orange">
|
||||
<name>Orange</name>
|
||||
</attribute>
|
||||
<attribute id="Optional_64GB_solid-state_drive">
|
||||
<name>Optional 64GB solid-state drive</name>
|
||||
</attribute>
|
||||
<attribute id="80GB_Parallel_ATA_Drive_4200_rpm">
|
||||
<name>80GB Parallel ATA Drive @ 4200 rpm</name>
|
||||
</attribute>
|
||||
<attribute id="1_60GHz_Intel_Core_2_Duo">
|
||||
<name>1.60GHz Intel Core 2 Duo</name>
|
||||
</attribute>
|
||||
<attribute id="1_80GHz_Intel_Core_2_Duo">
|
||||
<name>1.80GHz Intel Core 2 Duo</name>
|
||||
</attribute>
|
||||
<attribute id="80GB_20_000_Songs">
|
||||
<name>80GB: 20,000 Songs</name>
|
||||
</attribute>
|
||||
<attribute id="160GB_40_000_Songs">
|
||||
<name>160GB: 40,000 Songs</name>
|
||||
</attribute>
|
||||
<attribute id="Black">
|
||||
<name>Black</name>
|
||||
</attribute>
|
||||
<attribute id="8GB">
|
||||
<name>8GB</name>
|
||||
</attribute>
|
||||
<attribute id="16GB">
|
||||
<name>16GB</name>
|
||||
</attribute>
|
||||
<attribute id="32GB">
|
||||
<name>32GB</name>
|
||||
</attribute>
|
||||
<attribute id="Purple">
|
||||
<name>Purple</name>
|
||||
</attribute>
|
||||
<attribute id="Yellow">
|
||||
<name>Yellow</name>
|
||||
</attribute>
|
||||
<attribute id="Red">
|
||||
<name>Red</name>
|
||||
</attribute>
|
||||
</entity_attribute>
|
||||
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_attribute_group>
|
||||
<attribute_group id="Disk_space">
|
||||
<name>Disk space</name>
|
||||
<public_name>Disk space</public_name>
|
||||
</attribute_group>
|
||||
<attribute_group id="Color">
|
||||
<name>Color</name>
|
||||
<public_name>Color</public_name>
|
||||
</attribute_group>
|
||||
<attribute_group id="ICU">
|
||||
<name>ICU</name>
|
||||
<public_name>Processor</public_name>
|
||||
</attribute_group>
|
||||
</entity_attribute_group>
|
||||
@@ -0,0 +1,21 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<list_attributegroup>
|
||||
<attributegroup id="capacity">
|
||||
<name><![CDATA[Disk space]]></name>
|
||||
</attributegroup>
|
||||
<attributegroup id="capacity_public">
|
||||
<name><![CDATA[Disk space]]></name>
|
||||
</attributegroup>
|
||||
<attributegroup id="color">
|
||||
<name><![CDATA[Color]]></name>
|
||||
</attributegroup>
|
||||
<attributegroup id="color_public">
|
||||
<name><![CDATA[Color]]></name>
|
||||
</attributegroup>
|
||||
<attributegroup id="processor">
|
||||
<name><![CDATA[ICU]]></name>
|
||||
</attributegroup>
|
||||
<attributegroup id="processor_public">
|
||||
<name><![CDATA[Processor]]></name>
|
||||
</attributegroup>
|
||||
</list_attributegroup>
|
||||
@@ -0,0 +1,6 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_carrier>
|
||||
<carrier id="My_carrier" id_shop="1">
|
||||
<delay>Delivery next day!</delay>
|
||||
</carrier>
|
||||
</entity_carrier>
|
||||
@@ -0,0 +1,27 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_category>
|
||||
<category id="iPods" id_shop="1">
|
||||
<name>iPods</name>
|
||||
<description>Now that you can buy movies from the iTunes Store and sync them to your iPod, the whole world is your theater.</description>
|
||||
<link_rewrite>music-ipods</link_rewrite>
|
||||
<meta_title/>
|
||||
<meta_keywords/>
|
||||
<meta_description/>
|
||||
</category>
|
||||
<category id="Accessories" id_shop="1">
|
||||
<name>Accessories</name>
|
||||
<description>Wonderful accessories for your iPod</description>
|
||||
<link_rewrite>accessories-ipod</link_rewrite>
|
||||
<meta_title/>
|
||||
<meta_keywords/>
|
||||
<meta_description/>
|
||||
</category>
|
||||
<category id="Laptops" id_shop="1">
|
||||
<name>Laptops</name>
|
||||
<description>The latest Intel processor, a bigger hard drive, plenty of memory, and even more new features all fit inside just one liberating inch. The new Mac laptops have the performance, power, and connectivity of a desktop computer. Without the desk part.</description>
|
||||
<link_rewrite>laptops</link_rewrite>
|
||||
<meta_title>Apple laptops</meta_title>
|
||||
<meta_keywords>Apple laptops MacBook Air</meta_keywords>
|
||||
<meta_description>Powerful and chic Apple laptops</meta_description>
|
||||
</category>
|
||||
</entity_category>
|
||||
@@ -0,0 +1,18 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_feature>
|
||||
<feature id="Height">
|
||||
<name>Height</name>
|
||||
</feature>
|
||||
<feature id="Width">
|
||||
<name>Width</name>
|
||||
</feature>
|
||||
<feature id="Depth">
|
||||
<name>Depth</name>
|
||||
</feature>
|
||||
<feature id="Weight">
|
||||
<name>Weight</name>
|
||||
</feature>
|
||||
<feature id="Headphone">
|
||||
<name>Headphone</name>
|
||||
</feature>
|
||||
</entity_feature>
|
||||
@@ -0,0 +1,45 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_feature_value>
|
||||
<feature_value id="Jack_stereo">
|
||||
<value>Jack stereo</value>
|
||||
</feature_value>
|
||||
<feature_value id="Mini-jack_stereo">
|
||||
<value>Mini-jack stereo</value>
|
||||
</feature_value>
|
||||
<feature_value id="2_75_in">
|
||||
<value>2.75 in</value>
|
||||
</feature_value>
|
||||
<feature_value id="2_06_in">
|
||||
<value>2.06 in</value>
|
||||
</feature_value>
|
||||
<feature_value id="49_2_g">
|
||||
<value>49.2 g</value>
|
||||
</feature_value>
|
||||
<feature_value id="0_26_in">
|
||||
<value>0.26 in</value>
|
||||
</feature_value>
|
||||
<feature_value id="1_07_in">
|
||||
<value>1.07 in</value>
|
||||
</feature_value>
|
||||
<feature_value id="1_62_in">
|
||||
<value>1.62 in</value>
|
||||
</feature_value>
|
||||
<feature_value id="15_5_g">
|
||||
<value>15.5 g</value>
|
||||
</feature_value>
|
||||
<feature_value id="0_41_in_clip_included">
|
||||
<value>0.41 in (clip included)</value>
|
||||
</feature_value>
|
||||
<feature_value id="4_33_in">
|
||||
<value>4.33 in</value>
|
||||
</feature_value>
|
||||
<feature_value id="2_76_in">
|
||||
<value>2.76 in</value>
|
||||
</feature_value>
|
||||
<feature_value id="120g">
|
||||
<value>120g</value>
|
||||
</feature_value>
|
||||
<feature_value id="0_31_in">
|
||||
<value>0.31 in</value>
|
||||
</feature_value>
|
||||
</entity_feature_value>
|
||||
@@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<list_featurevalue>
|
||||
<featurevalue id="jack_stereo">
|
||||
<value><![CDATA[Jack stereo]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="mini_jack_stereo">
|
||||
<value><![CDATA[Mini-jack stereo]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="2.75in">
|
||||
<value><![CDATA[2.75 in]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="2.06in">
|
||||
<value><![CDATA[2.06 in]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="49.2g">
|
||||
<value><![CDATA[49.2 g]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="0.26in">
|
||||
<value><![CDATA[0.26 in]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="1.07in">
|
||||
<value><![CDATA[1.07 in]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="1.62in">
|
||||
<value><![CDATA[1.62 in]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="15.5g">
|
||||
<value><![CDATA[15.5 g]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="0.41in">
|
||||
<value><![CDATA[0.41 in (clip included)]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="4.33in">
|
||||
<value><![CDATA[4.33 in]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="2.76in">
|
||||
<value><![CDATA[2.76 in]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="120g">
|
||||
<value><![CDATA[120g]]></value>
|
||||
</featurevalue>
|
||||
<featurevalue id="0.31in">
|
||||
<value><![CDATA[0.31 in]]></value>
|
||||
</featurevalue>
|
||||
</list_featurevalue>
|
||||
@@ -0,0 +1,81 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_image>
|
||||
<image id="MacBook_Air">
|
||||
<legend>MacBook Air</legend>
|
||||
</image>
|
||||
<image id="MacBook_Air_1">
|
||||
<legend>MacBook Air</legend>
|
||||
</image>
|
||||
<image id="MacBook_Air_2">
|
||||
<legend>MacBook Air</legend>
|
||||
</image>
|
||||
<image id="MacBook_Air_3">
|
||||
<legend>MacBook Air</legend>
|
||||
</image>
|
||||
<image id="MacBook_Air_4">
|
||||
<legend>MacBook Air</legend>
|
||||
</image>
|
||||
<image id="MacBook_Air_SuperDrive">
|
||||
<legend> MacBook Air SuperDrive</legend>
|
||||
</image>
|
||||
<image id="iPod_touch">
|
||||
<legend>iPod touch</legend>
|
||||
</image>
|
||||
<image id="iPod_touch_1">
|
||||
<legend>iPod touch</legend>
|
||||
</image>
|
||||
<image id="iPod_touch_2">
|
||||
<legend>iPod touch</legend>
|
||||
</image>
|
||||
<image id="iPod_touch_3">
|
||||
<legend>iPod touch</legend>
|
||||
</image>
|
||||
<image id="iPod_touch_4">
|
||||
<legend>iPod touch</legend>
|
||||
</image>
|
||||
<image id="iPod_touch_5">
|
||||
<legend>iPod touch</legend>
|
||||
</image>
|
||||
<image id="housse-portefeuille-en-cuir">
|
||||
<legend>housse-portefeuille-en-cuir</legend>
|
||||
</image>
|
||||
<image id="Shure_SE210_Sound-Isolating_Earphones_for_iPod_and_iPhone">
|
||||
<legend>Shure SE210 Sound-Isolating Earphones for iPod and iPhone</legend>
|
||||
</image>
|
||||
<image id="iPod_Nano">
|
||||
<legend>iPod Nano</legend>
|
||||
</image>
|
||||
<image id="iPod_Nano_1">
|
||||
<legend>iPod Nano</legend>
|
||||
</image>
|
||||
<image id="iPod_Nano_2">
|
||||
<legend>iPod Nano</legend>
|
||||
</image>
|
||||
<image id="iPod_Nano_3">
|
||||
<legend>iPod Nano</legend>
|
||||
</image>
|
||||
<image id="iPod_Nano_4">
|
||||
<legend>iPod Nano</legend>
|
||||
</image>
|
||||
<image id="iPod_Nano_5">
|
||||
<legend>iPod Nano</legend>
|
||||
</image>
|
||||
<image id="iPod_Nano_6">
|
||||
<legend>iPod Nano</legend>
|
||||
</image>
|
||||
<image id="iPod_Nano_7">
|
||||
<legend>iPod Nano</legend>
|
||||
</image>
|
||||
<image id="iPod_shuffle">
|
||||
<legend>iPod shuffle</legend>
|
||||
</image>
|
||||
<image id="iPod_shuffle_1">
|
||||
<legend>iPod shuffle</legend>
|
||||
</image>
|
||||
<image id="iPod_shuffle_2">
|
||||
<legend>iPod shuffle</legend>
|
||||
</image>
|
||||
<image id="iPod_shuffle_3">
|
||||
<legend>iPod shuffle</legend>
|
||||
</image>
|
||||
</entity_image>
|
||||
@@ -0,0 +1,35 @@
|
||||
<?php
|
||||
/*
|
||||
* 2007-2013 PrestaShop
|
||||
*
|
||||
* 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.txt.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* http://opensource.org/licenses/osl-3.0.php
|
||||
* 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 http://www.prestashop.com for more information.
|
||||
*
|
||||
* @author PrestaShop SA <contact@prestashop.com>
|
||||
* @copyright 2007-2013 PrestaShop SA
|
||||
* @license http://opensource.org/licenses/osl-3.0.php Open Software License (OSL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
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,17 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_manufacturer>
|
||||
<manufacturer id="Apple_Computer_Inc">
|
||||
<description/>
|
||||
<short_description/>
|
||||
<meta_title/>
|
||||
<meta_keywords/>
|
||||
<meta_description/>
|
||||
</manufacturer>
|
||||
<manufacturer id="Shure_Incorporated">
|
||||
<description/>
|
||||
<short_description/>
|
||||
<meta_title/>
|
||||
<meta_keywords/>
|
||||
<meta_description/>
|
||||
</manufacturer>
|
||||
</entity_manufacturer>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_order_message>
|
||||
<order_message id="Delay">
|
||||
<name>Delay</name>
|
||||
<message>Hi,
|
||||
|
||||
Unfortunately, an item on your order is currently out of stock. This may cause a slight delay in delivery.
|
||||
Please accept our apologies and rest assured that we are working hard to rectify this.
|
||||
|
||||
Best regards,</message>
|
||||
</order_message>
|
||||
</entity_order_message>
|
||||
@@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<list_ordermessage>
|
||||
<ordermessage id="delay">
|
||||
<name><![CDATA[Delay]]></name>
|
||||
<message><![CDATA[Hi,
Unfortunately, an item on your order is currently out of stock. This may cause a slight delay in delivery.
Please accept our apologies and rest assured that we are working hard to rectify this.
Best regards,]]></message>
|
||||
</ordermessage>
|
||||
</list_ordermessage>
|
||||
@@ -0,0 +1,135 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_product>
|
||||
<product id="iPod_Nano" id_shop="1">
|
||||
<description><p><strong><span style="font-size: small;">Curved ahead of the curve.</span></strong></p>
|
||||
<p>For those about to rock, we give you nine amazing colors. But that's only part of the story. Feel the curved, all-aluminum and glass design and you won't want to put iPod nano down.</p>
|
||||
<p><strong><span style="font-size: small;">Great looks. And brains, too.</span></strong></p>
|
||||
<p>The new Genius feature turns iPod nano into your own highly intelligent, personal DJ. It creates playlists by finding songs in your library that go great together.</p>
|
||||
<p><strong><span style="font-size: small;">Made to move with your moves.</span></strong></p>
|
||||
<p>The accelerometer comes to iPod nano. Give it a shake to shuffle your music. Turn it sideways to view Cover Flow. And play games designed with your moves in mind.</p></description>
|
||||
<description_short><p>New design. New features. Now in 8GB and 16GB. iPod nano rocks like never before.</p></description_short>
|
||||
<link_rewrite>ipod-nano</link_rewrite>
|
||||
<meta_description/>
|
||||
<meta_keywords/>
|
||||
<meta_title/>
|
||||
<name>iPod Nano</name>
|
||||
<available_now>In stock</available_now>
|
||||
<available_later/>
|
||||
</product>
|
||||
<product id="iPod_shuffle" id_shop="1">
|
||||
<description><p><span style="font-size: small;"><strong>Instant attachment.</strong></span></p>
|
||||
<p>Wear up to 500 songs on your sleeve. Or your belt. Or your gym shorts. iPod shuffle is a badge of musical devotion. Now in new, more brilliant colors.</p>
|
||||
<p><span style="font-size: small;"><strong>Feed your iPod shuffle.</strong></span></p>
|
||||
<p>iTunes is your entertainment superstore. It’s your ultra-organized music collection and jukebox. And it’s how you load up your iPod shuffle in one click.</p>
|
||||
<p><span style="font-size: small;"><strong>Beauty and the beat.</strong></span></p>
|
||||
<p>Intensely colorful anodized aluminum complements the simple design of iPod shuffle. Now in blue, green, pink, red, and original silver.</p></description>
|
||||
<description_short><p>iPod shuffle, the world’s most wearable music player, now clips on in more vibrant blue, green, pink, and red.</p></description_short>
|
||||
<link_rewrite>ipod-shuffle</link_rewrite>
|
||||
<meta_description/>
|
||||
<meta_keywords/>
|
||||
<meta_title/>
|
||||
<name>iPod shuffle</name>
|
||||
<available_now>In stock</available_now>
|
||||
<available_later/>
|
||||
</product>
|
||||
<product id="MacBook_Air" id_shop="1">
|
||||
<description><p>MacBook Air is nearly as thin as your index finger. Practically every detail that could be streamlined has been. Yet it still has a 13.3-inch widescreen LED display, full-size keyboard, and large multi-touch trackpad. It’s incomparably portable without the usual ultraportable screen and keyboard compromises.</p><p>The incredible thinness of MacBook Air is the result of numerous size- and weight-shaving innovations. From a slimmer hard drive to strategically hidden I/O ports to a lower-profile battery, everything has been considered and reconsidered with thinness in mind.</p><p>MacBook Air is designed and engineered to take full advantage of the wireless world. A world in which 802.11n Wi-Fi is now so fast and so available, people are truly living untethered — buying and renting movies online, downloading software, and sharing and storing files on the web. </p></description>
|
||||
<description_short>MacBook Air is ultrathin, ultraportable, and ultra unlike anything else. But you don’t lose inches and pounds overnight. It’s the result of rethinking conventions. Of multiple wireless innovations. And of breakthrough design. With MacBook Air, mobile computing suddenly has a new standard.</description_short>
|
||||
<link_rewrite>macbook-air</link_rewrite>
|
||||
<meta_description/>
|
||||
<meta_keywords/>
|
||||
<meta_title/>
|
||||
<name>MacBook Air</name>
|
||||
<available_now/>
|
||||
<available_later/>
|
||||
</product>
|
||||
<product id="MacBook" id_shop="1">
|
||||
<description>Every MacBook has a larger hard drive, up to 250GB, to store growing media collections and valuable data.<br /><br />The 2.4GHz MacBook models now include 2GB of memory standard — perfect for running more of your favorite applications smoothly.</description>
|
||||
<description_short>MacBook makes it easy to hit the road thanks to its tough polycarbonate case, built-in wireless technologies, and innovative MagSafe Power Adapter that releases automatically if someone accidentally trips on the cord.</description_short>
|
||||
<link_rewrite>macbook</link_rewrite>
|
||||
<meta_description/>
|
||||
<meta_keywords/>
|
||||
<meta_title/>
|
||||
<name>MacBook</name>
|
||||
<available_now/>
|
||||
<available_later/>
|
||||
</product>
|
||||
<product id="iPod_touch" id_shop="1">
|
||||
<description><h3>Five new hands-on applications</h3>
|
||||
<p>View rich HTML email with photos as well as PDF, Word, and Excel attachments. Get maps, directions, and real-time traffic information. Take notes and read stock and weather reports.</p>
|
||||
<h3>Touch your music, movies, and more</h3>
|
||||
<p>The revolutionary Multi-Touch technology built into the gorgeous 3.5-inch display lets you pinch, zoom, scroll, and flick with your fingers.</p>
|
||||
<h3>Internet in your pocket</h3>
|
||||
<p>With the Safari web browser, see websites the way they were designed to be seen and zoom in and out with a tap.<sup>2</sup> And add Web Clips to your Home screen for quick access to favorite sites.</p>
|
||||
<h3>What's in the box</h3>
|
||||
<ul>
|
||||
<li><span></span>iPod touch</li>
|
||||
<li><span></span>Earphones</li>
|
||||
<li><span></span>USB 2.0 cable</li>
|
||||
<li><span></span>Dock adapter</li>
|
||||
<li><span></span>Polishing cloth</li>
|
||||
<li><span></span>Stand</li>
|
||||
<li><span></span>Quick Start guide</li>
|
||||
</ul></description>
|
||||
<description_short><ul>
|
||||
<li>Revolutionary Multi-Touch interface</li>
|
||||
<li>3.5-inch widescreen color display</li>
|
||||
<li>Wi-Fi (802.11b/g)</li>
|
||||
<li>8 mm thin</li>
|
||||
<li>Safari, YouTube, Mail, Stocks, Weather, Notes, iTunes Wi-Fi Music Store, Maps</li>
|
||||
</ul></description_short>
|
||||
<link_rewrite>ipod-touch</link_rewrite>
|
||||
<meta_description/>
|
||||
<meta_keywords/>
|
||||
<meta_title/>
|
||||
<name>iPod touch</name>
|
||||
<available_now/>
|
||||
<available_later/>
|
||||
</product>
|
||||
<product id="Belkin_Leather_Folio_for_iPod_nano_-_Black_Chocolate" id_shop="1">
|
||||
<description><p>Lorem ipsum</p></description>
|
||||
<description_short><p>Lorem ipsum</p></description_short>
|
||||
<link_rewrite>belkin-leather-folio-for-ipod-nano-black-chocolate</link_rewrite>
|
||||
<meta_description/>
|
||||
<meta_keywords/>
|
||||
<meta_title/>
|
||||
<name>Belkin Leather Folio for iPod nano - Black / Chocolate</name>
|
||||
<available_now/>
|
||||
<available_later/>
|
||||
</product>
|
||||
<product id="Shure_SE210_Sound-Isolating_Earphones_for_iPod_and_iPhone" id_shop="1">
|
||||
<description><div class="product-overview-full">Using Hi-Definition MicroSpeakers to deliver full-range audio, the ergonomic and lightweight design of the SE210 earphones is ideal for premium on-the-go listening on your iPod or iPhone. They offer the most accurate audio reproduction from both portable and home stereo audio sources--for the ultimate in precision highs and rich low end. In addition, the flexible design allows you to choose the most comfortable fit from a variety of wearing positions. <br /> <br /> <strong>Features </strong> <br /> 
|
||||
<ul>
|
||||
<li>Sound-isolating design </li>
|
||||
<li> Hi-Definition MicroSpeaker with a single balanced armature driver </li>
|
||||
<li> Detachable, modular cable so you can make the cable longer or shorter depending on your activity </li>
|
||||
<li> Connector compatible with earphone ports on both iPod and iPhone </li>
|
||||
</ul>
|
||||
<strong>Specifications </strong><br /> 
|
||||
<ul>
|
||||
<li>Speaker type: Hi-Definition MicroSpeaker </li>
|
||||
<li> Frequency range: 25Hz-18.5kHz </li>
|
||||
<li> Impedance (1kHz): 26 Ohms </li>
|
||||
<li> Sensitivity (1mW): 114 dB SPL/mW </li>
|
||||
<li> Cable length (with extension): 18.0 in./45.0 cm (54.0 in./137.1 cm) </li>
|
||||
</ul>
|
||||
<strong>In the box</strong><br /> 
|
||||
<ul>
|
||||
<li>Shure SE210 earphones </li>
|
||||
<li> Extension cable (36.0 in./91.4 cm) </li>
|
||||
<li> Three pairs foam earpiece sleeves (small, medium, large) </li>
|
||||
<li> Three pairs soft flex earpiece sleeves (small, medium, large) </li>
|
||||
<li> One pair triple-flange earpiece sleeves </li>
|
||||
<li> Carrying case </li>
|
||||
</ul>
|
||||
Warranty<br /> Two-year limited <br />(For details, please visit <br />www.shure.com/PersonalAudio/CustomerSupport/ProductReturnsAndWarranty/index.htm.) <br /><br /> Mfr. Part No.: SE210-A-EFS <br /><br />Note: Products sold through this website that do not bear the Apple Brand name are serviced and supported exclusively by their manufacturers in accordance with terms and conditions packaged with the products. Apple's Limited Warranty does not apply to products that are not Apple-branded, even if packaged or sold with Apple products. Please contact the manufacturer directly for technical support and customer service.</div></description>
|
||||
<description_short><p>Evolved from personal monitor technology road-tested by pro musicians and perfected by Shure engineers, the lightweight and stylish SE210 delivers full-range audio that's free from outside noise.</p></description_short>
|
||||
<link_rewrite>ecouteurs-a-isolation-sonore-shure-se210-blanc</link_rewrite>
|
||||
<meta_description/>
|
||||
<meta_keywords/>
|
||||
<meta_title/>
|
||||
<name>Shure SE210 Sound-Isolating Earphones for iPod and iPhone</name>
|
||||
<available_now/>
|
||||
<available_later/>
|
||||
</product>
|
||||
</entity_product>
|
||||
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_profile>
|
||||
<profile id="Administrator">
|
||||
<name>Administrator</name>
|
||||
</profile>
|
||||
<profile id="Logistician">
|
||||
<name>Logistician</name>
|
||||
</profile>
|
||||
<profile id="Translator">
|
||||
<name>Translator</name>
|
||||
</profile>
|
||||
<profile id="Salesman">
|
||||
<name>Salesman</name>
|
||||
</profile>
|
||||
</entity_profile>
|
||||
@@ -0,0 +1,12 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_scene>
|
||||
<scene id="The_iPods_Nano">
|
||||
<name>The iPods Nano</name>
|
||||
</scene>
|
||||
<scene id="The_iPods">
|
||||
<name>The iPods</name>
|
||||
</scene>
|
||||
<scene id="The_MacBooks">
|
||||
<name>The MacBooks</name>
|
||||
</scene>
|
||||
</entity_scene>
|
||||
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0"?>
|
||||
<entity_supplier>
|
||||
<supplier id="AppleStore">
|
||||
<description/>
|
||||
<meta_title/>
|
||||
<meta_keywords/>
|
||||
<meta_description/>
|
||||
</supplier>
|
||||
<supplier id="Shure_Online_Store">
|
||||
<description/>
|
||||
<meta_title/>
|
||||
<meta_keywords/>
|
||||
<meta_description/>
|
||||
</supplier>
|
||||
</entity_supplier>
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user