Skip to content

docs: remove unsupported Filter code sample #606

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 20, 2023

Conversation

kenjis
Copy link
Member

@kenjis kenjis commented Jan 19, 2023

See #600 (comment)

$filters cannot set filer aruguments.
@kenjis kenjis added the documentation Improvements or additions to documentation label Jan 19, 2023
$routes->resource('users');
$routes->group(
'',
['filter' => ['group:admin,superadmin', 'permission:users.manage']],
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
['filter' => ['group:admin,superadmin', 'permission:users.manage']],
['filter' => ['group:admin,superadmin', 'permission:users.manage-admins']],

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

permission:users.manage is not listed in https://github.com/codeigniter4/shield/blob/develop/docs/authorization.md#defining-available-permissions
But in this case, I feel permission:users.manage-admins is a bit weird.
The URI seems the page to manage users, not admin-users.

Copy link
Collaborator

@datamweb datamweb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @kenjis and sorry for the delay.

@kenjis kenjis merged commit 697f570 into codeigniter4:develop Jan 20, 2023
@kenjis kenjis deleted the fix-docs-flters branch January 20, 2023 08:46
@kenjis
Copy link
Member Author

kenjis commented Jan 20, 2023

@datamweb No problem. Thank you for the review.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants