Commit Graph

596 Commits

Author SHA1 Message Date
Jon
f9393a59d2 chore(access): Remove extra calls to get_obj_permission from permission Mixin has_permission
ref: #471 #511
2025-02-01 16:27:26 +09:30
Jon
22b02dc044 refactor(access): When fetching obj org, if pk exist attempt to fetch object
ref: #471 #511
2025-02-01 16:26:02 +09:30
Jon
c5eb26e62b feat: Views to cache discovered serializer
ref: #471 #511
2025-02-01 14:46:05 +09:30
Jon
b8cac94f9a fix(settings): grant the user access to their own settings object
ref: #485 #486
2025-01-24 15:17:07 +09:30
Jon
a1207bfb0f fix(settings): grant the user access to their own settings
ref: #485 #486
2025-01-23 22:47:55 +09:30
Jon
ab0666005c refactor(access): Dont override django middleware, create own for access tenancy
ref: #475
2025-01-19 15:32:48 +09:30
Jon
9b40668a30 fix(access): use request object passed to has_object_permission
ref: #473 #474
2025-01-18 23:43:11 +09:30
Jon
4d53e1846a fix(access): use the request user teams within Manager
ref: #473 #474
2025-01-18 23:03:20 +09:30
Jon
f08d3357d0 test: update to cater for tenancy object in request
ref: #473 #474
2025-01-18 22:57:00 +09:30
Jon
7f79c8485b feat(access): TenancyManager object to cache the users team lokkup
ref: #473
2025-01-18 17:58:33 +09:30
Jon
2d41d8a784 feat(access): if organization object casted to int, return organization.id
ref: #473 #474
2025-01-18 17:58:19 +09:30
Jon
e5d23cc1fa refactor(access): Move user perm logic to request.tenancy object
ref: #473 #474
2025-01-18 17:57:17 +09:30
Jon
6bf40e469c refactor: Move app_settings object to request object
ref: #473
2025-01-18 17:55:54 +09:30
Jon
7f16a06131 refactor(access): cache app settings during perm check
ref: #469 #471
2025-01-17 01:57:06 +09:30
Jon
fefde281be fix(access): cached orgs is an int list
ref: #469 #471
2025-01-17 01:51:48 +09:30
Jon
bd07c83cfc refactor(access): prefetch team related fields
ref: #469 #471
2025-01-17 01:50:02 +09:30
Jon
699a9608ef fix(access): Return API exception, not django
for current interface this exception will not work. however as the interface is depreciated, this bug is OK.

ref: #469
2025-01-12 17:43:04 +09:30
Jon
e2da2b173d chore(api): remove empty string for documentation link
ref: #463 #469
2025-01-12 16:48:12 +09:30
Jon
b9824892ae feat(access): Add organization to team display_name
ref: #465 #467
2025-01-09 14:51:02 +09:30
Jon
1087dde2d5 test(access): Ensure items returned from query are from user organization and/or globally set organization
ref: #459 closes #448
2025-01-04 18:04:02 +09:30
Jon
dd72843ffb feat(access): Enable Objects from global organization to be viewable by user with the permission
ref: #448 #459
2025-01-03 12:14:26 +09:30
Jon
0d5f329146 feat(access): Enable Objects from globally set organization to return within query
ref: #448 #459
2025-01-03 12:00:46 +09:30
Jon
a4a9f2c3a9 feat(access): Enable the calling of the dynamic permissions function to obtain permissions
creates recursive loop

ref: #437 #459
2025-01-02 17:01:01 +09:30
Jon
f7b444b8e4 fix(access): If no org specified during permission check, rtn false for permission
ref: #437 #459
2025-01-01 18:25:44 +09:30
Jon
845a5fb473 test(access): Test Cases for Organization Permission Mixin
ref: #456 # closes #442
2024-12-28 21:37:01 +09:30
Jon
4656617583 fix(access): Cached list objects must be a list including an empty one as required
ref: #442 #456
2024-12-28 18:31:53 +09:30
Jon
08b113b1ba feat(access): During permission checking also capture Http404
ref: #442 #456
2024-12-28 18:06:22 +09:30
Jon
a07dee370c refactor(access): Use exceptions for permission flow as required
ref: #442 #456
2024-12-28 17:33:11 +09:30
Jon
fbaf8770df feat(access): Super User to be granted permission
ref: #442 #456
2024-12-28 16:19:35 +09:30
Jon
e96916768e feat(access): Cache the permission required during permission checking
ref: #442 #456
2024-12-28 15:47:12 +09:30
Jon
193c6c3b7f feat(api): Add IndexViewset to ViewSet mixin
ref: #442 #456
2024-12-27 23:03:39 +09:30
Jon
62fcb5aa01 test(api): Adjust test case for metadata visibility
view user only

ref: #442 #456
2024-12-27 22:28:12 +09:30
Jon
1c87eeb188 feat(access): If the user lacks the permission during permission checks, return sooner
ref: #442 #456
2024-12-27 18:51:10 +09:30
Jon
17e437ce68 fix(access): Use request.method for determining the HTTP/Method for permission checks
ref: #442 #456
2024-12-27 18:50:09 +09:30
Jon
7c62643c6c feat(access): Enforce view action and HTTP/Method match for permission checks
ref: #442 #456
2024-12-27 18:26:58 +09:30
Jon
10becacbf7 fix(access): Add HTTP/Method=DELETE as valid option for object delete/destroy.
ref: #442 #454
2024-12-26 15:31:02 +09:30
Jon
534186a7f9 fix(access): Ensure Object permission are checked when an object is having an action performed against it.
ref: #442 #454
2024-12-26 14:11:05 +09:30
Jon
4be1e97cbe refactor(access): Object permission checking moved to has_object_permission function
ref: #442 #454
2024-12-26 00:49:40 +09:30
Jon
f2181b018d refactor(access): move ability to get required permissions from permissions mixin to organization mixin
ref: #442 #454
2024-12-26 00:33:21 +09:30
Jon
96ff5bd839 refactor(access): Organization Permission Mixin now caters for API ONLY
ref: #442 #454
2024-12-25 20:57:45 +09:30
Jon
d61929adaa refactor(access): Organization Mixin now caters for API ONLY
ref: #442 #454
2024-12-25 20:57:31 +09:30
Jon
bc1600e07b fix(access): Team User permission organiztion is team org
ref: #442 #454
2024-12-25 19:04:19 +09:30
Jon
2c715d69fa test(access): When adding org, test case must use non-super user
ref: #442 #454
2024-12-25 19:02:04 +09:30
Jon
dcd9e91dd9 refactor(base): move model calling of clean to tenancy model class
ref: #426 #433
2024-12-21 17:58:13 +09:30
Jon
63d44ed6e8 feat(information_management): Ability to link Knowledge Base article to a Team
ref: #426 #427
2024-12-21 17:06:05 +09:30
Jon
18769635ff feat(information_management): Ability to link Knowledge Base article to an Organization
ref: #426 #427
2024-12-21 17:05:46 +09:30
Jon
c649dc7669 test(base): Ensure Models inherit from Tenancy and SaveHistory Classes
ref: #426
2024-12-20 13:22:43 +09:30
Jon
cc98966a76 feat(access): Add project_management permissions to teams avail permissions
ref: #421
2024-12-19 13:40:27 +09:30
Jon
c14ee4c4be feat(api): If global organization defined, filter from ALL organization fields
This field is not intended to be selectable

ref: #418 closes #406
2024-12-09 22:29:57 +09:30
Jon
41ffe5b3bc refactor(access): Settings must be an available permissions when setting team permissions
ref: #408 #417
2024-12-06 17:06:38 +09:30