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

Clear user input doesn't sent a onChange and onSelect

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Normal
    • Resolution: Fixed
    • Affects Version/s: 8.0.0
    • Fix Version/s: 8.0.1
    • Component/s: None
    • Security Level: Jean
    • Labels:
      None
    • gh.sprint.customfield.default.name:
      ZK 8.0.1

      Description

      Steps to reproduce

      1. load zul
        <zk>
        <div apply="org.zkoss.bind.BindComposer" viewModel="@id('vm')@init('support.customization.T2407VM')">
        <combobox model="@load(vm.model)" selectedItem="@bind(vm.ourProp)"/>
        <button onClick="@command('onChange')"/>
        </div>
        </zk>
        
      2. select an item in the combobox with a mouse
      3. clear the item by pressing the "backspace"
      4. press the tab to blur it (or click outside from the combobox)

      Actual result

      no event sent. So selectedItem on the server doesn't change. But ZK 7 will send events below:

      dtid:z_y_90
      cmd_0:onChange
      uuid_0:z_3
      data_0:{"value":"","start":0}
      cmd_1:onSelect
      uuid_1:z_3
      data_1:{"items":[]}
      

      Debug info

      • in step 2, if selecting an item with the up and down key. Events are sent.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              DevChu DevChu
              Reporter:
              hawk hawk
              Votes:
              2 Vote for this issue
              Watchers:
              4 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 30 minutes
                  30m