<?xml version="1.0"?>
<data><xpath expr="//sheet" position="before">
                    <field name="use_leads" invisible="1"/>
                    <field name="use_opportunities" invisible="1"/>
                    <header>
                        <button name="action_assign_leads" type="object" string="Assign Leads" class="oe_highlight" confirm="This will assign leads to all members. Do you want to proceed?" invisible="not use_leads and not use_opportunities or not assignment_enabled" confirm-label="Assign Leads"/>
                    </header>
                </xpath>
                <xpath expr="//div[@name='options_active']" position="inside">
                    <span name="opportunities" groups="crm.group_use_lead">
                        <field name="use_opportunities"/>
                        <label for="use_opportunities"/>
                    </span>
                    <span name="leads" groups="crm.group_use_lead">
                        <field name="use_leads"/>
                        <label for="use_leads" string="Leads"/>
                    </span>
                </xpath>
                <xpath expr="//field[@name='user_id']" position="after">
                    <label for="alias_name" string="Email Alias" invisible="not use_leads and not use_opportunities"/>
                    <div name="alias_def" invisible="not use_leads and not use_opportunities">
                        <field name="alias_id" string="Email Alias" class="oe_read_only" required="0"/>
                        <div class="oe_edit_only" name="edit_alias" dir="ltr">
                            <field name="alias_name" placeholder="alias" class="oe_inline"/>@
                            <field name="alias_domain_id" class="oe_inline" placeholder="e.g. mycompany.com" options="{'no_create': True, 'no_open': True}"/>
                        </div>
                    </div>
                    <field name="alias_contact" string="Accept Emails From" invisible="not use_leads and not use_opportunities"/>
                </xpath>
                <xpath expr="//group[@name='right']" position="attributes">
                    <attribute name="string">Assignment Rules</attribute>
                    <attribute name="invisible">not assignment_enabled</attribute>
                </xpath>
                <xpath expr="//group[@name='right']" position="inside">
                    <field name="assignment_enabled" invisible="1"/>
                    <field name="assignment_auto_enabled" invisible="1"/>
                    <field name="lead_all_assigned_month_exceeded" invisible="1"/>
                    <div colspan="2">
                        <div class="o_crm_lead_all_assigned_month_exceeded" invisible="not lead_all_assigned_month_exceeded"/>
                        <div class="o_crm_lead_month_assignment text-muted" invisible="not assignment_enabled">
                            <i class="fa fa-info-circle me-2" title="Assigned Lead Count"/>
                            <field name="lead_all_assigned_month_count" class="oe_inline"/><span> leads assigned this month
                            on a maximum of </span><field name="assignment_max" class="oe_inline"/>
                        </div>
                    </div>
                    <field name="assignment_domain" widget="domain" string="Domain" options="{'foldable': True, 'model': 'crm.lead', 'in_dialog': True}" invisible="not assignment_enabled"/>
                    <field name="assignment_optout" invisible="not assignment_auto_enabled"/>
                </xpath>
                <xpath expr="//field[@name='member_ids']" position="attributes">
                    <attribute name="invisible">assignment_enabled</attribute>
                </xpath>
                <xpath expr="//field[@name='crm_team_member_ids']" position="attributes">
                    <attribute name="invisible">not assignment_enabled</attribute>
                </xpath>
            </data>