Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
xiaozhan
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
冷斌
xiaozhan
Commits
3989ebd2
Commit
3989ebd2
authored
Mar 11, 2020
by
冷斌
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
a7b393de
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
188 additions
and
36 deletions
+188
-36
admin/themes/simplebootx/Admin/Coinrecord/index.html
+3
-1
application/Admin/Controller/CoinrecordController.class.php
+185
-35
No files found.
admin/themes/simplebootx/Admin/Coinrecord/index.html
View file @
3989ebd2
...
@@ -10,6 +10,7 @@
...
@@ -10,6 +10,7 @@
$action=array("sendgift"=>"赠送礼物","sendbarrage"=>"弹幕","loginbonus"=>"登录奖励","buyvip"=>"购买VIP","buycar"=>"购买坐骑","buyliang"=>"购买靓号",'game_bet'=>'游戏下注','game_return'=>'游戏退还','game_win'=>'游戏获胜','game_banker'=>'庄家收益','set_deposit'=>'上庄扣除','deposit_return'=>'下庄退还','roomcharge'=>'房间扣费','timecharge'=>'计时扣费','sendred'=>'发送红包','robred'=>'抢红包','buyguard'=>'开通守护','reg_reward'=>'注册奖励');
$action=array("sendgift"=>"赠送礼物","sendbarrage"=>"弹幕","loginbonus"=>"登录奖励","buyvip"=>"购买VIP","buycar"=>"购买坐骑","buyliang"=>"购买靓号",'game_bet'=>'游戏下注','game_return'=>'游戏退还','game_win'=>'游戏获胜','game_banker'=>'庄家收益','set_deposit'=>'上庄扣除','deposit_return'=>'下庄退还','roomcharge'=>'房间扣费','timecharge'=>'计时扣费','sendred'=>'发送红包','robred'=>'抢红包','buyguard'=>'开通守护','reg_reward'=>'注册奖励');
</php>
</php>
<form
class=
"well form-search"
name=
"form1"
method=
"post"
action=
"{:U('Coinrecord/index')}"
>
<form
class=
"well form-search"
name=
"form1"
method=
"post"
action=
"{:U('Coinrecord/index')}"
>
<!--
<if condition="$showlevel eq 0">
<if condition="$showlevel eq 0">
代理商:
代理商:
<select class="select_2" name="proxyid" id="proxyid">
<select class="select_2" name="proxyid" id="proxyid">
...
@@ -25,6 +26,7 @@
...
@@ -25,6 +26,7 @@
</volist>
</volist>
</select>
</select>
</if>
</if>
-->
收支类型:
收支类型:
<select
class=
"select_2"
name=
"type"
>
<select
class=
"select_2"
name=
"type"
>
<option
value=
""
>
全部
</option>
<option
value=
""
>
全部
</option>
...
@@ -48,7 +50,7 @@
...
@@ -48,7 +50,7 @@
主播:
主播:
<input
type=
"text"
name=
"touid"
style=
"width: 200px;"
value=
"{$formget.touid}"
placeholder=
"请输入主播ID值..."
>
<input
type=
"text"
name=
"touid"
style=
"width: 200px;"
value=
"{$formget.touid}"
placeholder=
"请输入主播ID值..."
>
<input
type=
"submit"
class=
"btn btn-primary"
value=
"搜索"
>
<input
type=
"submit"
class=
"btn btn-primary"
value=
"搜索"
>
<input
type=
"button"
class=
"btn btn-primary"
style=
"background-color: #1dccaa;"
value=
"导出"
onclick=
"form1.action='{:U('
Userauth
/export')}';form1.submit();"
/>
<input
type=
"button"
class=
"btn btn-primary"
style=
"background-color: #1dccaa;"
value=
"导出"
onclick=
"form1.action='{:U('
Coinrecord
/export')}';form1.submit();"
/>
</form>
</form>
<form
method=
"post"
class=
"js-ajax-form"
>
<form
method=
"post"
class=
"js-ajax-form"
>
...
...
application/Admin/Controller/CoinrecordController.class.php
View file @
3989ebd2
...
@@ -9,18 +9,13 @@ class CoinrecordController extends AdminbaseController {
...
@@ -9,18 +9,13 @@ class CoinrecordController extends AdminbaseController {
function
index
(){
function
index
(){
$adminid
=
$_SESSION
[
'ADMIN_ID'
];
$adminid
=
$_SESSION
[
'ADMIN_ID'
];
$role_id
=
$_SESSION
[
'role_id'
];
$role_id
=
$_SESSION
[
'role_id'
];
$Proxy
=
M
(
'users_proxy'
);
$Proxy
=
M
(
'users_proxy'
);
/* 代理业务员 */
/* 代理业务员 */
$showlevel
=
'0'
;
$showlevel
=
'0'
;
if
(
$role_id
==
6
){
//一级代理
if
(
$role_id
==
6
){
//一级代理
$showlevel
=
'1'
;
$showlevel
=
'1'
;
$where
[
'u.user_type'
]
=
'1'
;
$where
[
'u.user_type'
]
=
'1'
;
$where
[
'r.role_id'
]
=
'7'
;
$where
[
'r.role_id'
]
=
'7'
;
$path
=
setpath
(
$adminid
);
$path
=
setpath
(
$adminid
);
$uids
=
$Proxy
->
where
(
"type=-1 and path like '%
{
$path
}
%'"
)
->
getField
(
'uid'
,
true
);
$uids
=
$Proxy
->
where
(
"type=-1 and path like '%
{
$path
}
%'"
)
->
getField
(
'uid'
,
true
);
if
(
!
$uids
){
if
(
!
$uids
){
...
@@ -28,7 +23,7 @@ class CoinrecordController extends AdminbaseController {
...
@@ -28,7 +23,7 @@ class CoinrecordController extends AdminbaseController {
array_push
(
$uids
,
'0'
);
array_push
(
$uids
,
'0'
);
}
}
$where
[
'u.id'
]
=
array
(
'in'
,
$uids
);
$where
[
'u.id'
]
=
array
(
'in'
,
$uids
);
$promoterlist
=
M
(
'users u'
)
$promoterlist
=
M
(
'users u'
)
->
join
(
'__ROLE_USER__ r ON r.user_id = u.id'
)
->
join
(
'__ROLE_USER__ r ON r.user_id = u.id'
)
->
field
(
'u.id,u.user_login,user_nicename'
)
->
field
(
'u.id,u.user_login,user_nicename'
)
...
@@ -80,25 +75,25 @@ class CoinrecordController extends AdminbaseController {
...
@@ -80,25 +75,25 @@ class CoinrecordController extends AdminbaseController {
}
}
$v
[
'list'
]
=
$promoterlistj
;
$v
[
'list'
]
=
$promoterlistj
;
$proxylistj
[
$v
[
'id'
]]
=
$v
;
$proxylistj
[
$v
[
'id'
]]
=
$v
;
}
}
}
}
$this
->
assign
(
'proxylistj'
,
json_encode
(
$proxylistj
));
$this
->
assign
(
'proxylistj'
,
json_encode
(
$proxylistj
));
$this
->
assign
(
'promoterlist'
,
$promoterlist
);
$this
->
assign
(
'promoterlist'
,
$promoterlist
);
$this
->
assign
(
'showlevel'
,
$showlevel
);
$this
->
assign
(
'showlevel'
,
$showlevel
);
if
(
$role_id
==
6
||
$role_id
==
7
||
$role_id
==
8
||
$role_id
==
9
||
$_REQUEST
[
'proxyid'
]
!=
''
||
$_REQUEST
[
'promoterid'
]
!=
''
){
if
(
$role_id
==
6
||
$role_id
==
7
||
$role_id
==
8
||
$role_id
==
9
||
$_REQUEST
[
'proxyid'
]
!=
''
||
$_REQUEST
[
'promoterid'
]
!=
''
){
if
(
$_REQUEST
[
'proxyid'
]
!=
''
){
if
(
$_REQUEST
[
'proxyid'
]
!=
''
){
$adminid
=
$_REQUEST
[
'proxyid'
];
$adminid
=
$_REQUEST
[
'proxyid'
];
$_GET
[
'proxyid'
]
=
$_REQUEST
[
'proxyid'
];
$_GET
[
'proxyid'
]
=
$_REQUEST
[
'proxyid'
];
}
}
if
(
$_REQUEST
[
'promoterid'
]
!=
''
){
if
(
$_REQUEST
[
'promoterid'
]
!=
''
){
$adminid
=
$_REQUEST
[
'promoterid'
];
$adminid
=
$_REQUEST
[
'promoterid'
];
$_GET
[
'promoterid'
]
=
$_REQUEST
[
'promoterid'
];
$_GET
[
'promoterid'
]
=
$_REQUEST
[
'promoterid'
];
}
}
$path
=
setpath
(
$adminid
);
$path
=
setpath
(
$adminid
);
$uids
=
$Proxy
->
where
(
"path like '%
{
$path
}
%'"
)
->
getField
(
'uid'
,
true
);
$uids
=
$Proxy
->
where
(
"path like '%
{
$path
}
%'"
)
->
getField
(
'uid'
,
true
);
if
(
!
$uids
){
if
(
!
$uids
){
...
@@ -107,43 +102,44 @@ class CoinrecordController extends AdminbaseController {
...
@@ -107,43 +102,44 @@ class CoinrecordController extends AdminbaseController {
}
}
$map
[
'uid'
]
=
array
(
'in'
,
$uids
);
$map
[
'uid'
]
=
array
(
'in'
,
$uids
);
}
}
if
(
$_REQUEST
[
'type'
]
!=
''
){
if
(
$_REQUEST
[
'type'
]
!=
''
){
$map
[
'type'
]
=
$_REQUEST
[
'type'
];
$map
[
'type'
]
=
$_REQUEST
[
'type'
];
$_GET
[
'type'
]
=
$_REQUEST
[
'type'
];
$_GET
[
'type'
]
=
$_REQUEST
[
'type'
];
}
}
if
(
$_REQUEST
[
'action'
]
!=
''
){
if
(
$_REQUEST
[
'action'
]
!=
''
){
$map
[
'action'
]
=
$_REQUEST
[
'action'
];
$map
[
'action'
]
=
$_REQUEST
[
'action'
];
$_GET
[
'action'
]
=
$_REQUEST
[
'action'
];
$_GET
[
'action'
]
=
$_REQUEST
[
'action'
];
}
}
if
(
$_REQUEST
[
'start_time'
]
!=
''
){
if
(
$_REQUEST
[
'start_time'
]
!=
''
){
$map
[
'addtime'
]
=
array
(
"gt"
,
strtotime
(
$_REQUEST
[
'start_time'
]));
$map
[
'addtime'
]
=
array
(
"gt"
,
strtotime
(
$_REQUEST
[
'start_time'
]));
$_GET
[
'start_time'
]
=
$_REQUEST
[
'start_time'
];
$_GET
[
'start_time'
]
=
$_REQUEST
[
'start_time'
];
}
}
if
(
$_REQUEST
[
'end_time'
]
!=
''
){
if
(
$_REQUEST
[
'end_time'
]
!=
''
){
$map
[
'addtime'
]
=
array
(
"lt"
,
strtotime
(
$_REQUEST
[
'end_time'
]));
$map
[
'addtime'
]
=
array
(
"lt"
,
strtotime
(
$_REQUEST
[
'end_time'
]));
$_GET
[
'end_time'
]
=
$_REQUEST
[
'end_time'
];
$_GET
[
'end_time'
]
=
$_REQUEST
[
'end_time'
];
}
}
if
(
$_REQUEST
[
'start_time'
]
!=
''
&&
$_REQUEST
[
'end_time'
]
!=
''
){
if
(
$_REQUEST
[
'start_time'
]
!=
''
&&
$_REQUEST
[
'end_time'
]
!=
''
){
$map
[
'addtime'
]
=
array
(
"between"
,
array
(
strtotime
(
$_REQUEST
[
'start_time'
]),
strtotime
(
$_REQUEST
[
'end_time'
])));
$map
[
'addtime'
]
=
array
(
"between"
,
array
(
strtotime
(
$_REQUEST
[
'start_time'
]),
strtotime
(
$_REQUEST
[
'end_time'
])));
$_GET
[
'start_time'
]
=
$_REQUEST
[
'start_time'
];
$_GET
[
'start_time'
]
=
$_REQUEST
[
'start_time'
];
$_GET
[
'end_time'
]
=
$_REQUEST
[
'end_time'
];
$_GET
[
'end_time'
]
=
$_REQUEST
[
'end_time'
];
}
}
if
(
$_REQUEST
[
'uid'
]
!=
''
){
if
(
$_REQUEST
[
'uid'
]
!=
''
){
$map
[
'uid'
]
=
$_REQUEST
[
'uid'
];
$map
[
'uid'
]
=
$_REQUEST
[
'uid'
];
$_GET
[
'uid'
]
=
$_REQUEST
[
'uid'
];
$_GET
[
'uid'
]
=
$_REQUEST
[
'uid'
];
}
}
if
(
$_REQUEST
[
'touid'
]
!=
''
){
if
(
$_REQUEST
[
'touid'
]
!=
''
){
$map
[
'touid'
]
=
$_REQUEST
[
'touid'
];
$map
[
'touid'
]
=
$_REQUEST
[
'touid'
];
$_GET
[
'touid'
]
=
$_REQUEST
[
'touid'
];
$_GET
[
'touid'
]
=
$_REQUEST
[
'touid'
];
}
}
$coin
=
M
(
"users_coinrecord"
);
$coin
=
M
(
"users_coinrecord"
);
$Users
=
M
(
"users"
);
$Users
=
M
(
"users"
);
$Game
=
M
(
"game"
);
$Game
=
M
(
"game"
);
...
@@ -160,7 +156,7 @@ class CoinrecordController extends AdminbaseController {
...
@@ -160,7 +156,7 @@ class CoinrecordController extends AdminbaseController {
'4'
=>
'开心牛仔'
,
'4'
=>
'开心牛仔'
,
'5'
=>
'二八贝'
,
'5'
=>
'二八贝'
,
);
);
$count
=
$coin
->
where
(
$map
)
->
count
();
$count
=
$coin
->
where
(
$map
)
->
count
();
$page
=
$this
->
page
(
$count
,
20
);
$page
=
$this
->
page
(
$count
,
20
);
$lists
=
$coin
$lists
=
$coin
...
@@ -168,7 +164,7 @@ class CoinrecordController extends AdminbaseController {
...
@@ -168,7 +164,7 @@ class CoinrecordController extends AdminbaseController {
->
order
(
"addtime DESC"
)
->
order
(
"addtime DESC"
)
->
limit
(
$page
->
firstRow
.
','
.
$page
->
listRows
)
->
limit
(
$page
->
firstRow
.
','
.
$page
->
listRows
)
->
select
();
->
select
();
foreach
(
$lists
as
$k
=>
$v
){
foreach
(
$lists
as
$k
=>
$v
){
$userinfo
=
$Users
->
field
(
"user_nicename"
)
->
where
(
"id='
$v[uid]
'"
)
->
find
();
$userinfo
=
$Users
->
field
(
"user_nicename"
)
->
where
(
"id='
$v[uid]
'"
)
->
find
();
$lists
[
$k
][
'userinfo'
]
=
$userinfo
;
$lists
[
$k
][
'userinfo'
]
=
$userinfo
;
...
@@ -235,31 +231,185 @@ class CoinrecordController extends AdminbaseController {
...
@@ -235,31 +231,185 @@ class CoinrecordController extends AdminbaseController {
$giftinfo
[
'giftname'
]
=
'未知'
;
$giftinfo
[
'giftname'
]
=
'未知'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
}
}
}
$this
->
assign
(
'lists'
,
$lists
);
$this
->
assign
(
'lists'
,
$lists
);
$this
->
assign
(
'formget'
,
$_GET
);
$this
->
assign
(
'formget'
,
$_GET
);
$this
->
assign
(
"page"
,
$page
->
show
(
'Admin'
));
$this
->
assign
(
"page"
,
$page
->
show
(
'Admin'
));
$this
->
display
();
$this
->
display
();
}
}
function
del
(){
function
export
()
{
$map
=
[];
if
(
$_REQUEST
[
'type'
]
!=
''
){
$map
[
'type'
]
=
$_REQUEST
[
'type'
];
}
if
(
$_REQUEST
[
'action'
]
!=
''
){
$map
[
'action'
]
=
$_REQUEST
[
'action'
];
}
if
(
$_REQUEST
[
'start_time'
]
!=
''
){
$map
[
'addtime'
]
=
array
(
"gt"
,
strtotime
(
$_REQUEST
[
'start_time'
]));
}
if
(
$_REQUEST
[
'end_time'
]
!=
''
){
$map
[
'addtime'
]
=
array
(
"lt"
,
strtotime
(
$_REQUEST
[
'end_time'
]));
}
if
(
$_REQUEST
[
'start_time'
]
!=
''
&&
$_REQUEST
[
'end_time'
]
!=
''
){
$map
[
'addtime'
]
=
array
(
"between"
,
array
(
strtotime
(
$_REQUEST
[
'start_time'
]),
strtotime
(
$_REQUEST
[
'end_time'
])));
$_GET
[
'start_time'
]
=
$_REQUEST
[
'start_time'
];
}
if
(
$_REQUEST
[
'uid'
]
!=
''
){
$map
[
'uid'
]
=
$_REQUEST
[
'uid'
];
}
if
(
$_REQUEST
[
'touid'
]
!=
''
){
$map
[
'touid'
]
=
$_REQUEST
[
'touid'
];
}
$coin
=
M
(
"users_coinrecord"
);
$Users
=
M
(
"users"
);
$Game
=
M
(
"game"
);
$Gift
=
M
(
"gift"
);
$Vip
=
M
(
"vip"
);
$Car
=
M
(
"car"
);
$Liang
=
M
(
"liang"
);
$Guard
=
M
(
"guard"
);
$game_action
=
array
(
'0'
=>
''
,
'1'
=>
'智勇三张'
,
'2'
=>
'海盗船长'
,
'3'
=>
'转盘'
,
'4'
=>
'开心牛仔'
,
'5'
=>
'二八贝'
,
);
$count
=
$coin
->
where
(
$map
)
->
count
();
$page
=
$this
->
page
(
$count
,
20
);
$lists
=
$coin
->
where
(
$map
)
->
order
(
"addtime DESC"
)
->
limit
(
$page
->
firstRow
.
','
.
$page
->
listRows
)
->
select
();
$type
=
array
(
"income"
=>
"收入"
,
"expend"
=>
"支出"
);
$actions
=
array
(
"sendgift"
=>
"赠送礼物"
,
"sendbarrage"
=>
"弹幕"
,
"loginbonus"
=>
"登录奖励"
,
"buyvip"
=>
"购买VIP"
,
"buycar"
=>
"购买坐骑"
,
"buyliang"
=>
"购买靓号"
,
'game_bet'
=>
'游戏下注'
,
'game_return'
=>
'游戏退还'
,
'game_win'
=>
'游戏获胜'
,
'game_banker'
=>
'庄家收益'
,
'set_deposit'
=>
'上庄扣除'
,
'deposit_return'
=>
'下庄退还'
,
'roomcharge'
=>
'房间扣费'
,
'timecharge'
=>
'计时扣费'
,
'sendred'
=>
'发送红包'
,
'robred'
=>
'抢红包'
,
'buyguard'
=>
'开通守护'
,
'reg_reward'
=>
'注册奖励'
);
foreach
(
$lists
as
$k
=>
$v
){
$userinfo
=
$Users
->
field
(
"user_nicename"
)
->
where
(
"id='
$v[uid]
'"
)
->
find
();
$lists
[
$k
][
'userinfo'
]
=
$userinfo
;
$touserinfo
=
$Users
->
field
(
"user_nicename"
)
->
where
(
"id='
$v[touid]
'"
)
->
find
();
$lists
[
$k
][
'touserinfo'
]
=
$touserinfo
;
$lists
[
$k
][
'user_nicename'
]
=
$userinfo
[
'user_nicename'
]
.
"("
.
$v
[
'uid'
]
.
")"
;
$lists
[
$k
][
'touser_nicename'
]
=
$touserinfo
[
'user_nicename'
]
.
"("
.
$v
[
'touid'
]
.
")"
;
$action
=
$v
[
'action'
];
$lists
[
$k
][
'action'
]
=
$actions
[
$action
];
$lists
[
$k
][
'type'
]
=
$type
[
$v
[
'type'
]];
if
(
$action
==
'sendgift'
){
$giftinfo
=
$Gift
->
field
(
"giftname"
)
->
where
(
"id='
$v[giftid]
'"
)
->
find
();
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'loginbonus'
){
$giftinfo
[
'giftname'
]
=
'第'
.
$v
[
'giftid'
]
.
'天'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'sendbarrage'
){
$giftinfo
[
'giftname'
]
=
'弹幕'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'game_bet'
||
$action
==
'game_return'
||
$action
==
'game_win'
||
$action
==
'game_brokerage'
||
$action
==
'game_banker'
){
$info
=
$Game
->
field
(
'action'
)
->
where
(
"id=
{
$v
[
'giftid'
]
}
"
)
->
find
();
$giftinfo
[
'giftname'
]
=
$game_action
[
$info
[
'action'
]];
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'set_deposit'
){
$giftinfo
[
'giftname'
]
=
'上庄扣除'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'deposit_return'
){
$giftinfo
[
'giftname'
]
=
'下庄退还'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'roomcharge'
){
$giftinfo
[
'giftname'
]
=
'房间扣费'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'timecharge'
){
$giftinfo
[
'giftname'
]
=
'计时扣费'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'buyvip'
){
$info
=
$Vip
->
field
(
"name"
)
->
where
(
"id='
{
$v
[
giftid
]
}
'"
)
->
find
();
$giftinfo
[
'giftname'
]
=
$info
[
'name'
];
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'buycar'
){
$info
=
$Car
->
field
(
"name"
)
->
where
(
"id='
{
$v
[
giftid
]
}
'"
)
->
find
();
$giftinfo
[
'giftname'
]
=
$info
[
'name'
];
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'buyliang'
){
$info
=
$Liang
->
field
(
"name"
)
->
where
(
"id='
{
$v
[
giftid
]
}
'"
)
->
find
();
$giftinfo
[
'giftname'
]
=
$info
[
'name'
];
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'sendred'
){
$giftinfo
[
'giftname'
]
=
'发送红包'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'robred'
){
$giftinfo
[
'giftname'
]
=
'抢红包'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'buyguard'
){
$info
=
$Guard
->
field
(
"name"
)
->
where
(
"id='
{
$v
[
giftid
]
}
'"
)
->
find
();
$giftinfo
[
'giftname'
]
=
$info
[
'name'
];
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'reg_reward'
){
$giftinfo
[
'giftname'
]
=
'注册奖励'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'luckgift'
){
$giftinfo
[
'giftname'
]
=
'礼物中奖'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
if
(
$action
==
'jackpotwin'
){
$giftinfo
[
'giftname'
]
=
'奖池中奖'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
else
{
$giftinfo
[
'giftname'
]
=
'未知'
;
$lists
[
$k
][
'giftinfo'
]
=
$giftinfo
;
}
//{$vo['giftinfo']['giftname']} ( {$vo['giftid']} )
$lists
[
$k
][
'gift_behavior'
]
=
$giftinfo
[
'giftname'
]
.
"("
.
$v
[
'giftid'
]
.
")"
;
$lists
[
$k
][
'addtime'
]
=
date
(
"Y-m-d H:i:s"
,
$v
[
'addtime'
]);
}
$xlsName
=
"Excel"
;
$action
=
"导出消费记录:"
.
$coin
->
getLastSql
();
setAdminLog
(
$action
);
$cellName
=
array
(
'A'
,
'B'
,
'C'
,
'D'
,
'E'
,
'F'
,
'G'
,
'H'
,
'I'
,
'J'
);
$xlsCell
=
array
(
array
(
'id'
,
'序号'
),
array
(
'type'
,
'收支类型'
),
array
(
'action'
,
'收支行为'
),
array
(
'user_nicename'
,
'会员'
),
array
(
'touser_nicename'
,
'主播'
),
array
(
'gift_behavior'
,
'行为说明'
),
array
(
'giftcount'
,
'数量'
),
array
(
'totalcoin'
,
'总价'
),
array
(
'showid'
,
'直播id'
),
array
(
'addtime'
,
'时间'
),
);
exportExcel
(
$xlsName
,
$xlsCell
,
$lists
,
$cellName
);
}
function
del
(){
$id
=
intval
(
$_GET
[
'id'
]);
$id
=
intval
(
$_GET
[
'id'
]);
if
(
$id
){
if
(
$id
){
$result
=
M
(
"users_coinrecord"
)
->
delete
(
$id
);
$result
=
M
(
"users_coinrecord"
)
->
delete
(
$id
);
if
(
$result
){
if
(
$result
){
$this
->
success
(
'删除成功'
);
$this
->
success
(
'删除成功'
);
}
else
{
}
else
{
$this
->
error
(
'删除失败'
);
$this
->
error
(
'删除失败'
);
}
}
}
else
{
}
else
{
$this
->
error
(
'数据传入失败!'
);
$this
->
error
(
'数据传入失败!'
);
}
}
$this
->
display
();
$this
->
display
();
}
}
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment