-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: axios 설치 * feat: 주행 관련 API 요청 코드 * feat: 주행 API 연결 * fix: 주행 후 리포트에 코멘트 추가 * feat: 홈 페이지 헤더 * feat: 홈 화면 점수 * feat: 주행, 주행기록 API 연결 * feat: 배지 이미지 추가, API 연결 * feat: 리포트 페이지 API 추가 * feat: 리포트 API 연결
- Loading branch information
Showing
26 changed files
with
187 additions
and
111 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
import { axiosInstance } from "./instance"; | ||
|
||
export const badgeAPI = async () => { | ||
try { | ||
const response = await axiosInstance.get("/badge"); | ||
return response.data; | ||
} catch { | ||
return null; | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
import { axiosInstance } from "./instance"; | ||
|
||
const date = new Date(); | ||
|
||
/** | ||
* 간단 주행 이력 조회 | ||
* /feedback/bio | ||
*/ | ||
export const reportBioAPI = async () => { | ||
try { | ||
const response = await axiosInstance.post("/feedback/bio", { | ||
thisMonth: date.getMonth() + 1, | ||
}); | ||
return response.data; | ||
} catch { | ||
return null; | ||
} | ||
}; | ||
|
||
/** | ||
* 운전 점수 조회 | ||
* /feedback/score | ||
*/ | ||
export const reportScoreAPI = async () => { | ||
try { | ||
const response = await axiosInstance.post("/feedback/score", { | ||
thisMonth: date.getMonth() + 1, | ||
}); | ||
return response.data; | ||
} catch { | ||
return null; | ||
} | ||
}; | ||
|
||
/** | ||
* 이번달 주의 항목 - 상위 4개 | ||
* /feedback/top4 | ||
*/ | ||
export const reportWarningAPI = async () => { | ||
try { | ||
const response = await axiosInstance.post("/feedback/top4", { | ||
thisMonth: date.getMonth() + 1, | ||
}); | ||
return response.data; | ||
} catch { | ||
return null; | ||
} | ||
}; | ||
|
||
/** | ||
* 이번달 주의 항목 | ||
* /feedback/caution | ||
*/ | ||
export const reportCautionAPI = async () => { | ||
try { | ||
const response = await axiosInstance.post("/feedback/caution", { | ||
thisMonth: date.getMonth() + 1, | ||
}); | ||
return response.data; | ||
} catch { | ||
return null; | ||
} | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 15 additions & 16 deletions
31
src/components/Report/Warning/DetailWarning/RatioBarDetail.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.