Fix js for ie in list

This commit is contained in:
Christophe Vilayphiou committed 2012-08-16 01:09:45 +08:00
1 parent 53c5f6a3b9
commit 96fd89cca3
5 files changed
+23 -21

No files matched your search

+2 -3
View File
@@ -129,7 +129,6 @@
var that = this
this.isShown = false
//alert(this.isShown+":"+this.$element.attr('class'))
$('body').removeClass('modal-open')
@@ -1250,8 +1249,8 @@
var that = this
, complete = function () {
if (startEvent == 'show') that.reset()
that.$element.trigger(completeEvent)
mainTablePosition();
that.$element.trigger(completeEvent)
setTimeout(mainTablePosition,150);
}
this.$element
-16
View File
@@ -1,16 +0,0 @@
$(document).on('click', '.list-remove', function(){
var a = [];
$('.checkbox_in_list').each(function(){
if (this.checked) a.push("ids[]=" + this.value);
});
var url = $(this).attr('rel');
if (url.indexOf('?') > -1){
$.getScript(url + '&' + a.join('&'));
}else{
$.getScript(url + '?' + a.join('&'));
}
});
$(document).on('click', '#check_all', function(){
$('.checkbox_in_list').attr("checked", this.checked);
});
+19
View File
@@ -0,0 +1,19 @@
<%#= encoding: utf-8 %>
$(document).on('click', '.list-remove', function(){
if(confirm("<%= I18n.t('sure?') %>")){
var a = [];
$('.checkbox_in_list').each(function(){
if (this.checked) a.push("ids[]=" + this.value);
});
var url = $(this).attr('rel');
if (url.indexOf('?') > -1){
$.getScript(url + '&' + a.join('&'));
}else{
$.getScript(url + '?' + a.join('&'));
}
}
});
$(document).on('click', '#check_all', function(){
$('.checkbox_in_list').attr("checked", this.checked);
});