diff --git a/addons/portal/controllers/portal.py b/addons/portal/controllers/portal.py index 845c2936243..87e3108a2b3 100644 --- a/addons/portal/controllers/portal.py +++ b/addons/portal/controllers/portal.py @@ -174,6 +174,7 @@ class CustomerPortal(Controller): if not error: values = {key: post[key] for key in self.MANDATORY_BILLING_FIELDS} values.update({key: post[key] for key in self.OPTIONAL_BILLING_FIELDS if key in post}) + values.update({'country_id': int(values.pop('country_id', 0))}) values.update({'zip': values.pop('zipcode', '')}) if values.get('state_id') == '': values.update({'state_id': False})