Feature/add default values for countries and sectors (#1133)

* Add default values

* Add database validation script

* Update changelog
pull/1135/head
Thomas Kaul 2 years ago committed by GitHub
parent dbc38e705e
commit 573038f407
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added
- Added `url` to the symbol profile overrides model for manual adjustments
- Added default values for `countries` and `sectors` of the symbol profile overrides model
### Changed

@ -26,6 +26,7 @@
"database:push": "prisma db push",
"database:seed": "prisma db seed",
"database:setup": "yarn database:push && yarn database:seed && yarn database:baseline",
"database:validate": "prisma validate",
"dep-graph": "nx dep-graph",
"e2e": "ng e2e",
"format": "nx format:write",

@ -0,0 +1,2 @@
-- AlterTable
ALTER TABLE "SymbolProfileOverrides" ALTER COLUMN "countries" SET DEFAULT '[]';

@ -0,0 +1,2 @@
-- AlterTable
ALTER TABLE "SymbolProfileOverrides" ALTER COLUMN "sectors" SET DEFAULT '[]';

@ -133,9 +133,9 @@ model SymbolProfile {
model SymbolProfileOverrides {
assetClass AssetClass?
assetSubClass AssetSubClass?
countries Json?
countries Json? @default("[]")
name String?
sectors Json?
sectors Json? @default("[]")
url String?
symbolProfileId String @id
updatedAt DateTime @updatedAt

Loading…
Cancel
Save