{% load dict_tools %} {# 确保加载了过滤器,虽然这里可能不再需要 get_item,但保留以防万一 #}
更多 >
{# 再次遍历 data 生成内容面板 #} {% for tab_id, items in data.items %}
    {# items 就是当前 key 对应的列表数据,直接使用 #} {% if items %} {% for item in items %}
  • {{ item.title|truncatechars:30 }}
    {{ item.created_at | date:"Y-m-d" }}
  • {% endfor %} {% else %}
  • 暂无数据
  • {% endif %}
{% endfor %}