Skip to Content
Former Member
Oct 17, 2016 at 10:35 PM

JS in product cockpit


Does anyone have a chance to use external javascript libraries in zul files on widgets in productcockpit?

or in any related to *.zul files in zkoss 3.x framework ?

I tried to use it in such way: myWidget.zul

  <include src="/trailcockpit/js/test.zul" visible="true"/>


 <?xml version="1.0" encoding="UTF-8"?>
 <div visible="false" use="de.hybris.platform.cockpit.components.CustomCsaIncludeHelper">
     <script type="text/javascript">
     function works(){
         alert("JS works")

But! after first trying of execution I get Error: error than I press redraw button after this I trying execute it againe - and its works

But I cant understood: how avoid first part:(