part_problems.html 1.32 KB
Newer Older
1
<table class="table table-bordered table-hover" id="problem-table">
Kento HASEGAWA's avatar
Kento HASEGAWA committed
2 3 4
    <thead>
        <tr>
            <th class="large-cell">File Name</th>
5 6
            <th class="small-cell">
                Size<br />
Kento HASEGAWA's avatar
Kento HASEGAWA committed
7
                #B/#L/#G/#N
8 9 10
            </th>
            <!-- <th class="small-cell">B/L/G</th> -->
            <th class="small-cell">Status</th>
Kento HASEGAWA's avatar
Kento HASEGAWA committed
11 12 13
        </tr>
    </thead>
    <tbody>
14
        {% for k, v in problems.items() %}
15 16 17 18 19 20 21 22 23
        {% set tr_class = '' %}
        {% if v.status == 'Saved' %}
            {% set tr_class = 'solution-saved' %}
        {% elif v.status.startswith('Solved') %}
            {% set tr_class = 'solution-solved' %}
        {% elif v.status.startswith('Tried') %}
            {% set tr_class = 'solution-tried' %}
        {% endif %}
        <tr class="problem-row {{tr_class}}" data-problem="{{v.name}}">
Kento HASEGAWA's avatar
Kento HASEGAWA committed
24
            <td class="large-cell">{{v.name}}</td>
25
            <td class="small-cell">
26
                {{v.size_str}} [{{'{:,.1f}%'.format(v.filling_rate * 100)}}]<br />
27 28
                {{v.block_num}} /
                {{v.line_numbers | length - 1}} /
Kento HASEGAWA's avatar
Kento HASEGAWA committed
29 30
                {{v.block_groups | length}} /
                {{v.null_blocks | length}}
31 32
            </td>
            <td class="small-cell">{{v.status}}</td>
Kento HASEGAWA's avatar
Kento HASEGAWA committed
33 34 35 36
        </tr>
        {% endfor %}
    </tbody>
</table>