##// END OF EJS Templates
Fixed gallery view.
neko259 -
r172:701dedb4 default
parent child Browse files
Show More
@@ -1,118 +1,118 b''
1 {% extends "boards/base.html" %}
1 {% extends "boards/base.html" %}
2
2
3 {% load i18n %}
3 {% load i18n %}
4 {% load markup %}
4 {% load markup %}
5
5
6 {% block head %}
6 {% block head %}
7 <title>Neboard - {{ posts.0.get_title }}</title>
7 <title>Neboard - {{ posts.0.get_title }}</title>
8 <script src="{{ STATIC_URL }}js/thread.js"></script>
9 {% endblock %}
8 {% endblock %}
10
9
11 {% block content %}
10 {% block content %}
11 <script src="{{ STATIC_URL }}js/thread.js"></script>
12
12
13 {% if posts %}
13 {% if posts %}
14 <div id="posts">
14 <div id="posts">
15 {% for post in posts %}
15 {% for post in posts %}
16 {% if bumpable %}
16 {% if bumpable %}
17 <div class="post" id="{{ post.id }}">
17 <div class="post" id="{{ post.id }}">
18 {% else %}
18 {% else %}
19 <div class="post dead_post" id="{{ post.id }}">
19 <div class="post dead_post" id="{{ post.id }}">
20 {% endif %}
20 {% endif %}
21 {% if post.image %}
21 {% if post.image %}
22 <div class="image">
22 <div class="image">
23 <a
23 <a
24 class="fancy"
24 class="fancy"
25 href="{{ post.image.url }}"><img
25 href="{{ post.image.url }}"><img
26 src="{{ post.image.url_200x150 }}"
26 src="{{ post.image.url_200x150 }}"
27 alt="{% trans 'Post image' %}"v
27 alt="{% trans 'Post image' %}"v
28 data-width="{{ post.image_width }}"
28 data-width="{{ post.image_width }}"
29 data-height="{{ post.image_height }}"/>
29 data-height="{{ post.image_height }}"/>
30 </a>
30 </a>
31 </div>
31 </div>
32 {% endif %}
32 {% endif %}
33 <div class="message">
33 <div class="message">
34 <div class="post-info">
34 <div class="post-info">
35 <span class="title">{{ post.title }}</span>
35 <span class="title">{{ post.title }}</span>
36 <a class="post_id" href="#{{ post.id }}">
36 <a class="post_id" href="#{{ post.id }}">
37 (#{{ post.id }})</a>
37 (#{{ post.id }})</a>
38 [{{ post.pub_time }}]
38 [{{ post.pub_time }}]
39 [<a href="#" onclick="javascript:addQuickReply('{{ post.id }}')
39 [<a href="#" onclick="javascript:addQuickReply('{{ post.id }}')
40 ; return false;">&gt;&gt;</a>]
40 ; return false;">&gt;&gt;</a>]
41
41
42 {% if user.is_moderator %}
42 {% if user.is_moderator %}
43 <span class="moderator_info">
43 <span class="moderator_info">
44 [<a href="{% url 'delete' post_id=post.id %}"
44 [<a href="{% url 'delete' post_id=post.id %}"
45 >{% trans 'Delete' %}</a>]
45 >{% trans 'Delete' %}</a>]
46 ({{ post.poster_ip }})
46 ({{ post.poster_ip }})
47 [<a href="{% url 'ban' post_id=post.id %}?next={{ request.path }}"
47 [<a href="{% url 'ban' post_id=post.id %}?next={{ request.path }}"
48 >{% trans 'Ban IP' %}</a>]
48 >{% trans 'Ban IP' %}</a>]
49 </span>
49 </span>
50 {% endif %}
50 {% endif %}
51 </div>
51 </div>
52 {% autoescape off %}
52 {% autoescape off %}
53 {{ post.text.rendered }}
53 {{ post.text.rendered }}
54 {% endautoescape %}
54 {% endautoescape %}
55 </div>
55 </div>
56 {% if post.id == posts.0.id %}
56 {% if post.id == posts.0.id %}
57 <div class="metadata">
57 <div class="metadata">
58 <span class="tags">{% trans 'Tags' %}:
58 <span class="tags">{% trans 'Tags' %}:
59 {% for tag in post.tags.all %}
59 {% for tag in post.tags.all %}
60 <a class="tag" href="{% url 'tag' tag.name %}">
60 <a class="tag" href="{% url 'tag' tag.name %}">
61 {{ tag.name }}</a>
61 {{ tag.name }}</a>
62 {% endfor %}
62 {% endfor %}
63 </span>
63 </span>
64 </div>
64 </div>
65 {% endif %}
65 {% endif %}
66 </div>
66 </div>
67 {% endfor %}
67 {% endfor %}
68 </div>
68 </div>
69 {% endif %}
69 {% endif %}
70
70
71 <form id="form" enctype="multipart/form-data" method="post"
71 <form id="form" enctype="multipart/form-data" method="post"
72 >{% csrf_token %}
72 >{% csrf_token %}
73 <div class="post-form-w">
73 <div class="post-form-w">
74 <div class="form-title">{% trans "Reply to thread" %} #{{ posts.0.id }}</div>
74 <div class="form-title">{% trans "Reply to thread" %} #{{ posts.0.id }}</div>
75 <div class="post-form">
75 <div class="post-form">
76 <div class="form-row">
76 <div class="form-row">
77 <div class="form-label">{% trans 'Title' %}</div>
77 <div class="form-label">{% trans 'Title' %}</div>
78 <div class="form-input">{{ form.title }}</div>
78 <div class="form-input">{{ form.title }}</div>
79 <div class="form-errors">{{ form.title.errors }}</div>
79 <div class="form-errors">{{ form.title.errors }}</div>
80 </div>
80 </div>
81 <div class="form-row">
81 <div class="form-row">
82 <div class="form-label">{% trans 'Text' %}</div>
82 <div class="form-label">{% trans 'Text' %}</div>
83 <div class="form-input">{{ form.text }}</div>
83 <div class="form-input">{{ form.text }}</div>
84 <div class="form-errors">{{ form.text.errors }}</div>
84 <div class="form-errors">{{ form.text.errors }}</div>
85 </div>
85 </div>
86 <div class="form-row">
86 <div class="form-row">
87 <div class="form-label">{% trans 'Image' %}</div>
87 <div class="form-label">{% trans 'Image' %}</div>
88 <div class="form-input">{{ form.image }}</div>
88 <div class="form-input">{{ form.image }}</div>
89 <div class="form-errors">{{ form.image.errors }}</div>
89 <div class="form-errors">{{ form.image.errors }}</div>
90 </div>
90 </div>
91 <div class="form-row">
91 <div class="form-row">
92 {{ form.captcha }}
92 {{ form.captcha }}
93 <div class="form-errors">{{ form.captcha.errors }}</div>
93 <div class="form-errors">{{ form.captcha.errors }}</div>
94 </div>
94 </div>
95 <div class="form-row">
95 <div class="form-row">
96 <div class="form-errors">{{ form.other.errors }}</div>
96 <div class="form-errors">{{ form.other.errors }}</div>
97 </div>
97 </div>
98 </div>
98 </div>
99
99
100 <div class="form-submit"><input type="submit"
100 <div class="form-submit"><input type="submit"
101 value="{% trans "Post" %}"/></div>
101 value="{% trans "Post" %}"/></div>
102 <div><a href="{% url "staticpage" name="help" %}">
102 <div><a href="{% url "staticpage" name="help" %}">
103 {% trans 'Text syntax' %}</a></div>
103 {% trans 'Text syntax' %}</a></div>
104 </div>
104 </div>
105 </form>
105 </form>
106
106
107 {% endblock %}
107 {% endblock %}
108
108
109 {% block metapanel %}
109 {% block metapanel %}
110
110
111 <span class="metapanel">
111 <span class="metapanel">
112 {{ posts.0.get_reply_count }} {% trans 'replies' %},
112 {{ posts.0.get_reply_count }} {% trans 'replies' %},
113 {{ posts.0.get_images_count }} {% trans 'images' %}.
113 {{ posts.0.get_images_count }} {% trans 'images' %}.
114 {% trans 'Last update: ' %}{{ posts.0.last_edit_time }}
114 {% trans 'Last update: ' %}{{ posts.0.last_edit_time }}
115 [<a href="rss/">RSS</a>]
115 [<a href="rss/">RSS</a>]
116 </span>
116 </span>
117
117
118 {% endblock %}
118 {% endblock %}
General Comments 0
You need to be logged in to leave comments. Login now