Created
February 24, 2020 17:52
-
-
Save pskd73/894d0a117b594c4a9c8703bdd01c1d9c to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def assign_logistic_service(order): | |
for logistic in logistic_services: | |
if logistic.is_serviceable(order.postal_code): | |
# if hack | |
if logistic.__class__.__name__ == 'DoneTodayLogisticService': | |
if order.postal_code in [690040, 690041]: | |
continue | |
logistic.make_shipping_request() | |
return logistic.__class__.__name__ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment