Add Form.show_cancel
flag, for hiding that button
also use fields from schema by default, if fields not provided
This commit is contained in:
parent
22d9981c2e
commit
6cc509f5b4
2 changed files with 6 additions and 1 deletions
tailbone/templates/forms2
|
@ -76,7 +76,9 @@ ${h.csrf_token(request)}
|
|||
## % if form.creating and form.allow_successive_creates:
|
||||
## ${h.submit('create_and_continue', form.successive_create_label)}
|
||||
## % endif
|
||||
${h.link_to("Cancel", form.cancel_url, class_='button autodisable')}
|
||||
% if getattr(form, 'show_cancel', True):
|
||||
${h.link_to("Cancel", form.cancel_url, class_='button autodisable')}
|
||||
% endif
|
||||
</div>
|
||||
% endif
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue