Left: | ||
Right: |
OLD | NEW |
---|---|
1 {% import "forms.html" as forms %} | 1 {% import "forms.html" as forms %} |
2 {% extends theme("layout.html") %} | 2 {% extends theme("layout.html") %} |
3 | 3 |
4 {% macro render_meta() %} | 4 {% macro render_meta() %} |
5 {% for e in [ | 5 {% for e in [ |
6 'summary', | 6 'summary', |
7 'effort', | 7 'effort', |
8 'difficulty', | 8 'difficulty', |
9 'severity', | 9 'severity', |
10 'priority', | 10 'priority', |
(...skipping 21 matching lines...) Expand all Loading... | |
32 {% macro render_backref() %} | 32 {% macro render_backref() %} |
33 {% for e in [ | 33 {% for e in [ |
34 'supersedes', | 34 'supersedes', |
35 'required_by', | 35 'required_by', |
36 'subscribers', | 36 'subscribers', |
37 ] %} | 37 ] %} |
38 {{ forms.render(form['backrefs'][e]) }} | 38 {{ forms.render(form['backrefs'][e]) }} |
39 {% endfor %} | 39 {% endfor %} |
40 {% endmacro %} | 40 {% endmacro %} |
41 | 41 |
42 {% set maxchars = 16 %} | |
43 | |
44 {% macro render_files(e) %} | |
45 <div> | |
46 {% set mimetype = "application/x.moin.download" %} | |
Thomas.J.Waldmann
2015/06/11 15:44:44
why is it that mimetype?
| |
47 <a href="{{ url_for('.show_item', item_name=e.fullname) }}" | |
Thomas.J.Waldmann
2015/06/11 15:44:44
don't use the name
vipul
2015/06/11 21:10:07
for rendering files, I've used IndexEntry instance
| |
48 class="{{ e.meta['contenttype']|contenttype_to_class }} moin-itemtype -{{ e.meta['itemtype'] }} moin-item" | |
49 title="{{ e.relname }}"> | |
50 </a>········ | |
51 <a href="{{ url_for('.download_item', item_name=e.fullname, mimetype=mim etype) }}"> | |
Thomas.J.Waldmann
2015/06/11 15:44:44
don't use the name
vipul
2015/06/11 21:10:07
same as said above
| |
52 {{ e.relname|truncate(maxchars, true, '..') }} | |
Thomas.J.Waldmann
2015/06/11 15:44:44
i think we already have a better "shorten" functio
| |
53 </a> | |
54 </div> | |
55 {% endmacro %} | |
56 | |
42 {% block head %} | 57 {% block head %} |
43 {{ super() }} | 58 {{ super() }} |
44 <link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/ ticket.css') }}" /> | 59 <link media="all" rel="stylesheet" href="{{ url_for('static', filename='css/ ticket.css') }}" /> |
45 {% endblock %} | 60 {% endblock %} |
46 | 61 |
47 {% set exists = item.fqname and storage.get_item(**item.fqname.query) %} | 62 {% set exists = item.fqname and storage.get_item(**item.fqname.query) %} |
48 {% block local_panel %} | 63 {% block local_panel %} |
49 {% if user.valid and exists %} | 64 {% if user.valid and exists %} |
50 <div class="list-group"> | 65 <div class="list-group"> |
51 <div class="list-group-item moin-list-heading"> | 66 <div class="list-group-item moin-list-heading"> |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
128 {% block ticket_metadata %} | 143 {% block ticket_metadata %} |
129 {% endblock %} | 144 {% endblock %} |
130 | 145 |
131 {{ gen.form.close() }} | 146 {{ gen.form.close() }} |
132 </div> | 147 </div> |
133 {% endblock %} | 148 {% endblock %} |
134 | 149 |
135 {% block footer_itemviews %} | 150 {% block footer_itemviews %} |
136 {{ itemviews() }} | 151 {{ itemviews() }} |
137 {% endblock %} | 152 {% endblock %} |
OLD | NEW |