Show More
@@ -4,95 +4,87 b'' | |||||
4 |
|
4 | |||
5 | {% get_current_language as LANGUAGE_CODE %} |
|
5 | {% get_current_language as LANGUAGE_CODE %} | |
6 |
|
6 | |||
7 | {% spaceless %} |
|
7 | {% if thread.archived %} | |
8 | {% cache 600 post post.id post.last_edit_time thread.archived bumpable truncated moderator LANGUAGE_CODE need_open_link %} |
|
8 | <div class="post archive_post" id="{{ post.id }}"> | |
9 | {% if thread.archived %} |
|
9 | {% elif bumpable %} | |
10 |
|
|
10 | <div class="post" id="{{ post.id }}"> | |
11 | {% elif bumpable %} |
|
11 | {% else %} | |
12 |
|
|
12 | <div class="post dead_post" id="{{ post.id }}"> | |
13 | {% else %} |
|
13 | {% endif %} | |
14 | <div class="post dead_post" id="{{ post.id }}"> |
|
|||
15 | {% endif %} |
|
|||
16 |
|
14 | |||
17 |
|
|
15 | <div class="post-info"> | |
18 |
|
|
16 | <a class="post_id" href="{% post_object_url post thread=thread %}" | |
19 |
|
|
17 | {% if not truncated and not thread.archived %} | |
20 |
|
|
18 | onclick="javascript:addQuickReply('{{ post.id }}'); return false;" | |
21 |
|
|
19 | title="{% trans 'Quote' %}" {% endif %}>({{ post.id }})</a> | |
22 | {% endif %} |
|
20 | <span class="title">{{ post.title }} </span> | |
23 | >({{ post.id }}) </a> |
|
21 | <span class="pub_time">{{ post.pub_time }}</span> | |
24 | <span class="title">{{ post.title }} </span> |
|
22 | {% if thread.archived %} | |
25 | <span class="pub_time">{{ post.pub_time }}</span> |
|
23 | β {{ thread.bump_time }} | |
26 | {% if thread.archived %} |
|
24 | {% endif %} | |
27 | β {{ thread.bump_time }} |
|
25 | {% if is_opening and need_open_link %} | |
|
26 | {% if thread.archived %} | |||
|
27 | [<a class="link" href="{% url 'thread' post.id %}">{% trans "Open" %}</a>] | |||
|
28 | {% else %} | |||
|
29 | [<a class="link" href="{% url 'thread' post.id %}#form">{% trans "Reply" %}</a>] | |||
|
30 | {% endif %} | |||
|
31 | {% endif %} | |||
|
32 | ||||
|
33 | {% if moderator %} | |||
|
34 | <span class="moderator_info"> | |||
|
35 | [<a href="{% url 'admin:boards_post_change' post.id %}" | |||
|
36 | >{% trans 'Edit' %}</a>] | |||
|
37 | {% if is_opening %} | |||
|
38 | [<a href="{% url 'admin:boards_thread_change' thread.id %}" | |||
|
39 | >{% trans 'Edit thread' %}</a>] | |||
28 | {% endif %} |
|
40 | {% endif %} | |
29 | {% if is_opening and need_open_link %} |
|
41 | </span> | |
30 | {% if thread.archived %} |
|
42 | {% endif %} | |
31 | [<a class="link" href="{% url 'thread' post.id %}">{% trans "Open" %}</a>] |
|
43 | </div> | |
32 | {% else %} |
|
44 | {% if post.images.exists %} | |
33 | [<a class="link" href="{% url 'thread' post.id %}#form">{% trans "Reply" %}</a>] |
|
45 | {% with post.images.all.0 as image %} | |
34 | {% endif %} |
|
46 | <div class="image"> | |
35 |
|
|
47 | <a | |
36 |
|
48 | class="thumb" | ||
37 | {% if moderator %} |
|
49 | href="{{ image.image.url }}"><img | |
38 | <span class="moderator_info"> |
|
50 | src="{{ image.image.url_200x150 }}" | |
39 |
|
|
51 | alt="{{ post.id }}" | |
40 | >{% trans 'Edit' %}</a>] |
|
52 | width="{{ image.pre_width }}" | |
41 | {% if is_opening %} |
|
53 | height="{{ image.pre_height }}" | |
42 | [<a href="{% url 'admin:boards_thread_change' thread.id %}" |
|
54 | data-width="{{ image.width }}" | |
43 | >{% trans 'Edit thread' %}</a>] |
|
55 | data-height="{{ image.height }}"/> | |
44 | {% endif %} |
|
56 | </a> | |
45 | </span> |
|
|||
46 | {% endif %} |
|
|||
47 | </div> |
|
57 | </div> | |
48 | {% if post.images.exists %} |
|
58 | {% endwith %} | |
49 | {% with post.images.all.0 as image %} |
|
59 | {% endif %} | |
50 |
|
|
60 | <div class="message"> | |
51 | <a |
|
61 | {% autoescape off %} | |
52 | class="thumb" |
|
62 | {% if truncated %} | |
53 | href="{{ image.image.url }}"><img |
|
63 | {{ post.get_text|truncatewords_html:50 }} | |
54 | src="{{ image.image.url_200x150 }}" |
|
64 | {% else %} | |
55 |
|
|
65 | {{ post.get_text }} | |
56 | width="{{ image.pre_width }}" |
|
|||
57 | height="{{ image.pre_height }}" |
|
|||
58 | data-width="{{ image.width }}" |
|
|||
59 | data-height="{{ image.height }}"/> |
|
|||
60 | </a> |
|
|||
61 | </div> |
|
|||
62 | {% endwith %} |
|
|||
63 | {% endif %} |
|
66 | {% endif %} | |
64 | <div class="message"> |
|
67 | {% endautoescape %} | |
|
68 | {% if post.is_referenced %} | |||
|
69 | <div class="refmap"> | |||
65 | {% autoescape off %} |
|
70 | {% autoescape off %} | |
66 | {% if truncated %} |
|
71 | {% trans "Replies" %}: {{ post.refmap }} | |
67 | {{ post.get_text|truncatewords_html:50 }} |
|
|||
68 | {% else %} |
|
|||
69 | {{ post.get_text }} |
|
|||
70 | {% endif %} |
|
|||
71 | {% endautoescape %} |
|
72 | {% endautoescape %} | |
72 | {% if post.is_referenced %} |
|
|||
73 | <div class="refmap"> |
|
|||
74 | {% autoescape off %} |
|
|||
75 | {% trans "Replies" %}: {{ post.refmap }} |
|
|||
76 | {% endautoescape %} |
|
|||
77 | </div> |
|
|||
78 | {% endif %} |
|
|||
79 | </div> |
|
73 | </div> | |
80 |
{% end |
|
74 | {% endif %} | |
81 | {% if is_opening %} |
|
75 | </div> | |
82 | {% cache 600 post_thread thread.id thread.last_edit_time LANGUAGE_CODE need_open_link %} |
|
76 | {% if is_opening %} | |
83 |
|
|
77 | <div class="metadata"> | |
84 |
|
|
78 | {% if is_opening and need_open_link %} | |
85 |
|
|
79 | {{ thread.get_reply_count }} {% trans 'messages' %}, | |
86 |
|
|
80 | {{ thread.get_images_count }} {% trans 'images' %}. | |
87 | {% endif %} |
|
|||
88 | <span class="tags"> |
|
|||
89 | {% for tag in thread.get_tags %} |
|
|||
90 | <a class="tag" href="{% url 'tag' tag.name %}"> |
|
|||
91 | #{{ tag.name }}</a>{% if not forloop.last %},{% endif %} |
|
|||
92 | {% endfor %} |
|
|||
93 | </span> |
|
|||
94 | </div> |
|
|||
95 | {% endcache %} |
|
|||
96 | {% endif %} |
|
81 | {% endif %} | |
97 | </div> |
|
82 | <span class="tags"> | |
98 | {% endspaceless %} |
|
83 | {% for tag in thread.get_tags %} | |
|
84 | <a class="tag" href="{% url 'tag' tag.name %}"> | |||
|
85 | #{{ tag.name }}</a>{% if not forloop.last %},{% endif %} | |||
|
86 | {% endfor %} | |||
|
87 | </span> | |||
|
88 | </div> | |||
|
89 | {% endif %} | |||
|
90 | </div> |
General Comments 0
You need to be logged in to leave comments.
Login now