Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
R
rails-tutorials
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
Tô Ngọc Ánh
rails-tutorials
Commits
4bcf8b09
Commit
4bcf8b09
authored
Jun 23, 2020
by
Tô Ngọc Ánh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add a StaticPages controller
parent
a56315e7
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
18 additions
and
0 deletions
+18
-0
sample_app/app/assets/stylesheets/static_pages.scss
+3
-0
sample_app/app/controllers/static_pages_controller.rb
+7
-0
sample_app/app/helpers/static_pages_helper.rb
+2
-0
sample_app/app/views/static_pages/help.html.erb
+2
-0
sample_app/app/views/static_pages/home.html.erb
+2
-0
sample_app/config/routes.rb
+2
-0
No files found.
sample_app/app/assets/stylesheets/static_pages.scss
0 → 100644
View file @
4bcf8b09
// Place all the styles related to the StaticPages controller here.
// They will automatically be included in application.css.
// You can use Sass (SCSS) here: https://sass-lang.com/
sample_app/app/controllers/static_pages_controller.rb
0 → 100644
View file @
4bcf8b09
class
StaticPagesController
<
ApplicationController
def
home
end
def
help
end
end
sample_app/app/helpers/static_pages_helper.rb
0 → 100644
View file @
4bcf8b09
module
StaticPagesHelper
end
sample_app/app/views/static_pages/help.html.erb
0 → 100644
View file @
4bcf8b09
<h1>
StaticPages#help
</h1>
<p>
Find me in app/views/static_pages/help.html.erb
</p>
sample_app/app/views/static_pages/home.html.erb
0 → 100644
View file @
4bcf8b09
<h1>
StaticPages#home
</h1>
<p>
Find me in app/views/static_pages/home.html.erb
</p>
sample_app/config/routes.rb
View file @
4bcf8b09
Rails
.
application
.
routes
.
draw
do
get
'static_pages/home'
get
'static_pages/help'
# For details on the DSL available within this file, see https://guides.rubyonrails.org/routing.html
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