Panel improvements
[mediagoblin.git] / mediagoblin / templates / mediagoblin / user_pages / processing_panel.html
CommitLineData
01c75c7e
CAW
1{#
2# GNU MediaGoblin -- federated, autonomous media hosting
cf29e8a8 3# Copyright (C) 2011, 2012 MediaGoblin contributors. See AUTHORS.
01c75c7e
CAW
4#
5# This program is free software: you can redistribute it and/or modify
6# it under the terms of the GNU Affero General Public License as published by
7# the Free Software Foundation, either version 3 of the License, or
8# (at your option) any later version.
9#
10# This program is distributed in the hope that it will be useful,
11# but WITHOUT ANY WARRANTY; without even the implied warranty of
12# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13# GNU Affero General Public License for more details.
14#
15# You should have received a copy of the GNU Affero General Public License
16# along with this program. If not, see <http://www.gnu.org/licenses/>.
17#}
18{% extends "mediagoblin/base.html" %}
19
20{% block mediagoblin_content %}
21
22<h1>{% trans %}Media processing panel{% endtrans %}</h1>
23
24<p>
25 {% trans %}You can track the state of media being processed for your gallery here.{% endtrans %}
26</p>
27
28<h2>{% trans %}Media in-processing{% endtrans %}</h2>
29
30{% if processing_entries.count() %}
31 <table class="media_panel processing">
32 <tr>
51eb0267 33 <th>ID</th>
01c75c7e
CAW
34 <th>Title</th>
35 <th>When submitted</th>
64712915 36 <th>Transcoding progress</th>
01c75c7e
CAW
37 </tr>
38 {% for media_entry in processing_entries %}
39 <tr>
51eb0267 40 <td>{{ media_entry._id }}</td>
ec82fbd8 41 <td>{{ media_entry.title }}</td>
05478430 42 <td>{{ media_entry.created.strftime("%m-%d-%Y %I:%M %p") }}</td>
64712915
JW
43 {% if media_entry.transcoding_progress %}
44 <td>{{ media_entry.transcoding_progress }}%</td>
45 {% else %}
46 <td>Unknown</td>
47 {% endif %}
01c75c7e
CAW
48 </tr>
49 {% endfor %}
50 </table>
51{% else %}
64712915 52 <p><em>{% trans %}No media in-processing{% endtrans %}</em></p>
01c75c7e
CAW
53{% endif %}
54
55{% if failed_entries.count() %}
56 <h2>{% trans %}These uploads failed to process:{% endtrans %}</h2>
57
58 <table class="media_panel failed">
59 <tr>
51eb0267 60 <th>ID</th>
01c75c7e
CAW
61 <th>Title</th>
62 <th>When submitted</th>
63 <th>Reason for failure</th>
51eb0267 64 <th>Failure metadata</th>
01c75c7e
CAW
65 </tr>
66 {% for media_entry in failed_entries %}
67 <tr>
51eb0267 68 <td>{{ media_entry._id }}</td>
ec82fbd8 69 <td>{{ media_entry.title }}</td>
51eb0267
JW
70 <td>{{ media_entry.created.strftime("%m-%d-%Y %I:%M %p") }}</td>
71 {% if media_entry.get_fail_exception() %}
01c75c7e 72 <td>{{ media_entry.get_fail_exception().general_message }}</td>
51eb0267
JW
73 <td>{{ media_entry.fail_metadata }}</td>
74 {% else %}
75 <td>&nbsp;</td>
76 <td>&nbsp;</td>
77 {% endif %}
01c75c7e
CAW
78 </tr>
79 {% endfor %}
80 </table>
64712915
JW
81{% else %}
82 <p><em>{% trans %}No failed entries!{% endtrans %}</em></p>
83{% endif %}
84{% if processed_entries.count() %}
85 <h2>{% trans %}Your last 10 successful uploads{% endtrans %}</h2>
86
87 <table class="media_panel processed">
88 <tr>
89 <th>ID</th>
90 <th>Title</th>
91 <th>Submitted</th>
92 </tr>
93 {% for entry in processed_entries %}
94 <tr>
95 <td>{{ entry._id }}</td>
96 <td><a href="{{ entry.url_for_self(request.urlgen) }}">{{ entry.title }}</a></td>
97 <td>{{ entry.created.strftime("%m-%d-%Y %I:%M %p") }}</td>
98 </tr>
99 {% endfor %}
100 </table>
101{% else %}
102 <p><em>{% trans %}No processed entries, yet!{% endtrans %}</em></p>
103{% endif %}
01c75c7e 104{% endblock %}