Hello everyone, good day. I have a question. I hav...
# general
a
Hello everyone, good day. I have a question. I have a Suitelet that applies filters and populates a sublist for me, but I want to add a button on the POST form called 'Back' that returns me to the initial part of the Suitelet, the 'GET' part (refresh the suitlet). I tried using 'window.open', but it came out as 'undefined'. What is the correct way to do this? Thank you very much🙏
n
There's a few ways, in a client script a simple way is to update the location in the url .
Copy code
function startOver(){
        let suiteURL = url.resolveScript({
            scriptId: "customscript_your_script_id",
            deploymentId: "customdeploy_your_deployment_id"
        });
        NS.form.setChanged(false); // prevents NS complaining you are leaving the page
        document.location.href = suiteURL;     
    }
thanks 1
a
Thank you very much @NElliott, all your contributions have been very helpful to me! 🙏
🙇🏻‍♂️ 1