W079: Update SKU
Edits a SKU's header fields. Triggered from SKU Detail.
Steps
-
Load the SKU. Call
Products.getSkuById. -
Check code uniqueness if changed.
-
Validate type if changed. Confirm the new
typeIdexists. -
Apply the patch. Call
Products.updateSku.
Returns
The updated SKU.
Business rules
- Code stays unique per org.
Errors
NotFoundError. The SKU or the new type was not found.ValidationError. Code collision.