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

ListModelList clear cause listbox to not add new listitems

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 9.6.0
    • 9.5.1, 9.5.1.3, 9.6.0
    • Components
    • Security Level: Jimmy
    • None

      Steps to Reproduce

      https://zkfiddle.org/sample/2crdgfr/2-Another-new-ZK-fiddle

      Open drop down, select an value

      Current Result

      Drop down is empty after update

      Expected Result

      Drop down contains "beep" "bop" after update 

      Debug Information

      Seem to happen after:

      https://github.com/zkoss/zk/commit/af6698a368b236824b70da2e6c237d9932378361#diff-45450f3948e27c39e03b7c9692a231a21a7c9397ad15faf3f10858bb7d337497R188

      Workaround

      create a new ListModelList instead of using clear(), and use notifyChange to replace the listmodel in the view.

            rudyhuang rudyhuang
            MDuchemin MDuchemin
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - 4 hours
                4h
                Remaining:
                Time Spent - 1 hour, 30 minutes Remaining Estimate - 2 hours, 30 minutes
                2h 30m
                Logged:
                Time Spent - 1 hour, 30 minutes Remaining Estimate - 2 hours, 30 minutes
                1h 30m