summaryrefslogtreecommitdiffstats
path: root/app/views/news/index.html.erb
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2012-07-18 17:47:19 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2012-07-18 17:47:19 +0000
commitff68fff80ed1cc9f95587581be9eb641d7a776e5 (patch)
tree8401052d01792a36dbe5486379e084a574a33c48 /app/views/news/index.html.erb
parentbb2af97dcf4ba9372ce78ba8163cc3dc2794a7bb (diff)
downloadredmine-ff68fff80ed1cc9f95587581be9eb641d7a776e5.tar.gz
redmine-ff68fff80ed1cc9f95587581be9eb641d7a776e5.zip
Adds a helper for preview links.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10031 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/views/news/index.html.erb')
-rw-r--r--app/views/news/index.html.erb7
1 files changed, 1 insertions, 6 deletions
diff --git a/app/views/news/index.html.erb b/app/views/news/index.html.erb
index b354adcb8..e62cce498 100644
--- a/app/views/news/index.html.erb
+++ b/app/views/news/index.html.erb
@@ -11,12 +11,7 @@
:html => { :id => 'news-form', :multipart => true } do |f| %>
<%= render :partial => 'news/form', :locals => { :f => f } %>
<%= submit_tag l(:button_create) %>
-<%= link_to_remote l(:label_preview),
- { :url => preview_news_path(:project_id => @project),
- :method => 'get',
- :update => 'preview',
- :with => "Form.serialize('news-form')"
- }, :accesskey => accesskey(:preview) %> |
+<%= preview_link preview_news_path(:project_id => @project), 'news-form' %> |
<%= link_to l(:button_cancel), "#", :onclick => 'Element.hide("add-news")' %>
<% end if @project %>
<div id="preview" class="wiki"></div>