增加基础设置页面

This commit is contained in:
2026-07-29 16:45:22 +08:00
parent 0b22d4f126
commit a9a890a849
15 changed files with 472 additions and 84 deletions
+15 -1
View File
@@ -53,7 +53,8 @@
</div>
</nav>
<section class="comments-section">
{{if .ShowComments}}
<section class="comments-section" id="comments">
<h3>评论 ({{.CommentCount}})</h3>
<form class="comment-form" action="/comment" method="POST">
@@ -106,5 +107,18 @@
<p class="no-comments">暂无评论,来发表第一条评论吧!</p>
{{end}}
</div>
{{if gt .CommentTotalPages 1}}
<div class="pagination comment-pagination">
{{if gt .CommentPage 1}}
<a href="/post/{{.Post.Slug}}?cpage={{sub .CommentPage 1}}#comments" class="prev">← 上一页</a>
{{end}}
<span class="page-info">{{.CommentPage}} / {{.CommentTotalPages}}</span>
{{if lt .CommentPage .CommentTotalPages}}
<a href="/post/{{.Post.Slug}}?cpage={{add .CommentPage 1}}#comments" class="next">下一页 →</a>
{{end}}
</div>
{{end}}
</section>
{{end}}
{{end}}