mail_group_demo.xml 10 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165
  1. <odoo>
  2. <data>
  3. <!-- Group 1 -->
  4. <record id="mail_group_1" model="mail.group">
  5. <field name="name">My Company News</field>
  6. <field name="alias_name">newsletter</field>
  7. <field name="description">Receive news about "My Company"</field>
  8. <field name="moderation" eval="True"/>
  9. <field name="moderator_ids" eval="[(4, ref('base.user_admin'))]"/>
  10. <field name="access_mode">groups</field>
  11. <field name="access_group_id" ref="base.group_user"/>
  12. </record>
  13. <!-- Members of group 1 -->
  14. <record id="mail_group_member_1" model="mail.group.member">
  15. <field name="partner_id" ref="base.partner_admin"/>
  16. <field name="email">admin@yourcompany.example.com</field>
  17. <field name="mail_group_id" ref="mail_group_1"/>
  18. </record>
  19. <record id="mail_group_member_2" model="mail.group.member">
  20. <field name="partner_id" ref="base.partner_demo"/>
  21. <field name="email">mark.brown23@example.com</field>
  22. <field name="mail_group_id" ref="mail_group_1"/>
  23. </record>
  24. <!-- Attachment of messages -->
  25. <record id="ir_attachment_mail_group_message_1" model="ir.attachment">
  26. <field name="datas">U3VwZXIgc2VjcmV0IGF0dGFjaG1lbnQ=</field>
  27. <field name="name">attachment.txt</field>
  28. </record>
  29. <record id="ir_attachment_mail_group_message_2" model="ir.attachment">
  30. <field name="datas">QnV0IEphdmFzY3JpcHQgc3Vja3M=</field>
  31. <field name="name">attachment.txt</field>
  32. </record>
  33. <!-- Messages of group 1 -->
  34. <record id="mail_group_message_1" model="mail.group.message">
  35. <field name="subject">Important Announce</field>
  36. <field name="body">This weekend, you should all come to our barbecue!</field>
  37. <field name="email_from">mark.brown23@example.com</field>
  38. <field name="author_id" ref="base.partner_demo"/>
  39. <field name="moderation_status">accepted</field>
  40. <field name="group_message_parent_id" eval="False"/>
  41. <field name="mail_group_id" ref="mail_group_1"/>
  42. <field name="attachment_ids" eval="[(4, ref('ir_attachment_mail_group_message_1'))]"/>
  43. </record>
  44. <record id="mail_group_message_1_1" model="mail.group.message">
  45. <field name="subject">Re: Important Announce</field>
  46. <field name="body">Will there be vegetarian food?</field>
  47. <field name="email_from">admin@yourcompany.example.com</field>
  48. <field name="author_id" ref="base.partner_admin"/>
  49. <field name="moderation_status">accepted</field>
  50. <field name="group_message_parent_id" ref="mail_group_message_1"/>
  51. <field name="mail_group_id" ref="mail_group_1"/>
  52. </record>
  53. <record id="mail_group_message_1_1_1" model="mail.group.message">
  54. <field name="subject">Re: Important Announce</field>
  55. <field name="body">Yes of course, and for those who are allergic bring your own food</field>
  56. <field name="email_from">mark.brown23@example.com</field>
  57. <field name="author_id" ref="base.partner_demo"/>
  58. <field name="moderation_status">accepted</field>
  59. <field name="group_message_parent_id" ref="mail_group_message_1_1"/>
  60. <field name="mail_group_id" ref="mail_group_1"/>
  61. </record>
  62. <record id="mail_group_message_1_2" model="mail.group.message">
  63. <field name="subject">Re: Important Announce</field>
  64. <field name="body">Can I come with my dog ?</field>
  65. <field name="email_from">joel.willis63@example.com</field>
  66. <field name="moderation_status">accepted</field>
  67. <field name="group_message_parent_id" ref="mail_group_message_1"/>
  68. <field name="mail_group_id" ref="mail_group_1"/>
  69. </record>
  70. <record id="mail_group_message_1_2_1" model="mail.group.message">
  71. <field name="subject">Re: Important Announce</field>
  72. <field name="body">No animals please.</field>
  73. <field name="email_from">admin@yourcompany.example.com</field>
  74. <field name="author_id" ref="base.partner_admin"/>
  75. <field name="moderation_status">accepted</field>
  76. <field name="group_message_parent_id" ref="mail_group_message_1_2"/>
  77. <field name="mail_group_id" ref="mail_group_1"/>
  78. </record>
  79. <record id="mail_group_message_2" model="mail.group.message">
  80. <field name="subject">Recruitment</field>
  81. <field name="body">We are pleased to announce that we have hired 10 new people this month.</field>
  82. <field name="email_from">admin@yourcompany.example.com</field>
  83. <field name="author_id" ref="base.partner_admin"/>
  84. <field name="moderation_status">accepted</field>
  85. <field name="group_message_parent_id" eval="False"/>
  86. <field name="mail_group_id" ref="mail_group_1"/>
  87. </record>
  88. <record id="mail_group_message_3" model="mail.group.message">
  89. <field name="subject">Relocation</field>
  90. <field name="body">We are moving our office to Brussels. Take back all your remaining stuff.</field>
  91. <field name="email_from">admin@yourcompany.example.com</field>
  92. <field name="author_id" ref="base.partner_admin"/>
  93. <field name="moderation_status">accepted</field>
  94. <field name="group_message_parent_id" eval="False"/>
  95. <field name="mail_group_id" ref="mail_group_1"/>
  96. </record>
  97. <record id="mail_group_message_3_1" model="mail.group.message">
  98. <field name="subject">Re: Relocation</field>
  99. <field name="body">Is there a swimming pool in this new office?</field>
  100. <field name="email_from">joel.willis63@example.com</field>
  101. <field name="moderation_status">accepted</field>
  102. <field name="group_message_parent_id" ref="mail_group_message_3"/>
  103. <field name="mail_group_id" ref="mail_group_1"/>
  104. </record>
  105. <record id="mail_group_message_3_1_1" model="mail.group.message">
  106. <field name="subject">Re: Relocation</field>
  107. <field name="body">Of course!</field>
  108. <field name="email_from">admin@yourcompany.example.com</field>
  109. <field name="author_id" ref="base.partner_admin"/>
  110. <field name="moderation_status">accepted</field>
  111. <field name="group_message_parent_id" ref="mail_group_message_3_1"/>
  112. <field name="mail_group_id" ref="mail_group_1"/>
  113. </record>
  114. <record id="mail_group_message_3_2" model="mail.group.message">
  115. <field name="subject">Re: Relocation</field>
  116. <field name="body">What is the deadline for taking back my stuff?</field>
  117. <field name="email_from">mark.brown23@example.com</field>
  118. <field name="author_id" ref="base.partner_demo"/>
  119. <field name="moderation_status">accepted</field>
  120. <field name="group_message_parent_id" ref="mail_group_message_3"/>
  121. <field name="mail_group_id" ref="mail_group_1"/>
  122. </record>
  123. <record id="mail_group_message_3_2_1" model="mail.group.message">
  124. <field name="subject">Re: Relocation</field>
  125. <field name="body">In 4 weeks.</field>
  126. <field name="email_from">admin@yourcompany.example.com</field>
  127. <field name="author_id" ref="base.partner_admin"/>
  128. <field name="moderation_status">pending_moderation</field>
  129. <field name="group_message_parent_id" ref="mail_group_message_3_2"/>
  130. <field name="mail_group_id" ref="mail_group_1"/>
  131. </record>
  132. <record id="mail_group_message_4" model="mail.group.message">
  133. <field name="subject">I really like CSS &amp; HTML</field>
  134. <field name="body">
  135. &lt;p style=&quot;margin:0px; font-size:13px;&quot;&gt;Hi,&lt;/p&gt;&lt;br&gt; &lt;p style=&quot;margin:0px; font-size:13px;&quot;&gt; We &lt;u style=&quot;font-size:14px&quot;&gt;really&lt;/u&gt; like &lt;font style=&quot;color:rgb(57, 123, 33); font-weight:bolder&quot;&gt;colors&lt;/font&gt; and &lt;span style=&quot;font-weight:bolder&quot;&gt;&lt;font style=&quot;color:rgb(255, 0, 0)&quot;&gt;CSS&lt;/font&gt;&lt;/span&gt;. &lt;/p&gt; &lt;p style=&quot;margin:0px; font-size:13px;&quot;&gt;Do you know you can add &lt;/p&gt; &lt;a href=&quot;https://example.com&quot; target=&quot;_blank&quot; class=&quot;btn btn-primary flat btn-sm&quot;&gt;link in email&lt;/a&gt; ? &lt;ol&gt; &lt;li&gt;Also image&lt;/li&gt; &lt;li&gt;List&lt;/li&gt; &lt;li&gt;Any HTML code in the end...&lt;/li&gt; &lt;/ol&gt;
  136. </field>
  137. <field name="email_from">admin@yourcompany.example.com</field>
  138. <field name="author_id" ref="base.partner_admin"/>
  139. <field name="moderation_status">pending_moderation</field>
  140. <field name="group_message_parent_id" eval="False"/>
  141. <field name="mail_group_id" ref="mail_group_1"/>
  142. <field name="attachment_ids" eval="[(4, ref('ir_attachment_mail_group_message_2'))]"/>
  143. </record>
  144. <!-- Group 2 -->
  145. <record id="mail_group_2" model="mail.group">
  146. <field name="name">Public Mailing List</field>
  147. <field name="alias_name">public_group</field>
  148. <field name="description">Get the patch notes of our amazing product.</field>
  149. <field name="moderation" eval="True"/>
  150. <field name="moderator_ids" eval="[(4, ref('base.user_admin'))]"/>
  151. </record>
  152. <!-- Message of Group 2 -->
  153. <record id="mail_group_message_5" model="mail.group.message">
  154. <field name="subject">Best patch ever</field>
  155. <field name="body">In this patch, we have cleaned the CSS!</field>
  156. <field name="email_from">mark.brown23@example.com</field>
  157. <field name="author_id" ref="base.partner_demo"/>
  158. <field name="moderation_status">accepted</field>
  159. <field name="group_message_parent_id" eval="False"/>
  160. <field name="mail_group_id" ref="mail_group_2"/>
  161. </record>
  162. </data>
  163. </odoo>