feat: delete link button
This commit is contained in:
parent
edec9a627a
commit
3b9db5f0f6
@ -1,15 +1,18 @@
|
|||||||
{% extends 'base.html' %}
|
{% extends 'base.html' %}
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
{% if not user.is_authenticated %}
|
{% if user.is_authenticated and urls|length > 0 %}
|
||||||
{% include 'docs.html' %}
|
|
||||||
{% endif %}
|
|
||||||
{% for url in urls %}
|
{% for url in urls %}
|
||||||
<!-- Post preview-->
|
<!-- Post preview-->
|
||||||
<div class="post-preview">
|
<div class="post-preview">
|
||||||
<a href="{{ url.url }}">
|
<div class="d-flex justify-content-between">
|
||||||
<h2 class="post-title">{{ url.title }}</h2>
|
<div class="p-2">
|
||||||
</a>
|
<a href="{{ url.url }}"><h2 class="post-title">{{ url.title }}</h2></a>
|
||||||
|
</div>
|
||||||
|
<div class="p-2">
|
||||||
|
<a href="/delete/{{ url.id }}"><span class="fa-solid fa-trash"></span></a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<p class="post-meta">
|
<p class="post-meta">
|
||||||
{{ url.url }}
|
{{ url.url }}
|
||||||
</p>
|
</p>
|
||||||
@ -17,4 +20,11 @@
|
|||||||
<!-- Divider-->
|
<!-- Divider-->
|
||||||
<hr class="my-4" />
|
<hr class="my-4" />
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
|
{% elif user.is_authenticated %}
|
||||||
|
<div class="post-preview">
|
||||||
|
<h2 class="post-title">У вас нет сохраненных ссылок</h2>
|
||||||
|
</div>
|
||||||
|
{% elif not user.is_authenticated %}
|
||||||
|
{% include 'docs.html' %}
|
||||||
|
{% endif %}
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
Loading…
Reference in New Issue
Block a user