This commit is contained in:
Anna Sudnitsina 2017-11-08 12:43:13 +03:00
parent dfe6c2ad56
commit 64eaab9d6b
6 changed files with 88 additions and 92 deletions

View File

@ -23,6 +23,14 @@ a {
letter-spacing: 1px; letter-spacing: 1px;
margin-right: 10px; margin-right: 10px;
} }
.delete {
right: 80px;
}
.edit {
position: absolute;
right: 10px;
bottom: 10px;
}
input#button-search { input#button-search {
background: url('https://touchit.com.ua/static/images/icons/search-25.png') no-repeat center center; background: url('https://touchit.com.ua/static/images/icons/search-25.png') no-repeat center center;
border: none; border: none;

View File

@ -5,10 +5,9 @@
<title>BLOG</title> <title>BLOG</title>
<link rel="stylesheet" href="{% static 'css/blog.css' %}"> <link rel="stylesheet" href="{% static 'css/blog.css' %}">
<link rel="stylesheet" href="{% static 'css/new.css' %}"> <link rel="stylesheet" href="{% static 'css/new.css' %}">
<meta charset="utf-8"><meta name=viewport content="width=device-width, initial-scale=1"> <meta charset="utf-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.3.0/css/font-awesome.min.css"> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.3.0/css/font-awesome.min.css">
<!--script src="https://code.jquery.com/jquery-1.12.4.js"></script> <script src="https://code.jquery.com/ui/1.12.0/jquery-ui.js"></script-->
<!--Let browser know website is optimized for mobile--> <meta name="viewport" content="width=device-width, initial-scale=1.0"/>
</head> </head>
<body> <body>
<div id="header"> <div id="header">
@ -24,8 +23,6 @@
{% block content %} {% block content %}
{% endblock %} {% endblock %}
<div class="sidemenu"> <div class="sidemenu">
Hop hey</div>
<div class="sidemenu">
<div class="block"> <div class="block">
<h2>Меню</h2> <h2>Меню</h2>
<ul> <ul>
@ -43,8 +40,6 @@ Hop hey</div>
</div> </div>
</div> </div>
</div> </div>
<ul class="menu_top paginator"> <ul class="menu_top paginator">
{% if posts.has_previous %} {% if posts.has_previous %}
<li> <a href="?page=1"><<</a> </li> <li> <a href="?page=1"><<</a> </li>

View File

@ -10,7 +10,6 @@
{% endfor %} {% endfor %}
{% endif %} {% endif %}
</h3> </h3>
<p>{{ post.text|safe|linebreaksbr }}</p> <p>{{ post.text|safe|linebreaksbr }}</p>
<span> <span>
{% if post.published_date %} {% if post.published_date %}
@ -18,8 +17,8 @@
{% endif %} {% endif %}
</span> </span>
<span class="edit" style="position: absolute; right: 10px; bottom: 10px;"><a href="{% url 'post_edit' pk=post.pk %}">edit post</a></span> <span class="edit"><a href="{% url 'post_edit' pk=post.pk %}">edit post</a></span>
<span class="edit" style="position: absolute; right: 80px; bottom: 10px;"><a href='#deletionDialog';">delete</a></span> <span class="edit delete"><a href='#deletionDialog';">delete</a></span>
<div id="deletionDialog" class="dialog"> <div id="deletionDialog" class="dialog">
<div> <div>
<p align="right"><a href=""><img src="http://py.difrex.ru/media/images/x.PNG"></a></p> <p align="right"><a href=""><img src="http://py.difrex.ru/media/images/x.PNG"></a></p>

View File

@ -1,7 +1,7 @@
{% extends 'blog/base.html' %} {% extends 'blog/base.html' %}
{% load pagination_tags %} {% load pagination_tags %}
{% block content %}
{% block content %}
<div id="posts"> <div id="posts">
{% for post in posts %} {% for post in posts %}
<div class="post"> <div class="post">
@ -19,7 +19,6 @@
</div> </div>
{{ post.text|safe|linebreaksbr|truncatewords:80 }} <!--|linebreaksbr|truncatewords:80 }}</p--><br> {{ post.text|safe|linebreaksbr|truncatewords:80 }} <!--|linebreaksbr|truncatewords:80 }}</p--><br>
</div> </div>
{% endfor %} {% endfor %}
</div> </div>
{% endblock content %} {% endblock content %}

View File

@ -1,24 +1,19 @@
{% extends 'blog/base.html' %} {% extends 'blog/base.html' %}
{% load pagination_tags %} {% load pagination_tags %}
{% block content %}
{% block content %}
{% for post in tagged_posts %} {% for post in tagged_posts %}
<div class="block post"> <div class="block post">
<h1><a href="{% url 'post_detail' pk=post.pk %}">{{ post.title }}</a></h1> <h1><a href="{% url 'post_detail' pk=post.pk %}">{{ post.title }}</a></h1>
{{ post.text|safe|linebreaksbr|truncatewords:80 }} <!--|linebreaksbr|truncatewords:80 }}</p--><br>
{{ post.text|safe|linebreaksbr|truncatewords:80 }} <!--|linebreaksbr|truncatewords:80 }}</p-->
<br>
<p style="float: left; color: #1abc9c; font-style: italic;"> Tags: <p style="float: left; color: #1abc9c; font-style: italic;"> Tags:
{% for tag in post.tags.names %} {% for tag in post.tags.names %}
<a href="{% url 'search_by_tag' tag=tag%}" style="color: #1abc9c; ">{{ tag }}</a> <a href="{% url 'search_by_tag' tag=tag%}" style="color: #1abc9c; ">{{ tag }}</a>
{% endfor %} {% endfor %}
</p> </p>
<p align="right"> <p align="right">
{{ post.published_date}} {{ post.published_date}}
</p> </p>
</div> </div>
{% endfor %} {% endfor %}
{% endblock content %} {% endblock content %}