Results 1 to 5 of 5

Thread: Override generates error

  1. #1
    Sencha User
    Join Date
    Aug 2013
    Posts
    2

    Default Override generates error

    I've created an override for the PullRefresh plugin using Sencha Architect, but when I try to run the app it gives me an error in the console.
    Code:
    Ext.define('Test.override.plugin.PullRefresh', {
        override: 'Ext.plugin.PullRefresh',
        
        onLatestFetched: function(operation) {
            this.callParent(arguments);
            //Custom functionality
        }
    });
    Which gives me the following error when I try to run the app
    Code:
    Uncaught TypeError: Object #<Object> has no method 'define'PullRefresh.js:1
    Anyone know how I can get this to work? Thanks!

  2. #2
    Sencha Premium Member
    Join Date
    Nov 2007
    Location
    Sydney
    Posts
    117
    Answers
    3

    Default

    I'm seeing the same problem. Looks like the microloader is pulling it in before the rest of ExtJS?

    For now I work around this by creating my overrides outside of SA then adding it to the 'requires' section of the application.

  3. #3
    Sencha Premium Member
    Join Date
    Jul 2013
    Location
    Moscow, Russia.
    Posts
    243
    Answers
    4

    Default

    Try to turn on the "requireSDK" checkbox in the properties of the file with the override.

  4. #4

    Default

    Quote Originally Posted by tiulkin View Post
    Try to turn on the "requireSDK" checkbox in the properties of the file with the override.
    I do believe this is the correct solution - but I wanted to check in and confirm that doing so fixes the issue for ispieter and CaCtus491 - are you both all set with that solution?
    Steve Sobel
    @honestbleeps
    Sencha Architect Development Team

  5. #5
    Sencha Premium Member
    Join Date
    Nov 2007
    Location
    Sydney
    Posts
    117
    Answers
    3

    Default

    Sorry for the late reply.

    Yes, this works when an application is built, but doesn't seem to work when using the non-built version.

    The screenshot below shows the configuration I'm using for a simple TextArea override (so we can insert text at the cursor position).

    override.jpg

Posting Permissions

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