Edit C:\Windows\install\galaxie_p01_15-09\sales\person\read_consolidated.jsp
<% /****************************************************************************** * Copyright (c) 2000-2013 E-DEAL * * E-DEAL S.A. * 41, rue Périer * 92120 Montrouge * France * * T: +33 (0)1 73 03 29 80 * 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.navigation.FlRequest" %> <%@ page import="com.edeal.frontline.FlContext" %> <%@ page import="com.edeal.frontline.Utils" %> <%@ page import="com.edeal.frontline.FieldNotInitializedException" %> <%@ page import="com.edeal.frontline.DataDictionary" %> <%@ page import="com.edeal.frontline.EnterpriseBean" %> <%@ page import="java.util.Date" %> <%@ page import="java.util.Hashtable" %> <%@ page import="com.edeal.frontline.FrontlineException" %> <%@ page import="com.edeal.frontline.LocationBean" %> <%@ page import="java.util.Vector" %> <%@ page import="com.edeal.frontline.PersonEventBean" %> <%@ page import="com.edeal.frontline.FlLocale" %> <%@ page import="com.edeal.frontline.SalesInvestBean" %> <%@ page import="java.text.DateFormat" %> <%@ page import="org.apache.commons.lang.StringUtils" %> <%@ page import="com.edeal.frontline.initializers.PersonReadInitializer" %> <%@ page import="com.edeal.frontline.helper.ContextHelper" %> <%@ page import="com.edeal.frontline.helper.MultifunctionHelper" %> <%@ page import="java.util.List" %> <%@ taglib uri="http://www.e-deal.com/taglib/fl" prefix="fl" %> <jsp:useBean class="com.edeal.frontline.PersonBean" id="Person" scope="request"/> <% 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 salesModel = context.getContextParameter("SalesModel"); String id = null; try { id = Person.getID(); } catch (FieldNotInitializedException e) { } String perFctParentID = null; try { perFctParentID = Person.getPerFctParentID(); } catch (FieldNotInitializedException e) { } boolean hasEnterprise = false; if (!"B2C".equalsIgnoreCase(salesModel)) { try { EnterpriseBean enterprise = Person.getPerEnterprise(); hasEnterprise = true; pageContext.setAttribute("Enterprise", enterprise); } catch (FieldNotInitializedException e) { } } String oppType = null; try{ oppType = dico.getRefIdByCode("OppStoID", "ORD"); }catch(FrontlineException e){ oppType = ""; } /*Pour savoir si le groupe de fonctions appartient à une ASSoc*/ String typeFct = null; boolean affStrucAss = false; try{ typeFct = (String)Person.getCustomProperty("PerGrpFct_"); }catch(FieldNotInitializedException e){ typeFct = ""; } if(typeFct.equals(dico.getRefIdByCode("PerGrpFct_", "ASS"))){ affStrucAss = true; } String SfwID = flRequest.getRequestParameterOrAttribute("SfwID"); if (SfwID == null) { SfwID = ""; } StringBuffer fullName = new StringBuffer(); if (id != null) { String val; try { val = Person.getPerCivID(); fullName.append(dico.getRefDisp(session, "PerCivID", val) + " "); } catch (FieldNotInitializedException e) { } try { val = Person.getPerFstName(); fullName.append(val + " "); } catch (FieldNotInitializedException e) { } try { val = Person.getPerName(); fullName.append(val + " "); } catch (FieldNotInitializedException e) { } } String fullNameFormatted = Utils.formatToJavascript(fullName.toString()).trim(); String perFstName = null; try { perFstName = Person.getPerFstName(); } catch (FieldNotInitializedException e) { } String perName = null; try { perName = Person.getPerName(); } catch (FieldNotInitializedException e) { } String nameKey = ""; nameKey = perFstName != null ? perFstName + "+" + perName : perName; List<String> individualFieldsList = MultifunctionHelper.getFieldsForIndividual(context); %> <script type="text/javascript" language="javascript"> function doSearchPerson(url, name) { popupCenter(url, name, '930', '600', 'menubar=no, status=no, toolbar=no, scrollbars=yes, resizable=yes'); } function nbLinkCallBack(index) { if (eDealXmlhttpArr[index].readyState == 4) { var nbLink =eval(eDealXmlhttpArr[index].responseText); if (nbLink==0) { // no links => hide the div $("#linkscounter").hide(); } else { // let's display the div $("#linkscounter").show(); $("#linksnumber").html(nbLink); } hideWaiting(); } } function loadNbLink() { var ajaxURL = '<fl:webapp/>/per_links_count.fl?id=<%= id %>'; doAjax(ajaxURL, nbLinkCallBack); } runOnTime("loadNbLink();", 0); <% if (ContextHelper.hasMultifunction(context)) { %> $(document).ready(loadFunctionsBar); function loadFunctionsBar() { var url = "get_function_bar.fl"; var data = {id: '<%= id %>'}; $.ajax({ url: url , data: data, dataType:"html", //timeout: 5000, success: function(data, textStatus, jqXHR) { $("#function_bar").width(($("#function_bar").width() - 10) + "px"); $("#function_bar").html(data); //sortListInstall(); setTimeout(sortListInstall, 500); }, error: function(jqXHR, textStatus, errorThrown) { console.log("error :"); console.log("jqXHR :"); console.log(jqXHR); console.log("textStatus :"); console.log(textStatus); console.log("errorThrown :"); console.log(errorThrown); } }); } var JSperFctParentID = '<%= perFctParentID %>'; var NewJSperFctParentID = '<%= perFctParentID %>'; function sortListInstall() { //if ($("#sortlist").height() > 15) { $("#sortlist").sortable({ opacity: 0.6, revert: true, scrollSpeed: 80, tolerance: 'pointer', update: function(event, ui) { // var data = $(this).sortable("serialize"); var sortID = $("#sortlist li"); var itemID = new Array(); $("#sortlist li").each(function(i){ itemID.push($(this).attr('id')); }); NewJSperFctParentID = itemID[0]; var jsondata = JSON.stringify(itemID); //alert(jsondata); $.ajax ({ url : "<fl:webapp/>/set_functions_positions.fl?parentID="+JSperFctParentID, type : "POST", data : jsondata, timeout: 200000, contentType: "application/json;charset=utf-8", dataType: 'json', success: analyseResult, error:function (xhr, ajaxOptions, thrownError){ NewJSperFctParentID = JSperFctParentID; alert(xhr.status); alert(thrownError); } }); function analyseResult(data) { if (data != null) { if (data.ERROR != "") { NewJSperFctParentID = JSperFctParentID; alert('Erreur lors du déplacement \n' + decodeURIComponent(data.ERROR)); } else if (data.REFRESH == "OK") { JSperFctParentID = NewJSperFctParentID; loadFunctionBar(); } } } } }); //} else { // $("#sortlist").css("display", "none"); //} } <%}%> function list_log_web() { window.open('<fl:webapp/>/list_log_web.fl?id=<%= id %>', 'LogList', 'menubar=no,status=no,toolbar=no,scrollbars=yes,resizable=yes,width=700,height=350'); } function refreshCorrs() { _grid__CORR2LIST_js_.render(); } function refreshReservs() { _grid__RESVCONT_js_.render(); } function refreshCards() { _grid__CFD_CON_js_.render(); } function refreshChqs() { _grid__CQF_CON_js_.render(); } function refreshTrans() { _grid__TRN_CON_js_.render(); } function refreshContrs() { _grid__CTR_CON_js_.render(); } function refreshSolicitations() { _grid__SOL_CON_js_.render(); } function refreshOpps() { _grid__CMDCONTACT_js_.render(); } function refreshFcts() { _grid__FUNCLIST_js_.render(); } function refreshInts() { _grid__INTERPFCT_js_.render(); } function refreshQuals() { _grid__APPETFCT_js_.render(); } function refreshSols() { _grid__SOLFCT_EMB_js_.render(); } function refreshFunction() { _grid__FUNC_EMBST_js_.render(); } function refreshEvents() { _grid__EVTPERFCT_js_.render(); } function doRefreshEvents() { window.setTimeout(refreshEvents, 10); } function refreshLnks() { _grid__PerLin_js_.render("PerFullName",encodeURIComponent('<%= fullNameFormatted %>')); } function doLink() { if (navigator.appName == 'Microsoft Internet Explorer') { window.open('<fl:webapp/>/open_link_person.fl?perID=<%= id %>', 'LinkPer', 'menubar=no, status=no, toolbar=no, scrollbars=no, resizable=yes, width=800, height=230'); } else { window.open('<fl:webapp/>/open_link_person.fl?perID=<%= id %>', 'LinkPer', 'menubar=no, status=no, toolbar=no, scrollbars=no, resizable=yes, width=800, height=200'); } } function doLinkID(linID) { if (navigator.appName == 'Microsoft Internet Explorer') { window.open('<fl:webapp/>/open_link_person.fl?perID=<%= id %>&id=' + linID, 'LinkPer', 'menubar=no, status=no, toolbar=no, scrollbars=no, resizable=yes, width=800, height=230'); } else { window.open('<fl:webapp/>/open_link_person.fl?perID=<%= id %>&id=' + linID, 'LinkPer', 'menubar=no, status=no, toolbar=no, scrollbars=no, resizable=yes, width=800, height=200'); } } function delLink(linID) { if (confirm('<fl:getMessage code="M2004" alt="Etes-vous sûr de vouloir supprimer?" js="true"/>')) { doAjax('<fl:webapp/>/delete_object_ajax.fl?type=Link&id=' + linID, lnkDoReturn); } } function lnkDoReturn(arrIndex) { if (arrIndex && eDealXmlhttpArr[arrIndex].readyState != 4) { // we are in an ajax context if arrIndex is not null return; } window.setTimeout(refreshLnks, 10); } function markEvent() { window.open('<fl:webapp/>/edit_personevent.fl?initPerID=<%= id == null ? "" : id %>&fullName=' + encodeURIComponent('<%= fullNameFormatted %>') , 'MarkEvt', 'width=800,height=250,menubar=no,status=no,toolbar=no,scrollbars=auto,resizable=no'); } function editMarkedEvent(PvtID) { window.open('<fl:webapp/>/edit_personevent.fl?id=' + PvtID + '&initPerID=<%= id == null ? "" : id %>&fullName=' + encodeURIComponent('<%= fullNameFormatted %>') , 'MarkEvt', 'width=765,height=250,menubar=no,status=no,toolbar=no,scrollbars=auto,resizable=no'); } function deleteMarkedEvent(PvtID) { if (confirm('<fl:getMessage code="M6102" alt="Etes-vous sûr de vouloir supprimer ce marquage ?" js="true"/>')) { doAjax('<fl:webapp/>/delete_object_ajax.fl?type=PersonEvent&id=' + PvtID , delPvtCallback); } } function delPvtCallback(arrIndex){ if (eDealXmlhttpArr[arrIndex].readyState == 4) { hideWaiting(); eval(eDealXmlhttpArr[arrIndex].responseText); setTimeout('refreshEvents()', 10); } } function viewResponse(id){ window.open('<fl:webapp/>/read_formresponse.fl?id='+id, 'ViewFormResponse' , 'menubar=no,status=no,toolbar=no,scrollbars=no,resizable=yes,width=810,height=500'); } function previewScriptResponse(id, hasNotes, perID){ window.open('<fl:webapp/>/read_scriptresponse.fl?scriptID='+id+'&preview=0&lsePosition=0&hasNotes='+hasNotes+'&perID='+perID, 'PreviewFormResponse' , 'menubar=no,status=no,toolbar=no,scrollbars=no,resizable=yes,width=800,height=500'); } function doLoadPerson(perID) { window.location.href = '<fl:link list="true" menu="true" url="read_person_consolidated.fl"/>&id=' + perID; } function doOnLoad() { refreshFcts(); } </script> <fl:bigTabs listTitle="<%= Utils.getMessage(session, \"L63C2\", \"Liste des personnes\") %>" objectTitle="<%= Utils.getMessage(session, \"F002E\", false, true, \"Personne\") %>" ou="/read_person_consolidated.fl" showFooter="false"> <table class="container" cellpadding="0" cellspacing="0"> <tr class="fieldline"> <td colspan="5"> <table class="container" cellpadding="0" cellspacing="0"> <tr class="fieldline"> <td class="titreFiche" style="white-space: nowrap"> <%= fullName.toString() %> <span> <%@include file="/sales/person/socialNetWorkLinkList.jsp" %> </span> </td> </table> </td> </tr> <tr class="ligne_separation"> <td colspan="5"></td> </tr> </table> <link href="<fl:webapp/>/css/smalltabs_css.jsp" rel="stylesheet" type="text/css"> <fl:smallTabs name="EntRead"> <fl:sTab id="FCTS" title="<%= Utils.getMessage(session, \"L658A\", false, true, \"Fonctions\") %>" onselect="refreshFcts();"> <table class="container" cellpadding="0"> <tr> <td class="column2"> <table class="container" cellpadding="0"> <fl:fieldRead property="PerGrpFct_"/> <fl:fieldRead property="PerFctID"/> <fl:fieldRead property="PerTitle"/> <% if (hasEnterprise) { %> <fl:fieldRead property="PerEntID" separator="<br>" bean="true" href="true" disp="<%= flRequest.computeURL(\"/read_enterprise.fl\") %>"/> <% } %> <tr class="ligne_separation"><td></td></tr> <tr> <td class="titreInterneSmalltabs" colspan="5"> <fl:getMessage code="F6099" alt="Coordonnées"/> </td> </tr> <tr class="ligne_separation"><td></td></tr> <tr class="fieldline"> <td id="PerNumVoie__label" class="dataLabel"><fl:label code="FF02E" label="Voie"/></td> <td id="PerNumVoie__value" class="dataValue"><fl:getProperty name="Person" property="PerNumVoie_" alt=""/>, <fl:getProperty name="Person" property="PerNatVoie_" alt=""/> <fl:getProperty name="Person" property="PerLibVoie_" alt=""/></td> </tr> <fl:fieldRead property="PerBtq_"/> <fl:fieldRead property="PerCplGeo_"/> <fl:fieldRead property="PerAd1"/> <fl:fieldRead property="PerPremcou_"/> <fl:fieldRead property="PerBP_"/> <fl:fieldRead property="PerLieuDit_"/> <fl:fieldRead property="PerZip"/> <fl:fieldRead property="PerCity"/> <fl:fieldRead property="PerCtrID"/> <fl:fieldRead property="PerPhone"/> <fl:fieldRead property="PerMobile"/> <fl:fieldRead property="PerFax"/> <fl:fieldRead property="PerMail"/> <fl:fieldRead property="PerMailSec_"/> </table> </td> <td class="separation"><div class="separation"></div></td> <td class="column2"> <table class="container" cellpadding="0"> <tr> <td class="column2"> <table class="container" cellpadding="0"> <tr> <fl:fieldRead property="PerFctEntryDt"/> <fl:fieldRead property="PerFctExitDt"/> <fl:fieldRead property="PerNvComm_" valueCodeIfTrue="L2005" valueCodeIfFalse="L2006"/> <%-- A afficher seulement si le groupe de fonctions est "ASSOCIATION" --%> <% if (affStrucAss){ %> <tr class="ligne_separation"><td></td></tr> <tr> <td class="titreInterneSmalltabs" colspan="5"> <fl:getMessage code="LF04D" alt="Liste structure Logis"/> </td> </tr> <tr class="ligne_separation"><td></td></tr> <fl:fieldRead property="PerAffCatAss_" valueCodeIfTrue="L2005" valueCodeIfFalse="L2006"/> <fl:fieldRead property="PerColCatAss_"/> <fl:fieldRead property="PerOrdAff_"/> </tr> <tr> <fl:fieldRead property="PerOrdAff_"/> </tr> </table> <fl:notes name="PerAssRem_" title="<%= Utils.getMessage(session, \"L64B4\", \"Commentaires\") %>" nbPix="32"><fl:getProperty name="Person" property="PerAssRem_" alt=" " edit="false" /></fl:notes> <%} else { %> </tr> </table> <%}%> </td> <td class="column2"> <table class="container" cellpadding="0"> <tr class="fieldline"> <% if (ContextHelper.hasMultifunction(context)) { %> <td rowspan="1"> <div class="sc_menu" id="function_bar"></div> </td> <% } %> </tr> </table> </td> </tr> </table> </td> </tr> </table> </fl:sTab> <fl:sTab id="CORRESS" title="<%= Utils.getMessage(session, \"LF031\", false, true, \"Correspondances\") %>" onselect="refreshCorrs();"> <fl:grid name="CORR2LIST" ajaxUrl="<%= \"/embedded_list_ajax.fl?code=CORR2LIST&PerID=\" + id %>"> </fl:grid> </fl:sTab> <fl:sTab id="CTRS" title="<%= Utils.getMessage(session, \"LF032\", false, true, \"Contrats\")%>" onselect="refreshContrs();"> <fl:grid name="CTR_CON" ajaxUrl="<%= \"/embedded_list_ajax.fl?code=CTR_CON&PerID=\" + id %>"/> </fl:sTab> <fl:sTab id="OPPS" title="<%= Utils.getMessage(session, \"LF030\", false, true, \"Commandes\") %>" onselect="refreshOpps();"> <fl:grid name="CMDCONTACT" ajaxUrl="<%= \"/embedded_list_ajax.fl?code=CMDCONTACT&OppPerID=\" + id + \" &OppStoID=\" + oppType %>"/> </fl:sTab> <fl:sTab id="RESVS" title="<%=Utils.getMessage(session, \"LF02C\", false, true, \"Réservations\")%>" onselect="refreshReservs();refreshSols();"> <fl:grid name="RESVCONT" ajaxUrl="<%= \"/embedded_list_ajax.fl?code=RESVCONT&Rs_Contact=\" + id %>" /> </fl:sTab> <fl:sTab id="FIDS" title="<%=Utils.getMessage(session, \"LF033\", false, true, \"Fidélisations\")%>" onselect="refreshCards();refreshChqs();refreshTrans();"> <table> <tr> <td class="titreInterneSmalltabs" colspan="5"> <fl:getMessage code="FF147" alt="Cartes de fidélité"/> </td> </tr> <tr class="ligne_separation"><td></td></tr> </table> <fl:grid name="CFD_CON" ajaxUrl="<%= \"/embedded_list_ajax.fl?code=CFD_CON&Cd_Guest=\" + id %>"/> <table> <tr class="ligne_separation"><td></td></tr> <tr> <td class="titreInterneSmalltabs" colspan="5"> <fl:getMessage code="LF07F" alt="Chèques de Fidélité"/> </td> </tr> <tr class="ligne_separation"><td></td></tr> </table> <fl:grid name="CQF_CON" ajaxUrl="<%= \"/embedded_list_ajax.fl?code=CQF_CON&Cf_Guest=\" + id %>"/> <table> <tr class="ligne_separation"><td></td></tr> <tr> <td class="titreInterneSmalltabs" colspan="5"> <fl:getMessage code="LF080" alt="Transactions de fidélité"/> </td> </tr> <tr class="ligne_separation"><td></td></tr> </table> <fl:grid name="TRN_CON" ajaxUrl="<%= \"/embedded_list_ajax.fl?code=TRN_CON&Tf_Guest=\" + id %>"/> </fl:sTab> <fl:sTab id="SOLS" title="<%= Utils.getMessage(session, \"L652F\", false, true, \"Sollicitations\") %>" onselect="refreshSolicitations();"> <fl:grid name="SOL_CON" ajaxUrl="<%= \"/embedded_list_ajax.fl?code=SOL_CON&SolSolliciteurs_=\" + id %>"/> </fl:sTab> </fl:smallTabs> </fl:bigTabs>
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de