feat(api): apiClient.delete에 body 데이터 지원 추가

- DELETE 요청 시 body 데이터 전송 가능하도록 수정
- 일괄 삭제 기능 (bulk delete) 정상 작동 지원
- 영향 범위: 7개 모듈의 일괄 삭제 기능

Phase 3.2 품목관리 API 연동 완료
This commit is contained in:
2026-01-09 22:07:30 +09:00
parent e4b5e6ae30
commit b9af603cb7

View File

@@ -146,9 +146,14 @@ export class ApiClient {
/**
* DELETE 요청
* @param endpoint API 엔드포인트
* @param options body 데이터 (일괄 삭제 등에서 사용)
*/
async delete<T>(endpoint: string): Promise<T> {
return this.request<T>(endpoint, { method: 'DELETE' });
async delete<T>(endpoint: string, options?: { data?: unknown }): Promise<T> {
return this.request<T>(endpoint, {
method: 'DELETE',
body: options?.data ? JSON.stringify(options.data) : undefined,
});
}
/**