<div dir="ltr">Use getAssociatedProducts function  in include/utils/EditViewUtils.php<div><br></div><div><div>$focus = CRMEntity::getInstance($module);</div><div>$focus->id = $recordId;</div><div>$related_products<span class="" style="white-space:pre">       </span>= getAssociatedProducts($module,$focus);</div><div><br></div><div><br></div></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><br>Regards,<br>Lajeesh<br></div></div>
<br><div class="gmail_quote">On Thu, Feb 5, 2015 at 3:53 PM, Uma S <span dir="ltr"><<a href="mailto:uma.s@vtiger.com" target="_blank">uma.s@vtiger.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Hi,<div><br></div><div>Using getProducts() api on Inventory record model, will get information regarding line-items linked with inventory modules (SalesOrder/ Quotes/ Invoice/ PurchaseOrder).</div></div><div class="gmail_extra"><div><div class="h5"><br><div class="gmail_quote">On Thu, Feb 5, 2015 at 1:11 PM, Alan Lord <span dir="ltr"><<a href="mailto:alanslists@gmail.com" target="_blank">alanslists@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><span>On 04/02/15 22:22, Richard Hills - Technologywise wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
I am now doing this as follows:<br>
<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
                include_once 'modules/Quotes/<u></u>QuotePDFController.php';<br>
                $controller = new Vtiger_QuotePDFController('<u></u>Quotes');<br>
$controller->loadRecord(vtlib_<u></u>purify($request->get('quote'))<u></u>);<br>
                foreach($controller-><u></u>associated_products as $lineitem)<br>
...<br>
</blockquote>
Happy to hear of any better methods.<br>
</blockquote>
<br></span>
I haven't looked at the Quote/Inventory design but I would have thought you should be simply getting the Record model for the Quote/SalesOrder/Invoice. I would have assumed that the line item data will be present (or accessible) in the Record itself.<br>
<br>
HTH<br>
<br>
Al<br>
<br>
<br>
______________________________<u></u>_________________<br>
<a href="http://www.vtiger.com/" target="_blank">http://www.vtiger.com/</a><br>
</blockquote></div><br><br clear="all"><div><br></div></div></div><span class="HOEnZb"><font color="#888888">-- <br><div><div dir="ltr">With<br>Best Regards<br>Uma.S<br><div>Vtiger Team</div></div></div>
</font></span></div>
<br>_______________________________________________<br>
<a href="http://www.vtiger.com/" target="_blank">http://www.vtiger.com/</a><br></blockquote></div><br></div></div>