Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
crawler.vmusicchart.vn
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Phạm Văn Đoan
crawler.vmusicchart.vn
Commits
b57573a7
Commit
b57573a7
authored
Mar 26, 2020
by
Phạm Văn Đoan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cập nhật task từ NCT
parent
49f2074b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
5 deletions
+9
-5
NctCrawlerTrackCommand.php
app/Console/Commands/Nct/NctCrawlerTrackCommand.php
+0
-1
NhacVnCrawlerTrackCommand.php
app/Console/Commands/NhacVn/NhacVnCrawlerTrackCommand.php
+4
-4
Kernel.php
app/Console/Kernel.php
+5
-0
No files found.
app/Console/Commands/Nct/NctCrawlerTrackCommand.php
View file @
b57573a7
...
@@ -60,7 +60,6 @@ class NctCrawlerTrackCommand extends Command
...
@@ -60,7 +60,6 @@ class NctCrawlerTrackCommand extends Command
$tracks
=
$this
->
trackRepository
->
processNctGetTrackInfoFromTop100
(
$url
);
$tracks
=
$this
->
trackRepository
->
processNctGetTrackInfoFromTop100
(
$url
);
$tracks_playlist
=
$this
->
trackRepository
->
processNctGetTrackInfoFromTop100Playlist
(
$url_playlist_top100
);
$tracks_playlist
=
$this
->
trackRepository
->
processNctGetTrackInfoFromTop100Playlist
(
$url_playlist_top100
);
//print_r($tracks); return false;
if
(
count
(
$tracks
)
==
0
)
return
false
;
if
(
count
(
$tracks
)
==
0
)
return
false
;
...
...
app/Console/Commands/N
ct/NctCrawlerUpdateTrackLin
kCommand.php
→
app/Console/Commands/N
hacVn/NhacVnCrawlerTrac
kCommand.php
View file @
b57573a7
<?php
<?php
namespace
App\Console\Commands\N
ct
;
namespace
App\Console\Commands\N
hacVn
;
use
App\Repositories\TrackRepository
;
use
App\Repositories\TrackRepository
;
use
Illuminate\Console\Command
;
use
Illuminate\Console\Command
;
class
N
ctCrawlerUpdateTrackLin
kCommand
extends
Command
class
N
hacVnCrawlerTrac
kCommand
extends
Command
{
{
/**
/**
* The name and signature of the console command.
* The name and signature of the console command.
*
*
* @var string
* @var string
*/
*/
protected
$signature
=
'n
ct:update-track-lin
k'
;
protected
$signature
=
'n
hacvn:get-trac
k'
;
/**
/**
* The console command description.
* The console command description.
*
*
* @var string
* @var string
*/
*/
protected
$description
=
'
Cập nhật link bài hát từ NCT
'
;
protected
$description
=
'
Lấy bài hát từ Nhạc VN
'
;
protected
$trackRepository
;
protected
$trackRepository
;
...
...
app/Console/Kernel.php
View file @
b57573a7
...
@@ -4,6 +4,7 @@ namespace App\Console;
...
@@ -4,6 +4,7 @@ namespace App\Console;
use
App\Console\Commands\CrontjobCommand
;
use
App\Console\Commands\CrontjobCommand
;
use
App\Console\Commands\Nct\NctCrawlerTrackCommand
;
use
App\Console\Commands\Nct\NctCrawlerTrackCommand
;
use
App\Console\Commands\NhacVn\NhacVnCrawlerTrackCommand
;
use
App\Console\Commands\Zing\ZingCrawlerNewRealeaseCommand
;
use
App\Console\Commands\Zing\ZingCrawlerNewRealeaseCommand
;
use
App\Console\Commands\Zing\ZingCrawlerTrackCommand
;
use
App\Console\Commands\Zing\ZingCrawlerTrackCommand
;
use
App\Console\Commands\CrawlerTrackImageCommand
;
use
App\Console\Commands\CrawlerTrackImageCommand
;
...
@@ -23,6 +24,7 @@ class Kernel extends ConsoleKernel
...
@@ -23,6 +24,7 @@ class Kernel extends ConsoleKernel
ZingCrawlerNewRealeaseCommand
::
class
,
ZingCrawlerNewRealeaseCommand
::
class
,
CrawlerTrackImageCommand
::
class
,
CrawlerTrackImageCommand
::
class
,
NctCrawlerTrackCommand
::
class
,
NctCrawlerTrackCommand
::
class
,
NhacVnCrawlerTrackCommand
::
class
,
];
];
...
@@ -42,8 +44,11 @@ class Kernel extends ConsoleKernel
...
@@ -42,8 +44,11 @@ class Kernel extends ConsoleKernel
$schedule
->
command
(
'zing:get-track'
)
->
everyThirtyMinutes
();
$schedule
->
command
(
'zing:get-track'
)
->
everyThirtyMinutes
();
$schedule
->
command
(
'zing:get-new-release-track'
)
->
hourlyAt
(
10
);
$schedule
->
command
(
'zing:get-new-release-track'
)
->
hourlyAt
(
10
);
$schedule
->
command
(
'crawler:get-track-image'
)
->
hourlyAt
(
15
);
$schedule
->
command
(
'crawler:get-track-image'
)
->
hourlyAt
(
15
);
$schedule
->
command
(
'nct:get-track'
)
->
hourlyAt
(
30
);
$schedule
->
command
(
'queue:work --once --timeout=120'
)
->
everyMinute
()
->
withoutOverlapping
();
$schedule
->
command
(
'queue:work --once --timeout=120'
)
->
everyMinute
()
->
withoutOverlapping
();
}
}
...
...
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