Skip to content

Instantly share code, notes, and snippets.

@etdebruin
Created May 29, 2013 15:57
Show Gist options
  • Select an option

  • Save etdebruin/5671416 to your computer and use it in GitHub Desktop.

Select an option

Save etdebruin/5671416 to your computer and use it in GitHub Desktop.
employment
<%= form_for(@employment, :html => {:id => "user-form", :class => "user-form"}) do |f| %>
<% if @employment.errors.any? %>
<div id="error_explanation">
<h2><%= pluralize(@employment.errors.count, "error") %> prohibited this employment from being saved:</h2>
<ul>
<% @employment.errors.full_messages.each do |msg| %>
<li><%= msg %></li>
<% end %>
</ul>
</div>
<% end %>
<p>
<%= f.select :position, options_for_select(Employment::POSITION), :prompt => "Job Title" %>
</p>
<p><%= f.date_select :start %></p>
<p><%= f.date_select :stop %></p>
<p><%= f.check_box :present %> Present</p>
<p><%= f.text_area :description, :placeholder => "Describe your roles and responsibilities" %>
<div class="actions">
<%= f.hidden_field :company_id, :value => params[:company_id] %>
<%= f.submit %>
</div>
<% end %>
@etdebruin

Copy link
Copy Markdown
Author

Check box snippet produces:

 <p><input name="employment[present]" type="hidden" value="0" /><input id="employment_present" name="employment[present]" type="checkbox" value="1" /> Present</p>

@zakinalvix

zakinalvix commented Oct 28, 2026 •

Copy link
Copy Markdown

Proper employment registration helps organize applicant information and required documents. For overseas Filipino workers, visit www.dmw.gov.ph registration to find official guidance on registration and employment requirements.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment