2012-03-27 09:42:08 +00:00
|
|
|
//add delete confirm dialog
|
|
|
|
var Del_url = '';
|
|
|
|
function addConfirmTo(ele) {
|
|
|
|
ele.each(function() {
|
|
|
|
$(this).click(function() {
|
|
|
|
$('#dialog-delete-confirm').modal({appendTo:'#main'});
|
|
|
|
Del_url = $(this).attr('data');
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
$('#yes-btn').click(function() {
|
|
|
|
location.href = Del_url;
|
|
|
|
});
|
2012-05-14 13:51:55 +00:00
|
|
|
|
2012-03-30 05:49:32 +00:00
|
|
|
//handle table
|
|
|
|
$("table tr:nth-child(even)").addClass("even");
|
|
|
|
$("table tr:nth-child(odd)").addClass("odd");
|
2012-05-18 06:45:27 +00:00
|
|
|
|
|
|
|
//highlight the tr when mouse hover on it
|
|
|
|
$("table tr:gt(0)").hover(
|
|
|
|
function() {
|
|
|
|
$(this).addClass('hl');
|
|
|
|
},
|
|
|
|
function() {
|
|
|
|
$(this).removeClass('hl');
|
|
|
|
}
|
|
|
|
);
|