##// END OF EJS Templates
Add gallery and tree links to the thread list
neko259 -
r1694:ea97d140 default
parent child Browse files
Show More
@@ -1,110 +1,112 b''
1 1 {% load i18n %}
2 2 {% load board %}
3 3
4 4 {% get_current_language as LANGUAGE_CODE %}
5 5
6 6 <div class="{{ css_class }}" id="{{ post.id }}" data-uid="{{ post.uid }}" {% if tree_depth %}style="margin-left: {{ tree_depth }}em;"{% endif %}>
7 7 <div class="post-info">
8 8 <a class="post_id" href="{{ post.get_absolute_url }}">#{{ post.id }}</a>
9 9 <span class="title">{{ post.title }}</span>
10 10 {% if perms.boards.change_post and post.has_ip %}
11 11 <a href="{% url 'feed' %}?ip={{ post.poster_ip }}">*</a>
12 12 <span class="pub_time" style="border-bottom: solid 2px #{{ post.get_ip_color }};" title="{{ post.poster_ip }}">
13 13 {% else %}
14 14 <span class="pub_time">
15 15 {% endif %}
16 16 <time datetime="{{ post.pub_time|date:'c' }}">{{ post.pub_time }}</time></span>
17 17 {% if post.tripcode %}
18 18 /
19 19 {% with tripcode=post.get_tripcode %}
20 20 <a href="{% url 'feed' %}?tripcode={{ tripcode.get_full_text }}"
21 21 class="tripcode" title="{{ tripcode.get_full_text }}"
22 22 style="border: solid 2px #{{ tripcode.get_color }}; border-left: solid 1ex #{{ tripcode.get_color }};">{{ tripcode.get_short_text }}</a>
23 23 {% endwith %}
24 24 {% endif %}
25 25 {% comment %}
26 26 Thread death time needs to be shown only if the thread is alredy archived
27 27 and this is an opening post (thread death time) or a post for popup
28 28 (we don't see OP here so we show the death time in the post itself).
29 29 {% endcomment %}
30 30 {% if is_opening and thread.is_archived %}
31 31 <time datetime="{{ thread.bump_time|date:'c' }}">{{ thread.bump_time }}</time>
32 32 {% endif %}
33 33 {% if is_opening %}
34 34 {% if need_open_link %}
35 35 {% if thread.is_archived %}
36 36 <a class="link" href="{% url 'thread' post.id %}">{% trans "Open" %}</a>
37 37 {% else %}
38 38 <a class="link" href="{% url 'thread' post.id %}#form">{% trans "Reply" %}</a>
39 39 {% endif %}
40 40 {% endif %}
41 41 {% else %}
42 42 {% if need_op_data %}
43 43 {% with thread.get_opening_post as op %}
44 44 {% trans " in " %}{{ op.get_link_view|safe }} <span class="title">{{ op.get_title_or_text }}</span>
45 45 {% endwith %}
46 46 {% endif %}
47 47 {% endif %}
48 48 {% if reply_link and not thread.is_archived %}
49 49 <a href="#form" onclick="addQuickReply('{{ post.id }}'); return false;">{% trans 'Reply' %}</a>
50 50 {% endif %}
51 51
52 52 {% if perms.boards.change_post or perms.boards.delete_post or perms.boards.change_thread or perms_boards.delete_thread %}
53 53 <span class="moderator_info">
54 54 {% if perms.boards.change_post or perms.boards.delete_post %}
55 55 | <a href="{% url 'admin:boards_post_change' post.id %}">{% trans 'Edit' %}</a>
56 56 {% endif %}
57 57 {% if perms.boards.change_thread or perms_boards.delete_thread %}
58 58 {% if is_opening %}
59 59 | <a href="{% url 'admin:boards_thread_change' thread.id %}">{% trans 'Edit thread' %}</a>
60 60 | <a href="{% url 'admin:boards_thread_delete' thread.id %}">{% trans 'Delete thread' %}</a>
61 61 {% else %}
62 62 | <a href="{% url 'admin:boards_post_delete' post.id %}">{% trans 'Delete post' %}</a>
63 63 {% endif %}
64 64 {% endif %}
65 65 {% if post.global_id_id %}
66 66 | <a href="{% url 'post_sync_data' post.id %}">RAW</a>
67 67 {% endif %}
68 68 </span>
69 69 {% endif %}
70 70 </div>
71 71 {% comment %}
72 72 Post images. Currently only 1 image can be posted and shown, but post model
73 73 supports multiple.
74 74 {% endcomment %}
75 75 {% for image in post.images.all %}
76 76 {{ image.get_view|safe }}
77 77 {% endfor %}
78 78 {% for file in post.attachments.all %}
79 79 {{ file.get_view|safe }}
80 80 {% endfor %}
81 81 {% comment %}
82 82 Post message (text)
83 83 {% endcomment %}
84 84 <div class="message">
85 85 {% if truncated %}
86 86 {{ post.get_text|truncatewords_html:50|safe }}
87 87 {% else %}
88 88 {{ post.get_text|safe }}
89 89 {% endif %}
90 90 </div>
91 91 {% if post.is_referenced and not mode_tree %}
92 92 <div class="refmap">
93 93 {% trans "Replies" %}: {{ post.refmap|safe }}
94 94 </div>
95 95 {% endif %}
96 96 {% comment %}
97 97 Thread metadata: counters, tags etc
98 98 {% endcomment %}
99 99 {% if is_opening %}
100 100 <div class="metadata">
101 101 {% if need_open_link %}
102 102 ♥ {{ thread.get_reply_count }}
103 103 ❄ {{ thread.get_images_count }}
104 <a href="{% url 'thread_gallery' post.id %}">G</a>
105 <a href="{% url 'thread_tree' post.id %}">T</a>
104 106 {% endif %}
105 107 <span class="tags">
106 108 {{ thread.get_tag_url_list|safe }}
107 109 </span>
108 110 </div>
109 111 {% endif %}
110 112 </div>
General Comments 0
You need to be logged in to leave comments. Login now