Added all controllers,html and routes

parent ed8aae7e
...@@ -159,3 +159,6 @@ DEPENDENCIES ...@@ -159,3 +159,6 @@ DEPENDENCIES
tzinfo-data tzinfo-data
uglifier (>= 1.3.0) uglifier (>= 1.3.0)
web-console (~> 2.0) web-console (~> 2.0)
BUNDLED WITH
1.10.4
class CarLogsController < ApplicationController
def index
render "car_logs/index.html.erb"
end
def add
render "car_logs/add_cars.html.erb"
end
end
class PagesController < ApplicationController
def index
render "pages/index.html.erb"
end
end
...@@ -2,4 +2,8 @@ class PagesController < ApplicationController ...@@ -2,4 +2,8 @@ class PagesController < ApplicationController
def index def index
render "pages/index.html.erb" render "pages/index.html.erb"
end end
def creators
render "pages/creators.html.erb"
end
end end
<h1>Add Cars</h1>
\ No newline at end of file
<h1>Car Records</h1>
<a href="/car_logs/add">Add Entry</a>
\ No newline at end of file
<h1>Meet the Creators</h1>
<body>
<li>Miko</li>
<li>Chesco</li>
<li>Manny</li>
</body>
<h1>Welcome to Our Parking Lot!</h1> <h1>Park Lot 1.0</h1>
<h2>Created by Miko, Chesco and Manny</h2> <a href="/pages">Meet the Creators</a>
\ No newline at end of file <a href="/car_logs">View Car Parking Log</a>
Rails.application.routes.draw do Rails.application.routes.draw do
root to: "pages#index" root to: "pages#index"
get "/pages", to: "pages#creators"
get "/car_logs", to: "car_logs#index"
get "/car_logs/add", to: "car_logs#add"
end end
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment