Skip to Content
Apr 01, 2021 at 07:03 AM

Navigate to New Object Page with a new EntitySet in edit mode


I have added a button the List page of a Fiori Elements application and on click I'm navigating to a new object page with a new entity set. Following is my Navigate Internal:

var sObjectPath = this.getOwnerComponent().getModel().createKey("EntitySetName", { KeyField1: "" }); 

var oModel = this.getOwnerComponent().getModel(); 
var sObjectPath1 = oModel.createEntry("/" + sObjectPath); 


I'm facing following issues:

1. Navigation is Inconsistent - Refreshing the page gives an error "requested page cannot be found"

2. By default the page is navigated in Display page - We need it in Creatable/Edit mode for a new entry.

3. When sap:updatable is set to true, edit button appears on the page. Click Edit and enter the data, On click of SAVE there's no POST call