|
|
@@ -1,11 +1,54 @@
|
|
|
{% extends "base.html" %}
|
|
|
|
|
|
-{% block title %}
|
|
|
-党建工作
|
|
|
-{% endblock %}
|
|
|
+{% block title %}{{ title }}{% endblock %}
|
|
|
|
|
|
{% block content %}
|
|
|
<div class="container">
|
|
|
- <h1>党建工作</h1>
|
|
|
+ <div class="row">
|
|
|
+ <div class="col-md-3">
|
|
|
+ <div class="model-title">党团工作</div>
|
|
|
+ <div class="model-list">
|
|
|
+ <ul class="list-group">
|
|
|
+ <li class="list-group-item" id="party_work">
|
|
|
+ <a href="{% url 'partyApp:party_work' %}">党建工作</a>
|
|
|
+ </li>
|
|
|
+ <li class="list-group-item" id="youth_work">
|
|
|
+ <a href="{% url 'partyApp:youth_work' %}">团学工作</a>
|
|
|
+ </li>
|
|
|
+ </ul>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="col-md-9">
|
|
|
+ <div class="model-details-title">{{ title }}</div>
|
|
|
+ <div class="row">
|
|
|
+ {% for article in list %}
|
|
|
+ <div class="col-md-4">
|
|
|
+ <div class="thumbnail">
|
|
|
+ {% if article.cover %}
|
|
|
+ <img src="{{ article.cover }}" alt="{{ article.title }}" class="img-responsive" style="height:200px;object-fit:cover;">
|
|
|
+ {% endif %}
|
|
|
+ <div class="caption">
|
|
|
+ <h4 style="text-align:center;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;">{{ article.title }}</h4>
|
|
|
+ <p style="text-align:center;color:#999;">{{ article.created_at|date:"Y-m-d" }}</p>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ {% endfor %}
|
|
|
+ </div>
|
|
|
+ {% if list.has_other_pages %}
|
|
|
+ <nav>
|
|
|
+ <ul class="pagination">
|
|
|
+ {% if list.has_previous %}
|
|
|
+ <li><a href="?page={{ list.previous_page_number }}">«上一页</a></li>
|
|
|
+ {% endif %}
|
|
|
+ <li><span>第 {{ list.number }} / {{ list.paginator.num_pages }} 页</span></li>
|
|
|
+ {% if list.has_next %}
|
|
|
+ <li><a href="?page={{ list.next_page_number }}">下一页»</a></li>
|
|
|
+ {% endif %}
|
|
|
+ </ul>
|
|
|
+ </nav>
|
|
|
+ {% endif %}
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
{% endblock %}
|