Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
M
MIS21MidtermsParkingLot
Project
Project
Details
Activity
Releases
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Dean Krisitan Bardeloza
MIS21MidtermsParkingLot
Commits
47c07067
Commit
47c07067
authored
Jul 05, 2016
by
Bianca Tarun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
edited car_logs_controller.rb
parent
59dbbc58
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
12 additions
and
9 deletions
+12
-9
Gemfile.lock
parkinglot/Gemfile.lock
+3
-0
car_logs_controller.rb
parkinglot/app/controllers/car_logs_controller.rb
+1
-1
add.html.erb
parkinglot/app/views/carlog/add.html.erb
+2
-2
index.html.erb
parkinglot/app/views/carlog/index.html.erb
+1
-1
routes.rb
parkinglot/config/routes.rb
+5
-5
No files found.
parkinglot/Gemfile.lock
View file @
47c07067
...
@@ -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
parkinglot/app/controllers/car_logs_controller.rb
View file @
47c07067
class
CarLogController
<
ApplicationController
class
CarLog
s
Controller
<
ApplicationController
def
index
def
index
@car_logs
=
Carlog
.
all
@car_logs
=
Carlog
.
all
...
...
parkinglot/app/views/carlog/add.html.erb
View file @
47c07067
<h1>
Add Car
</h1>
<h1>
Add Car
</h1>
<%=
form_tag
(
"/car_log/add"
,
method:
"post"
)
do
%>
<%=
form_tag
(
"/car_log
s
/add"
,
method:
"post"
)
do
%>
<label>
Plate Number:
</label>
<label>
Plate Number:
</label>
<input
type=
"text"
name=
"plate_number"
/>
<input
type=
"text"
name=
"plate_number"
/>
<hr>
<hr>
...
@@ -37,4 +37,4 @@
...
@@ -37,4 +37,4 @@
<input
type=
"submit"
value=
"Add Car"
/>
<input
type=
"submit"
value=
"Add Car"
/>
<%
end
%>
<%
end
%>
<hr>
<hr>
<a
href=
"/car_log"
>
View All Cars
</a>
<a
href=
"/car_logs"
>
View All Cars
</a>
\ No newline at end of file
\ No newline at end of file
parkinglot/app/views/carlog/index.html.erb
View file @
47c07067
...
@@ -45,6 +45,6 @@
...
@@ -45,6 +45,6 @@
</tbody>
</tbody>
</table>
</table>
<hr>
<hr>
<a
href=
"/car_log/add"
>
Add New Sport
</a>
<a
href=
"/car_log
s
/add"
>
Add New Sport
</a>
<hr>
<hr>
<a
href=
"/"
>
Go back to Homepage
</a>
<a
href=
"/"
>
Go back to Homepage
</a>
\ No newline at end of file
parkinglot/config/routes.rb
View file @
47c07067
Rails
.
application
.
routes
.
draw
do
Rails
.
application
.
routes
.
draw
do
root
to:
"pages#index"
root
to:
"pages#index"
get
"/car_log
"
,
to:
"car_log
#index"
get
"/car_log
s"
,
to:
"car_logs
#index"
get
"/car_log
/add"
,
to:
"car_log
#add"
get
"/car_log
s/add"
,
to:
"car_logs
#add"
get
"/car_log
/delete"
,
to:
"car_log
#delete"
get
"/car_log
s/delete"
,
to:
"car_logs
#delete"
post
"/car_log
/add"
,
to:
"car_log
#add"
post
"/car_log
s/add"
,
to:
"car_logs
#add"
post
"/car_log
/delete"
,
to:
"car_log
#delete"
post
"/car_log
s/delete"
,
to:
"car_logs
#delete"
end
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