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
Mai Hoang Thai Ha
VenJob
Commits
6fa1254d
Commit
6fa1254d
authored
Jul 27, 2021
by
Mai Hoang Thai Ha
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add job details
parent
0114316b
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
67 additions
and
49 deletions
+67
-49
app/assets/stylesheets/custom.scss
+0
-33
app/controllers/jobs_controller.rb
+1
-2
app/views/jobs/_job_details.html.slim
+59
-9
app/views/top/_latest_jobs.html.slim
+4
-4
app/views/top/_top_cities.html.slim
+1
-0
app/views/top/_top_industries.html.slim
+1
-0
db/schema.rb
+1
-1
No files found.
app/assets/stylesheets/custom.scss
View file @
6fa1254d
...
@@ -83,14 +83,6 @@ footer {
...
@@ -83,14 +83,6 @@ footer {
// latest-job
// latest-job
.latest-job
{
.latest-job
{
h2
{
margin-bottom
:
30px
;
}
h2
:
:
after
{
content
:
""
;
display
:
block
;
border-bottom
:
1px
solid
rgba
(
0
,
0
,
0
,
0
.3
);
}
.job-item
{
.job-item
{
font-size
:
14px
;
font-size
:
14px
;
.job-title
{
.job-title
{
...
@@ -129,28 +121,11 @@ footer {
...
@@ -129,28 +121,11 @@ footer {
}
}
}
}
}
}
.
job-item
:
:
after
{
content
:
""
;
display
:
block
;
margin-top
:
10px
;
border-bottom
:
1px
solid
rgba
(
0
,
0
,
0
,
0
.3
);
}
.job-item
:last-child::after
{
border-bottom
:
none
;
}
}
}
// top_cities
// top_cities
.top_cities
{
.top_cities
{
h2
{
margin-bottom
:
30px
;
}
h2
:
:
after
{
content
:
""
;
display
:
block
;
border-bottom
:
1px
solid
rgba
(
0
,
0
,
0
,
0
.3
);
}
.city-item
{
.city-item
{
margin-bottom
:
12px
;
margin-bottom
:
12px
;
a
{
a
{
...
@@ -173,14 +148,6 @@ footer {
...
@@ -173,14 +148,6 @@ footer {
// top_industries
// top_industries
.top_industries
{
.top_industries
{
h2
{
margin-bottom
:
30px
;
}
h2
:
:
after
{
content
:
""
;
display
:
block
;
border-bottom
:
1px
solid
rgba
(
0
,
0
,
0
,
0
.3
);
}
.industry-item
{
.industry-item
{
margin-bottom
:
12px
;
margin-bottom
:
12px
;
a
{
a
{
...
...
app/controllers/jobs_controller.rb
View file @
6fa1254d
...
@@ -16,7 +16,6 @@ class JobsController < ApplicationController
...
@@ -16,7 +16,6 @@ class JobsController < ApplicationController
end
end
def
show
def
show
@job
=
Job
.
find_by
(
params
[
:id
])
@job
=
Job
.
find
(
params
[
:id
])
# debugger
end
end
end
end
app/views/jobs/_job_details.html.slim
View file @
6fa1254d
...
@@ -5,15 +5,65 @@
...
@@ -5,15 +5,65 @@
=
link_to
'Apply for this job'
,
'#'
,
class:
'btn btn-primary'
=
link_to
'Apply for this job'
,
'#'
,
class:
'btn btn-primary'
p
.text-secondary
p
.text-secondary
=
@job
.
company
.
name
=
@job
.
company
.
name
ul
.list-unstyled
.row.bg-light
-
@job
.
cities
.
each
do
|
city
|
.col-4
li
ul
.list-unstyled
=
city
.
name
li
p
.text-success
strong
=
@job
.
salary
|
Location
p
-
@job
.
cities
.
each
do
|
city
|
=
@job
.
description
p
=
info
=
city
.
name
li
strong
|
Salary
p
.text-success
=
@job
.
salary
.col-4
ul
.list-unstyled
li
strong
|
Type
p
=
@job
.
job_type
li
strong
|
Position
p
=
@job
.
position
.col-4
ul
.list-unstyled
li
strong
|
Experience
p
=
@job
.
experience
li
strong
|
Expiration date
p
=
@job
.
expiration_date
.job-benefits.my-4
h3
|
Benefits
.row
-
@job
.
benefit
.
split
(
'---'
).
each
do
|
benefit
|
li
.list-unstyled.col-4.text-secondary
=
benefit
.job-desc.my-4
h3
|
Description
=
@job
.
description
.
html_safe
()
.job-req.my-4
h3
|
Requirement
=
@job
.
requirement
.
html_safe
()
.job-info.my-4
h3
|
Other info
-
@job
.
other_info
.
split
(
'---'
).
each
do
|
info
|
li
.text-secondary
=
info
.job-apply.d-flex.align-items-center.justify-content-between
.job-apply.d-flex.align-items-center.justify-content-between
=
link_to
'Apply for this job'
,
'#'
,
class:
'btn btn-primary'
=
link_to
'Apply for this job'
,
'#'
,
class:
'btn btn-primary'
=
link_to
'Favorite'
,
'#'
,
class:
'btn btn-primary'
=
link_to
'Favorite'
,
'#'
,
class:
'btn btn-primary'
app/views/top/_latest_jobs.html.slim
View file @
6fa1254d
.latest-job.mb-5
.latest-job.mb-5
.container
.container
.mb-5
h2
h2
|
Latest jobs
|
Latest jobs
hr
.my-2
-
@latest_jobs
.
each
do
|
job
|
-
@latest_jobs
.
each
do
|
job
|
.job-item.mb-4
.job-item.mb-4
=
link_to
job
.
title
,
"#"
,
class:
"job-title"
=
link_to
job
.
title
,
"#"
,
class:
"job-title"
...
@@ -16,5 +17,5 @@
...
@@ -16,5 +17,5 @@
li
li
=
city
.
name
=
city
.
name
.job-desc
.job-desc
p
=
truncate
(
simple_format
(
job
.
description
),
escape:
false
,
length:
250
)
=
job
.
description
hr
.my-2
\ No newline at end of file
app/views/top/_top_cities.html.slim
View file @
6fa1254d
.top_cities.mb-5
.top_cities.mb-5
.container
.container
h2
Top
cities
h2
Top
cities
hr
.my-2
.row.align-items-start.mb-3
.row.align-items-start.mb-3
-
@top_cities
.
each
do
|
city
,
city_jobs
|
-
@top_cities
.
each
do
|
city
,
city_jobs
|
.col-4.city-item
.col-4.city-item
...
...
app/views/top/_top_industries.html.slim
View file @
6fa1254d
.top_industries.mb-5
.top_industries.mb-5
.container
.container
h2
Top
industries
h2
Top
industries
hr
.my-2
.row.align-items-start
.row.align-items-start
-
@top_industries
.
each
do
|
industry
,
industry_jobs
|
-
@top_industries
.
each
do
|
industry
,
industry_jobs
|
.col-4.industry-item
.col-4.industry-item
...
...
db/schema.rb
View file @
6fa1254d
...
@@ -109,7 +109,7 @@ ActiveRecord::Schema.define(version: 2021_07_22_080023) do
...
@@ -109,7 +109,7 @@ ActiveRecord::Schema.define(version: 2021_07_22_080023) do
end
end
create_table
"jobs"
,
charset:
"utf8mb4"
,
collation:
"utf8mb4_0900_ai_ci"
,
force: :cascade
do
|
t
|
create_table
"jobs"
,
charset:
"utf8mb4"
,
collation:
"utf8mb4_0900_ai_ci"
,
force: :cascade
do
|
t
|
t
.
string
"title"
t
.
string
"title"
,
null:
false
t
.
string
"job_type"
t
.
string
"job_type"
t
.
string
"salary"
t
.
string
"salary"
t
.
string
"experience"
t
.
string
"experience"
...
...
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