Mercurial > pub > site.implab
comparison shared_view/includes/dojo/form.tt @ 11:573272ec604b
almost comlete doxygen library
author | sergey |
---|---|
date | Thu, 15 May 2014 18:24:02 +0400 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
10:83ad674a8cdd | 11:573272ec604b |
---|---|
1 [% | |
2 BLOCK INIT; | |
3 document.dojo.modules.push("dijit/form/Form"); | |
4 END; | |
5 | |
6 FormResult = import('IMPL::Web::View::FormResult'); | |
7 Metadata = import('IMPL::Web::View::Metadata::FormMeta'); | |
8 | |
9 UNLESS is(model,FormResult); | |
10 THROW form 'The form result is required'; | |
11 END; | |
12 | |
13 # defaults | |
14 content = layout.content || 'form/group'; | |
15 enctype = enctype || 'application/x-www-form-urlencoded'; | |
16 method = method || 'POST'; | |
17 formMeta = Metadata.GetMetadataForModel(model.node, errors = model.errors, nodes = [model.node]); | |
18 %] | |
19 <form data-dojo-type="dijit/form/Form" class="form-control" method="$method" [% IF action %]action="$action" [% END %] enctype="$enctype"> | |
20 [% display_model(formMeta, content, layout.args) %] | |
21 </form> |