File tree Expand file tree Collapse file tree 2 files changed +21
-0
lines changed
quix-frontend/service/src/modules/web-api Expand file tree Collapse file tree 2 files changed +21
-0
lines changed Original file line number Diff line number Diff line change @@ -30,6 +30,13 @@ export class FoldersController {
30
30
return list ;
31
31
}
32
32
33
+ @Get ( '/user/:email/files' )
34
+ async getUserFullTree ( @Param ( 'email' ) email : string ) {
35
+ const list = await this . foldersService . getFilesForUser ( email ) ;
36
+
37
+ return list ;
38
+ }
39
+
33
40
@Get ( 'files/:id' )
34
41
async getSpecificFolder ( @Param ( 'id' ) id : string ) {
35
42
const folder = this . foldersService . getFolder ( id ) ;
Original file line number Diff line number Diff line change @@ -29,4 +29,18 @@ export class NotebookController {
29
29
30
30
return notebook ;
31
31
}
32
+
33
+ @Get ( ':id/:email' )
34
+ @UseGuards ( AuthGuard )
35
+ async getUserNotebook ( @Param ( 'email' ) email : string , @Param ( 'id' ) id : string ) {
36
+ const notebook = await this . notebookService . getNotebook ( email , id ) ;
37
+
38
+ if ( ! notebook ) {
39
+ throw new HttpException ( `Can't find notebook` , HttpStatus . NOT_FOUND ) ;
40
+ }
41
+
42
+ return notebook ;
43
+ }
44
+
45
+
32
46
}
You can’t perform that action at this time.
0 commit comments