<%@page import="org.springframework.web.context.support.WebApplicationContextUtils"%> <%@page import="org.springframework.web.servlet.tags.MessageTag"%> <%@page import="org.xdams.workflow.bean.WorkFlowBean"%> <%@page import="java.util.Map.Entry"%> <%@page import="java.util.Map"%> <%@page import="org.xdams.utility.testing.TestingGeneric"%> <%@page import="java.util.Enumeration"%> <%@page import="org.xdams.xml.builder.XMLBuilder"%> <%@page import="java.net.URLEncoder"%> <%@page import="java.util.ArrayList"%> <%@page import="java.util.List"%> <%@page import="java.util.Hashtable"%> <%@page import="org.xdams.page.query.bean.QueryBean"%> <%@page import="org.xdams.user.bean.UserBean"%> <%@page import="org.xdams.conf.master.ConfBean"%> <%@taglib uri="/WEB-INF/xDamsJSTL.tld" prefix="xDamsJSTL"%> <%@taglib uri="http://www.springframework.org/tags" prefix="spring"%> <% ConfBean confBean = (ConfBean)request.getAttribute("confBean"); UserBean userBean = (UserBean)request.getAttribute("userBean"); WorkFlowBean workFlowBean = (WorkFlowBean)request.getAttribute("workFlowBean"); QueryBean queryBean = (QueryBean)request.getAttribute("queryBean"); System.out.println(queryBean); String thePne = workFlowBean.getArchive().getPne(); XMLBuilder builderQuery = confBean.getTheXMLConfQuery(); String perpage = "50"; try{ perpage = WebUtils.getCookie(request, "title"+workFlowBean.getAlias()+userBean.getId()).getValue(); }catch(Exception e){ //out.println("ERRORE"); } %> xDams - <%=workFlowBean.getArchive().getArchiveDescr()%>
<%@include file="../common/inc_menu.jsp" %>
<% int numeroSezione = builderQuery.contaNodi("/root/access_method/hierbrowse[@active='yes']"); String noElements = builderQuery.valoreNodo("/root/access_method/@noElements"); String withElements = builderQuery.valoreNodo("/root/access_method/@withElements"); String userValue = builderQuery.valoreNodo("/root/access_method/@userValue"); TestingGeneric testingGeneric = new TestingGeneric(); boolean isUserMod = true; if(!userValue.trim().equals("")){ isUserMod = testingGeneric.controllaLivello(workFlowBean,userValue.split(";")); } if(isUserMod && noElements.equals("insert") && queryBean.getTotNumDoc() == 0){ %><spring:message code=" /><% }else{ for(int i=0;i &docStart=<%=builderQuery.valoreNodo("/root/access_method/hierbrowse[@active='yes']["+(i+1)+"]/text()")%>"><%=builderQuery.valoreNodo("/root/access_method/hierbrowse[@active='yes']["+(i+1)+"]/@label")%><spring:message code=" /> <% } numeroSezione = builderQuery.contaNodi("/root/access_method/query[@active='yes']"); for(int i=0;i"><%=builderQuery.valoreNodo("/root/access_method/query[@active='yes']["+(i+1)+"]/@label")%><spring:message code=" /><% }else{ %>',document.theForm)"><%=builderQuery.valoreNodo("/root/access_method/query[@active='yes']["+(i+1)+"]/@label")%><spring:message code=" /><% } } if(isUserMod && withElements.equals("insert")){ %><spring:message code=" /><% } } %>
<%=queryBean.getTotNumDoc()%> <%=queryBean.getLastUpdate()%>
<% Map>> positionMap = (Map>>)request.getAttribute("positionMap"); Map>> positionAdminMap = (Map>>)request.getAttribute("positionAdminMap"); List outputHourField = (List)request.getAttribute("outputHourField"); List outputDataField = (List)request.getAttribute("outputDataField"); List outputSortField = (List)request.getAttribute("outputSortField"); for (Entry>> entry : positionMap.entrySet()) { String positionDiv = entry.getKey(); List> listOutput = entry.getValue(); if(positionDiv.equals("") || positionDiv.equals("center")){ for (int z = 0; z < listOutput.size() ; z++) { Map hashLabel = (Map)listOutput.get(z); for (Entry entryLabel : hashLabel.entrySet()) { String attrLabel = entryLabel.getKey(); String outputField = entryLabel.getValue(); %>
<%=outputField%>
<% } } }else if(positionDiv.equals("sx") || positionDiv.equals("left")){ %>
<% for (int z = 0; z < listOutput.size() ; z++) { Map hashLabel = (Map)listOutput.get(z); for (Entry entryLabel : hashLabel.entrySet()) { String attrLabel = entryLabel.getKey(); String outputField = entryLabel.getValue(); %>
<%=outputField%>
<% } } %>
<% }else if(positionDiv.equals("dx") || positionDiv.equals("right")){ %>
<% for (int z = 0; z < listOutput.size() ; z++) { Map hashLabel = (Map)listOutput.get(z); for (Entry entryLabel : hashLabel.entrySet()) { String attrLabel = entryLabel.getKey(); String outputField = entryLabel.getValue(); %>
<%=outputField%>
<% } } %>
<% } } %>
<% for (int z = 0; z < outputHourField.size() ; z++) { out.println((String)outputHourField.get(z)); } %>
<% for (int z = 0; z < outputDataField.size() ; z++) { out.println((String)outputDataField.get(z)); } %>
<% for (int z = 0; z < outputSortField.size() ; z++) { out.println((String)outputSortField.get(z)); } %>
:
<% String ultimeRicerche = ""; /* creazione bean di ricerca */ boolean valorizzato = false; if(session.getAttribute(workFlowBean.getQueryBeanName()) != null){ ArrayList arrQueryBean = (ArrayList)session.getAttribute(workFlowBean.getQueryBeanName()); for(int i = 0; i< arrQueryBean.size();i++){ QueryBean ilBean = (QueryBean)arrQueryBean.get(i); String ilDb = ilBean.getDb(); if(ilDb.equals(workFlowBean.getArchive().getAlias())){ valorizzato = true; String laQuery = ilBean.getQuery(); laQuery = laQuery.substring(laQuery.indexOf("]]")+2,laQuery.length()-1); String laQueryVis = ((laQuery.replaceAll("\\[","")).replaceAll("\\]","")).replaceAll("XML,","").replace('(',' ').replace(')',' '); String ilTot = ilBean.getTot(); ultimeRicerche+="\n"; } } } /* fine creazione bean di ricerca*/ if(valorizzato) ultimeRicerche = ""+ultimeRicerche; else ultimeRicerche = ""; %>
:
<% for (Entry>> entry : positionAdminMap.entrySet()) { String positionDiv = entry.getKey(); List> listOutput = entry.getValue(); if(positionDiv.equals("") || positionDiv.equals("center")){ for (int z = 0; z < listOutput.size() ; z++) { Map hashLabel = (Map)listOutput.get(z); for (Entry entryLabel : hashLabel.entrySet()) { String attrLabel = entryLabel.getKey(); String outputField = entryLabel.getKey(); %>
<%=attrLabel%>
<%=outputField%>
<%} } }else if(positionDiv.equals("sx") || positionDiv.equals("left")){ %>
<% for (int z = 0; z < listOutput.size() ; z++) { Map hashLabel = (Map)listOutput.get(z); for (Entry entryLabel : hashLabel.entrySet()) { String attrLabel = entryLabel.getKey(); String outputField = entryLabel.getValue(); %>
<%=attrLabel%>
<%=outputField%>
<%} } %>
<% }else if(positionDiv.equals("dx") || positionDiv.equals("right")){ %>
<% for (int z = 0; z < listOutput.size() ; z++) { Map hashLabel = (Map)listOutput.get(z); for (Entry entryLabel : hashLabel.entrySet()) { String attrLabel = entryLabel.getKey(); String outputField = entryLabel.getValue(); %>
<%=attrLabel%>
<%=outputField%>
<%} } %>
<% } } %>
<% String prefix = "/root/query/data/element"; int numField = builderQuery.contaNodi(prefix); if(numField>0){ %> ]" /> ]" value="" /> <%}%>
<%@include file="../common/inc_sub_menu.jsp"%>