Fix TypeScript errors

Fixes TypeScript errors related to type assignments and declaration conflicts. Specifically, addresses the type mismatch in `TransactionEditDialog.tsx` and declaration conflicts in `deleteTransactionStorage.ts`.
This commit is contained in:
gpt-engineer-app[bot]
2025-03-18 04:07:08 +00:00
parent 1fc2ee8a15
commit 1dcd63cb12
3 changed files with 44 additions and 47 deletions

View File

@@ -2,7 +2,7 @@
import { MutableRefObject } from 'react';
import { Transaction } from '@/components/TransactionCard';
import { saveTransactionsToStorage } from '../../storageUtils';
import { deleteTransactionFromSupabase } from '../../supabaseUtils';
import { deleteTransactionFromSupabase as deleteFromSupabase } from '../../supabaseUtils';
import { toast } from '@/hooks/useToast.wrapper';
import { normalizeDate } from '@/utils/sync/transaction/dateUtils';
@@ -33,7 +33,7 @@ export const handleDeleteStorage = (
setTimeout(() => {
try {
// 동기화 작업 실행
deleteTransactionFromSupabase(user, id)
deleteFromSupabase(user, id)
.catch(error => {
console.error('Supabase 삭제 오류:', error);
})
@@ -105,11 +105,4 @@ export const handleDeleteStorage = (
}
};
/**
* Supabase에서 트랜잭션 삭제
*/
export const deleteTransactionFromSupabase = async (user: any, transactionId: string): Promise<void> => {
// supabaseUtils에서 구현된 함수 사용
// 이 함수는 네트워크 요청을 처리합니다
return;
};
// 내부 함수 선언 제거 (supabaseUtils.ts에서 가져오기 때문에 중복 선언할 필요 없음)

View File

@@ -1,4 +1,3 @@
import { useCallback, useRef, useEffect } from 'react';
import { Transaction } from '@/components/TransactionCard';
import { useAuth } from '@/contexts/auth/AuthProvider';