diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2012-08-10 06:42:31 -0700 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2012-08-10 06:42:31 -0700 |
commit | 5fd0e7ba119d59a3e9f2ea3eed03ece1e8baeec3 (patch) | |
tree | 2df982fb426d38e61589e66eb958138a105a0a19 /app/controllers/notes_controller.rb | |
parent | 35b45da63e683e29318afac2e41ec8b3ac8419ab (diff) | |
parent | 9639780359f16d784f22af2a1dbbcd8322ffd6c3 (diff) | |
download | gitlab-ce-5fd0e7ba119d59a3e9f2ea3eed03ece1e8baeec3.tar.gz |
Merge pull request #1198 from NARKOZ/preview_notes
ability to preview notes
Diffstat (limited to 'app/controllers/notes_controller.rb')
-rw-r--r-- | app/controllers/notes_controller.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/app/controllers/notes_controller.rb b/app/controllers/notes_controller.rb index e8e4bb544a8..8fac6428a58 100644 --- a/app/controllers/notes_controller.rb +++ b/app/controllers/notes_controller.rb @@ -33,7 +33,11 @@ class NotesController < ApplicationController end end - protected + def preview + render :text => view_context.markdown(params[:note]) + end + + protected def notes @notes = Notes::LoadContext.new(project, current_user, params).execute |