Moved Save button to the bottom of the dialog.
@@ -32,13 +32,13 @@ class mp_form_helper(BaseFormHelper):
'</div><br>')
+
# Order of the Fields below determines their layout on the edit page
# For consistency, make sure this ordering matches models.py->get_xml()
field_width = 'form-control input-sm'
css_multichar = field_width + ' multichar'
layout = Layout(
HTML('<legend>Data</legend>'),
- HTML('<div class="col-sm-6 col-xs-12">'),
Field('modelEngine', css_class=css_multichar, style="display:none"),
multiselect['modelEngine'],
Field('modelSoftware', css_class=css_multichar, style="display:none"),
@@ -48,22 +48,17 @@ class mp_form_helper(BaseFormHelper):
Field('modelReleaseNotes', css_class=css_multichar, style="display:none"),
multiselect['modelReleaseNotes'],
HTML('<hr style="border:0">'),
- HTML('</div>'),
HTML('<legend>General</legend>'),
- HTML('<div class="col-sm-6 col-xs-12">'),
Field('modelReleaseDate', css_class=field_width, style="display:none"),
HTML('<input type="text" class="'+field_width+'" id="modelReleaseDate_picker">'),
Field('modelVersion', css_class=field_width),
HTML('<br>'),
HTML('<hr style="border:0">'),
- HTML('</div>'),
HTML('<legend>Software</legend>'),
- HTML('<div class="col-sm-6 col-xs-12">'),
Field('modelWebsite', css_class=field_width),
Field('modelProgramLanguage', css_class=field_width),
Field('modelOperatingSystem', css_class=field_width),
Field('modelCodeRepository', css_class=field_width),
- HTML('</div>'),
)
super(mp_form_helper, self).__init__(allow_edit, res_short_id, element_id, element_name, layout, element_name_label=' ', *args, **kwargs)
