diff options
Diffstat (limited to 'ishtar_common/models.py')
-rw-r--r-- | ishtar_common/models.py | 35 |
1 files changed, 22 insertions, 13 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py index 13b7a4d2f..1ba1de7ec 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -4208,19 +4208,28 @@ class IshtarUser(FullSearch): def get_extra_actions(self, request): actions = [] - if request.user.ishtaruser.is_ishtaradmin: - actions += [ - ( - reverse("regenerate-permissions", args=[self.pk]), - _("Regenerate permissions"), - "fa fa-repeat", - _("regen."), - "btn-warning", - True, - 200, - ) - ] - + # for admin only + if not request.user.ishtaruser.is_ishtaradmin: + return actions + actions += [ + ( + reverse("regenerate-permissions", args=[self.pk]), + _("Regenerate permissions"), + "fa fa-repeat", + _("regen."), + "btn-warning", + True, + 200, + ), + ( + reverse("account-manage", args=[self.pk]), + _("Manage account"), + "fa fa-user", + "", + "", + False, + ), + ] return actions @post_importer_action |