You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It'd be neat if the upsert-capabilities of createOrUpdatePartial could use unique columns like code to find an existing row.
Also maybe "unique per parent", i.e. a Product parent with ProductDimension children, but there should be only one ProductDimension for a given type for each Product.
With the combination of config.addRule(uniquePerParentAnd("product", "type")), we could take saveProduct({ id: "pr:1", dimensions: [{ type: ..., value: ... }] }) and update existing dimensions-of-that-type.
The text was updated successfully, but these errors were encountered:
It'd be neat if the
upsert
-capabilities ofcreateOrUpdatePartial
could use unique columns likecode
to find an existing row.Also maybe "unique per parent", i.e. a
Product
parent withProductDimension
children, but there should be only oneProductDimension
for a giventype
for eachProduct
.With the combination of
config.addRule(uniquePerParentAnd("product", "type"))
, we could takesaveProduct({ id: "pr:1", dimensions: [{ type: ..., value: ... }] })
and update existing dimensions-of-that-type.The text was updated successfully, but these errors were encountered: