aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBruno Perles2015-12-23 15:41:34 +0100
committerBruno Perles2015-12-23 15:41:34 +0100
commit8dbc16364a168a853ef71a7179b87c27143037af (patch)
tree411cf752011a358332faadbe77b57fb3e01332da
parent3928a7d46738913888a795b0bae8e5fb7b310d21 (diff)
parent588d11f0f848624eb2c09544038486f3a145ee98 (diff)
downloadchouette-core-8dbc16364a168a853ef71a7179b87c27143037af.tar.bz2
Merge branch 'feature/fixed_bugs' into develop
-rw-r--r--app/assets/javascripts/partials/ie_report.js.coffee.erb3
-rw-r--r--app/assets/javascripts/vehicle_journey.coffee8
-rw-r--r--app/assets/stylesheets/main/vehicle_journey_frequencies.scss2
-rw-r--r--app/assets/stylesheets/modules/job_status_colors.scss2
-rw-r--r--app/controllers/compliance_checks_controller.rb5
-rw-r--r--app/controllers/imports_controller.rb1
-rw-r--r--app/helpers/vehicle_journey_frequencies_helper.rb5
-rw-r--r--app/helpers/vehicle_journeys_helper.rb4
-rw-r--r--app/maps/design/route_section_style_map.rb2
-rw-r--r--app/models/route_sections_selector.rb8
-rw-r--r--app/views/compliance_checks/_compliance_check_results.erb88
-rw-r--r--app/views/compliance_checks/report.html.erb2
-rw-r--r--app/views/compliance_checks/show.html.erb2
-rw-r--r--app/views/journey_patterns/_journey_pattern.html.erb13
-rw-r--r--app/views/routes/_route.html.erb2
-rw-r--r--app/views/shared/_ie_report_file.html.erb2
-rw-r--r--app/views/shared/_ie_report_line.html.erb13
-rw-r--r--app/views/vehicle_journeys/_vehicle_journeys.html.erb7
-rw-r--r--config/locales/breadcrumbs.fr.yml2
-rw-r--r--config/locales/compliance_check_results.en.yml1
-rw-r--r--config/locales/compliance_check_results.fr.yml1
-rw-r--r--config/locales/journey_frequencies.fr.yml4
-rw-r--r--config/locales/referentials.fr.yml2
-rw-r--r--config/locales/timebands.fr.yml22
-rw-r--r--config/locales/vehicle_journey_frequencies.fr.yml6
-rw-r--r--config/locales/vehicle_journeys.fr.yml16
-rw-r--r--spec/features/timebands_spec.rb8
27 files changed, 132 insertions, 99 deletions
diff --git a/app/assets/javascripts/partials/ie_report.js.coffee.erb b/app/assets/javascripts/partials/ie_report.js.coffee.erb
index 20c6dbb16..5d42566ea 100644
--- a/app/assets/javascripts/partials/ie_report.js.coffee.erb
+++ b/app/assets/javascripts/partials/ie_report.js.coffee.erb
@@ -6,7 +6,8 @@ $(".imports.show, .exports.show, .compliance_checks.show").ready ->
setInterval(reloadPage,refreshInterval * 1000)
footableFilter = (parent, el) ->
- $(parent).footable().bind 'footable_filtering', (e) ->
+ no_pagination = $(parent).data('no-pagination') != true
+ $(parent).footable( { paginate: no_pagination } ).bind 'footable_filtering', (e) ->
selected = $("select#{el} option:selected").val()
if selected and selected.length > 0
e.filter += if e.filter and e.filter.length > 0 then ' ' + selected else selected
diff --git a/app/assets/javascripts/vehicle_journey.coffee b/app/assets/javascripts/vehicle_journey.coffee
index caf505960..d87df7cd4 100644
--- a/app/assets/javascripts/vehicle_journey.coffee
+++ b/app/assets/javascripts/vehicle_journey.coffee
@@ -55,8 +55,8 @@ jQuery ->
hour = parseInt( $(".vehicle_journey_at_stops select#date_hour").val())
minute = parseInt( $(".vehicle_journey_at_stops select#date_minute").val())
departure_or_arrival = $(".departure_or_arrival option:selected").val()
-
- selector_prefix = ".vehicle_journey_at_stops .journey_pattern_dependent_list"
+ console.log(hour)
+ selector_prefix = ".journey_pattern_dependent_list"
if (departure_or_arrival == "departure")
vjas_hour_selector = selector_prefix + " .departure_time select.hour"
vjas_minute_selector = selector_prefix + " .departure_time select.minute"
@@ -66,9 +66,9 @@ jQuery ->
vjas_hour = $( vjas_hour_selector).prop( "selectedIndex" )
vjas_minute = $( vjas_minute_selector).prop( "selectedIndex" )
-
+ console.log(vjas_hour_selector)
duration = (hour - vjas_hour) * 60 + (minute - vjas_minute)
-
+ console.log(duration)
slide_to( '.departure_time', duration)
slide_to( '.arrival_time', duration)
diff --git a/app/assets/stylesheets/main/vehicle_journey_frequencies.scss b/app/assets/stylesheets/main/vehicle_journey_frequencies.scss
index 8e077adae..e50755194 100644
--- a/app/assets/stylesheets/main/vehicle_journey_frequencies.scss
+++ b/app/assets/stylesheets/main/vehicle_journey_frequencies.scss
@@ -3,6 +3,8 @@
.btn {
white-space: normal;
width: 130px;
+ font-size: 11px;
+ padding: 2px 0;
}
}
.ce-TimeBandFormTable th {
diff --git a/app/assets/stylesheets/modules/job_status_colors.scss b/app/assets/stylesheets/modules/job_status_colors.scss
index 3c9086471..b3ae3d72c 100644
--- a/app/assets/stylesheets/modules/job_status_colors.scss
+++ b/app/assets/stylesheets/modules/job_status_colors.scss
@@ -1,4 +1,4 @@
.terminated{ color: $brand-success; }
-.processed{ color: $brand-info; }
+.processed{ color: $brand-info; box-shadow: none; }
.aborted{ color: $brand-danger; }
diff --git a/app/controllers/compliance_checks_controller.rb b/app/controllers/compliance_checks_controller.rb
index 39ae397e6..d8f8d17b2 100644
--- a/app/controllers/compliance_checks_controller.rb
+++ b/app/controllers/compliance_checks_controller.rb
@@ -73,6 +73,11 @@ class ComplianceChecksController < ChouetteController
def resource
@compliance_check ||= compliance_check_service.find(params[:id])
+ @line_items = @compliance_check.report.line_items
+ if @line_items.size > 500
+ @line_items = @line_items.paginate(page: params[:page], per_page: 20)
+ end
+ @compliance_check
end
def collection
diff --git a/app/controllers/imports_controller.rb b/app/controllers/imports_controller.rb
index 44f0307a0..ea91d8d8b 100644
--- a/app/controllers/imports_controller.rb
+++ b/app/controllers/imports_controller.rb
@@ -100,6 +100,7 @@ class ImportsController < ChouetteController
if @line_items.size > 500
@line_items = @line_items.paginate(page: params[:page], per_page: 20)
end
+ @import
end
def collection
diff --git a/app/helpers/vehicle_journey_frequencies_helper.rb b/app/helpers/vehicle_journey_frequencies_helper.rb
index 1c603e4b1..28cdc7d21 100644
--- a/app/helpers/vehicle_journey_frequencies_helper.rb
+++ b/app/helpers/vehicle_journey_frequencies_helper.rb
@@ -6,4 +6,9 @@ module VehicleJourneyFrequenciesHelper
width = (right < left ? 100 - left : right - left)
[left.round(2), width.round(2)]
end
+
+ def exist_vehicle_journey_frequencies?(route, journey_pattern=nil)
+ where = journey_pattern ? { journey_pattern: journey_pattern } : nil
+ route.vehicle_journey_frequencies.where(where).count > 0
+ end
end
diff --git a/app/helpers/vehicle_journeys_helper.rb b/app/helpers/vehicle_journeys_helper.rb
index c5f3242be..e70f2954b 100644
--- a/app/helpers/vehicle_journeys_helper.rb
+++ b/app/helpers/vehicle_journeys_helper.rb
@@ -49,6 +49,10 @@ module VehicleJourneysHelper
:stop => first_vjas.stop_point.stop_area.name,
:time => vehicle_departure(vehicle))
end
+
+ def exist_vehicle_journeys?(route)
+ route.vehicle_journeys.count > 0
+ end
end
diff --git a/app/maps/design/route_section_style_map.rb b/app/maps/design/route_section_style_map.rb
index 2c94bb3a0..01fbafe0f 100644
--- a/app/maps/design/route_section_style_map.rb
+++ b/app/maps/design/route_section_style_map.rb
@@ -36,7 +36,7 @@ class Design::RouteSectionStyleMap < Design::GenericStyleMap
:labelYOffset => -15,
:strokeColor => "green",
:strokeOpacity => 1,
- :strokeWidth => 2,
+ :strokeWidth => 5,
:strokeLineCap => "round",
:strokeLineJoin => "round",
:strokeDashstyle => "solid",
diff --git a/app/models/route_sections_selector.rb b/app/models/route_sections_selector.rb
index b3c984559..0db09ed25 100644
--- a/app/models/route_sections_selector.rb
+++ b/app/models/route_sections_selector.rb
@@ -38,7 +38,7 @@ class RouteSectionsSelector
route_section = Chouette::RouteSection.find_by(departure: departure.stop_area, arrival: arrival.stop_area)
end
- sections << Section.new(departure.stop_area, arrival.stop_area, route_section)
+ sections << Section.new(departure.stop_area, arrival.stop_area, index, route_section)
end
end
end
@@ -59,10 +59,10 @@ class RouteSectionsSelector
class Section
extend ActiveModel::Translation
- attr_accessor :departure, :arrival, :route_section_id
+ attr_accessor :departure, :arrival, :rank, :route_section_id
- def initialize(departure, arrival, route_section = nil)
- @departure, @arrival = departure, arrival
+ def initialize(departure, arrival, rank, route_section = nil)
+ @departure, @arrival, @rank = departure, arrival, rank
self.route_section = route_section
end
diff --git a/app/views/compliance_checks/_compliance_check_results.erb b/app/views/compliance_checks/_compliance_check_results.erb
index ab8d283eb..28d5a289e 100644
--- a/app/views/compliance_checks/_compliance_check_results.erb
+++ b/app/views/compliance_checks/_compliance_check_results.erb
@@ -1,7 +1,7 @@
<p>
<form class="form-inline">
<div class="form-group">
- <label><%= t("shared.ie_report.html.search") %></label>
+ <label><%= t("shared.ie_report.search") %></label>
<input id="filter" type="text" class="form-control">
</div>
<div class="form-group">
@@ -40,51 +40,57 @@
</tr>
</thead>
<tbody>
- <% compliance_check_validation_report.tests.each_with_index do |test, index| %>
- <tr class='<%= "#{test.result}_#{test.severity}" %>'>
- <td data-value="<%="status-#{test.result}"%>"><%= status_icon( test.result, test.severity ) %> </td>
- <td data-value="<%="severity-#{test.severity}"%>"><%= t("compliance_check_result.severities.#{test.severity}_txt") %></td>
- <td data-value="<%= "#{test.result}_#{test.severity}" %>">
- <%= link_to test.test_id, test_definition(test.test_id), title: ComplianceCheckResult.human_attribute_name(test.test_id), target: "compliance_check" %>
- </td>
- <td>
- <%= ("#{test.error_count || 0} #{ComplianceCheckResult.human_attribute_name(:violation_count)}") if test.errors.present? %>
- </td>
- <td>
- <%= truncate(t("activemodel.attributes.compliance_check_result.#{test.test_id}"), length: 50)%>
- </td>
- <td>
- <p><b><%=t("activemodel.attributes.compliance_check_result.#{test.test_id}")%></b></p>
- <% if test.errors.present? %>
- <% test.errors.first(10).each do |error| %>
- <dl class="inline">
- <dt>
- <% if error["source"].present? %>
- <% if error[:source].object_path.present? %>
- <% if error[:source].label.present? %>
- <%= link_to error[:source].label, object_url(@referential.id, error), target: :_blank %>
- <% else %>
- <%= link_to "#{error[:source].object_path.type} (#{error[:source].object_path.id})", object_url(@referential.id, error), target: :_blank %>
+ <% if compliance_check_validation_report %>
+ <% compliance_check_validation_report.tests.each_with_index do |test, index| %>
+ <tr class='<%= "#{test.result}_#{test.severity}" %>'>
+ <td data-value="<%="status-#{test.result}"%>"><%= status_icon( test.result, test.severity ) %> </td>
+ <td data-value="<%="severity-#{test.severity}"%>"><%= t("compliance_check_result.severities.#{test.severity}_txt") %></td>
+ <td data-value="<%= "#{test.result}_#{test.severity}" %>">
+ <%= link_to test.test_id, test_definition(test.test_id), title: ComplianceCheckResult.human_attribute_name(test.test_id), target: "compliance_check" %>
+ </td>
+ <td>
+ <%= ("#{test.error_count || 0} #{ComplianceCheckResult.human_attribute_name(:violation_count)}") if test.errors.present? %>
+ </td>
+ <td>
+ <%= truncate(t("activemodel.attributes.compliance_check_result.#{test.test_id}"), length: 50)%>
+ </td>
+ <td>
+ <p><b><%=t("activemodel.attributes.compliance_check_result.#{test.test_id}")%></b></p>
+ <% if test.errors.present? %>
+ <% test.errors.first(10).each do |error| %>
+ <dl class="inline">
+ <dt>
+ <% if error["source"].present? %>
+ <% if error[:source].object_path.present? %>
+ <% if error[:source].label.present? %>
+ <%= link_to error[:source].label, object_url(@referential.id, error), target: :_blank %>
+ <% else %>
+ <%= link_to "#{error[:source].object_path.type} (#{error[:source].object_path.id})", object_url(@referential.id, error), target: :_blank %>
+ <% end %>
+ <% end %>
+ <% if error[:source].file.present? %>
+ <%= error[:source].objectid if error[:source].objectid.present? %>
<% end %>
<% end %>
- <% if error[:source].file.present? %>
- <%= error[:source].objectid if error[:source].objectid.present? %>
- <% end %>
+ </dt>
+ <dd><%=t("compliance_check_result.details.detail_#{error[:error_id]}", object_labels_hash(error))%></dd>
+ </dl>
+ <% if error[:source].file.present? %>
+ <p class="file_error">
+ <%= error[:source].file.filename %>
+ <%= ", li: #{error[:source].file.line_number}" if error[:source].file.line_number.present? %>
+ <%= ", co: #{error[:source].file.column_number}" if error[:source].file.column_number.present? %>
+ </p>
<% end %>
- </dt>
- <dd><%=t("compliance_check_result.details.detail_#{error[:error_id]}", object_labels_hash(error))%></dd>
- </dl>
- <% if error[:source].file.present? %>
- <p class="file_error">
- <%= error[:source].file.filename %>
- <%= ", li: #{error[:source].file.line_number}" if error[:source].file.line_number.present? %>
- <%= ", co: #{error[:source].file.column_number}" if error[:source].file.column_number.present? %>
- </p>
<% end %>
<% end %>
- <% end %>
- </td>
- </tr>
+ </td>
+ </tr>
+ <% end %>
+ <% else %>
+ <tr>
+ <td colspan="6"><%= t('compliance_check_results.in_progress') %></td>
+ </tr>
<% end %>
</tbody>
<tfoot class="hide-if-no-paging">
diff --git a/app/views/compliance_checks/report.html.erb b/app/views/compliance_checks/report.html.erb
index 28abd4cbb..7bd0d7a92 100644
--- a/app/views/compliance_checks/report.html.erb
+++ b/app/views/compliance_checks/report.html.erb
@@ -30,7 +30,7 @@
</div>
<% content_for :sidebar do %>
- <% if @compliance_check.compliance_check_validation_report.nok_error.blank? %>
+ <% if @compliance_check.compliance_check_validation_report && @compliance_check.compliance_check_validation_report.nok_error.blank? %>
<div class="row">
<%=font_awesome_classic_tag('fa-thumbs-up fa-5x col-md-3')%>
<p class='col-md-7' id='validation_success'><%=t('.validation_success')%></p>
diff --git a/app/views/compliance_checks/show.html.erb b/app/views/compliance_checks/show.html.erb
index 1a1f842f5..1b656692e 100644
--- a/app/views/compliance_checks/show.html.erb
+++ b/app/views/compliance_checks/show.html.erb
@@ -13,7 +13,7 @@
<div class="links">
<%= link_to font_awesome_classic_tag("fa-external-link") + t("compliance_checks.actions.report"), report_referential_compliance_check_path(@referential, @compliance_check.id) if @compliance_check.compliance_check_validation_report? %>
</div>
- <%= render(partial: "shared/ie_report.html", locals: { job: @compliance_check, type: :validation } ) %>
+ <%= render(partial: "shared/ie_report", locals: { job: @compliance_check, type: :validation, line_items: @line_items } ) %>
</div>
<% content_for :sidebar do %>
diff --git a/app/views/journey_patterns/_journey_pattern.html.erb b/app/views/journey_patterns/_journey_pattern.html.erb
index 5794f8d69..029b3c40e 100644
--- a/app/views/journey_patterns/_journey_pattern.html.erb
+++ b/app/views/journey_patterns/_journey_pattern.html.erb
@@ -21,9 +21,16 @@
<% end %>
<p><%= t('.stop_count', :count => journey_pattern.stop_points.count, :route_count => @route.stop_points.count) %> | <%= t('.vehicle_journeys_count', :count => journey_pattern.vehicle_journeys.count) %></p>
<% if journey_pattern.vehicle_journeys.count > 0 %>
- <p>
- <i class="fa fa-clock-o"></i><%= link_to t('journey_patterns.journey_pattern.vehicle_journey_at_stops'), referential_line_route_vehicle_journeys_path(@referential, @line, @route, :q => {:journey_pattern_id_eq => journey_pattern.id}), :class => "with_fa" %>
- </p>
+ <p>
+ <i class="fa fa-clock-o"></i>
+ <%= link_to t('journey_patterns.journey_pattern.vehicle_journey_at_stops'), referential_line_route_vehicle_journeys_path(@referential, @line, @route, :q => {:journey_pattern_id_eq => journey_pattern.id}), :class => "with_fa" %>
+ </p>
+ <% if exist_vehicle_journey_frequencies?(@route, journey_pattern) %>
+ <p>
+ <i class="fa fa-clock-o"></i>
+ <%= link_to t('vehicle_journey_frequencies.actions.index'), referential_line_route_vehicle_journey_frequencies_path(@referential, @line, @route, :q => {:journey_pattern_id_eq => journey_pattern.id}) %>
+ </p>
+ <% end %>
<% end %>
</div>
</div>
diff --git a/app/views/routes/_route.html.erb b/app/views/routes/_route.html.erb
index 179f06a25..d428d5b38 100644
--- a/app/views/routes/_route.html.erb
+++ b/app/views/routes/_route.html.erb
@@ -30,7 +30,7 @@
<%= t('.no_journey_pattern')%>
<% end%>
</p>
- <% if @line.vehicle_journey_frequencies? %>
+ <% if exist_vehicle_journey_frequencies?(route) %>
<p>
<i class="fa fa-clock-o"></i>
<%= link_to t("vehicle_journey_frequencies.actions.index"), referential_line_route_vehicle_journey_frequencies_path(@referential, @line, route) %>
diff --git a/app/views/shared/_ie_report_file.html.erb b/app/views/shared/_ie_report_file.html.erb
index 20e4bb659..fdd97f128 100644
--- a/app/views/shared/_ie_report_file.html.erb
+++ b/app/views/shared/_ie_report_file.html.erb
@@ -5,7 +5,7 @@
<p>
<form class="form-inline">
<div class="form-group">
- <label><%= t("shared.ie_report.html.search") %></label>
+ <label><%= t("shared.ie_report.search") %></label>
<input id="filter-file" type="text" class="form-control">
</div>
<div class="form-group">
diff --git a/app/views/shared/_ie_report_line.html.erb b/app/views/shared/_ie_report_line.html.erb
index 69a12779c..2f5332e5b 100644
--- a/app/views/shared/_ie_report_line.html.erb
+++ b/app/views/shared/_ie_report_line.html.erb
@@ -12,7 +12,7 @@
<p>
<form class="form-inline">
<div class="form-group">
- <label><%= t("shared.ie_report.html.search") %></label>
+ <label><%= t("shared.ie_report.search") %></label>
<input id="filter-line" type="text" class="form-control">
</div>
<div class="form-group">
@@ -25,7 +25,7 @@
</div>
</form>
</p>
- <table class="table table-hover table-striped data-table toggle-circle toggle-medium" data-filter="#filter-line" id="table-line"<% unless line_items.respond_to?(:total_pages) %> data-page-size="20"<% end %>>
+ <table class="table table-hover table-striped data-table toggle-circle toggle-medium" data-filter="#filter-line" id="table-line" data-page-size="20"<% if line_items.respond_to?(:total_pages) %> data-no-pagination="true"<% end %>>
<thead>
<tr>
<th><%= t(".table.line.state") %></th>
@@ -59,14 +59,13 @@
<tfoot>
<tr>
<td colspan="10">
- <% unless line_items.respond_to?(:total_pages) %>
- <ul class="pagination pagination-centered"></ul>
+ <% if line_items.respond_to?(:total_pages) %>
+ <%= will_paginate line_items, renderer: BootstrapPagination::Rails %>
+ <% else %>
+ <ul class="pagination pagination-centered hide-if-no-paging"></ul>
<% end %>
</td>
</tr>
</tfoot>
</table>
- <% if line_items.respond_to?(:total_pages) %>
- <%= will_paginate line_items, renderer: BootstrapPagination::Rails %>
- <% end %>
</div>
diff --git a/app/views/vehicle_journeys/_vehicle_journeys.html.erb b/app/views/vehicle_journeys/_vehicle_journeys.html.erb
index 3bff10b59..71a28ec6e 100644
--- a/app/views/vehicle_journeys/_vehicle_journeys.html.erb
+++ b/app/views/vehicle_journeys/_vehicle_journeys.html.erb
@@ -2,10 +2,11 @@
<span class="search"><%= t("will_paginate.page_entries_info.search") %></span>
<%= page_entries_info @vehicle_journeys %>
<span class="pull-right">
- <i class="fa fa-clock-o"></i>
- <% if controller_name == 'vehicle_journey_frequencies' %>
+ <% if controller_name == 'vehicle_journey_frequencies' && exist_vehicle_journeys?(@route) %>
+ <i class="fa fa-clock-o"></i>
<%= link_to t("vehicle_journeys.actions.show"), referential_line_route_vehicle_journeys_path(@referential, @line, @route) %>
- <% else %>
+ <% elsif exist_vehicle_journey_frequencies?(@route) %>
+ <i class="fa fa-clock-o"></i>
<%= link_to t("vehicle_journey_frequencies.actions.show"), referential_line_route_vehicle_journey_frequencies_path(@referential, @line, @route) %>
<% end %>
</span>
diff --git a/config/locales/breadcrumbs.fr.yml b/config/locales/breadcrumbs.fr.yml
index 03c0155e2..ffcba3015 100644
--- a/config/locales/breadcrumbs.fr.yml
+++ b/config/locales/breadcrumbs.fr.yml
@@ -1,6 +1,6 @@
fr:
breadcrumbs:
vehicle_journeys: "Horaires"
- vehicle_journey_frequencies: "Plages horaires"
+ vehicle_journey_frequencies: "Créneaux horaires"
referentials: "Accueil"
users: "Utilisateurs"
diff --git a/config/locales/compliance_check_results.en.yml b/config/locales/compliance_check_results.en.yml
index 72a87e17f..dcc0f4598 100644
--- a/config/locales/compliance_check_results.en.yml
+++ b/config/locales/compliance_check_results.en.yml
@@ -8,6 +8,7 @@ en:
index:
line: "Li"
column: "Col"
+ in_progress: "Compliance check in progress..."
compliance_check_result:
severities:
error: "Required"
diff --git a/config/locales/compliance_check_results.fr.yml b/config/locales/compliance_check_results.fr.yml
index bfca568dd..c630e3e83 100644
--- a/config/locales/compliance_check_results.fr.yml
+++ b/config/locales/compliance_check_results.fr.yml
@@ -8,6 +8,7 @@ fr:
index:
line: "Li"
column: "Col"
+ in_progress: "Validation en cours..."
compliance_check_result:
severities:
error: "Obligatoires"
diff --git a/config/locales/journey_frequencies.fr.yml b/config/locales/journey_frequencies.fr.yml
index 7bfd6de69..a168117d5 100644
--- a/config/locales/journey_frequencies.fr.yml
+++ b/config/locales/journey_frequencies.fr.yml
@@ -1,6 +1,6 @@
fr:
journey_frequencies:
- time_band: Plages horaires
+ time_band: Créneaux horaires
form:
add_line: Ajouter une ligne
activerecord:
@@ -10,4 +10,4 @@ fr:
last_departure_time: Dernier départ
scheduled_headway_interval: Intervalle
exact_time: Exact ?
- timeband: Plage horaires
+ timeband: Créneau horaire
diff --git a/config/locales/referentials.fr.yml b/config/locales/referentials.fr.yml
index 7a1d26956..d8b72d3e3 100644
--- a/config/locales/referentials.fr.yml
+++ b/config/locales/referentials.fr.yml
@@ -69,7 +69,7 @@ fr:
rule_parameter_sets: "Jeux de paramètres"
data_format_restrictions: "Format d'export privilégié"
data_format: "Format d'export privilégié"
- timebands: "Plages horaires"
+ timebands: "Créneaux horaires"
formtastic:
titles:
referential:
diff --git a/config/locales/timebands.fr.yml b/config/locales/timebands.fr.yml
index 1865d0c39..2653fe686 100644
--- a/config/locales/timebands.fr.yml
+++ b/config/locales/timebands.fr.yml
@@ -1,24 +1,24 @@
fr:
timebands:
actions:
- new: "Ajouter une plage horaire"
- edit: "Modifier cette plage horaire"
- destroy: "Supprimer cette plage horaire"
- destroy_confirm: "Merci de confirmer la suppression de cette plage horaire."
+ new: "Ajouter un créneau horaire"
+ edit: "Modifier ce créneau horaire"
+ destroy: "Supprimer ce créneau horaire"
+ destroy_confirm: "Merci de confirmer la suppression de ce créneau horaire."
new:
- title: "Ajouter une plage horaire"
+ title: "Ajouter un créneau horaire"
edit:
- title: "Modifier la plage horaire %{timeband}"
+ title: "Modifier le créneau horaire %{timeband}"
show:
- title: Plage horaire %{timeband}
+ title: "Créneau horaire %{timeband}"
index:
- title: "Plages horaires"
+ title: "Créneaux horaires"
activerecord:
models:
timeband:
- zero: "plage horaire"
- one: "plage horaire"
- other: "plages horaires"
+ zero: "créneau horaire"
+ one: "créneau horaire"
+ other: "créneaux horaires"
attributes:
timeband:
name: "Titre"
diff --git a/config/locales/vehicle_journey_frequencies.fr.yml b/config/locales/vehicle_journey_frequencies.fr.yml
index d8bc48b4b..20b0a6eac 100644
--- a/config/locales/vehicle_journey_frequencies.fr.yml
+++ b/config/locales/vehicle_journey_frequencies.fr.yml
@@ -1,7 +1,7 @@
fr:
vehicle_journey_frequencies:
vehicle_journeys_matrix:
- line_routes: Séquences d'arrêts de la ligne
+ line_routes: "Séquences d'arrêts de la ligne"
actions:
- index: "Courses à fréquence"
- show: "Voir les courses à fréquence"
+ index: "Courses en fréquence"
+ show: "Voir les courses en fréquence"
diff --git a/config/locales/vehicle_journeys.fr.yml b/config/locales/vehicle_journeys.fr.yml
index d879e7a4e..2adcde6a7 100644
--- a/config/locales/vehicle_journeys.fr.yml
+++ b/config/locales/vehicle_journeys.fr.yml
@@ -6,21 +6,21 @@ fr:
title_stopless: "Course %{name}"
title: "Course partant de %{stop} à %{time}"
vehicle_journey_frequency:
- title_stopless: "Course à fréquences %{name}"
- title: "Course à fréquence partant de %{stop} à %{time}"
- title_frequency: "Course à fréquence de %{interval}min partant de %{stop} de %{time_first} à %{time_last}"
+ title_stopless: "Course en fréquence %{name}"
+ title: "Course en fréquence partant de %{stop} à %{time}"
+ title_frequency: "Course en fréquence de %{interval}min partant de %{stop} de %{time_first} à %{time_last}"
actions:
index: "Horaires des courses"
new: "Ajouter une course à horaire"
- new_frequency: "Ajouter une course à fréquence"
+ new_frequency: "Ajouter une course en fréquence"
edit: "Modifier cette course à horaire"
- edit_frequency: "Modifier cette course à fréquence"
+ edit_frequency: "Modifier cette course en fréquence"
destroy: "Supprimer cette course"
destroy_confirm: "Etes vous sûr de supprimer cette course ?"
show: "Voir les courses à horaire"
new:
title: "Ajouter une course à horaire"
- title_frequency: "Ajouter une course à fréquence"
+ title_frequency: "Ajouter une course en fréquence"
edit:
title_stopless: "Modifier la course %{name}"
title: "Modifier la course partant de %{stop} à %{time}"
@@ -38,9 +38,9 @@ fr:
slide_departure: "horaire de départ au 1° arrêt à"
slide_arrival: "horaire d'arrivée au 1° arrêt à"
submit_timed: "Créer course"
- submit_frequency: "Créer course à fréquence"
+ submit_frequency: "Créer course en fréquence"
submit_timed_edit: "Modifier course"
- submit_frequency_edit: "Modifier course à fréquence"
+ submit_frequency_edit: "Modifier course en fréquence"
timeless:
title: "Courses sans horaire"
vehicle_journeys: "Courses ayant des horaires"
diff --git a/spec/features/timebands_spec.rb b/spec/features/timebands_spec.rb
index 6f07fab4f..bd1d4b820 100644
--- a/spec/features/timebands_spec.rb
+++ b/spec/features/timebands_spec.rb
@@ -28,7 +28,7 @@ describe "Timebands", :type => :feature do
describe "new" do
it "creates timeband and return to show" do
visit referential_timebands_path(referential)
- click_link "Ajouter une plage horaire"
+ click_link "Ajouter un créneau horaire"
fill_in "Titre", :with => "Timeband 1"
select '10', from: 'timeband_start_time_4i'
@@ -36,7 +36,7 @@ describe "Timebands", :type => :feature do
select '11', from: 'timeband_end_time_4i'
select '00', from: 'timeband_end_time_5i'
- click_button("Créer plage horaire")
+ click_button("Créer créneau horaire")
expect(page).to have_content("Timeband 1")
end
end
@@ -44,9 +44,9 @@ describe "Timebands", :type => :feature do
describe "edit and return to show" do
it "edit timeband" do
visit referential_timeband_path(referential, subject)
- click_link "Modifier cette plage horaire"
+ click_link "Modifier ce créneau horaire"
fill_in "Titre", :with => "Timeband Modified"
- click_button("Modifier plage horaire")
+ click_button("Modifier créneau horaire")
expect(page).to have_content("Timeband Modified")
end
end