Success! Looks like we've fixed this one. According to our records the fix was applied for DSGNR-1279 in a recent build.
  1. #1
    Ext JS Premium Member Artistan's Avatar
    Join Date
    Apr 2007
    Location
    MN
    Posts
    144
    Vote Rating
    0
    Artistan is on a distinguished road

      0  

    Default Sencha Touch 2 Project using appFolder configuration continues to use default of app

    Sencha Touch 2 Project using appFolder configuration continues to use default of app


    http://visits.benint.net/visits/touc.../designer.html

    it is trying to load from folder "app" when clearly defined with a different name and appFolder.
    Code:
    Ext.application({
        appFolder: 'BenAdmin',
        autoCreateViewport: true,
        defaultUrl: 'http://visits.brokerbin.com/visits/touch/',
        name: 'BenAdmin',
    
        models: [
            'Visit',
            'VisitsStats',
            'VisitsSites',
            'VisitsList',
            'AllCompanies',
            'AllReps'
        ],
    
        stores: [
            'Visit',
            'VisitsStats',
            'VisitsSites',
            'VisitsList',
            'AllCompanies',
            'AllReps'
        ],
    
        controllers: [
            'Visits'
        ],
    
        launch: function() {
    
        }
    });

    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/model/Visit.js', please verify that the file exists[/COLOR]



    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/model/VisitsStats.js', please verify that the file exists[/COLOR]

    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/model/VisitsSites.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/model/VisitsList.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/model/AllCompanies.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/model/AllReps.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/controller/Visits.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/store/Visit.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/store/VisitsStats.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/store/VisitsSites.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/store/VisitsList.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/store/AllCompanies.js', please verify that the file exists[/COLOR]


    • [COLOR=red !important]sencha-touch-all-debug.js:4897Uncaught Error: [Ext.Loader] Failed loading 'app/store/AllReps.js', please verify that the file exists[/COLOR]


    [/COLOR]

  2. #2
    Sencha - Architect Dev Team aconran's Avatar
    Join Date
    Mar 2007
    Posts
    9,363
    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


    Thanks for the report. I know appFolder was removed from ST2 but then reintroduced recently. We will followup to determine if this is an SDK or Designer problem.

    Thanks,
    Aaron Conran
    @aconran
    Sencha Architect Development Team

  3. #3
    Sencha - Architect Dev Team aconran's Avatar
    Join Date
    Mar 2007
    Posts
    9,363
    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  
    Aaron Conran
    @aconran
    Sencha Architect Development Team

  4. #4
    Touch Premium Member
    Join Date
    Nov 2011
    Posts
    11
    Vote Rating
    0
    keithjjones is on a distinguished road

      0  

    Default


    Thank you for the quick reply on the other thread. I will continue writing here since the issue has already been classified as a bug. (You may want to jump to the last paragraph if you want my suggestion of a quick fix to this bug.)

    I looked at this bug thread but I think it's description is a bit different than the problem the author of the other thread and I brought up. The author of the other thread and I are trying to address having parent directories and in this thread the author seems to be claiming that appFolder does not work at all.

    I should have noted that I am using the standard Ext-JS v4 (not Touch) pointed to by default with Designer 2.0.0 build 268. Basically, the only way I can get my app to work correctly is to go into designer.js and add an appFolder property by hand with the full URL for the application. I have to do this *every* time I click save in Designer in order to bring up and test the web page that uses that application.

    Basically, like the first post stated on the other thread you referenced, it should work something like this:

    The user opens their browser and goes to:

    http://www.somedomain.com/SomeDirectory

    which through ASP provides the user's browser with HTML output and has a script tag in it to load something like:

    http://www.somedomain.com/Scripts/On...ps/designer.js.

    I have verified that part all happens correctly, but once designer.js is loaded it tries to load the stores and views of the application named "OneOfMySenchaApps" and they are being called without parent directories, such as:

    http://www.somedomain.com/app/store/MyJSONStore.js
    (which doesn't actually exist)

    instead of:

    http://www.somedomain.com/Scripts/On...MyJSONStore.js
    (whch is the correct URL).

    The solution is changing the appFolder property in designer.js (by hand each time you click save in Designer) to:

    appFolder: '/Scripts/OneOfMySenchaApps/app'

    which is pretty tedious, error prone, and time consuming.

    You can't place the string '/Scripts/MySenchaApp/app' in the Designer directly for the application's appFolder property because the '/' characters are not allowed by the Designer (plus Designer seems to rename some of the application's subdirectories automatically based upon its interpretation of the appFolder property, which may not actually address the original intent of the appFolder property).

    Does that make more sense? The problem I am describing is not about the default appFolder path and it being potentially being broken. I can get it to work but it just takes some hand editing to do so each time the project is saved.

    The quick fix? Enable special characters in the appFolder application property in Designer. Then, don't let Designer try to rename any subdirectories based upon the value of appFolder. Keep the subdirectory the same name as the the default "app" directory without renaming it. That would completely solve the issue, from what I can tell.

  5. #5
    Touch Premium Member
    Join Date
    Nov 2011
    Posts
    11
    Vote Rating
    0
    keithjjones is on a distinguished road

      0  

    Default


    I was wondering if you gentlemen had any other ideas that I did not think of for a workaround, even if it's just a temporary workaround until Designer v2 is updated, for the problem I presented above? Editing the designer.js by hand after every save is not fun. Thanks!

  6. #6
    Sencha - Architect Dev Team Phil.Strong's Avatar
    Join Date
    Mar 2007
    Location
    Olney, MD
    Posts
    1,925
    Vote Rating
    63
    Phil.Strong is just really nice Phil.Strong is just really nice Phil.Strong is just really nice Phil.Strong is just really nice

      0  

    Default


    @keithjjones It appears your right in that we need to be able to accept a path as well as a folder name here. In the end I suspect for production you'll be creating a single file and not using the loader at all in this manner.

    @Artistan It seems that after the designer version of sencha touch 2 was updated to beta1 the issue you were seeing went away. The link about does now resolve all the files correctly.
    Phil Strong
    @philstrong
    #SenchaArchitect
    Sencha Architect Development Team

  7. #7
    Touch Premium Member
    Join Date
    Nov 2011
    Posts
    11
    Vote Rating
    0
    keithjjones is on a distinguished road

      0  

    Default


    Thank you for your response. You are correct in that for production I will probably create a single file. However right now I'm developing so it's not that feasible to compile it to a single file to test it after every little change (which can be many times a day). Can you think of a better way than I suggested of getting around this issue other than hand editing designer.js to take the appFolder property correctly every time I click "save" in Designer?

    By the way - I love all the improvements in v2! It's going to save a lot of design time for me once I figure a way around this little bug.

  8. #8
    Sencha - Architect Dev Team Phil.Strong's Avatar
    Join Date
    Mar 2007
    Location
    Olney, MD
    Posts
    1,925
    Vote Rating
    63
    Phil.Strong is just really nice Phil.Strong is just really nice Phil.Strong is just really nice Phil.Strong is just really nice

      0  

    Default


    the quickest work around is to copy the designer.js file and name it index.js and change it one time in that file.

    the application is changed rather rarely once you get your project going. You can use source control to know when you need to update your index.js file w/ changes made in designer.js.

    Then wait for Designer update to make this easier. We're talking w/ the framework team to figure out the route for this
    Phil Strong
    @philstrong
    #SenchaArchitect
    Sencha Architect Development Team

  9. #9
    Touch Premium Member
    Join Date
    Nov 2011
    Posts
    11
    Vote Rating
    0
    keithjjones is on a distinguished road

      0  

    Default


    Great idea! I wouldn't have thought of that. Thanks for the tip!

  10. #10
    Touch Premium Member
    Join Date
    Nov 2011
    Posts
    11
    Vote Rating
    0
    keithjjones is on a distinguished road

      0  

    Default


    I am now using Version 2.0.0 build 298 (Release Channel 2.0-beta) and you can add slashes (/) to the appFolder which was exactly what I needed! Awesome! Thank you!

    Now, the problem is that Designer takes it upon itself to rename the subdirectories under the project to whatever you put in "appFolder" which completely defeats the bug fix (you can read my previous example above to see why this won't work). Is there any way to separate what the output directories are for the project from the value of appFolder to get this to work correctly?

    Thanks!

    Take care,
    Keith