Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
V
VeNJOB
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Nguyen Hoang Mai Phuong
VeNJOB
Commits
2a939b3b
Commit
2a939b3b
authored
Jul 23, 2021
by
Nguyen Hoang Mai Phuong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix crawler
parent
6ba9bc64
Pipeline
#1359
canceled with stages
in 0 seconds
Changes
1
Pipelines
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
2 deletions
+6
-2
lib/tasks/crawler.rake
+6
-2
No files found.
lib/tasks/crawler.rake
View file @
2a939b3b
...
...
@@ -103,8 +103,10 @@ namespace :crawler do
industries
=
detail_job
.
css
(
'div.detail-box.has-background ul li p a'
)
industries
.
each
do
|
industry
|
name
=
industry
.
text
.
squish
job_industries
<<
Industry
.
find_
_
by
(
name:
name
)
job_industries
<<
Industry
.
find_by
(
name:
name
)
end
next
if
job_industries_cities
.
nil?
job
.
industries
<<
job_industries
job_cities
=
[]
...
...
@@ -113,7 +115,9 @@ namespace :crawler do
name
=
city
.
text
job_cities
<<
City
.
find_by
(
name:
name
)
end
job
.
cities
<<
job_cities
unless
job_cities
.
nil?
next
if
job_cities
.
nil?
job
.
cities
<<
job_cities
end
page
+=
1
end
...
...
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