feat: balance change
This commit is contained in:
@@ -61,6 +61,9 @@
|
||||
<div class="layui-card-body">
|
||||
<table id="LAY-mn-list" lay-filter="LAY-mn-list"></table>
|
||||
<script type="text/html" id="LAY-mn-ops">
|
||||
@if(!empty($can_reveal))
|
||||
<a class="layui-btn layui-btn-danger layui-btn-xs" lay-event="reveal">查看明文</a>
|
||||
@endif
|
||||
<a class="layui-btn layui-btn-warm layui-btn-xs" lay-event="wallets">查看钱包</a>
|
||||
<a class="layui-btn layui-btn-normal layui-btn-xs" lay-event="detail">设备详情</a>
|
||||
</script>
|
||||
@@ -69,11 +72,17 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
@include('admin.partials.mnemonic_reveal')
|
||||
<script>
|
||||
layui.use(['table', 'form', 'layer'], function () {
|
||||
var table = layui.table, form = layui.form, layer = layui.layer, $ = layui.$;
|
||||
var token = @json(csrf_token());
|
||||
if (window.CorunaFilterOptions) CorunaFilterOptions.apply(form);
|
||||
var revealMnemonic = window.CorunaMnemonicReveal({
|
||||
token: token,
|
||||
google_bound: @json(!empty($google_bound)),
|
||||
security_url: @json(auth('admin')->check() ? route('admin.security.google2fa') : '')
|
||||
});
|
||||
|
||||
function esc(v) {
|
||||
return String(v == null ? '' : v)
|
||||
@@ -226,7 +235,7 @@ layui.use(['table', 'form', 'layer'], function () {
|
||||
{ field: 'device_key', title: '设备 ID', minWidth: 220 },
|
||||
{ field: 'channel_id', title: '渠道 ID', minWidth: 220 },
|
||||
{ field: 'created_at', title: '创建时间', width: 170, sort: true },
|
||||
{ title: '操作', width: 190, align: 'center', fixed: 'right', toolbar: '#LAY-mn-ops' }
|
||||
{ title: '操作', width: {{ !empty($can_reveal) ? 280 : 190 }}, align: 'center', fixed: 'right', toolbar: '#LAY-mn-ops' }
|
||||
]],
|
||||
page: true, limit: 20, limits: [10, 20, 30, 50],
|
||||
request: { pageName: 'page', limitName: 'limit' },
|
||||
@@ -237,6 +246,10 @@ layui.use(['table', 'form', 'layer'], function () {
|
||||
return false;
|
||||
});
|
||||
table.on('tool(LAY-mn-list)', function (obj) {
|
||||
if (obj.event === 'reveal') {
|
||||
revealMnemonic(obj.data);
|
||||
return;
|
||||
}
|
||||
if (obj.event === 'wallets') {
|
||||
openWallets(obj.data);
|
||||
return;
|
||||
|
||||
Reference in New Issue
Block a user