правки в верстке, добавлена страница "О нас"
This commit is contained in:
parent
26f1ab89d6
commit
237dbd031b
BIN
db/moona_data.db
BIN
db/moona_data.db
Binary file not shown.
14
main.py
14
main.py
@ -418,15 +418,6 @@ def recovery():
|
||||
if finish.validate_on_submit():
|
||||
db_sess = db_session.create_session()
|
||||
user = db_sess.query(User).filter(User.email == user_email).first()
|
||||
# user2 = User(
|
||||
# name=user.name,
|
||||
# surname=user.surname,
|
||||
# login=user.login,
|
||||
# age=user.age,
|
||||
# about=user.about,
|
||||
# email=user_email,
|
||||
# photo=user.photo,
|
||||
# role='user')
|
||||
user.set_password(finish.password.data)
|
||||
user2 = session.merge(user)
|
||||
session.add(user2)
|
||||
@ -436,6 +427,11 @@ def recovery():
|
||||
return render_template('recovery.html', title='Восстановление пароля', form=form, message='', s='1')
|
||||
|
||||
|
||||
@app.route('/about_us')
|
||||
def about():
|
||||
return render_template('about.html', title='О нас')
|
||||
|
||||
|
||||
def main():
|
||||
db_session.global_init("db/moona_data.db")
|
||||
app.run()
|
||||
|
||||
0
static/css/about.css
Normal file
0
static/css/about.css
Normal file
@ -8,12 +8,36 @@ height: 55%;
|
||||
-webkit-border-radius:22px;
|
||||
-moz-border-radius: 22px;
|
||||
border-radius: 22px;
|
||||
border:2px solid #FFFFFF;
|
||||
border:2px solid #ffffff;
|
||||
margin-top: 20px;
|
||||
}
|
||||
.bad_centre {
|
||||
text-align: center;
|
||||
}
|
||||
summary {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
.pos_emot {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
.nig_emot {
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
.my_author {
|
||||
width:148px;
|
||||
height:44px;
|
||||
left:255px;
|
||||
-webkit-border-radius: 22px;
|
||||
-moz-border-radius: 22px;
|
||||
border-radius: 22px;
|
||||
border:2px;
|
||||
solid #ffffff;
|
||||
background-color:#1daff0;
|
||||
top: 98px;
|
||||
}
|
||||
.emot {
|
||||
margin-bottom: 30px;
|
||||
}
|
||||
#image {
|
||||
width: 70%;
|
||||
}
|
||||
@ -91,7 +115,7 @@ margin-left: 10px;
|
||||
}
|
||||
.is_ans {
|
||||
background-color:#ddefff;
|
||||
border:2px solid #FFFFFF;
|
||||
border:2px solid #ffffff;
|
||||
border-radius: 25px;
|
||||
}
|
||||
.emot_block {
|
||||
|
||||
@ -2,10 +2,10 @@
|
||||
margin-left: auto;
|
||||
margin-right: auto;
|
||||
width: 50%;
|
||||
}
|
||||
.add_q {
|
||||
width: 50%;
|
||||
}
|
||||
}
|
||||
.h_q {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
6
templates/about.html
Normal file
6
templates/about.html
Normal file
@ -0,0 +1,6 @@
|
||||
<link rel="stylesheet" href="../static/css/about.css">
|
||||
{% extends "base.html" %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
{% endblock %}
|
||||
@ -34,7 +34,7 @@
|
||||
</a>
|
||||
</ul>
|
||||
<ul class="navbar-nav">
|
||||
<a class="navbar-brand" href="/about">
|
||||
<a class="navbar-brand" href="/about_us">
|
||||
<h2 style="color:#56a3ff">О нас</h2>
|
||||
</a>
|
||||
</ul>
|
||||
|
||||
@ -31,13 +31,11 @@
|
||||
<summary class="emot_block">
|
||||
<strong class="emot_block">Позитивные эмоции</strong>
|
||||
</summary>
|
||||
<p></p>
|
||||
{% for item2 in emotion_pub[loop.index0]['pos_emot'] %}
|
||||
<strong class="alert alert-success" role="alert" style="border-radius: 22px;">{{item2}}</strong>
|
||||
{% endfor %}
|
||||
</details>
|
||||
</div>
|
||||
<p></p>
|
||||
{% endif %}
|
||||
{% if emotion_pub[loop.index0]['nig_emot'] != None %}
|
||||
<div class="nig_emot">
|
||||
@ -51,31 +49,25 @@
|
||||
{% endfor %}
|
||||
</details>
|
||||
</div>
|
||||
<p></p>
|
||||
{% endif %}
|
||||
{% if item.photo != None %}
|
||||
<p></p>
|
||||
<div class="photo">
|
||||
<img width="90%" src="{{ item.photo }}"
|
||||
style="border-radius: 22px;">
|
||||
</div>
|
||||
<p></p>
|
||||
{% endif %}
|
||||
{% if emotion_pub[loop.index0]['link'] != None %}
|
||||
<details>
|
||||
<summary class="emot_block">
|
||||
<strong class="emot_block">Ссылки</strong>
|
||||
</summary>
|
||||
<p></p>
|
||||
{% for item2 in emotion_pub[loop.index0]['link'] %}
|
||||
<div class="link">
|
||||
<a class="alert alert-light" role="alert" href="{{ item2 }}" style="border-radius: 22px;">Ссылка
|
||||
{{ loop.index }}</a>
|
||||
</div>
|
||||
<p></p>
|
||||
{% endfor %}
|
||||
</details>
|
||||
<p></p>
|
||||
{% endif %}
|
||||
{% if item.public == 1 or item.public == 'True' %}
|
||||
<div style="border-radius: 22px;" class="alert alert-success pub" role="alert">Запись
|
||||
@ -86,9 +78,7 @@
|
||||
приватная
|
||||
</div>
|
||||
{% endif %}
|
||||
<div class="my_author" style="style=position:absolute; width:148px; height:44px; left:255px; -webkit-border-radius:
|
||||
22px;-moz-border-radius: 22px;border-radius: 22px; border:2px solid #FFFFFF; background-color:#1daff0; top:
|
||||
98px;"><img src="../{{ current_user.photo }}" width="40" height="40" style="border-radius: 22px">
|
||||
<div class="my_author"><img src="../{{ current_user.photo }}" width="40" height="40" style="border-radius: 22px">
|
||||
<strong style="color: #ffffff">{{ current_user.name }}</strong>
|
||||
</div>
|
||||
<strong style="color:#ffffff">{{item.date}}</strong>
|
||||
@ -130,13 +120,13 @@
|
||||
<summary class="emot_block">
|
||||
<strong class="emot_block">Позитивные эмоции</strong>
|
||||
</summary>
|
||||
<p></p>
|
||||
<ul style="list-style-type: none">
|
||||
{% for item2 in emotion[loop.index0]['pos_emot'] %}
|
||||
<strong class="alert alert-success" role="alert" style="border-radius: 22px;">{{item2}}</strong>
|
||||
<li><div class="emot"><strong class="alert alert-success" role="alert" style="border-radius: 22px;">{{item2}}</strong></div></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</details>
|
||||
</div>
|
||||
<p></p>
|
||||
{% endif %}
|
||||
{% if emotion[loop.index0]['nig_emot'] != None %}
|
||||
<div class="nig_emot">
|
||||
@ -144,37 +134,32 @@
|
||||
<summary class="emot_block">
|
||||
<strong class="emot_block">Негативные эмоции</strong>
|
||||
</summary>
|
||||
<p></p>
|
||||
<ul style="list-style-type: none">
|
||||
{% for item2 in emotion[loop.index0]['nig_emot'] %}
|
||||
<strong class="alert alert-danger" role="alert" style="border-radius: 22px;">{{item2}}</strong>
|
||||
<li><div class="emot"><strong class="alert alert-danger" role="alert" style="border-radius: 22px;">{{item2}}</strong></div></li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
</details>
|
||||
</div>
|
||||
<p></p>
|
||||
{% endif %}
|
||||
{% if item.photo != None %}
|
||||
<p></p>
|
||||
<div class="photo">
|
||||
<img width="90%" src="{{ item.photo }}"
|
||||
style="border-radius: 22px;">
|
||||
</div>
|
||||
<p></p>
|
||||
{% endif %}
|
||||
{% if emotion[loop.index0]['link'] != None %}
|
||||
<details>
|
||||
<summary class="emot_block">
|
||||
<strong class="emot_block">Ссылки</strong>
|
||||
</summary>
|
||||
<p></p>
|
||||
{% for item2 in emotion[loop.index0]['link'] %}
|
||||
<div class="link">
|
||||
<a class="alert alert-light" role="alert" href="{{ item2 }}" style="border-radius: 22px;">Ссылка
|
||||
{{ loop.index }}</a>
|
||||
</div>
|
||||
<p></p>
|
||||
{% endfor %}
|
||||
</details>
|
||||
<p></p>
|
||||
{% endif %}
|
||||
{% if item.public == 1 or item.public == 'True' %}
|
||||
<div style="border-radius: 22px;" class="alert alert-success pub" role="alert">Запись
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user