Skip to content
Snippets Groups Projects
Commit 2ffe5e4a authored by Daniil Digtyar Vasilieva's avatar Daniil Digtyar Vasilieva :call_me:
Browse files

Added get role codes to user

parent bc70de4a
No related branches found
No related tags found
1 merge request!7314 imp other endpoints
......@@ -177,3 +177,7 @@ class ResUsers(models.Model):
# yes, Keycloak sends back NOTHING on create
# so we are forced to do anothe call to get its data :(
return self._get_users(token, provider_id, search=data['username'])[0]
def get_role_codes(self):
#TODO Map all code to company and enable (We should update the API schema too)
return self.role_line_ids[0].role_id.code
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment