Skip to content
This repository has been archived by the owner on Sep 12, 2024. It is now read-only.

Commit

Permalink
Merge pull request #11 from hewanm/17.0-develop
Browse files Browse the repository at this point in the history
removed all unnecessary fields from service provider
  • Loading branch information
shibu-narayanan authored May 31, 2024
2 parents 8083837 + ee1d8d8 commit a0ca59e
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 0 deletions.
1 change: 1 addition & 0 deletions g2p_service_provider_portal_base/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
"views/profile.xml",
"views/other.xml",
"views/menu_view.xml",
"views/service_provider_extend_view.xml",
],
"assets": {
"web.assets_frontend": [],
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
<?xml version="1.0" encoding="UTF-8" ?>
<odoo>

<record id="view_partner_form_custom" model="ir.ui.view">
<field name="name">res.partner.form.custom</field>
<field name="model">res.partner</field>
<field name="inherit_id" ref="base.view_partner_form" />
<field name="arch" type="xml">
<!-- Hide the individual and company radio buttons and company name field -->
<xpath expr="//field[@name='company_type']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>

<!-- Hide Tax, function, title and tags fields -->
<xpath expr="//field[@name='vat']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>
<xpath expr="//field[@name='function']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>
<xpath expr="//field[@name='title']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>
<xpath expr="//field[@name='category_id']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>

<!-- Hide Contacts & addresses, sales & purchase, invoicing, internal notes pages -->
<xpath expr="//page[@name='contact_addresses']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>
<xpath expr="//page[@name='sales_purchases']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>
<xpath expr="//page[@name='accounting']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>
<xpath expr="//page[@name='internal_notes']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>

<!-- hide invoices smart button -->
<xpath expr="//button[@name='action_view_partner_invoices']" position="attributes">
<attribute name="invisible">1</attribute>
</xpath>

</field>
</record>

</odoo>

0 comments on commit a0ca59e

Please sign in to comment.