Le repo des sources pour le site web des JM2L
Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 
 
 

62 строки
1.9 KiB

  1. <%inherit file="jm2l:templates/layout.mako"/>
  2. <div class="row-fluid">
  3. <div class="span10 offset1">
  4. <span class="pull-right">
  5. <a href="/entity">Ajouter une entité</a> -
  6. <a href="/categorie/entity">Editer les catégories</a>
  7. </span>
  8. <br>
  9. <div class="tabbable" id="main_tab">
  10. <ul class="nav nav-tabs" style="margin-bottom: 5px;">
  11. % for Num, Entity_Type in enumerate(entities.keys()):
  12. <li class="${["","active"][Num==0]}">
  13. <a href="#${Entity_Type}" id="Map_${Entity_Type}" data-toggle="tab">${Entity_Type}s</a>
  14. </li>
  15. % endfor
  16. </ul>
  17. <div class="tab-content" style="padding:0 10px">
  18. % for Num, Entity_Type in enumerate(entities.keys()):
  19. <div class="tab-pane fade ${["","active "][Num==0]} in" id="${Entity_Type}">
  20. <table class="table table-striped table-bordered table-hover">
  21. <thead>
  22. <tr>
  23. <th style="width:7em;text-align:center;">Type</th>
  24. <th style="text-align:center;">Nom</th>
  25. </tr>
  26. </thead>
  27. <tbody>
  28. % for entity in entities[Entity_Type].all():
  29. <tr>
  30. <td style="text-align:center;">
  31. % for img_path in entity.ThumbLinks:
  32. <img src="${img_path}" alt="logo" />
  33. % endfor
  34. </td>
  35. <td style="position: relative;">
  36. ${Entity_Type}, ${entity.get_entity_type.entity_subtype}<br>
  37. <strong>
  38. <a href="/entity/${entity.get_entity_type.slug_entity_type}/${entity.slug}">${entity.name}</a>
  39. </strong>
  40. % if request.user and request.user.Staff:
  41. <span style="float:right;">
  42. <a href="/entity/${entity.get_entity_type.slug_entity_type}/${entity.slug}/edit">edit</a>
  43. </span>
  44. % endif
  45. </td>
  46. </tr>
  47. % endfor
  48. </tbody>
  49. </table>
  50. </div>
  51. % endfor
  52. </div>
  53. </div>
  54. </div>