Bharat Mediratta
3d2fc86604
Permission only function on albums.
2008-12-16 00:30:05 +00:00
Bharat Mediratta
b6363bcb03
Update to reflect changes in Kohana ORM relationship code.
...
Now you must call ORM::save() after ORM::add() and ORM::remove().
2008-12-15 20:49:05 +00:00
Bharat Mediratta
af8c74f612
Fix a bug where parent permissions were not getting inherited to newly
...
created albums and photos.
2008-12-13 20:06:20 +00:00
Bharat Mediratta
8ba5ea3cf8
Make sure that access::can fails if the item is not loaded
2008-12-13 19:49:33 +00:00
Bharat Mediratta
a3142246e4
Move the view permission cache directly into the item table for efficiency. Unit tests ftw!
2008-12-12 06:54:48 +00:00
Bharat Mediratta
2cf3233f54
Get rid of all pseudo users and pseudo groups, while preserving all
...
other functionality. This makes our user/group and access code
fully consistent.
2008-12-12 00:59:30 +00:00
Bharat Mediratta
18a6614a11
Change all access API methods to take ORMs instead of ids. This will
...
minimize reloading objects from the database.
2008-12-10 07:05:49 +00:00
Bharat Mediratta
e62103b8d9
Move code to delete users and add/remove users from groups into the
...
model.
2008-12-09 08:47:30 +00:00
Bharat Mediratta
f69f3967ea
move user::delete() to User_Model::delete()
2008-12-09 00:07:26 +00:00
Bharat Mediratta
e3ad42a276
Add access::can() which verifies that the user belongs to a group that has the
...
given permission.
2008-12-09 00:02:20 +00:00
Bharat Mediratta
bd3a472be7
Rename access::can() to access::group_can()
2008-12-08 10:46:53 +00:00
Bharat Mediratta
5d23a6515d
Finish writing unit tests for Access. No bugs found!
2008-12-07 10:56:44 +00:00
Bharat Mediratta
bf7ab8904a
Change ORM_MPTT::add_to_parent() to take an ORM instead of an id so
...
that it's consistent with ORM_MPTT::move_to()
2008-12-07 08:46:44 +00:00
Bharat Mediratta
bae905a4cb
Improvements to access helper.
...
o Rename access::remove_group() to access::delete_group() for
consistency.
o Wrote more unit tests
o Tests found a bug in access::remove_item() .. yay!
2008-12-04 06:40:35 +00:00
Bharat Mediratta
d8511f2fde
Implement two tests
2008-12-03 19:10:23 +00:00
Bharat Mediratta
efc6270295
Test stubs
2008-12-03 17:17:59 +00:00