fix: paginate operational list pages
This commit is contained in:
@@ -24,8 +24,10 @@ export class ClientSendChainController {
|
||||
}
|
||||
|
||||
@Get('batch-tasks')
|
||||
listBatchTasks(@TenantId() tenantId?: string, @Query('status') status?: string) {
|
||||
return this.sendChain.listBatchTasks(requireTenantId(tenantId), status, 'client');
|
||||
listBatchTasks(@TenantId() tenantId?: string, @Query('status') status?: string, @Query('keyword') keyword?: string, @Query('applicationKeyword') applicationKeyword?: string, @Query('createdAtFrom') createdAtFrom?: string, @Query('createdAtTo') createdAtTo?: string, @Query('page') page?: string, @Query('pageSize') pageSize?: string) {
|
||||
return page || pageSize
|
||||
? this.sendChain.listBatchTasksPage({ tenantId: requireTenantId(tenantId), status, sourceType: 'client', keyword, applicationKeyword, createdAtFrom, createdAtTo, page: Number(page), pageSize: Number(pageSize) })
|
||||
: this.sendChain.listBatchTasks(requireTenantId(tenantId), status, 'client');
|
||||
}
|
||||
|
||||
@Get('batch-tasks/:id')
|
||||
|
||||
Reference in New Issue
Block a user