fix:dashboard stats

This commit is contained in:
Rama Priyanto 2025-06-13 17:35:07 +07:00
parent 413f28599f
commit 0d390b460b
2 changed files with 3 additions and 1 deletions

View File

@ -261,6 +261,7 @@ export default function DashboardContainer() {
const res = await getUserLevelDataStat( const res = await getUserLevelDataStat(
getDate(postContentDate.startDate), getDate(postContentDate.startDate),
getDate(postContentDate.endDate), getDate(postContentDate.endDate),
getUnixTimestamp(),
id id
); );
const polresNowData = getTableNumberStats(res?.data?.data); const polresNowData = getTableNumberStats(res?.data?.data);

View File

@ -190,6 +190,7 @@ export async function deleteArticleFiles(id: number) {
export async function getUserLevelDataStat( export async function getUserLevelDataStat(
startDate: string, startDate: string,
endDate: string, endDate: string,
timeStamp: number,
levelId?: number levelId?: number
) { ) {
// const headers = { // const headers = {
@ -197,7 +198,7 @@ export async function getUserLevelDataStat(
// Authorization: `Bearer ${token}`, // Authorization: `Bearer ${token}`,
// }; // };
return await httpGetInterceptor( return await httpGetInterceptor(
`/articles/statistic/user-levels?startDate=${startDate}&endDate=${endDate}&userLevelId=${ `/articles/statistic/user-levels?startDate=${startDate}&endDate=${endDate}&timeStamp=${timeStamp}&userLevelId=${
levelId || "" levelId || ""
}` }`
); );