add
This commit is contained in:
parent
fed255d2c8
commit
a3f3f54639
|
@ -187,6 +187,19 @@ export class PostService extends BaseTreeService<Prisma.PostDelegate> {
|
||||||
);
|
);
|
||||||
return transDto;
|
return transDto;
|
||||||
}
|
}
|
||||||
|
// async findMany(args: Prisma.PostFindManyArgs, staff?: UserProfile) {
|
||||||
|
// if (!args.where) args.where = {};
|
||||||
|
// args.where.OR = await this.preFilter(args.where.OR, staff);
|
||||||
|
// return this.wrapResult(super.findMany(args), async (result) => {
|
||||||
|
// await Promise.all(
|
||||||
|
// result.map(async (item) => {
|
||||||
|
// await setPostRelation({ data: item, staff });
|
||||||
|
// await this.setPerms(item, staff);
|
||||||
|
// }),
|
||||||
|
// );
|
||||||
|
// return { ...result };
|
||||||
|
// });
|
||||||
|
// }
|
||||||
async findManyWithCursor(args: Prisma.PostFindManyArgs, staff?: UserProfile) {
|
async findManyWithCursor(args: Prisma.PostFindManyArgs, staff?: UserProfile) {
|
||||||
if (!args.where) args.where = {};
|
if (!args.where) args.where = {};
|
||||||
args.where.OR = await this.preFilter(args.where.OR, staff);
|
args.where.OR = await this.preFilter(args.where.OR, staff);
|
||||||
|
|
Loading…
Reference in New Issue