##// END OF EJS Templates
Adds wiki toolbar to notes editing form (#7899)....
Jean-Philippe Lang -
r5120:9730ff22257b
parent child
Show More
@@ -1,19 +1,21
1 1 <% reply_links = authorize_for('issues', 'edit') -%>
2 2 <% for journal in journals %>
3 3 <div id="change-<%= journal.id %>" class="<%= journal.css_classes %>">
4 4 <h4><div class="journal-link"><%= link_to "##{journal.indice}", :anchor => "note-#{journal.indice}" %></div>
5 5 <%= avatar(journal.user, :size => "24") %>
6 6 <%= content_tag('a', '', :name => "note-#{journal.indice}")%>
7 7 <%= authoring journal.created_on, journal.user, :label => :label_updated_time_by %></h4>
8 8
9 9 <% if journal.details.any? %>
10 10 <ul class="details">
11 11 <% for detail in journal.details %>
12 12 <li><%= show_detail(detail) %></li>
13 13 <% end %>
14 14 </ul>
15 15 <% end %>
16 16 <%= render_notes(issue, journal, :reply_links => reply_links) unless journal.notes.blank? %>
17 17 </div>
18 18 <%= call_hook(:view_issues_history_journal_bottom, { :journal => journal }) %>
19 19 <% end %>
20
21 <% heads_for_wiki_formatter if User.current.allowed_to?(:edit_issue_notes, issue.project) || User.current.allowed_to?(:edit_own_issue_notes, issue.project) %>
@@ -1,8 +1,11
1 1 <% form_remote_tag(:url => {}, :html => { :id => "journal-#{@journal.id}-form" }) do %>
2 <%= text_area_tag :notes, @journal.notes, :class => 'wiki-edit',
2 <%= text_area_tag :notes, @journal.notes,
3 :id => "journal_#{@journal.id}_notes",
4 :class => 'wiki-edit',
3 5 :rows => (@journal.notes.blank? ? 10 : [[10, @journal.notes.length / 50].max, 100].min) %>
4 6 <%= call_hook(:view_journals_notes_form_after_notes, { :journal => @journal}) %>
5 7 <p><%= submit_tag l(:button_save) %>
6 8 <%= link_to l(:button_cancel), '#', :onclick => "Element.remove('journal-#{@journal.id}-form'); " +
7 9 "Element.show('journal-#{@journal.id}-notes'); return false;" %></p>
8 10 <% end %>
11 <%= wikitoolbar_for "journal_#{@journal.id}_notes" %>
General Comments 0
You need to be logged in to leave comments. Login now