fix: 'NoneType' object is not iterable (backport #39977) (#39981)

fix: 'NoneType' object is not iterable (#39977)

(cherry picked from commit 8e7d47b3a7453ce7ded83c4205c556716f2afa19)

Co-authored-by: rohitwaghchaure <rohitw1991@gmail.com>
This commit is contained in:
mergify[bot] 2024-02-20 15:53:12 +05:30 committed by GitHub
parent 720144898f
commit 0f87ec15ad
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -73,6 +73,10 @@ class PickList(Document):
self.update_status()
self.set_item_locations()
if self.get("locations"):
self.validate_sales_order_percentage()
def validate_sales_order_percentage(self):
# set percentage picked in SO
for location in self.get("locations"):
if (