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
255f9567
Commit
255f9567
authored
Jul 23, 2020
by
shajiaiming
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'feature/optimize' into develop
parents
5a4d7c8e
26cf8255
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
1 deletion
+6
-1
ArticleController.php
console/controllers/ArticleController.php
+6
-1
No files found.
console/controllers/ArticleController.php
View file @
255f9567
...
@@ -36,9 +36,14 @@ class ArticleController extends Controller
...
@@ -36,9 +36,14 @@ class ArticleController extends Controller
if
(
!
isset
(
$resp
[
'list'
]))
{
if
(
!
isset
(
$resp
[
'list'
]))
{
return
0
;
return
0
;
}
}
$create_time
=
Article
::
find
()
->
where
([
'source'
=>
1
])
->
max
(
'create_time'
);
$list
=
$resp
[
'list'
][
0
][
'lives'
];
$list
=
$resp
[
'list'
][
0
][
'lives'
];
if
(
$create_time
>=
$list
[
0
][
'created_at'
])
{
return
0
;
}
$list
=
Tools
::
arraySort
(
$list
,
'created_at'
,
SORT_ASC
);
$list
=
Tools
::
arraySort
(
$list
,
'created_at'
,
SORT_ASC
);
$create_time
=
Article
::
find
()
->
where
([
'source'
=>
1
])
->
max
(
'create_time'
);
$article
=
new
Article
();
$article
=
new
Article
();
foreach
(
$list
as
&
$item
)
{
foreach
(
$list
as
&
$item
)
{
...
...
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