2012-11-15 09:23:39 +00:00
|
|
|
|
<div class="modal hide fade address-edit <%= btn_class %>" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true" id=<%= html_id%>>
|
2012-11-12 02:41:41 +00:00
|
|
|
|
<div class="modal-header">
|
|
|
|
|
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
|
|
|
|
<h3 id="myModalLabel"><%= (field_name rescue nil) || t("address_modal.default_title") %></h3>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="modal-body">
|
|
|
|
|
<div class="tabbable">
|
|
|
|
|
<ul class="nav nav-tabs">
|
|
|
|
|
<% VALID_LOCALES.each do |locale|%>
|
2012-11-15 09:23:39 +00:00
|
|
|
|
<% active = (locale == I18n.locale.to_s ? ["active"] : [] ) %>
|
|
|
|
|
<%= content_tag :li,:class=>active.push("modal_tab","address_tab").join(' '),:for=>locale do%>
|
2012-11-12 02:41:41 +00:00
|
|
|
|
<%= link_to t("langs.#{locale}"),".#{btn_class}.address_modal.#{locale}",:data=>{:toggle=>"tab"}%>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% end %>
|
|
|
|
|
</ul>
|
|
|
|
|
<div class="tab-content">
|
|
|
|
|
<% VALID_LOCALES.each do |locale|%>
|
|
|
|
|
<!-- start of lang tab context -->
|
2012-11-15 09:23:39 +00:00
|
|
|
|
<% active = (locale == I18n.locale.to_s ? "active" : "" ) %>
|
2012-11-12 02:41:41 +00:00
|
|
|
|
<div class="tab-pane <%= active %> fade in <%= "#{btn_class} address_modal #{locale}" %>" for="<%= locale %>">
|
|
|
|
|
<div class="control-group">
|
|
|
|
|
<label class="control-label" for="street_address"><%= t("address_modal.street_address") %></label>
|
|
|
|
|
<div class="controls">
|
2012-11-16 07:36:08 +00:00
|
|
|
|
|
|
|
|
|
<%= text_area_tag("#{field_name_basic}[temp][address_ext][#{locale}][street_address]",nil,:rows=>3,:func=>'street_address') %>
|
2012-11-12 02:41:41 +00:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="control-group">
|
|
|
|
|
<label class="control-label" for="city"><%= t("address_modal.city") %></label>
|
|
|
|
|
<div class="controls">
|
2012-11-16 07:36:08 +00:00
|
|
|
|
<%= text_field_tag("#{field_name_basic}[temp][address_ext][#{locale}][city]",'',:func=>'city') %>
|
2012-11-12 02:41:41 +00:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="control-group">
|
|
|
|
|
<label class="control-label" for="counties"><%= t("address_modal.county") %></label>
|
|
|
|
|
<div class="controls">
|
2012-11-16 07:36:08 +00:00
|
|
|
|
<%= text_field_tag("#{field_name_basic}[temp][address_ext][#{locale}][county]",'',:func=>'county') %>
|
2012-11-12 02:41:41 +00:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="control-group">
|
|
|
|
|
<label class="control-label" for="zip"><%= t("address_modal.zip") %></label>
|
|
|
|
|
<div class="controls">
|
2012-11-16 07:36:08 +00:00
|
|
|
|
<%= text_field_tag("#{field_name_basic}[temp][address_ext][#{locale}][zip]",nil,:class=>"input-mini",:func=>'zip') %>
|
2012-11-12 02:41:41 +00:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="control-group">
|
|
|
|
|
<label class="control-label" for="country"><%= t("address_modal.country") %></label>
|
|
|
|
|
<div class="controls">
|
2012-11-16 07:36:08 +00:00
|
|
|
|
<%= text_field_tag("#{field_name_basic}[temp][address_ext][#{locale}][country]",'',:func=>'country') %>
|
2012-11-12 02:41:41 +00:00
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<!-- end of tab context -->
|
|
|
|
|
<% end %>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="modal-footer">
|
|
|
|
|
<button class="btn" data-dismiss="modal" aria-hidden="true"><%=t("modal.close")%></button>
|
|
|
|
|
<button href="" class="btn btn-primary bt-save" data-dismiss="modal" aria-hidden="true"><%=t("modal.save_and_close")%></button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|