chg: [organisation:index] Added quickfilter showing all orgs having the same nationality as logged user.org
parent
31750da7c9
commit
ae8ecf3955
|
@ -56,6 +56,16 @@ class OrganisationsController extends AppController
|
|||
// ],
|
||||
];
|
||||
|
||||
$loggedUserOrganisationNationality = $this->ACL->getUser()['organisation']['nationality'];
|
||||
if (!empty($loggedUserOrganisationNationality)) {
|
||||
$customContextFilters[] = [
|
||||
'label' => __('Country: {0}', $loggedUserOrganisationNationality),
|
||||
'filterCondition' => [
|
||||
'nationality' => $loggedUserOrganisationNationality,
|
||||
]
|
||||
];
|
||||
}
|
||||
|
||||
$this->CRUD->index([
|
||||
'filters' => $this->filterFields,
|
||||
'quickFilters' => $this->quickFilterFields,
|
||||
|
|
Loading…
Reference in New Issue