Browse Source

Adding makeshift home button, Added view your bike link

denney-fix-saving-dates
Jason Denney 11 years ago
parent
commit
9527725e07
  1. 1
      app/controllers/site_controller.rb
  2. 2
      app/views/bikes/new.html.haml
  3. 2
      app/views/bikes/show.html.haml
  4. 8
      app/views/site/index.html.haml

1
app/controllers/site_controller.rb

@ -1,5 +1,6 @@
class SiteController < ApplicationController class SiteController < ApplicationController
def index def index
@bike = current_user.bike
end end
end end

2
app/views/bikes/new.html.haml

@ -1,3 +1,5 @@
%a{ class: "btn btn-default btn-lg", href: root_path}
%span{ class:"icon-home"}
%h2 Add Bike %h2 Add Bike
%p %p

2
app/views/bikes/show.html.haml

@ -1,3 +1,5 @@
%a{ class: "btn btn-default btn-lg", href: root_path}
%span{ class:"icon-home"}
%h2 #{@bike.shop_id}: #{@bike.bike_brand} %h2 #{@bike.shop_id}: #{@bike.bike_brand}
%h2 #{@bike.model} %h2 #{@bike.model}

8
app/views/site/index.html.haml

@ -9,10 +9,10 @@
%p %p
%a{class: "btn btn-lg btn-block btn-primary", href: new_bike_path} Add Bike %a{class: "btn btn-lg btn-block btn-primary", href: new_bike_path} Add Bike
%p Your Bikes: - if !@bike.nil?
%ol %p
%li Bike 1 %a{class: "btn btn-lg btn-block btn-primary", href: bike_path(@bike)} View Your Bike
%li Bike 2
%p %p
%p %p

Loading…
Cancel
Save