Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
杨树贤
/
ic_welfare
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
6191a5be
authored
Sep 18, 2019
by
杨树贤
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
修复bug
parent
ea7c42c2
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
13 additions
and
4 deletions
app/Http/Controllers/Api/AssistsApiController.php
app/Http/Controllers/Api/CodesApiController.php
app/Http/Controllers/Api/ExchangeSettingsApiController.php
app/Http/Controllers/Api/IntegralsApiController.php
app/Http/Controllers/Api/InvitesApiController.php
app/Http/Transformers/UserExchangeTransformer.php
app/Http/Transformers/UserIntegralTransformer.php
app/Http/Controllers/Api/AssistsApiController.php
View file @
6191a5be
...
...
@@ -25,7 +25,7 @@ class AssistsApiController extends Controller
return
$this
->
apiReturn
(
0
,
'ok'
,
[
'data'
=>
$data
[
'data'
],
'count'
=>
$data
[
'count'
]
,
'count'
=>
array_get
(
$data
,
'count'
,
0
)
,
]);
}
...
...
app/Http/Controllers/Api/CodesApiController.php
View file @
6191a5be
...
...
@@ -25,7 +25,7 @@ class CodesApiController extends Controller
return
$this
->
apiReturn
(
0
,
'ok'
,
[
'data'
=>
$data
[
'data'
],
'count'
=>
$data
[
'count'
]
,
'count'
=>
array_get
(
$data
,
'count'
,
0
)
,
]);
}
...
...
app/Http/Controllers/Api/ExchangeSettingsApiController.php
View file @
6191a5be
...
...
@@ -30,6 +30,9 @@ class ExchangeSettingsApiController extends Controller
private
function
transformer
(
$data
)
{
if
(
!
is_array
(
$data
[
'data'
]))
{
return
$data
;
}
foreach
(
$data
[
'data'
]
as
&
$item
)
{
$item
[
'status'
]
=
$item
[
'status'
]
?
'使用中'
:
'已停用'
;
$item
[
'add_time'
]
=
date
(
'Y-m-d H:i:s'
,
$item
[
'add_time'
]);
...
...
app/Http/Controllers/Api/IntegralsApiController.php
View file @
6191a5be
...
...
@@ -25,7 +25,7 @@ class IntegralsApiController extends Controller
return
$this
->
apiReturn
(
0
,
'ok'
,
[
'data'
=>
$data
[
'data'
],
'count'
=>
$data
[
'count'
]
,
'count'
=>
array_get
(
$data
,
'count'
,
0
)
,
]);
}
...
...
app/Http/Controllers/Api/InvitesApiController.php
View file @
6191a5be
...
...
@@ -27,7 +27,7 @@ class InvitesApiController extends Controller
return
$this
->
apiReturn
(
0
,
'ok'
,
[
'data'
=>
$data
[
'data'
],
'count'
=>
$data
[
'count'
]
,
'count'
=>
array_get
(
$data
,
'count'
,
0
)
,
]);
}
...
...
app/Http/Transformers/UserExchangeTransformer.php
View file @
6191a5be
...
...
@@ -17,6 +17,9 @@ class UserExchangeTransformer
public
function
transform
(
$data
)
{
if
(
!
is_array
(
$data
[
'data'
]))
{
return
$data
;
}
$userIds
=
array_column
(
$data
[
'data'
],
'user_id'
);
$userMobiles
=
[];
$certifications
=
[];
...
...
app/Http/Transformers/UserIntegralTransformer.php
View file @
6191a5be
...
...
@@ -17,6 +17,9 @@ class UserIntegralTransformer
public
function
transform
(
$data
)
{
if
(
!
is_array
(
$data
[
'data'
]))
{
return
$data
;
}
$userIds
=
array_column
(
$data
[
'data'
],
'user_id'
);
$userMobiles
=
[];
$certifications
=
[];
...
...
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