Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork5.2k
[WIP] create voters_data_permission.rst article#3138
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Can you prefix your PR title with |
done |
.. index:: | ||
single: Security; Data Permission Voters | ||
How to implement your own Voter to check the permission for a object agains a user |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
to check user permissions for accessing a given object
.. code-block:: php | ||
$container |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
add// src/Acme/DemoBundle/Resources/config/services.php
above this line
Sorry@monbro for so many comments. I really like the work you have done so far! All these comments are only small issues which should be fixed easily. |
@xabbuh no worries, you are making good points! These conflicts should be solved now. You can have another look. |
user is granted access. This method must return one of the following values: | ||
* ``VoterInterface::ACCESS_GRANTED``: The user is allowed to access the | ||
application |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
these items should start at the same level as the backticks of the previous line. So:
* ``VoterInterface::ACCESS_GRANTED``: The user is allowed to access the application
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
btw, same for the other list items below
So ready for another review! |
This PR was merged into the 2.3 branch.Discussion----------New Data Voter Article (continuation)Hiya guys!This is just a continuation of#3138 by@monbro. I needed to rebase it against the 2.3 branch (which had conflicts), and wanted to proofread it (hence the fresh PR).Please check out my latest commit to see if I've made any mistakes :).| Q | A| ------------- | ---| Doc fix? | no| New docs? | yes| Applies to | 2.3| Fixed tickets |#2877Thanks!Commits-------d3f9383 [#3594] Nice tweaks thanks to@wouterj and@xabbuh2391758 [#2877][#3138] Proofreading the new voter data permission entry11aead7 simplified the example8227270 updated according to the reviewda7b97e missed one comment9b91501 updated the docs according to the last review872a05f updated the link from ACL to the data permission voters1fd3b0e updated docs according to the review5275230 updated with missing fixesf4eb5f3 updated docs according to the reviewsee0def1 improved tip box with additional link to /cookbook/security731dcad updated page with suggestion from the review1466fa7 improvements according to the reviews99b1b0f a couple of changes according to the comments, not finished now2bda150 create voters_data_permission.rst article
This is a draft about how the article for a data permission voter could look like. I am happy about feedback. I will try to improve this article the next days.
This pull-request will solve this issue#2877