##// END OF EJS Templates
#32 Changed "view" link to "reply". The thread can be opened at the top by clicking its id.
neko259 -
r45:97bf814e default
parent child Browse files
Show More
@@ -1,93 +1,93 b''
1 {% extends "base.html" %}
1 {% extends "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</title>
7 <title>Neboard</title>
8 {% endblock %}
8 {% endblock %}
9
9
10 {% block content %}
10 {% block content %}
11
11
12 {% if threads %}
12 {% if threads %}
13 {% for thread in threads %}
13 {% for thread in threads %}
14 <div class="post">
14 <div class="post">
15 {% if thread.image %}
15 {% if thread.image %}
16 <div class="image">
16 <div class="image">
17 <a href="{{ thread.image.url }}"><img
17 <a href="{{ thread.image.url }}"><img
18 src="{{ thread.image.url_200x150 }}" />
18 src="{{ thread.image.url_200x150 }}" />
19 </a>
19 </a>
20 </div>
20 </div>
21 {% endif %}
21 {% endif %}
22 <div class="message">
22 <div class="message">
23 <span class="title">{{ thread.title }}</span>
23 <span class="title">{{ thread.title }}</span>
24 <a class="post_id" href="{% url 'thread' thread.id %}">
24 <a class="post_id" href="{% url 'thread' thread.id %}">
25 (#{{ thread.id }})</a>
25 (#{{ thread.id }})</a>
26 [{{ thread.pub_time }}]
26 [{{ thread.pub_time }}]
27 [<a class="link" href="{% url 'thread' thread.id %}"
27 [<a class="link" href="{% url 'thread' thread.id %}#form"
28 >{% trans "View" %}</a>]
28 >{% trans "Reply" %}</a>]
29 {% autoescape off %}
29 {% autoescape off %}
30 {{ thread.text.rendered|truncatechars:300 }}
30 {{ thread.text.rendered|truncatechars:300 }}
31 {% endautoescape %}
31 {% endautoescape %}
32 </div>
32 </div>
33 <div class="metadata">
33 <div class="metadata">
34 {{ thread.get_reply_count }} {% trans 'replies' %},
34 {{ thread.get_reply_count }} {% trans 'replies' %},
35 {{ thread.get_images_count }} {% trans 'images' %},
35 {{ thread.get_images_count }} {% trans 'images' %},
36 {{ thread.get_gets_count }} {% trans 'gets' %}.
36 {{ thread.get_gets_count }} {% trans 'gets' %}.
37 {% if thread.tags.all %}
37 {% if thread.tags.all %}
38 <span class="tags">{% trans 'Tags' %}:
38 <span class="tags">{% trans 'Tags' %}:
39 {% for tag in thread.tags.all %}
39 {% for tag in thread.tags.all %}
40 <a class="tag" href="
40 <a class="tag" href="
41 {% url 'tag' tag_name=tag.name %}">
41 {% url 'tag' tag_name=tag.name %}">
42 {{ tag.name }}</a>
42 {{ tag.name }}</a>
43 {% endfor %}
43 {% endfor %}
44 </span>
44 </span>
45 {% endif %}
45 {% endif %}
46 </div>
46 </div>
47 </div>
47 </div>
48 {% endfor %}
48 {% endfor %}
49 {% else %}
49 {% else %}
50 No threads found.
50 No threads found.
51 <hr />
51 <hr />
52 {% endif %}
52 {% endif %}
53
53
54 <form enctype="multipart/form-data" method="post">{% csrf_token %}
54 <form enctype="multipart/form-data" method="post">{% csrf_token %}
55 <div class="post-form-w">
55 <div class="post-form-w">
56 <div class="form-title">{% trans "Create new thread" %}</div>
56 <div class="form-title">{% trans "Create new thread" %}</div>
57 <div class="post-form">
57 <div class="post-form">
58 <div class="form-row">
58 <div class="form-row">
59 <div class="form-label">{% trans 'Title' %}</div>
59 <div class="form-label">{% trans 'Title' %}</div>
60 <div class="form-input">{{ form.title }}</div>
60 <div class="form-input">{{ form.title }}</div>
61 </div>
61 </div>
62 <div class="form-row">
62 <div class="form-row">
63 <div class="form-label">{% trans 'Text' %}</div>
63 <div class="form-label">{% trans 'Text' %}</div>
64 <div class="form-input">{{ form.text }}</div>
64 <div class="form-input">{{ form.text }}</div>
65 </div>
65 </div>
66 <div class="form-row">
66 <div class="form-row">
67 <div class="form-label">{% trans 'Image' %}</div>
67 <div class="form-label">{% trans 'Image' %}</div>
68 <div class="form-input">{{ form.image }}</div>
68 <div class="form-input">{{ form.image }}</div>
69 </div>
69 </div>
70 <div class="form-row">
70 <div class="form-row">
71 <div class="form-label">{% trans 'Tags' %}</div>
71 <div class="form-label">{% trans 'Tags' %}</div>
72 <div class="form-input">{{ form.tags }}</div>
72 <div class="form-input">{{ form.tags }}</div>
73 </div>
73 </div>
74 </div>
74 </div>
75 <div class="form-submit"><input type="submit"
75 <div class="form-submit"><input type="submit"
76 value="{% trans "Post" %}"/></div>
76 value="{% trans "Post" %}"/></div>
77 <div>Tags must be delimited by spaces. Text or image is required
77 <div>Tags must be delimited by spaces. Text or image is required
78 </div>
78 </div>
79 <div>Use <a
79 <div>Use <a
80 href="http://daringfireball.net/projects/markdown/basics">
80 href="http://daringfireball.net/projects/markdown/basics">
81 markdown</a> syntax for posting.</div>
81 markdown</a> syntax for posting.</div>
82 </div>
82 </div>
83 </form>
83 </form>
84
84
85 {% endblock %}
85 {% endblock %}
86
86
87 {% block metapanel %}
87 {% block metapanel %}
88
88
89 <span class="metapanel">
89 <span class="metapanel">
90 Neboard 2013-05 (dev)
90 Neboard 2013-05 (dev)
91 </span>
91 </span>
92
92
93 {% endblock %} No newline at end of file
93 {% endblock %}
@@ -1,91 +1,92 b''
1 {% extends "base.html" %}
1 {% extends "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.title }}</title>
7 <title>Neboard - {{ posts.0.title }}</title>
8 {% endblock %}
8 {% endblock %}
9
9
10 {% block content %}
10 {% block content %}
11
11
12 {% if posts %}
12 {% if posts %}
13 {% for post in posts %}
13 {% for post in posts %}
14 <a id="{{ post.id }}"></a>
14 <a id="{{ post.id }}"></a>
15 <div class="post">
15 <div class="post">
16 {% if post.image %}
16 {% if post.image %}
17 <div class="image">
17 <div class="image">
18 <a href="{{ post.image.url }}"><img
18 <a href="{{ post.image.url }}"><img
19 src="{{ post.image.url_200x150 }}" />
19 src="{{ post.image.url_200x150 }}" />
20 </a>
20 </a>
21 </div>
21 </div>
22 {% endif %}
22 {% endif %}
23 <div class="message">
23 <div class="message">
24 <span class="title">{{ post.title }}</span>
24 <span class="title">{{ post.title }}</span>
25 <a class="post_id" href="#{{ post.id }}">
25 <a class="post_id" href="#{{ post.id }}">
26 (#{{ post.id }})</a>
26 (#{{ post.id }})</a>
27 [{{ post.pub_time }}]
27 [{{ post.pub_time }}]
28 {% if post.is_get %}
28 {% if post.is_get %}
29 <span class="get">
29 <span class="get">
30 {% trans "Get!" %}
30 {% trans "Get!" %}
31 </span>
31 </span>
32 {% endif %}
32 {% endif %}
33 {% autoescape off %}
33 {% autoescape off %}
34 {{ post.text.rendered }}
34 {{ post.text.rendered }}
35 {% endautoescape %}
35 {% endautoescape %}
36 </div>
36 </div>
37 {% if post.tags.all %}
37 {% if post.tags.all %}
38 <div class="metadata">
38 <div class="metadata">
39 <span class="tags">{% trans 'Tags' %}:
39 <span class="tags">{% trans 'Tags' %}:
40 {% for tag in post.tags.all %}
40 {% for tag in post.tags.all %}
41 <a class="tag" href="{% url 'tag' tag.name %}">
41 <a class="tag" href="{% url 'tag' tag.name %}">
42 {{ tag.name }}</a>
42 {{ tag.name }}</a>
43 {% endfor %}
43 {% endfor %}
44 </span>
44 </span>
45 </div>
45 </div>
46 {% endif %}
46 {% endif %}
47 </div>
47 </div>
48 {% endfor %}
48 {% endfor %}
49 {% else %}
49 {% else %}
50 No threads found.
50 No threads found.
51 <hr />
51 <hr />
52 {% endif %}
52 {% endif %}
53
53
54 <form enctype="multipart/form-data" method="post">{% csrf_token %}
54 <form id="form" enctype="multipart/form-data" method="post"
55 >{% csrf_token %}
55 <div class="post-form-w">
56 <div class="post-form-w">
56 <div class="form-title">{% trans "Reply to thread" %}</div>
57 <div class="form-title">{% trans "Reply to thread" %}</div>
57 <div class="post-form">
58 <div class="post-form">
58 <div class="form-row">
59 <div class="form-row">
59 <div class="form-label">{% trans 'Title' %}</div>
60 <div class="form-label">{% trans 'Title' %}</div>
60 <div class="form-input">{{ form.title }}</div>
61 <div class="form-input">{{ form.title }}</div>
61 </div>
62 </div>
62 <div class="form-row">
63 <div class="form-row">
63 <div class="form-label">{% trans 'Text' %}</div>
64 <div class="form-label">{% trans 'Text' %}</div>
64 <div class="form-input">{{ form.text }}</div>
65 <div class="form-input">{{ form.text }}</div>
65 </div>
66 </div>
66 <div class="form-row">
67 <div class="form-row">
67 <div class="form-label">{% trans 'Image' %}</div>
68 <div class="form-label">{% trans 'Image' %}</div>
68 <div class="form-input">{{ form.image }}</div>
69 <div class="form-input">{{ form.image }}</div>
69 </div>
70 </div>
70 </div>
71 </div>
71 <div class="form-submit"><input type="submit"
72 <div class="form-submit"><input type="submit"
72 value="{% trans "Post" %}"/></div>
73 value="{% trans "Post" %}"/></div>
73 <div>Use <a
74 <div>Use <a
74 href="http://daringfireball.net/projects/markdown/basics">
75 href="http://daringfireball.net/projects/markdown/basics">
75 markdown</a> syntax for posting.</div>
76 markdown</a> syntax for posting.</div>
76 <div>Example: *<i>italic</i>*, **<b>bold</b>**</div>
77 <div>Example: *<i>italic</i>*, **<b>bold</b>**</div>
77 <div>Insert quotes with "&gt;"</div>
78 <div>Insert quotes with "&gt;"</div>
78 </div>
79 </div>
79 </form>
80 </form>
80
81
81 {% endblock %}
82 {% endblock %}
82
83
83 {% block metapanel %}
84 {% block metapanel %}
84
85
85 <span class="metapanel">
86 <span class="metapanel">
86 {{ posts.0.get_reply_count }} {% trans 'replies' %},
87 {{ posts.0.get_reply_count }} {% trans 'replies' %},
87 {{ posts.0.get_images_count }} {% trans 'images' %},
88 {{ posts.0.get_images_count }} {% trans 'images' %},
88 {{ posts.0.get_gets_count }} {% trans 'gets' %}
89 {{ posts.0.get_gets_count }} {% trans 'gets' %}
89 </span>
90 </span>
90
91
91 {% endblock %} No newline at end of file
92 {% endblock %}
General Comments 0
You need to be logged in to leave comments. Login now