diff options
author | RaNaN <Mast3rRaNaN@hotmail.de> | 2011-07-12 23:42:11 +0200 |
---|---|---|
committer | RaNaN <Mast3rRaNaN@hotmail.de> | 2011-07-12 23:42:11 +0200 |
commit | c52ee8392501ee916d85fd9da75aa08a8f014493 (patch) | |
tree | 1cd802f64a1ffe0173473fd1f044e014bee59fff /module/web/templates/default/settings_item.html | |
parent | changed version strings (diff) | |
download | pyload-c52ee8392501ee916d85fd9da75aa08a8f014493.tar.xz |
removed server_methods, please test everything entirely
Diffstat (limited to 'module/web/templates/default/settings_item.html')
-rw-r--r-- | module/web/templates/default/settings_item.html | 84 |
1 files changed, 42 insertions, 42 deletions
diff --git a/module/web/templates/default/settings_item.html b/module/web/templates/default/settings_item.html index 593050bd2..92223557d 100644 --- a/module/web/templates/default/settings_item.html +++ b/module/web/templates/default/settings_item.html @@ -1,45 +1,45 @@ <table class="settable"> - {% for okey, option in section.iteritems() %} - {% if okey != "desc" %} - <tr> - <td><label for="{{skey}}|{{okey}}" - style="color:#424242;">{{ option.desc }}:</label></td> - <td> - {% if option.type == "bool" %} - <select id="{{skey}}|{{okey}}" name="{{skey}}|{{okey}}"> - <option {% if option.value %} selected="selected" - {% endif %}value="True">{{ _("on") }}</option> - <option {% if not option.value %} selected="selected" - {% endif %}value="False">{{ _("off") }}</option> - </select> - {% elif ";" in option.type %} - <select id="{{skey}}|{{okey}}" name="{{skey}}|{{okey}}"> - {% for entry in option.list %} - <option {% if option.value == entry %} - selected="selected" {% endif %}>{{ entry }}</option> - {% endfor %} - </select> - {% elif option.type == "folder" %} - <input name="{{skey}}|{{okey}}" type="text" - id="{{skey}}|{{okey}}" value="{{option.value}}"/> - <input name="browsebutton" type="button" - onclick="ifield = document.getElementById('{{skey}}|{{okey}}'); pathchooser = window.open('{% if option.value %}{{ "/pathchooser/" + option.value|quotepath }}{% else %}{{ pathroot }}{% endif %}', 'pathchooser', 'scrollbars=yes,toolbar=no,menubar=no,statusbar=no,width=650,height=300'); pathchooser.ifield = ifield; window.ifield = ifield;" - value="{{_("Browse")}}"/> - {% elif option.type == "file" %} - <input name="{{skey}}|{{okey}}" type="text" - id="{{skey}}|{{okey}}" value="{{option.value}}"/> - <input name="browsebutton" type="button" - onclick="ifield = document.getElementById('{{skey}}|{{okey}}'); filechooser = window.open('{% if option.value %}{{ "/filechooser/" + option.value|quotepath }}{% else %}{{ fileroot }}{% endif %}', 'filechooser', 'scrollbars=yes,toolbar=no,menubar=no,statusbar=no,width=650,height=300'); filechooser.ifield = ifield; window.ifield = ifield;" - value="{{_("Browse")}}"/> - {% elif option.type == "password" %} - <input id="{{skey}}|{{okey}}" name="{{skey}}|{{okey}}" - type="password" value="{{option.value}}"/> - {% else %} - <input id="{{skey}}|{{okey}}" name="{{skey}}|{{okey}}" - type="text" value="{{option.value}}"/> - {% endif %} - </td> - </tr> - {% endif %} + {% set skey = section.name %} + {% for option in section.items %} + {% set okey = option.name %} + <tr> + <td><label for="{{skey}}|{{okey}}" + style="color:#424242;">{{ option.description }}:</label></td> + <td> + {% if option.type == "bool" %} + <select id="{{skey}}|{{okey}}" name="{{skey}}|{{okey}}"> + <option {% if option.value %} selected="selected" + {% endif %}value="True">{{ _("on") }}</option> + <option {% if not option.value %} selected="selected" + {% endif %}value="False">{{ _("off") }}</option> + </select> + {% elif option.type|type == "<type 'list'>" %} + <select id="{{skey}}|{{okey}}" name="{{skey}}|{{okey}}"> + {% for entry in option.type %} + <option {% if option.value == entry %} + selected="selected" {% endif %}>{{ entry }}</option> + {% endfor %} + </select> + {% elif option.type == "folder" %} + <input name="{{skey}}|{{okey}}" type="text" + id="{{skey}}|{{okey}}" value="{{option.value}}"/> + <input name="browsebutton" type="button" + onclick="ifield = document.getElementById('{{skey}}|{{okey}}'); pathchooser = window.open('{% if option.value %}{{ "/pathchooser/" + option.value|quotepath }}{% else %}{{ pathroot }}{% endif %}', 'pathchooser', 'scrollbars=yes,toolbar=no,menubar=no,statusbar=no,width=650,height=300'); pathchooser.ifield = ifield; window.ifield = ifield;" + value="{{_("Browse")}}"/> + {% elif option.type == "file" %} + <input name="{{skey}}|{{okey}}" type="text" + id="{{skey}}|{{okey}}" value="{{option.value}}"/> + <input name="browsebutton" type="button" + onclick="ifield = document.getElementById('{{skey}}|{{okey}}'); filechooser = window.open('{% if option.value %}{{ "/filechooser/" + option.value|quotepath }}{% else %}{{ fileroot }}{% endif %}', 'filechooser', 'scrollbars=yes,toolbar=no,menubar=no,statusbar=no,width=650,height=300'); filechooser.ifield = ifield; window.ifield = ifield;" + value="{{_("Browse")}}"/> + {% elif option.type == "password" %} + <input id="{{skey}}|{{okey}}" name="{{skey}}|{{okey}}" + type="password" value="{{option.value}}"/> + {% else %} + <input id="{{skey}}|{{okey}}" name="{{skey}}|{{okey}}" + type="text" value="{{option.value}}"/> + {% endif %} + </td> + </tr> {% endfor %} </table>
\ No newline at end of file |