From 76ffda9cad519bc5b5ad3a6fcd6c1051bd10ae4a Mon Sep 17 00:00:00 2001 From: Rick Barrette Date: Thu, 28 Apr 2016 11:57:54 -0400 Subject: [PATCH] Update vehicles_controller.rb --- app/controllers/vehicles_controller.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/controllers/vehicles_controller.rb b/app/controllers/vehicles_controller.rb index 92d97f1..595a957 100644 --- a/app/controllers/vehicles_controller.rb +++ b/app/controllers/vehicles_controller.rb @@ -37,7 +37,7 @@ class VehiclesController < ApplicationController def show @vehicle = Vehicle.find_by_id(params[:id]) if @vehicle - @customer = @vehicle.qbo_customer.name if @vehicle.qbo_customer + @customer = @vehicle.customer.name if @vehicle.customer else flash[:error] = "Vehicle Not Found" render :index @@ -47,7 +47,7 @@ class VehiclesController < ApplicationController # return an HTML form for editing a vehicle def edit @vehicle = Vehicle.find_by_id(params[:id]) - @customer = @vehicle.qbo_customer.id if @vehicle.qbo_customer + @customer = @vehicle.customer.id if @vehicle.customer end # update a specific vehicle