fix api manage list response system
This commit is contained in:
parent
b10f17b5dc
commit
0e5cf4f69a
1 changed files with 5 additions and 1 deletions
|
|
@ -368,6 +368,7 @@ export class ApiManageController extends Controller {
|
|||
if (system) {
|
||||
queryBuilder.andWhere("apiName.system = :system", { system });
|
||||
}
|
||||
// console.log("query ===> ", queryBuilder.getQuery());
|
||||
|
||||
const [apiNames, total] = await queryBuilder
|
||||
.skip(offset)
|
||||
|
|
@ -377,7 +378,10 @@ export class ApiManageController extends Controller {
|
|||
.getManyAndCount();
|
||||
|
||||
return new HttpSuccess({
|
||||
data: apiNames,
|
||||
data: apiNames.map((api) => ({
|
||||
...api,
|
||||
system: this.systems.find((s) => s.code === api.system)?.name || api.system,
|
||||
})),
|
||||
total,
|
||||
});
|
||||
} catch (error) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue