fix(stock-location,core-flows,types): updates existing address when updating stock location (#10832)
* fix(stock-location,core-flows,types): updates existing address when updating stock location address * chore: use hasOne instead of hasMany
This commit is contained in:
@@ -13,7 +13,7 @@ const StockLocationAddress = model
|
||||
province: model.text().nullable(),
|
||||
postal_code: model.text().nullable(),
|
||||
metadata: model.json().nullable(),
|
||||
stock_locations: model.hasMany(() => StockLocation, {
|
||||
stock_locations: model.hasOne(() => StockLocation, {
|
||||
mappedBy: "address",
|
||||
}),
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user