From 9eca9f937516668a9b247e4a98a396567f4fc060 Mon Sep 17 00:00:00 2001 From: xdite Date: Wed, 13 Feb 2013 19:15:10 +0800 Subject: [PATCH] use helper again --- app/helpers/topics_helper.rb | 3 --- app/views/topics/show.html.erb | 4 ++-- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/app/helpers/topics_helper.rb b/app/helpers/topics_helper.rb index 978b118d5b1..8ad809ef62b 100644 --- a/app/helpers/topics_helper.rb +++ b/app/helpers/topics_helper.rb @@ -4,7 +4,4 @@ module TopicsHelper link_to(topic.title,topic.relative_url) end - def render_topic_next_page_link(topic, next_page) - link_to("next page", "#{topic.relative_url}?page=#{next_page}") - end end diff --git a/app/views/topics/show.html.erb b/app/views/topics/show.html.erb index e4125c15dcf..4a6f5d2e594 100644 --- a/app/views/topics/show.html.erb +++ b/app/views/topics/show.html.erb @@ -1,5 +1,5 @@

- <%= @topic_view.title %> + <%= render_topic_title(@topic_view.topic) %>


@@ -15,7 +15,7 @@ <% if @topic_view.next_page %>

- next page → + <%= link_to("next page →", @topic_view.next_page_path ) %>

<% end %>