Skip to content

Commit

Permalink
Merge pull request #60 from onesteinbv/16.0-website_membership_regist…
Browse files Browse the repository at this point in the history
…ration-changes

Changes to allow searching members and contacts by their name,email,ref,vat,display_name and company_registry through the name filter
  • Loading branch information
ByteMeAsap authored Jul 30, 2024
2 parents fa81c14 + d7c43f3 commit d084f09
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
1 change: 1 addition & 0 deletions membership_activity_gitlab/models/project_project.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

import dateutil
from dateutil.relativedelta import relativedelta

from odoo import api, fields, models


Expand Down
12 changes: 11 additions & 1 deletion website_membership_registration/views/res_partner_view.xml
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,17 @@
<field name="model">res.partner</field>
<field name="arch" type="xml">
<xpath expr="//field[@name='name']" position="attributes">
<attribute name="filter_domain">['|', '|', ('display_name', 'ilike', self), ('parent_id', 'ilike', self), ('ref' , '=', self)]</attribute>
<attribute name="filter_domain">['|', '|', '|', '|', '|',('name', 'ilike', self), ('display_name', 'ilike', self), ('ref', '=', self), ('email', 'ilike', self), ('vat', 'ilike', self), ('company_registry', 'ilike', self)]</attribute>
</xpath>
</field>
</record>

<record id="view_res_partner_filter" model="ir.ui.view">
<field name="inherit_id" ref="base.view_res_partner_filter" />
<field name="model">res.partner</field>
<field name="arch" type="xml">
<xpath expr="//field[@name='name']" position="attributes">
<attribute name="filter_domain">['|', '|', '|', '|', '|',('name', 'ilike', self), ('display_name', 'ilike', self), ('ref', '=', self), ('email', 'ilike', self), ('vat', 'ilike', self), ('company_registry', 'ilike', self)]</attribute>
</xpath>
</field>
</record>
Expand Down

0 comments on commit d084f09

Please sign in to comment.