fix: AI 추천 이미지 해상도 및 스타일 개선
- 썸네일(3KB) 대신 원본 이미지(33KB) 사용 - 테두리/배경 제거로 깔끔한 디자인 - text-align:center로 중앙 정렬 - 최대 크기 140px
This commit is contained in:
@@ -2421,15 +2421,15 @@ def api_get_recommendation(user_id):
|
||||
|
||||
product_name = rec['recommended_product']
|
||||
logging.info(f"[AI추천] 검색할 제품명: {product_name}")
|
||||
# 제품명으로 이미지 검색 (LIKE 검색으로 부분 매칭)
|
||||
# 제품명으로 이미지 검색 (LIKE 검색으로 부분 매칭) - 원본 이미지 사용
|
||||
img_cursor.execute("""
|
||||
SELECT thumbnail_base64 FROM product_images
|
||||
WHERE product_name LIKE ? AND thumbnail_base64 IS NOT NULL
|
||||
SELECT image_base64 FROM product_images
|
||||
WHERE product_name LIKE ? AND image_base64 IS NOT NULL
|
||||
LIMIT 1
|
||||
""", (f'%{product_name}%',))
|
||||
img_row = img_cursor.fetchone()
|
||||
if img_row:
|
||||
product_image = img_row['thumbnail_base64']
|
||||
product_image = img_row['image_base64']
|
||||
logging.info(f"[AI추천] 이미지 찾음: {len(product_image)} bytes")
|
||||
else:
|
||||
logging.info(f"[AI추천] 이미지 없음 (제품: {product_name})")
|
||||
|
||||
Reference in New Issue
Block a user