summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIT Fixcomart <it@fixcomart.co.id>2022-09-27 15:00:39 +0700
committerIT Fixcomart <it@fixcomart.co.id>2022-09-27 15:00:39 +0700
commitd1bc570eae2818bc4b535840f2eb3061b99ca98b (patch)
treea0588d2b67f61f4f708a6b0f763231265946f201
parent469dd515bacbd4f76265860a9d7c8c745cb5bcf0 (diff)
Fix product image not found rest api
-rw-r--r--indoteknik_custom/controllers/api/product.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/indoteknik_custom/controllers/api/product.py b/indoteknik_custom/controllers/api/product.py
index 0cd02e90..3b1c4ce8 100644
--- a/indoteknik_custom/controllers/api/product.py
+++ b/indoteknik_custom/controllers/api/product.py
@@ -82,7 +82,7 @@ class ProductApi(api_controller.ApiController):
data['products'].append({
'id': product_template.id,
- 'image': base_url + 'api/image/product.template/image_128/' + str(product_template.id),
+ 'image': base_url + 'api/image/product.template/image_128/' + str(product_template.id) if product_template.image_128 else '',
'name': product_template.name,
'price': price,
'discount_price': discount_price,