|
|
@ -400,22 +400,22 @@ SCRIPT; |
|
|
|
protected function registerExportJs() |
|
|
|
{ |
|
|
|
$js = <<<SCRIPT |
|
|
|
$("a.export-all").click(function(){ |
|
|
|
var url = $(this).data("url")+location.search; |
|
|
|
// var params = location.search.split("&");
|
|
|
|
// var new_params = [];
|
|
|
|
// var ret = /page=\d*/
|
|
|
|
// $.each(params,function(index,value){
|
|
|
|
// if(!ret.test(value)){
|
|
|
|
// new_params.push(value);
|
|
|
|
// }
|
|
|
|
// });
|
|
|
|
window.location.replace(url+"&page-type=all"); |
|
|
|
}); |
|
|
|
$("a.export-page").click(function(){ |
|
|
|
$("a.export-all").click(function(url){ |
|
|
|
var url = $(this).data("url"); |
|
|
|
if(!location.search){ |
|
|
|
window.location.replace(url+"?page-type=all"); |
|
|
|
}else{ |
|
|
|
window.location.replace(url+location.search+"&page-type=all"); |
|
|
|
} |
|
|
|
}); |
|
|
|
$("a.export-page").click(function(url){ |
|
|
|
var url = $(this).data("url")+location.search; |
|
|
|
window.location.replace(url+"&page-type=page"); |
|
|
|
}); |
|
|
|
if(!location.search){ |
|
|
|
window.location.replace(url+"?page-type=page"); |
|
|
|
}else{ |
|
|
|
window.location.replace(url+location.search+"&page-type=page"); |
|
|
|
} |
|
|
|
}); |
|
|
|
SCRIPT; |
|
|
|
$this->getView()->registerJs($js); |
|
|
|
} |
|
|
|