2012-08-11 00:07:50 +02:00
|
|
|
%table{style: "display:none;"}
|
2012-01-11 23:26:01 +01:00
|
|
|
%tr.per_line_form
|
2012-08-11 00:07:50 +02:00
|
|
|
%td{colspan: 3 }
|
2012-08-30 20:31:55 +02:00
|
|
|
.line-note-form-holder
|
|
|
|
= form_for [@project, @note], remote: "true", multipart: true do |f|
|
|
|
|
%h3.page_title Leave a note
|
|
|
|
%div.span10
|
|
|
|
-if @note.errors.any?
|
|
|
|
.alert-message.block-message.error
|
|
|
|
- @note.errors.full_messages.each do |msg|
|
|
|
|
%div= msg
|
2012-01-11 23:26:01 +01:00
|
|
|
|
2012-08-30 20:31:55 +02:00
|
|
|
= f.hidden_field :noteable_id
|
2012-12-18 19:02:00 +01:00
|
|
|
= f.hidden_field :commit_id
|
2012-08-30 20:31:55 +02:00
|
|
|
= f.hidden_field :noteable_type
|
|
|
|
= f.hidden_field :line_code
|
2012-10-12 08:19:34 +02:00
|
|
|
= f.text_area :note, size: 255, class: 'line-note-text js-gfm-input'
|
2012-08-30 20:31:55 +02:00
|
|
|
.note_actions
|
|
|
|
.buttons
|
2012-09-01 22:35:04 +02:00
|
|
|
= f.submit 'Add note', class: "btn save-btn submit_note submit_inline_note", id: "submit_note"
|
2012-08-30 20:31:55 +02:00
|
|
|
= link_to "Cancel", "#", class: "btn hide-button"
|
|
|
|
.options
|
|
|
|
%h6.left Notify via email:
|
|
|
|
.labels
|
|
|
|
= label_tag :notify do
|
|
|
|
= check_box_tag :notify, 1, @note.noteable_type != "Commit"
|
|
|
|
%span Project team
|
2012-02-13 23:20:23 +01:00
|
|
|
|
2012-08-30 20:31:55 +02:00
|
|
|
- if @note.notify_only_author?(current_user)
|
|
|
|
= label_tag :notify_author do
|
|
|
|
= check_box_tag :notify_author, 1 , @note.noteable_type == "Commit"
|
|
|
|
%span Commit author
|
2012-01-11 23:26:01 +01:00
|
|
|
|
2012-06-04 00:37:27 +02:00
|
|
|
:javascript
|
2012-01-20 08:51:48 +01:00
|
|
|
$(function(){
|
|
|
|
$(".per_line_form .hide-button").bind("click", function(){
|
|
|
|
$('.per_line_form').hide();
|
|
|
|
return false;
|
|
|
|
});
|
|
|
|
});
|