refactor: remove usage of inventory_quantity from the codebase (#7323)

This commit is contained in:
Harminder Virk
2024-05-14 13:01:49 +02:00
committed by GitHub
parent 9ca302d33f
commit a502222582
18 changed files with 159 additions and 118 deletions
@@ -97,17 +97,6 @@ class ProductVariant {
@Property({ columnType: "text", nullable: true })
upc?: string | null
// TODO: replace with BigNumber
// Note: Upon serialization, this turns to a string. This is on purpose, because you would loose
// precision if you cast numeric to JS number, as JS number is a float.
// Ref: https://github.com/mikro-orm/mikro-orm/issues/2295
@Property({
columnType: "numeric",
default: 100,
serializer: optionalNumericSerializer,
})
inventory_quantity?: number = 100
@Property({ columnType: "boolean", default: false })
allow_backorder?: boolean = false