summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorParamjit Singh Sahota <psa@tinyerp.com>2013-06-26 16:17:22 +0530
committerParamjit Singh Sahota <psa@tinyerp.com>2013-06-26 16:17:22 +0530
commitcc05ab11dfd7e2070d2af9642808de34ec031add (patch)
treee4eecd5399b7fcb10361a72a4c81580ceeb12adc
parent74bbd696f77af64dae1c49a60a298c252d21a8f3 (diff)
[IMP] Little Improvement.
bzr revid: psa@tinyerp.com-20130626104722-jpzcu0gnbbggitv8
-rw-r--r--addons/mail/static/src/js/mail_followers.js8
1 files changed, 5 insertions, 3 deletions
diff --git a/addons/mail/static/src/js/mail_followers.js b/addons/mail/static/src/js/mail_followers.js
index eafbb3ac4e1..b7862564732 100644
--- a/addons/mail/static/src/js/mail_followers.js
+++ b/addons/mail/static/src/js/mail_followers.js
@@ -74,6 +74,7 @@ openerp_mail_followers = function(session, mail) {
this.$el.on('click', '.oe_subtype_list input', self.do_update_subscription);
// event: click on 'invite' button, that opens the invite wizard
this.$('.oe_invite').on('click', self.on_invite_follower);
+ // event: click on 'edit_subtype(pencil)' button to edit subscription
this.$el.on('click', '.oe_edit_subtype', self.on_edit_subtype);
this.$el.on('click', '.oe_remove_follower', self.on_remove_follower);
this.$el.on('click', '.oe_show_more', self.on_show_more_followers)
@@ -81,13 +82,14 @@ openerp_mail_followers = function(session, mail) {
on_edit_subtype: function(event) {
var self = this;
- var user_pid = $(event.target).data('id');
+ var $currentTarget = $(event.currentTarget);
+ var user_pid = $currentTarget.data('id');
$('div.oe_edit_actions').remove();
self.$dialog = new session.web.dialog($('<div class="oe_edit_actions">'), {
modal: true,
width: 'auto',
height: 'auto',
- title: _t('Edit Subscription of ') + $(event.target).siblings('a').text(),
+ title: _t('Edit Subscription of ') + $currentTarget.siblings('a').text(),
buttons: [
{ text: _t("Apply"), click: function() {
self.do_update_subscription(event, user_pid);
@@ -96,7 +98,7 @@ openerp_mail_followers = function(session, mail) {
{ text: _t("Cancel"), click: function() { $(this).dialog("close"); }}
],
});
- return self.fetch_subtypes(user_pid);
+ return self.fetch_subtypes(user_pid);
},
on_invite_follower: function (event) {