Uploaded image for project: 'ZK Spring'
  1. ZK Spring
  2. ZKSPRING-58

Cannot reference ZUL file in "template" tag within a ZK/Spring Boot app

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • None
    • None
    • None

      Whilst trying to build my first Spring Boot/ZK web app using the newly released "https://github.com/zkoss/zkspringboot" I have stumbled across a major problem that blocks the use of template tags in a ZUL file

      See the "index.ZUL" file shown below:

      <zk>
          <apply templateURI="template_public.zul">
               <template name="header" src="header_public.zul" />
               <template name="main" src="main_index.zul" />
          </apply>
      
      </zk>
      
      

      I have the three zul files referenced in this template at the same folder level as 'index.zul., in a folder under resources of "web/zul/"

      When I run the app and then open up localhost:8080 I get the following error:

      "Page not found: /zul/template_public.zul"

      I presume that this is because the ZK 'template' tag Java code is looking for a physical location based around 'resource'. In reality the file is physically located at "/web/zul/template_public.zul"

      The Spring Boot ZK Logic assumes that all ZK files are under 'web', but the template tag code is not working on the same basis.

      I've ranked this as a major bug as I see the template idea as being a cornerstone of ZK capabilities

            Unassigned Unassigned
            davout davout
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: