Skip to content

Commit

Permalink
[MERGE] forward port branch 9.0 up to 2917b38
Browse files Browse the repository at this point in the history
  • Loading branch information
KangOl committed Aug 14, 2018
2 parents b41baa3 + 2917b38 commit c0f1471
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 2 additions & 0 deletions addons/crm/models/crm_lead.py
Original file line number Diff line number Diff line change
Expand Up @@ -658,6 +658,8 @@ def get_duplicated_leads(self, partner_id, include_lost=False):
@api.model
def _get_duplicated_leads_by_emails(self, partner_id, email, include_lost=False):
""" Search for opportunities that have the same partner and that arent done or cancelled """
if not email:
return []
partner_match_domain = []
for email in set(email_split(email) + [email]):
partner_match_domain.append(('email_from', '=ilike', email))
Expand Down
5 changes: 4 additions & 1 deletion addons/sale_crm/views/crm_lead_views.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,10 @@
<button string="New Quotation" name="%(sale_action_quotations_new)d" type="action" class="oe_highlight"
context="{'search_default_partner_id': partner_id,
'default_partner_id': partner_id,
'default_team_id': team_id}"/>
'default_team_id': team_id,
'default_campaign_id': campaign_id,
'default_medium_id': medium_id,
'default_source_id': source_id}"/>
</xpath>
<div name="button_box" position="inside">
<button class="oe_stat_button" type="action"
Expand Down

0 comments on commit c0f1471

Please sign in to comment.