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

Can't click-and-select any tree node in modal dialog window if included in JSP

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Normal Normal
    • 5.0.9
    • 5.0.7
    • General
    • IE 8 and Firefox 6.0.1
      Using JSP

      ZK code that get's opened in modal dialog box:

      <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
      "http://www.w3.org/TR/html4/loose.dtd">

      <%@ page language="java" pageEncoding="UTF-8"
      contentType="text/html;charset=utf-8"%>
      <%@ taglib prefix="zk" uri="http://www.zkoss.org/jsp/zul"%>

      <zk:variable-resolver
      use="org.zkoss.zkplus.spring.DelegatingVariableResolver" />
      <zk:init use="org.zkoss.zkplus.databind.AnnotateDataBinderInit" />

      <zk:page zscriptLanguage="java">

      <zk:window>
      <zk:tree id="tree" width="400px" rows="8">
      <zk:treecols sizable="true">
      <zk:treecol label="Name" />
      <zk:treecol label="Description" />
      </zk:treecols>
      <zk:treechildren>
      <zk:treeitem>
      <zk:treerow>
      <zk:treecell label="Item 1" />
      <zk:treecell label="Item 1 description" />
      </zk:treerow>
      </zk:treeitem>
      <zk:treeitem>
      <zk:treerow>
      <zk:treecell label="Item 2" />
      <zk:treecell label="Item 2 description" />
      </zk:treerow>
      <zk:treechildren>
      <zk:treeitem>
      <zk:treerow>
      <zk:treecell label="Item 2.1" />
      </zk:treerow>
      <zk:treechildren>
      <zk:treeitem>
      <zk:treerow>
      <zk:treecell label="Item 2.1.1" />
      </zk:treerow>
      </zk:treeitem>
      <zk:treeitem>
      <zk:treerow>
      <zk:treecell label="Item 2.1.2" />
      </zk:treerow>
      </zk:treeitem>
      </zk:treechildren>
      </zk:treeitem>
      <zk:treeitem>
      <zk:treerow>
      <zk:treecell label="Item 2.2" />
      </zk:treerow>
      <zk:treechildren>
      <zk:treeitem>
      <zk:treerow>
      <zk:treecell label="Item 2.2.1" />
      </zk:treerow>
      </zk:treeitem>
      </zk:treechildren>
      </zk:treeitem>
      </zk:treechildren>
      </zk:treeitem>
      <zk:treeitem label="Item 3" />
      </zk:treechildren>
      </zk:tree>

      </zk:window>

      </zk:page>

      Java code to open modal dialog box:

      Include topicDetailInclude = new Include();
      topicDetailInclude.setMode("auto");
      String detailIncludeSrc = "/M/" + currentMId
      + "/C.edit";
      topicDetailInclude.setSrc(detailIncludeSrc);

      // create a new window and set some attributes
      Window win = (Window) new Window();
      win.setTitle("Add New Category");
      win.setClosable(true);
      win.setWidth("360px");
      win.setHeight("320px");
      win.appendChild(topicDetailInclude);

      // attach to the main window
      win.setParent(t);

      win.doModal();

            tomyeh tomyeh
            sydd sydd
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0 minutes
                0m
                Logged:
                Time Spent - 1 hour
                1h