74 lines
3.7 KiB
XML
74 lines
3.7 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<odoo>
|
|
<record id="view_project_sync_config_form" model="ir.ui.view">
|
|
<field name="name">project.sync.config.form</field>
|
|
<field name="model">project.sync.config</field>
|
|
<field name="arch" type="xml">
|
|
<form>
|
|
<header>
|
|
<button name="action_fetch_remote_projects" string="Fetch Remote Projects"
|
|
type="object" class="oe_highlight"/>
|
|
<button name="action_sync" string="Sync Selected Projects"
|
|
type="object" class="oe_highlight"
|
|
invisible="not selected_project_ids"/>
|
|
<button name="action_clear_errors" string="Clear All Errors"
|
|
type="object"
|
|
invisible="not selected_project_ids"/>
|
|
</header>
|
|
<sheet>
|
|
<group>
|
|
<field name="name"/>
|
|
<field name="active"/>
|
|
</group>
|
|
<group string="Remote Server Connection">
|
|
<field name="remote_url"/>
|
|
<field name="remote_db"/>
|
|
<field name="remote_user"/>
|
|
<field name="remote_password" password="True"/>
|
|
</group>
|
|
<group string="Sync Settings">
|
|
<field name="sync_direction"/>
|
|
<field name="last_sync"/>
|
|
</group>
|
|
<notebook>
|
|
<page string="Remote Projects (Multi-Select)">
|
|
<field name="remote_project_ids" readonly="1">
|
|
<list>
|
|
<field name="remote_id"/>
|
|
<field name="remote_name"/>
|
|
<field name="sync_status" widget="badge"/>
|
|
</list>
|
|
</field>
|
|
</page>
|
|
<page string="Selected for Sync">
|
|
<field name="selected_project_ids" widget="many2many_tags"
|
|
options="{'no_create': True, 'no_open': True, 'color_field': 'sync_status'}"/>
|
|
<group>
|
|
<p class="text-muted">
|
|
Select projects from the list above, then map them to local projects.
|
|
Click "Sync Selected Projects" to start.
|
|
</p>
|
|
</group>
|
|
</page>
|
|
<page string="Synced Tasks (Local Filter)">
|
|
<p>After syncing, go to <b>Project → Tasks</b> and filter by project to view synced tasks.</p>
|
|
</page>
|
|
</notebook>
|
|
</sheet>
|
|
</form>
|
|
</field>
|
|
</record>
|
|
<record id="action_project_sync_config" model="ir.actions.act_window">
|
|
<field name="name">Project Sync Configurations</field>
|
|
<field name="res_model">project.sync.config</field>
|
|
<field name="view_mode">list,form</field>
|
|
<field name="help" type="html">
|
|
<p class="o_view_nocontent_smiling_face">
|
|
Create a connection to start syncing projects between Odoo instances.
|
|
</p>
|
|
</field>
|
|
</record>
|
|
|
|
<menuitem id="menu_project_sync_root" name="Server Sync" parent="project.menu_project_config" sequence="100"/>
|
|
<menuitem id="menu_project_sync_config" name="Sync Configurations" parent="menu_project_sync_root" action="action_project_sync_config" sequence="10"/>
|
|
</odoo> |