优化资源查询

This commit is contained in:
2025-05-07 18:17:37 +08:00
parent a661827842
commit 3b2f4f1f40
2 changed files with 6 additions and 4 deletions

View File

@@ -11,6 +11,11 @@ export class ResourceService {
) { }
async findAll(): Promise<Resource[]> {
return this.resourceRepository.find();
return this.resourceRepository.find({
where: { isHidden: false },
order: {
createdAt: 'DESC',
}
});
}
}