mwielgoszewski/doorman

View on GitHub
doorman/templates/manage/forms/file.html

Summary

Maintainability
Test Coverage
                <form class="form-horizontal" method="POST">
                    <fieldset>
                        {% if file_path is defined %}
                        <legend>update file path</legend>
                        {% else %}
                        <legend>add file path</legend>
                        {% endif %}
                        {{ form.csrf_token }}

                        <div class="form-group">
                            {{ form.category.label(class_="col-sm-2 control-label") }}
                            <div class="col-sm-10">
                                {{ form.category(class_="form-control") }}
                            </div>
                        </div>

                        <div class="form-group">
                            {{ form.target_paths.label(class_="col-sm-2 control-label") }}
                            <div class="col-sm-10">
                                {{ form.target_paths(placeholder="One file/directory glob pattern per line", class_="form-control") }}
                            </div>
                        </div>

                        <div class="form-group">
                            {{ form.tags.label(class_="col-sm-2 control-label") }}
                            <div class="col-sm-10">
                                {{ form.tags(placeholder="One tag per line", class_="form-control") }}
                            </div>
                        </div>

                        <div class="form-group"> 
                            <div class="col-sm-10 col-sm-offset-2">
                                <p><input class="btn-small btn-default btn-submit" type="submit" value="{% if file_path is defined %}update{% else %}add{% endif %} file path"></p>
                            </div>
                        </div>

                    </fieldset>

                </form>