260929_01_ENH: 모니터링 평가양식에 classification추가

This commit is contained in:
2026-09-29 16:00:47 +09:00
parent 2647b88daf
commit c090c87b00
3 changed files with 44 additions and 10 deletions

View File

@@ -21,6 +21,7 @@ import {PDF_CONVERT_STATUS, REQUEST_FORM_DETAIL_KEY, REQUEST_FORM_LABEL, REQUEST
import type {CodeGroup} from "@/query/code";
import {HttpError} from "@kri/common/http";
import {
getReviewTemplateClassification,
useDownloadReviewOriginalMutation,
useDownloadReviewPdfMutation,
useDownloadReviewTemplateMutation,
@@ -304,8 +305,12 @@ export function PerformanceDetailDialog({
const reviewTemplateMutation = useDownloadReviewTemplateMutation();
const downloadReviewTemplate = (reviewType: number) => {
reviewTemplateMutation.mutate(reviewType, {
onSuccess: () => downloadFromUrl(`/api/review/template/download/${reviewType}`),
if (!draft) return;
const performanceId = draft.performanceId;
const classification = getReviewTemplateClassification(reviewType, performanceId);
const downloadUrl = `/api/review/template/download/${reviewType}${classification ? `?classification=${encodeURIComponent(classification)}` : ""}`;
reviewTemplateMutation.mutate({reviewType, performanceId}, {
onSuccess: () => downloadFromUrl(downloadUrl),
});
};