Merge branch '1028-Filtro-de-búsqueda-Agent-Detail-se-borra-al-cambiar-de-página-dev' into 'develop'

Fixed error in filter pagination

See merge request !597
This commit is contained in:
vgilc 2017-06-22 10:21:40 +02:00
commit 87db7368c0
1 changed files with 7 additions and 5 deletions

View File

@ -1621,13 +1621,15 @@ function ui_pagination ($count, $url = false, $offset = 0,
// Pagination links for users include delete, create and other params, now not use these params, and not retry the previous action when go to pagination link.
$remove = array("user_del","disable_user","delete_user");
$finalUrl = $config['homeurl'].'?';
foreach($_GET as $index => $get){
if(!in_array($index, $remove)){
$finalUrl .= $index.'='.$get.'&';
$url = explode("&",$url);
$finalUrl = array();
foreach ($url as $key => $value) {
if(strpos($value, $remove[0]) === false && strpos($value, $remove[1]) === false && strpos($value, $remove[2]) === false){
array_push($finalUrl,$value);
}
}
$url = $finalUrl;
$url = implode("&",$finalUrl);
/*
URL passed render links with some parameter