Fix #1338 : Fix notices display in admin

This commit is contained in:
Romain Neutron
2013-07-17 13:38:30 +02:00
parent 2b6a284e9c
commit 5c22b69d98
5 changed files with 24 additions and 18 deletions

View File

@@ -19,7 +19,13 @@
<td colspan="2" style="height:20px;" />
</tr>
<tr>
<td colspan="2" valign="center" align="left"><div class="form-actions"><button class="btn btn-primary" id="apply">{% trans 'boutton::valider' %}</button></div></td>
<td colspan="2" valign="center" align="left">
<div class="form-actions">
<button class="btn btn-primary" id="apply">
{% trans 'boutton::valider' %}
</button>
</div>
</td>
</tr>
</table>
@@ -70,7 +76,7 @@
var html = _.template($("#alert_"+ (datas.success ? "success" : "error") +"_tpl").html(), {
content:datas.msg
});
$('#table-order').insertBefore(html);
$('#table-order').before(html);
},
complete : function() {
$this.attr('disabled', false);
@@ -81,13 +87,13 @@
function moveUpItem(select){
select.find('option:selected').each(function(){
$(this).insertBefore($(this).prev());
$(this).before($(this).prev());
});
}
function moveDownItem(select){
select.find('option:selected').each(function(){
$(this).insertAfter($(this).next());
$(this).after($(this).next());
});
}

View File

@@ -655,7 +655,7 @@ function valid()
if(data.success) {
$('#tree li.selected a').trigger('click');
} else {
$(".page-header").insertAfter(
$(".page-header").after(
'<div class="alert alert-error">'
+'<button class="close" data-dismiss="alert">×</button>'
+ data.msg