Results 1 to 4 of 4

Thread: ExJs 5.1 bootstrap bug

    Thank you for reporting this bug. We will make it our priority to review this report.
  1. #1
    Sencha User yeghikyan's Avatar
    Join Date
    Mar 2009
    Location
    München
    Posts
    574

    Default ExJs 5.1 bootstrap bug

    Hallo,
    first of all I would like to thank you for developing the great ExtJs framework. It is really good product.
    Unfertunately after update from 5.0 to 5.1 the same bug arrived.
    In case the index.html file located in another directory, not the same as ext library the bootstrap continues to load data from the same directory.
    Before this bug existed in 5.0.1 version and was fixed but afterwords the fix was droped.
    Please have a look at the "loadSyncBasePrefix" and "loadBasePrefix" (there are "prependBaseUrl" property which was used to fixed the bug... now this two methods are not called at all. In the method "loadSync" this mechanism is missing.

    bug in 5.0 is located http://www.sencha.com/forum/showthre...bootstrap.json

  2. #2
    Sencha User
    Join Date
    Feb 2013
    Location
    California
    Posts
    11,985

    Default

    Thanks for the report. Can you please post a test case which reproduces the issue you are seeing?
    https://fiddle.sencha.com/#home

  3. #3
    Sencha User yeghikyan's Avatar
    Join Date
    Mar 2009
    Location
    München
    Posts
    574

    Default

    Unfortunately the fiddle is not a correct place to reproduce such a bug.
    But you yourself can reproduce it just by moving index.html file to anothoer location, it must be not in the same directory where extjs lib located, somthing like
    /dir01/index.html
    /js/myExtJsProject/*

    after that change in app.json
    indexHtmlPath: "../dir01/index.html"
    -------------------------------------------
    Just look where are called in ./sencha/app/Boot.js (or in generated Bootstrap.js, which is included in index.html filed) these two methods: "loadSyncBasePrefix" and "loadBasePrefix", I think you will see that it is a dead methods.

    noch einmal, this two methods are not called at all.
    PHP Code:
    loadBasePrefix: function(request) {
        
    request = new Request(request);
        
    request.prependBaseUrl true;
        return 
    Boot.load(request);
    },

    loadSyncBasePrefix: function(request) {
        
    request = new Request(request);
        
    request.prependBaseUrl true;
        return 
    Boot.loadSync(request);
    }, 
    Regards
    A.

  4. #4
    Sencha User yeghikyan's Avatar
    Join Date
    Mar 2009
    Location
    München
    Posts
    574

    Default

    I have fixed the bug in "loadSync" method:

    PHP Code:
    load: function (request) {    //<debug>
        
    _debug("Boot.load called");
        
    //</debug>
        
    var request = new Request(request);

        if (
    request.sync === false || Boot.syncMode) { // Hier is fix one
            
    return Boot.loadSync(request);
        }

        
    // If there is a request in progress, we must
        // queue this new request to be fired  when the current request completes.
        
    if (Boot.currentRequest) {
            
    //<debug>
            
    _debug("current active request, suspending this request");
            
    //</debug>
            // trigger assignment of entries now to ensure that overlapping
            // entries with currently running requests will synchronize state
            // with this pending one as they complete
            
    request.getEntries();
            
    Boot.suspendedQueue.push(request);
        } else {
            
    Boot.currentRequest request;
            
    Boot.processRequest(requestfalse);
        }
        return 
    Boot;
    }, 
    PHP Code:
    loadSync: function (request) {    //<debug>
        
    _debug("Boot.loadSync called");
        
    //</debug>
        
    var request = new Request(request);
        
    request.prependBaseUrl true// <--- Hier is fix two
        
    Boot.syncMode++;
        
    Boot.processRequest(requesttrue);
        
    Boot.syncMode--;
        return 
    Boot;
    }, 
    but as you can see on the next upgrade this fix will be lost.

Tags for this Thread

Posting Permissions

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