Files
inventree-stock-tool/src/stocktool/web/app.py
grabowski ed9a3307ef fix: Add authenticated image proxy for part images
Fixes 'Unauthorized' errors when loading part images in web app.

Problem:
- InvenTree media files require authentication
- Direct image URLs return 401 Unauthorized
- Browser can't send API token with image requests

Solution:
- Added /api/proxy/image endpoint in Flask app
- Proxy fetches images with API token authentication
- Returns image with correct Content-Type header
- Frontend uses proxy URL instead of direct InvenTree URL

Usage:
- Images now load via: /api/proxy/image?url=/media/part_images/...
- Proxy adds Authorization header automatically
- Works for both image and thumbnail URLs

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-29 11:36:44 +07:00

14 KiB