fix: bug in services list

This commit is contained in:
mahyargdz
2025-03-04 14:31:34 +03:30
parent ea184c643b
commit 3db3a1de99
2 changed files with 4 additions and 5 deletions
@@ -93,8 +93,7 @@ export class DanakServicesService {
const { limit, skip } = PaginationUtils(queryDto);
const queryBuilder = this.danakServicesCategoryRepository
.createQueryBuilder("category")
.where("service.deletedAt = :deletedAt", { deletedAt: IsNull() })
// .where("category.deletedAt IS NULL")
.where("category.deletedAt IS NULL")
.loadRelationCountAndMap("category.servicesCount", "category.danakServices")
.loadRelationCountAndMap("category.childrenCount", "category.children");
@@ -259,7 +258,7 @@ export class DanakServicesService {
async getDanakServiceByIdWithSubs(serviceId: string, isAdmin: boolean, userId: string) {
const serviceQueryBuilder = this.danakServicesRepository
.createQueryBuilder("service")
.where("service.deletedAt = :deletedAt", { deletedAt: IsNull() })
.where("service.deletedAt IS NULL")
.leftJoinAndSelect("service.images", "images")
.leftJoinAndSelect("service.subscriptionPlans", "subscriptionPlans")
.leftJoin("service.reviews", "reviews", "reviews.status = :reviewStatus", { reviewStatus: ReviewStatus.APPROVED })