From 2b1f0f4ddfc19ed4f14d6f0c5550cc88b8cab0ff Mon Sep 17 00:00:00 2001 From: vagrant Date: Fri, 6 Feb 2015 03:30:27 +0000 Subject: [PATCH] Extra fixed in wrestler controller and in school view --- app/controllers/wrestlers_controller.rb | 2 +- app/views/schools/show.html.erb | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/app/controllers/wrestlers_controller.rb b/app/controllers/wrestlers_controller.rb index e3f3a73..26188a2 100644 --- a/app/controllers/wrestlers_controller.rb +++ b/app/controllers/wrestlers_controller.rb @@ -102,6 +102,6 @@ class WrestlersController < ApplicationController # Never trust parameters from the scary internet, only allow the white list through. def wrestler_params - params.require(:wrestler).permit(:name, :school_id, :weight_id, :seed, :original_seed, :season_win, :season_loss,:criteria) + params.require(:wrestler).permit(:name, :school_id, :weight_id, :seed, :original_seed, :season_win, :season_loss,:criteria,:extra) end end diff --git a/app/views/schools/show.html.erb b/app/views/schools/show.html.erb index 57686bf..e13e669 100644 --- a/app/views/schools/show.html.erb +++ b/app/views/schools/show.html.erb @@ -38,6 +38,7 @@ Seed Record Seed Criteria + Extra? Actions @@ -51,6 +52,9 @@ <%= wrestler.original_seed %> <%= wrestler.season_win %>-<%= wrestler.season_loss %> <%= wrestler.criteria %> + <% if wrestler.extra? == true %> + Yes + <% end %> <% if user_signed_in? %> <%= link_to 'Show', wrestler , :class=>"btn" %>