2012-01-11 23:26:01 +01:00
|
|
|
%table{:style => "display:none;"}
|
|
|
|
%tr.per_line_form
|
|
|
|
%td{:colspan => 3 }
|
2012-01-28 10:54:11 +01:00
|
|
|
%div.well
|
2012-01-11 23:26:01 +01:00
|
|
|
= form_for [@project, @note], :remote => "true", :multipart => true do |f|
|
2012-01-28 10:54:11 +01:00
|
|
|
%h3 Leave a note
|
2012-01-11 23:26:01 +01:00
|
|
|
-if @note.errors.any?
|
2012-01-28 10:54:11 +01:00
|
|
|
.alert-message.block-message.error
|
2012-01-11 23:26:01 +01:00
|
|
|
- @note.errors.full_messages.each do |msg|
|
|
|
|
%div= msg
|
|
|
|
|
|
|
|
= f.hidden_field :noteable_id
|
|
|
|
= f.hidden_field :noteable_type
|
|
|
|
= f.hidden_field :line_code
|
2012-01-28 10:54:11 +01:00
|
|
|
= f.text_area :note, :size => 255
|
|
|
|
.prepend-top-10
|
|
|
|
= f.submit 'Add note', :class => "btn primary", :id => "submit_note"
|
|
|
|
.right
|
|
|
|
= link_to "Close", "#", :class => "btn hide-button"
|
2012-01-11 23:26:01 +01:00
|
|
|
|
2012-01-20 08:51:48 +01:00
|
|
|
:javascript
|
|
|
|
$(function(){
|
|
|
|
$(".per_line_form .hide-button").bind("click", function(){
|
|
|
|
$('.per_line_form').hide();
|
|
|
|
return false;
|
|
|
|
});
|
|
|
|
});
|