85 lines
3.9 KiB
PHP
85 lines
3.9 KiB
PHP
{extend name="../../admin/view/main"}
|
|
|
|
{block name="content"}
|
|
<div class="think-box-shadow">
|
|
<form class="layui-form layui-form-pane form-search" action="{:sysuri()}" onsubmit="return false" method="get" autocomplete="off">
|
|
<div class="layui-form-item layui-inline">
|
|
<label class="layui-form-label">账号邮箱</label>
|
|
<div class="layui-input-inline">
|
|
<input name="email" value="{$get.email|default=''}" placeholder="请输入账号邮箱" class="layui-input">
|
|
</div>
|
|
</div>
|
|
|
|
<div class="layui-form-item layui-inline">
|
|
<label class="layui-form-label">设备ID</label>
|
|
<div class="layui-input-inline">
|
|
<input name="used_by" value="{$get.used_by|default=''}" placeholder="请输入设备ID" class="layui-input">
|
|
</div>
|
|
</div>
|
|
|
|
<div class="layui-form-item layui-inline">
|
|
<button class="layui-btn layui-btn-primary"><i class="layui-icon"></i> 搜 索</button>
|
|
</div>
|
|
</form>
|
|
|
|
<table class="layui-table margin-top-10" lay-skin="line">
|
|
{notempty name='list'}
|
|
<thead>
|
|
<tr>
|
|
<th class='text-left'>设备ID</th>
|
|
<th class='text-left'>账号邮箱</th>
|
|
<th class='text-left'>代理商</th>
|
|
<th class='text-left'>激活码数量</th>
|
|
<th class='text-left'>总天数</th>
|
|
<th class='text-left'>首次激活</th>
|
|
<th class='text-left'>到期时间</th>
|
|
<th class='text-left'>剩余天数</th>
|
|
<th class='text-left'>缓存状态</th>
|
|
<th class='text-left'>冷却状态</th>
|
|
<th class='text-left'>操作</th>
|
|
</tr>
|
|
</thead>
|
|
{/notempty}
|
|
<tbody>
|
|
{foreach $list as $key=>$vo}
|
|
<tr>
|
|
<td class='text-left'>{$vo.used_by|default='--'}</td>
|
|
<td class='text-left'>{if isset($vo.email)}{$vo.email}{else}--{/if}</td>
|
|
<td class='text-left'>{if isset($vo.agent_names)}{$vo.agent_names}{else}--{/if}</td>
|
|
<td class='text-left'>{if isset($vo.total_codes)}{$vo.total_codes}{else}0{/if}</td>
|
|
<td class='text-left'>{if isset($vo.total_days)}{$vo.total_days} 天{else}0 天{/if}</td>
|
|
<td class='text-left'>{if isset($vo.first_activation)}{$vo.first_activation|format_datetime}{else}--{/if}</td>
|
|
<td class='text-left'>{if isset($vo.expire_time)}{$vo.expire_time}{else}--{/if}</td>
|
|
<td class='text-left'>
|
|
{if isset($vo.days_left) && $vo.days_left > 0}
|
|
<span class="color-green">{$vo.days_left} 天</span>
|
|
{else}
|
|
<span class="color-red">已过期</span>
|
|
{/if}
|
|
</td>
|
|
<td class='text-left'>
|
|
{if isset($vo.has_cache) && $vo.has_cache}
|
|
<span class="color-green">已缓存</span>
|
|
{else}
|
|
<span class="color-gray">无缓存</span>
|
|
{/if}
|
|
</td>
|
|
<td class='text-left'>
|
|
{if isset($vo.in_cooldown) && $vo.in_cooldown}
|
|
<span class="color-red">冷却中 {if isset($vo.cooldown_time)}(至 {$vo.cooldown_time}){/if}</span>
|
|
{else}
|
|
<span class="color-green">可用</span>
|
|
{/if}
|
|
</td>
|
|
<td class='text-left'>
|
|
{if auth("resetDevice")}
|
|
<a class="layui-btn layui-btn-sm layui-btn-warm" data-confirm="确定要重置该设备的账号吗?" data-csrf="{:systoken('resetDevice')}" data-action='{:url("resetDevice")}' data-value="machine_id#{$vo.used_by}">重置账号</a>
|
|
{/if}
|
|
</td>
|
|
</tr>
|
|
{/foreach}
|
|
</tbody>
|
|
</table>
|
|
{empty name='list'}<span class="notdata">没有记录哦</span>{else}{$pagehtml|raw|default=''}{/empty}
|
|
</div>
|
|
{/block}
|