How do i configure redirect rule?

ChuanYanF
Tera Guru

Dear experts,

I have a new problem here, so when a business user have submitted the risk event record, the system will bring him back to the page where the list shows all the risk events, but I want the system to bring him to the page where it shows opened by him and the state is new just like the open events page module when the risk event is submitted how do i do this? Currently when I go into the create new page, and press the back or submit button it will redirect me to all risk event lists which I dont want to instead I want to go to the list with opened by is dynamic me and state is new.

 

1 ACCEPTED SOLUTION

Shubham_Jain
Mega Sage

@ChuanYanF 

 

Use UI Action 

 

(function executeRule(current, gForm, gS) {
    current.update();  // Saves the record
    
    var userId = gs.getUserID(); // Get current user ID
    var url = "/risk_event_list.do?sysparm_query=opened_by=" + userId + "^state=new";
    
    action.setRedirectURL(url); // Redirect to filtered list
})(current, gForm, gS);

✔️ If this solves your issue, please mark it as Correct.


✔️ If you found it helpful, please mark it as Helpful.



Shubham Jain


View solution in original post

3 REPLIES 3

Shubham_Jain
Mega Sage

@ChuanYanF 

 

Use UI Action 

 

(function executeRule(current, gForm, gS) {
    current.update();  // Saves the record
    
    var userId = gs.getUserID(); // Get current user ID
    var url = "/risk_event_list.do?sysparm_query=opened_by=" + userId + "^state=new";
    
    action.setRedirectURL(url); // Redirect to filtered list
})(current, gForm, gS);

✔️ If this solves your issue, please mark it as Correct.


✔️ If you found it helpful, please mark it as Helpful.



Shubham Jain


Do I create a new action or edit the existing one? Because I could not find the submit ui action under the risk event table.

@ChuanYanF 

 

create new one only if it is not available already. 

✔️ If this solves your issue, please mark it as Correct.


✔️ If you found it helpful, please mark it as Helpful.



Shubham Jain