Uploaded image for project: 'ZK'
  1. ZK
  2. ZK-4185

Combobox: provide option to reduce onSelect/onChange events when using keyboard

XMLWordPrintable

    • Icon: New Feature New Feature
    • Resolution: Done
    • Icon: Normal Normal
    • 8.6.1
    • 8.6.0.1
    • Components
    • Security Level: Jimmy
    • None
    • ZK 8.6.1 S1
    • None

      Steps to Reproduce

        <combobox onSelect="Clients.log(event.toString())" onChange="Clients.log(event.toString())">
          <comboitem label="aaa"/>
          <comboitem label="bbb"/>
          <comboitem label="ccc"/>
        </combobox>
      

      use cursor DOWN to change the current selection to select 'ccc'

      Current Result

      everytime when pressing up/down an onSelect/onChange event is fired to the server
      (this doesn't happen when simply typing 'ccc', here the events only trigger during onBlur)

      When using the mouse it is possible to chose an element without firing the events for intermediate results

      Expected Result

      provide an options to disable eagerly sent events (and send event when leaving the combobox onBlur) For scenarios where only the final selection is required (and intermediate selections only trigger unwanted http requests)

      Debug Info

      this becomes especially more apparent when using autodrop="true", indicating more a preview than the actual selection before confirming with ENTER

      Root Cause

      ZK-2548 could be related

      Workaround

            rudyhuang rudyhuang
            cor3000 cor3000
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 1 day
                1d
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 day
                1d