标签作用:用于对内容列表进行筛选
1)到后台多查筛选设置
2)修改这三条记录(jiage/yanse/类型),注意不能删除这三条记录否则出错
多选:
<a {% if request.GET.duoxuan == "" or request.GET.danxuan == None %} color: #902b2b; {% endif %}" href="{% url 'webapp:column' url %}?danxuan={{ request.GET.danxuan }}&duoxuan=&shuzi={{ request.GET.shuzi }}">全部</a>
{% for v in extfields %}
<a {% if request.GET.duoxuan == v %} color: #902b2b; {% endif %}"href="{% url 'webapp:column' url %}?danxuan={{ request.GET.danxuan }}&duoxuan={{ v }}&shuzi={{ request.GET.shuzi }}"> {{ v }}</a>
{% endfor %}
单选:
<a {% if request.GET.danxuan == "" or request.GET.danxuan == None %} color: #902b2b; {% endif %}" href="{% url 'webapp:column' url %}?danxuan=&duoxuan={{ request.GET.duoxuan }}&shuzi={{ request.GET.shuzi }}">全部</a>
{% for v in extfields1 %}
<a style="margin-right: 20px; {% if request.GET.danxuan == v %} color: #902b2b; {% endif %}" href="{% url 'webapp:column' url %}?danxuan={{ v }}&duoxuan={{ request.GET.duoxuan }}&shuzi={{ request.GET.shuzi }}"> {{ v }}
</a>
{% endfor %}
数字:
<a {% if request.GET.shuzi == "" or request.GET.danxuan == None %} color: #902b2b; {% endif %}" href="{% url 'webapp:column' url %}?danxuan={{ request.GET.danxuan }}&duoxuan={{ request.GET.duoxuan }}&shuzi=">全部</a>
{% for v in extfields2 %}
<a {% if request.GET.shuzi == v %} color: #902b2b; {% endif %}" href="{% url 'webapp:column' url %}?danxuan={{ request.GET.danxuan }}&duoxuan={{ request.GET.duoxuan }}&shuzi={{ v }}">{{ v }}元
{% if forloop.last %}以上{% endif %}</a>
{% endfor %}