Commit 7fd786cc by Damien Moulard

Merge branch '6190-CAGETTE-sur-brinks-cacher-le-doublon-user-rattache-non-coop'…

Merge branch '6190-CAGETTE-sur-brinks-cacher-le-doublon-user-rattache-non-coop' into 'dev_cooperatic'

6190 cagette sur brinks cacher le doublon user rattache non coop

See merge request !266
parents 3f1b6284 089df0ea
Pipeline #3384 failed with stage
in 1 minute 6 seconds
...@@ -877,8 +877,13 @@ class CagetteMember(models.Model): ...@@ -877,8 +877,13 @@ class CagetteMember(models.Model):
del partner['parent_name'] del partner['parent_name']
return res return res
elif search_type == "short": #used in brinks. do not show rattaché user (only the member user)
fields = CagetteMember.m_short_default_fields
fields = fields + ['total_partner_owned_share','amount_subscription']
cond.append(['parent_member_num', '=', 0])
res = api.search_read('res.partner', cond, fields)
return res
else: else:
# TODO differentiate short & subscription_data searches
fields = CagetteMember.m_short_default_fields fields = CagetteMember.m_short_default_fields
fields = fields + ['total_partner_owned_share','amount_subscription'] fields = fields + ['total_partner_owned_share','amount_subscription']
res = api.search_read('res.partner', cond, fields) res = api.search_read('res.partner', cond, fields)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment