diff --git a/addons/mail/static/src/components/chatter_topbar/chatter_topbar.xml b/addons/mail/static/src/components/chatter_topbar/chatter_topbar.xml index d1bb0da2c86..094b05b32f5 100644 --- a/addons/mail/static/src/components/chatter_topbar/chatter_topbar.xml +++ b/addons/mail/static/src/components/chatter_topbar/chatter_topbar.xml @@ -62,8 +62,6 @@ diff --git a/addons/mail/static/src/components/follower/follower.js b/addons/mail/static/src/components/follower/follower.js index 123e4772da5..05523b2e38b 100644 --- a/addons/mail/static/src/components/follower/follower.js +++ b/addons/mail/static/src/components/follower/follower.js @@ -5,31 +5,16 @@ import { registerMessagingComponent } from '@mail/utils/messaging_component'; const { Component } = owl; export class Follower extends Component { - - //-------------------------------------------------------------------------- - // Public - //-------------------------------------------------------------------------- - /** - * @returns {Follower} + * @returns {FollowerView} */ - get follower() { - return this.props.follower; + get followerView() { + return this.props.record; } - } Object.assign(Follower, { - defaultProps: { - onClick: () => {}, - }, - props: { - follower: Object, - onClick: { - type: Function, - optional: true, - }, - }, + props: { record: Object }, template: 'mail.Follower', }); diff --git a/addons/mail/static/src/components/follower/follower.xml b/addons/mail/static/src/components/follower/follower.xml index 4f9cf41ca65..f2ba85cebd3 100644 --- a/addons/mail/static/src/components/follower/follower.xml +++ b/addons/mail/static/src/components/follower/follower.xml @@ -2,17 +2,17 @@ - -
- - Avatar - + +
+ + Avatar + - - - diff --git a/addons/mail/static/src/components/follower_list_menu/follower_list_menu.js b/addons/mail/static/src/components/follower_list_menu/follower_list_menu.js index a80a9f67e0f..2093b9e2f4f 100644 --- a/addons/mail/static/src/components/follower_list_menu/follower_list_menu.js +++ b/addons/mail/static/src/components/follower_list_menu/follower_list_menu.js @@ -36,13 +36,6 @@ export class FollowerListMenu extends Component { return this.props.record; } - /** - * @return {Thread} - */ - get thread() { - return this.props.thread; - } - //-------------------------------------------------------------------------- // Handlers //-------------------------------------------------------------------------- @@ -54,7 +47,7 @@ export class FollowerListMenu extends Component { _onClickAddFollowers(ev) { ev.preventDefault(); this.followerListMenuView.hide(); - this.thread.promptAddPartnerFollower(); + this.followerListMenuView.chatterOwner.thread.promptAddPartnerFollower(); } /** @@ -73,14 +66,7 @@ export class FollowerListMenu extends Component { } Object.assign(FollowerListMenu, { - defaultProps: { - isChatterButton: false, - }, - props: { - thread: Object, - isChatterButton: { type: Boolean, optional: true }, - record: Object, - }, + props: { record: Object }, template: 'mail.FollowerListMenu', }); diff --git a/addons/mail/static/src/components/follower_list_menu/follower_list_menu.xml b/addons/mail/static/src/components/follower_list_menu/follower_list_menu.xml index cc8e6b1db75..066f93858b8 100644 --- a/addons/mail/static/src/components/follower_list_menu/follower_list_menu.xml +++ b/addons/mail/static/src/components/follower_list_menu/follower_list_menu.xml @@ -2,33 +2,32 @@ - +
-