You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
169 lines
9.7 KiB
169 lines
9.7 KiB
<?xml version="1.0" encoding="utf-8"?>
|
|
<odoo>
|
|
<!-- Record for Form view of hubspot.connector -->
|
|
<record id="hubspot_connector_view_form" model="ir.ui.view">
|
|
<field name="name">hubspot.connector.view.form</field>
|
|
<field name="model">hubspot.connector</field>
|
|
<field name="arch" type="xml">
|
|
<form>
|
|
<header>
|
|
<field name="state" widget="statusbar" clickable="1"/>
|
|
</header>
|
|
<sheet>
|
|
<field name="connection" attrs="{'invisible': 1}"/>
|
|
<div name="button_box" position="inside">
|
|
<button class="oe_stat_button" type="object"
|
|
name="action_connect"
|
|
attrs="{'invisible': [('connection', '=', True)]}"
|
|
icon="fa-link" string="CONNECT">
|
|
</button>
|
|
<button class="oe_stat_button" type="object"
|
|
name="action_connect"
|
|
attrs="{'invisible': [('connection', '=', False)]}"
|
|
icon="fa-link" string="CLOSE">
|
|
</button>
|
|
</div>
|
|
<div class="oe_title">
|
|
<label for="name"/>
|
|
<h1>
|
|
<field name="name"
|
|
placeholder="e.g. Hubspot Instance"
|
|
required="1"/>
|
|
</h1>
|
|
</div>
|
|
<group>
|
|
<group string="Authorization" attrs="{'invisible': [('connection', '=', True)]}">
|
|
<field name="owner_id"/>
|
|
<field name="access_key"/>
|
|
</group>
|
|
</group>
|
|
<notebook
|
|
attrs="{'invisible': [('connection', '=', False)]}">
|
|
<page string=" Sync Contacts">
|
|
<group>
|
|
<group>
|
|
<field name="export_contacts"
|
|
widget="boolean_toggle"/>
|
|
<field name="contacts_last_exported"
|
|
attrs="{'invisible': [('export_contacts', '=', False)]}"/>
|
|
<field name="import_contacts"
|
|
widget="boolean_toggle"/>
|
|
<field name="contacts_last_imported"
|
|
attrs="{'invisible': [('import_contacts', '=', False)]}"/>
|
|
<field name="update_odoo_contacts"
|
|
widget="boolean_toggle"/>
|
|
<field style="white-space: pre-wrap;"
|
|
name="odoo_contact_last_updated"
|
|
attrs="{'invisible': [('update_odoo_contacts', '=', False)]}"/>
|
|
<field name="update_hub_contacts"
|
|
widget="boolean_toggle"/>
|
|
<field name="hub_contact_last_updated"
|
|
attrs="{'invisible': [('update_hub_contacts', '=', False)]}"/>
|
|
</group>
|
|
<group>
|
|
<button name="action_contact_sync"
|
|
type="object"
|
|
class="btn btn-outline-dark"
|
|
attrs="{'invisible': [('export_contacts', '=', False),('import_contacts', '=', False),('update_odoo_contacts', '=', False),('update_hub_contacts', '=', False)]}">
|
|
<span style="white-space: nowrap;">
|
|
<span class="fa fa-refresh"/>
|
|
<span> Sync Contacts</span>
|
|
</span>
|
|
</button>
|
|
</group>
|
|
</group>
|
|
</page>
|
|
<page string="Sync Company">
|
|
<group>
|
|
<group>
|
|
<field name="import_company"
|
|
widget="boolean_toggle"/>
|
|
<field name="company_last_imported"
|
|
attrs="{'invisible': [('import_company', '=', False)]}"/>
|
|
<field name="export_company"
|
|
widget="boolean_toggle"/>
|
|
<field name="company_last_exported"
|
|
attrs="{'invisible': [('export_company', '=', False)]}"/>
|
|
|
|
<field name="update_odoo_company"
|
|
widget="boolean_toggle"/>
|
|
<field name="odoo_company_last_updated"
|
|
attrs="{'invisible': [('update_odoo_company', '=', False)]}"/>
|
|
<field name="update_hub_company"
|
|
widget="boolean_toggle"/>
|
|
<field name="hub_company_last_updated"
|
|
attrs="{'invisible': [('update_hub_company', '=', False)]}"/>
|
|
</group>
|
|
<group>
|
|
<button name="action_company_sync"
|
|
type="object"
|
|
class="btn btn-outline-dark"
|
|
attrs="{'invisible': [('export_company', '=', False),('import_company', '=', False),('update_odoo_company', '=', False),('update_hub_company', '=', False)]}">
|
|
<span style="white-space: nowrap;">
|
|
<span class="fa fa-refresh"/>
|
|
<span> Sync Company</span>
|
|
</span>
|
|
</button>
|
|
</group>
|
|
</group>
|
|
</page>
|
|
<page string="Sync Deals">
|
|
<group>
|
|
<group>
|
|
<field name="import_deals"
|
|
widget="boolean_toggle"/>
|
|
<field name="deals_last_imported"
|
|
attrs="{'invisible': [('import_deals', '=', False)]}"/>
|
|
<field name="export_deals"
|
|
widget="boolean_toggle"/>
|
|
<field name="deals_last_exported"
|
|
attrs="{'invisible': [('export_deals', '=', False)]}"/>
|
|
|
|
<field name="update_odoo_deals"
|
|
widget="boolean_toggle"/>
|
|
<field name="odoo_deal_last_updated"
|
|
attrs="{'invisible': [('update_odoo_deals', '=', False)]}"/>
|
|
<field name="update_hub_deals"
|
|
widget="boolean_toggle"/>
|
|
<field name="hub_deal_last_updated"
|
|
attrs="{'invisible': [('update_hub_deals', '=', False)]}"/>
|
|
</group>
|
|
<group>
|
|
<button name="action_deal_sync"
|
|
type="object"
|
|
class="btn btn-outline-dark"
|
|
attrs="{'invisible': [('export_deals', '=', False),('import_deals', '=', False),('update_odoo_deals', '=', False),('update_hub_deals', '=', False)]}">
|
|
<span style="white-space: nowrap;">
|
|
<span class="fa fa-refresh"/>
|
|
<span> Sync Deals</span>
|
|
</span>
|
|
</button>
|
|
</group>
|
|
</group>
|
|
</page>
|
|
</notebook>
|
|
</sheet>
|
|
</form>
|
|
</field>
|
|
</record>
|
|
<!-- Menu action for Hubspot connector -->
|
|
<record id="hubspot_connector_action" model="ir.actions.act_window">
|
|
<field name="name">Hubspot Connector</field>
|
|
<field name="type">ir.actions.act_window</field>
|
|
<field name="res_model">hubspot.connector</field>
|
|
<field name="view_mode">tree,form</field>
|
|
</record>
|
|
<!-- Root Menu -->
|
|
<menuitem id="hubspot_connector_menu_root"
|
|
name="Hubspot Connector"
|
|
web_icon="hubspot_odoo_connector,static/description/icon.png"/>
|
|
<!-- Sub Menus -->
|
|
<menuitem id="hubspot_connector_menu"
|
|
name="HubSpot"
|
|
action="hubspot_connector_action"
|
|
parent="hubspot_connector_menu_root"/>
|
|
<menuitem id="hubspot_sync_history_menu"
|
|
name="Configuration"
|
|
parent="hubspot_connector_menu_root"
|
|
sequence="100"/>
|
|
</odoo>
|
|
|