You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
101 lines
4.4 KiB
101 lines
4.4 KiB
{% extends request.is_ajax|yesno:'nullcont.htm,abonapp/ext.htm' %}
|
|
{% load i18n %}
|
|
{% block content %}
|
|
|
|
<legend>{% trans 'Services of subscriber' %}</legend>
|
|
<table class="table table-striped table-bordered">
|
|
<thead>
|
|
<tr>
|
|
<th width="50">{% trans 'Priority' %}</th>
|
|
<th>{% trans 'Service' %}</th>
|
|
<th>{% trans 'Sum' %}</th>
|
|
<th>{% trans 'Input speed' %}</th>
|
|
<th>{% trans 'Output speed' %}</th>
|
|
<th>{% trans 'Time of action' %}</th>
|
|
<th>{% trans 'Edit' %}</th>
|
|
</tr>
|
|
</thead>
|
|
|
|
<tbody>
|
|
{% for trf in abon_tarifs %}
|
|
<tr{% if trf.id == active_abontariff_id %} class="active"{% endif %}>
|
|
<td>{{ trf.tariff_priority }}</td>
|
|
<td>
|
|
|
|
{% if perms.tariff_app.change_tariff %}
|
|
<a href="{% url 'tarifs:edit' trf.tariff.id %}" title="{{ trf.time_start|default:'' }}">
|
|
{{ trf.tariff.title }}
|
|
</a>
|
|
{% else %}
|
|
{{ trf.tariff.title }}
|
|
{% endif %}
|
|
|
|
</td>
|
|
<td>{{ trf.tariff.amount }}</td>
|
|
<td>{{ trf.tariff.speedIn }}</td>
|
|
<td>{{ trf.tariff.speedOut }}</td>
|
|
<td>{{ trf.tariff.time_of_action }}</td>
|
|
{% if trf.id != active_abontariff_id %}
|
|
<td class="btn-group">
|
|
|
|
{% if perms.abonapp.can_activate_service %}
|
|
{% if not active_abontariff_id %}
|
|
<a href="{% url 'abonapp:activate_service' abon_group.id abon.id trf.id %}"
|
|
class="btn btn-success btn-sm" title="{% trans 'Activate service' %}">
|
|
<i class="glyphicon glyphicon-shopping-cart"></i>
|
|
</a>
|
|
{% endif %}
|
|
{% endif %}
|
|
|
|
<!-- "{ % url 'abonapp:chpriority_tariff' abon_group.id abon.id % }?t={ { trf.id } }&a=up" -->
|
|
<a href="#"
|
|
class="btn btn-default btn-sm disabled" title="{% trans 'Priority up' %}">
|
|
<i class="glyphicon glyphicon-hand-up"></i>
|
|
</a>
|
|
|
|
<!-- "{ % url 'abonapp:chpriority_tariff' abon_group.id abon.id % }?t={ { trf.id } }&a=down" -->
|
|
<a href="#"
|
|
class="btn btn-default btn-sm disabled" title="{% trans 'Priority down' %}">
|
|
<i class="glyphicon glyphicon-hand-down"></i>
|
|
</a>
|
|
|
|
{% if perms.abonapp.delete_abontariff %}
|
|
<a href="{% url 'abonapp:unsubscribe_service' abon_group.id abon.id trf.id %}"
|
|
class="btn btn-danger btn-sm" title="{% trans 'Delete service' %}">
|
|
<i class="glyphicon glyphicon-remove"></i>
|
|
</a>
|
|
{% endif %}
|
|
</td>
|
|
{% else %}
|
|
<td>
|
|
<a href="{% url 'abonapp:compl_srv' abon_group.id abon.id trf.id %}" class="btn btn-danger btn-sm">
|
|
<i class="glyphicon glyphicon-remove"></i> {% trans 'Finish service' %}
|
|
</a>
|
|
</td>
|
|
{% endif %}
|
|
</tr>
|
|
{% empty %}
|
|
<tr>
|
|
<td colspan="7">{% trans 'Services of subscribers not found' %}.
|
|
{% if perms.abonapp.can_buy_tariff %}
|
|
<a href="{% url 'abonapp:pick_tariff' abon_group.id abon.id %}" class="lgtbx">{% trans 'Buy' %}</a>
|
|
{% endif %}
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
{% if perms.abonapp.can_buy_tariff %}
|
|
<tfoot>
|
|
<tr>
|
|
<th colspan="7">
|
|
<a href="{% url 'abonapp:pick_tariff' abon_group.id abon.id %}" class="btn btn-sm btn-success">
|
|
<span class="glyphicon glyphicon-plus"></span> {% trans 'Buy service' %}
|
|
</a>
|
|
</th>
|
|
</tr>
|
|
</tfoot>
|
|
{% endif %}
|
|
</table>
|
|
|
|
|
|
{% endblock %}
|