17 Commits

Author SHA1 Message Date
OCA-git-bot
b703c619bc Merge PR #120 into 12.0
Signed-off-by dreispt
2021-04-26 16:46:34 +00:00
Sylvain LE GAL
0709376620 [FIX] base_user_role : affect correct default category, when creating the related group 2021-04-26 15:58:36 +02:00
Sylvain LE GAL
612f648fdf [IMP] base_user_role : prevent errors if users are not accessible by ACL, when updating roles 2021-04-20 13:05:18 +02:00
Andrius Laukavičius
115aba15df [FIX] base_user_role: default user multi-company
When creating user, default roles are using `base.default_user`, which
in multi-company case, can be from different company than user is being
created for. If thats the case, user creating another user, will get
access error, when trying to read default template user.

To work around that, we use sudo, to make sure, template user data can
be read regardless of a company.

Also improved the way base_user_role tests are run. Changed base test
class from TransactionCase to SavepointCase.

From how tests are ran perspective, both classes behave the same: each
test uses set up which is roll backed after.

But the difference is that SavepointCase case is much faster, because
it calls setUpClass once and saves this case for all tests (reusing
saved state).
2020-12-16 20:12:49 +02:00
Kevin Khao
588e8e0daa [IMP] base_user_role: Added multicompany support from commit server-tool repo commit 840c2c1119460424230c935da24ec42f95c21122 2020-03-06 16:59:08 +01:00
Kevin Khao
d64b4123a9 [IMP] base_user_role: black 2020-03-04 10:49:05 +01:00
Harald Panten
bfcf31add1 [IMP] base_user_role: Adding a new tab for user comments in roles form. 2019-12-09 18:25:12 +01:00
Jordi Ballester Alomar
300455f59d [base_user_role] improve performance by only adding/removing from a user
the groups that have changed with respecto the role.
2019-02-25 19:06:48 +07:00
Duc Dao
a34fb2eae4 [MIG] base_user_role: Migration to 12.0 2018-11-19 18:00:21 +01:00
Benjamin Willig
dcc76bd648 [IMP] Use default user to define default roles to create for a new user 2018-11-19 18:00:21 +01:00
sebalix
48703df707 [FIX+IMP] base_user_role: Several things:
* FIX: Update users' groups when a role is deleted
* IMP: add some test cases to check user's groups when its last role line is removed
* FIX: ensure that the user's groups are updated when its last role line is removed
2018-11-19 18:00:21 +01:00
Duc Dao
e63b03047b [MIG] base_user_role: Migration to 11.0 2018-11-19 18:00:21 +01:00
Benjamin Willig
03609673e7 [10.0][FIX] User group not updating when removing a user from the role view 2018-11-19 17:59:33 +01:00
Alexis de Lattre
44a20fcafc [FIX] Crash in base_user_role when role_id is not set on res.users.role.line 2018-11-19 17:59:33 +01:00
Adrien Peiffer (ACSONE)
439d324bde [MIG] base_user_role: Port to 10.0 2018-11-19 17:59:33 +01:00
sebalix
195a958e30 base_user_role - Set a default category to associated groups 2018-11-19 17:59:33 +01:00
Sébastien Alix
e0daffb241 8.0 - New module 'base_user_role' to manage user roles efficiently (#608)
* [ADD] New module 'base_user_role'

* [FIX] base_user_role - Review

* [FIX] base_user_role - Review s/is_active/is_enabled/

* [FIX] base_user_role - Review s/is_active/is_enabled/

* [IMP] base_user_role - Translations updated (template + FR)

* [FIX] base_user_role - Lint
2018-11-19 17:59:33 +01:00