31 lines
978 B
Plaintext
31 lines
978 B
Plaintext
<% # encoding: utf-8 %>
|
|
|
|
<%= form_for(:role_filter, :remote => true, :url => @url, :method => @verb, :html => { :id => 'form_role_filter' } ) do |f| %>
|
|
|
|
<h2><%= (@role_filter.new_record? ? 'Add' : 'Edit') %></h2>
|
|
|
|
<div id="widget-title">
|
|
<%= f.label :key %>
|
|
<%= f.text_field :key %>
|
|
</div>
|
|
|
|
<div id="widget-title">
|
|
<%= f.fields_for :title_translations do |f| %>
|
|
<% @site_valid_locales.each do |locale| %>
|
|
<div class="control-group">
|
|
<%= label_tag "name-#{locale}", "Name-#{I18nVariable.from_locale(locale)}", :class => 'control-label' %>
|
|
<div class="controls">
|
|
<%= f.text_field locale, :class =>' input-xxlarge', :value => (@role_filter.title_translations[locale] rescue nil) %>
|
|
</div>
|
|
</div>
|
|
<% end %>
|
|
<% end %>
|
|
</div>
|
|
|
|
<div class="form-actions">
|
|
<%= f.hidden_field :role_id, :value => params[:role_id] if !params[:role_id].blank? %>
|
|
<%= f.submit 'Submit/送出', :class=>'btn btn-primary' %>
|
|
</div>
|
|
|
|
<% end %>
|
|
|