hi folks
any simple example to use oe_chatter class in our custom module?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
hi folks
any simple example to use oe_chatter class in our custom module?
Hello Shabeeh,
In PY :-
class custom_class(modules.Model):
_name = 'custom.class'
_inherit = ['mail.thread', 'ir.needaction_mixin']
In Xml:-
<record id="custom_class_form_view" model="ir.ui.view">
<field name="name">custom.class.form.view</field>
<field name="model">custom.class</field>
<field name="arch" type="xml">
<form string="Custom Class">
<sheet>
<!-- Code for Form View -->
</sheet>
<div class="oe_chatter">
<field name="message_follower_ids" widget="mail_followers" groups="base.group_user"/>
<field name="message_ids" widget="mail_thread"/>
</div>
</form>
</field>
</record>
Thanks,
Just Define following code in your form view before </form> tag ending(it must need mail.thread inherited _inherit = ['mail.thread']).
<div class="oe_chatter">
<field name="message_follower_ids" widget="mail_followers" groups="base.group_user"/>
<field name="message_ids" widget="mail_thread"/>
</div>
Thanks,
Pinakin
use class="oe_chatter o_chatter_position_right
/
Create an account today to enjoy exclusive features and engage with our awesome community!
Sign upRelated Posts | Replies | Views | Activity | |
---|---|---|---|---|
|
8
Apr 23
|
32061 | ||
|
0
Mar 15
|
4506 | ||
|
3
Mar 25
|
36289 | ||
|
0
Jun 18
|
2863 | ||
|
2
Mar 16
|
5765 |