Browse Source
Merge pull request #731 from OCA/10.0-partner_multi_relation-relation_all-write_multiple
[FIX] make res.partner.relation.all#write work for multiple records
pull/642/merge
Pedro M. Baeza
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
3 additions and
2 deletions
-
partner_multi_relation/models/res_partner_relation_all.py
|
|
@ -386,8 +386,9 @@ CREATE OR REPLACE VIEW %%(table)s AS |
|
|
|
if type_id: |
|
|
|
is_inverse = vals.get('is_inverse') |
|
|
|
type_selection_id = type_id * 2 + (is_inverse and 1 or 0) |
|
|
|
return type_selection_id and self.type_selection_id.browse( |
|
|
|
type_selection_id) or False |
|
|
|
return self.env['res.partner.relation.type.selection'].browse( |
|
|
|
type_selection_id or [] |
|
|
|
) |
|
|
|
|
|
|
|
@api.multi |
|
|
|
def write(self, vals): |
|
|
|