articles page
This commit is contained in:
SDE
2023-10-05 19:27:57 +03:00
parent 5f71eb5e0b
commit c781453055
3 changed files with 17 additions and 14 deletions

View File

@@ -21,7 +21,7 @@ def get_articles(art_kwargs, request_Data=None, from_el=None, to_el=None):
arts = arts[:to_el]
else:
to_el = 3
arts = arts[:3]
arts = arts[:to_el]
last_block = False
if not to_el or to_el >= el_count:

View File

@@ -2,6 +2,7 @@
<div class="news_block_pagination">
{% for art in articles %}
{% if from_el and forloop.counter > from_el %}
<div class="news_item_pagination">
<div class="pag_news_img"><img src="{{ MEDIA_URL }}{{ art.picture }}" /></div>
<div class="pag_news_item_text">
@@ -14,6 +15,7 @@
<div class="clear_both"></div>
</div>
{% endif %}
{#<div>{{ art.text|safe }}</div>#}
{% endfor %}
</div>

View File

@@ -29,8 +29,9 @@
{% endfor %}
</div>
{% with from_el=3 %}
{% include 'blocks/static_pages_blocks/b_news_elements.html' %}
{% endwith %}
{% if last_block == False %}
<div class="text-align-center w-68 f-r">