1. #51
    Ext JS Premium Member
    Join Date
    Oct 2009
    Location
    Brisbane, Australia
    Posts
    30
    Vote Rating
    1
    elilindner is on a distinguished road

      0  

    Default


    Very nice plugin.

    Not sure if you can do this out of the box, but instead of returning a number of POST variables, I have created a small override to submit an array of values instead.

    PHP Code:
    Ext.override(Ext.ux.form.field.BoxSelect, {
        
    getSubmitData: function() {        var val = {};        val[this.name] = Ext.JSON.encode(this.getSubmitValue());        return val;    }
    }); 

  2. #52
    Ext JS Premium Member
    Join Date
    Dec 2007
    Posts
    215
    Vote Rating
    0
    ngd is on a distinguished road

      0  

    Default Prevent the combo-box height from growing

    Prevent the combo-box height from growing


    I would like the combo-box's height to remain unchanged as I have a space constraint. How do I do that?

    I tried a few css settings but a) doesn't work in all browsers and b) cursor doesn't move back to the first option.

    Any help will be be appreciated. Thanks again for some wonderful work.

  3. #53
    Sencha User
    Join Date
    Aug 2011
    Posts
    9
    Vote Rating
    0
    tommytob is on a distinguished road

      0  

    Default


    I must say it's a great plugin,

    but I have the same problem as smalltalker and ngd

    the panel/fieldset/... where the boxselect is into will not change the heigth

    greetz thomas

  4. #54
    Sencha User commanche's Avatar
    Join Date
    Jun 2008
    Location
    Prague, Czech Republic
    Posts
    20
    Vote Rating
    3
    commanche is on a distinguished road

      0  

    Default


    It's a nice extension, thanks for sharing it.

    However, there is a small problem when using it in "autocomplete" mode. If the user clicks at the input field to enter some text to be found, the trigger action is fired and the query tries to fetch all the records which is not desired. The query should be fired after certain number of letters (minChars) has been entered.

    I'd suggest adding a config option like triggerOnClick: true/false like this:

    Code:
        triggerOnClick: false,
    
        // skip
    
        onItemListClick : function(evt, el, o) {
            var me = this, itemEl = evt.getTarget('.x-boxselect-item'), closeEl = itemEl ? evt
            .getTarget('.x-boxselect-item-close') : false;
    
    
            if (me.readOnly || me.disabled) {
                return;
            }
    
    
            if (itemEl) {
                if (closeEl) {
                    me.removeByListItemNode(itemEl);
                } else {
                    me.toggleSelectionByListItemNode(itemEl, evt.shiftKey);
                }
                me.inputEl.focus();
            } else {
                if (this.triggerOnClick) {
                    me.onTriggerClick();
                }
            }
        },

  5. #55
    Sencha Premium Member
    Join Date
    Mar 2008
    Posts
    92
    Vote Rating
    1
    kveeiv is on a distinguished road

      0  

    Default


    I appreciate everyone's patience and wanted to just post a quick message to say that this extension is still being maintained and the contributions that have been made as well as some other bug fixes will be included in an update that will be coming in the next week. Thanks for everyone's support!

  6. #56
    Sencha User
    Join Date
    Aug 2011
    Posts
    9
    Vote Rating
    0
    tommytob is on a distinguished road

      0  

    Default


    I have the solution. You must not use the hbox but a column layout.

  7. #57
    Sencha User
    Join Date
    May 2010
    Posts
    28
    Vote Rating
    0
    sankarbaluz is on a distinguished road

      0  

    Exclamation How to give "displayFieldTpl"?

    How to give "displayFieldTpl"?


    Hi,
    Thanks for your great plugin.Could I understand that how we are giving "displayFieldTpl"?I am getting only the "displayField" in my combo.Please help me out from this.I given something like:
    Code:
    displayFieldTpl: '{ctrType} ({delFlg})'
    Regards,
    Sankar

  8. #58
    Ext JS Premium Member
    Join Date
    Mar 2008
    Location
    Phoenix, AZ
    Posts
    627
    Vote Rating
    9
    zombeerose will become famous soon enough zombeerose will become famous soon enough

      0  

    Default


    Two bugs when using emptyText config...

    1) Empty text is not displayed at all:
    Code:
    Ext.define('State', {
        extend: 'Ext.data.Model',
        fields: [
            {type: 'string', name: 'abbr'},
            {type: 'string', name: 'name'},
            {type: 'string', name: 'slogan'}
        ]
    });
    
    
    var states = [
        {"abbr":"AL","name":"Alabama","slogan":"The Heart of Dixie"},
        {"abbr":"AK","name":"Alaska","slogan":"The Land of the Midnight Sun"},
        {"abbr":"AZ","name":"Arizona","slogan":"The Grand Canyon State"}
    ];
    
    
    var statesStore = Ext.create('Ext.data.Store', {
        model: 'State',
        data: states
    });
    
    
    var singleSelect = Ext.create('Ext.ux.form.field.BoxSelect', {
        emptyText: 'States',
        fieldLabel: 'Select a state',
        renderTo: Ext.getBody(),
        displayField: 'name',
        width: 500,
        labelWidth: 130,
        store: statesStore,
        queryMode: 'local',
        valueField: 'abbr'
    });
    2) Error "me.value is null" when setting multiSelect to false.
    Code:
    Ext.define('State', {
        extend: 'Ext.data.Model',
        fields: [
            {type: 'string', name: 'abbr'},
            {type: 'string', name: 'name'},
            {type: 'string', name: 'slogan'}
        ]
    });
    
    
    var states = [
        {"abbr":"AL","name":"Alabama","slogan":"The Heart of Dixie"},
        {"abbr":"AK","name":"Alaska","slogan":"The Land of the Midnight Sun"},
        {"abbr":"AZ","name":"Arizona","slogan":"The Grand Canyon State"}
    ];
    
    
    var statesStore = Ext.create('Ext.data.Store', {
        model: 'State',
        data: states
    });
    
    
    var singleSelect = Ext.create('Ext.ux.form.field.BoxSelect', {
        emptyText: 'States',
        multiSelect: false,
        fieldLabel: 'Select a state',
        renderTo: Ext.getBody(),
        displayField: 'name',
        width: 500,
        labelWidth: 130,
        store: statesStore,
        queryMode: 'local',
        valueField: 'abbr'
    });
    Running version 1.1
    Last edited by zombeerose; 12 Sep 2011 at 11:35 AM. Reason: version

  9. #59
    Sencha Premium Member
    Join Date
    May 2007
    Location
    USA
    Posts
    73
    Vote Rating
    0
    notjoshing is on a distinguished road

      0  

    Default


    For lists with tens or even hundreds of items this works well. I've found it tends to bog down on larger lists, though. It may be a good idea to buffer the picker so that it only renders a limited selection at any given moment. What do you think?
    Using:
    ExtJS 2.2, 3.2, 4.0.7a
    WinXP SP3
    FF10,6; IE6; IE8; Safari

  10. #60
    Sencha Premium Member
    Join Date
    Mar 2008
    Posts
    92
    Vote Rating
    1
    kveeiv is on a distinguished road

      0  

    Default 1.2 released

    1.2 released


    1.2 has been released and the first post has been updated. Please see that post for a more complete list of updates. Many thanks go out to the many testing and coding contributions that have been made so far for this extension.

    Quote Originally Posted by zacware View Post
    #1 When typing in a state in the examples, like "Conn" for conneticut, and then hitting return, Conneticut is entered into the field but then the text "Conn" is still after it. If a match is found and the return key is pressed, the typed text showed go away (?)
    I have tied this behavior to the pinList: false configuration.

    Quote Originally Posted by zacware View Post
    #2 I tried using a store with a proxy to get data remotely and I load that using the .load() command on the store when I first create my form that the box select field is in. But if I try to use local query mode when I try to select an item from the list nothing shows up in the field after I click on a selection. If I switch to remote I am sent a query string on the server side which I can use to filter the list but I would prefer to let the store search the store that is already loaded rather than having to go to the server.
    Can you please try this with 1.2? If you're still able to duplicate it but unable to debug the problem, I will need a small example. What you describe is my most common use case, so this should be working.

    Quote Originally Posted by Smalltalker View Post
    When you select an item, the top of the control moves up
    Quote Originally Posted by ngd View Post
    I would like the combo-box's height to remain unchanged as I have a space constraint. How do I do that?
    Quote Originally Posted by tommytob View Post
    the panel/fieldset/... where the boxselect is into will not change the heigth
    Quote Originally Posted by tommytob View Post
    I have the solution. You must not use the hbox but a column layout.
    All of these comments should be addressed in 1.2. The component layout has been redone and should respect heights that are set by the containing layout, through the initial configuration, or directly manipulated through things like setHeight. As hbox is for fixed heights, if you want the field to grow you will want to use a column layout as you mentioned. Additionally, support for the grow/growMin/growMax configuration options has been added, so you should now be able to achieve any desired effects with regards to height and layout.

    Quote Originally Posted by elilindner View Post
    Not sure if you can do this out of the box, but instead of returning a number of POST variables, I have created a small override to submit an array of values instead.
    Thanks for the contribution! I have incorporated this functionality in to 1.2, configurable via the encodeSubmitValue option.

    Quote Originally Posted by commanche View Post
    However, there is a small problem when using it in "autocomplete" mode. If the user clicks at the input field to enter some text to be found, the trigger action is fired and the query tries to fetch all the records which is not desired. The query should be fired after certain number of letters (minChars) has been entered. I'd suggest adding a config option like triggerOnClick: true/false
    Thanks for the contribution! I have incorporated this functionality in to 1.2. I have defaulted this to 'true', but you can globally override this in your code by using Ext.ux.form.field.BoxSelect.prototype.triggerOnClick = false; if you find that matches more of your use cases.

    Quote Originally Posted by sankarbaluz View Post
    Hi,
    Thanks for your great plugin.Could I understand that how we are giving "displayFieldTpl"?
    This is not a valid ComboBox configuration according to the docs. If you would like to implement support for this type of functionality, contributions are always greatly appreciated!

    Quote Originally Posted by zombeerose View Post
    Two bugs when using emptyText config...
    1) Empty text is not displayed at all:
    2) Error "me.value is null" when setting multiSelect to false.
    Thanks for the report. I have fixed the logic associated to emptyText that was introduced in 1.1, and have added emptyText configurations in to the examples page to prevent this error from popping back up.

    Quote Originally Posted by notjoshing View Post
    For lists with tens or even hundreds of items this works well. I've found it tends to bog down on larger lists, though. It may be a good idea to buffer the picker so that it only renders a limited selection at any given moment. What do you think?
    I haven't used it, but I believe ComboBox's configuration of 'pageSize' is exactly what you're looking for. BoxSelect currently doesn't manipulate the picker at all, so if it works for ComboBox it should work fine for this component as well.

Thread Participants: 92

  1. scottw (1 Post)
  2. mysticav (2 Posts)
  3. JorisA (5 Posts)
  4. bobmanc (2 Posts)
  5. notjoshing (4 Posts)
  6. grgur (1 Post)
  7. ValterBorges (2 Posts)
  8. WebProgrammer (1 Post)
  9. Schlurcher (1 Post)
  10. zacware (2 Posts)
  11. ngd (8 Posts)
  12. radtad (2 Posts)
  13. zombeerose (13 Posts)
  14. nicholasnet (1 Post)
  15. themightychris (2 Posts)
  16. abraxxa (8 Posts)
  17. ttbgwt (1 Post)
  18. Psychokrameur (1 Post)
  19. commanche (1 Post)
  20. ernst96 (2 Posts)
  21. omarc (1 Post)
  22. qooleot (1 Post)
  23. foxmarco (1 Post)
  24. christophe.geiser (1 Post)
  25. wki01 (1 Post)
  26. purnama (1 Post)
  27. mediacept (1 Post)
  28. bareflix (2 Posts)
  29. User 0815 (1 Post)
  30. yuuzai (1 Post)
  31. talha06 (1 Post)
  32. xjpmauricio (1 Post)
  33. Smalltalker (1 Post)
  34. hazimdikenli (2 Posts)
  35. raz0r1 (1 Post)
  36. McQuack_82 (1 Post)
  37. elilindner (1 Post)
  38. hexawing (1 Post)
  39. maneljn (3 Posts)
  40. Tim Toady (2 Posts)
  41. alonweiss (1 Post)
  42. ubong (1 Post)
  43. salarmehr (5 Posts)
  44. koblass (1 Post)
  45. Karthikeyan.rajmohan (2 Posts)
  46. Reimius (1 Post)
  47. CSC-Germany (1 Post)
  48. sankarbaluz (2 Posts)
  49. alaley (2 Posts)
  50. navvn (2 Posts)
  51. danCTS (2 Posts)
  52. bentoo42 (1 Post)
  53. jmaia (2 Posts)
  54. maslofer (1 Post)
  55. sunaku (3 Posts)
  56. mrinsan (1 Post)
  57. yumaa (1 Post)
  58. rsqw (2 Posts)
  59. mahesh21688 (3 Posts)
  60. derditze (3 Posts)
  61. kunalshah6363 (1 Post)
  62. NatVik (1 Post)
  63. softwareguy (1 Post)
  64. alicexyl (7 Posts)
  65. under_dog (1 Post)
  66. tommytob (2 Posts)
  67. charlie17 (5 Posts)
  68. nathanrice (1 Post)
  69. srarnold (3 Posts)
  70. ettavolt (1 Post)
  71. qnens (1 Post)
  72. nikadod (3 Posts)
  73. PanchiKB (1 Post)
  74. Hooped (1 Post)
  75. dedoz (3 Posts)
  76. metas (1 Post)
  77. lindemann-medien (2 Posts)
  78. nathanmelis (1 Post)
  79. cyborat (1 Post)
  80. Forn (1 Post)
  81. gaurav.rehan (1 Post)
  82. Avman2119 (3 Posts)
  83. zzhouag (5 Posts)
  84. andreas-spindler (3 Posts)
  85. Alvaro L (1 Post)
  86. hown (1 Post)
  87. edson.hh (2 Posts)
  88. QuantumScripting (1 Post)
  89. chungns (1 Post)
  90. Delphine (1 Post)
  91. folivieri (1 Post)
  92. Lpsmash (1 Post)

Tags for this Thread

film izle

hd film izle

film sitesi

takipci kazanma sitesi

takipci kazanma sitesi

güzel olan herşey

takipci alma sitesi

komik eğlenceli videolar