Hi, one generic question about Suitelet with custo...
# suitescript
z
Hi, one generic question about Suitelet with custom form as result I want to create a form with multiple buttons, filter fields and one custom sublist (not NetSuite record….). Each button has “submit” function… When suitelet is loaded for the first time (URL in browser, or link from the menu), we know that GET method is executed. Later, clicking the button from the menu, values from the form are POSTed to the same SuiteLet…and here are the question: I want to “refresh” form, get new data for the sublist. I know there is no (easy) way to simulate AJAX style, it is OK to start create form every time when suitelet is executed, but I am sure what I should do in “POST” processing > recreate form or redirect or …. What are you doing in similar cases? Is it OK to use response.writePage() as response for POST method
b
depends on what your form has on it
the one major thing you need to know about suitelet forms is that netsuite does a GET to get select options when it does paging
👍 1
z
@battk yup, another topic... I noticed paging GET... and i would appreciate if you have a link to sample script how to handle paging select... I gave up with that and work without paging option ( i would be happy to have that on suitelet form)
the main point for question is experience : is there something bad-issue. etc if I use writePage as response when POST method is executed
b
there are general things associated with posts like refresh and back not working as nice
for the pagination, its actually not documented behavior
but you will need to look at the request's parameters to determine which field its asking for
👍 1
and then write a form containing that field
z
now, after learning @tdietrich SuiteQL Query, nothing else to say except : forget everything you did, start again with https://timdietrich.me/netsuite-suitescripts/suiteql-query-tool/downloads/