I have just upgraded a site in progress from 1.11.0 to 1.12.0. The client has a large catalog of products already created and mostly finished. Is there any way to get the content from the existing products (which have a merchello product selector set to the correct product) onto the merchello products?
I am happy to write a script to do this one time if there is a method I can use.
Am I right in thinking that all of the content from the extended content tabs goes in to the values column on the merchProductVariantDetachedContent table as a json array?
I did manage to get this working in the end using the code from the bazaardatainstaller, however, I had to compile a custom dll to get it to work as many of the things I needed to use from the DetachedContentTypeService were marked internal so I had to make them public temporarily. Is there a way to add detached content which doesn't use the DetachedContentTypeService or have I missed something which would get me access to the internal classes?
I'm onto another project now which also requires me to import products with detached content and I don't want to have to fiddle with the core merchello code again if I don't have to!
The product selector is still available without being changed. Also, there are many perfectly good valid usages for using it so I would not say it is not recommended.
Upgrade to 1.12.0. Any way to link existing content to extended content?
I have just upgraded a site in progress from 1.11.0 to 1.12.0. The client has a large catalog of products already created and mostly finished. Is there any way to get the content from the existing products (which have a merchello product selector set to the correct product) onto the merchello products?
I am happy to write a script to do this one time if there is a method I can use.
Am I right in thinking that all of the content from the extended content tabs goes in to the values column on the merchProductVariantDetachedContent table as a json array?
Thanks
Chris
@Chris
Yes - the values do get stored as JSON in the merchProductVariantDetachedContent table.
You can checkout the Bazaar data installer as an example of how I populated dummy data ...
https://github.com/Merchello/Merchello/blob/1.12.0/src/Merchello.Bazaar/Install/BazaarDataInstaller.cs
Fantastic, thank you. I'll post my code up when i've made it work!
Hi Rusty,
I did manage to get this working in the end using the code from the bazaardatainstaller, however, I had to compile a custom dll to get it to work as many of the things I needed to use from the DetachedContentTypeService were marked internal so I had to make them public temporarily. Is there a way to add detached content which doesn't use the DetachedContentTypeService or have I missed something which would get me access to the internal classes?
I'm onto another project now which also requires me to import products with detached content and I don't want to have to fiddle with the core merchello code again if I don't have to!
Thanks
Chris
So I guess that I will still have to compile my own dll with these not internal to do my import. Is this ever likely to be changed in the future?
Hi Chris,
I tried to create detached content and faced the same problems, follow this thread:
https://our.umbraco.org/projects/collaboration/merchello/merchello/71850-how-to-programtically-add-product-with-variants-in-one-method
I'm sorry for the off-topic but is the product selector not available after 1.12 or just not the recommended way anymore?
@Pantelis
The product selector is still available without being changed. Also, there are many perfectly good valid usages for using it so I would not say it is not recommended.
is working on a reply...