Editable combobox setting incorrect value

Posted by: pedro-antonio.vicente on 14 March 2018, 9:41 pm EST

  • Posted 14 March 2018, 9:41 pm EST

    There seems to be a problem when binding an editable combobox via the ngModel directive.

    HTML:

    
    <wj-combo-box
        [itemsSource]="['test1', 'test2', 'lorem', 'ipsum']"
        [(ngModel)]="attr"
        [wjModelProperty]="'text'"
        [isEditable]="true">
    </wj-combo-box>
    <button (click)="attr = 'T'">Modify to 'T'</button>
    <button (click)="attr = 'S'">Modify to 'S'</button>
    <div>Attr value: {{attr}}</div>
    
    

    Clicking the Modify to ‘S’ button will correctly modify the value in the input.

    However, Modify to ‘T’ will set the value to test1. Clicking it a second time will modify the attribute value to T but will not update the input’s value.

    It would seem the combobox’s autocomplete feature is intercepting the value and setting the first match found within the options list (thus why it shows test1 and not test2).

    Angular v5.2.3

    Wijmo v3.1.0

    I haven’t been able to find a workaround so far so any help is appreciated.

  • Posted 15 March 2018, 9:02 pm EST

    Hi,

    We were able to replicate the issue at our end and as you have already figured it out it’s due to auto complete feature.

    We have forwarded the concern to the devteam. The internal trackingID for case is 313812

    As a workaround if you want to change the display text as per your requirement you can set comboBox.inputElement.text=“your text” ;

    Refer to following code snippet:-

    <wj-combo-box #cb
        [itemsSource]="['alpha','test1', 'test2', 'lorem', 'ipsum']"
        [wjModelProperty]="'text'"
        [isEditable]="true"
        >
    </wj-combo-box>
    <button (click)="cb.inputElement.value='T'">Modify to 'T'</button>
    <button (click)="cb.inputElement.value='S'">Modify to 'S'</button>
    <div>combo box text: {{cb.text}}</div>
    
  • Posted 16 March 2018, 1:56 am EST

    Hi,

    Thank you for the quick response. Unfortunately, the workaround you propose is not something we can use.

    Am I then correct in assuming this is a bug and that you are working on a fix?

    Please do keep me posted if anything comes up regarding this issue.

  • Posted 17 March 2018, 4:50 am EST

    I have also the same problem so thanks for the valuable information https://mailhelp.net/ is a help support site as like you help us.

  • Posted 19 March 2018, 1:44 pm EST

    Yes,

    We have reported this as a bug. We will update you once this gets fixed.

  • Posted 3 April 2018, 7:51 pm EST

    Hi,

    Are there any news concerning this bug? An estimated fix date would be particularly invaluable as it is quite critical to us.

    Thanks.

  • Posted 4 April 2018, 10:17 pm EST

    Hi,

    I have asked the concerned team to look it, but I am unable to provide an ETA. I will update you regarding the same on monday

  • Posted 10 April 2018, 7:48 pm EST

    Hi,

    Any updates?

    Thanks.

  • Posted 11 April 2018, 2:06 pm EST

    Hi,

    This issue has been fixed in our latest nightly release . You can test this out by downloading the build from here . We do not suggest to use nightly builds in production environments.

    http://prerelease.componentone.com/wijmo5/

    This fix will be included in our next maintenance release.

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels