1. #1
    Sencha User
    Join Date
    Aug 2011
    Posts
    8
    Vote Rating
    0
    lcurrens is on a distinguished road

      0  

    Default How to integrate your own controllers

    How to integrate your own controllers


    I have some legacy code that I want to be able to integrate as a Controller. I want to be able to add it to the Application in the "controllers:" stanza. I have it in the application filesystem under app/controller/MyFile.js, and if I add it to the application "controllers:"stanza then it gets initialized and I can access it with this.getApplication().getController('MyApp.controller.MyFile') for example.

    I cannot edit the Application file, and so I am having to do this by hand after every save to the filesytsem before I run the App. I would rather you let me edit that file and get myself in a ditch if I want to than to make me edit the file in the filesystem after every iteration.

    Same difficulty with the <application>.html file, I am having to edit that file every time to add the legacy Controller file. I would love to be able to just set that once and not have it over-ridden each time I save from Designer. Please add a little flexibility - maybe it can be default read-only, but you provide a way to override this. Otherwise the workarounds are too painful and time consuming (i.e. editing the files after each save of Designer).

  2. #2
    Sencha User
    Join Date
    Jun 2009
    Location
    Redwood City, CA
    Posts
    197
    Vote Rating
    6
    CaliLuke is on a distinguished road

      0  

    Default


    It's a pain I experienced first hand while working on Designer too, we get it. Over time, all of that will get implemented, there's much to do but we're not ignoring the problem.

    I know it's not much to go on, but I hope this reassures you we're on the ball.
    --
    Luca Candela
    twitter: @luckymethod

  3. #3
    Sencha - Architect Dev Team aconran's Avatar
    Join Date
    Mar 2007
    Posts
    9,358
    Vote Rating
    128
    aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold aconran is a splendid one to behold

      0  

    Default


    As Luca said we are aware of these issues and working on it. My current recommendation would be to duplicate designer.js and designer.html into index.js and index.html. We will not touch any new files that you add. These files change so infrequently that you will just have to synchronize them with the changes you want when it happens.
    Aaron Conran
    @aconran
    Sencha Architect Development Team

Thread Participants: 2

Tags for this Thread