Commit 79c27e6a authored by Jacob Schatz's avatar Jacob Schatz

Merge branch 'emoji_award_coffee_refactoring' into 'master'

AwardsHandler follows code style conventions



See merge request !3871
parents bfc6a0e3 311c859d
...@@ -167,8 +167,8 @@ class @Notes ...@@ -167,8 +167,8 @@ class @Notes
return return
if note.award if note.award
awards_handler.addAwardToEmojiBar(note.note) awardsHandler.addAwardToEmojiBar(note.note)
awards_handler.scrollToAwards() awardsHandler.scrollToAwards()
# render note if it not present in loaded list # render note if it not present in loaded list
# or skip if rendered # or skip if rendered
......
...@@ -15,16 +15,16 @@ ...@@ -15,16 +15,16 @@
- if current_user - if current_user
:javascript :javascript
var get_emojis_url = "#{emojis_path}"; var getEmojisUrl = "#{emojis_path}";
var post_emoji_url = "#{award_toggle_namespace_project_notes_path(@project.namespace, @project)}"; var postEmojiUrl = "#{award_toggle_namespace_project_notes_path(@project.namespace, @project)}";
var noteable_type = "#{votable.class.name.underscore}"; var noteableType = "#{votable.class.name.underscore}";
var noteable_id = "#{votable.id}"; var noteableId = "#{votable.id}";
var unicodes = #{AwardEmoji.unicode.to_json}; var unicodes = #{AwardEmoji.unicode.to_json};
window.awards_handler = new AwardsHandler( window.awardsHandler = new AwardsHandler(
get_emojis_url, getEmojisUrl,
post_emoji_url, postEmojiUrl,
noteable_type, noteableType,
noteable_id, noteableId,
unicodes unicodes
); );
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment