diff --git a/backend/src/controllers/ollama.controller.js b/backend/src/controllers/ollama.controller.js index 62f7e1f..6670d70 100644 --- a/backend/src/controllers/ollama.controller.js +++ b/backend/src/controllers/ollama.controller.js @@ -121,9 +121,9 @@ exports.generateTemplate = async (req, res, next) => { if (template_name && template_type) { savedTemplate = await MailTemplate.create({ name: template_name, - type: template_type, + template_type: template_type, // Fixed: was 'type', should be 'template_type' subject_template: templateData.subject_template, - body_template: templateData.body_template, + body_html: templateData.body_template, // Fixed: was 'body_template', should be 'body_html' description: `AI tarafından oluşturuldu - ${scenario}`, });