fix: 看板已激活追溯码与列表口径一致,修正未激活筛选返回已激活的码

This commit is contained in:
Nixevol
2026-11-15 14:57:24 +08:00
parent a5f7844125
commit c8f076a3a7
9 changed files with 76 additions and 13 deletions
@@ -16,6 +16,7 @@ import {
import { TraceCodeStatus } from '@artveris/shared';
import { PaginationDto } from '../../common/dto/pagination.dto';
import { ONCHAIN_FILTER_STATUSES, OnchainFilterStatus } from '../../common/dto/trace-code-selection.dto';
import { queryBoolean } from '../../common/utils/query-boolean.util';
export class GenerateBatchDto {
@ApiProperty({ description: '所属作品(款)ID' })
@@ -73,9 +74,7 @@ export class QueryTraceCodeDto extends PaginationDto {
@ApiPropertyOptional({ description: '是否已经首次激活' })
@IsOptional()
@Transform(({ value }) =>
value === undefined || value === null || value === '' ? undefined : value === true || value === 'true',
)
@Transform(queryBoolean)
@IsBoolean()
activated?: boolean;
@@ -230,6 +229,12 @@ export class ExportTraceCodeDto {
@IsIn(['OUTBOUND', 'NOT_OUTBOUND'])
outboundStatus?: 'OUTBOUND' | 'NOT_OUTBOUND';
@ApiPropertyOptional({ description: '是否已经首次激活' })
@IsOptional()
@Transform(queryBoolean)
@IsBoolean()
activated?: boolean;
@ApiPropertyOptional({ description: '关键词' })
@IsOptional()
@IsString()