Browse Source

[FIX] company_email doesn't exist on partner

The code has been moved from subscription request and this should have been removed previously when moving the code
pull/9/head
Houssine BAKKALI 6 years ago
committed by GitHub
parent
commit
3330df2f91
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      easy_my_coop/models/account_invoice.py

2
easy_my_coop/models/account_invoice.py

@ -24,8 +24,6 @@ class account_invoice(models.Model):
def create_user(self, partner): def create_user(self, partner):
user_obj = self.env['res.users'] user_obj = self.env['res.users']
email = partner.email email = partner.email
if partner.is_company:
email = partner.company_email
user = user_obj.search([('login', '=', email)]) user = user_obj.search([('login', '=', email)])
if not user: if not user:

Loading…
Cancel
Save