I'm using Umbraco 8 to store Webshop Products. Within Product I have a nested content with Product Variants and within those variants I have created nested content with Product Variant Values. Example structure;
Product X (documenttypealies Product):
- Variant Color (type alias ProductVariant:
-- Variant value Red (type alias ProductVariantValue)
-- Variant value Blue
- Variant Size:
-- Variant value L
--- Variant value XL
Now I store a property Stock on both the Product level and Product Variant Value level. In case a product gets ordered, I want to substract the ordered amount from the correct size and color nested content item.
I'm able to read all the Product X nested content values, but I have no idea how to set a specific value within the ProductVariantValue level. I've seen some examples of serializing the property value, but this feels a bit overkill. Isn't there any simple method to update a value within a certain nested content item?
Umbraco 8 Nested Content update property value
Hi,
I'm using Umbraco 8 to store Webshop Products. Within Product I have a nested content with Product Variants and within those variants I have created nested content with Product Variant Values. Example structure;
Product X (documenttypealies Product): - Variant Color (type alias ProductVariant: -- Variant value Red (type alias ProductVariantValue) -- Variant value Blue - Variant Size: -- Variant value L --- Variant value XL
Now I store a property Stock on both the Product level and Product Variant Value level. In case a product gets ordered, I want to substract the ordered amount from the correct size and color nested content item.
I'm able to read all the Product X nested content values, but I have no idea how to set a specific value within the ProductVariantValue level. I've seen some examples of serializing the property value, but this feels a bit overkill. Isn't there any simple method to update a value within a certain nested content item?
Regards,
Paul
is working on a reply...