Navigate to record Form Page automatically

Hi community,

Is there any Low-Code possibilty to navigate directlty to Form Page of the created record?

Chain of events

1 - Mini Page is opened and data is entered

2- Mini Page Save evend is performed

3- After the record is created we navigate directly to the created record Form Page

 

Basically we need the symetric operation of this articel but for FreedomUI

https://customerfx.com/article/automatically-navigating-to-the-new-record-created-by-an-add-mini-page-in-creatio/

 

If there is no-code possibility, can you provide a code snippet how to achieve  it?

Sasor

Like 0

Like

1 comments
Best reply

For a no code approach - there really isn't an exact match, the closest possibility is the action "Continue in other page" which will open it in the default page for the entity type (assuming the mini page is set up as the "Add" page). However, that doesn't actually save the record first (just validates it).

For a code approach, you'd need to add a save request handler see here, then use: 

const saveResult = await next.handle(request);
if (saveRequest) {
	// navigate here
}
return saveRequest;

The navigate here part would use this and open the record in edit mode. 

Also, it likely would not be a good idea to do this in the base page for all mini pages, since dialogs can be used for different purposes, not like how it was for mini pages in classic (although I suppose you could check if the current mini page is in add mode).

Ryan 

For a no code approach - there really isn't an exact match, the closest possibility is the action "Continue in other page" which will open it in the default page for the entity type (assuming the mini page is set up as the "Add" page). However, that doesn't actually save the record first (just validates it).

For a code approach, you'd need to add a save request handler see here, then use: 

const saveResult = await next.handle(request);
if (saveRequest) {
	// navigate here
}
return saveRequest;

The navigate here part would use this and open the record in edit mode. 

Also, it likely would not be a good idea to do this in the base page for all mini pages, since dialogs can be used for different purposes, not like how it was for mini pages in classic (although I suppose you could check if the current mini page is in add mode).

Ryan 

Show all comments