Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
tl_estate
Project
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hujun
tl_estate
Commits
ef999d3a
Commit
ef999d3a
authored
May 13, 2019
by
clone
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
947a5017
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
2 deletions
+14
-2
LookShop.php
application/index/controller/LookShop.php
+4
-2
Basic.php
application/index/extend/Basic.php
+10
-0
No files found.
application/index/controller/LookShop.php
View file @
ef999d3a
...
...
@@ -14,6 +14,7 @@ use app\api_broker\service\VerifyService;
use
app\index\extend\Basic
;
use
app\model\TLookShopModel
;
use
app\model\TLookShopUser
;
use
app\model\Users
;
class
LookShop
extends
Basic
{
...
...
@@ -90,9 +91,10 @@ class LookShop extends Basic
"page_no" => 1,
"page_size" => 15
);*/
//验证权限
$verifyAgent
=
new
VerifyService
();
if
(
empty
(
$params
[
"user_id"
])
||
empty
(
$params
[
"agent_id"
])){
return
$this
->
response
(
"101"
,
"请求参数错误"
);
}
$pageNo
=
empty
(
$params
[
'page_no'
])
?
1
:
$params
[
'page_no'
];
$pageSize
=
empty
(
$params
[
'page_size'
])
?
25
:
$params
[
'page_size'
];
...
...
application/index/extend/Basic.php
View file @
ef999d3a
...
...
@@ -11,6 +11,7 @@ namespace app\index\extend;
*/
use
app\api_broker\service\RedisCacheService
;
use
app\api_broker\service\VipService
;
use
app\extra\RedisExt
;
use
app\model\AAgents
;
use
app\model\GHouses
;
...
...
@@ -264,6 +265,15 @@ class Basic extends Controller
$is_auth
=
1
;
}
}
//验证客户看铺日志权限
if
(
$requestPath
==
'index/lookShopUser'
&&
isset
(
$this
->
params
[
'user_id'
])
&&
isset
(
$this
->
params
[
'agent_id'
]))
{
$user_id
=
$this
->
params
[
'user_id'
];
$agent_id
=
$this
->
params
[
'agent_id'
];
$data
=
$redis_cache
->
getRedisCache
(
1
,
$user_id
);
if
(
$data
&&
$data
[
"agent_id"
]
==
$agent_id
){
$is_auth
=
1
;
}
}
}
if
(
empty
(
$is_auth
)
&&
$this
->
userId
!=
1
)
{
...
...
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