AfterCreate entity redirect to another entity

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • alexS
    Junior Member
    • May 2018
    • 8

    AfterCreate entity redirect to another entity

    Hey guys,

    After I create a specific entity I need to redirect to another entity. Anyone knows how can i do that?

    Thanks
  • jakub.skowron
    Junior Member
    • Jan 2020
    • 21

    #2
    You can override exit method on desired view with someting like this :

    PHP Code:
    var url = '#' + this.scope + '/view/' + this.model.id;
    this.getRouter().navigate(url, {trigger: false});
    this.getRouter().dispatch(this.scope, 'view', {
    id: this.model.id,
    rootUrl: this.options.rootUrl,
    model: this.model,
    }); 
    

    Comment

    Working...