Show More
@@ -103,7 +103,12 b' def display_user_sort(obj):' | |||||
103 | if obj.username == User.DEFAULT_USER: |
|
103 | if obj.username == User.DEFAULT_USER: | |
104 | return '#####' |
|
104 | return '#####' | |
105 | prefix = PERMISSION_TYPE_SORT.get(obj.permission.split('.')[-1], '') |
|
105 | prefix = PERMISSION_TYPE_SORT.get(obj.permission.split('.')[-1], '') | |
106 | return prefix + obj.username |
|
106 | extra_sort_num = '1' # default | |
|
107 | ||||
|
108 | # NOTE(dan): inactive duplicates goes last | |||
|
109 | if getattr(obj, 'duplicate_perm', None): | |||
|
110 | extra_sort_num = '9' | |||
|
111 | return prefix + extra_sort_num + obj.username | |||
107 |
|
112 | |||
108 |
|
113 | |||
109 | def display_user_group_sort(obj): |
|
114 | def display_user_group_sort(obj): |
@@ -33,6 +33,12 b' table.dataTable {' | |||||
33 | .rc-user { |
|
33 | .rc-user { | |
34 | white-space: nowrap; |
|
34 | white-space: nowrap; | |
35 | } |
|
35 | } | |
|
36 | .user-perm-duplicate { | |||
|
37 | color: @grey4; | |||
|
38 | a { | |||
|
39 | color: @grey4; | |||
|
40 | } | |||
|
41 | } | |||
36 | } |
|
42 | } | |
37 |
|
43 | |||
38 | .td-email { |
|
44 | .td-email { |
@@ -68,10 +68,15 b'' | |||||
68 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> |
|
68 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> | |
69 | % endif |
|
69 | % endif | |
70 | % else: |
|
70 | % else: | |
71 |
|
|
71 | % if getattr(_user, 'duplicate_perm', None): | |
72 |
|
|
72 | <span class="user-perm-duplicate"> | |
73 |
|
|
73 | ${h.link_to_user(_user.username)} | |
74 | %endif |
|
74 | <span class="tooltip" title="${_('This entry is a duplicate, most probably left-over from previously set permission. This user has a higher permission set, so this entry is inactive. Please revoke this permission manually.')}">(${_('inactive duplicate')}) | |
|
75 | </span> | |||
|
76 | </span> | |||
|
77 | % else: | |||
|
78 | ${h.link_to_user(_user.username)} | |||
|
79 | % endif | |||
75 | % endif |
|
80 | % endif | |
76 | </span> |
|
81 | </span> | |
77 | </td> |
|
82 | </td> | |
@@ -116,10 +121,15 b'' | |||||
116 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> |
|
121 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> | |
117 | % endif |
|
122 | % endif | |
118 | % else: |
|
123 | % else: | |
119 |
|
|
124 | % if getattr(_user, 'duplicate_perm', None): | |
120 |
|
|
125 | <span class="user-perm-duplicate"> | |
121 |
|
|
126 | ${h.link_to_user(_user.username)} | |
122 | %endif |
|
127 | <span class="tooltip" title="${_('This entry is a duplicate, most probably left-over from previously set permission. This user has a higher permission set, so this entry is inactive. Please revoke this permission manually.')}">(${_('inactive duplicate')}) | |
|
128 | </span> | |||
|
129 | </span> | |||
|
130 | % else: | |||
|
131 | ${h.link_to_user(_user.username)} | |||
|
132 | % endif | |||
123 | % endif |
|
133 | % endif | |
124 | <span class="user-perm-help-text">(${_('delegated admin')})</span> |
|
134 | <span class="user-perm-help-text">(${_('delegated admin')})</span> | |
125 | </span> |
|
135 | </span> |
@@ -94,10 +94,16 b'' | |||||
94 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> |
|
94 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> | |
95 | % endif |
|
95 | % endif | |
96 | % else: |
|
96 | % else: | |
97 |
|
|
97 | % if getattr(_user, 'duplicate_perm', None): | |
98 |
|
|
98 | <span class="user-perm-duplicate"> | |
99 |
|
|
99 | ${h.link_to_user(_user.username)} | |
100 | %endif |
|
100 | <span class="tooltip" title="${_('This entry is a duplicate, most probably left-over from previously set permission. This user has a higher permission set, so this entry is inactive. Please revoke this permission manually.')}">(${_('inactive duplicate')}) | |
|
101 | </span> | |||
|
102 | </span> | |||
|
103 | % else: | |||
|
104 | ${h.link_to_user(_user.username)} | |||
|
105 | % endif | |||
|
106 | ||||
101 |
|
|
107 | %if getattr(_user, 'branch_rules', None): | |
102 | % if used_by_n_rules == 1: |
|
108 | % if used_by_n_rules == 1: | |
103 | (${_('used by {} branch rule, requires write+ permissions').format(used_by_n_rules)}) |
|
109 | (${_('used by {} branch rule, requires write+ permissions').format(used_by_n_rules)}) |
@@ -74,10 +74,15 b'' | |||||
74 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> |
|
74 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> | |
75 | % endif |
|
75 | % endif | |
76 | % else: |
|
76 | % else: | |
77 |
|
|
77 | % if getattr(_user, 'duplicate_perm', None): | |
78 |
|
|
78 | <span class="user-perm-duplicate"> | |
79 |
|
|
79 | ${h.link_to_user(_user.username)} | |
80 | %endif |
|
80 | <span class="tooltip" title="${_('This entry is a duplicate, most probably left-over from previously set permission. This user has a higher permission set, so this entry is inactive. Please revoke this permission manually.')}">(${_('inactive duplicate')}) | |
|
81 | </span> | |||
|
82 | </span> | |||
|
83 | % else: | |||
|
84 | ${h.link_to_user(_user.username)} | |||
|
85 | % endif | |||
81 | % endif |
|
86 | % endif | |
82 | </span> |
|
87 | </span> | |
83 | </td> |
|
88 | </td> | |
@@ -122,10 +127,15 b'' | |||||
122 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> |
|
127 | <span class="user-perm-help-text"> - ${_('permission for other logged in users')}</span> | |
123 | % endif |
|
128 | % endif | |
124 | % else: |
|
129 | % else: | |
125 |
|
|
130 | % if getattr(_user, 'duplicate_perm', None): | |
126 |
|
|
131 | <span class="user-perm-duplicate"> | |
127 |
|
|
132 | ${h.link_to_user(_user.username)} | |
128 | %endif |
|
133 | <span class="tooltip" title="${_('This entry is a duplicate, most probably left-over from previously set permission. This user has a higher permission set, so this entry is inactive. Please revoke this permission manually.')}">(${_('inactive duplicate')}) | |
|
134 | </span> | |||
|
135 | </span> | |||
|
136 | % else: | |||
|
137 | ${h.link_to_user(_user.username)} | |||
|
138 | % endif | |||
129 | % endif |
|
139 | % endif | |
130 | <span class="user-perm-help-text">(${_('delegated admin')})</span> |
|
140 | <span class="user-perm-help-text">(${_('delegated admin')})</span> | |
131 | </span> |
|
141 | </span> |
General Comments 0
You need to be logged in to leave comments.
Login now