[FIX] base_contact typo

bzr revid: fp@tinyerp.com-20111228224040-px156w7pf7r0lx2k
This commit is contained in:
Fabien Pinckaers 2011-12-28 23:40:40 +01:00
commit c210a4f927
2 changed files with 5 additions and 3 deletions

View File

@ -169,7 +169,8 @@ class res_partner_address(osv.osv):
_inherit = 'res.partner.address'
def _default_location_id(self, cr, uid, context=None):
context = context or {}
if context is None:
context = {}
if not context.get('default_partner_id',False):
return False
ids = self.pool.get('res.partner.location').search(cr, uid, [('partner_id','=',context['default_partner_id'])], context=context)
@ -242,7 +243,8 @@ class res_partner_address(osv.osv):
}
def default_get(self, cr, uid, fields=[], context=None):
context = context or {}
if context is None:
context = {}
if 'default_type' in context:
del context['default_type']
return super(res_partner_address, self).default_get(cr, uid, fields, context)

View File

@ -91,7 +91,7 @@
<field name="arch" type="xml">
<search string="Partner Contact">
<field name="name" string="First/Lastname"
filter_domain="['|', ('firstname','ilike', self), ('lastname','ilike',self)]"/>
filter_domain="['|', ('first_name','ilike', self), ('last_name', 'ilike', self)]"/>
<field name="partner_id" string="Partner"/>
</search>
</field>