odoo/addons/marketing_campaign/data/marketing_campaign_demo.xml

103 lines
4.8 KiB
XML
Raw Normal View History

<?xml version="1.0" encoding="utf-8"?>
<odoo>
<!-- Email tempalte -->
<record id="email_template_1" model="mail.template">
<field name="name">welcome new partner</field>
<field name="email_from">info@openerp.com</field>
<field name="subject">Welcome to the Odoo Partner Channel!</field>
<field name="email_to">${(object.email or '')|safe}</field>
<field name="model_id" ref="base.model_res_partner"/>
<field name="body_html"><![CDATA[
<p>Hello,</p>
<p>You will receive your welcome pack via email shortly.</p>
<p>Thank you,</p>
]]></field>
</record>
<record id="email_template_2" model="mail.template">
<field name="name">congrats silver partner</field>
<field name="email_from">info@openerp.com</field>
<field name="subject">Congratulations! You are now a Silver Partner!</field>
<field name="email_to">${(object.email or '')|safe}</field>
<field name="model_id" ref="base.model_res_partner"/>
<field name="body_html"><![CDATA[
<p>Hello,</p>
<p>We are delighted to welcome you among our Silver Partners as of today!</p>
<p>Thank you,</p>
]]></field>
</record>
<record id="email_template_3" model="mail.template">
<field name="name">congrats gold partner</field>
<field name="email_from">info@openerp.com</field>
<field name="subject">Congratulations! You are now one of our Gold Partners!</field>
<field name="email_to">${(object.email or '')|safe}</field>
<field name="model_id" ref="base.model_res_partner"/>
<field name="body_html"><![CDATA[
<p>Hello,</p>
<p>We are delighted to let you know that you have entered the select circle of our Gold Partners!</p>
<p>Thank you,</p>
]]></field>
</record>
<!-- Campaign -->
<record id="marketing_campaign_openerppartnerchannel" model="marketing.campaign">
<field name="name">Odoo Partner Channel</field>
<field name="object_id" ref="base.model_res_partner"/>
<field name="mode">active</field>
</record>
<!-- Activity -->
<record id="marketing_campaign_activity_0" model="marketing.campaign.activity">
<field name="name">New Partner</field>
<field name="campaign_id" ref="marketing_campaign_openerppartnerchannel"/>
<field name="email_template_id" ref="email_template_1"/>
<field name="condition">object.credit_limit &lt; 10000</field>
<field name="keep_if_condition_not_met">True</field>
<field eval="1" name="start"/>
</record>
<record id="marketing_campaign_activity_1" model="marketing.campaign.activity">
<field name="name">Silver Partner</field>
<field name="campaign_id" ref="marketing_campaign_openerppartnerchannel"/>
<field name="condition">object.credit_limit &gt;= 10000 and object.credit_limit &lt; 50000</field>
<field name="keep_if_condition_not_met">True</field>
<field name="email_template_id" ref="email_template_2"/>
</record>
<record id="marketing_campaign_activity_2" model="marketing.campaign.activity">
<field name="name">Gold Partner</field>
<field name="condition">object.credit_limit &gt;= 100000</field>
<field name="campaign_id" ref="marketing_campaign_openerppartnerchannel"/>
<field name="keep_if_condition_not_met">True</field>
<field name="email_template_id" ref="email_template_3"/>
</record>
<!-- Transition -->
<record id="marketing_campaign_transition_0" model="marketing.campaign.transition">
<field name="activity_from_id" ref="marketing_campaign_activity_0"/>
<field name="activity_to_id" ref="marketing_campaign_activity_1"/>
</record>
<record id="marketing_campaign_transition_1" model="marketing.campaign.transition">
<field name="activity_from_id" ref="marketing_campaign_activity_1"/>
<field name="activity_to_id" ref="marketing_campaign_activity_2"/>
</record>
<!-- Segment -->
<record id="filter0" model="ir.filters">
<field name="name">Partners</field>
<field name="domain">[('name','like','Agrolait')]</field>
<field name="model_id">res.partner</field>
</record>
<record id="marketing_campaign_segment0" model="marketing.campaign.segment">
<field eval="time.strftime('%Y-%m-%d %H:%M:%S')" name="date_run"/>
<field name="name">Odoo Partner</field>
<field name="sync_mode">create_date</field>
<field name="ir_filter_id" ref="filter0"/>
<field name="campaign_id" ref="marketing_campaign_openerppartnerchannel"/>
</record>
</odoo>