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

zk calls callback functions added by zk.afterLoad() in a different order when embedding a zul

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: Normal
    • Resolution: Unresolved
    • Affects Version/s: 9.6.2
    • Fix Version/s: None
    • Component/s: None
    • Labels:

      Description

      Steps to Reproduce

      1. run the zul, check developer tool > Console tab
      2. embed the zul from an HTML page (based on zkembedded-app)
      3. compare the loading order of 2 cases (not embedded, embedded)

      Current Result

      • embedded zul
        when zk calls a callback afterLoad('zk'), actually all package wpd files are already loaded.

      Expected Result

      either we can make the behavior consistent or document it

      Debug Information

      • since zk embed API puts the callback js (listener.js) at the end of the page. zk embed API ignores script directive, so there is no way to load the script earlier.

        But loading zul in a normal way (not-embedded), zk generates the script tag on the expected position we specified in a zul.

        Attachments

        1. js.jpg
          js.jpg
          60 kB
        2. minimal.html
          0.4 kB
        3. minimal.js
          0.5 kB
        4. zk-5226.js
          0.6 kB
        5. zk-5226.zul
          0.2 kB
        6. zul.jpg
          zul.jpg
          43 kB

          Activity

            People

            Assignee:
            Unassigned Unassigned
            Reporter:
            hawk hawk
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: