Add SQL query for average cost retrieval and generate TriggerLog model

This commit is contained in:
2025-12-14 10:15:57 +03:30
parent 41d7dd8802
commit 9d7d94b5f8
45 changed files with 3742 additions and 440 deletions
@@ -1,19 +1,30 @@
import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger'
import { Type } from 'class-transformer'
import { IsInt, IsOptional, IsString } from 'class-validator'
import { ArrayMinSize, IsInt, IsOptional, IsString } from 'class-validator'
import { CreateInventoryTransferItemDto } from '../../inventory-transfer-items/dto/create-inventory-transfer-item.dto'
export class CreateInventoryTransferDto {
@ApiProperty()
@IsString()
code: string
@ApiPropertyOptional()
@IsOptional()
@IsString()
description?: string
@ApiProperty()
@Type(() => Number)
@IsInt()
fromInventoryId: number
@ApiProperty()
@Type(() => Number)
@IsInt()
toInventoryId: number
@ApiProperty({ type: [CreateInventoryTransferItemDto] })
@Type(() => Array)
@ArrayMinSize(1)
items: Array<Omit<CreateInventoryTransferItemDto, 'transferId'>>
}