Created
April 15, 2016 16:18
-
-
Save yakschuss/ddb34597407e42bfc5a719f1c8fba94d to your computer and use it in GitHub Desktop.
Event Creation Form with nested Ticket_Type
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div class="form"> | |
<div class="form-group-columns"> | |
<%= form_for [:admin, @event] do |f| %> | |
<%= f.text_field :name, placeholder: "Name" %> | |
<br/> | |
<br/> | |
<%= f.text_area :description, placeholder: "Description" %> | |
<br/> | |
<%= f.date_select(:date , :start_year => 2016) %> | |
<br/> | |
<%= f.fields_for :ticket_types do |ticket_type_form| %> | |
<ul class="ticket-type-group"> | |
<li class="ticket-form"> | |
<%= ticket_type_form.label :type %> | |
<%= ticket_type_form.text_field :level %> | |
<%= ticket_type_form.label :price %> | |
<%= ticket_type_form.number_field :cost %> | |
<%# Want to duplicate this to allow for multiple ticket_type param sets. by hitting FA icon below%> | |
</li> | |
</ul> | |
<span class="fa fa-plus-circle fa-1.5x ticket-form-add"></span> | |
<br/> | |
<% end %> | |
<br/> | |
<%= f.submit :save, class: "button" %> | |
<% end %> | |
</div> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment