{% extends "bee_django_mission/base.html" %}
{% load bee_django_mission_filter %}

{% block content %}
    <div class="text-center"><h3>
        阶段列表
    </h3>
    </div>
{#    <div class="text-right">#}
{#        <a class="btn btn-default" href="{% url 'bee_django_mission:stage_add' %}">添加阶段</a>#}
{#    </div>#}
    <table class="table">
        <thead>
        <tr>
            <th></th>
            <th>名称</th>
            <th>统计</th>

        </tr>
        </thead>
        <tbody>
        {% for stage in stage_list %}
            <tr>
                <td>{{ forloop.counter }}</td>
                <td>{{ stage.line.name }}-{{ stage.name }}</td>
                <td>学生任务分类</td>
                <td>
{#                    <a href="{% url 'bee_django_mission:stage_detail' stage.id %}  ">详情</a>#}
{#                    <a href="{% url 'bee_django_mission:stage_update' pk=stage.id %}  ">修改</a>#}
                    {#                    <a href="#" id="delete_{{ source.id }}"#}
                    {#                       data-confirm="{% url "bee_django_crm:source_delete" source.id %}"#}
                    {#                       onclick="click_del(this)">删除</a>#}
                </td>
            </tr>

        {% endfor %}
        </tbody>
    </table>
    {% include 'bee_django_mission/paginator.html' %}
{% endblock %}
{% block scripts %}
    <script>
{#        function click_del(_this) {#}
{#            if (!confirm('确认要执行这个操作？')) {#}
{#                return false;#}
{#            }#}
{#            var url = $(_this).attr('data-confirm');#}
{#            $.post(url).done(function (data) {#}
{#                alert('删除成功!');#}
{#                location.reload();#}
{#            });#}
{#        }#}
    </script>
{% endblock %}