Only expose "Make User" button when viewing a person
i.e. don't expose when editing the person
This commit is contained in:
parent
a99b8c6aaf
commit
975aa0a3cc
|
@ -214,7 +214,7 @@ class PeopleView(MasterView):
|
||||||
items.append(HTML.tag('li', c=[tags.link_to(text, url)]))
|
items.append(HTML.tag('li', c=[tags.link_to(text, url)]))
|
||||||
if items:
|
if items:
|
||||||
return HTML.tag('ul', c=items)
|
return HTML.tag('ul', c=items)
|
||||||
elif self.request.has_perm('users.create'):
|
elif self.viewing and self.request.has_perm('users.create'):
|
||||||
if use_buefy:
|
if use_buefy:
|
||||||
return HTML.tag('button', type='button', class_='button is-primary',
|
return HTML.tag('button', type='button', class_='button is-primary',
|
||||||
id='make-user', c="Make User")
|
id='make-user', c="Make User")
|
||||||
|
|
Loading…
Reference in a new issue