##// END OF EJS Templates
Refmap is a separate block, not a part of a message
neko259 -
r1288:5e8376c2 default
parent child Browse files
Show More
@@ -1,110 +1,110 b''
1 {% load i18n %}
1 {% load i18n %}
2 {% load board %}
2 {% load board %}
3
3
4 {% get_current_language as LANGUAGE_CODE %}
4 {% get_current_language as LANGUAGE_CODE %}
5
5
6 <div class="{{ css_class }}" id="{{ post.id }}" data-uid="{{ post.uid }}">
6 <div class="{{ css_class }}" id="{{ post.id }}" data-uid="{{ post.uid }}">
7 <div class="post-info">
7 <div class="post-info">
8 <a class="post_id" href="{{ post.get_absolute_url }}">#{{ post.get_absolute_id }}</a>
8 <a class="post_id" href="{{ post.get_absolute_url }}">#{{ post.get_absolute_id }}</a>
9 <span class="title">{{ post.title }}</span>
9 <span class="title">{{ post.title }}</span>
10 <span class="pub_time"><time datetime="{{ post.pub_time|date:'c' }}">{{ post.pub_time }}</time></span>
10 <span class="pub_time"><time datetime="{{ post.pub_time|date:'c' }}">{{ post.pub_time }}</time></span>
11 {% comment %}
11 {% comment %}
12 Thread death time needs to be shown only if the thread is alredy archived
12 Thread death time needs to be shown only if the thread is alredy archived
13 and this is an opening post (thread death time) or a post for popup
13 and this is an opening post (thread death time) or a post for popup
14 (we don't see OP here so we show the death time in the post itself).
14 (we don't see OP here so we show the death time in the post itself).
15 {% endcomment %}
15 {% endcomment %}
16 {% if thread.archived %}
16 {% if thread.archived %}
17 {% if is_opening %}
17 {% if is_opening %}
18 β€” <time datetime="{{ thread.bump_time|date:'c' }}">{{ thread.bump_time }}</time>
18 β€” <time datetime="{{ thread.bump_time|date:'c' }}">{{ thread.bump_time }}</time>
19 {% endif %}
19 {% endif %}
20 {% endif %}
20 {% endif %}
21 {% if is_opening %}
21 {% if is_opening %}
22 {% if need_open_link %}
22 {% if need_open_link %}
23 {% if thread.archived %}
23 {% if thread.archived %}
24 <a class="link" href="{% url 'thread' post.id %}">{% trans "Open" %}</a>
24 <a class="link" href="{% url 'thread' post.id %}">{% trans "Open" %}</a>
25 {% else %}
25 {% else %}
26 <a class="link" href="{% url 'thread' post.id %}#form">{% trans "Reply" %}</a>
26 <a class="link" href="{% url 'thread' post.id %}#form">{% trans "Reply" %}</a>
27 {% endif %}
27 {% endif %}
28 {% endif %}
28 {% endif %}
29 {% else %}
29 {% else %}
30 {% if need_op_data %}
30 {% if need_op_data %}
31 {% with thread.get_opening_post as op %}
31 {% with thread.get_opening_post as op %}
32 {% trans " in " %}<a href="{{ op.get_absolute_url }}">&gt;&gt;{{ op.id }}</a> <span class="title">{{ op.get_title|striptags|truncatewords:5 }}</span>
32 {% trans " in " %}<a href="{{ op.get_absolute_url }}">&gt;&gt;{{ op.id }}</a> <span class="title">{{ op.get_title|striptags|truncatewords:5 }}</span>
33 {% endwith %}
33 {% endwith %}
34 {% endif %}
34 {% endif %}
35 {% endif %}
35 {% endif %}
36 {% if reply_link and not thread.archived %}
36 {% if reply_link and not thread.archived %}
37 <a href="#form" onclick="addQuickReply('{{ post.id }}'); return false;">{% trans 'Reply' %}</a>
37 <a href="#form" onclick="addQuickReply('{{ post.id }}'); return false;">{% trans 'Reply' %}</a>
38 {% endif %}
38 {% endif %}
39
39
40 {% if moderator %}
40 {% if moderator %}
41 <span class="moderator_info">
41 <span class="moderator_info">
42 | <a href="{% url 'admin:boards_post_change' post.id %}">{% trans 'Edit' %}</a>
42 | <a href="{% url 'admin:boards_post_change' post.id %}">{% trans 'Edit' %}</a>
43 {% if is_opening %}
43 {% if is_opening %}
44 | <a href="{% url 'admin:boards_thread_change' thread.id %}">{% trans 'Edit thread' %}</a>
44 | <a href="{% url 'admin:boards_thread_change' thread.id %}">{% trans 'Edit thread' %}</a>
45 {% endif %}
45 {% endif %}
46 </span>
46 </span>
47 {% endif %}
47 {% endif %}
48 </div>
48 </div>
49 {% comment %}
49 {% comment %}
50 Post images. Currently only 1 image can be posted and shown, but post model
50 Post images. Currently only 1 image can be posted and shown, but post model
51 supports multiple.
51 supports multiple.
52 {% endcomment %}
52 {% endcomment %}
53 {% if post.images.exists %}
53 {% if post.images.exists %}
54 {% with post.images.first as image %}
54 {% with post.images.first as image %}
55 {% autoescape off %}
55 {% autoescape off %}
56 {{ image.get_view }}
56 {{ image.get_view }}
57 {% endautoescape %}
57 {% endautoescape %}
58 {% endwith %}
58 {% endwith %}
59 {% endif %}
59 {% endif %}
60 {% if post.attachments.exists %}
60 {% if post.attachments.exists %}
61 {% with post.attachments.first as file %}
61 {% with post.attachments.first as file %}
62 {% autoescape off %}
62 {% autoescape off %}
63 {{ file.get_view }}
63 {{ file.get_view }}
64 {% endautoescape %}
64 {% endautoescape %}
65 {% endwith %}
65 {% endwith %}
66 {% endif %}
66 {% endif %}
67 {% comment %}
67 {% comment %}
68 Post message (text)
68 Post message (text)
69 {% endcomment %}
69 {% endcomment %}
70 <div class="message">
70 <div class="message">
71 {% autoescape off %}
71 {% autoescape off %}
72 {% if truncated %}
72 {% if truncated %}
73 {{ post.get_text|truncatewords_html:50 }}
73 {{ post.get_text|truncatewords_html:50 }}
74 {% else %}
74 {% else %}
75 {{ post.get_text }}
75 {{ post.get_text }}
76 {% endif %}
76 {% endif %}
77 {% endautoescape %}
77 {% endautoescape %}
78 </div>
78 {% if post.is_referenced %}
79 {% if post.is_referenced %}
79 {% if mode_tree %}
80 {% if mode_tree %}
80 <div class="tree_reply">
81 <div class="tree_reply">
81 {% for refpost in post.get_referenced_posts %}
82 {% for refpost in post.get_referenced_posts %}
82 {% post_view refpost mode_tree=True %}
83 {% post_view refpost mode_tree=True %}
83 {% endfor %}
84 {% endfor %}
84 </div>
85 </div>
85 {% else %}
86 {% else %}
86 <div class="refmap">
87 <div class="refmap">
87 {% autoescape off %}
88 {% autoescape off %}
88 {% trans "Replies" %}: {{ post.refmap }}
89 {% trans "Replies" %}: {{ post.refmap }}
89 {% endautoescape %}
90 {% endautoescape %}
90 </div>
91 </div>
91 {% endif %}
92 {% endif %}
92 {% endif %}
93 {% endif %}
93 </div>
94 {% comment %}
94 {% comment %}
95 Thread metadata: counters, tags etc
95 Thread metadata: counters, tags etc
96 {% endcomment %}
96 {% endcomment %}
97 {% if is_opening %}
97 {% if is_opening %}
98 <div class="metadata">
98 <div class="metadata">
99 {% if is_opening and need_open_link %}
99 {% if is_opening and need_open_link %}
100 {{ thread.get_reply_count }} {% trans 'messages' %},
100 {{ thread.get_reply_count }} {% trans 'messages' %},
101 {{ thread.get_images_count }} {% trans 'images' %}.
101 {{ thread.get_images_count }} {% trans 'images' %}.
102 {% endif %}
102 {% endif %}
103 <span class="tags">
103 <span class="tags">
104 {% autoescape off %}
104 {% autoescape off %}
105 {{ thread.get_tag_url_list }}
105 {{ thread.get_tag_url_list }}
106 {% endautoescape %}
106 {% endautoescape %}
107 </span>
107 </span>
108 </div>
108 </div>
109 {% endif %}
109 {% endif %}
110 </div>
110 </div>
General Comments 0
You need to be logged in to leave comments. Login now