diff --git a/TODO b/TODO index d3a9501..5380931 100644 --- a/TODO +++ b/TODO @@ -10,7 +10,6 @@ TODO: * Need an admin contact in footer * Show recipes from non-software/base layers differently in recipes list * Submit layer form fixes: - * Layout for maintainers (js collapse?) * Captcha Later: diff --git a/layerindex/editlayer.html b/layerindex/editlayer.html index b0e717b..1653b0b 100644 --- a/layerindex/editlayer.html +++ b/layerindex/editlayer.html @@ -17,84 +17,119 @@ {% block content %} {% autoescape on %} +
+
+ {% block heading %} + + {% endblock %} + {% block formtag %} {% if form.was_saved %}
Changes saved successfully.
{% endif %} -
+ {% endblock %} {% csrf_token %} {% for hidden in form.hidden_fields %} {{ hidden }} {% endfor %} - {% for field in form.visible_fields %} -
+
+ {% for field in form.visible_fields %} + {% if field.errors %} +
{{ field.errors }} - {{ field.label_tag }} - {% if field.name = 'deps' %} -
- - {% for deplayer in deplistlayers %} - {% if deplayer.id in form.checked_deps %} - - - {% if deplayer.status = 'N' %} - - {% else %} - - {% endif %} - - {% endif %} - {% endfor %} - {% for deplayer in deplistlayers %} - {% if not deplayer.id in form.checked_deps %} - - - {% if deplayer.status = 'N' %} - - {% else %} - - {% endif %} - - {% endif %} - {% endfor %} -
-
{% else %} - {{ field }} +
{% endif %} - {{ field.help_text }} -
- {% endfor %} -

Maintainers

+
+ {{ field.label_tag }} +
+
+ {% if field.name = 'deps' %} +
+ + {% for deplayer in deplistlayers %} + {% if deplayer.id in form.checked_deps %} + + + {% if deplayer.status = 'N' %} + + {% else %} + + {% endif %} + + {% endif %} + {% endfor %} + {% for deplayer in deplistlayers %} + {% if not deplayer.id in form.checked_deps %} + + + {% if deplayer.status = 'N' %} + + {% else %} + + {% endif %} + + {% endif %} + {% endfor %} +
+
+ {% else %} + {{ field }} + {% endif %} + + {{ field.help_text }} + +
+
+ {% endfor %} +
+

Maintainers

{{ maintainerformset.non_form_errors }} {{ maintainerformset.management_form }} {% for maintainerform in maintainerformset %}
-

Maintainer {{forloop.counter}}

- {% for hidden in maintainerform.hidden_fields %} - {{ hidden }} - {% endfor %} +

Maintainer {{forloop.counter}}

+
+ {% for hidden in maintainerform.hidden_fields %} + {{ hidden }} + {% endfor %} - {% for field in maintainerform.visible_fields %} -
- {{ field.errors }} - {{ field.label_tag }} - {{ field }} - {{ field.help_text }} + {% for field in maintainerform.visible_fields %} + {% if field.errors %} +
+ {{ field.errors }} + {% else %} +
+ {% endif %} +
+ {{ field.label_tag }} +
+ {{ field }} + + {{ field.help_text }} + +
+ {% endfor %}
- {% endfor %}
{% endfor %} -

Add another maintainer

+

Add maintainer

+

{% block submitbuttons %} - + {% endblock %} +
+
+
+ {% endautoescape %} {% endblock %} diff --git a/layerindex/static/css/additional.css b/layerindex/static/css/additional.css index b4d5f3f..d5abfe8 100644 --- a/layerindex/static/css/additional.css +++ b/layerindex/static/css/additional.css @@ -59,9 +59,60 @@ h1 .btn { height: auto; max-height: 120px; overflow: auto; +width: 40.1709%; +border: 1px solid #DDDDDD; +padding: 8px; +} + +.scrolling td { + padding: 4px; +} + +.scrolling checkbox, label { + margin: 0px; +} + +.formfields input { + width: 50%; +} + +.formfields textarea { + width: 50%; +} + +#maintainers { + padding-top: 0.75em; +} + +.maintainerform { + /* Fix slight jumping at end of expand in Firefox */ + padding-top: 1px; +} + +.maintainerformfields input { + width: 25em; +} + +.custom-help { + margin-left: 10px; + max-width: 40%; + color: #999; + vertical-align:top; +} + +.errorlist { + color: #b94a48; + list-style-type: none; + margin-left: 0px; } .copyable { padding-left: 5px; padding-right: 3px; } + +.submitbuttons { + margin-top: 2em; + padding-top: 1em; + border-top: 1px solid rgb(238, 238, 238); +} diff --git a/layerindex/submitlayer.html b/layerindex/submitlayer.html index c4d7e0d..f83375d 100644 --- a/layerindex/submitlayer.html +++ b/layerindex/submitlayer.html @@ -14,16 +14,22 @@ {% block title %}OpenEmbedded metadata index - submit layer{% endblock %} --> + {% block heading %} + + {% endblock %} + + {% block submitlink %}
  • Submit layer
  • {% endblock %} - {% block formtag %} -
    + {% endblock %} {% block submitbuttons %} - + {% endblock %}