Permalink
Switch branches/tags
Nothing to show
Find file
Fetching contributors…
Cannot retrieve contributors at this time
39 lines (36 sloc) 2.05 KB
<div id="new-pilot-fields" class="modal fade" data-backdrop="static">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
<h3>Add a Pilot<%= " to the #{ @ship.name } Pilot Roster" unless @ship.name.nil? %></h3>
</div>
<div class="modal-body">
<fieldset>
<div class="control-group">
<%= f.label(:first_name, :class => "control-label") %>
<div class="controls">
<%= f.text_field(:first_name, :class => "input-xlarge field", :data => { :validation => "required validate_max_length length50", "validation-error-msg" => "First Name is required and cannot be longer than 50 characters." }) %>
</div>
</div>
<div class="control-group">
<%= f.label(:last_name, :class => "control-label") %>
<div class="controls">
<%= f.text_field(:last_name, :class => "input-xlarge field", :data => { :validation => "required validate_max_length length50", "validation-error-msg" => "Last Name is required and cannot be longer than 50 characters." }) %>
</div>
</div>
<div class="control-group">
<%= f.label(:call_sign, :class => "control-label") %>
<div class="controls">
<%= f.text_field(:call_sign, :class => "input-xlarge field", :data => { :validation => "required validate_length length5-50", "validation-error-msg" => "Call Sign is required and cannot be must be between 5 and 50 characters." }) %>
</div>
</div>
<%= f.hidden_field(:_destroy, :class => "field") %>
</fieldset>
</div>
<div class="modal-footer">
<button id="addButton" type="button" class="btn btn-primary" data-dismiss="modal" aria-hidden="true" title="Add this Pilot to the list of Pilots that are assigned to this Ship.">Add</button>
<button id="cancelButton" type="button" class="btn btn-inverse" data-dismiss="modal" aria-hidden="true" title="Close this screen without adding the Pilot to the list.">Cancel</button>
</div>
</div>
<script type="text/javascript">
pilotFieldsUI.init();
</script>