Code

Opened 3 years ago

Closed 2 years ago

Last modified 2 years ago

#17131 closed Bug (fixed)

Permissions documentation not up to date

Reported by: dchandek Owned by: mateusgondim
Component: Documentation Version: 1.3
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

https://docs.djangoproject.com/en/dev/topics/auth/#permissions says:

Permissions are set globally per type of object, not per specific object instance. For example, it's possible to say "Mary may change news stories," but it's not currently possible to say "Mary may change news stories, but only the ones she created herself" or "Mary may only change news stories that have a certain status, publication date or ID." The latter functionality is something Django developers are currently discussing.

However, the ModelAdmin class provides has_add_permission, has_change_permission and has_delete_permission methods.

Attachments (1)

ticket17131.diff (1.1 KB) - added by mateusgondim 2 years ago.
I replaced the outdated text in auth.txt with a text talking about the possibility of permissions per specific object instance.

Download all attachments as: .zip

Change History (6)

comment:1 Changed 3 years ago by lukeplant

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Accepted
  • Type changed from Uncategorized to Bug

comment:2 Changed 2 years ago by mateusgondim

  • Owner changed from nobody to mateusgondim

Changed 2 years ago by mateusgondim

I replaced the outdated text in auth.txt with a text talking about the possibility of permissions per specific object instance.

comment:3 Changed 2 years ago by mateusgondim

  • Has patch set

comment:4 Changed 2 years ago by Tim Graham <timograham@…>

  • Resolution set to fixed
  • Status changed from new to closed

In [8d3e501502c308cbdd3cc95b62ace0fe11d373ab]:

Fixed #17131 - Added per object permission notes to docs.

Thanks dchandek for the suggestion and mateusgondim for the patch.

comment:5 Changed 2 years ago by Tim Graham <timograham@…>

In [fa6577f5b2af9848b661fc24719b59e07d214728]:

Fixed #17131 - Added per object permission notes to docs.

Thanks dchandek for the suggestion and mateusgondim for the patch.

Backport of 8d3e501502c308cbdd3cc95b62ace0fe11d373ab from master

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.