Results 1 to 4 of 4

Thread: Problem with event fireing

  1. #1
    Sencha User
    Join Date
    Nov 2011
    Posts
    16
    Answers
    1

    Default Problem with event fireing

    I've ported my app form extjs 4.1 to 5.0
    I've a problem with events

    my controller:
    Code:
    Ext.define('Docu.controller.Auth', {
      extend: 'Core.Controller',
      stores: [],
      init: function() {
        this.control({
          'LoginForm': {
            doLogin: function () {
              console.log('do login'); <--- dont fires
            },
            render: function () {
              console.log('render'); // <--- this fires OK
            }
          }
        });
    
    
    
    
    
    
      }...

    my view:
    Code:
    Ext.define('Docu.view.LoginForm', {
      extend: 'Ext.Window',
      alias: 'widget.LoginForm',
      requires: ['Ext.form.field.Text', 'Core.plugins.Autocomplete'],
    ...
      initComponent : function () {
        var component = this;
    ....
          buttons: {
            items:        [
              {
                text: '????',
                scope: this,
                id: login_button_id,
                formBind : true,
                handler: function() {
                  var params = formPanel.getForm().getValues();
                  component.fireEvent('doLogin', params); <--- fire my event
                }
              },
    In extjs 4.1 it was fine. But not for 5.0

    What should I use?

  2. #2
    Sencha User
    Join Date
    Nov 2011
    Posts
    16
    Answers
    1

    Default

    I found that if I use 'doLogin' event it is not calling. If i do 'dologin' --- it's all right!

  3. #3
    Sencha Premium User
    Join Date
    Nov 2010
    Location
    Chicago
    Posts
    2,339
    Answers
    20

    Default

    Quote Originally Posted by noway View Post
    I found that if I use 'doLogin' event it is not calling. If i do 'dologin' --- it's all right!
    See this Q&A

  4. #4
    Sencha User
    Join Date
    Nov 2011
    Posts
    16
    Answers
    1

    Default

    thank you!

Posting Permissions

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