2013-08-30 08:47:44 +00:00
|
|
|
<div id="address-field" class="modal hide fade">
|
|
|
|
<div class="modal-header">
|
|
|
|
<button type="button" class="close" data-dismiss="modal" aria-hidden="true">×</button>
|
|
|
|
<h3><%= (field_name rescue nil) || t("address_modal.default_title") %></h3>
|
|
|
|
</div>
|
|
|
|
<div class="modal-body form-horizontal address-modal">
|
2012-11-12 02:41:41 +00:00
|
|
|
<div class="tabbable">
|
2013-08-30 08:47:44 +00:00
|
|
|
<ul class="nav nav-tabs">
|
|
|
|
<% VALID_LOCALES.each do |locale|%>
|
|
|
|
<% active = (locale == I18n.locale.to_s ? ["active"] : [] ) %>
|
|
|
|
<%= content_tag :li,:class=>active,:for=>locale do%>
|
|
|
|
<%= link_to I18nVariable.from_locale(locale),".#{btn_class}.address_modal.#{locale}",:data=>{:toggle=>"tab"}%>
|
2012-11-12 02:41:41 +00:00
|
|
|
<% end %>
|
2013-08-30 08:47:44 +00:00
|
|
|
<% end %>
|
|
|
|
</ul>
|
|
|
|
<div class="tab-content">
|
|
|
|
|
|
|
|
<% VALID_LOCALES.each do |locale|%>
|
|
|
|
<!-- start of lang tab context -->
|
|
|
|
<% active = (locale == I18n.locale.to_s ? "active" : "" ) %>
|
|
|
|
<div class="tab-pane fade <%= active %> in %>" for="<%= locale %>">
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label muted" for="street_address"><%= t("address_modal.street_address") %></label>
|
|
|
|
<div class="controls">
|
|
|
|
|
|
|
|
<%= text_area_tag("#{field_name_basic}[temp][address_ext][#{locale}][street_address]",nil,:rows=>3,:func=>'street_address', :class=>"input-xlarge") %>
|
2012-11-12 02:41:41 +00:00
|
|
|
</div>
|
2013-08-30 08:47:44 +00:00
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label muted" for="city"><%= t("address_modal.city") %></label>
|
|
|
|
<div class="controls">
|
|
|
|
<%= text_field_tag("#{field_name_basic}[temp][address_ext][#{locale}][city]",'',:func=>'city', :class=>"input-xlarge") %>
|
2012-11-12 02:41:41 +00:00
|
|
|
</div>
|
2013-08-30 08:47:44 +00:00
|
|
|
</div>
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label muted" for="counties"><%= t("address_modal.county") %></label>
|
|
|
|
<div class="controls">
|
|
|
|
<%= text_field_tag("#{field_name_basic}[temp][address_ext][#{locale}][county]",'',:func=>'county', :class=>"input-xlarge") %>
|
2012-11-12 02:41:41 +00:00
|
|
|
</div>
|
2013-08-30 08:47:44 +00:00
|
|
|
</div>
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label muted" for="zip"><%= t("address_modal.zip") %></label>
|
|
|
|
<div class="controls">
|
|
|
|
<%= text_field_tag("#{field_name_basic}[temp][address_ext][#{locale}][zip]",nil,:class=>"input-mini",:func=>'zip', :class=>"input-xlarge") %>
|
2012-11-12 02:41:41 +00:00
|
|
|
</div>
|
2013-08-30 08:47:44 +00:00
|
|
|
</div>
|
|
|
|
<div class="control-group">
|
|
|
|
<label class="control-label muted" for="country"><%= t("address_modal.country") %></label>
|
|
|
|
<div class="controls">
|
|
|
|
<%= text_field_tag("#{field_name_basic}[temp][address_ext][#{locale}][country]",'',:func=>'country', :class=>"input-xlarge") %>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="control-group hide">
|
|
|
|
<label class="control-label muted" for="indicator"><%= t("address_modal.Indicator") %></label>
|
|
|
|
<div class="controls">
|
|
|
|
<%= text_field_tag("#{field_name_basic}[temp][address_ext][#{locale}][indicator]",'',:func=>'country', :class=>"input-xlarge") %>
|
2012-11-12 02:41:41 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
2013-08-30 08:47:44 +00:00
|
|
|
<!-- end of tab context -->
|
|
|
|
<% end %>
|
|
|
|
|
|
|
|
</div>
|
2012-11-12 02:41:41 +00:00
|
|
|
</div>
|
2013-08-30 08:47:44 +00:00
|
|
|
</div>
|
|
|
|
<div class="modal-footer">
|
|
|
|
<a class="btn" data-dismiss="modal" aria-hidden="true"><%=t(:close)%></a>
|
|
|
|
<a class="btn btn-primary returnDecide" data-dismiss="modal" aria-hidden="true"><%=t(:save_and_close)%></a>
|
|
|
|
</div>
|
|
|
|
</div>
|