feat: fix set false bookmark report
continuous-integration/drone/tag Build is passing Details

pull/44/head devel_13.0.0
Firman Ramdhani 2024-07-30 16:59:11 +07:00
parent e1004b3843
commit 9bcc72a69e
1 changed files with 4 additions and 0 deletions

View File

@ -181,6 +181,8 @@ export class ReportBookmarkService extends BaseReportService {
const data = await this.getOne(id);
const creator_id = data.creator_id;
const type = data.type;
const group_name = data.group_name;
const unique_name = data.unique_name;
await this.repo
.createQueryBuilder()
@ -188,6 +190,8 @@ export class ReportBookmarkService extends BaseReportService {
.set({ applied: false })
.where((query) => {
query.andWhere(`id != :id`, { id });
query.andWhere(`group_name = :group_name`, { group_name });
query.andWhere(`unique_name = :unique_name`, { unique_name });
query.andWhere(`creator_id = :creator_id`, { creator_id });
query.andWhere(`type = :type`, { type });
})