Edit C:\galaxie\Back\galaxie\admin\requester\edit.jsp
<% /****************************************************************************** * 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. ******************************************************************************/ /* a.stouky@e-deal.ma : 18/08/06 paragraphe de champ à 2 colonnes : 1ère colonne: objet concerné + type de requête 2ème colonne: Code Requête dans les normes de "Note" Ajout d'un smallTab à 2 onglets Paramètres Dans le style d'un grid Commentaires */ %> <%@page session="true"%> <%@ page import="com.edeal.frontline.navigation.FlRequest" %> <%@ page import="com.edeal.frontline.DataDictionary" %> <%@ page import="com.edeal.frontline.FlContext" %> <%@ page import="com.edeal.frontline.FieldNotInitializedException" %> <%@ page import="com.edeal.frontline.CampaignBean" %> <%@ page import="com.edeal.frontline.Utils" %> <%@ page import="java.util.Vector" %> <%@ page import="com.edeal.frontline.ObjectsBean" %> <%@ page import="com.edeal.frontline.ActorBean" %> <%@taglib uri="http://www.e-deal.com/taglib/fl" prefix="fl" %> <jsp:useBean class="com.edeal.frontline.RequesterBean" id="Requester" 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 id = null; try { id = Requester.getID(); } catch (FieldNotInitializedException fnie) { } String reqRemarks = null; String[] reqParam = new String[9]; try { reqRemarks = Requester.getReqRemarks(); } catch (FieldNotInitializedException ex) {} try { reqParam[0] = Requester.getReqParam1(); } catch (FieldNotInitializedException ex) { reqParam[0] = null; } try { reqParam[1] = Requester.getReqParam2(); } catch (FieldNotInitializedException ex) { reqParam[1] = null; } try { reqParam[2] = Requester.getReqParam3(); } catch (FieldNotInitializedException ex) { reqParam[2] = null; } try { reqParam[3] = Requester.getReqParam4(); } catch (FieldNotInitializedException ex) { reqParam[3] = null; } try { reqParam[4] = Requester.getReqParam5(); } catch (FieldNotInitializedException ex) { reqParam[4] = null; } try { reqParam[5] = Requester.getReqParam6(); } catch (FieldNotInitializedException ex) { reqParam[5] = null; } try { reqParam[6] = Requester.getReqParam7(); } catch (FieldNotInitializedException ex) { reqParam[6] = null; } try { reqParam[7] = Requester.getReqParam8(); } catch (FieldNotInitializedException ex) { reqParam[7] = null; } try { reqParam[8] = Requester.getReqParam9(); } catch (FieldNotInitializedException ex) { reqParam[8] = null; } %> <script language="javascript"> var sendReqLookUp = true; var bool = true; function checkQuery() { var f = document.forms[0]; if (f.ReqQuery.value != '' ) { var cutStr = f.ReqQuery.value.toUpperCase().substring(0,6); //alert(cutStr); if (cutStr != 'SELECT') { bool = false; } else { bool=true; } } return bool; } function doSubmit(){ var bool = true; f = document.forms[0]; if (f.ReqTitle.value == ''){ alert('<fl:getMessage code="L63DC" alt="Veuillez saisir un Titre" js="true"/>'); f.ReqTitle.focus(); return } if (f.ReqCode.value == ''){ alert('<fl:getMessage code="L6144" alt="Veuillez saisir un Code" js="true"/>'); f.ReqCode.focus(); return } if (f.ReqQuery.value == ''){ alert('<fl:getMessage code="M6031" alt="Veuillez spécifier une requête SQL." js="true"/>'); f.ReqQuery.focus(); return }else{ var cutStr = f.ReqQuery.value.toUpperCase().substring(0,6); //alert(cutStr); if (cutStr != 'SELECT') { bool = false; alert('<fl:getMessage code="M60D3" alt="Requete doit commencer par \\\'SELECT \\\'" js="true"/>'); f.ReqQuery.focus(); return; }else{ bool = true; } } if (f.ReqTitle.value != ''&& f.ReqCode.value != ''&& bool){ presentFieldsValue(); f.submit(); } } function checkLookup(champ, index) { if (champ.value != '' && sendReqLookUp == true) { var url = '<fl:webapp/>/validate_req_query.fl?index=' + index + '&ReqLookUp=' + escape(champ.value); sendReqLookUp = false; doAjax(url); } } function doSelect(pFld) { var f = document.forms[0]; window.open('<fl:link url="/select_label.fl?1=1"/>&field=' + pFld, 'select_label', 'width=1000,height=500,menubar=no,status=no,resizable=yes'); } function doRemove(pFld) { var f = document.forms[0]; f.elements[pFld].value = ''; f.elements['lbl' + pFld].value = ''; } </script> <fl:form action="/save_requester.fl" bean="Requester"> <input name="$$presentFields" type="hidden" value=""/> <fl:bigTabs listTitle="<%= Utils.getMessage(session, \"L63CB\", false, true, \"Liste des requesters\") %>" objectTitle="<%= Utils.getMessage(session, \"L60E2\", \"Requester\") %>" ou="<%= \"/edit_requester.fl\" + (id != null ? \"?id=\" + id : \"\") %>"> <table class="container" cellpadding="0"> <tbody> <tr> <td colspan="3"> <table class="container" cellpadding="0"> <tr class="fieldline"> <td > <fl:label field="ReqTitle" labelClassName="labelTitreFiche"/> </td> <td class="fieldTitreFiche"> <fl:input property="ReqTitle" mandatoryMsgCode="L63DC"/> </td> </tr> </table> </td> </tr> <tr class="ligne_separation"><td></td></tr> <tr> <td class="column2"> <table class="data_column" cellpadding="0"> <fl:fieldEdit property="ReqObjID"/> <fl:fieldEdit property="ReqTyrID"/> </table> </td> <td class="separation"><div class="separation"></div></td> <td class="column2"> <table class="data_column" cellpadding="0"> <fl:fieldEdit property="ReqCode" mandatoryMsgCode="L6144" unicityMsgCode="M60CE"/> </table> </td> </tr> </table> <%--Les positions des champs de la requette --%> <table class="container" cellpadding="0"> <tr class="ligne_separation"><td></td></tr> <tr> <td class="column2"> <table class="data_column" cellpadding="0"> <fl:fieldEdit property="ReqPpePerID"/> <fl:fieldEdit property="ReqPpeEntID"/> <fl:fieldEdit property="ReqPpeJouID"/> </table> </td> <td class="separation"><div class="separation"></div></td> <td class="column2"> <table class="data_column" cellpadding="0"> <fl:fieldEdit property="ReqPpeSilID"/> <fl:fieldEdit property="ReqPpeSupID"/> <!-- fl:fieldEdit property="ReqCode" mandatoryMsgCode="L6144" unicityMsgCode="M60CE"/--> </table> </td> </tr> </table> <table class="container" cellpadding="0"> <tr class="ligne_separation"><td></td></tr> <tr> <td class="column2"> <table class="data_column" cellpadding="0"> <fl:fieldEdit property="ReqPpeFob1"/> <fl:fieldEdit property="ReqPpeFob2"/> <fl:fieldEdit property="ReqPpeFob3"/> <fl:fieldEdit property="ReqPpeFob4"/> <fl:fieldEdit property="ReqPpeFob5"/> </table> </td> <td class="separation"><div class="separation"></div></td> <td class="column2"> <table class="data_column" cellpadding="0"> <fl:fieldEdit property="ReqPopObj1"/> <fl:fieldEdit property="ReqPopObj2"/> <fl:fieldEdit property="ReqPopObj3"/> <fl:fieldEdit property="ReqPopObj4"/> <fl:fieldEdit property="ReqPopObj5"/> <!-- fl:fieldEdit property="ReqCode" mandatoryMsgCode="L6144" unicityMsgCode="M60CE"/--> </table> </td> </tr> </table> <table class="container" cellpadding="0"> <tr class="ligne_separation"><td></td></tr> <tr> <td class="titrePartie"><fl:getMessage code="L64B3" alt="Requête"/></td> </tr> <tr> <td><fl:input property="ReqQuery" onblur="checkQuery();" mandatoryMsgCode="M6031"/></td> </tr> <tr class="ligne_separation"><td></td></tr> <tr class="ligne_separation_couleur"><td></td></tr> <tr class="ligne_separation"><td></td></tr> </table> <link href="<fl:webapp/>/css/smalltabs_css.jsp" rel="stylesheet" type="text/css"> <fl:smallTabs name="RequesterTabs"> <fl:sTab id="Paramètres" title="<%= Utils.getMessage(session, \"L6070\", \"Paramètres\") %>"> <table class="container" cellpadding="0"> <tr> <td style="width: 15%;" class="headerDataGrid"></td> <td style="width: 30%;" class="headerDataGrid"> <fl:getMessage code="L6070" alt="Paramètres"/> </td> <td style="width: 30%;" class="headerDataGrid"> <fl:getMessage code="F603A" alt="LookUp"/> </td> <td style="width: 25%;" class="headerDataGrid"> <fl:getMessage code="F1023" alt="Type"/> </td> </tr> <% for(int i = 1; i < 10; i++) { String strLookUp = "ReqLookUp" + i; String strType = "ReqType" + i; String label = Utils.getMessage(session, reqParam[i - 1],""); if (label.equals("")){} %> <tr class="<%= i%2 == 0 ? "tabSimpleFdBlanc" : "tabSimpleFdBleu" %>"> <td><fl:getMessage code="F6039" alt="Paramètre"/><%= i %></td> <td id="ReqParam<%= i %>_value"> <input name="ReqParam<%= i %>" type="hidden" value="<%= reqParam[i - 1] == null ? "" : reqParam[i - 1] %>"> <input name="lblReqParam<%= i %>" class="input fob" type="text" value="<%= reqParam[i - 1] == null ? "" : Utils.getMessage(session, reqParam[i - 1],"") %>"> <a href="javascript:doSelect('ReqParam<%= i %>')"><img src="<fl:webapp/>/icons/ico/rechercher.gif" alt="" width="15" height="15" border="0"></a> <a href="javascript:doRemove('ReqParam<%= i %>')"><img src="<fl:webapp/>/icons/ico/supprimer.gif" alt="" width="15" height="15" border="0"></a> </td> <td id="ReqLookUp<%= i %>_value"> <input name="ReqLookUp<%= i %>" class="input text" maxlength="60" onblur="checkLookup(this, '<%= i %>');" type="text" value="<fl:getProperty name="Requester" property="<%= strLookUp %>" alt="" edit="true"/>"> </td> <td id="ReqType<%= i %>_value"> <select name="ReqType<%= i %>" class="select"> <fl:getProperty name="Requester" property="<%= strType %>" alt="" edit="true" type="select"/> </select> </td> </tr> <% } %> </table> </fl:sTab> <fl:sTab id="Commentaires" title="<%= Utils.getMessage(session, \"L64B4\", \"Commentaires\") %>"> <table class="container" cellpadding="0"> <tr class="ligne_separation"><td></td></tr> <tr> <td> <fl:input property="ReqRemarks"/> </td> </tr> </table> </fl:sTab> </fl:smallTabs> </fl:bigTabs> </fl:form>
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de