misc: don't include "enable" action on readonly forms (#4960)
This commit is contained in:
parent
f7c1315323
commit
a42f6aa10c
|
@ -142,6 +142,8 @@ class FieldsDirectory(FieldsDirectory):
|
|||
readonly_message = N_('This form is readonly.')
|
||||
|
||||
def index_bottom(self):
|
||||
if self.objectdef.is_readonly():
|
||||
return
|
||||
if hasattr(self.objectdef, str('disabled')) and self.objectdef.disabled:
|
||||
r = TemplateIO(html=True)
|
||||
r += htmltext('<div class="warningnotice">')
|
||||
|
|
Loading…
Reference in New Issue