Check for quotation return when not have zips

This commit is contained in:
resteve 2015-01-27 13:08:08 +01:00
parent 8b3a57b3f9
commit a1cf04ad70
1 changed files with 2 additions and 0 deletions

View File

@ -72,6 +72,8 @@ class Sale:
shipment_zip = (self.shipment_address and self.shipment_address.zip
or '')
carrier = self.carrier
if not carrier.zips:
return res
if (carrier and shipment_zip):
for carrier_zip in carrier.zips:
if (int(carrier_zip.start_zip) <= int(shipment_zip)