feat: complete publish test logic

This commit is contained in:
2026-08-08 16:59:19 +03:30
parent 9742616f28
commit b4343bdb53
7 changed files with 170 additions and 65 deletions
@@ -8,6 +8,7 @@ import { filterTests } from '../helpers/filter-tests.helper';
import Utils from '@/common/utils';
import { Test } from '../entities/test.entity';
import { AppException } from '@/common/exceptions/app.exception';
import { TestStatus } from '../enums/test-status.enum';
@Injectable()
export class TestsQueryProvider {
@@ -49,7 +50,7 @@ export class TestsQueryProvider {
public async findAllForUser() {
try {
return await this.testRepository.find({
where: { isActive: true },
where: { isActive: true, status: TestStatus.PUBLISHED },
select: {
id: true,
accessType: true,