diff options
| author | Marc Florisson | 2014-03-04 09:24:05 +0100 |
|---|---|---|
| committer | Marc Florisson | 2014-03-04 09:26:18 +0100 |
| commit | 3587b4b60cdcc3a832b5694b9cb0d7b7d4e7853e (patch) | |
| tree | 6d0bde8178b2b1a8a70993e415b5212732a6f416 /app/views/stop_areas | |
| parent | 5c901c9f3d003c9b122925013e6155fdfa1f6dff (diff) | |
| download | chouette-core-3587b4b60cdcc3a832b5694b9cb0d7b7d4e7853e.tar.bz2 | |
fix tokenInput translations, Mantis #24416
Diffstat (limited to 'app/views/stop_areas')
| -rw-r--r-- | app/views/stop_areas/add_children.html.erb | 15 | ||||
| -rw-r--r-- | app/views/stop_areas/add_routing_lines.html.erb | 15 | ||||
| -rw-r--r-- | app/views/stop_areas/add_routing_stops.html.erb | 15 | ||||
| -rw-r--r-- | app/views/stop_areas/select_parent.html.erb | 15 |
4 files changed, 36 insertions, 24 deletions
diff --git a/app/views/stop_areas/add_children.html.erb b/app/views/stop_areas/add_children.html.erb index 6f637086c..acf4ff603 100644 --- a/app/views/stop_areas/add_children.html.erb +++ b/app/views/stop_areas/add_children.html.erb @@ -2,10 +2,10 @@ <%= semantic_form_for [@referential, @stop_area] do |form| %> <div> - <%= form.inputs do %> + <%= form.inputs do %> <%= form.input :children_ids, :as => :text, :input_html => { :"data-pre" => ( @children.map { |child| { :id => child.id.to_s, :name => "#{child.name} #{child.country_code}" } } ).to_json } %> - <% end %> - + <% end %> + <%= form.actions do %> <%= form.action :submit, :as => :button %> <%= form.action :cancel, :as => :link %> @@ -15,14 +15,17 @@ <script> $(function() { - $( "#stop_area_children_ids" ).tokenInput('<%= referential_stop_area_stop_area_children_path(@referential, @stop_area, :format => :json) %>', { - crossDomain: false, + $( "#stop_area_children_ids" ).tokenInput('<%= referential_stop_area_stop_area_children_path(@referential, @stop_area, :format => :json) %>', { + crossDomain: false, prePopulate: $('#stop_area_children_id').data('pre'), minChars: 3, + hintText: '<%= t('search_hint') %>', + noResultsText: '<%= t('no_result_text') %>', + searchingText: '<%= t('searching_term') %>' }); }); </script> - + <% content_for :sidebar do %> <ul class="actions"> </ul> diff --git a/app/views/stop_areas/add_routing_lines.html.erb b/app/views/stop_areas/add_routing_lines.html.erb index e0750a758..84d03f8b2 100644 --- a/app/views/stop_areas/add_routing_lines.html.erb +++ b/app/views/stop_areas/add_routing_lines.html.erb @@ -2,10 +2,10 @@ <%= semantic_form_for [@referential, @stop_area] do |form| %> <div> - <%= form.inputs do %> + <%= form.inputs do %> <%= form.input :routing_line_ids, :as => :text, :input_html => { :"data-pre" => ( @lines.map { |line| { :id => line.id.to_s, :name => "#{line.number} - #{line.name}" } } ).to_json } %> - <% end %> - + <% end %> + <%= form.actions do %> <%= form.action :submit, :as => :button %> <%= form.action :cancel, :as => :link %> @@ -15,14 +15,17 @@ <script> $(function() { - $( "#stop_area_routing_line_ids" ).tokenInput('<%= referential_stop_area_stop_area_routing_lines_path(@referential, @stop_area, :format => :json) %>', { - crossDomain: false, + $( "#stop_area_routing_line_ids" ).tokenInput('<%= referential_stop_area_stop_area_routing_lines_path(@referential, @stop_area, :format => :json) %>', { + crossDomain: false, prePopulate: $('#stop_area_routing_line_id').data('pre'), minChars: 1, + hintText: '<%= t('search_hint') %>', + noResultsText: '<%= t('no_result_text') %>', + searchingText: '<%= t('searching_term') %>' }); }); </script> - + <% content_for :sidebar do %> <ul class="actions"> </ul> diff --git a/app/views/stop_areas/add_routing_stops.html.erb b/app/views/stop_areas/add_routing_stops.html.erb index 5fc2326f0..06a96d575 100644 --- a/app/views/stop_areas/add_routing_stops.html.erb +++ b/app/views/stop_areas/add_routing_stops.html.erb @@ -2,10 +2,10 @@ <%= semantic_form_for [@referential, @stop_area] do |form| %> <div> - <%= form.inputs do %> + <%= form.inputs do %> <%= form.input :routing_stop_ids, :as => :text, :input_html => { :"data-pre" => ( @stops.map { |stop| { :id => stop.id.to_s, :name => "#{stop.name} #{stop.country_code}" } } ).to_json } %> - <% end %> - + <% end %> + <%= form.actions do %> <%= form.action :submit, :as => :button %> <%= form.action :cancel, :as => :link %> @@ -15,14 +15,17 @@ <script> $(function() { - $( "#stop_area_routing_stop_ids" ).tokenInput('<%= referential_stop_area_stop_area_routing_stops_path(@referential, @stop_area, :format => :json) %>', { - crossDomain: false, + $( "#stop_area_routing_stop_ids" ).tokenInput('<%= referential_stop_area_stop_area_routing_stops_path(@referential, @stop_area, :format => :json) %>', { + crossDomain: false, prePopulate: $('#stop_area_routing_stop_id').data('pre'), minChars: 3, + hintText: '<%= t('search_hint') %>', + noResultsText: '<%= t('no_result_text') %>', + searchingText: '<%= t('searching_term') %>' }); }); </script> - + <% content_for :sidebar do %> <ul class="actions"> </ul> diff --git a/app/views/stop_areas/select_parent.html.erb b/app/views/stop_areas/select_parent.html.erb index fedd83446..2e5f4ca94 100644 --- a/app/views/stop_areas/select_parent.html.erb +++ b/app/views/stop_areas/select_parent.html.erb @@ -2,10 +2,10 @@ <%= semantic_form_for [@referential, @stop_area] do |form| %> <div> - <%= form.inputs do %> + <%= form.inputs do %> <%= form.input :parent_id, :as => :text, :input_html => { :"data-pre" => ( @parent.present? ? [ { :id => @parent.id.to_s, :name => "#{@parent.name} #{@parent.country_code}" } ]: [] ).to_json } %> - <% end %> - + <% end %> + <%= form.actions do %> <%= form.action :submit, :as => :button %> <%= form.action :cancel, :as => :link %> @@ -15,15 +15,18 @@ <script> $(function() { - $( "#stop_area_parent_id" ).tokenInput('<%= referential_stop_area_stop_area_parents_path(@referential, @stop_area, :format => :json) %>', { - crossDomain: false, + $( "#stop_area_parent_id" ).tokenInput('<%= referential_stop_area_stop_area_parents_path(@referential, @stop_area, :format => :json) %>', { + crossDomain: false, prePopulate: $('#stop_area_parent_id').data('pre'), tokenLimit: 1, minChars: 3, + hintText: '<%= t('search_hint') %>', + noResultsText: '<%= t('no_result_text') %>', + searchingText: '<%= t('searching_term') %>' }); }); </script> - + <% content_for :sidebar do %> <ul class="actions"> </ul> |
