Looks like we cannot reproduce this. Please provide another test case to reproduce this issue.
  1. #1
    Sencha Premium Member
    Join Date
    May 2011
    Posts
    33
    Vote Rating
    0
    mrinsan is on a distinguished road

      0  

    Default 4.2 Beta appFolder config Ext.application do not work properly

    4.2 Beta appFolder config Ext.application do not work properly


    Facing problem with Ext.application in 4.2 Beta
    i have my appFolder pointing to a different folder (not the default 'app' folder)

    It is a Java/web application
    and my ext application is sitting at client/desktop/app folder

    when i specify this setting in 4.2 beta
    while loading the controllers it seems to ignore this and trys to load them from the default app folder
    however views and stores are assumed to be present in the appFolder path specified in the Ext.application config

    this used to work fine with extjs 4.1 but broken in 4.2 beta

    i have a fairly complex app and see many layouts issues while adding/removing components dynamically.
    they work well in 4.1.

    will post the test cases as and when i get time and find out the issues

    Code:
    Ext.application({    name: 'MyApp',    launch: function () {        console.log('app launched');    },    appFolder: 'client/desktop/app',    controllers: [        'AppController',        'ChartController'    ]});

  2. #2
    Sencha User Stormseeker's Avatar
    Join Date
    Jan 2010
    Location
    Evanston, Illinois
    Posts
    55
    Vote Rating
    1
    Stormseeker is on a distinguished road

      0  

    Default


    I'm having a similar problem, however I am using the 'paths' config value. When the application loads, it is still looking for the source files to be the /apps/model/ect... folder.

    Basically, we don't have an apps folder. This was working for us in 4.1.0 and 4.1.1 but not in the 4.2 beta.

    Code:
    Ext.application({
        name                : 'QLP',
        paths                : {
            'Ext'                : '/javascript/extjs/src',
            'Ext.ux'            : '/javascript/extjs/examples/ux',
            'QLP'                : '.'
        },
        autoCreateViewport    : true
    });

  3. #3
    Sencha - Ext JS Dev Team
    Join Date
    Jun 2011
    Location
    San Diego, CA
    Posts
    226
    Vote Rating
    43
    nohuhu has a spectacular aura about nohuhu has a spectacular aura about nohuhu has a spectacular aura about

      0  

    Default


    Thanks for reporting, I'll look into it.

    Regards,
    Alex.

  4. #4
    Sencha - Ext JS Dev Team
    Join Date
    Jun 2011
    Location
    San Diego, CA
    Posts
    226
    Vote Rating
    43
    nohuhu has a spectacular aura about nohuhu has a spectacular aura about nohuhu has a spectacular aura about

      0  

    Default


    Can't reproduce this in current codebase. There was a bunch of changes to MVC since Beta 1, so I probably fixed it along. The fixes will be available in nightly builds for 4.2 once they're available (should be shortly), and of course in the next beta.

    Regards,
    Alex.

  5. #5
    Sencha User Stormseeker's Avatar
    Join Date
    Jan 2010
    Location
    Evanston, Illinois
    Posts
    55
    Vote Rating
    1
    Stormseeker is on a distinguished road

      0  

    Default


    Quote Originally Posted by nohuhu View Post
    Can't reproduce this in current codebase. There was a bunch of changes to MVC since Beta 1, so I probably fixed it along..
    I'm trying out Beta2 currently and things seem to be MUCH better. However I did notice a weird bug. It seems if you have some requires statements in the Ext.application config code, they are executed before the paths are resolved? Here is my code examples.

    Code:
    Ext.application({
        requires            : [
            'QLP.ux.window.DropDownMessage'
        ],
        name                : 'QLP',
        paths                : {
            'Ext'                : 'javascript/extjs/src',
            'Ext.ux'            : 'javascript/extjs/examples/ux',
            'QLP'                : 'javascript/crm2',
            'QLP.ux'            : '/apps/common/ux'
        },
        autoCreateViewport    : true,
       ...
    });
    Which gives me the following error in console:
    HTML Code:
    GET http://www.extcrm.com:8010/QLP/ux/window/DropDownMessage.js?_dc=1357920129233 404 (Not Found) ext-all-dev.js:10275
    Uncaught Error: [Ext.Loader] Failed loading 'QLP/ux/window/DropDownMessage.js', please verify that the file exists
    However I reference other files that in the QLP.ux namespace later on in the application and it seems to find them correctly. Not sure if this is a timing issue or if the requires isn't aware of the paths config.

    Thanks,
    Tim

  6. #6
    Ext JS Premium Member
    Join Date
    Mar 2007
    Location
    Germany
    Posts
    691
    Vote Rating
    25
    Dumbledore will become famous soon enough Dumbledore will become famous soon enough

      0  

    Default


    same here...

  7. #7
    Sencha - Ext JS Dev Team
    Join Date
    Jun 2011
    Location
    San Diego, CA
    Posts
    226
    Vote Rating
    43
    nohuhu has a spectacular aura about nohuhu has a spectacular aura about nohuhu has a spectacular aura about

      0  

    Default


    Huh, now that's definitely a bug. Thanks for spotting!

  8. #8
    Sencha - Ext JS Dev Team
    Join Date
    Jun 2011
    Location
    San Diego, CA
    Posts
    226
    Vote Rating
    43
    nohuhu has a spectacular aura about nohuhu has a spectacular aura about nohuhu has a spectacular aura about

      0  

    Default


    Hmm. Looks like this one is not as simple as it seemed. I'll have to shelf it; meanwhile you can work around this problem by calling Ext.Loader.setPath() before Ext.application(). Or, better yet, take a look at Sencha Cmd - that's the tool that is supposed to handle all pathing for you.

    Regards,
    Alex.

  9. #9
    Sencha User Stormseeker's Avatar
    Join Date
    Jan 2010
    Location
    Evanston, Illinois
    Posts
    55
    Vote Rating
    1
    Stormseeker is on a distinguished road

      0  

    Default


    Quote Originally Posted by nohuhu View Post
    Hmm. Looks like this one is not as simple as it seemed. I'll have to shelf it; meanwhile you can work around this problem by calling Ext.Loader.setPath() before Ext.application(). .
    Yup, I'm using the Ext.Loader.setPath() workaround but wasn't sure if it was going to cause problems later on. Looks good so far. I'm also using Sencha Cmd but didn't want to have to run a build every time I make a change to source. Thanks for the tips.

  10. #10
    Sencha Premium Member
    Join Date
    Oct 2008
    Posts
    40
    Vote Rating
    10
    lombardo will become famous soon enough

      0  

    Default


    I have the same error
    It fixed if we add the path for the app in the paths config of the Ext.loader, ie:

    Ext.Loader.setConfig({
    disableCaching: false,
    enabled: true,
    paths: {
    Ext: '.',
    Sepp: 'app'
    }
    });

    In version 4.1.3 it works..........but in 4.2 beta 2 it doesn´t work