<% /****************************************************************************** * Copyright (c) 2000-2005 e-Deal * * e-Deal S.A. * 55 rue Brillat Savarin * 75013 Paris * France * * T: +33 (0)1 53 80 80 30 * F: +33 (0)1 73 01 69 77 * http://www.e-deal.com * * La diffusion de ce code source sous quelque forme que ce soit sans * l'autorisation de E-DEAL est interdite. * * Vous êtes autorisés à modifier ce code source uniquement pour votre usage * propre et sous réserve que les mentions de copyright demeurent intactes. * * Ce code est fourni en l'état. Aucune garantie d'aucune sorte, explicite ou * implicite n'est donnée. En aucun cas E-DEAL ne pourra être tenu pour * responsable des dommages pouvant résulter de l'utilisation de ce code * source. ******************************************************************************/ %><%@page session="true" %> <%@ page import="com.edeal.frontline.FlContext" %> <%@ page import="com.edeal.frontline.DataDictionary" %> <%@ page import="com.edeal.frontline.navigation.FlRequest" %> <%@ page import="java.util.Vector" %> <%@ page import="java.util.Iterator" %> <%@ page import="java.util.Hashtable" %> <%@ page import="com.edeal.frontline.Utils" %> <%@ page import="com.edeal.frontline.controller.actions.Identical" %> <%@ page import="com.edeal.frontline.FieldBean" %> <%@taglib uri="http://www.e-deal.com/taglib/fl" prefix="fl" %><% final org.apache.commons.logging.Log logger = org.apache.commons.logging.LogFactory.getLog(getClass()); FlRequest flRequest = new FlRequest(request); FlContext context = flRequest.getContext(); DataDictionary dico = context.getDataDictionary(); String objType = (String) flRequest.getAttribute("objType"); String doublon = (String) flRequest.getParameter("doublon"); if (doublon == null) { doublon = "all"; } Vector similarObjs = (Vector)flRequest.getAttribute("vectIdentical"); if (similarObjs == null) { similarObjs = new Vector(); } Vector fields = (Vector)flRequest.getAttribute("fieldList"); if (fields == null) { fields = new Vector(); } int totalNbOfRecs = 0; if (flRequest.getAttribute("totalNbOfRecs") != null) { try { totalNbOfRecs = ((Integer) flRequest.getAttribute("totalNbOfRecs")).intValue(); } catch (Exception ex) { logger.error(ex); } } int totalNbOfPages = 0; if (flRequest.getAttribute("totalNbOfPages") != null) { try { totalNbOfPages = ((Integer) flRequest.getAttribute("totalNbOfPages")).intValue(); } catch (Exception ex) { logger.error(ex); } } int nbOfPage = 0; if (flRequest.getAttribute("numOfPage") != null) { try { nbOfPage = ((Integer) flRequest.getAttribute("numOfPage")).intValue(); if(nbOfPage > totalNbOfPages){ nbOfPage = totalNbOfPages; } } catch (Exception ex) { logger.error(ex); } } int seuilCert = 0; if (flRequest.getAttribute("seuilCert") != null) { try { seuilCert = ((Integer) flRequest.getAttribute("seuilCert")).intValue(); } catch (Exception ex) { logger.error(ex); } } %> ">
" class="search-button" id="valid-button">
<% if (similarObjs.size() > 0) { %>
<% if (nbOfPage > 1) { %> <% } %> <%= Utils.getMessage(session, "F608C", "Page") %> <%= nbOfPage + "/" + totalNbOfPages %><%= " - (" + totalNbOfRecs + ")" %> <% if (nbOfPage < totalNbOfPages) { %> <% } %>
<% } %> <% if (similarObjs.size() == 0) { %> <% } else { %> <% for (int i = 0; i < fields.size(); i++) { String codeLbl = null; try { codeLbl = dico.getFieldByName((String)fields.elementAt(i)).getFldDisplayLabel(); } catch (Exception e) { codeLbl = ""; } String altLbl = null; try { altLbl = dico.getFieldByName((String)fields.elementAt(i)).getFldDisplay(); } catch (Exception e) { altLbl = ""; } String fieldLbl = Utils.getMessage(session, codeLbl, altLbl); %> <% } %> <% boolean doColor = false; for (int i = 0; i < similarObjs.size(); i++) { Identical identical = (Identical)similarObjs.elementAt(i); String id = identical.getId(); Integer poids = identical.getPoids(); String objid1 = identical.getObj1id(); String objid2 = identical.getObj2id(); Hashtable obj1 = identical.getObj1(); Hashtable obj2 = identical.getObj2(); %> " valign="top"> <% for (int j = 0; j < fields.size(); j++) { Object valOfField = (Object) obj1.get(fields.elementAt(j)); %> <% } %> " valign="top"> <% for (int k = 0; k < fields.size(); k++) { Object valOfField = (Object) obj2.get(fields.elementAt(k)); %> <% } doColor = !doColor; %> <% if (i != similarObjs.size() - 1) {%> <% } %> <% } } %>
<%= fieldLbl %>
"> "/> Voir"> <%= valOfField.toString().length() > 50 ? valOfField.toString().substring(0, 50) : valOfField.toString() %>
"/> Voir"> <%= valOfField.toString().length() > 50 ? valOfField.toString().substring(0, 50) : valOfField.toString() %>