diff options
Diffstat (limited to 'config')
| -rw-r--r-- | config/initializers/simple_form.rb | 4 | ||||
| -rw-r--r-- | config/initializers/simple_form_bootstrap.rb | 8 | ||||
| -rw-r--r-- | config/locales/enumerize.en.yml | 17 | ||||
| -rw-r--r-- | config/locales/enumerize.fr.yml | 17 | ||||
| -rw-r--r-- | config/locales/routes.yml | 13 | ||||
| -rw-r--r-- | config/locales/stop_points.yml | 10 | ||||
| -rw-r--r-- | config/routes.rb | 4 |
7 files changed, 67 insertions, 6 deletions
diff --git a/config/initializers/simple_form.rb b/config/initializers/simple_form.rb index e2ad34eee..a128195d2 100644 --- a/config/initializers/simple_form.rb +++ b/config/initializers/simple_form.rb @@ -95,7 +95,7 @@ SimpleForm.setup do |config| # config.label_text = lambda { |label, required| "#{required} #{label}" } # You can define the class to use on all labels. Default is nil. - config.label_class = 'col-lg-2 control-label' + config.label_class = 'col-lg-3 control-label' # You can define the class to use on all forms. Default is simple_form. config.form_class = "simple_form form-horizontal" @@ -132,7 +132,7 @@ SimpleForm.setup do |config| # config.default_input_size = 50 # When false, do not use translations for labels. - # config.translate_labels = true + config.translate_labels = true # Automatically discover new inputs in Rails' autoload path. # config.inputs_discovery = false diff --git a/config/initializers/simple_form_bootstrap.rb b/config/initializers/simple_form_bootstrap.rb index c3dd5e348..552a2ff66 100644 --- a/config/initializers/simple_form_bootstrap.rb +++ b/config/initializers/simple_form_bootstrap.rb @@ -4,7 +4,7 @@ SimpleForm.setup do |config| b.use :html5 b.use :placeholder b.use :label - b.wrapper :tag => 'div', :class => 'col-lg-10' do |ba| + b.wrapper :tag => 'div', :class => 'col-lg-9' do |ba| ba.use :input ba.use :error, :wrap_with => { :tag => 'span', :class => 'help-inline' } ba.use :hint, :wrap_with => { :tag => 'p', :class => 'help-block' } @@ -26,7 +26,7 @@ SimpleForm.setup do |config| b.use :html5 b.use :placeholder b.use :label - b.wrapper :tag => 'div', :class => 'col-lg-10' do |input| + b.wrapper :tag => 'div', :class => 'col-lg-9' do |input| input.wrapper :tag => 'div', :class => 'input-prepend' do |prepend| prepend.use :input end @@ -39,7 +39,7 @@ SimpleForm.setup do |config| b.use :html5 b.use :placeholder b.use :label - b.wrapper :tag => 'div', :class => 'col-lg-10' do |input| + b.wrapper :tag => 'div', :class => 'col-lg-9' do |input| input.wrapper :tag => 'div', :class => 'input-append' do |append| append.use :input end @@ -54,5 +54,5 @@ SimpleForm.setup do |config| # buttons and other elements. config.default_wrapper = :bootstrap config.button_class = 'btn' - config.label_class = 'col-lg-2 control-label' + config.label_class = 'col-lg-3 control-label' end diff --git a/config/locales/enumerize.en.yml b/config/locales/enumerize.en.yml new file mode 100644 index 000000000..574c316cd --- /dev/null +++ b/config/locales/enumerize.en.yml @@ -0,0 +1,17 @@ +en: + simple_form: + include_blanks: + defaults: + for_boarding: "Undefined" + for_alighting: "Undefined" + enumerize: + for_boarding: + normal: "Regularly scheduled pickup" + forbidden: "No pickup available" + request_stop: "Pickup if requested" + is_flexible: "Booking requested for pickup" + for_alighting: + normal: "Regularly scheduled drop off" + forbidden: "No drop off available" + request_stop: "Drop off if requested" + is_flexible: "Booking requested for drop off"
\ No newline at end of file diff --git a/config/locales/enumerize.fr.yml b/config/locales/enumerize.fr.yml new file mode 100644 index 000000000..0dad16319 --- /dev/null +++ b/config/locales/enumerize.fr.yml @@ -0,0 +1,17 @@ +fr: + simple_form: + include_blanks: + defaults: + for_boarding: "Non défini" + for_alighting: "Non défini" + enumerize: + for_boarding: + normal: "Montée autorisée" + forbidden: "Montée interdite" + request_stop: "Montée sur demande au conducteur" + is_flexible: "Montée sur réservation" + for_alighting: + normal: "Descente autorisée" + forbidden: "Descente interdite" + request_stop: "Descente sur demande au conducteur" + is_flexible: "Descente sur réservation"
\ No newline at end of file diff --git a/config/locales/routes.yml b/config/locales/routes.yml index b68f1802a..1807ef30d 100644 --- a/config/locales/routes.yml +++ b/config/locales/routes.yml @@ -3,6 +3,7 @@ en: actions: new: "Add a new route" edit: "Edit this route" + edit_boarding_alighting: "Stop alighting and boarding" destroy: "Remove this route" destroy_confirm: "Are you sure you want destroy this route?" export_kml: "Export KML route" @@ -25,6 +26,11 @@ en: title: "Routes" selection: "Selection" selection_all: "All" + edit_boarding_alighting: + title: "Stop alighting and boarding properties" + stop_area_name: "Stop area name" + for_boarding: "Boarding" + for_alighting: "Alighting" route: no_journey_pattern: "No Journey pattern" wayback: @@ -58,6 +64,7 @@ en: object_version: "Version" creation_time: "Created on" creator_id: "Created by" + no_journey_pattern: "No journey pattern" formtastic: titles: route: @@ -68,6 +75,7 @@ fr: actions: new: "Ajouter une séquence d'arrêts" edit: "Modifier cette séquence d'arrêts" + edit_boarding_alighting: "Contraintes de montée - descente" destroy: "Supprimer cette séquence d'arrêts" destroy_confirm: "Etes vous sûr de supprimer cette séquence d'arrêts ?" export_kml: "Export KML de la séquence d'arrêts" @@ -90,6 +98,11 @@ fr: title: "Séquences d'arrêts" selection: "Sélection" selection_all: "Tous" + edit_boarding_alighting: + title: "Contraintes de montée - descente aux arrêts" + stop_area_name: "Nom de l'arrêt" + for_boarding: "Montée" + for_alighting: "Descente" route: no_journey_pattern: "Pas de mission" wayback: diff --git a/config/locales/stop_points.yml b/config/locales/stop_points.yml index cead1f93b..819ed4c0f 100644 --- a/config/locales/stop_points.yml +++ b/config/locales/stop_points.yml @@ -33,6 +33,11 @@ en: attributes: stop_point: lines: "lines" + simple_form: + labels: + stop_point: + for_boarding: "Pickup" + for_alighting: "Drop off" fr: stop_points: reorder_success: "La list des arrêts a été mise à jour" @@ -68,3 +73,8 @@ fr: attributes: stop_point: lines: "Lignes" + simple_form: + labels: + stop_point: + for_boarding: "Montée" + for_alighting: "Descente" diff --git a/config/routes.rb b/config/routes.rb index 530e17409..37cff975e 100644 --- a/config/routes.rb +++ b/config/routes.rb @@ -76,6 +76,10 @@ ChouetteIhm::Application.routes.draw do resources :lines, :networks, :group_of_lines do resources :routes do + member do + get 'edit_boarding_alighting' + put 'save_boarding_alighting' + end resources :journey_patterns do member do get 'new_vehicle_journey' |
