Hello,
We have developed a mobile application with remote views, where we are navigating between pages using app.navigate. I am now experimenting with the Router and want to set up a route for, say, '/things/:thingId' which displays the remote view 'views/thing-detail.html' for the correct thing (so we can address that particular page from an email, for instance). My code for the route set up is as follows:
This works, but when kendoApplication.navigate is called the URL is updated to #views/thing-detail.html, which is not what I want to happen (I want it to stay as /thing/123). In the SPA examples I have read, the views and layouts are constructed programmatically. If I want to use the router in this way, will I have to do the same, or is there a way to have the Router and Mobile Application work together (or am I going about this the wrong way!)?
We have developed a mobile application with remote views, where we are navigating between pages using app.navigate. I am now experimenting with the Router and want to set up a route for, say, '/things/:thingId' which displays the remote view 'views/thing-detail.html' for the correct thing (so we can address that particular page from an email, for instance). My code for the route set up is as follows:
application.router.route( "/things/:thingId", function ( thingId ) { var store = application.managedContext.getEntityStore( "things" ); store.find( thingId ) // potentially async call which returns a promise to return a thing .done( function ( thing ) { application.kendoApplication.navigate( "views/thing-detail.html" ); application.views.thingDetailViewModel.setSelectedThing( thing ); });});