]> source.dussan.org Git - redmine.git/commitdiff
Fixed: "Add news" link broken by recent refactoring (#6650).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Fri, 22 Oct 2010 14:42:38 +0000 (14:42 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Fri, 22 Oct 2010 14:42:38 +0000 (14:42 +0000)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@4267 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/views/news/index.rhtml

index c2a227fe0f61d1742fa965e24ad3b785b0e3bf5e..b9cd2b24e1bc6fcd7ef23fe6455a8b4b02188908 100644 (file)
@@ -1,8 +1,8 @@
 <div class="contextual">
-<%= link_to_if_authorized(l(:label_news_new),
-                          new_project_news_path(@project),
-                          :class => 'icon icon-add',
-                          :onclick => 'Element.show("add-news"); Form.Element.focus("news_title"); return false;') if @project %>
+<%= link_to(l(:label_news_new),
+            new_project_news_path(@project),
+            :class => 'icon icon-add',
+            :onclick => 'Element.show("add-news"); Form.Element.focus("news_title"); return false;') if @project && User.current.allowed_to?(:manage_news, @project) %>
 </div>
 
 <div id="add-news" style="display:none;">