<%@page import="com.ibm.tivoli.maximo.miniapps.control.HasExtraResources"%> <%@page import="com.ibm.tivoli.maximo.miniapps.control.WebResource"%> <%@page import="com.ibm.tivoli.maximo.miniapps.control.MiniAppControl.ClientEvent"%> <%@page import="com.ibm.tivoli.maximo.miniapps.control.MiniAppControl"%> <%@ include file="../../common/simpleheader.jsp"%> <% String waitlockId = component.getProperty("waitlockid"); boolean hasWait = (waitlockId!=null && waitlockId.trim().length()>0); String MINIAPP_ID=component.getProperty("appid"); MiniAppControl miniControl = (MiniAppControl) control; String MINIAPP_ENTRY_POINT = miniControl.getProperty("mainclass"); // passing an empty string return the miniapps ROOT dir for all miniapps String MINIAPP_ROOTURL=miniControl.getMiniAppRootDir(servletBase, ""); // returns the miniapp base url for THIS miniapp String MINIAPP_BASEURL=miniControl.getMiniAppRootDir(servletBase, MINIAPP_ID); String MINIAPP_DOMID = miniControl.createDOMId(MINIAPP_ID, MINIAPP_ENTRY_POINT); java.util.List extraPaths = miniControl.resolveExtraPaths(servletBase, MINIAPP_BASEURL); String width = miniControl.getProperty("width"); if (width==null) width="500px"; String height= miniControl.getProperty("height"); if (height==null) height="500px"; if ("100%".equals(height)) { System.out.println(MINIAPP_ID + ": MiniApps should not set height=100%. Consider using a fixed height, and resize the control using JavaScript."); //height="500px"; } boolean autosize = miniControl.getBoolean("autosize"); width = component.getWebClientSession().attachUOM(width); height = component.getWebClientSession().attachUOM(height); boolean hasProgress = miniControl.getBoolean("progressindicator"); String displayProgress=""; if (!hasProgress) { displayProgress="display:none"; } boolean singleInstance=component.getBoolean("singleinstance"); String singleInstanceId=component.getProperty("singleinstanceid"); String sessionUrlParam = wcs.getUISessionUrlParameter() + wcs.getCSRFTokenParameter(); %> <% if(designmode) { %> <%miniControl.loadDesigner(MINIAPP_ID); %> <% } else { if (component.needsRender()) { %>
loading..." align="middle" style="margin:0;position:absolute;top:50%;left:50%;margin-right:-50%;transform: translate(-50%,-50%);<%=displayProgress%>"/>
" id="<%=MINIAPP_DOMID%>" style="width:<%=width %>;padding:0px;margin: 0px;border: 0px">
<% } else { if (miniControl.hasClientEvents()) { %> <% } else { JSONObject evt = miniControl.getLastWebClientEventInstance(); evt.put("miniapp_id",MINIAPP_ID); evt.put("miniapp_entry_point",MINIAPP_ENTRY_POINT); %> <% } } } %> <%@ include file="../../common/componentfooter.jsp" %>