feat: 챗봇 신고 페이지 AI 백엔드 추가 및 기타 개선
- ai-service: 챗봇 분석/요약 엔드포인트 추가 (chatbot.py, chatbot_service.py) - tkreport: 챗봇 신고 페이지 (chat-report.html/js/css), nginx ai-api 프록시 - tkreport: 이미지 업로드 서비스 개선, M-Project 연동 신고자 정보 전달 - system1: TBM 작업보고서 UI 개선 - TKQC: 관리함/수신함 기능 개선 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -461,7 +461,7 @@ function createInProgressRow(issue, project) {
|
||||
<i class="fas fa-lightbulb mr-2"></i>AI 해결방안 제안 (과거 사례 기반)
|
||||
</button>
|
||||
<div id="aiSuggestResult_${issue.id}" class="hidden mt-2 p-3 bg-purple-50 border border-purple-200 rounded-lg">
|
||||
<p id="aiSuggestContent_${issue.id}" class="text-sm text-gray-800 whitespace-pre-wrap"></p>
|
||||
<div id="aiSuggestContent_${issue.id}" class="text-sm text-gray-800 prose prose-sm max-w-none"></div>
|
||||
<p id="aiSuggestSources_${issue.id}" class="text-xs text-purple-600 mt-2"></p>
|
||||
<button onclick="applyAiSuggestion(${issue.id})" class="mt-2 text-xs px-2 py-1 bg-purple-600 text-white rounded hover:bg-purple-700 transition-colors">
|
||||
<i class="fas fa-paste mr-1"></i>해결방안에 적용
|
||||
@@ -985,7 +985,15 @@ async function aiSuggestSolution() {
|
||||
return;
|
||||
}
|
||||
|
||||
if (content) content.textContent = data.suggestion || '';
|
||||
if (content) {
|
||||
const raw = data.suggestion || '';
|
||||
content.dataset.raw = raw;
|
||||
if (typeof marked !== 'undefined') {
|
||||
content.innerHTML = marked.parse(raw);
|
||||
} else {
|
||||
content.textContent = raw;
|
||||
}
|
||||
}
|
||||
if (sources && data.referenced_issues) {
|
||||
const refs = data.referenced_issues
|
||||
.filter(r => r.has_solution)
|
||||
@@ -1017,7 +1025,15 @@ async function aiSuggestSolutionInline(issueId) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (content) content.textContent = data.suggestion || '';
|
||||
if (content) {
|
||||
const raw = data.suggestion || '';
|
||||
content.dataset.raw = raw;
|
||||
if (typeof marked !== 'undefined') {
|
||||
content.innerHTML = marked.parse(raw);
|
||||
} else {
|
||||
content.textContent = raw;
|
||||
}
|
||||
}
|
||||
if (sources && data.referenced_issues) {
|
||||
const refs = data.referenced_issues
|
||||
.filter(r => r.has_solution)
|
||||
@@ -1033,7 +1049,7 @@ function applyAiSuggestion(issueId) {
|
||||
const content = document.getElementById(`aiSuggestContent_${issueId}`);
|
||||
const textarea = document.getElementById(`management_comment_${issueId}`);
|
||||
if (content && textarea) {
|
||||
textarea.value = content.textContent;
|
||||
textarea.value = content.dataset.raw || content.textContent;
|
||||
textarea.focus();
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user