29 lines
1.2 KiB
HTML
29 lines
1.2 KiB
HTML
|
|
{% extends "base.html" %}
|
||
|
|
{% block title %}{{ post.title or ("Пост #" ~ post.id) }}{% endblock %}
|
||
|
|
|
||
|
|
{% block content %}
|
||
|
|
<article class="post-full">
|
||
|
|
<h2>{{ post.title or ("Пост #" ~ post.id) }}</h2>
|
||
|
|
<div class="meta">{{ post.created_at }} • #{{ post.id }}</div>
|
||
|
|
<div class="body">{{ markdown(post.body)|safe }}</div>
|
||
|
|
|
||
|
|
<div class="post-actions">
|
||
|
|
<form action="{{ url_for('vote', pid=post.id) }}" method="post" style="display:inline;">
|
||
|
|
<input type="hidden" name="vote" value="up">
|
||
|
|
<button type="submit">▲ {{ votes.ups }}</button>
|
||
|
|
</form>
|
||
|
|
<form action="{{ url_for('vote', pid=post.id) }}" method="post" style="display:inline;">
|
||
|
|
<input type="hidden" name="vote" value="down">
|
||
|
|
<button type="submit">▼ {{ votes.downs }}</button>
|
||
|
|
</form>
|
||
|
|
<span class="score">Score: {{ votes.score }}</span>
|
||
|
|
|
||
|
|
<form action="{{ url_for('flag_post', pid=post.id) }}" method="post" class="flag-form" style="display:inline;">
|
||
|
|
<input type="text" name="reason" placeholder="Пожаловаться..." />
|
||
|
|
<button type="submit">Flag ({{ flags }})</button>
|
||
|
|
</form>
|
||
|
|
</div>
|
||
|
|
|
||
|
|
<p><a href="{{ url_for('index') }}">← Назад в ленту</a></p>
|
||
|
|
</article>
|
||
|
|
{% endblock %}
|