Bugfix/fix fees on account level (#2588)

* Fix fees on account level

* Update changelog
pull/2586/head^2
Thomas Kaul 8 months ago committed by GitHub
parent 81ded53363
commit 8a523a981a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## Unreleased
### Fixed
- Loosened the validation in the activities import (expects values greater than or equal to 0 for `fee`, `quantity` and `unitPrice`)
## 2.17.0 - 2023-11-02 ## 2.17.0 - 2023-11-02
### Added ### Added

@ -13,7 +13,6 @@ import {
IsISO8601, IsISO8601,
IsNumber, IsNumber,
IsOptional, IsOptional,
IsPositive,
IsString, IsString,
Min Min
} from 'class-validator'; } from 'class-validator';
@ -54,7 +53,7 @@ export class CreateOrderDto {
fee: number; fee: number;
@IsNumber() @IsNumber()
@IsPositive() @Min(0)
quantity: number; quantity: number;
@IsString() @IsString()
@ -68,7 +67,7 @@ export class CreateOrderDto {
type: Type; type: Type;
@IsNumber() @IsNumber()
@IsPositive() @Min(0)
unitPrice: number; unitPrice: number;
@IsBoolean() @IsBoolean()

@ -8,12 +8,10 @@ import {
import { Transform, TransformFnParams } from 'class-transformer'; import { Transform, TransformFnParams } from 'class-transformer';
import { import {
IsArray, IsArray,
IsBoolean,
IsEnum, IsEnum,
IsISO8601, IsISO8601,
IsNumber, IsNumber,
IsOptional, IsOptional,
IsPositive,
IsString, IsString,
Min Min
} from 'class-validator'; } from 'class-validator';
@ -56,7 +54,7 @@ export class UpdateOrderDto {
id: string; id: string;
@IsNumber() @IsNumber()
@IsPositive() @Min(0)
quantity: number; quantity: number;
@IsString() @IsString()
@ -70,6 +68,6 @@ export class UpdateOrderDto {
type: Type; type: Type;
@IsNumber() @IsNumber()
@IsPositive() @Min(0)
unitPrice: number; unitPrice: number;
} }

Loading…
Cancel
Save