Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
  • 69 commits
  • 81 files changed
  • 0 comments
  • 4 contributors
Jul 11, 2006
Jacob Kaplan-Moss Created per-object-permissions branch for Christopher Long's SoC proj…
…ect.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3330 bcc190cf-cafb-0310-a4f2-bffc1f526a37
53fed0e
Jul 24, 2006
[per-object-permissions] Updated auth model's to contain the row leve…
…l permission object and connected users with row level permissions

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3440 bcc190cf-cafb-0310-a4f2-bffc1f526a37
71dad9e
[per-object-permissions] django.db.models.base now adds the row level…
… permission relation when enabled using the meta class

[per-object-permissions] django.db.models.options contains the row level permission option for the meta class, by default the option is false (not enabled)

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3441 bcc190cf-cafb-0310-a4f2-bffc1f526a37
8e48efb
Jul 27, 2006
[per-object-permissions] Update to trunk 75c6dc9
Jul 29, 2006
[per-object-permissions] Very basic integration of RLPs into admin in…
…terface.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3486 bcc190cf-cafb-0310-a4f2-bffc1f526a37
340718b
[per-object-permissions] Fixed some problems with checking of permiss…
…ions

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3487 bcc190cf-cafb-0310-a4f2-bffc1f526a37
68072fa
Aug 02, 2006
[per-object-permissions] Renamed the attribute in RLPs to be model in…
…stead of type

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3518 bcc190cf-cafb-0310-a4f2-bffc1f526a37
aba82ef
Aug 06, 2006
[per-object-permissions] First version of checking for row level perm…
…issions. No cache implemented at this point. See wiki page for more details.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3529 bcc190cf-cafb-0310-a4f2-bffc1f526a37
18c889d
Aug 07, 2006
[per-object-permissions] Fixed RLP perm checking so it now accepts th…
…e string app_label.perm_codename format correctly.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3531 bcc190cf-cafb-0310-a4f2-bffc1f526a37
e8ea76b
[per-object-permissions] model test for row level permissions 1eb8c61
[per-object-permissions] model test for row level permissions (w/ files) b68a6ae
[per-object-permissions] Rewrote urls for row level permission views …
…to take the ajax parameter as a GET instead of a addition to the URL

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3534 bcc190cf-cafb-0310-a4f2-bffc1f526a37
759f426
Aug 09, 2006
[per-object-permissions] AJAX interface is now working most of the ti…
…me. A fair amount of work has to be done still and some tidying up of the interface. Uses YUI toolkit. Currently comes w/ the full toolkit, once debugged and working will keep only the needed js files.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3540 bcc190cf-cafb-0310-a4f2-bffc1f526a37
2176184
[per-object-permissions] Forgot to add toolkit files in last commit ea345fa
Aug 11, 2006
[per-object-permissions] Separated the AJAX javascript from the non-A…
…JAX JS

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3555 bcc190cf-cafb-0310-a4f2-bffc1f526a37
98bb076
[per-object-permissions] Removed AJAX code from branch. Will possibly…
… be integrated in at another point.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3556 bcc190cf-cafb-0310-a4f2-bffc1f526a37
e46e6f6
[per-object-permissions] Removing YUI toolkit code. 03e1b7f
Aug 13, 2006
[per-object-permissions] Added "Apply Selected" button to RLP table t…
…hat submits the selected row levle permissions to be changed.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3578 bcc190cf-cafb-0310-a4f2-bffc1f526a37
4f01189
Aug 14, 2006
[per-object-permissions] Merged to revision 3582 4cfd320
[per-object-permissions] Merged to revision 3582 (resolved conflict) dc3c4db
[per-object-permissions] Corrected incorrect import in row_level_perm…
…_manipulator and made some format changes to the row level perm template

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3586 bcc190cf-cafb-0310-a4f2-bffc1f526a37
77eda02
[per-object-permissions] Corrected bug in creating of default row lev…
…el perms that would cause no permission to be found due to capitalization

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3587 bcc190cf-cafb-0310-a4f2-bffc1f526a37
8cd0dbd
Aug 15, 2006
[per-object-permissions] Created template tag if_has_perm to check fo…
…r a users permission

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3589 bcc190cf-cafb-0310-a4f2-bffc1f526a37
8250114
Aug 18, 2006
[per-object-permissions] Added grant_change_row_level_perm and grant_…
…delete_row_level_perm for admin class in models, assigns the given permissions automatically after creation of an object

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3609 bcc190cf-cafb-0310-a4f2-bffc1f526a37
7c98652
[per-object-permissions] Renders multiple object select field using o…
…ptgroup to separate the types of objects

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3610 bcc190cf-cafb-0310-a4f2-bffc1f526a37
f180bb6
Aug 19, 2006
[per-object-permissions] Fixed bug in if_has_perm tag that would caus…
…e it to not work if an object paramter was not passed to it

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3614 bcc190cf-cafb-0310-a4f2-bffc1f526a37
da50848
[per-object-permissions] Updating admin interface of RLP to be on a s…
…eparate page, not entirely working at this point

[per-object-permissions] Changed global.css to apply styles to reset button

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3615 bcc190cf-cafb-0310-a4f2-bffc1f526a37
9f115aa
[per-object-permissions] Added "Edit Row Level Permissions" link on c…
…hange_form if object has row level permissions enabled

[per-object-permissions] Modified the row level permissions edit page so the URL is based off of the object instead of being part of the auth 

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3616 bcc190cf-cafb-0310-a4f2-bffc1f526a37
b5cbbf5
[per-object-permissions] Changed pagination to use the paginator tag … 741df7b
[per-object-permissions] Minor fixes to admin RLP interface 23cb1f0
Aug 20, 2006
[per-object-permissions] Minor fixes to admin RLP views
[per-object-permissions] Removed test failing due to cache problems

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3619 bcc190cf-cafb-0310-a4f2-bffc1f526a37
6bed9e0
[per-object-permissions] Added some more comments
[per-object-permissions] Added "hidden" option to admin options, this is to allow an object to have admin options but not be shown on the admin interface. Might not be wanted, and can be removed if that is the case.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3622 bcc190cf-cafb-0310-a4f2-bffc1f526a37
722d0db
[per-object-permissions] Removed commented (unused) code 19ece74
[per-object-permissions] Expanded on has_module_perm to check for row…
… level permissions contained within the module

[per-object-permissions] Created method contains_permission to check if a user has a permission on a model (not hte instance). The difference between this and has_perm is that contains_permission does not require an instance of a model, it only checks that there exists a row level permission for an instance of this object.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3624 bcc190cf-cafb-0310-a4f2-bffc1f526a37
e1caee2
[per-object-permissions] Updated admin pages to use contains_permissi…
…on, this means the admin interface will now show the change list link to a user even if they only have change row level permissions on one of the objects. Right now, it does list all the objects and does not filter out those that the user does not have permissions on.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3625 bcc190cf-cafb-0310-a4f2-bffc1f526a37
8a38dfa
[per-object-permissions] Removed debug print statement in auth/models.py
[per-object-permissions] Added admin option: show_all_rows which by default is set to True. If False, it will only show the rows the user has permission for. Implemented the changes into change_list to allow this

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3627 bcc190cf-cafb-0310-a4f2-bffc1f526a37
736feba
[per-object-permissions] Added comments to change_list and admin_list.py 98fc1a2
[per-object-permissions] Fixed bug in contains_permission where it wa…
…s just checking against any permission instead of the given permission

[per-object-permissions] Made changes so delete and "Save and add another" only shows up if the user has permissions
[per-object-permissions] Rewrote the has permission variables in the context for change form to use has_perms and check for model

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3629 bcc190cf-cafb-0310-a4f2-bffc1f526a37
455842e
[per-object-permissions] Update to trunk 49c1c2f
Aug 21, 2006
[per-object-permissions] Fixed up some comments 84771a6
Aug 24, 2006
[per-object-permissions] Fixed two bugs (noticed by Robert). 1) has_a…
…dd_permission was not part of the new add user context and was causing an error when rendering the submit_row, changed view to have the has_add_permission 2) Custom SQL for checking if permissions exist was causing an error due to an incorrect False statment, corrected now.

[per-object-permissions] Fixed a bug where delete row level permission was giving a PermissionDenied error falsely

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3655 bcc190cf-cafb-0310-a4f2-bffc1f526a37
7b2e379
[per-object-permissions] Fixed a bug where delete row level permissio…
…n was giving a PermissionDenied error falsely. (Missed adding the file to the commit)

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3656 bcc190cf-cafb-0310-a4f2-bffc1f526a37
5d37e5c
Aug 25, 2006
[per-object-permissions] Removed a debug print statement and changed …
…an incorrect order of a format string

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3657 bcc190cf-cafb-0310-a4f2-bffc1f526a37
bd64483
Aug 28, 2006
[per-object-permissions] Merged to trunk 3666 61d6f59
[per-object-permissions] New method: get_model_list in the RowLevelPe…
…rmission manager. This returns a list of ids for the given model that the user has the given permission on. It should work better then doing something like has_perm or {% if_has_perm %}

[per-object-permissions] Modified the change_list to use get_model_list instead of the current checking each perm. Note: this method has not been tested extensively, and might cause some problems

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3674 bcc190cf-cafb-0310-a4f2-bffc1f526a37
64be2e2
Aug 29, 2006
[per-object-permissions] Fixed missing parenthesis 325762a
Aug 30, 2006
[per-object-permissions] Fixed #2622 and added in contains_permission…
… method to the anonymous user model

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3682 bcc190cf-cafb-0310-a4f2-bffc1f526a37
ea2a514
Sep 04, 2006
[per-object-permissions] Fixes #2652, modified the form field to incl…
…ude the app label in the select field (the elements of which are now separated by a /)

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3716 bcc190cf-cafb-0310-a4f2-bffc1f526a37
aef0582
Sep 07, 2006
[per-object-permissions] Fixes #2664 and #2663 5c13ad5
[per-object-permissions] Merged to trunk [3731] e12c2f8
Sep 12, 2006
[per-object-permissions] Fixes problem with one-to-one relationships …
…as the original code assumed every model had an id attribute, now uses "_get_pk_val()" to determine the model id.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3752 bcc190cf-cafb-0310-a4f2-bffc1f526a37
00972e6
[per-object-permissions] Fixes MySQL error caused by when a user is n…
…ot a member of a group

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3753 bcc190cf-cafb-0310-a4f2-bffc1f526a37
43260cf
Sep 15, 2006
[per-object-permissions] Fixes the delete permission which assumed th…
…e object had an id attribute

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3764 bcc190cf-cafb-0310-a4f2-bffc1f526a37
a2fbd5f
Sep 17, 2006
[per-object-permissions] Fixes bug described in ticket #2749
[per-object-permissions] Fixes the add manipulator so it does not assume the pk attribute is "id"

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3767 bcc190cf-cafb-0310-a4f2-bffc1f526a37
20ca175
Sep 18, 2006
[per-object-permissions] Fixes another problem when using one-to-one …
…relations and POPs

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3769 bcc190cf-cafb-0310-a4f2-bffc1f526a37
aa6725c
Sep 23, 2006
[per-object-permissions] Fixes the bug described by schotm where grou…
…p permissions were causing a db error when show_all_rows was set to false

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3809 bcc190cf-cafb-0310-a4f2-bffc1f526a37
13d039d
[per-object-permissions] Merged to trunk [3809] 5ea24f0
Sep 25, 2006
[per-object-permissions] Latest revision showed "Edit Row Level Permi…
…ssions" for all objects in admin interface (not just those for which it is enabled), this revision fixes this bug

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3843 bcc190cf-cafb-0310-a4f2-bffc1f526a37
ea24926
Oct 03, 2006
[per-object-permissions] First version where inline objects are check…
…ed for row level permissions

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3891 bcc190cf-cafb-0310-a4f2-bffc1f526a37
655bee8
[per-object-permissions] Sets the row level permisisons on objects cr…
…eated inline if the inline objects have row level permissions enabled. This has not been tested indepth, and might not work 100%

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3895 bcc190cf-cafb-0310-a4f2-bffc1f526a37
46f6dc7
Oct 04, 2006
[per-object-permissions] Fixed a bug where the RLP for an inline obje…
…ct would only be set when changing an object not adding

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@3896 bcc190cf-cafb-0310-a4f2-bffc1f526a37
3f60a8e
Oct 27, 2006
[per-object-permissions] Merged to trunk [3938] f6fa103
Nov 24, 2006
Adrian Holovaty per-object-permissions: Small change to django.db.models.base check t…
…o make it more explicit

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@4095 bcc190cf-cafb-0310-a4f2-bffc1f526a37
47fca88
Adrian Holovaty per-object-permissions: Merged to trunk [4095] 1b54fc3
Nov 25, 2006
Adrian Holovaty per-object-permissions: Made some code-formatting changes 6fab0ff
Adrian Holovaty per-object-permissions: Merged to trunk [4101] c4673e4
Dec 27, 2006
Adrian Holovaty per-object-permissions: Merged to trunk [4241] 0cf7bc4
Jun 17, 2007
per-object-permissions: Merged to trunk [5486] NOTE: Not fully tested…
…, will be working on this over the next few weeks.

git-svn-id: http://code.djangoproject.com/svn/django/branches/per-object-permissions@5488 bcc190cf-cafb-0310-a4f2-bffc1f526a37
ae22b6d
Sep 11, 2009
James Bennett Move the per-object-permissions branch into the attic. 66ada24