Edit C:\galaxie\deploy\Tomcat6\webapps\galaxie\js\frontoffice\knowledge_base_js.jsp
<%@page session="true"%> <%@ page import="com.edeal.frontline.navigation.FlRequest" %> <%@ page import="com.edeal.frontline.Utils" pageEncoding="UTF-8" %> <%@ taglib uri="http://www.e-deal.com/taglib/fl" prefix="fl" %><% FlRequest flRequest = new FlRequest(request); String deleteMode = flRequest.getRequestParameterOrAttribute("deleteMode"); String crtID = flRequest.getRequestParameterOrAttribute("CrtID"); response.setContentType("application/x-javascript"); %> function showFaq(id){ $.ajax({ url: "<fl:webapp/>/get_faq_score.fl?FaqID="+id, success:function(score){ $.openPopupLayer({ name: "Faq_"+id, width: "auto", height: "auto", url: "<fl:webapp/>/faq_popup.fl?id=" + id + "<%=(!Utils.isEmpty(deleteMode)? "&deleteMode="+deleteMode : "") %>" + "<%=(!Utils.isEmpty(crtID)? "&crtID="+crtID : "") %>" , cache: false, success: function (data) { _grid__FAQCMNTS_js_.render(); $('#popupLayerScreenLocker').height(($(document).height()) + "px"); $('#rating').ratings(5,score).bind('ratingchanged', function(event, data) { $.ajax({ url:"<fl:webapp/>/set_faq_score.fl?FaqID="+id+"&score="+data.rating, success:function(result) { $(".score_"+id).each(function(index){ $(this).html(result + " <fl:getMessage code="L70F0" alt="avis"/>"); }); } }); }); }, error: function () { alert("Erreur lors de l'ouverture de la popup !"); } }); } }); } function addComment(id){ if(($("#CmtTitle").val() == "") && ($("#CmtContent").val() != "")){ alert('<fl:getMessage code="M201C" alt="Veuillez spécifier un titre." js="true"/>'); return; } else if(($("#CmtContent").val() == "") && ($("#CmtTitle").val() != "")){ alert('<fl:getMessage code="M900E" alt="Veuillez spécifier un contenu." js="true"/>'); return; } else if(($("#CmtContent").val() == "") && ($("#CmtTitle").val() == "")){ $("#comments").attr("style","display:none;"); } else if(($("#CmtTitle").val() != "") && ($("#CmtContent").val() != "")){ var cmtTitle = encodeURI($("#CmtTitle").val()); var cmtContent = encodeURI($("#CmtContent").val()); var fields = {"CmtTitle": cmtTitle, "CmtContent": cmtContent}; var json = []; json[0] = {"type":"Comments","id":"cmtID","fields":fields}; var jsondata = JSON.stringify(json); $.ajax({ data: jsondata, type: "POST", timeout: 20000, contentType: "application/json;charset=utf-8", dataType: 'json', async: false, url: "<fl:webapp/>/add_faq_comment.fl?FaqID="+id, success:function(data){ //_grid__FAQCMNTS_js_.callAjaxForHtml(_grid__FAQCMNTS_js_.getAjaxUrl(),null,false,false,_grid__FAQCMNTS_js_callback,false,null); //$('#popupLayerScreenLocker').height($(document).height() + "px"); $("#CmtTitle").val(""); $("#CmtContent").val(""); $("#comments").attr("style","display:none;"); $("#nb_comments").html("<fl:getMessage code="L64B4" alt="Commentaires"/>("+data.nbComments+")"); } }); } } function showComments(){ _grid__FAQCMNTS_js_.callAjaxForHtml(_grid__FAQCMNTS_js_.getAjaxUrl(),null,false,false,_grid__FAQCMNTS_js_callback,false,null); } function _grid__FAQCMNTS_js_callback(arrIndex) { //if (eDealXmlhttpArr[arrIndex].readyState == 4) { $("#comments").attr("style","display:block;"); $("#popupLayerScreenLocker").height($(document).height() + "px"); $("#popup_closer").hide(); //} }
Ms-Dos/Windows
Unix
Write backup
jsp File Browser version 1.2 by
www.vonloesch.de