So,
Perhaps I'm have 'Scripters Block', but does anyone have an example on how to inject the actual Button Function logic? In other words ... on a before submit of a record (in this case an item), I add a button.
context.<span style="color:'#660e7a'"><strong>form</strong></span>.<span style="color:'#7a7a43'">addButton</span>({ <span style="color:'#660e7a'"><strong>id</strong></span>: <span style="color:'#008000'"><strong>'custpage_generate_rpt'</strong></span>, <span style="color:'#660e7a'"><strong>label</strong></span>: <span style="color:'#008000'"><strong>'Generate Report'</strong></span>, <span style="color:'#660e7a'"><strong>functionName</strong></span>: <span style="color:'#008000'"><strong>'generateFromPublication()' </strong></span>}); Now, how to I inject my code for generateFromPublication()?The logic there is simple generateFromPublication(){ <span style="color:'#484848'"><span style="font-family:'monospace'">redirect</span></span><span style="color:'#000080'"><span style="font-family:'monospace'"><strong>.toSuitelet</strong></span></span><span style="color:'#484848'"><span style="font-family:'monospace'">(</span></span><span style="color:'#484848'"><span style="font-family:'monospace'">{ [COLOR=#0000FF]<strong>scriptId</strong></span>:<span style="color:'#008000'"><strong> [COLOR=#0000FF]31</span> , deploymentId: <span style="color:'#0000FF'">1</span>, parameters: {'custparam_test':'helloWorld'</strong>[/COLOR]</span>[/COLOR]<span style="color:'#484848'"><span style="font-family:'monospace'">} }</span></span><span style="color:'#008000'"><strong> </strong></span>} I'd knock this out in SS 1.0 in about 5 mins, can some one shed some light with an example? I just need a button that will redirect me to a Suitelet (with a few parameters)