diff options
author | Giovane <giovaneliberato@gmail.com> | 2015-09-21 17:38:55 -0300 |
---|---|---|
committer | Giovane <giovaneliberato@gmail.com> | 2015-09-21 18:09:07 -0300 |
commit | b492d6928dc757e56404a1a6f0d632658c38bc13 (patch) | |
tree | 21517158863acdfe7cb133e3e71f74484be32060 /web-ui/app/js/mail_view/ui | |
parent | 84b78e43770efa48d85818cf99aecccbd3035d7b (diff) |
#442 Shows success message after sending feedback
Diffstat (limited to 'web-ui/app/js/mail_view/ui')
-rw-r--r-- | web-ui/app/js/mail_view/ui/feedback_box.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/web-ui/app/js/mail_view/ui/feedback_box.js b/web-ui/app/js/mail_view/ui/feedback_box.js index aad35f2a..eb079b5b 100644 --- a/web-ui/app/js/mail_view/ui/feedback_box.js +++ b/web-ui/app/js/mail_view/ui/feedback_box.js @@ -46,11 +46,16 @@ define(['flight/lib/component', 'views/templates', 'page/events', 'features'], this.trigger(document, events.feedback.submit, { feedback: feedback }); }; + this.showSuccessMessage = function () { + this.trigger(document, events.ui.userAlerts.displayMessage, { message: 'Thanks for your feedback!' }); + }; + this.after('initialize', function () { if (features.isEnabled('feedback')) { this.render(); this.on(document, events.dispatchers.rightPane.openFeedbackBox, this.openFeedbackBox); this.on(document, events.feedback.submitted, this.showNoMessageSelected); + this.on(document, events.feedback.submitted, this.showSuccessMessage); this.on(this.select('closeButton'), 'click', this.showNoMessageSelected); this.on(this.select('submitButton'), 'click', this.submitFeedback); } |