<?xml version="1.0" encoding="UTF-8" ?>
<odoo>

    <record id="message_private_rule" model="ir.rule">
        <field name="model_id" ref="mail.model_mail_message"/>
        <field name="name">Message private rules</field>
        <field name="domain_force">['|', '|', ('mail_group_id', '=', False), ('model', '=', False), ('mail_group_id', 'in', user.message_group_ids.ids)]</field>
    </record>


    <record id="attachment_private_rule" model="ir.rule">
        <field name="model_id" ref="base.model_ir_attachment"/>
        <field name="name">Attachment private rules</field>
        <field name="domain_force">['|', '|',  ('mail_group_id', '=', False), ('res_model', '=', False), ('mail_group_id', 'in', user.message_group_ids.ids)]</field>
    </record>
</odoo>
