Browse Source

[REFACT] for legal reason we remove the niss number to email instead

pull/12/head
houssine 5 years ago
parent
commit
34a9960a36
  1. 4
      easy_my_coop/__manifest__.py
  2. 35
      easy_my_coop/models/belgian_identification_id_generator.py
  3. 34
      easy_my_coop/models/company.py
  4. 92
      easy_my_coop/models/coop.py
  5. 19
      easy_my_coop/models/partner.py
  6. 2
      easy_my_coop/views/operation_request_view.xml
  7. 6
      easy_my_coop/views/res_company_view.xml
  8. 1
      easy_my_coop/views/res_partner_view.xml
  9. 1
      easy_my_coop/views/subscription_request_view.xml
  10. 42
      easy_my_coop/wizard/create_subscription_from_partner.py
  11. 2
      easy_my_coop/wizard/create_subscription_from_partner.xml
  12. 2
      easy_my_coop/wizard/update_partner_info.py
  13. 1
      easy_my_coop_be/__init__.py
  14. 2
      easy_my_coop_be/models/__init__.py
  15. 10
      easy_my_coop_be/models/coop.py
  16. 10
      easy_my_coop_be/models/partner.py
  17. 2
      easy_my_coop_ch/__manifest__.py
  18. 1
      easy_my_coop_ch/models/__init__.py
  19. 34
      easy_my_coop_ch/models/coop.py
  20. 16
      easy_my_coop_ch/models/partner.py
  21. 13
      easy_my_coop_ch/views/subscription_request_view.xml
  22. 18
      easy_my_coop_ch/views/subscription_template.xml
  23. 6
      easy_my_coop_export_xlsx/wizard/export_global_wizard.py
  24. 3
      easy_my_coop_fr/__manifest__.py
  25. 1
      easy_my_coop_fr/models/__init__.py
  26. 13
      easy_my_coop_fr/models/coop.py
  27. 12
      easy_my_coop_fr/models/partner.py
  28. 2
      easy_my_coop_fr/views/subscription_template.xml
  29. 66
      easy_my_coop_website/controllers/main.py
  30. 200
      easy_my_coop_website/views/subscription_template.xml
  31. 4
      easy_my_coop_website_portal/views/easy_my_coop_website_portal_templates.xml

4
easy_my_coop/__manifest__.py

@ -1,11 +1,11 @@
# Copyright 2013-2018 Open Architects Consulting SPRL. # Copyright 2013-2018 Open Architects Consulting SPRL.
# Copyright 2018- Coop IT Easy SCRLfs (<http://www.coopiteasy.be>)
# Copyright 2018 Coop IT Easy SCRLfs (<http://www.coopiteasy.be>)
# - Houssine BAKKALI - <houssine@coopiteasy.be> # - Houssine BAKKALI - <houssine@coopiteasy.be>
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).
{ {
"name": "Easy My Coop", "name": "Easy My Coop",
"version": "12.0.1.0.1",
"version": "12.0.2.0.1",
"depends": [ "depends": [
"base", "base",
"sale", "sale",

35
easy_my_coop/models/belgian_identification_id_generator.py

@ -1,35 +0,0 @@
from random import randrange, randint
from datetime import date, timedelta
def random_date(start, end):
delta = end - start
return start + timedelta(seconds=randrange(delta.total_seconds()))
def generate_identification_id(start_date, end_date):
birthday = random_date(start_date, end_date)
year = str(birthday.year)[2:]
month = str(birthday.month).zfill(2)
day = str(birthday.day).zfill(2)
gender = str(randint(1, 998)).zfill(3)
millenium_baby = birthday.year > 2000
main_number = year + month + day + gender
control_number = '2' + main_number if millenium_baby else main_number
control_number = 97 - int(control_number) % 97
control_number = str(control_number).zfill(2)
return main_number + control_number
def identification_id_to_gender(identification_id):
if identification_id and len(identification_id) == 11:
gender = identification_id[6:9]
return int(gender) % 2
INDENTITY_ID = generate_identification_id(date(1920, 1, 1), date(1995, 12, 31))
GENDER = identification_id_to_gender(INDENTITY_ID)
print('Rijksregisternummer: ' + INDENTITY_ID)
print('Geslacht: ' + ('Man' if GENDER else 'Vrouw'))

34
easy_my_coop/models/company.py

@ -1,4 +1,4 @@
from odoo import fields, models
from odoo import api, fields, models
class ResCompany(models.Model): class ResCompany(models.Model):
@ -43,3 +43,35 @@ class ResCompany(models.Model):
bottom_logo2 = fields.Binary(string="Bottom logo 2") bottom_logo2 = fields.Binary(string="Bottom logo 2")
logo_url = fields.Char(string="logo url", logo_url = fields.Char(string="logo url",
compute="_get_base_logo") compute="_get_base_logo")
display_data_policy_approval = fields.Boolean(
help="Choose to display a data policy checkbox on the cooperator"
" website form."
)
data_policy_approval_required = fields.Boolean(
string="Is data policy approval required?"
)
data_policy_approval_text = fields.Html(
translate=True,
help="Text to display aside the checkbox to approve data policy."
)
display_internal_rules_approval = fields.Boolean(
help="Choose to display an internal rules checkbox on the"
" cooperator website form."
)
internal_rules_approval_required = fields.Boolean(
string="Is internal rules approval required?"
)
internal_rules_approval_text = fields.Html(
translate=True,
help="Text to display aside the checkbox to approve internal rules."
)
@api.onchange('data_policy_approval_required')
def onchange_data_policy_approval_required(self):
if self.data_policy_approval_required:
self.display_data_policy_approval = True
@api.onchange('internal_rules_approval_required')
def onchange_internal_rules_approval_required(self):
if self.internal_rules_approval_required:
self.display_internal_rules_approval = True

92
easy_my_coop/models/coop.py

@ -15,7 +15,7 @@ _REQUIRED = ['email',
'city', 'city',
'iban', 'iban',
'no_registre', 'no_registre',
'gender'] # Could be improved including required from model
'gender']
@api.model @api.model
@ -29,10 +29,16 @@ class SubscriptionRequest(models.Model):
_description = 'Subscription Request' _description = 'Subscription Request'
def get_required_field(self): def get_required_field(self):
return _REQUIRED
required_fields = _REQUIRED
company = self.env['res.company']._company_default_get()
if company.data_policy_approval_required:
required_fields.append('data_policy_approved')
if company.internal_rules_approval_required:
required_fields.append('internal_rules_approved')
return required_fields
def get_mail_template_notif(self): def get_mail_template_notif(self):
return'easy_my_coop.email_template_confirmation'
return 'easy_my_coop.email_template_confirmation'
def is_member(self, vals, cooperator): def is_member(self, vals, cooperator):
if cooperator.member: if cooperator.member:
@ -47,12 +53,12 @@ class SubscriptionRequest(models.Model):
if not vals.get('partner_id'): if not vals.get('partner_id'):
cooperator = False cooperator = False
if vals.get('no_registre'):
cooperator = partner_obj.get_cooperator_from_nin(
vals.get('no_registre'))
if vals.get('email'):
cooperator = partner_obj.get_cooperator_from_email(
vals.get('email'))
if cooperator: if cooperator:
# TODO remove the following line of code once it has # TODO remove the following line of code once it has
# been found a way to avoid dubble encoding
# been found a way to avoid double encoding
cooperator = cooperator[0] cooperator = cooperator[0]
vals['type'] = 'subscription' vals['type'] = 'subscription'
@ -90,22 +96,6 @@ class SubscriptionRequest(models.Model):
return subscr_request return subscr_request
def check_belgian_identification_id(self, nat_register_num):
if not self.check_empty_string(nat_register_num):
return False
if len(nat_register_num) != 11:
return False
if not nat_register_num.isdigit():
return False
birthday_number = nat_register_num[0:9]
controle = nat_register_num[9:11]
check_controle = 97 - (int(birthday_number) % 97)
if int(check_controle) != int(controle):
check_controle = 97 - ((2000000000 + int(birthday_number)) % 97)
if int(check_controle) != int(controle):
return False
return True
def check_empty_string(self, value): def check_empty_string(self, value):
if value is None or value is False or value == '': if value is None or value is False or value == '':
return False return False
@ -120,17 +110,10 @@ class SubscriptionRequest(models.Model):
return validated return validated
@api.multi @api.multi
@api.depends('iban', 'no_registre', 'skip_control_ng', 'is_company')
@api.depends('iban', 'skip_control_ng', 'is_company')
def _validated_lines(self): def _validated_lines(self):
for sub_request in self: for sub_request in self:
validated = self.check_iban(sub_request.iban) validated = self.check_iban(sub_request.iban)
if validated and (sub_request.skip_control_ng or
self.check_belgian_identification_id(
sub_request.no_registre)):
validated = True
else:
validated = False
sub_request.validated = validated sub_request.validated = validated
@api.multi @api.multi
@ -235,9 +218,6 @@ class SubscriptionRequest(models.Model):
phone = fields.Char(string='Phone', phone = fields.Char(string='Phone',
readonly=True, readonly=True,
states={'draft': [('readonly', False)]}) states={'draft': [('readonly', False)]})
no_registre = fields.Char(string='National Register Number',
readonly=True,
states={'draft': [('readonly', False)]})
user_id = fields.Many2one('res.users', user_id = fields.Many2one('res.users',
string='Responsible', string='Responsible',
readonly=True) readonly=True)
@ -284,11 +264,7 @@ class SubscriptionRequest(models.Model):
company_register_number = fields.Char(string='Company register number', company_register_number = fields.Char(string='Company register number',
readonly=True, readonly=True,
states={'draft': [('readonly', False)]}) states={'draft': [('readonly', False)]})
company_type = fields.Selection([('scrl', 'SCRL'),
('asbl', 'ASBL'),
('sprl', 'SPRL'),
('sa', 'SA'),
('other', 'Other')],
company_type = fields.Selection([('', '')],
string="Company type", string="Company type",
readonly=True, readonly=True,
states={'draft': [('readonly', False)]}) states={'draft': [('readonly', False)]})
@ -336,13 +312,20 @@ class SubscriptionRequest(models.Model):
default="website", default="website",
readonly=True, readonly=True,
states={'draft': [('readonly', False)]}) states={'draft': [('readonly', False)]})
data_policy_approved = fields.Boolean(
string='Data Policy Approved',
default=False,
)
internal_rules_approved = fields.Boolean(
string='Approved Internal Rules',
default=False,
)
_order = "id desc" _order = "id desc"
def get_person_info(self, partner): def get_person_info(self, partner):
self.firstname = partner.firstname self.firstname = partner.firstname
self.name = partner.name self.name = partner.name
self.lastname = partner.lastname self.lastname = partner.lastname
self.no_registre = partner.national_register_number
self.email = partner.email self.email = partner.email
self.birthdate = partner.birthdate_date self.birthdate = partner.birthdate_date
self.gender = partner.gender self.gender = partner.gender
@ -401,11 +384,11 @@ class SubscriptionRequest(models.Model):
return res return res
def send_capital_release_request(self, invoice): def send_capital_release_request(self, invoice):
invoice_email_template = self.env['mail.template'].search([('name', '=', 'Request to Release Capital - Send by Email')])[0]
email_template = self.env.ref('email_template_release_capital', False)
# we send the email with the capital release request in attachment # we send the email with the capital release request in attachment
# TODO remove sudo() and give necessary access right # TODO remove sudo() and give necessary access right
invoice_email_template.sudo().send_mail(invoice.id, True)
email_template.sudo().send_mail(invoice.id, True)
invoice.sent = True invoice.sent = True
def get_journal(self): def get_journal(self):
@ -459,7 +442,10 @@ class SubscriptionRequest(models.Model):
'customer': self.share_product_id.customer, 'customer': self.share_product_id.customer,
'out_inv_comm_algorithm': 'random', 'out_inv_comm_algorithm': 'random',
'country_id': self.country_id.id, 'country_id': self.country_id.id,
'lang': self.lang}
'lang': self.lang,
'data_policy_approved': self.data_policy_approved,
'internal_rules_approved': self.internal_rules_approved
}
return partner_vals return partner_vals
def get_partner_vals(self): def get_partner_vals(self):
@ -468,12 +454,14 @@ class SubscriptionRequest(models.Model):
'zip': self.zip_code, 'email': self.email, 'zip': self.zip_code, 'email': self.email,
'gender': self.gender, 'cooperator': True, 'gender': self.gender, 'cooperator': True,
'city': self.city, 'phone': self.phone, 'city': self.city, 'phone': self.phone,
'national_register_number': self.no_registre,
'out_inv_comm_type': 'bba', 'out_inv_comm_type': 'bba',
'out_inv_comm_algorithm': 'random', 'out_inv_comm_algorithm': 'random',
'country_id': self.country_id.id, 'lang': self.lang, 'country_id': self.country_id.id, 'lang': self.lang,
'birthdate_date': self.birthdate, 'birthdate_date': self.birthdate,
'customer': self.share_product_id.customer}
'customer': self.share_product_id.customer,
'data_policy_approved': self.data_policy_approved,
'internal_rules_approved': self.internal_rules_approved
}
return partner_vals return partner_vals
def create_coop_partner(self): def create_coop_partner(self):
@ -514,8 +502,8 @@ class SubscriptionRequest(models.Model):
' checked please select a cooperator.')) ' checked please select a cooperator.'))
elif self.is_company and self.company_register_number: elif self.is_company and self.company_register_number:
domain = [('company_register_number', '=', self.company_register_number)] #noqa domain = [('company_register_number', '=', self.company_register_number)] #noqa
elif not self.is_company and self.no_registre:
domain = [('national_register_number', '=', self.no_registre)]
elif not self.is_company and self.email:
domain = [('email', '=', self.email)]
if domain: if domain:
partner = partner_obj.search(domain) partner = partner_obj.search(domain)
@ -527,8 +515,8 @@ class SubscriptionRequest(models.Model):
if self.is_company and not partner.has_representative(): if self.is_company and not partner.has_representative():
contact = False contact = False
if self.no_registre:
domain = [('national_register_number', '=', self.no_registre)]
if self.email:
domain = [('email', '=', self.email)]
contact = partner_obj.search(domain) contact = partner_obj.search(domain)
if contact: if contact:
contact.type = 'representative' contact.type = 'representative'
@ -540,7 +528,6 @@ class SubscriptionRequest(models.Model):
'street': self.address, 'gender': self.gender, 'street': self.address, 'gender': self.gender,
'zip': self.zip_code, 'city': self.city, 'zip': self.zip_code, 'city': self.city,
'phone': self.phone, 'email': self.email, 'phone': self.phone, 'email': self.email,
'national_register_number': self.no_registre,
'country_id': self.country_id.id, 'country_id': self.country_id.id,
'out_inv_comm_type': 'bba', 'out_inv_comm_type': 'bba',
'out_inv_comm_algorithm': 'random', 'out_inv_comm_algorithm': 'random',
@ -549,7 +536,10 @@ class SubscriptionRequest(models.Model):
'parent_id': partner.id, 'parent_id': partner.id,
'representative': True, 'representative': True,
'function': self.contact_person_function, 'function': self.contact_person_function,
'type': 'representative'}
'type': 'representative',
'data_policy_approved': self.data_policy_approved,
'internal_rules_approved': self.internal_rules_approved
}
contact = partner_obj.create(contact_vals) contact = partner_obj.create(contact_vals)
else: else:
if len(contact) > 1: if len(contact) > 1:

19
easy_my_coop/models/partner.py

@ -4,17 +4,6 @@ from odoo import api, fields, models
class ResPartner(models.Model): class ResPartner(models.Model):
_inherit = 'res.partner' _inherit = 'res.partner'
# def _auto_init(self, cr, context=None):
# """
# Convert the column birthdate into date if it's not the case to avoid warning and data loss with orm conversion
# """
# cr.execute("select data_type from information_schema.columns where table_name = 'res_partner' and column_name= 'birthdate';")
# res = cr.fetchone()
# if not 'date' in res:
# cr.execute("ALTER TABLE res_partner ALTER COLUMN birthdate TYPE date USING birthdate::date;")
#
# return super(ResPartner, self)._auto_init(cr, context=context)
@api.multi @api.multi
def _invoice_total(self): def _invoice_total(self):
account_invoice_report = self.env['account.invoice.report'] account_invoice_report = self.env['account.invoice.report']
@ -138,6 +127,10 @@ class ResPartner(models.Model):
subscription_request_ids = fields.One2many('subscription.request', subscription_request_ids = fields.One2many('subscription.request',
'partner_id', 'partner_id',
string="Subscription request") string="Subscription request")
legal_form = fields.Selection([('', '')],
string="Legal form")
data_policy_approved = fields.Boolean(string="Approved Data Policy")
internal_rules_approved = fields.Boolean(string="Approved Internal Rules")
@api.multi @api.multi
@api.depends('subscription_request_ids.state') @api.depends('subscription_request_ids.state')
@ -161,9 +154,9 @@ class ResPartner(models.Model):
def get_representative(self): def get_representative(self):
return self.child_ids.filtered('representative') return self.child_ids.filtered('representative')
def get_cooperator_from_nin(self, national_id_number):
def get_cooperator_from_email(self, email):
return self.search([('cooperator', '=', True), return self.search([('cooperator', '=', True),
('national_register_number', '=', national_id_number)])
('email', '=', email)])
def get_cooperator_from_crn(self, company_register_number): def get_cooperator_from_crn(self, company_register_number):
return self.search([('cooperator', '=', True), return self.search([('cooperator', '=', True),

2
easy_my_coop/views/operation_request_view.xml

@ -53,7 +53,6 @@
<field name="subscription_request" attrs="{'invisible':['|',('operation_type','!=','transfer'),('receiver_not_member','=',False)]}" context="{'default_is_operation': True, 'default_ordered_parts':quantity,'default_share_product_id': share_product_id, 'default_source':'operation'}"> <field name="subscription_request" attrs="{'invisible':['|',('operation_type','!=','transfer'),('receiver_not_member','=',False)]}" context="{'default_is_operation': True, 'default_ordered_parts':quantity,'default_share_product_id': share_product_id, 'default_source':'operation'}">
<tree> <tree>
<field name="name"/> <field name="name"/>
<field name="no_registre"/>
<field name="birthdate"/> <field name="birthdate"/>
<field name="phone"/> <field name="phone"/>
<field name="email"/> <field name="email"/>
@ -71,7 +70,6 @@
<field name="gender"/> <field name="gender"/>
<field name="email"/> <field name="email"/>
<field name="phone"/> <field name="phone"/>
<field name="no_registre"/>
<field name="iban"/> <field name="iban"/>
</group> </group>
<group> <group>

6
easy_my_coop/views/res_company_view.xml

@ -20,6 +20,12 @@
<field name="default_lang_id"/> <field name="default_lang_id"/>
<field name="board_representative"/> <field name="board_representative"/>
<field name="signature_scan"/> <field name="signature_scan"/>
<field name="display_data_policy_approval"/>
<field name="data_policy_approval_required"/>
<field name="data_policy_approval_text"/>
<field name="display_internal_rules_approval"/>
<field name="internal_rules_approval_required"/>
<field name="internal_rules_approval_text"/>
</group> </group>
</group> </group>
</field> </field>

1
easy_my_coop/views/res_partner_view.xml

@ -21,7 +21,6 @@
<field name="representative" attrs="{'invisible':['|',('parent_id','=',False),('is_company','=',True)]}"/> <field name="representative" attrs="{'invisible':['|',('parent_id','=',False),('is_company','=',True)]}"/>
<field name="cooperator_register_number" readonly="True" attrs="{'invisible':[('member','=',False)]}"/> <field name="cooperator_register_number" readonly="True" attrs="{'invisible':[('member','=',False)]}"/>
<field name="company_register_number" readonly="True" attrs="{'invisible':[('is_company','=',False)]}"/> <field name="company_register_number" readonly="True" attrs="{'invisible':[('is_company','=',False)]}"/>
<field name="national_register_number" readonly="True" attrs="{'invisible':[('is_company','=',True)]}" groups="easy_my_coop.group_easy_my_coop_manager"/>
<field name="coop_candidate" groups="easy_my_coop.group_easy_my_coop_user"/> <field name="coop_candidate" groups="easy_my_coop.group_easy_my_coop_user"/>
<field name="cooperator" invisible="True" groups="easy_my_coop.group_easy_my_coop_super_manager"/> <field name="cooperator" invisible="True" groups="easy_my_coop.group_easy_my_coop_super_manager"/>
<field name="member" groups="easy_my_coop.group_easy_my_coop_super_manager"/> <field name="member" groups="easy_my_coop.group_easy_my_coop_super_manager"/>

1
easy_my_coop/views/subscription_request_view.xml

@ -57,7 +57,6 @@
<field name="email"/> <field name="email"/>
<field name="phone"/> <field name="phone"/>
<field name="contact_person_function" attrs="{'invisible':[('is_company','=',False)]}"/> <field name="contact_person_function" attrs="{'invisible':[('is_company','=',False)]}"/>
<field name="no_registre"/>
<field name="iban"/> <field name="iban"/>
<field name="address"/> <field name="address"/>
<field name="zip_code"/> <field name="zip_code"/>

42
easy_my_coop/wizard/create_subscription_from_partner.py

@ -29,15 +29,15 @@ class PartnerCreateSubscription(models.TransientModel):
def _get_representative(self): def _get_representative(self):
partner = self._get_partner() partner = self._get_partner()
if partner.is_company: if partner.is_company:
return self.env['res.partner'].search([('parent_id', '=', partner.id),
('representative', '=', True)])
return partner.search([('parent_id', '=', partner.id),
('representative', '=', True)])
return False return False
@api.model @api.model
def _get_representative_number(self):
def _get_representative_email(self):
representative = self._get_representative() representative = self._get_representative()
if representative: if representative:
return representative.national_register_number
return representative.email
return False return False
@api.model @api.model
@ -58,16 +58,13 @@ class PartnerCreateSubscription(models.TransientModel):
@api.model @api.model
def _get_email(self): def _get_email(self):
partner = self._get_partner()
return partner.email
return self._get_partner().email
@api.model @api.model
def _get_register_number(self): def _get_register_number(self):
partner = self._get_partner() partner = self._get_partner()
if partner.is_company: if partner.is_company:
return partner.company_register_number return partner.company_register_number
else:
return partner.national_register_number
@api.model @api.model
def _get_bank_account(self): def _get_bank_account(self):
@ -100,7 +97,7 @@ class PartnerCreateSubscription(models.TransientModel):
cooperator = fields.Many2one('res.partner', cooperator = fields.Many2one('res.partner',
string="Cooperator", string="Cooperator",
default=_get_partner) default=_get_partner)
register_number = fields.Char(string="Register Number",
register_number = fields.Char(string="Register Company Number",
required=True, required=True,
default=_get_register_number) default=_get_register_number)
email = fields.Char(string="Email", email = fields.Char(string="Email",
@ -125,16 +122,8 @@ class PartnerCreateSubscription(models.TransientModel):
readonly=True) readonly=True)
representative_name = fields.Char(string='Representative name', representative_name = fields.Char(string='Representative name',
default=_get_representative_name) default=_get_representative_name)
representative_number = fields.Char(string='Representative national '
'register number',
default=_get_representative_number)
def check_belgian_ident_id(self, register_number):
sub_req = self.env['subscription.request']
if sub_req.check_belgian_identification_id(register_number):
return True
else:
raise UserError(_("The national register number is not valid."))
representative_email = fields.Char(string='Representative email',
default=_get_representative_email)
@api.multi @api.multi
def create_subscription(self): def create_subscription(self):
@ -162,7 +151,6 @@ class PartnerCreateSubscription(models.TransientModel):
vals['is_company'] = True vals['is_company'] = True
else: else:
vals['name'] = cooperator.name vals['name'] = cooperator.name
vals['no_registre'] = self.register_number
coop_vals = {} coop_vals = {}
if not self._get_email(): if not self._get_email():
@ -171,15 +159,12 @@ class PartnerCreateSubscription(models.TransientModel):
if not self._get_register_number(): if not self._get_register_number():
if self.is_company: if self.is_company:
coop_vals['company_register_number'] = self.register_number coop_vals['company_register_number'] = self.register_number
else:
if self.check_belgian_ident_id(self.register_number):
coop_vals['national_register_number'] = self.register_number
if self.is_company and not self._get_representative(): if self.is_company and not self._get_representative():
representative = False representative = False
if self.representative_number:
representative_number = self.representative_number
representative = partner_obj.search([('national_register_number', '=', representative_number)])
if self.representative_email:
representative = partner_obj.search(
[('email', '=', self.representative_email)])
if representative: if representative:
if len(representative) > 1: if len(representative) > 1:
@ -192,10 +177,10 @@ class PartnerCreateSubscription(models.TransientModel):
"two different companies.")) "two different companies."))
representative.parent_id = cooperator.id representative.parent_id = cooperator.id
else: else:
if self.check_belgian_ident_id(representative_number):
if self.representative_email:
represent_vals = {'name': self.representative_name, represent_vals = {'name': self.representative_name,
'cooperator': True, 'cooperator': True,
'national_register_number': representative_number,
'email': self.representative_email,
'parent_id': cooperator.id, 'parent_id': cooperator.id,
'representative': True} 'representative': True}
partner_obj.create(represent_vals) partner_obj.create(represent_vals)
@ -208,7 +193,6 @@ class PartnerCreateSubscription(models.TransientModel):
if self.is_company: if self.is_company:
representative = self._get_representative() representative = self._get_representative()
vals['name'] = representative.name vals['name'] = representative.name
vals['no_registre'] = representative.national_register_number
if coop_vals: if coop_vals:
cooperator.write(coop_vals) cooperator.write(coop_vals)

2
easy_my_coop/wizard/create_subscription_from_partner.xml

@ -13,7 +13,7 @@
<field name="is_company" invisible="True"/> <field name="is_company" invisible="True"/>
<field name="cooperator" invisible="True"/> <field name="cooperator" invisible="True"/>
<field name="representative_name" attrs="{'invisible':[('is_company','=',False)],'required':[('is_company','=',True)]}"/> <field name="representative_name" attrs="{'invisible':[('is_company','=',False)],'required':[('is_company','=',True)]}"/>
<field name="representative_number" attrs="{'invisible':[('is_company','=',False)],'required':[('is_company','=',True)]}"/>
<field name="representative_email" attrs="{'invisible':[('is_company','=',False)],'required':[('is_company','=',True)]}"/>
<field name="email"/> <field name="email"/>
<field name="register_number"/> <field name="register_number"/>
<field name="bank_account"/> <field name="bank_account"/>

2
easy_my_coop/wizard/update_partner_info.py

@ -16,7 +16,7 @@ class PartnerUpdateInfo(models.TransientModel):
if partner.is_company: if partner.is_company:
return partner.company_register_number return partner.company_register_number
register_number = fields.Char(string="Register Number",
register_number = fields.Char(string="Register Company Number",
required=True, required=True,
default=_get_register_number) default=_get_register_number)
cooperator = fields.Many2one('res.partner', cooperator = fields.Many2one('res.partner',

1
easy_my_coop_be/__init__.py

@ -0,0 +1 @@
from . import models

2
easy_my_coop_be/models/__init__.py

@ -0,0 +1,2 @@
from . import coop
from . import partner

10
easy_my_coop_be/models/coop.py

@ -0,0 +1,10 @@
from odoo import fields, models
class SubscriptionRequest(models.Model):
_inherit = 'subscription.request'
company_type = fields.Selection([('scrl', 'SCRL'),
('asbl', 'ASBL'),
('sprl', 'SPRL'),
('sa', 'SA')])

10
easy_my_coop_be/models/partner.py

@ -0,0 +1,10 @@
from odoo import fields, models
class ResPartner(models.Model):
_inherit = 'res.partner'
legal_form = fields.Selection(selection_add=[('scrl', 'SCRL'),
('asbl', 'ASBL'),
('sprl', 'SPRL'),
('sa', 'SA')])

2
easy_my_coop_ch/__manifest__.py

@ -20,7 +20,7 @@
############################################################################## ##############################################################################
{ {
"name": "Easy My Coop CH", "name": "Easy My Coop CH",
"version": "1.0",
"version": "12.0.1.0.2",
"depends": ["easy_my_coop", "depends": ["easy_my_coop",
"l10n_ch"], "l10n_ch"],
"author": "Houssine BAKKALI <houssine@coopiteasy.be>", "author": "Houssine BAKKALI <houssine@coopiteasy.be>",

1
easy_my_coop_ch/models/__init__.py

@ -1 +1,2 @@
from . import coop from . import coop
from . import partner

34
easy_my_coop_ch/models/coop.py

@ -1,31 +1,27 @@
# -*- coding: utf-8 -*-
from openerp import fields, models
from odoo import fields, models
class subscription_request(models.Model):
class SubscriptionRequest(models.Model):
_inherit = 'subscription.request' _inherit = 'subscription.request'
company_type = fields.Selection([('ei', 'Individual company'),
('snc', 'Partnership'),
('sa', 'Limited company (SA)'),
('sarl', 'Limited liability company (Ltd)'), #noqa
('sc', 'Cooperative'),
('asso', 'Association'),
('fond', 'Foundation'),
('edp', 'Company under public law')])
company_type = fields.Selection(selection_add=[
('ei', 'Individual company'),
('snc', 'Partnership'),
('sa', 'Limited company (SA)'),
('sarl', 'Limited liability company (Ltd)'), #noqa
('sc', 'Cooperative'),
('asso', 'Association'),
('fond', 'Foundation'),
('edp', 'Company under public law')])
def get_required_field(self): def get_required_field(self):
req_fields = super(subscription_request, self).get_required_field()
if 'no_registre' in req_fields:
req_fields.remove('no_registre')
req_fields = super(SubscriptionRequest, self).get_required_field()
if 'iban' in req_fields:
req_fields.remove('iban')
return req_fields return req_fields
def check_belgian_identification_id(self, nat_register_num):
# deactivate number validation for swiss localization
return True
def check_iban(self, iban): def check_iban(self, iban):
if iban: if iban:
return super(subscription_request, self).check_iban(iban)
return super(SubscriptionRequest, self).check_iban(iban)
return True return True

16
easy_my_coop_ch/models/partner.py

@ -0,0 +1,16 @@
from odoo import fields, models
class ResPartner(models.Model):
_inherit = 'res.partner'
legal_form = fields.Selection(selection_add=[
('ei', 'Individual company'),
('snc', 'Partnership'),
('sa', 'Limited company (SA)'),
('sarl', 'Limited liability company (Ltd)'),
('sc', 'Cooperative'),
('asso', 'Association'),
('fond', 'Foundation'),
('edp', 'Company under public law')
])

13
easy_my_coop_ch/views/subscription_request_view.xml

@ -1,13 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<data>
<record id="subscription_request_form" model="ir.ui.view">
<field name="name">subscription.request.form</field>
<field name="model">subscription.request</field>
<field name="inherit_id" ref="easy_my_coop.subscription_request_form"/>
<field name="arch" type="xml">
<field name="no_registre" position="replace"/>
</field>
</record>
</data>
</odoo>

18
easy_my_coop_ch/views/subscription_template.xml

@ -2,11 +2,25 @@
<odoo> <odoo>
<data> <data>
<template id="subscription_i18n_ch" inherit_id="easy_my_coop.becomecooperator" name="Removing fields"> <template id="subscription_i18n_ch" inherit_id="easy_my_coop.becomecooperator" name="Removing fields">
<xpath expr="//label[@for='no_registre']/.." position="replace"/>
<xpath expr="//label[@for='iban']/.." position="replace">
<div t-attf-class="form-group #{error and 'iban' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="iban">Bank Account Number</label>
<div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="iban" t-attf-value="#{iban or ''}" placeholder="BE48523080767127"/>
</div>
</div>
</xpath>
</template> </template>
<template id="company_subscription_i18n_ch" inherit_id="easy_my_coop.becomecompanycooperator" name="Company Removing fields"> <template id="company_subscription_i18n_ch" inherit_id="easy_my_coop.becomecompanycooperator" name="Company Removing fields">
<xpath expr="//label[@for='no_registre']/.." position="replace"/>
<xpath expr="//label[@for='iban']/.." position="replace">
<div t-attf-class="form-group #{error and 'iban' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="iban">Bank Account Number</label>
<div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="iban" t-attf-value="#{iban or ''}" placeholder="BE48523080767127"/>
</div>
</div>
</xpath>
</template> </template>
</data> </data>
</odoo> </odoo>

6
easy_my_coop_export_xlsx/wizard/export_global_wizard.py

@ -10,7 +10,6 @@ import xlsxwriter
HEADER = [ HEADER = [
'Num. Coop', 'Num. Coop',
'Numero de registre national',
'Nom', 'Nom',
'Email', 'Email',
'Banque', 'Banque',
@ -36,7 +35,6 @@ HEADER2 = [
'Nombre de part', 'Nombre de part',
'Montant', 'Montant',
'Statut', 'Statut',
'Numero de registre national',
'Email', 'Email',
'Mobile', 'Mobile',
'Adresse', 'Adresse',
@ -77,8 +75,6 @@ class export_global_report(models.TransientModel):
i = 0 i = 0
worksheet1.write(j, i, coop.cooperator_register_number) worksheet1.write(j, i, coop.cooperator_register_number)
i += 1 i += 1
worksheet1.write(j, i, coop.national_register_number)
i += 1
worksheet1.write(j, i, coop.name) worksheet1.write(j, i, coop.name)
i += 1 i += 1
worksheet1.write(j, i, coop.email) worksheet1.write(j, i, coop.email)
@ -161,8 +157,6 @@ class export_global_report(models.TransientModel):
i = 0 i = 0
worksheet1bis.write(j, i, coop.cooperator_register_number) worksheet1bis.write(j, i, coop.cooperator_register_number)
i += 1 i += 1
worksheet1bis.write(j, i, coop.national_register_number)
i += 1
worksheet1bis.write(j, i, coop.name) worksheet1bis.write(j, i, coop.name)
i += 1 i += 1
worksheet1bis.write(j, i, coop.email) worksheet1bis.write(j, i, coop.email)

3
easy_my_coop_fr/__manifest__.py

@ -4,7 +4,7 @@
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).# # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).#
{ {
"name": "Easy My Coop Fr", "name": "Easy My Coop Fr",
"version": "12.0.1.0.0",
"version": "12.0.1.0.1",
"depends": ["easy_my_coop", "depends": ["easy_my_coop",
"l10n_fr"], "l10n_fr"],
"author": "Houssine BAKKALI <houssine@coopiteasy.be>", "author": "Houssine BAKKALI <houssine@coopiteasy.be>",
@ -16,7 +16,6 @@
""", """,
'data': [ 'data': [
'views/subscription_template.xml', 'views/subscription_template.xml',
# 'views/layout_template.xml',
'views/certificate_template.xml' 'views/certificate_template.xml'
], ],
'installable': True, 'installable': True,

1
easy_my_coop_fr/models/__init__.py

@ -1 +1,2 @@
from . import coop from . import coop
from . import partner

13
easy_my_coop_fr/models/coop.py

@ -1,15 +1,15 @@
# -*- coding: utf-8 -*-
from openerp import fields, models
from odoo import fields, models
class SubscriptionRequest(models.Model): class SubscriptionRequest(models.Model):
_inherit = 'subscription.request' _inherit = 'subscription.request'
company_type = fields.Selection([
company_type = fields.Selection(selection_add=[
('asso', 'Association'), ('asso', 'Association'),
('eurl', 'EURL / Entreprise individuelle'), ('eurl', 'EURL / Entreprise individuelle'),
('sarl', 'SARL'), ('sarl', 'SARL'),
('sa', 'SA / SAS')])
('sa', 'SA / SAS')
])
def get_required_field(self): def get_required_field(self):
req_fields = super(SubscriptionRequest, self).get_required_field() req_fields = super(SubscriptionRequest, self).get_required_field()
@ -17,8 +17,3 @@ class SubscriptionRequest(models.Model):
req_fields.remove('iban') req_fields.remove('iban')
return req_fields return req_fields
# override function to disable the check
def check_belgian_identification_id(self, nat_register_num):
# deactivate number validation for french localization
return True

12
easy_my_coop_fr/models/partner.py

@ -0,0 +1,12 @@
from odoo import fields, models
class ResPartner(models.Model):
_inherit = 'res.partner'
gal_form = fields.Selection(selection_add=[
('asso', 'Association'),
('eurl', 'EURL / Entreprise individuelle'),
('sarl', 'SARL'),
('sa', 'SA / SAS')
])

2
easy_my_coop_fr/views/subscription_template.xml

@ -2,8 +2,6 @@
<odoo> <odoo>
<data> <data>
<template id="subscription_i18n" inherit_id="easy_my_coop.becomecooperator" name="Removing fields"> <template id="subscription_i18n" inherit_id="easy_my_coop.becomecooperator" name="Removing fields">
<!-- <xpath expr="//label[@for='no_registre']/.." position="replace">
</xpath> -->
<xpath expr="//label[@for='iban']/.." position="replace"> <xpath expr="//label[@for='iban']/.." position="replace">
</xpath> </xpath>
</template> </template>

66
easy_my_coop_website/controllers/main.py

@ -12,17 +12,17 @@ _TECHNICAL = ['view_from', 'view_callback']
_BLACKLIST = ['id', 'create_uid', 'create_date', 'write_uid', 'write_date', _BLACKLIST = ['id', 'create_uid', 'create_date', 'write_uid', 'write_date',
'user_id', 'active'] 'user_id', 'active']
_COOP_FORM_FIELD = ['email', 'firstname', 'lastname', 'birthdate', 'iban',
'share_product_id', 'no_registre', 'address', 'city',
'zip_code', 'country_id', 'phone', 'lang', 'nb_parts',
'total_parts', 'error_msg']
_COOP_FORM_FIELD = ['email', 'confirm_email', 'firstname', 'lastname',
'birthdate', 'iban', 'share_product_id', 'no_registre',
'address', 'city', 'zip_code', 'country_id', 'phone',
'lang', 'nb_parts', 'total_parts', 'error_msg']
_COMPANY_FORM_FIELD = ['is_company', 'company_register_number', 'company_name', _COMPANY_FORM_FIELD = ['is_company', 'company_register_number', 'company_name',
'company_email', 'company_type', 'email', 'firstname',
'company_email', 'confirm_email', 'email', 'firstname',
'lastname', 'birthdate', 'iban', 'share_product_id', 'lastname', 'birthdate', 'iban', 'share_product_id',
'no_registre', 'address', 'city', 'zip_code', 'no_registre', 'address', 'city', 'zip_code',
'country_id', 'phone', 'lang', 'nb_parts', 'country_id', 'phone', 'lang', 'nb_parts',
'total_parts', 'error_msg']
'total_parts', 'error_msg', 'company_type']
class WebsiteSubscription(http.Controller): class WebsiteSubscription(http.Controller):
@ -37,7 +37,7 @@ class WebsiteSubscription(http.Controller):
logged = True logged = True
partner = request.env.user.partner_id partner = request.env.user.partner_id
if partner.is_company: if partner.is_company:
return request.render("easy_my_coop_website.becomecompanycooperator", values)
return self.display_become_company_cooperator_page()
values = self.fill_values(values, False, logged, True) values = self.fill_values(values, False, logged, True)
for field in _COOP_FORM_FIELD: for field in _COOP_FORM_FIELD:
@ -52,8 +52,8 @@ class WebsiteSubscription(http.Controller):
type='http', auth="public", website=True) type='http', auth="public", website=True)
def display_become_company_cooperator_page(self, **kwargs): def display_become_company_cooperator_page(self, **kwargs):
values = {} values = {}
logged = False logged = False
if request.env.user.login != 'public': if request.env.user.login != 'public':
logged = True logged = True
values = self.fill_values(values, True, logged, True) values = self.fill_values(values, True, logged, True)
@ -62,7 +62,8 @@ class WebsiteSubscription(http.Controller):
if kwargs.get(field): if kwargs.get(field):
values[field] = kwargs.pop(field) values[field] = kwargs.pop(field)
values.update(kwargs=kwargs.items()) values.update(kwargs=kwargs.items())
return request.render("easy_my_coop_website.becomecompanycooperator", values)
return request.render("easy_my_coop_website.becomecompanycooperator",
values)
def preRenderThanks(self, values, kwargs): def preRenderThanks(self, values, kwargs):
""" Allow to be overrided """ """ Allow to be overrided """
@ -101,6 +102,7 @@ class WebsiteSubscription(http.Controller):
values['company_register_number'] = partner.company_register_number values['company_register_number'] = partner.company_register_number
values['company_name'] = partner.name values['company_name'] = partner.name
values['company_email'] = partner.email values['company_email'] = partner.email
values['company_type'] = partner.legal_form
# contact person values # contact person values
representative = partner.get_representative() representative = partner.get_representative()
values['firstname'] = representative.firstname values['firstname'] = representative.firstname
@ -108,7 +110,6 @@ class WebsiteSubscription(http.Controller):
values['gender'] = representative.gender values['gender'] = representative.gender
values['email'] = representative.email values['email'] = representative.email
values['contact_person_function'] = representative.function values['contact_person_function'] = representative.function
values['no_registre'] = representative.national_register_number
values['birthdate'] = self.get_date_string(representative.birthdate) values['birthdate'] = self.get_date_string(representative.birthdate)
values['lang'] = representative.lang values['lang'] = representative.lang
values['phone'] = representative.phone values['phone'] = representative.phone
@ -117,7 +118,6 @@ class WebsiteSubscription(http.Controller):
values['lastname'] = partner.lastname values['lastname'] = partner.lastname
values['email'] = partner.email values['email'] = partner.email
values['gender'] = partner.gender values['gender'] = partner.gender
values['no_registre'] = partner.national_register_number
values['birthdate'] = self.get_date_string(partner.birthdate_date) values['birthdate'] = self.get_date_string(partner.birthdate_date)
values['lang'] = partner.lang values['lang'] = partner.lang
values['phone'] = partner.phone values['phone'] = partner.phone
@ -162,6 +162,16 @@ class WebsiteSubscription(http.Controller):
if not values.get('lang'): if not values.get('lang'):
if company.default_lang_id: if company.default_lang_id:
values['lang'] = company.default_lang_id.code values['lang'] = company.default_lang_id.code
comp = request.env['res.company']._company_default_get()
values.update({
'display_data_policy': comp.display_data_policy_approval,
'data_policy_required': comp.data_policy_approval_required,
'data_policy_text': comp.data_policy_approval_text,
'display_internal_rules': comp.display_internal_rules_approval,
'internal_rules_required': comp.internal_rules_approval_required,
'internal_rules_text': comp.internal_rules_approval_text,
})
return values return values
def get_products_share(self, is_company): def get_products_share(self, is_company):
@ -228,6 +238,15 @@ class WebsiteSubscription(http.Controller):
"fill in the form") "fill in the form")
return request.render(redirect, values) return request.render(redirect, values)
else:
confirm_email = kwargs.get('confirm_email')
if email != confirm_email:
values = self.fill_values(values, is_company, logged)
values.update(kwargs)
values["error_msg"] = _("The email and the confirmation "
"email doesn't match.Please check "
"the given mail addresses")
return request.render(redirect, values)
company = request.website.company_id company = request.website.company_id
if company.allow_id_card_upload: if company.allow_id_card_upload:
@ -247,17 +266,6 @@ class WebsiteSubscription(http.Controller):
"is not valid") "is not valid")
return request.render(redirect, values) return request.render(redirect, values)
if not is_company and 'no_registre' in required_fields:
no_registre = re.sub('[^0-9a-zA-Z]+', '',
kwargs.get("no_registre"))
valid = sub_req_obj.check_belgian_identification_id(no_registre)
if not valid:
values = self.fill_values(values, is_company, logged)
values["error_msg"] = _("You national register number "
"is not valid")
return request.render(redirect, values)
values["no_registre"] = no_registre
# check the subscription's amount # check the subscription's amount
max_amount = company.subscription_maximum_amount max_amount = company.subscription_maximum_amount
if logged: if logged:
@ -339,6 +347,12 @@ class WebsiteSubscription(http.Controller):
values["already_cooperator"] = already_coop values["already_cooperator"] = already_coop
values["is_company"] = is_company values["is_company"] = is_company
if kwargs.get('data_policy_approved', 'off') == 'on':
values['data_policy_approved'] = True
if kwargs.get('internal_rules_approved', 'off') == 'on':
values['internal_rules_approved'] = True
lastname = kwargs.get("lastname").upper() lastname = kwargs.get("lastname").upper()
firstname = kwargs.get("firstname").title() firstname = kwargs.get("firstname").title()
@ -358,14 +372,6 @@ class WebsiteSubscription(http.Controller):
kwargs.get("company_register_number")) kwargs.get("company_register_number"))
subscription_id = sub_req_obj.sudo().create_comp_sub_req(values) subscription_id = sub_req_obj.sudo().create_comp_sub_req(values)
else: else:
no_registre = re.sub('[^0-9a-zA-Z]+', '',
kwargs.get("no_registre"))
values["no_registre"] = no_registre
if 'no_registre' in required_fields:
no_registre = re.sub('[^0-9a-zA-Z]+', '',
kwargs.get("no_registre"))
values["no_registre"] = no_registre
subscription_id = sub_req_obj.sudo().create(values) subscription_id = sub_req_obj.sudo().create(values)
if subscription_id: if subscription_id:

200
easy_my_coop_website/views/subscription_template.xml

@ -70,9 +70,9 @@
</label> </label>
</div> </div>
<div t-attf-class="form-group">
<div t-attf-class="form-group" style="display: none;">
<label> <label>
<input type="checkbox" t-att-value="already_cooperator" name="already_cooperator" />
<input type="checkbox" t-att-checked="already_cooperator" name="already_cooperator" />
Already cooperator? Already cooperator?
</label> </label>
</div> </div>
@ -80,27 +80,43 @@
<div name="email_from_container" t-attf-class="form-group #{error and 'email_from' in error and 'has-error' or ''}"> <div name="email_from_container" t-attf-class="form-group #{error and 'email_from' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="email">Email</label> <label class="col-md-3 col-sm-4 control-label" for="email">Email</label>
<div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px"> <div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px">
<input type="email" class="form-control mandatory-field" name="email" required="True" t-attf-value="#{email or ''}" placeholder="didier.bourdon@bees-coop.be"/>
<input type="email" class="form-control mandatory-field" name="email"
required="True" t-att-readonly="logged"
t-attf-value="#{email or ''}" placeholder="didier.bourdon@bees-coop.be"/>
</div>
</div>
<div name="confirm_email_container" t-attf-class="form-group #{error and 'email_from' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="confirm_email">Confirm Email</label>
<div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px">
<input type="confirm_email" class="form-control mandatory-field" name="confirm_email"
required="required" t-att-readonly="logged"
t-attf-value="#{confirm_email or ''}" placeholder="didier.bourdon@bees-coop.be"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'firstname' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'firstname' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="name">First Name</label> <label class="col-md-3 col-sm-4 control-label" for="name">First Name</label>
<div class="col-md-7 col-sm-8" style="padding-top:5px"> <div class="col-md-7 col-sm-8" style="padding-top:5px">
<input type="text" class="form-control mandatory-field" name="firstname" required="True" t-attf-value="#{firstname or ''}" placeholder="Didier"/>
<input type="text" class="form-control mandatory-field" name="firstname"
required="True" t-att-readonly="logged"
t-attf-value="#{firstname or ''}" placeholder="Didier"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'lastname' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'lastname' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="name">Last Name</label> <label class="col-md-3 col-sm-4 control-label" for="name">Last Name</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="lastname" required="True" t-attf-value="#{lastname or ''}" placeholder="Bourdon"/>
<input type="text" class="form-control mandatory-field" name="lastname"
required="True" t-att-readonly="logged" t-attf-value="#{lastname or ''}" placeholder="Bourdon"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'gender' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'gender' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="company_type">Gender</label> <label class="col-md-3 col-sm-4 control-label" for="company_type">Gender</label>
<select name="gender" class="col-md-7 col-sm-8 form-control" required="True" style="width:54%;margin-left:15px">
<select name="gender" class="col-md-7 col-sm-8 form-control"
required="True" t-att-readonly="logged"
style="width:54%;margin-left:15px">
<option value=""></option> <option value=""></option>
<t t-foreach="genders or []" t-as="type"> <t t-foreach="genders or []" t-as="type">
<option t-att-value="type[0]" t-att-selected="type[0] == gender"><t t-esc="type[1]"/></option> <option t-att-value="type[0]" t-att-selected="type[0] == gender"><t t-esc="type[1]"/></option>
@ -111,27 +127,24 @@
<div t-attf-class="form-group #{error and 'birthdate' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'birthdate' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="birthdate">Birthdate</label> <label class="col-md-3 col-sm-4 control-label" for="birthdate">Birthdate</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" data-inputmask="'alias': 'date'" class="form-control mandatory-field" name="birthdate" required="True" t-attf-value="#{birthdate or ''}" placeholder="05/03/1978"/>
</div>
</div>
<div t-attf-class="form-group #{error and 'no_registre' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="no_registre">National Register Number</label>
<div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="no_registre" t-attf-value="#{no_registre or ''}" placeholder="78230226321"/>
<input type="text" data-inputmask="'alias': 'date'" class="form-control mandatory-field"
name="birthdate" required="True" t-att-readonly="logged"
t-attf-value="#{birthdate or ''}" placeholder="05/03/1978"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'iban' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'iban' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="iban">Bank Account Number</label> <label class="col-md-3 col-sm-4 control-label" for="iban">Bank Account Number</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="iban" required="True" t-attf-value="#{iban or ''}" placeholder="BE48523080767127"/>
<input type="text" class="form-control mandatory-field" name="iban"
required="True" t-att-readonly="logged" t-attf-value="#{iban or ''}" placeholder="BE48523080767127"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'lang' in error and 'has-error' or ''}" > <div t-attf-class="form-group #{error and 'lang' in error and 'has-error' or ''}" >
<label class="col-md-3 col-sm-4 control-label" style="width:25%" for="lang">Language</label> <label class="col-md-3 col-sm-4 control-label" style="width:25%" for="lang">Language</label>
<select name="lang" class="col-md-7 col-sm-8 form-control " style="width:30%;margin-left:15px">
<select name="lang" class="col-md-7 col-sm-8 form-control "
t-att-readonly="logged" style="width:30%;margin-left:15px">
<option value="2">Language...</option> <option value="2">Language...</option>
<t t-foreach="langs or []" t-as="langue"> <t t-foreach="langs or []" t-as="langue">
<option t-att-value="langue.code" t-att-selected="langue.code == lang"><t t-esc="langue.name"/></option> <option t-att-value="langue.code" t-att-selected="langue.code == lang"><t t-esc="langue.name"/></option>
@ -144,7 +157,9 @@
<div t-attf-class="form-group #{error and 'address' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'address' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="address">Address</label> <label class="col-md-3 col-sm-4 control-label" for="address">Address</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="address" required="True" t-attf-value="#{address or ''}" placeholder="rue Van Hove, 19"/>
<input type="text" class="form-control mandatory-field" name="address"
required="True" t-att-readonly="logged"
t-attf-value="#{address or ''}" placeholder="rue Van Hove, 19"/>
</div> </div>
</div> </div>
@ -154,11 +169,15 @@
<table> <table>
<tr> <tr>
<td width="20%"> <td width="20%">
<input type="text" class="form-control mandatory-field" name="zip_code" required="True" t-attf-value="#{zip_code or ''}" placeholder="1030"/>
<input type="text" class="form-control mandatory-field" name="zip_code"
required="True" t-att-readonly="logged"
t-attf-value="#{zip_code or ''}" placeholder="1030"/>
</td> </td>
<td width="3%"></td> <td width="3%"></td>
<td> <td>
<input type="text" class="form-control mandatory-field" name="city" required="True" t-attf-value="#{city or ''}" placeholder="Bruxelles"/>
<input type="text" class="form-control mandatory-field" name="city"
required="True" t-att-readonly="logged"
t-attf-value="#{city or ''}" placeholder="Bruxelles"/>
</td> </td>
</tr> </tr>
</table> </table>
@ -167,7 +186,7 @@
<div t-attf-class="form-group #{error and 'country_id' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'country_id' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" style="width:25%" for="country_id">Country</label> <label class="col-md-3 col-sm-4 control-label" style="width:25%" for="country_id">Country</label>
<select name="country_id" class="col-md-7 col-sm-8 form-control " style="width:54%;margin-left:15px">
<select name="country_id" class="col-md-7 col-sm-8 form-control " t-att-readonly="logged" style="width:54%;margin-left:15px">
<option value="">Country...</option> <option value="">Country...</option>
<t t-foreach="countries or []" t-as="country"> <t t-foreach="countries or []" t-as="country">
<option t-att-value="country.id" t-att-selected="country.id == int(country_id)"><t t-esc="country.name"/></option> <option t-att-value="country.id" t-att-selected="country.id == int(country_id)"><t t-esc="country.name"/></option>
@ -178,7 +197,8 @@
<div t-attf-class="form-group #{error and 'phone' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'phone' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="phone">Phone</label> <label class="col-md-3 col-sm-4 control-label" for="phone">Phone</label>
<div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px"> <div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px">
<input type="text" class="form-control" name="phone" required="True" t-attf-value="#{phone or ''}" placeholder="e.g. (+32).81.81.37.00"/>
<input type="text" class="form-control" name="phone"
required="True" t-att-readonly="logged" t-attf-value="#{phone or ''}" placeholder="e.g. (+32).81.81.37.00"/>
</div> </div>
</div> </div>
@ -240,6 +260,35 @@
<br/> <br/>
<div id="data_policy_approved" t-if="display_data_policy" t-attf-class="form-group" >
<label class="col-md-3 col-sm-4 control-label" for="data_policy_approved">Privacy Policy</label>
<div class="col-md-9 col-sm-8">
<div class="checkbox">
<label>
<input type="checkbox"
name="data_policy_approved"
t-att="{'required': 'required'} if data_policy_required else {}"
t-attf-value="#{data_policy_approved or ''}"/>
<t t-raw="data_policy_text"/>
</label>
</div>
</div>
</div>
<div id="internal_rules_approved" t-if="display_internal_rules" t-attf-class="form-group" >
<label class="col-md-3 col-sm-4 control-label" for="internal_rules_approved">Internal Rules</label>
<div class="col-md-9 col-sm-8">
<div class="checkbox">
<label>
<input type="checkbox"
name="internal_rules_approved"
t-att="{'required': 'required'} if internal_rules_required else {}"
t-attf-value="#{internal_rules_approved or ''}"/>
<t t-raw="internal_rules_text"/>
</label>
</div>
</div>
</div>
<table style="margin-left:195px"> <table style="margin-left:195px">
<tr> <tr>
<td width="80%"> <td width="80%">
@ -297,20 +346,26 @@
<div t-attf-class="form-group #{error and 'company_register_number' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'company_register_number' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="company_register_number">Company Register Number</label> <label class="col-md-3 col-sm-4 control-label" for="company_register_number">Company Register Number</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="company_register_number" required="True" t-attf-value="#{company_register_number or ''}" placeholder="0647980091"/>
<input type="text" class="form-control mandatory-field" name="company_register_number"
required="True" t-att-readonly="logged"
t-attf-value="#{company_register_number or ''}" placeholder="0647980091"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'company_name' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'company_name' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="company_name">Company name</label> <label class="col-md-3 col-sm-4 control-label" for="company_name">Company name</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="company_name" required="True" t-attf-value="#{company_name or ''}" placeholder="La super coopérative"/>
<input type="text" class="form-control mandatory-field" name="company_name"
required="True" t-att-readonly="logged"
t-attf-value="#{company_name or ''}" placeholder="La super coopérative"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'company_type' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'company_type' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="company_type">Company type</label> <label class="col-md-3 col-sm-4 control-label" for="company_type">Company type</label>
<select name="company_type" class="col-md-7 col-sm-8 form-control" required="True" style="width:54%;margin-left:15px">
<select name="company_type" class="col-md-7 col-sm-8 form-control"
required="True" t-att-readonly="logged"
style="width:54%;margin-left:15px">
<option value=""></option> <option value=""></option>
<t t-foreach="company_types or []" t-as="type"> <t t-foreach="company_types or []" t-as="type">
<option t-att-value="type[0]" t-att-selected="type[0] == company_type"><t t-esc="type[1]"/></option> <option t-att-value="type[0]" t-att-selected="type[0] == company_type"><t t-esc="type[1]"/></option>
@ -324,11 +379,20 @@
<input type="text" class="form-control mandatory-field" name="company_email" required="True" t-attf-value="#{company_email or ''}" placeholder="administration@beescoop.be"/> <input type="text" class="form-control mandatory-field" name="company_email" required="True" t-attf-value="#{company_email or ''}" placeholder="administration@beescoop.be"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'email_from' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="confirm_email">Confirm Email</label>
<div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px">
<input type="confirm_email" class="form-control mandatory-field" name="confirm_email"
required="required" t-att-readonly="logged"
t-attf-value="#{confirm_email or ''}" placeholder="didier.bourdon@bees-coop.be"/>
</div>
</div>
<div t-attf-class="form-group #{error and 'iban' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'iban' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="iban">Bank Account Number</label> <label class="col-md-3 col-sm-4 control-label" for="iban">Bank Account Number</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="iban" required="True" t-attf-value="#{iban or ''}" placeholder="BE48523080767127"/>
<input type="text" class="form-control mandatory-field" name="iban"
required="True" t-att-readonly="logged"
t-attf-value="#{iban or ''}" placeholder="BE48523080767127"/>
</div> </div>
</div> </div>
@ -342,7 +406,9 @@
<div t-attf-class="form-group #{error and 'address' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'address' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="address">Address</label> <label class="col-md-3 col-sm-4 control-label" for="address">Address</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="address" required="True" t-attf-value="#{address or ''}" placeholder="rue Van Hove, 19"/>
<input type="text" class="form-control mandatory-field" name="address"
required="True" t-att-readonly="logged"
t-attf-value="#{address or ''}" placeholder="rue Van Hove, 19"/>
</div> </div>
</div> </div>
@ -352,11 +418,15 @@
<table> <table>
<tr> <tr>
<td width="20%"> <td width="20%">
<input type="text" class="form-control mandatory-field" name="zip_code" required="True" t-attf-value="#{zip_code or ''}" placeholder="1030"/>
<input type="text" class="form-control mandatory-field" name="zip_code"
required="True" t-att-readonly="logged"
t-attf-value="#{zip_code or ''}" placeholder="1030"/>
</td> </td>
<td width="3%"></td> <td width="3%"></td>
<td> <td>
<input type="text" class="form-control mandatory-field" name="city" required="True" t-attf-value="#{city or ''}" placeholder="Bruxelles"/>
<input type="text" class="form-control mandatory-field" name="city"
required="True" t-att-readonly="logged"
t-attf-value="#{city or ''}" placeholder="Bruxelles"/>
</td> </td>
</tr> </tr>
</table> </table>
@ -366,7 +436,8 @@
<div t-attf-class="form-group #{error and 'country_id' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'country_id' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" style="width:25%" for="country_id">Country</label> <label class="col-md-3 col-sm-4 control-label" style="width:25%" for="country_id">Country</label>
<select name="country_id" class="col-md-7 col-sm-8 form-control" style="width:54%;margin-left:15px">
<select name="country_id" class="col-md-7 col-sm-8 form-control"
t-att-readonly="logged" style="width:54%;margin-left:15px">
<option value="">Country...</option> <option value="">Country...</option>
<t t-foreach="countries or []" t-as="country"> <t t-foreach="countries or []" t-as="country">
<option t-att-value="country.id" t-att-selected="country.id == int(country_id)"><t t-esc="country.name"/></option> <option t-att-value="country.id" t-att-selected="country.id == int(country_id)"><t t-esc="country.name"/></option>
@ -383,20 +454,25 @@
<div t-attf-class="form-group #{error and 'firstname' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'firstname' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="firstname">First Name</label> <label class="col-md-3 col-sm-4 control-label" for="firstname">First Name</label>
<div class="col-md-7 col-sm-8" style="padding-top:5px"> <div class="col-md-7 col-sm-8" style="padding-top:5px">
<input type="text" class="form-control mandatory-field" name="firstname" required="True" t-attf-value="#{firstname or ''}" placeholder="Didier"/>
<input type="text" class="form-control mandatory-field" name="firstname"
required="True" t-att-readonly="logged"
t-attf-value="#{firstname or ''}" placeholder="Didier"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'lastname' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'lastname' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="lastname">Last Name</label> <label class="col-md-3 col-sm-4 control-label" for="lastname">Last Name</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="lastname" required="True" t-attf-value="#{lastname or ''}" placeholder="Bourdon"/>
<input type="text" class="form-control mandatory-field" name="lastname"
required="True" t-att-readonly="logged"
t-attf-value="#{lastname or ''}" placeholder="Bourdon"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'gender' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'gender' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="gender">Gender</label> <label class="col-md-3 col-sm-4 control-label" for="gender">Gender</label>
<select name="gender" class="col-md-7 col-sm-8 form-control" required="True" style="width:54%;margin-left:15px">
<select name="gender" class="col-md-7 col-sm-8 form-control"
required="True" t-att-readonly="logged" style="width:54%;margin-left:15px">
<option value=""></option> <option value=""></option>
<t t-foreach="genders or []" t-as="type"> <t t-foreach="genders or []" t-as="type">
<option t-att-value="type[0]" t-att-selected="type[0] == gender"><t t-esc="type[1]"/></option> <option t-att-value="type[0]" t-att-selected="type[0] == gender"><t t-esc="type[1]"/></option>
@ -407,42 +483,44 @@
<div name="email_from_container" t-attf-class="form-group #{error and 'email_from' in error and 'has-error' or ''}"> <div name="email_from_container" t-attf-class="form-group #{error and 'email_from' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="email">Email</label> <label class="col-md-3 col-sm-4 control-label" for="email">Email</label>
<div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px"> <div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px">
<input type="email" class="form-control mandatory-field" name="email" required="True" t-attf-value="#{email or ''}" placeholder="didier.bourdon@bees-coop.be"/>
<input type="email" class="form-control mandatory-field" name="email"
required="True" t-att-readonly="logged"
t-attf-value="#{email or ''}" placeholder="didier.bourdon@bees-coop.be"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'phone' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'phone' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="phone">Phone</label> <label class="col-md-3 col-sm-4 control-label" for="phone">Phone</label>
<div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px"> <div class="col-md-7 col-sm-8 bottom-line" style="padding-bottom:20px">
<input type="text" class="form-control" name="phone" required="True" t-attf-value="#{phone or ''}" placeholder="e.g. (+32).81.81.37.00"/>
<input type="text" class="form-control" name="phone"
required="True" t-att-readonly="logged"
t-attf-value="#{phone or ''}" placeholder="e.g. (+32).81.81.37.00"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'contact_person_function' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'contact_person_function' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="contact_person_function">Function</label> <label class="col-md-3 col-sm-4 control-label" for="contact_person_function">Function</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="contact_person_function" required="True" t-attf-value="#{contact_person_function or ''}"/>
</div>
</div>
<div t-attf-class="form-group #{error and 'no_registre' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="no_registre">National Register Number</label>
<div class="col-md-7 col-sm-8">
<input type="text" class="form-control mandatory-field" name="no_registre" required="True" t-attf-value="#{no_registre or ''}" placeholder="78230226321"/>
<input type="text" class="form-control mandatory-field" name="contact_person_function"
required="True" t-att-readonly="logged"
t-attf-value="#{contact_person_function or ''}"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'birthday' in error and 'has-error' or ''}"> <div t-attf-class="form-group #{error and 'birthday' in error and 'has-error' or ''}">
<label class="col-md-3 col-sm-4 control-label" for="birthdate">Birthdate</label> <label class="col-md-3 col-sm-4 control-label" for="birthdate">Birthdate</label>
<div class="col-md-7 col-sm-8"> <div class="col-md-7 col-sm-8">
<input type="text" data-inputmask="'alias': 'date'" class="form-control mandatory-field" name="birthdate" required="True" t-attf-value="#{birthdate or ''}" placeholder="05/03/1978"/>
<input type="text" data-inputmask="'alias': 'date'" class="form-control mandatory-field"
name="birthdate" required="True" t-att-readonly="logged"
t-attf-value="#{birthdate or ''}" placeholder="05/03/1978"/>
</div> </div>
</div> </div>
<div t-attf-class="form-group #{error and 'lang' in error and 'has-error' or ''}" > <div t-attf-class="form-group #{error and 'lang' in error and 'has-error' or ''}" >
<label class="col-md-3 col-sm-4 control-label" style="width:25%" for="lang">Language</label> <label class="col-md-3 col-sm-4 control-label" style="width:25%" for="lang">Language</label>
<select name="lang" class="col-md-7 col-sm-8 form-control " style="width:30%;margin-left:15px">
<select name="lang" class="col-md-7 col-sm-8 form-control"
t-att-readonly="logged" style="width:30%;margin-left:15px">
<option value="2">Language...</option> <option value="2">Language...</option>
<t t-foreach="langs or []" t-as="langue"> <t t-foreach="langs or []" t-as="langue">
<option t-att-value="langue.code" t-att-selected="langue.code == lang"><t t-esc="langue.name"/></option> <option t-att-value="langue.code" t-att-selected="langue.code == lang"><t t-esc="langue.name"/></option>
@ -502,10 +580,40 @@
<br/> <br/>
<div id="data_policy_approved" t-if="display_data_policy" t-attf-class="form-group" >
<label class="col-md-3 col-sm-4 control-label" for="data_policy_approved">Privacy Policy</label>
<div class="col-md-9 col-sm-8">
<div class="checkbox">
<label>
<input type="checkbox"
name="data_policy_approved"
t-att="{'required': 'required'} if data_policy_required else {}"
t-attf-value="#{data_policy_approved or ''}"/>
<t t-raw="data_policy_text"/>
</label>
</div>
</div>
</div>
<div id="internal_rules_approved" t-if="display_internal_rules" t-attf-class="form-group" >
<label class="col-md-3 col-sm-4 control-label" for="internal_rules_approved">Internal Rules</label>
<div class="col-md-9 col-sm-8">
<div class="checkbox">
<label>
<input type="checkbox"
name="internal_rules_approved"
t-att="{'required': 'required'} if internal_rules_required else {}"
t-attf-value="#{internal_rules_approved or ''}"/>
<t t-raw="internal_rules_text"/>
</label>
</div>
</div>
</div>
<table style="margin-left:195px"> <table style="margin-left:195px">
<tr> <tr>
<td width="80%"> <td width="80%">
<div class="g-recaptcha" t-att-data-sitekey="website.recaptcha_site_key" data-theme="green"/><br/>
<div class="g-recaptcha" t-att-data-sitekey="website.recaptcha_key_site" data-theme="green"/><br/>
</td> </td>
<td> <td>
<div class="form-group"> <div class="form-group">

4
easy_my_coop_website_portal/views/easy_my_coop_website_portal_templates.xml

@ -73,10 +73,6 @@
<label>Bank Account: </label> <label>Bank Account: </label>
<t t-esc="coop_bank.acc_number"/> <t t-esc="coop_bank.acc_number"/>
</p> </p>
<p t-if="coop.national_register_number">
<label>National Register Number: </label>
<t t-esc="coop.national_register_number"/>
</p>
<p t-if="coop.is_company and coop.company_register_number"> <p t-if="coop.is_company and coop.company_register_number">
<label>Company Register Number: </label> <label>Company Register Number: </label>
<t t-esc="coop.company_register_number"/> <t t-esc="coop.company_register_number"/>

Loading…
Cancel
Save