The CMS.Ecommerce.SKUInfoProvider.GetSKUInfo(skuId) returns just the SKUInfo object and no document (page) information. Is there a way to get the actual document associated with the SKU in code? From the joined view in the database, I can see the SKUID, NodeID, DocumentID, and NodeSKUID in a single record. How can I get from SKU to Document in code?
For clarity, I would like the returned object to be of type CMS.DocumentEngine.TreeNode or comparable with an input of data gleaned from the SKUInfo object.
Thanks
Edit:
I was able to reliably get to the actual document with the following.
CMS.DocumentEngine.TreeProvider tree = new CMS.DocumentEngine.TreeProvider();
var nodes = tree.SelectNodes(CMS.SiteProvider.SiteContext.CurrentSiteName, <path>, "en-us", false, <class name>, "NodeSKUID = '" + skuID + "'");
if (nodes != null)
{
CMS.DocumentEngine.TreeNode node = nodes.FirstOrDefault();
}