feat(pipelines): 添加查询 commit logs 接口。

This commit is contained in:
Ivan Li
2021-03-07 22:53:16 +08:00
parent bba7963949
commit f00f75673b
6 changed files with 82 additions and 2 deletions

View File

@@ -4,6 +4,7 @@ import { UpdatePipelineInput } from './dtos/update-pipeline.input';
import { Pipeline } from './pipeline.entity';
import { PipelinesService } from './pipelines.service';
import { ListPipelineArgs } from './dtos/list-pipelines.args';
import { LogList } from '../repos/dtos/log-list.model';
@Resolver()
export class PipelinesResolver {
@@ -41,4 +42,9 @@ export class PipelinesResolver {
async deletePipeline(@Args('id', { type: () => String }) id: string) {
return await this.service.remove(id);
}
@Query(() => String)
async listLogsForPipeline(@Args('id', { type: () => String }) id: string) {
return await this.service.listLogsForPipeline(id);
}
}