Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
token
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
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
wallet
token
Commits
a5a82f29
Commit
a5a82f29
authored
Dec 12, 2018
by
ZhuChunYang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
update
parent
2bab81c8
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
0 deletions
+20
-0
CoinReleaseCheckController.php
backend/controllers/CoinReleaseCheckController.php
+20
-0
No files found.
backend/controllers/CoinReleaseCheckController.php
View file @
a5a82f29
...
@@ -114,6 +114,26 @@ class CoinReleaseCheckController extends BaseController
...
@@ -114,6 +114,26 @@ class CoinReleaseCheckController extends BaseController
'check_first_uid'
=>
$model
->
check_first_uid
,
'check_first_uid'
=>
$model
->
check_first_uid
,
'check_second_uid'
=>
$model
->
check_second_uid
,
'check_second_uid'
=>
$model
->
check_second_uid
,
]);
]);
$user_id
=
Yii
::
$app
->
user
->
identity
->
id
;
$auth
=
Yii
::
$app
->
authManager
;
$user_role
=
current
(
$auth
->
getRolesByUser
(
$user_id
));
$user_role_name
=
$user_role
->
name
;
//超级管理员与国盾管理员可以审核所有企业用户
if
(
$user_id
==
Yii
::
$app
->
params
[
'admin'
]
||
$user_role_name
==
'国盾'
)
{
$user_role_name
=
''
;
}
else
{
// 判断该用户组是否有监控币种
$all_owners
=
CoinPublish
::
find
()
->
select
(
'owner'
)
->
asArray
()
->
all
();
$all_owners
=
array_unique
(
array_column
(
$all_owners
,
'owner'
));
while
(
!
in_array
(
$user_role_name
,
$all_owners
)
&&
$user_role_name
!=
'国盾'
)
{
$user_role_name
=
AuthItemChild
::
find
()
->
select
(
'parent'
)
->
where
([
'child'
=>
$user_role_name
])
->
asArray
()
->
One
();
$user_role_name
=
$user_role_name
[
'parent'
];
}
}
if
(
$user_role_name
)
{
$query
=
$query
->
andWhere
([
'company_name'
=>
$user_role_name
]);
}
if
(
$model
->
start_time
)
{
if
(
$model
->
start_time
)
{
$query
=
$query
->
andFilterWhere
([
'>='
,
'create_time'
,
$model
->
start_time
]);
$query
=
$query
->
andFilterWhere
([
'>='
,
'create_time'
,
$model
->
start_time
]);
}
}
...
...
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