Add comments to Wiki pages
This commit is contained in:
parent
652d28f56b
commit
36efa2042c
10 changed files with 72 additions and 1 deletions
|
@ -18,6 +18,8 @@ class Admin::MailerController < ApplicationController
|
|||
when "Issue" then
|
||||
@issue = Issue.first
|
||||
render :file => 'notify/note_issue_email', :layout => 'notify'
|
||||
when "Wiki" then
|
||||
render :file => 'notify/note_wiki_email', :layout => 'notify'
|
||||
else
|
||||
render :file => 'notify/note_wall_email', :layout => 'notify'
|
||||
end
|
||||
|
|
|
@ -51,6 +51,8 @@ class NotesController < ApplicationController
|
|||
then project.issues.find(params[:target_id]).notes.inc_author.order("created_at DESC").limit(20)
|
||||
when "merge_request"
|
||||
then project.merge_requests.find(params[:target_id]).notes.inc_author.order("created_at DESC").limit(20)
|
||||
when "wiki"
|
||||
then project.wikis.find(params[:target_id]).notes.order("created_at DESC").limit(20)
|
||||
end
|
||||
|
||||
@notes = if params[:last_id]
|
||||
|
|
|
@ -17,6 +17,8 @@ class WikisController < ApplicationController
|
|||
return render_404 unless can?(current_user, :write_wiki, @project)
|
||||
end
|
||||
|
||||
@note = @project.notes.new(:noteable => @wiki)
|
||||
|
||||
respond_to do |format|
|
||||
if @wiki
|
||||
format.html
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue