I'm trying to do dashboard portlet that will take a search criteria and execute a suitelet to do a highly custom search with many joins and return this list of results back to either the same or another portlet window on the dashboard and am running into a number of problems. Was hoping someone could help me understand what I can and can't do in this scenario.
1. When using an HTML portlet, can I not include script functions or call nlapi functions from within this html on the dashboard? I've tried (see example) and it returns an error "nlapiGetContext" is undefined and "mytestfunc" is undefined. However the alert works.
function portlet_test1(portlet,column) { portlet.setTitle('My Form'); var content = "<td><script type="text/javascript">function doit() { alert('here');var d = document.getElementById('csi_result'); alert('d='+d); d.innerHTML = "New Results!-"+(new Date()).getTime()+"";}</script>"; content += "<form method="POST" action="">"; content += "<input type="text" name="mytest" value="Testing..."/>"; content += "<input type="button" name="Submit" value="Submit" onclick="alert('ready!');var x=nlapiGetContext(); alert(x.getUser());var y=document.getElementById('csi_result');y.innerHTML='Hello';"/>"; content += "</form>"; content += "<hr/>"; content += "<div id="csi_result" style="text-align:top;scroll:auto;">No Results</div></td>"; portlet.setHtml(content); } 2. Is there a way to one of the following:a) have a search portlet that can populate a second portlet on the users dashboard with custom HTML results (an HTML table)?b) have a search portlet return results to itself and display them below (like inside a DIV tag or something)? 3. Is there some other way to do this (other than popping up a window with the results? Popping up a window is what we are doing now however this list of results has actionable links (like create customer record) and we want to redirect the user back to the dashboard after they perform the actionable item (can't redirect back to the popup very cleanly). Thanks.-Steve