I\'d like to have a couple of different routes pointing to the same view/viewmodel and I have managed to make this happen.
{ route: \'formulation
I think your best bet is to override areSameItem
on the activator (which is created by the router as activeItem
). Somewhere early on in the wireup of your application, try doing this:
var routerAreSameItem = router.activeItem.settings.areSameItem;
router.activeItem.settings.areSameItem = function (currentItem, newItem, currentActivationData, newActivationData) {
debugger;
return routerAreSameItem.apply(this, _.toArray(arguments));
};
Obviously this particular implementation isn't going to do anything; but you should be able to provide some custom logic in the areSameItem
method to distingish the item change.
If my memory serves correctly, returning false
from that method should make your activate
method get called.