Files
balikci/backend/src
salvacybersec 1b3d6f263f fix: Remove unique constraint from template_type and improve AI response handling
Database Changes:
- Remove UNIQUE constraint from mail_templates.template_type
- Allow multiple templates with same type (e.g., multiple bank templates)

Ollama Service Improvements:
- Add detailed logging for AI responses (first 500 chars)
- Check multiple field name variations (subject/Subject/konu/title, body/Body/html/content)
- Improve error messages with actual field names
- Better JSON parsing with fallback
- Clearer prompt instructions to AI

This fixes:
- 400 Validation Error when creating templates with existing type
- AI response parsing issues with different field names
2025-11-10 23:40:46 +03:00
..
2025-11-10 20:01:41 +03:00