Browse Source
Bugfix/fix fees on account level (#2588)
* Fix fees on account level
* Update changelog
pull/2586/head^2
Thomas Kaul
1 year ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with
10 additions and
7 deletions
-
CHANGELOG.md
-
apps/api/src/app/order/create-order.dto.ts
-
apps/api/src/app/order/update-order.dto.ts
|
|
@ -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/), |
|
|
|
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 |
|
|
|
|
|
|
|
### Added |
|
|
|
|
|
@ -13,7 +13,6 @@ import { |
|
|
|
IsISO8601, |
|
|
|
IsNumber, |
|
|
|
IsOptional, |
|
|
|
IsPositive, |
|
|
|
IsString, |
|
|
|
Min |
|
|
|
} from 'class-validator'; |
|
|
@ -54,7 +53,7 @@ export class CreateOrderDto { |
|
|
|
fee: number; |
|
|
|
|
|
|
|
@IsNumber() |
|
|
|
@IsPositive() |
|
|
|
@Min(0) |
|
|
|
quantity: number; |
|
|
|
|
|
|
|
@IsString() |
|
|
@ -68,7 +67,7 @@ export class CreateOrderDto { |
|
|
|
type: Type; |
|
|
|
|
|
|
|
@IsNumber() |
|
|
|
@IsPositive() |
|
|
|
@Min(0) |
|
|
|
unitPrice: number; |
|
|
|
|
|
|
|
@IsBoolean() |
|
|
|
|
|
@ -8,12 +8,10 @@ import { |
|
|
|
import { Transform, TransformFnParams } from 'class-transformer'; |
|
|
|
import { |
|
|
|
IsArray, |
|
|
|
IsBoolean, |
|
|
|
IsEnum, |
|
|
|
IsISO8601, |
|
|
|
IsNumber, |
|
|
|
IsOptional, |
|
|
|
IsPositive, |
|
|
|
IsString, |
|
|
|
Min |
|
|
|
} from 'class-validator'; |
|
|
@ -56,7 +54,7 @@ export class UpdateOrderDto { |
|
|
|
id: string; |
|
|
|
|
|
|
|
@IsNumber() |
|
|
|
@IsPositive() |
|
|
|
@Min(0) |
|
|
|
quantity: number; |
|
|
|
|
|
|
|
@IsString() |
|
|
@ -70,6 +68,6 @@ export class UpdateOrderDto { |
|
|
|
type: Type; |
|
|
|
|
|
|
|
@IsNumber() |
|
|
|
@IsPositive() |
|
|
|
@Min(0) |
|
|
|
unitPrice: number; |
|
|
|
} |
|
|
|