cancel
Showing results for 
Search instead for 
Did you mean: 

Wave 2 Navigation

Former Member
0 Kudos

Hello All,

  I need to add one custom view in timesheet (Wave 2 App) between the standard views, say  after s2 view. I was able to do it by adding new view in base project and configuring it in component.js. But I need to do this[adding custom view inbetween standard views and navigating from there] in an extension project w/o any changes in base project. I see that there are no options in toolkit for adding new view in extension project,we can do either modify/replace standard view. Any one got any idea how to do this? Any help will be immensely appreciated.

Thanks and Regards,

Muthu.

Accepted Solutions (1)

Accepted Solutions (1)

former_member206705
Participant
0 Kudos

Hi Muthu,

Please refer this document http://scn.sap.com/docs/DOC-52555 and follow the step "Use case: Adding a custom view (Q Issue Task Detail)"

Thanks and best regards,

Shilpa

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Shilpa,

Thanks for replying. I specified the viewPath in component.js but still navigation to my newview is not working out. From the document you shared above I see that new route has to be merged with  ComponentBase.js of the com.sap.ca.scfld.md library. But I am unable to find ComponentBAse.js and scfld librabry. Can you help me on this? Can we add one new view and route to it from standard S2 view of timesheet app.. Please correct me if my approach is wrong.Looking forward to your reply.


Thanks and Regards,

Muthu

Former Member
0 Kudos

Hi Shilpa,

  Thanks for replying. Actually I  was referring to the document you mentioned and was trying the scenario. I have added NewView

routing : {

  fullScreenPageRoutes : {

  "S2" : {

  "pattern" : "home",

  "view" : "S2"

  },

  "NewView" : {

  "pattern" : "",

  "view" : "NewView"

  },

  "S3" : {

  "pattern" : "detail/{context}",

  "view" : "S3"

  },

  "S31" : {

  "pattern" : "subdetail",

  "view" : "S31"

  }

  }

  },

in component.js as above and did controller extension as below

customizing: {

  "sap.ui.controllerExtensions": {

  "hcm.emp.mytimesheet.view.S2": {

  controllerName: "hcm.emp.mytimesheet.Z_TimesheetExt.view.S2Custom",

  },

  },

  }

I tried navigating from S2 to new view but its not happening[but the function is called ,as alert message is displayed ]. Kindly let me know, if I need to change the approach here.

Thanks and Regards,

-Muthu

agentry_src
Active Contributor
0 Kudos

Hi Muthu,

I would recommend taking a look at the Extensibility docs in the What is SAP Fiori UX? landing page.

Regards, Mike

SAP Customer Experience Group - CEG

former_member206705
Participant
0 Kudos

Hi Muthu,

During runtime, did you debug and check if your router object has the new route in the correct hierarchy? Also, like the document mentions, you'll be adding the newView.view.xml and newView.controller.js in the extension project. Since this is in a different path than the views in the base project, you'll have to specify the viewPath specifically (viewPath will be the path in the extension project where newView.view.xml exists). Please see the attachment.

Thanks and best regards,

Shilpa