added community space

This commit is contained in:
hannathkadher
2024-10-15 11:38:49 +04:00
parent 2292c01220
commit d14d3b5ba2
16 changed files with 253 additions and 11 deletions

View File

@ -3,9 +3,9 @@ import { InternalServerErrorException } from '@nestjs/common';
import { BaseResponseDto } from '../dto/base.response.dto';
import { PageResponseDto } from '../dto/pagination.response.dto';
import { buildTypeORMSortQuery } from '../util/buildTypeORMSortQuery';
import { getPaginationResponseDto } from '../util/getPaginationResponseDto';
import { buildTypeORMWhereClause } from '../util/buildTypeORMWhereClause';
import { buildTypeORMIncludeQuery } from '../util/buildTypeORMIncludeQuery';
import { buildTypeORMWhereClause } from '../util/buildTypeORMWhereClause';
import { getPaginationResponseDto } from '../util/getPaginationResponseDto';
export interface TypeORMCustomModelFindAllQuery {
page: number | undefined;
@ -101,7 +101,7 @@ export function TypeORMCustomModel(repository: Repository<any>) {
// Ensure the whereClause is passed directly to findAndCount
const [data, count] = await repository.findAndCount({
where: whereClause.where || whereClause, // Don't wrap this under another 'where'
where: whereClause,
take: size,
skip: skip,
order: order,