perf: 上传自定义证书

This commit is contained in:
xiaojunnuo
2025-01-24 18:04:17 +08:00
parent c89686a2fd
commit 75a38d95f3
7 changed files with 177 additions and 63 deletions
@@ -84,4 +84,15 @@ export class CertInfoController extends CrudController<CertInfoService> {
});
return this.ok(list);
}
@Post('/upload', { summary: Constants.per.authOnly })
async upload(@Body(ALL) body: any) {
if (body.id) {
await this.service.checkUserId(body.id, this.getUserId());
}
const res = await this.service.upload(body);
return this.ok(res);
}
}