summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2009-05-25 20:38:59 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2009-05-25 20:38:59 +0000
commit5db407ca59cd63282837097957db3961b6e63fc0 (patch)
tree67b056c95d756e11fe5096967e1079359ab83a9b
parent53b002b4970c6c0f690a0d6788f20ca50306f233 (diff)
downloadredmine-5db407ca59cd63282837097957db3961b6e63fc0.tar.gz
redmine-5db407ca59cd63282837097957db3961b6e63fc0.zip
Render new message form if needed.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@2767 e93f8b46-1217-0410-a6f0-8f06a7374b81
-rw-r--r--app/views/boards/show.rhtml2
1 files changed, 2 insertions, 0 deletions
diff --git a/app/views/boards/show.rhtml b/app/views/boards/show.rhtml
index 7f1600af0..9a4028c95 100644
--- a/app/views/boards/show.rhtml
+++ b/app/views/boards/show.rhtml
@@ -9,6 +9,7 @@
</div>
<div id="add-message" style="display:none;">
+<% if authorize_for('messages', 'new') %>
<h2><%= link_to h(@board.name), :controller => 'boards', :action => 'show', :project_id => @project, :id => @board %> &#187; <%= l(:label_message_new) %></h2>
<% form_for :message, @message, :url => {:controller => 'messages', :action => 'new', :board_id => @board}, :html => {:multipart => true, :id => 'message-form'} do |f| %>
<%= render :partial => 'messages/form', :locals => {:f => f} %>
@@ -23,6 +24,7 @@
<%= link_to l(:button_cancel), "#", :onclick => 'Element.hide("add-message")' %></p>
<% end %>
<div id="preview" class="wiki"></div>
+<% end %>
</div>
<h2><%=h @board.name %></h2>