Исправлены конфликты
This commit is contained in:
@@ -30,13 +30,17 @@
|
||||
table.paleblue tr.weekend {
|
||||
background-color: #FFE4E1
|
||||
}
|
||||
.inline {
|
||||
display: inline-block;
|
||||
vertical-align: top;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div class="breadcrumbs">
|
||||
{% block menu %}
|
||||
<ul id="menu" class="hr">
|
||||
<li><a href={% url 'asuzr-main' %}>Таблица посещаемости</a></li>
|
||||
<li><a href={% url 'asuzr.views.visit_view' %}>Таблица посещаемости</a></li>
|
||||
<li><a href={% url 'asuzr.views.orders' 0 %}>Таблица выхода заказов</a></li>
|
||||
<li><a href={% url 'asuzr.views.orders' 1 %}>Архивная таблица</a></li>
|
||||
<li><a href={% url 'asuzr.views.desreport' %}>Отчет по дизайнерам</a></li>
|
||||
|
||||
12
templates/asuzr/sketches.html
Normal file
12
templates/asuzr/sketches.html
Normal file
@@ -0,0 +1,12 @@
|
||||
{% extends "asuzr/table.html" %}
|
||||
|
||||
{% block additional %}
|
||||
<div class="inline">
|
||||
<form action="/sketches/{{ order_id }}/" method="POST" enctype="multipart/form-data">
|
||||
{% csrf_token %}
|
||||
<div>Добавить эскизы:</div>
|
||||
<input type="file" name="sketch_file" multiple />
|
||||
<input type="submit" text="Добавить эскиз">
|
||||
</form>
|
||||
</div>
|
||||
{% endblock %}
|
||||
@@ -3,6 +3,10 @@
|
||||
{% load render_table from django_tables2 %}
|
||||
|
||||
{% block page %}
|
||||
{% render_table table %}
|
||||
{% block table %}
|
||||
{% render_table table %}
|
||||
{% endblock %}
|
||||
{% block additional %}
|
||||
{% endblock %}
|
||||
{% endblock %}
|
||||
|
||||
|
||||
24
templates/asuzr/table2.html
Normal file
24
templates/asuzr/table2.html
Normal file
@@ -0,0 +1,24 @@
|
||||
{% extends "asuzr/base.html" %}
|
||||
{% load inplace_edit %}
|
||||
{% load render_table from django_tables2 %}
|
||||
|
||||
{% block page %}
|
||||
<div class="inline"><div><h3>{{ table1.verbose_name }}</h3></div>{% render_table table1 %}</div>
|
||||
<div class="inline"><div><h3>{{ table2.verbose_name }}</h3></div>{% render_table table2 %}</div>
|
||||
{% if additional_info %}
|
||||
<div>
|
||||
<hr>
|
||||
<div>
|
||||
<h3>{{ additional_info.title }}</h3>
|
||||
</div>
|
||||
<div class="table-container">
|
||||
<table class="paleblue">
|
||||
{% for row in additional_info.rows %}
|
||||
<tr><td>{{ row.title }}</td><td>{{ row.value }}</td></tr>
|
||||
{% endfor %}
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
||||
|
||||
15
templates/asuzr/totals_table.html
Normal file
15
templates/asuzr/totals_table.html
Normal file
@@ -0,0 +1,15 @@
|
||||
{% extends "django_tables2/table.html" %}
|
||||
{% load django_tables2 %}
|
||||
{% load i18n %}
|
||||
{% block table.tfoot %}
|
||||
<tfoot>
|
||||
{% if table.summary %}
|
||||
<tr>
|
||||
{% for summary in table.summary %}
|
||||
<td> {{ summary }} </td>
|
||||
{% endfor %}
|
||||
</tr>
|
||||
{% endif %}
|
||||
</tfoot>
|
||||
{% endblock table.tfoot %}
|
||||
|
||||
@@ -1,60 +1,14 @@
|
||||
{% spaceless %}
|
||||
{% extends "asuzr/totals_table.html" %}
|
||||
{% load django_tables2 %}
|
||||
{% load i18n %}
|
||||
{% if table.page %}
|
||||
<div class="table-container">
|
||||
{% endif %}
|
||||
{% block table %}
|
||||
<table{% if table.attrs %} {{ table.attrs.as_html }}{% endif %}>
|
||||
{% nospaceless %}
|
||||
{% block table.thead %}
|
||||
<thead>
|
||||
<tr>
|
||||
{% for column in table.columns %}
|
||||
{% if column.orderable %}
|
||||
<th {{ column.attrs.th.as_html }}><a href="{% querystring table.prefixed_order_by_field=column.order_by_alias.next %}">{{ column.header }}</a></th>
|
||||
{% else %}
|
||||
<th {{ column.attrs.th.as_html }}>{{ column.header }}</th>
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</tr>
|
||||
</thead>
|
||||
{% endblock table.thead %}
|
||||
{% block table.tbody %}
|
||||
<tbody>
|
||||
{% for row in table.page.object_list|default:table.rows %} {# support pagination #}
|
||||
{% block table.tbody.row %}
|
||||
<tr class="
|
||||
{% if row.date.is_weekend %}weekend{% else %}
|
||||
{{ forloop.counter|divisibleby:2|yesno:"even,odd" }}{% endif %}
|
||||
"> {# avoid cycle for Django 1.2-1.6 compatibility #}
|
||||
{% for column, cell in row.items %}
|
||||
<td {{ column.attrs.td.as_html }}>{% if column.localize == None %}{{ cell }}{% else %}{% if column.localize %}{{ cell|localize }}{% else %}{{ cell|unlocalize }}{% endif %}{% endif %}</td>
|
||||
{% endfor %}
|
||||
</tr>
|
||||
{% endblock table.tbody.row %}
|
||||
{% empty %}
|
||||
{% if table.empty_text %}
|
||||
{% block table.tbody.empty_text %}
|
||||
<tr><td colspan="{{ table.columns|length }}">{{ table.empty_text }}</td></tr>
|
||||
{% endblock table.tbody.empty_text %}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
{% endblock table.tbody %}
|
||||
{% block table.tfoot %}
|
||||
<tfoot>
|
||||
{% if table.summary %}
|
||||
<tr>
|
||||
{% for summary in table.summary %}
|
||||
<td> {{ summary }} </td>
|
||||
{% block table.tbody.row %}
|
||||
<tr class="
|
||||
{% if row.date.is_weekend %}weekend{% else %}
|
||||
{{ forloop.counter|divisibleby:2|yesno:"even,odd" }}{% endif %}
|
||||
"> {# avoid cycle for Django 1.2-1.6 compatibility #}
|
||||
{% for column, cell in row.items %}
|
||||
<td {{ column.attrs.td.as_html }}>{% if column.localize == None %}{{ cell }}{% else %}{% if column.localize %}{{ cell|localize }}{% else %}{{ cell|unlocalize }}{% endif %}{% endif %}</td>
|
||||
{% endfor %}
|
||||
</tr>
|
||||
{% endif %}
|
||||
</tfoot>
|
||||
{% endblock table.tfoot %}
|
||||
{% endnospaceless %}
|
||||
</table>
|
||||
{% endblock table %}
|
||||
</tr>
|
||||
{% endblock table.tbody.row %}
|
||||
|
||||
{% endspaceless %}
|
||||
|
||||
Reference in New Issue
Block a user