Move vps notebook to smartbutton
This commit is contained in:
@@ -5,21 +5,15 @@
|
||||
<field name="model">res.partner</field>
|
||||
<field name="inherit_id" ref="base.view_partner_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<xpath expr="//notebook" position="inside">
|
||||
<page string="VPS Servers" attrs="{'invisible': [('is_company', '=', False)]}">
|
||||
<field name="is_company" invisible="1"/>
|
||||
<field name="vps_server_ids" readonly="1">
|
||||
<tree>
|
||||
<field name="name"/>
|
||||
<field name="ip_address"/>
|
||||
<field name="cpu"/>
|
||||
<field name="ram"/>
|
||||
<field name="storage"/>
|
||||
<field name="os"/>
|
||||
</tree>
|
||||
</field>
|
||||
</page>
|
||||
</xpath>
|
||||
<!-- Remove the notebook page if it exists -->
|
||||
<!-- <xpath expr="//page[@name='vps_servers']" position="replace"/> -->
|
||||
|
||||
<!-- Add the smart button -->
|
||||
<div name="button_box" position="inside">
|
||||
<button name="action_view_vps_servers" type="object" class="oe_stat_button" icon="fa-server" attrs="{'invisible': [('vps_server_count', '=', 0)]}">
|
||||
<field name="vps_server_count" widget="statinfo" string="VPS Servers"/>
|
||||
</button>
|
||||
</div>
|
||||
</field>
|
||||
</record>
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user