Merge branch 'bootstrap' of https://github.com/PrestaShop/PrestaShop into bootstrap
This commit is contained in:
@@ -88,26 +88,34 @@
|
||||
if (data.result) {
|
||||
if (typeof data.result.{$name} !== 'undefined') {
|
||||
for (var i=0; i<data.result.{$name}.length; i++) {
|
||||
|
||||
if (data.result.{$name}[i] !== null && data.result.{$name}[i].status == 'ok') {
|
||||
var response = data.result.{$name}[i];
|
||||
var cover = "icon-check-empty";
|
||||
|
||||
if (response.cover == "1")
|
||||
cover = "icon-check-sign";
|
||||
|
||||
imageLine(response.id, response.path, response.position, cover, response.shops,
|
||||
response.legend[{$default_language|intval}])
|
||||
$("#countImage").html(parseInt($("#countImage").html()) + 1);
|
||||
$("#img" + id).remove();
|
||||
$("#imageTable").tableDnDUpdate();
|
||||
if (typeof data.result.{$name}[i].error !== 'undefined' && data.result.{$name}[i].error != '') {
|
||||
$('#{$id}-errors').html('<strong>'+data.result.{$name}[i].name+'</strong> : '+data.result.{$name}[i].error).parent().show();
|
||||
}
|
||||
else
|
||||
{
|
||||
$(data.context).appendTo($('#{$id}-success'));
|
||||
$('#{$id}-success').parent().show();
|
||||
|
||||
if (data.result.{$name}[i] !== null && data.result.{$name}[i].status == 'ok')
|
||||
{
|
||||
var response = data.result.{$name}[i];
|
||||
var cover = "icon-check-empty";
|
||||
|
||||
if (response.cover == "1")
|
||||
cover = "icon-check-sign";
|
||||
|
||||
imageLine(response.id, response.path, response.position, cover, response.shops,
|
||||
response.legend[{$default_language|intval}])
|
||||
$("#countImage").html(parseInt($("#countImage").html()) + 1);
|
||||
$("#img" + id).remove();
|
||||
$("#imageTable").tableDnDUpdate();
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
$(data.context).find('button').remove();
|
||||
$(data.context).appendTo($('#{$id}-success'));
|
||||
$('#{$id}-success').parent().show();
|
||||
}
|
||||
},
|
||||
}).on('fileuploadalways', function (e, data) {
|
||||
|
||||
@@ -203,7 +203,7 @@
|
||||
</a>
|
||||
</div>
|
||||
<div class="panel-footer text-small">
|
||||
<a href="index.php?tab=AdminCustomerThreads&token={getAdminToken tab='AdminCustomerThreads'}">{l s='Show all messages'}</a>
|
||||
<a href="index.php?controller=AdminCustomerThreads&token={getAdminToken tab='AdminCustomerThreads'}">{l s='Show all messages'}</a>
|
||||
</div>
|
||||
</section>
|
||||
</div>
|
||||
|
||||
@@ -122,25 +122,32 @@
|
||||
if (typeof data.result.{$name} !== 'undefined') {
|
||||
for (var i=0; i<data.result.{$name}.length; i++) {
|
||||
if (data.result.{$name}[i] !== null) {
|
||||
if (typeof data.result.{$name}[i].image !== 'undefined') {
|
||||
var template = '<div class="img-thumbnail text-center">';
|
||||
template += '<p>'+data.result.{$name}[i].image+'</p>';
|
||||
|
||||
if (typeof data.result.{$name}[i].delete_url !== 'undefined') {
|
||||
template += '<p><a class="btn btn-default" href="'+data.result.{$name}[i].delete_url+'"><i class="icon-trash"></i> {l s='Delete'}</a></p>';
|
||||
}
|
||||
if (typeof data.result.{$name}[i].error !== 'undefined' && data.result.{$name}[i].error != '') {
|
||||
$('#{$id}-errors').html('<strong>'+data.result.{$name}[i].name+'</strong> : '+data.result.{$name}[i].error).parent().show();
|
||||
}
|
||||
else
|
||||
{
|
||||
$(data.context).appendTo($('#{$id}-success'));
|
||||
$('#{$id}-success').parent().show();
|
||||
|
||||
template += '</div>';
|
||||
$('#{$id}-images-thumbnails').html($('#{$id}-images-thumbnails').html()+template);
|
||||
$('#{$id}-images-thumbnails').parent().show();
|
||||
if (typeof data.result.{$name}[i].image !== 'undefined')
|
||||
{
|
||||
var template = '<div class="img-thumbnail text-center">';
|
||||
template += '<p>'+data.result.{$name}[i].image+'</p>';
|
||||
|
||||
if (typeof data.result.{$name}[i].delete_url !== 'undefined')
|
||||
template += '<p><a class="btn btn-default" href="'+data.result.{$name}[i].delete_url+'"><i class="icon-trash"></i> {l s='Delete'}</a></p>';
|
||||
|
||||
template += '</div>';
|
||||
$('#{$id}-images-thumbnails').html($('#{$id}-images-thumbnails').html()+template);
|
||||
$('#{$id}-images-thumbnails').parent().show();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$(data.context).find('button').remove();
|
||||
$(data.context).appendTo($('#{$id}-success'));
|
||||
$('#{$id}-success').parent().show();
|
||||
$(data.context).find('button').remove();
|
||||
}
|
||||
},
|
||||
}).on('fileuploadalways', function (e, data) {
|
||||
|
||||
Reference in New Issue
Block a user