##// END OF EJS Templates
Fixed validation of image without text. This refs #13
Fixed validation of image without text. This refs #13

File last commit:

r76:604015c5 default
r77:30874aa0 default
Show More
thread.html
104 lines | 3.7 KiB | text/html | HtmlLexer
neko259
Added a page to view the thread.
r20 {% extends "base.html" %}
neko259
Added localization (not fully working). Added tags posting. Changed the design a bit.
r24 {% load i18n %}
neko259
Changed themes.
r36 {% load markup %}
neko259
Added localization (not fully working). Added tags posting. Changed the design a bit.
r24
neko259
Fixed medadata design when an image is present. Added a method to determine if the tag is empty (has no attached threads).
r33 {% block head %}
neko259
#29 Added a thread title to the page title. #31 Added a panel to the page bottom.
r44 <title>Neboard - {{ posts.0.title }}</title>
neko259
Fixed medadata design when an image is present. Added a method to determine if the tag is empty (has no attached threads).
r33 {% endblock %}
neko259
Added a page to view the thread.
r20 {% block content %}
neko259
#37 Added javascript gallery mode for viewing thread in image-only mode.
r66 <script src="{{ STATIC_URL }}js/thread.js"></script>
neko259
Added a page to view the thread.
r20
{% if posts %}
neko259
#37 Added javascript gallery mode for viewing thread in image-only mode.
r66 <div id="posts">
neko259
Added a page to view the thread.
r20 {% for post in posts %}
neko259
#44 Show last replies in the threads list.
r59 {% if posts.0.can_bump %}
<div class="post" id="{{ post.id }}">
{% else %}
<div class="post dead_post" id="{{ post.id }}">
{% endif %}
neko259
Added images upload. Changed the design a bit. Reformatted some code by PEP 8. Changed the urls: not the main site is located at /, not /boards/.
r22 {% if post.image %}
neko259
Updated the Snow White theme. Scroll to the new post after posting to thread.
r41 <div class="image">
neko259
Added js popup for image viewing.
r63 <a
class="fancy"
href="{{ post.image.url }}"><img
neko259
Added images upload. Changed the design a bit. Reformatted some code by PEP 8. Changed the urls: not the main site is located at /, not /boards/.
r22 src="{{ post.image.url_200x150 }}" />
</a>
</div>
{% endif %}
neko259
Updated the Snow White theme. Scroll to the new post after posting to thread.
r41 <div class="message">
neko259
#44 Show last replies in the threads list.
r59 <div class="post-info">
<span class="title">{{ post.title }}</span>
<a class="post_id" href="#{{ post.id }}">
(#{{ post.id }})</a>
[{{ post.pub_time }}]
{% if post.is_get %}
<span class="get">
{% trans "Get!" %}
</span>
{% endif %}
</div>
neko259
Added new markdown field. Added gets algorithm with regexes.
r39 {% autoescape off %}
{{ post.text.rendered }}
{% endautoescape %}
neko259
Added images upload. Changed the design a bit. Reformatted some code by PEP 8. Changed the urls: not the main site is located at /, not /boards/.
r22 </div>
neko259
Fixed medadata design when an image is present. Added a method to determine if the tag is empty (has no attached threads).
r32 {% if post.tags.all %}
<div class="metadata">
<span class="tags">{% trans 'Tags' %}:
{% for tag in post.tags.all %}
<a class="tag" href="{% url 'tag' tag.name %}">
{{ tag.name }}</a>
{% endfor %}
</span>
</div>
{% endif %}
neko259
Added maximum threads count parameter to the settings. Delete the old posts to preserve the max count. Small design tweaks.
r28 </div>
neko259
Added a page to view the thread.
r20 {% endfor %}
neko259
#37 Added javascript gallery mode for viewing thread in image-only mode.
r66 </div>
neko259
Added a page to view the thread.
r20 {% else %}
neko259
#37 Added javascript gallery mode for viewing thread in image-only mode.
r66 No thread found.
neko259
Added a page to view the thread.
r20 <hr />
{% endif %}
neko259
#32 Changed "view" link to "reply". The thread can be opened at the top by clicking its id.
r45 <form id="form" enctype="multipart/form-data" method="post"
>{% csrf_token %}
neko259
Changed themes.
r36 <div class="post-form-w">
neko259
Implemented bumplimit.
r38 <div class="form-title">{% trans "Reply to thread" %}</div>
neko259
Changed themes.
r36 <div class="post-form">
<div class="form-row">
<div class="form-label">{% trans 'Title' %}</div>
<div class="form-input">{{ form.title }}</div>
neko259
Merged with the old validation changes.
r75 <div class="form-errors">{{ form.title.errors }}</div>
neko259
Changed themes.
r36 </div>
<div class="form-row">
<div class="form-label">{% trans 'Text' %}</div>
<div class="form-input">{{ form.text }}</div>
neko259
Merged with the old validation changes.
r75 <div class="form-errors">{{ form.text.errors }}</div>
neko259
Changed themes.
r36 </div>
<div class="form-row">
<div class="form-label">{% trans 'Image' %}</div>
<div class="form-input">{{ form.image }}</div>
neko259
Merged with the old validation changes.
r75 <div class="form-errors">{{ form.image.errors }}</div>
neko259
Changed themes.
r36 </div>
neko259
Added maximum threads count parameter to the settings. Delete the old posts to preserve the max count. Small design tweaks.
r28 </div>
neko259
Changed themes.
r36 <div class="form-submit"><input type="submit"
value="{% trans "Post" %}"/></div>
<div>Use <a
href="http://daringfireball.net/projects/markdown/basics">
markdown</a> syntax for posting.</div>
<div>Example: *<i>italic</i>*, **<b>bold</b>**</div>
<div>Insert quotes with "&gt;"</div>
</div>
</form>
neko259
Added a page to view the thread.
r20
neko259
Implemented bumplimit.
r38 {% endblock %}
neko259
#29 Added a thread title to the page title. #31 Added a panel to the page bottom.
r44
{% block metapanel %}
<span class="metapanel">
{{ posts.0.get_reply_count }} {% trans 'replies' %},
neko259
Limit number of tags shown in the navigation bar to only the most popular ones.
r57 {{ posts.0.get_images_count }} {% trans 'images' %}.
{% trans 'Last update: ' %}{{ posts.0.last_edit_time }}
neko259
#29 Added a thread title to the page title. #31 Added a panel to the page bottom.
r44 </span>
{% endblock %}