Files
jiang13-forum/templates/messages/list.tmpl
freefire c32c81d1ca feat: SSR 评论回复与 @ 提及通知
发评/审通接入 NotifyService,系统通知会话支持 kind 筛选。

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-08-29 21:51:52 +08:00

42 lines
1.5 KiB
Cheetah
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
{{define "messages/list"}}
{{template "base/head" .}}
{{template "base/navbar" .}}
<main class="j13-main j13-messages">
<h1>私信与通知</h1>
{{template "base/alert" .}}
<p class="j13-muted">
未读 {{.UnreadTotal}}
(私信 {{.UnreadDM}} · 通知 {{.UnreadNotify}}
{{if gt .UnreadTotal 0}}
<form method="post" action="/messages/read-all" class="j13-inline-form">
<input type="hidden" name="_csrf" value="{{.CSRF}}"/>
<button type="submit" class="j13-linkbtn">全部标已读</button>
</form>
{{end}}
</p>
<p class="j13-muted"><a href="/messages/with/0">系统通知</a> · <a href="/messages/with/0?kind=reply">回复</a> · <a href="/messages/with/0?kind=mention">提及</a></p>
{{if .Conversations}}
<ul class="j13-msg-list">
{{range .Conversations}}
<li class="j13-msg-item{{if gt .Unread 0}} is-unread{{end}}">
<a href="/messages/with/{{.PeerID}}">
<strong>{{.PeerName}}</strong>
{{if gt .Unread 0}}<span class="j13-badge">{{.Unread}}</span>{{end}}
<span class="j13-msg-item__preview">{{.Preview}}</span>
<span class="j13-muted">{{.UpdatedLabel}}</span>
</a>
</li>
{{end}}
</ul>
<nav class="j13-pager">
{{if .HasPrev}}<a href="/messages?page={{.PrevPage}}">上一页</a>{{end}}
{{if .HasMore}}<a href="/messages?page={{.NextPage}}">下一页</a>{{end}}
</nav>
{{else}}
<p class="j13-empty">暂无会话。可在用户主页点击「发私信」开始对话。</p>
{{end}}
</main>
{{template "base/footer" .}}
{{end}}