<%#= link_to(l(:button_edit), edit_contest_contestnotification_path(@contest, @contestnotification), :class => 'icon icon-edit', :accesskey => accesskey(:edit), :onclick => '$("#edit-contestnotifications").show(); return true;') if User.current %> <%= delete_link contest_contestnotification_path(@contest, @contestnotification) if (User.current.admin? && User.current.logged? )||(User.current == @contest.author && User.current.logged?) %>

<%=h @contestnotification.title %>

<% if authorize_for_contest('contestnotifications', 'edit') %> <% end %>
<%= textilizable(@contestnotification, :description) %>
<%#= link_to_attachments @contestnotification %>

<%= toggle_link l(:label_comment_add), "add_notificationcomment_form", :focus => "notificationcomment_notificationcomments" %>

<%= form_tag( contest_contestnotification_notificationcomments_path(@contest, @contestnotification) , :id => "add_notificationcomment_form", :style => "display:none;") do %>
<%= text_area 'notificationcomment', 'notificationcomments', :cols => 80, :rows => 15, :class => 'wiki-edit' %> <%= wikitoolbar_for 'notificationcomment_notificationcomments' %>

<%= submit_tag l(:button_add) %> <%= submit_tag l(:button_cancel), :onclick => "cancel();" %>

<% end %> <% html_title @contestnotification.title -%> <% content_for :header_tags do %> <%= stylesheet_link_tag 'scm' %> <% end %>

<%= l(:label_comment_plural) %>

<% notificationcomments = @notificationcomments.reverse %> <% notificationcomments.each do |notificationcomment| %> <% next if notificationcomment.new_record? %>
<%= image_tag(url_to_avatar(notificationcomment.author), :class => "avatar")%>
<%= link_to_user(notificationcomment.author) if notificationcomment.respond_to?(:author) %> <%= l(:label_project_newadd) %><%= l(:label_comment_plural) %>

<%= textilizable(notificationcomment.notificationcomments) %>

<%= format_time(notificationcomment.created_at) %> <%= link_to_if_authorized_contest image_tag('delete.png'), {:controller => 'notificationcomments', :action => 'destroy', :id => @contestnotifications, :notificationcomment_id => notificationcomment}, :data => {:confirm => l(:text_are_you_sure)}, :method => :delete, :title => l(:button_delete) %>
<% end if @notificationcomments.any? %>