We're reclaiming inactive PDIs to keep them available for active builders. Learn what's changing, who's affected, and how to protect your work. Read More

Navigate internally without reloading using action assignment

Nolan4
Tera Contributor

Hi, 

I have put this code in the action assignment's client script - 

function onClick() {
    const projectSysId = g_form.getUniqueValue();
    const timestamp = Date.now(); // same as new Date().getTime()
 
    // Construct the proper Financials workspace URL
    var financialsURL = '/now/workspace/project/home/sub/pw-financials/pm_project/' +
        projectSysId + '/' + timestamp +
        '/params/page-name/financials';
 
    // Redirect user to the Financials section
    open(financialsURL, '_self');
}


This is working but the only thing here is, the page is completely reloading. Instead it should just navigate internally.

OR
If you know the solution using UXF client action.

 

 

2 REPLIES 2

Ankur Bawiskar
Tera Patron

@Nolan4 

what should happen when that button is clicked?

what's the source and what's the target once button is clicked?

Regards,
Ankur
Certified Technical Architect  ||  10x ServiceNow MVP  ||  ServiceNow Community Leader

Hi,

PFA image.
We are in the Details section and there is a Manage button on the cost plans related list. 
Upon clicking, it should navigate to the Financials section. 
The var financialsURL has the target url.