summaryrefslogtreecommitdiff
path: root/web-ui/app/js/mail_view/ui/mail_view.js
diff options
context:
space:
mode:
authorPatrick Maia <patrickjourdanmaia@gmail.com>2014-08-07 18:01:01 -0300
committerPatrick Maia <patrickjourdanmaia@gmail.com>2014-08-08 13:44:44 -0300
commitbd624bdd14ef63186064b2e39fc422f328b24b26 (patch)
tree4a1ecee496baaf490354b5f11f222410ecf94379 /web-ui/app/js/mail_view/ui/mail_view.js
parentb30c4434e50c4e3ac128cf04ce4935ca6c660037 (diff)
disables save draft, add tag, reply-section features
Diffstat (limited to 'web-ui/app/js/mail_view/ui/mail_view.js')
-rw-r--r--web-ui/app/js/mail_view/ui/mail_view.js21
1 files changed, 12 insertions, 9 deletions
diff --git a/web-ui/app/js/mail_view/ui/mail_view.js b/web-ui/app/js/mail_view/ui/mail_view.js
index 1e27c879..9114fa2e 100644
--- a/web-ui/app/js/mail_view/ui/mail_view.js
+++ b/web-ui/app/js/mail_view/ui/mail_view.js
@@ -12,10 +12,11 @@ define(
'helpers/view_helper',
'mixins/with_hide_and_show',
'page/events',
- 'views/i18n'
+ 'views/i18n',
+ 'features'
],
- function (defineComponent, templates, mailActions, viewHelpers, withHideAndShow, events, i18n) {
+ function (defineComponent, templates, mailActions, viewHelpers, withHideAndShow, events, i18n, features) {
return defineComponent(mailView, mailActions, withHideAndShow);
@@ -148,13 +149,15 @@ define(
};
this.createNewTag = function() {
- var tagsCopy = this.attr.mail.tags.slice();
- tagsCopy.push(this.select('newTagInput').val());
- this.attr.tagCompleter.clear();
- this.attr.tagCompleter.clearPrefetchCache();
- this.attr.tagCompleter.clearRemoteCache();
- this.trigger(document, events.mail.tags.update, { ident: this.attr.mail.ident, tags: _.uniq(tagsCopy)});
- this.trigger(document, events.dispatchers.tags.refreshTagList);
+ if(features.isEnabled('createNewTag')) {
+ var tagsCopy = this.attr.mail.tags.slice();
+ tagsCopy.push(this.select('newTagInput').val());
+ this.attr.tagCompleter.clear();
+ this.attr.tagCompleter.clearPrefetchCache();
+ this.attr.tagCompleter.clearRemoteCache();
+ this.trigger(document, events.mail.tags.update, { ident: this.attr.mail.ident, tags: _.uniq(tagsCopy)});
+ this.trigger(document, events.dispatchers.tags.refreshTagList);
+ }
};
this.handleKeyDown = function(event) {