I have a web application that needs to use different layout depending where it is.
Basically, if I'm inside the page "Profile", I would like to use a specific app layout and a specific page layout. If I'm going to another page "Messages", I would like to use another app layout and another page layout. I need to combine them to render my page.
Is there a way to do something like that?
profile.js (view)
export default Ember.View.extend({
appLayoutName: 'appLayoutType1',
layoutName: 'pageLayoutType1',
templateName: 'profile'
});
messages.js (view)
export default Ember.View.extend({
appLayoutName: 'appLayoutType2',
layoutName: 'pageLayoutType2',
templateName: 'messages'
});
forums.js (view)
export default Ember.View.extend({
appLayoutName: 'appLayoutType1',
layoutName: 'pageLayoutType2',
templateName: 'forums'
});
Another detail, the route should not impact those changes. I shouldn't add a level in the route of my page to select the right layout.
Thanks!