@@ -0,0 +1,58 @@
|
||||
{{define "content"}}
|
||||
<div class="page">
|
||||
<header class="page-head">
|
||||
<div>
|
||||
<h1>客户</h1>
|
||||
<p class="muted">共 {{.D.Total}} 位 · 输入手机尾号可快速定位</p>
|
||||
</div>
|
||||
<div class="page-actions">
|
||||
<a class="btn btn-primary" href="/customers/new">+ 新建客户</a>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
<form class="filterbar" method="get" action="/customers">
|
||||
<input type="search" name="q" value="{{.D.Q}}" placeholder="手机尾号 / 姓名 / 游戏名 / 联系方式" autocomplete="off">
|
||||
<button class="btn" type="submit">搜索</button>
|
||||
{{if .D.Q}}<a class="btn btn-ghost" href="/customers">清除</a>{{end}}
|
||||
</form>
|
||||
|
||||
{{if .D.List}}
|
||||
<div class="table-wrap">
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr><th>尾号</th><th>客户</th><th>联系方式</th><th>订阅与剩余</th><th>标签</th><th></th></tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{{range .D.List}}
|
||||
<tr>
|
||||
<td><a class="tail" href="/customers/{{.ID}}">{{.Tail}}</a></td>
|
||||
<td>
|
||||
<a class="name" href="/customers/{{.ID}}">{{.Name}}</a>
|
||||
{{if .GameName}}<div class="muted small">{{.GameName}}{{if .GameServer}} · {{.GameServer}}{{end}}</div>{{end}}
|
||||
</td>
|
||||
<td class="muted small">{{if .Contact}}{{.Contact}}{{else}}—{{end}}</td>
|
||||
<td>
|
||||
<span class="summary due-{{.Level}}">{{.Summary}}</span>
|
||||
</td>
|
||||
<td>{{range .TagList}}<span class="tagchip">{{.}}</span>{{end}}</td>
|
||||
<td class="right"><a class="btn btn-sm" href="/customers/{{.ID}}">详情</a></td>
|
||||
</tr>
|
||||
{{end}}
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
{{template "pager" .D.Pager}}
|
||||
{{else}}
|
||||
<div class="empty">
|
||||
<div class="empty-mark">票</div>
|
||||
{{if .D.Q}}
|
||||
<p>没有匹配「{{.D.Q}}」的客户。</p>
|
||||
<a class="btn" href="/customers">看全部客户</a>
|
||||
{{else}}
|
||||
<p>还没有客户。先建一位,再给他开套餐。</p>
|
||||
<a class="btn btn-primary" href="/customers/new">+ 新建客户</a>
|
||||
{{end}}
|
||||
</div>
|
||||
{{end}}
|
||||
</div>
|
||||
{{end}}
|
||||
Reference in New Issue
Block a user