This topic contains 1 reply, has 0 voices, and was last updated by david.smith 7 years, 5 months ago.

  • Author
    Posts
  • #5613

    ultra7

    Hello,

    Like to semi-automate a report functionality where the users can have an automated process without having to update the formula every-time they want to run the saved search report. As I suspected, adding configuration into a custom filter into the saved search is not doable. So the way i thought was to build a custom field and call the saved search with a drop down field with a custom filter based on the vales selected in the filter. Unfortunately later on found out that is part of the limitations of NetSuite, as far as I know, does not have the ability to add a custom select field in a Suitelet list. Adding to that, there are fields set to Group in the saved search which Suitelet is unable to pull.

    This an ad-hoc process that the group uses if they want to execute a report for a previous month by updating a formula within the saved search (the values to -1) or so forth as you can see in the attachment. The request is that they liked to know if there is a drop down selection list to pull from the saved search where they can select the months they want to run. As you can see in my previous comment, having an issue to do that. I attached Suitelet script here. Any suggestions would be really great, if this can be done in the first place or some other alternative. If this can’t be done, they can always still go back to the way they been executing it.

    ************************************************** ************************************************** ************************************************** ************************************************** **************

    function LoadSuitelet(request, response) {

    try {

    var list = nlapiCreateList(‘PO Invoice Report’);

    list.setStyle(request.getParameter(‘style’));

    // add columns

    list.addColumn(‘document_number’,’text’,’Document Number’,’left’);

    list.addColumn(‘vendor_name’,’text’,’Vendor Name’,’left’);

    list.addColumn(‘customer’,’text’,’Customer’,’left’ );

    list.addColumn(‘po_type’,’text’,’PO Type’,’left’);

    list.addColumn(‘purchase_type’,’text’,’Purchase Type’,’left’);

    list.addColumn(‘po_total’,’text’,’PO Total’,’left’);

    list.addColumn(‘bill_amount’,’text’,’Bill Amount’,’left’);

    list.addColumn(‘bill_status’,’text’,’Bill Status’,’left’);

    list.addColumn(‘bill_delta’,’text’,’Delta Bill’,’left’);

    list.addColumn(‘mrc_total’,’text’,’MRC Total’,’left’);

    list.addColumn(‘invoice_number’,’text’,’Invoice Number’,’left’);

    var searchresults = nlapiSearchRecord(‘transaction’, ‘customsearch535’, null, null);

    nlapiLogExecution(‘DEBUG’, ‘searchresults’, searchresults.length);

    if(searchresults != null) {

    var columns = searchresults[0].getAllColumns();

    nlapiLogExecution(‘DEBUG’, ‘columns’, columns.length);

    for(var i=0; iThis is a cached copy. Click here to see the original post.

  • #5614

    david.smith

    Originally posted by ultra7

    View Post

    adding configuration into a custom filter into the saved search is not doable.

    What does “configuration” mean? You can add additional filters and columns to a saved search via script so I’m not sure I follow what you’re trying to do.

    It looks to me like you might just want to replace those formula columns with your dynamic dates? If so, just rewrite that one column in your script.

You must be logged in to reply to this topic.