[IMP] Improved code and removed unwanted code.

bzr revid: psa@tinyerp.com-20130620050026-3kwfmowqfa9f4quz
This commit is contained in:
Paramjit Singh Sahota
2013-06-20 10:30:26 +05:30
parent ae8302a3d6
commit 4180da8a40
2 changed files with 11 additions and 12 deletions
+1 -1
View File
@@ -650,7 +650,7 @@
width: 10px !important;
height: 12px !important;
}
img.hidden {
.openerp .oe_followers .oe_partner img.hidden{
display: none;
}
.openerp.ui-dialog .ui-dialog-titlebar .ui-dialog-title{
+10 -11
View File
@@ -195,14 +195,6 @@ openerp_mail_followers = function(session, mail) {
// clean and display title
var node_user_list = this.$('.oe_follower_list').empty();
this.$('.oe_follower_title').html(this._format_followers(this.followers.length));
// On mouseenter it will show the edit_subtype penil
this.$el.on('mouseenter', 'div.oe_follower_list', function() {
$("img.oe_edit_subtype").removeClass("hidden");
$('div.oe_follower_list').find('.oe_partner').addClass('oe_partner_name');
}).on('mouseleave', 'div.oe_follower_list', function(){
$("img.oe_edit_subtype").addClass("hidden");
$('div.oe_follower_list').find('.oe_partner').removeClass('oe_partner_name');
});
// truncate number of displayed followers
var truncated = this.followers.slice(0, this.displayed_nb);
@@ -211,6 +203,16 @@ openerp_mail_followers = function(session, mail) {
self.check_access = result;
record.avatar_url = mail.ChatterUtils.get_image(self.session, 'res.partner', 'image_small', record.id);
$(session.web.qweb.render('mail.followers.partner', {'record': record, 'widget': self})).appendTo(node_user_list);
// On mouseenter it will show the edit_subtype penil
if (self.check_access == true) {
self.$el.on('mouseenter', 'div.oe_follower_list', function() {
$("img.oe_edit_subtype").removeClass("hidden");
$('div.oe_follower_list').find('.oe_partner').addClass('oe_partner_name');
}).on('mouseleave', 'div.oe_follower_list', function(){
$("img.oe_edit_subtype").addClass("hidden");
$('div.oe_follower_list').find('.oe_partner').removeClass('oe_partner_name');
});
}
})
});
// FVA note: be sure it is correctly translated
@@ -271,9 +273,6 @@ openerp_mail_followers = function(session, mail) {
if (_.size(records) > 1) {
$list.show();
}
if (this.check_access && this.session.debug) {
$('div.oe_follower_list').find('.oe_partner').css('margin-right', '28px');
}
},
do_follow: function () {