Results 1 to 2 of 2

Thread: How to exchange data between two controllers

  1. #1
    Ext JS Premium Member
    Join Date
    Sep 2010
    Posts
    51

    Default How to exchange data between two controllers

    We are following MVC pattern for our application and jumping to other controller by 'this.application.runAction('Controllername', 'Index') '. is there any way to pass tha data between these two controllers?

    Regards,
    At
    AS

  2. #2
    Sencha Premium User mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    40,449
    Answers
    3997

    Default

    You can do it two ways...

    First (and my preferred) is fire an event on the application and have your controllers listen to these events. This allows your code not be tightly coupled with your app structure.

    Resolve the controller (getController method on the application) and execute a method on that controller.
    Mitchell Simoens @LikelyMitch
    Modus Create, Senior Fullstack Engineer
    ________________
    Modus Create is based on the model of an open source team. We’re a remote, global team of experts in our field. To find out more about the work we do, head over to our website.

    Check out my GitHub:
    https://github.com/mitchellsimoens

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •