Velocipede's User, Sales, and Bike Inventory Web App
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

35 lines
449 B

class BikesController < AuthenticatedController
expose(:bike)
expose(:bikes) { Bike.order('id').paginate(:page => params[:page]) }
def index
end
def show
end
def new
end
def create
if bike.save
redirect_to bike
else
render :new
end
end
def update
if bike.save
redirect_to bike
else
render :edit
end
end
def destroy
bike.destroy
redirect_to bikes_url
end
end