diff options
Diffstat (limited to 'themes/okadmin')
| -rw-r--r-- | themes/okadmin/templates/partials/inputs.liquid | 12 | ||||
| -rw-r--r-- | themes/okadmin/templates/resource.liquid | 2 |
2 files changed, 12 insertions, 2 deletions
diff --git a/themes/okadmin/templates/partials/inputs.liquid b/themes/okadmin/templates/partials/inputs.liquid index 2726473..ad5beab 100644 --- a/themes/okadmin/templates/partials/inputs.liquid +++ b/themes/okadmin/templates/partials/inputs.liquid @@ -16,7 +16,17 @@ {% if spec.disabled %} disabled="true" {% endif %} - name="{{name}}" rows="40" cols="80">{{spec.value}}</textarea> + name="{{name}}">{{spec.value}}</textarea> + {% else if type == 'enum' %} + <select + {% if spec.disabled %} + disabled="true" + {% endif %} + name="{{name}}"> + {% for option in spec.values %} + {{spec.value}} + {% endfor %} + </select> {% else %} <p><pre style="color: red">Admin template doesn't support '{{type}}' properties!</pre></p> {% endif %} diff --git a/themes/okadmin/templates/resource.liquid b/themes/okadmin/templates/resource.liquid index 2a6d2ce..26d62f2 100644 --- a/themes/okadmin/templates/resource.liquid +++ b/themes/okadmin/templates/resource.liquid @@ -5,7 +5,7 @@ </nav> <section class="resource main"> - <h2>EDIT {{ resource.type }} {{ resource.spec.title.id }}</h2> + <h2>EDIT {{ resource.type }} '{{ resource.spec.title.id }}'</h2> <form action="." method="POST"> <input type="hidden" name="_method" value="PUT"> {% include 'partials/inputs' %} |
