Simplified the organisation column permissions for now
This commit is contained in:
@@ -1114,17 +1114,8 @@ class OrganisationController extends SimpleController
|
||||
throw new ForbiddenException();
|
||||
}
|
||||
|
||||
$tableColumns = [ 'description' ];
|
||||
$tableColumns = [ 'description', 'join' ];
|
||||
|
||||
if (
|
||||
(
|
||||
$currentUser->organisations(true)->count() == 0
|
||||
|| !$config['organisation']['membership']['single_membership']
|
||||
)
|
||||
&& !$config['organisation']['combine_action_buttons']
|
||||
) {
|
||||
$tableColumns[] = 'join';
|
||||
}
|
||||
|
||||
if ($currentUser->organisations(true)->wherePivot('flag_admin', true)
|
||||
|| $authorizer->checkAccess($currentUser, 'delete_organisation')
|
||||
@@ -1136,6 +1127,11 @@ class OrganisationController extends SimpleController
|
||||
$tableColumns[] = 'actions';
|
||||
}
|
||||
|
||||
if ($currentUser->organisations(true)->wherePivot('flag_admin', true)) {
|
||||
$tableColumns[] = 'status';
|
||||
$tableColumns[] = 'actions';
|
||||
}
|
||||
|
||||
return $this->ci->view->render(
|
||||
$response,
|
||||
'pages/organisations.html.twig',
|
||||
|
||||
Reference in New Issue
Block a user