Skip to content

Commit

Permalink
build: client gen
Browse files Browse the repository at this point in the history
  • Loading branch information
JeanMarc-RAJAONARIVELONA committed Nov 20, 2024
1 parent 3072de0 commit bb2f2fa
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 14 deletions.
8 changes: 4 additions & 4 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
"test:merge:reports": "srm ./dist/test-reports.xml \"./dist/**/!(*test-reports).xml\""
},
"dependencies": {
"@haapi/typescript-client": "^1.78.0",
"@haapi/typescript-client": "^1.79.0",
"@mui/x-date-pickers": "^7.21.0",
"@react-admin/ra-calendar": "^4.0.1",
"@react-admin/ra-enterprise": "^7.0.0",
Expand Down
14 changes: 5 additions & 9 deletions src/providers/docsProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const docsProvider: HaDataProviderType = {
}
if (meta.type in FileType) {
return filesApi()
.getStudentFiles(meta?.studentId, page, perPage, meta.type)
.getUserFiles(meta?.studentId, page, perPage, meta.type)
.then((result) => ({data: result.data}));
}
return {data: []};
Expand All @@ -42,7 +42,7 @@ const docsProvider: HaDataProviderType = {
.then((result) => result.data);
}
return filesApi()
.getStudentFilesById(meta.studentId, id)
.getUserFilesById(meta.studentId, id)
.then((result) => result.data);
default:
return [];
Expand Down Expand Up @@ -77,13 +77,9 @@ const docsProvider: HaDataProviderType = {
}
if (doc.type in FileType) {
return filesApi()
.uploadStudentFile(
doc.studentId,
doc.type,
doc.title,
raw.rawFile,
{headers: MULTIPART_HEADERS}
)
.uploadUserFile(doc.studentId, doc.type, doc.title, raw.rawFile, {
headers: MULTIPART_HEADERS,
})
.then((result) => [result.data]);
}
return [];
Expand Down

0 comments on commit bb2f2fa

Please sign in to comment.