[FIX] website_sale_delivery: if state_ids is not specified, all states supported
Set up a delivery method that has a country set on it, but no states (e.g. USA) When the client is required to fill his address info in and when he chooses USA as the country Before this commit: The selection field where the states are selectable is not displayed. After this commit: All the states of the country are selectable The usability choice is to say that if states are not specified on the delivery method that means all states are supported OPW 1818591
This commit is contained in:
@@ -35,5 +35,7 @@ class ResCountry(models.Model):
|
||||
states = res
|
||||
break
|
||||
states |= carrier.state_ids
|
||||
if not states:
|
||||
states = states.search([('country_id', '=', self.id)])
|
||||
res = res & states
|
||||
return res
|
||||
|
||||
Reference in New Issue
Block a user