提交 17bbe870 编写于 作者: D devil_gong

细节优化

上级 90fea6f5
......@@ -148,9 +148,22 @@
</div>
</td>
<td class="view-operation">
<a href="{{:PluginsAdminUrl('wallet', 'wallet', 'saveinfo', ['id'=>$v['id']])}}">
<button class="am-btn am-btn-secondary am-btn-xs am-radius am-icon-edit"> 编辑</button>
</a>
<div>
<a href="{{:PluginsAdminUrl('wallet', 'wallet', 'saveinfo', ['id'=>$v['id']])}}">
<button class="am-btn am-btn-primary am-btn-xs am-radius m-r-5 am-icon-edit"> 编辑</button>
</a>
<a href="{{:PluginsAdminUrl('wallet', 'recharge', 'index', ['keywords'=>$v['user']['user_name_view']])}}">
<button class="am-btn am-btn-secondary am-btn-xs am-radius am-icon-shield"> 充值</button>
</a>
</div>
<div>
<a href="{{:PluginsAdminUrl('wallet', 'cash', 'index', ['keywords'=>$v['user']['user_name_view']])}}">
<button class="am-btn am-btn-warning am-btn-xs am-radius m-t-10 m-r-5 am-icon-money"> 提现</button>
</a>
<a href="{{:PluginsAdminUrl('wallet', 'walletlog', 'index', ['keywords'=>$v['user']['user_name_view']])}}">
<button class="am-btn am-btn-default am-btn-xs am-radius m-t-10 am-icon-history"> 明细</button>
</a>
</div>
</td>
</tr>
{{/foreach}}
......
......@@ -11,7 +11,25 @@
<div class="walletlog-content">
<!-- form start -->
<form class="am-form form-validation form-search" method="post" action="{{:PluginsAdminUrl('wallet', 'walletlog', 'index')}}" request-type="form">
<table class="so-list more-where">
<div class="thin">
<div class="am-input-group am-input-group-sm am-fl so">
<input type="text" autocomplete="off" name="keywords" class="am-radius" placeholder="用户名/昵称/手机/邮箱" value="{{if !empty($params.keywords)}}{{$params.keywords}}{{/if}}" />
<span class="am-input-group-btn">
<button class="am-btn am-btn-default am-radius" type="submit" data-am-loading="{spinner:'circle-o-notch', loadingText:'搜索中...'}">搜索</button>
</span>
</div>
<label class="am-fl thin_sub more-submit">
更多筛选条件
{{if isset($params['is_more']) and $params['is_more'] eq 1}}
<input type="checkbox" name="is_more" value="1" id="is_more" checked />
<i class="am-icon-angle-up"></i>
{{else /}}
<input type="checkbox" name="is_more" value="1" id="is_more" />
<i class="am-icon-angle-down"></i>
{{/if}}
</label>
</div>
<table class="so-list more-where {{if !isset($params['is_more'])}}none{{/if}}">
<tbody>
<tr>
<td>
......@@ -63,9 +81,10 @@
<table class="am-table am-table-striped am-table-hover m-t-10">
<thead>
<tr>
<th class="am-hide-sm-only">业务类型</th>
<th class="am-hide-sm-only">操作类型</th>
<th>金额类型</th>
<th class="am-hide-md-down">用户信息</th>
<th class="am-hide-sm-only">业务</th>
<th class="am-hide-sm-only">操作</th>
<th>类型</th>
<th>操作金额(元)</th>
<th class="am-hide-sm-only">原始金额(元)</th>
<th>最新金额(元)</th>
......@@ -77,6 +96,19 @@
{{if !empty($data_list)}}
{{foreach $data_list as $v}}
<tr>
<td class="user-info am-hide-md-down">
{{if !empty($v['user'])}}
<img src="{{$v.user.avatar}}" alt="{{$v.user.user_name_view}}" class="am-img-thumbnail am-radius am-align-left" />
<ul class="user-base">
<li>名称:{{if empty($v['user']['username'])}}<span class="cr-ccc">未填写</span>{{else /}}{{$v.user.username}}{{/if}}</li>
<li>昵称:{{if empty($v['user']['nickname'])}}<span class="cr-ccc">未填写</span>{{else /}}{{$v.user.nickname}}{{/if}}</li>
<li>手机:{{if empty($v['user']['mobile'])}}<span class="cr-ccc">未填写</span>{{else /}}{{$v.user.mobile}}{{/if}}</li>
<li>邮箱:{{if empty($v['user']['email'])}}<span class="cr-ccc">未填写</span>{{else /}}{{$v.user.email}}{{/if}}</li>
</ul>
{{else /}}
用户信息异常
{{/if}}
</td>
<td class="am-hide-sm-only">{{$v.business_type_text}}</td>
<td class="am-hide-sm-only">
{{if $v['operation_type'] eq 0}}
......@@ -112,6 +144,21 @@
</div>
<div class="am-popup-bd">
<dl class="dl-content">
<dt>用户信息</dt>
<dd class="user-info">
{{if !empty($v['user'])}}
<img src="{{$v.user.avatar}}" alt="{{$v.user.user_name_view}}" class="am-img-thumbnail am-radius am-align-left" />
<ul class="user-base">
<li>名称:{{if empty($v['user']['username'])}}<span class="cr-ccc">未填写</span>{{else /}}{{$v.user.username}}{{/if}}</li>
<li>昵称:{{if empty($v['user']['nickname'])}}<span class="cr-ccc">未填写</span>{{else /}}{{$v.user.nickname}}{{/if}}</li>
<li>手机:{{if empty($v['user']['mobile'])}}<span class="cr-ccc">未填写</span>{{else /}}{{$v.user.mobile}}{{/if}}</li>
<li>邮箱:{{if empty($v['user']['email'])}}<span class="cr-ccc">未填写</span>{{else /}}{{$v.user.email}}{{/if}}</li>
</ul>
{{else /}}
用户信息异常
{{/if}}
</dd>
<dt>业务类型</dt>
<dd>{{$v.business_type_text}}</dd>
......
......@@ -273,6 +273,9 @@ class BaseService
$money_type_list = WalletService::$money_type_list;
foreach($data as &$v)
{
// 用户信息
$v['user'] = self::GetUserInfo($v['user_id']);
// 业务类型
$v['business_type_text'] = (isset($v['business_type']) && isset($business_type_list[$v['business_type']])) ? $business_type_list[$v['business_type']]['name'] : '未知';
......@@ -325,6 +328,19 @@ class BaseService
$where[] = ['user_id', '=', $params['user']['id']];
}
// 用户
if(!empty($params['keywords']))
{
$user_ids = Db::name('User')->where('username|nickname|mobile|email', '=', $params['keywords'])->column('id');
if(!empty($user_ids))
{
$where[] = ['user_id', 'in', $user_ids];
} else {
// 无数据条件,避免用户搜索条件没有数据造成的错觉
$where[] = ['id', '=', 0];
}
}
// 业务类型
if(isset($params['business_type']) && $params['business_type'] > -1)
{
......
/**
* 列表
*/
.wallet-content .view-operation {
width: 160px;
}
.wallet-content .view-operation button {
width: calc(50% - 5px);
}
/**
* 金额
*/
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册