Browse Source
Merge pull request #60 from coopiteasy/9.0-check-contact-company-emails
[9.0][ADD] emc : company and contact emails must be different
pull/30/head
Houssine BAKKALI
5 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
6 additions and
1 deletions
-
easy_my_coop/controllers/main.py
|
|
@ -223,7 +223,12 @@ class WebsiteSubscription(http.Controller): |
|
|
|
if is_company: |
|
|
|
is_company = True |
|
|
|
redirect = "easy_my_coop.becomecompanycooperator" |
|
|
|
email = kwargs.get('company_email') |
|
|
|
company_email = kwargs.get('company_email') |
|
|
|
if email == company_email: |
|
|
|
values["error_msg"] = _("Cooperator and company emails" |
|
|
|
" should be different.") |
|
|
|
return request.website.render(redirect, values) |
|
|
|
email = company_email |
|
|
|
|
|
|
|
if ('g-recaptcha-response' not in kwargs |
|
|
|
or not request.website.is_captcha_valid( |
|
|
|