]> git.parisson.com Git - teleforma.git/commitdiff
fix profile courses, cleanup tables
authoryomguy <yomguy@parisson.com>
Tue, 5 Jun 2012 21:56:28 +0000 (23:56 +0200)
committeryomguy <yomguy@parisson.com>
Tue, 5 Jun 2012 21:56:28 +0000 (23:56 +0200)
teleforma/templates/teleforma/inc/conference_list.html
teleforma/templates/teleforma/inc/document_list.html
teleforma/templates/teleforma/inc/media_list.html
teleforma/templates/telemeta/profile_detail.html

index 1cd0609b5c70dc0eed2e147d623533575b0c80f6..b2327b956db27b37e9e01e64b4fa3e7cda037d53 100644 (file)
@@ -9,25 +9,23 @@
     <table class="listing" width="100%">
     <thead>
         <tr>
-        <th class="highlight">{% trans "Type" %}</th>
-        <th >{% trans "Room" %}</th>
-        <th >{% trans "Session" %}</th>
+        <th class="highlight">{% trans "Session" %}</th>
         <th>{% trans "Professor" %}</th>
         <th>{% trans "Begin date" %}</th>
+        <th >{% trans "Room" %}</th>
         <th>{% trans "Streaming" %}</th>
         </tr>
     </thead>
     <tbody>
         {% for conference in course.conference.all|from_type:type %}
             <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
-            <td><a href="{% url teleforma-conference-detail conference.id %}">{{ conference.course_type }}</a></td>
-            <td><a href="{% url teleforma-conference-detail conference.id %}">{{ conference.room }}</a></td>
             <td><a href="{% url teleforma-conference-detail conference.id %}">{{ conference.session }}</a></td>
             <td><a href="{% url telemeta-profile-detail conference.professor.user.username %}" target="_blank">{{ conference.professor }}</a></td>
             <td>{{ conference.date_begin }}</td>
+            <td>{{ conference.room }}</td>
              <td align="center">
                 {% if conference.streaming %}
-                <a href="{% url teleforma-conference-detail conference.id %}"><img src="images/media-record.png" alt="yes" style="vertical-align:middle" /></a>
+                <img src="images/media-record.png" alt="yes" style="vertical-align:middle" />
                 {% endif %}
             </td>
             </tr>
index 772269896a6573ad2f4f690bff76689c93d00216..14867b5052025da56d838e32b96adf147107435d 100644 (file)
@@ -10,7 +10,6 @@
     <thead>
         <tr>
         <th class="highlight">{% trans "Title" %}</th>
-        <th>{% trans "Description" %}</th>
         <th>{% trans "Annal" %}</th>
         <th>{% trans "Date modified" %}</th>
         <th>{% trans "Download" %}</th>
     <tbody>
         {% for document in course.document.all|from_type:type %}
         <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
-        <td><a href="{% url teleforma-document-detail document.id %}" target="_blank">{{ document.title }}</a></td>
-        <td>{{ document.description }}</td>
+        <td>{% if document.file %}<a href="{% url teleforma-document-detail document.id %}" target="_blank">{% endif %}{{ document.title }}{% if document.file %}</a>{% endif %}</td>
         <td align="center">
         {% if document.is_annal %}
           <img src="images/ok.png" alt="yes" style="vertical-align:middle" />&nbsp;
         {% endif %}
         </td>
         <td>{{ document.date_added }}</td>
-        <td align="center"><a href="{% url teleforma-document-download document.id %}"><img src="{% url telemeta-images "download.png" %}" width="16px"  style="vertical-align:middle" /></a></td>
+        <td align="center">{% if document.file %}<a href="{% url teleforma-document-download document.id %}"><img src="{% url telemeta-images "download.png" %}" width="16px"  style="vertical-align:middle" /></a>{% endif %}</td>
         </tr>
     {% endfor %}
     </tbody>
index 76e0b82aacc1814c5948683057e25c121505575b..0566a14ac8d67d11b248ea96aaf6d358230d54b3 100644 (file)
@@ -9,17 +9,19 @@
     <table class="listing" width="100%">
     <thead>
         <tr>
-        <th class="highlight">{% trans "Title" %}</th>
-        <th>{% trans "Description" %}</th>
-        <th>{% trans "Date modified" %}</th>
+        <th class="highlight">{% trans "Session" %}</th>
+        <th>{% trans "Professor" %}</th>
+        <th>{% trans "Begin date" %}</th>
+        <th>{% trans "Duration" %}</th>
         </tr>
     </thead>
     <tbody>
         {% for media in course.media.all|from_type:type %}
             <tr {% if not forloop.counter0|divisibleby:"2" %}class="odd"{% endif %}>
-            <td><a href="{% url teleforma-media-detail media.id %}">{{ media.item.title }}</a></td>
-            <td>{{ media.item.description }}</td>
-            <td>{{ media.date_modified }}</td>
+            <td><a href="{% url teleforma-media-detail media.id %}">{{ media.conference.session }}</a></td>
+            <td><a href="{% url telemeta-profile-detail media.conference.professor.user.username %}" target="_blank">{{ media.conference.professor }}</a></td>
+            <td><a href="{% url teleforma-media-detail media.id %}">{{ media.conference.date_begin }}</a></td>
+            <td>{{ media.item.approx_duration }}</td>
             </tr>
         {% endfor %}
     </tbody>
index e26b1249d5056b37106e1c89409b3a8005e47d36..97340ab985288eced577d713007733499c8a0864 100644 (file)
     <ul>
     {% block courses %}
     {% with user|user_courses as courses %}
-    {% for course in courses %}
-    <li><a href="{% url teleforma-course-detail course.id %}">{{ course.title}} {{ course.type }}</a></li>
-    {% endfor %}
+     {% for c in courses %}
+      {% for course in c.courses %}
+       <li><a href="{% url teleforma-course-detail course.id %}">{{ course.title}} {{ course.type }}</a></li>
+      {% endfor %}
+     {% endfor %}
     {% endwith %}
     {% endblock courses %}
     </ul>