front.sidebar.html 1.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. {% load authperm %}
  2. <div class="panel panel-primary">
  3. <div class="panel-heading">
  4. <h4 class="panel-title">
  5. <span class="glyphicon glyphicon-th-large btn-xs"></span>
  6. 分类导航
  7. </h4>
  8. </div>
  9. <table class="table">
  10. <tbody>
  11. <tr>
  12. <td>
  13. <span class="glyphicon glyphicon-list-alt btn-xs"></span>
  14. <a href="{% url 'pichublog_postlist' '*' %}">全部</a>
  15. </td>
  16. </tr>
  17. {% for i in ctlist %}
  18. <tr>
  19. <td>
  20. <span class="glyphicon glyphicon-list-alt btn-xs"></span>
  21. <a href="{% url 'pichublog_postlist' i.engname %}">{{i.title}}</a>
  22. </td>
  23. </tr>
  24. {% endfor %}
  25. </tbody>
  26. </table>
  27. </div>
  28. {% ifperm "pichublog" "Writer" %}
  29. <div class="panel panel-primary">
  30. <div class="panel-heading">
  31. <h4 class="panel-title">
  32. <span class="glyphicon glyphicon-wrench btn-xs"></span>
  33. 前台管理操作
  34. </h4>
  35. </div>
  36. <table class="table">
  37. <tbody>
  38. <tr>
  39. <td>
  40. <span class="glyphicon glyphicon-plus btn-xs"></span>
  41. <a href="{% url 'pichublog_postadd' %}">新建文章</a>
  42. </td>
  43. </tr>
  44. <tr>
  45. <td>
  46. <span class="glyphicon glyphicon-th-list btn-xs"></span>
  47. <a href="{% url 'pichublog_postwbklist' %}">管理文章</a>
  48. </td>
  49. </tr>
  50. </tbody>
  51. </table>
  52. </div>
  53. {% endifperm %}