mwielgoszewski/doorman

View on GitHub
doorman/templates/manage/tables/packs.html

Summary

Maintainability
Test Coverage
                <table class="table table-striped table-condensed">
                    <thead>
                        <tr>
                            <th>Pack</th>
                            <th>Platform</th>
                            <th>Version</th>
                            <th>Description</th>
                            <th>Shard</th>
                            <th>Queries</th>
                            <th>Tags</th>
                        </tr>
                    </thead>

                    <tbody>
                        {% for pack in packs %}

                        <tr>
                            <td>
                                <a href="{{ url_for('manage.packs', _anchor=pack.name) }}">{{ pack.name }}</a>
                            </td>
                            <td>{{ pack.platform or 'all' }}</td>
                            <td>{{ pack.version or '' }}</td>
                            <td>{{ pack.description or '' }}</td>
                            <td>{{ pack.shard or '' }}</td>
                            <td>{{ pack.queries | count }}</td>
                            <td>
                                <select multiple class="tagsinput" data-uri="{{ url_for('manage.tag_pack', pack_name=pack.name) }}"{% if not loop.index0 %} placeholder="Add tags by typing here"{% endif %}>
                                    {% for tag in pack.tags | sort(attribute='value') %}
                                    <option value="{{ tag.value }}">{{ tag.value }}</option>
                                    {% endfor %}
                                </select>
                            </td>
                        </tr>

                        {% endfor %}
                    </tbody>

                </table>