diff --git a/app/call_block/call_block.php b/app/call_block/call_block.php index 09c6af8d0a..5fa5a5f10e 100644 --- a/app/call_block/call_block.php +++ b/app/call_block/call_block.php @@ -98,9 +98,9 @@ //prepare to page the results $sql = "select count(*) from view_call_block "; $sql .= "where true "; - if ($_GET['show'] == "all" && permission_exists('call_forward_all')) { - $sql .= "and (domain_uuid = :domain_uuid or domain_uuid is null) "; - $parameters['domain_uuid'] = $_SESSION['domain_uuid']; + if ($_GET['show'] == "all" && permission_exists('call_block_all')) { + //$sql .= "and (domain_uuid = :domain_uuid or domain_uuid is null) "; + //$parameters['domain_uuid'] = $_SESSION['domain_uuid']; } else { $sql .= "and (domain_uuid = :domain_uuid) "; @@ -127,7 +127,7 @@ //prepare to page the results $rows_per_page = ($_SESSION['domain']['paging']['numeric'] != '') ? $_SESSION['domain']['paging']['numeric'] : 50; $param = "&search=".$search; - if ($_GET['show'] == "all" && permission_exists('call_forward_all')) { + if ($_GET['show'] == "all" && permission_exists('call_block_all')) { $param .= "&show=all"; } $page = $_GET['page']; @@ -139,9 +139,9 @@ //get the list $sql = "select * from view_call_block "; $sql .= "where true "; - if ($_GET['show'] == "all" && permission_exists('call_forward_all')) { - $sql .= "and (domain_uuid = :domain_uuid or domain_uuid is null) "; - $parameters['domain_uuid'] = $_SESSION['domain_uuid']; + if ($_GET['show'] == "all" && permission_exists('call_block_all')) { + //$sql .= "and (domain_uuid = :domain_uuid or domain_uuid is null) "; + //$parameters['domain_uuid'] = $_SESSION['domain_uuid']; } else { $sql .= "and (domain_uuid = :domain_uuid) "; @@ -192,7 +192,7 @@ echo button::create(['type'=>'button','label'=>$text['button-delete'],'icon'=>$_SESSION['theme']['button_icon_delete'],'id'=>'btn_delete','name'=>'btn_delete','style'=>'display: none;','onclick'=>"modal_open('modal-delete','btn_delete');"]); } echo "