56
|
1 {# display a single ticket |
|
2 |
|
3 @variable item(xmlui_item): ticket to display |
|
4 @variable comments(data_object.BlogItems): comments of the ticket |
|
5 @variable comments_service(unicode): service for adding comments |
|
6 @variable comments_node(unicode): node for adding comments |
|
7 #} |
|
8 |
|
9 {% if not embedded %}{% extends 'base/base.html' %}{% endif %} |
|
10 {% import 'input/xmlui.html' as xmlui with context %} |
|
11 {% import 'blog/macros.html' as blog with context %} |
|
12 {% import 'input/comment.html' as comment with context %} |
|
13 |
|
14 {% block title %}{{item|adv_format('[{value.widget_value.id}] {value.widget_value.title}') }}{% endblock %} |
|
15 |
|
16 {% block confirm_message %} |
|
17 {% trans %}Your comment has been sent{% endtrans %} |
|
18 {% endblock confirm_message %} |
|
19 |
|
20 {% block body %} |
|
21 <div id="{{ item.widget_value['id'] }}" class="view single ticket box"> |
|
22 {{ xmlui.generate(item, |
|
23 form=false, |
|
24 filters={'created': {'filters': ['date_fmt'], filters_args:[{'fmt': 'short'}]}, |
|
25 'updated': {'filters': ['date_fmt'], filters_args:[{'fmt': 'short'}]}}, |
|
26 )}} |
|
27 </div> |
|
28 {% if comments is defined %} |
|
29 <div id="blog_items"> |
|
30 {{ blog.show_items(comments|reverse, expanded=true) }} |
|
31 </div> |
|
32 {% endif %} |
|
33 {% if comments_node is defined %} |
|
34 <div class="comment_post"> |
|
35 {{- comment.comment_or_login(service=comments_service, node=comments_node) -}} |
|
36 </div> |
|
37 {% endif %} |
|
38 {% endblock body %} |