目前,后台管理功能基本完成,但还有两个工作没做:清理后台管理的导航菜单以及后台管理首页的模板。
后台管理菜单
<!-- templates/backend/base.html -->
<!-- ... -->
<div class="container-fluid">
<div class="row">
<nav id="sidebarMenu" class="col-md-3 col-lg-2 d-md-block bg-light sidebar collapse">
<div class="position-sticky pt-3">
<ul class="nav flex-column">
<li class="nav-item">
<a class="nav-link" aria-current="page" href="/admin">
<span data-feather="home"></span>
首页
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="/admin/category">
<span data-feather="file"></span>
分类
</a>
</li>
<li class="nav-item">
<a class="nav-link" href="/admin/topic">
<span data-feather="shopping-cart"></span>
文章
</a>
</li>
</ul>
</div>
</nav>
<!-- ... -->
后台管理首页
<!-- templates/backend/index.html -->
{% extends "./base.html" %}
{% block title%}后台管理{%endblock%}
{% block content %}
<div>欢迎光临</div>
{%endblock%}
标签:菜单,axum,管理,首页,后台,模板
From: https://www.cnblogs.com/pythonClub/p/17779459.html