_notes.html.haml 498 Bytes
%ul#notes-list= render "notes/notes_list"

%br
%br
- if can? current_user, :write_note, @project
  = render "notes/form"

:javascript
  $('.delete-note').live('ajax:success', function() {  
    $(this).closest('li').fadeOut(); });  

- if ["issues", "projects"].include?(controller.controller_name)
  :javascript
    $(function(){
      var int =self.setInterval("updatePage()", 20000);
    });

    function updatePage(){
      $.ajax({type: "GET", url: location.href, dataType: "script"});
    }