mirror of
https://github.com/immich-app/immich
synced 2025-11-07 17:27:20 +00:00
refactor(server): controller cleanup (#11923)
chore(server): controller cleanup
This commit is contained in:
parent
ef9a06be5c
commit
3be1aaaaa4
25 changed files with 656 additions and 1186 deletions
|
|
@ -25,12 +25,6 @@ export class ActivityController {
|
|||
return this.service.getAll(auth, dto);
|
||||
}
|
||||
|
||||
@Get('statistics')
|
||||
@Authenticated({ permission: Permission.ACTIVITY_STATISTICS })
|
||||
getActivityStatistics(@Auth() auth: AuthDto, @Query() dto: ActivityDto): Promise<ActivityStatisticsResponseDto> {
|
||||
return this.service.getStatistics(auth, dto);
|
||||
}
|
||||
|
||||
@Post()
|
||||
@Authenticated({ permission: Permission.ACTIVITY_CREATE })
|
||||
async createActivity(
|
||||
|
|
@ -45,6 +39,12 @@ export class ActivityController {
|
|||
return value;
|
||||
}
|
||||
|
||||
@Get('statistics')
|
||||
@Authenticated({ permission: Permission.ACTIVITY_STATISTICS })
|
||||
getActivityStatistics(@Auth() auth: AuthDto, @Query() dto: ActivityDto): Promise<ActivityStatisticsResponseDto> {
|
||||
return this.service.getStatistics(auth, dto);
|
||||
}
|
||||
|
||||
@Delete(':id')
|
||||
@HttpCode(HttpStatus.NO_CONTENT)
|
||||
@Authenticated({ permission: Permission.ACTIVITY_DELETE })
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue