You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

27 lines
1.0 KiB

5 years ago
5 years ago
5 years ago
5 years ago
  1. # -*- coding: utf-8 -*-
  2. from openerp import fields, models
  3. class subscription_request(models.Model):
  4. _inherit = 'subscription.request'
  5. company_type = fields.Selection([('ei', 'Individual company'),
  6. ('snc', 'Partnership'),
  7. ('sa', 'Limited company (SA)'),
  8. ('sarl', 'Limited liability company (Ltd)'), #noqa
  9. ('sc', 'Cooperative'),
  10. ('asso', 'Association'),
  11. ('fond', 'Foundation'),
  12. ('edp', 'Company under public law')])
  13. def get_required_field(self):
  14. req_fields = super(subscription_request, self).get_required_field()
  15. if 'iban' in req_fields:
  16. req_fields.remove('iban')
  17. return req_fields
  18. def check_iban(self, iban):
  19. if iban:
  20. return super(subscription_request, self).check_iban(iban)
  21. return True