2011-10-20 18:21:58 +02:00
|
|
|
- if controller.action_name == "wall"
|
|
|
|
%ul#notes-list= render "notes/notes_list"
|
2011-10-08 23:36:38 +02:00
|
|
|
|
2011-10-26 15:46:25 +02:00
|
|
|
- else
|
2011-10-20 18:21:58 +02:00
|
|
|
%ul#notes-list= render "notes/notes_list"
|
|
|
|
%br
|
|
|
|
%br
|
|
|
|
- if can? current_user, :write_note, @project
|
|
|
|
= render "notes/form"
|
2011-10-08 23:36:38 +02:00
|
|
|
|
|
|
|
:javascript
|
2011-10-26 15:46:25 +02:00
|
|
|
$('.delete-note').live('ajax:success', function() {
|
|
|
|
$(this).closest('li').fadeOut(); });
|
2011-10-08 23:36:38 +02:00
|
|
|
|
2011-10-17 19:05:47 +02:00
|
|
|
$("#new_note").live("ajax:before", function(){
|
2011-10-26 15:46:25 +02:00
|
|
|
$("#submit_note").attr("disabled", "disabled");
|
2011-10-17 19:05:47 +02:00
|
|
|
})
|
|
|
|
|
|
|
|
$("#new_note").live("ajax:complete", function(){
|
2011-10-26 15:46:25 +02:00
|
|
|
$("#submit_note").removeAttr("disabled");
|
2011-10-17 19:05:47 +02:00
|
|
|
})
|
|
|
|
|
2011-10-17 18:48:10 +02:00
|
|
|
- if ["issues", "projects"].include?(controller.controller_name)
|
|
|
|
:javascript
|
|
|
|
$(function(){
|
|
|
|
var int =self.setInterval("updatePage()", 20000);
|
|
|
|
});
|