aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--app/views/time_tables/show.html.erb4
-rw-r--r--spec/views/time_tables/show.html.erb_spec.rb3
2 files changed, 4 insertions, 3 deletions
diff --git a/app/views/time_tables/show.html.erb b/app/views/time_tables/show.html.erb
index 45763fad5..d5034c6b2 100644
--- a/app/views/time_tables/show.html.erb
+++ b/app/views/time_tables/show.html.erb
@@ -64,9 +64,9 @@
</p>
<div class="year_choice">
- <span class="previous"> <%= link_to("<", :year => (@year - 1) ) %> </span>
+ <span class="previous"> <%= link_to("<", referential_time_table_path(@referential, @time_table, :year => (@year - 1)) ) %> </span>
<span class="year"> <%= "#{@year}" %> </span>
- <span class="next"> <%= link_to(">", :year => (@year + 1) ) %> </span>
+ <span class="next"> <%= link_to(">", referential_time_table_path(@referential, @time_table, :year => (@year + 1)) ) %> </span>
</div>
<div class="calendar_helper">
<%= cal = ""
diff --git a/spec/views/time_tables/show.html.erb_spec.rb b/spec/views/time_tables/show.html.erb_spec.rb
index 17449748b..9d0527c5d 100644
--- a/spec/views/time_tables/show.html.erb_spec.rb
+++ b/spec/views/time_tables/show.html.erb_spec.rb
@@ -4,8 +4,9 @@ describe "/time_tables/show" do
assign_referential
let!(:time_table) { assign(:time_table, create(:time_table)) }
+ let!(:year) { assign(:year, Date.today.cwyear) }
- it "should render h2 with the time_table comment" do
+ it "should render h2 with the time_table comment" do
render
rendered.should have_selector("h2", :text => Regexp.new(time_table.comment))
end