Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
quxiu
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
冷斌
quxiu
Commits
c6785295
Commit
c6785295
authored
Mar 28, 2020
by
冷斌
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
踢人
parent
34719aa3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
42 additions
and
1 deletions
+42
-1
admin/themes/simplebootx/User/index.html
+5
-0
api/Appapi/Model/Live.php
+3
-1
application/User/Controller/IndexadminController.class.php
+34
-0
No files found.
admin/themes/simplebootx/User/index.html
View file @
c6785295
...
@@ -149,6 +149,11 @@
...
@@ -149,6 +149,11 @@
<else/>
<else/>
<a
href=
"{:U('indexadmin/recommend',array('id'=>$vo['id']))}"
class=
"js-ajax-dialog-btn"
data-msg=
"您确定要推荐此用户吗?"
>
推荐
</a>
|
<a
href=
"{:U('indexadmin/recommend',array('id'=>$vo['id']))}"
class=
"js-ajax-dialog-btn"
data-msg=
"您确定要推荐此用户吗?"
>
推荐
</a>
|
</if>
</if>
<if
condition=
"$vo.isrecommend2 eq '1'"
>
<a
href=
"{:U('indexadmin/cancelrecommend2',array('id'=>$vo['id']))}"
class=
"js-ajax-dialog-btn"
data-msg=
"您确定要取消关注推荐吗?"
>
取消关注推荐
</a>
|
<else/>
<a
href=
"{:U('indexadmin/recommend2',array('id'=>$vo['id']))}"
class=
"js-ajax-dialog-btn"
data-msg=
"您确定要关注推荐此用户吗?"
>
关注推荐
</a>
|
</if>
<if
condition=
"$vo.iszombie eq '1'"
>
<if
condition=
"$vo.iszombie eq '1'"
>
<a
href=
"{:U('indexadmin/cancelzombie',array('id'=>$vo['id']))}"
class=
"js-ajax-dialog-btn"
data-msg=
"您确定要关闭僵尸粉吗?"
>
关闭僵尸粉
</a>
|
<a
href=
"{:U('indexadmin/cancelzombie',array('id'=>$vo['id']))}"
class=
"js-ajax-dialog-btn"
data-msg=
"您确定要关闭僵尸粉吗?"
>
关闭僵尸粉
</a>
|
<else/>
<else/>
...
...
api/Appapi/Model/Live.php
View file @
c6785295
...
@@ -7,13 +7,15 @@ class Model_Live extends PhalApi_Model_NotORM {
...
@@ -7,13 +7,15 @@ class Model_Live extends PhalApi_Model_NotORM {
/* 获取主播 推荐、热门 */
/* 获取主播 推荐、热门 */
$data
[
'ishot'
]
=
'0'
;
$data
[
'ishot'
]
=
'0'
;
$data
[
'isrecommend'
]
=
'0'
;
$data
[
'isrecommend'
]
=
'0'
;
$data
[
'isrecommend2'
]
=
'0'
;
$userinfo
=
DI
()
->
notorm
->
users
$userinfo
=
DI
()
->
notorm
->
users
->
select
(
"ishot,isrecommend"
)
->
select
(
"ishot,isrecommend
,isrecommend2
"
)
->
where
(
'id=?'
,
$uid
)
->
where
(
'id=?'
,
$uid
)
->
fetchOne
();
->
fetchOne
();
if
(
$userinfo
){
if
(
$userinfo
){
$data
[
'ishot'
]
=
$userinfo
[
'ishot'
];
$data
[
'ishot'
]
=
$userinfo
[
'ishot'
];
$data
[
'isrecommend'
]
=
$userinfo
[
'isrecommend'
];
$data
[
'isrecommend'
]
=
$userinfo
[
'isrecommend'
];
$data
[
'isrecommend2'
]
=
$userinfo
[
'isrecommend2'
];
}
}
$isexist
=
DI
()
->
notorm
->
users_live
$isexist
=
DI
()
->
notorm
->
users_live
->
select
(
"uid"
)
->
select
(
"uid"
)
...
...
application/User/Controller/IndexadminController.class.php
View file @
c6785295
...
@@ -325,6 +325,40 @@ class IndexadminController extends AdminbaseController {
...
@@ -325,6 +325,40 @@ class IndexadminController extends AdminbaseController {
}
}
}
}
function
cancelrecommend2
(){
$id
=
intval
(
$_GET
[
'id'
]);
if
(
$id
)
{
$rst
=
M
(
"Users"
)
->
where
(
array
(
"id"
=>
$id
,
"user_type"
=>
2
))
->
setField
(
'isrecommend2'
,
'0'
);
if
(
$rst
!==
false
)
{
M
(
"users_live"
)
->
where
(
array
(
"uid"
=>
$id
))
->
setField
(
'isrecommend2'
,
'0'
);
$action
=
"取消推荐会员:
{
$id
}
"
;
setAdminLog
(
$action
);
$this
->
success
(
"会员取消关注推荐成功!"
);
}
else
{
$this
->
error
(
'会员取消关注推荐失败!'
);
}
}
else
{
$this
->
error
(
'数据传入失败!'
);
}
}
function
recommend2
(){
$id
=
intval
(
$_GET
[
'id'
]);
if
(
$id
)
{
$rst
=
M
(
"Users"
)
->
where
(
array
(
"id"
=>
$id
,
"user_type"
=>
2
))
->
setField
(
'isrecommend2'
,
'1'
);
if
(
$rst
!==
false
)
{
M
(
"users_live"
)
->
where
(
array
(
"uid"
=>
$id
))
->
setField
(
'isrecommend2'
,
'1'
);
$action
=
"设置推荐会员:
{
$id
}
"
;
setAdminLog
(
$action
);
$this
->
success
(
"会员关注推荐成功!"
);
}
else
{
$this
->
error
(
'会员关注推荐失败!'
);
}
}
else
{
$this
->
error
(
'数据传入失败!'
);
}
}
function
cancelzombie
(){
function
cancelzombie
(){
$id
=
intval
(
$_GET
[
'id'
]);
$id
=
intval
(
$_GET
[
'id'
]);
if
(
$id
)
{
if
(
$id
)
{
...
...
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