diff options
| author | IT Fixcomart <it@fixcomart.co.id> | 2025-06-16 01:39:22 +0000 |
|---|---|---|
| committer | IT Fixcomart <it@fixcomart.co.id> | 2025-06-16 01:39:22 +0000 |
| commit | 27bfdedcb547fdf9f4cca084c77f966375f748f0 (patch) | |
| tree | 627a7bf82b6f664037a62d4ffbf451262d0ad526 /indoteknik_custom/models/product_template.py | |
| parent | b87f89b8af2731e02d6ab095c3e92e48b39b4f6c (diff) | |
| parent | df02e9c6f0db21b43ae25d77c7072a5dd15f9848 (diff) | |
Merged in biteship-v1 (pull request #329)
Biteship v1
Diffstat (limited to 'indoteknik_custom/models/product_template.py')
| -rwxr-xr-x | indoteknik_custom/models/product_template.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/indoteknik_custom/models/product_template.py b/indoteknik_custom/models/product_template.py index 2c07824a..f59bea6b 100755 --- a/indoteknik_custom/models/product_template.py +++ b/indoteknik_custom/models/product_template.py @@ -349,6 +349,9 @@ class ProductTemplate(models.Model): 'search_key':[item_code], } response = requests.post(url, headers=headers, json=json_data) + if response.status_code != 200: + return 0 + datas = json.loads(response.text)['data'] qty = 0 for data in datas: |
