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

Listbox Data Refresh throws errors within certain layout elements

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • 6.5.2
    • 6.0.0, 6.0.1, 6.0.2, 6.5.0, 6.0.3, 6.5.1, 6.0.4
    • Components
    • Tested using Java 1.6.0.35. Tomcat 6.0.32. Windows 7 development environment, also found on Windows Server 2003 test environment.

      A listbox that is within a Columnlayout that is also nested within a borderlayout throws an error "Failed to mount: this.parent._initDrag is not a function" on data refresh.

      This error is due to the following pattern of containers/objects.

      <borderlayout>
      <center>
      <columnlayout>
      <columnchildren>
      <listbox model="@load(vm.dataset)">
      ....
      </listbox>
      </columnchildren>
      </columnlayout>
      </center>
      </borderlayout>

      The initial load does not cause any problems. But once the data is refreshed, a window appears on the UI with the above error.

      If the columnlayout is removed as so:

      <borderlayout>
      <center>
      <listbox model="@load(vm.dataset)">
      ....
      </listbox>
      </center>
      </borderlayout>

      the error does not appear on data reload.

      I have attached a eclipse project that demonstrates the issue. The columnlayout as described is located on Line 80 of Main.zul. If that columnlayout is removed, the issue does not appear.

      This issue appears if data refresh is performed using either MVC or MVVM architecture.

      The included zip has source files only, but creating a new ZK Project and simply dropping in the src folders and the .zul should be enough to replicate the issue (as it has been for me).

            vincentjian vincentjian
            kryselmire kryselmire
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: