decidim-system/app/views/decidim/system/organizations/new.html.erb in decidim-0.0.1.alpha9 vs decidim-system/app/views/decidim/system/organizations/new.html.erb in decidim-0.0.1
- old
+ new
@@ -10,19 +10,39 @@
<div class="field">
<%= f.text_field :host %>
</div>
<div class="field">
- <%= f.translated :text_area, :description %>
+ <%= f.text_field :organization_admin_name %>
</div>
<div class="field">
- <%= f.text_field :organization_admin_name %>
+ <%= f.email_field :organization_admin_email %>
</div>
+ <%= f.fields_for :locales do |fields| %>
<div class="field">
- <%= f.email_field :organization_admin_email %>
+ <%= f.label :organization_locales, '', class: @form.respond_to?(:errors) && @form.errors[:default_locale].present? ? "is-invalid-label" : "" %>
+ <table>
+ <thead>
+ <tr>
+ <td>Locale</td>
+ <td>Enabled <%= f.error_for(:available_locales) %></td>
+ <td>Default? <%= f.error_for(:default_locale) %></td>
+ </tr>
+ </thead>
+ <tbody>
+ <% localized_locales.each do |locale| %>
+ <tr>
+ <td><%= locale.name %></td>
+ <td><%= check_box_tag "organization[available_locales][#{locale.id}]", locale.id, @form.available_locales.include?(locale.id) %></td>
+ <td><%= radio_button_tag "organization[default_locale]", locale.id, @form.default_locale == locale.id %></td>
+ </tr>
+ <% end %>
+ </tbody>
+ </table>
</div>
+ <% end %>
<div class="actions">
<%= f.submit t("decidim.system.models.organization.actions.save_and_invite") %>
</div>
<% end %>