mirror of
https://github.com/jcwimer/wrestlingApp
synced 2026-04-08 07:22:38 +00:00
Trying to get create wrestler for school link to work
This commit is contained in:
@@ -16,6 +16,9 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<br>
|
||||||
|
<br>
|
||||||
|
<%= link_to "New #{@school.name} Wrestler" , new_wrestler_path(@school) %>
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
|
|
||||||
|
|||||||
@@ -15,10 +15,13 @@
|
|||||||
<%= f.label :name %><br>
|
<%= f.label :name %><br>
|
||||||
<%= f.text_field :name %>
|
<%= f.text_field :name %>
|
||||||
</div>
|
</div>
|
||||||
<div class="field">
|
|
||||||
<%= f.label 'School' %><br>
|
|
||||||
<%= f.collection_select :school_id, School.all, :id, :name %>
|
<div class="field">
|
||||||
</div>
|
<%= f.label 'School' %><br>
|
||||||
|
<%= f.collection_select :school_id, School.all, :id, :name %>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="field">
|
<div class="field">
|
||||||
<%= f.label 'Weight Class' %><br>
|
<%= f.label 'Weight Class' %><br>
|
||||||
<%= f.collection_select :weight_id, Weight.all, :id, :max %>
|
<%= f.collection_select :weight_id, Weight.all, :id, :max %>
|
||||||
|
|||||||
@@ -1,9 +1,13 @@
|
|||||||
Wrestling::Application.routes.draw do
|
Wrestling::Application.routes.draw do
|
||||||
resources :wrestlers
|
resources :schools
|
||||||
|
|
||||||
resources :weights
|
resources :weights
|
||||||
|
|
||||||
resources :schools
|
resources :wrestlers
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
# The priority is based upon order of creation: first created -> highest priority.
|
# The priority is based upon order of creation: first created -> highest priority.
|
||||||
# See how all your routes lay out with "rake routes".
|
# See how all your routes lay out with "rake routes".
|
||||||
|
|||||||
Reference in New Issue
Block a user