how can I modifying blockGridModel/blockGridItem as json during saving event?
during a Saving event I'd like to access the setting values of a BlockGridModel and modify the BlockGridItems like I can with published content.
When I access the content.getValue("myGrid") I get json, but there are no values available in this, just udi's. Unfortunately, these don't seem to return any values either.
I can achieve what I want with IPublishedContent because I can iterate over the blockGridItems within the BlockGridModel and get what I need from the settings. However, what I really want to do is equivalent during a saving event working with the json.
Any ideas, I've spent far to long on this, lol! Thank you inadvance!
how can I modifying blockGridModel/blockGridItem as json during saving event?
during a Saving event I'd like to access the setting values of a BlockGridModel and modify the BlockGridItems like I can with published content.
When I access the content.getValue("myGrid") I get json, but there are no values available in this, just udi's. Unfortunately, these don't seem to return any values either.
I can achieve what I want with IPublishedContent because I can iterate over the blockGridItems within the BlockGridModel and get what I need from the settings. However, what I really want to do is equivalent during a saving event working with the json.
Any ideas, I've spent far to long on this, lol! Thank you inadvance!
Hi Elliott,
Maybe take a look at the code here https://github.com/rickbutterfield/Umbraco.Community.BlockPreview
There are some services that probably do what you are trying.
is working on a reply...