메일관리 콘솔로그 주석처리 세이브

This commit is contained in:
leeheejin
2025-10-02 18:22:58 +09:00
parent bf58e0c878
commit b4c5be1f17
28 changed files with 3081 additions and 460 deletions

View File

@@ -14,7 +14,7 @@ import {
Calendar,
Clock
} from "lucide-react";
import { getMailAccounts, getMailTemplates } from "@/lib/api/mail";
import { getMailAccounts, getMailTemplates, getMailStatistics } from "@/lib/api/mail";
interface DashboardStats {
totalAccounts: number;
@@ -39,19 +39,22 @@ export default function MailDashboardPage() {
const loadStats = async () => {
setLoading(true);
try {
// 계정 수 (apiClient를 통해 토큰 포함)
// 계정 수
const accounts = await getMailAccounts();
// 템플릿 수 (apiClient를 통해 토큰 포함)
// 템플릿 수
const templates = await getMailTemplates();
// 발송 통계
const mailStats = await getMailStatistics();
setStats({
totalAccounts: accounts.length,
totalTemplates: templates.length,
sentToday: 0, // TODO: 실제 발송 통계 API 연동
receivedToday: 0,
sentThisMonth: 0,
successRate: 0,
sentToday: mailStats.todayCount,
receivedToday: 0, // 수신함 기능은 별도
sentThisMonth: mailStats.thisMonthCount,
successRate: mailStats.successRate,
});
} catch (error) {
// console.error('통계 로드 실패:', error);
@@ -229,6 +232,17 @@ export default function MailDashboardPage() {
</div>
</a>
<a
href="/admin/mail/sent"
className="flex items-center p-4 rounded-lg border border-gray-200 hover:border-orange-300 hover:bg-orange-50 transition-all"
>
<Inbox className="w-8 h-8 text-indigo-500 mr-3" />
<div>
<p className="font-medium text-gray-900"></p>
<p className="text-sm text-gray-500"> </p>
</div>
</a>
<a
href="/admin/mail/receive"
className="flex items-center p-4 rounded-lg border border-gray-200 hover:border-orange-300 hover:bg-orange-50 transition-all"