170 lines
8.5 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<%@ page import="org.apache.commons.lang3.StringUtils" %>
<%@ page contentType="text/html; charset=GBK"%>
<%@ include file="/Frame/resources/include/include_begin_info.jspf"%><%
/*
Author: undefined 2017-06-17
Content: 示例详情页面
History Log:
*/
String orgId = CurUser.getOrgID();
String ishistory = CurPage.getParameter("IsHistory");
String flowunid = CurPage.getParameter("FlowUnid");
String contractId = CurPage.getParameter("ContractId");
String compClientID = CurPage.getParameter("CompClientID");
String phaseNo = CurPage.getParameter("PhaseNo");
String ProductId = CurPage.getParameter("ProductId");
String productid = Sqlca.getString("select PRODUCT_ID from LB_CONTRACT_INFO_TEMP where flowunid = '"+flowunid+"'");
String projectId = CurPage.getParameter("ProjectId");
String gpsVendor = Sqlca.getString("select cl.itemname from lb_project_info lpi left join LM_GPS_ORDER lgr on lgr.apply_no=lpi.project_no left join code_library cl on cl.itemno=lgr.source and cl.codeno='gpsVendor' where lpi.id='"+projectId+"'");
String userId = CurUser.getUserID();
//gps来源 中瑞1 天易0
String source = Sqlca.getString("SELECT SOURCE from LM_GPS_ORDER where PROJECT_ID='"+projectId+"'");
String orderNo = Sqlca.getString("SELECT ORDER_NO from LM_GPS_ORDER where PROJECT_ID='"+projectId+"'");
String vin = Sqlca.getString("SELECT CAR_VIN from LM_GPS_ORDER where PROJECT_ID='"+projectId+"'");
String applyNo = Sqlca.getString("SELECT APPLY_NO from LM_GPS_ORDER where PROJECT_ID='"+projectId+"'");
System.out.println("projectId=" + projectId);
System.out.println("userId=" + userId);
System.out.println("orderNo=" + orderNo);
System.out.println("vin=" + vin);
System.out.println("applyNo=" + applyNo);
System.out.println("source=" + source);
String sTempletNo = "LB_CONTRACT_INFO_PAY";//--模板号--
ASObjectModel doTemp = new ASObjectModel(sTempletNo);
/* if(null!=ishistory&&ishistory.equals("true")){
doTemp.setDataQueryClass("com.tenwa.flow.flowHistory.FlowDataInfoHistory");//如果是历史则新显示历史数据
} */
ASObjectWindow dwTemp = new ASObjectWindow(CurPage, doTemp,request);
dwTemp.Style = "2";
dwTemp.ReadOnly = "1";
dwTemp.genHTMLObjectWindow(contractId);
doTemp.setHtmlEvent("IS_NETCAR","onChange","changeNetCarInfo");
String url="/Tenwa/Lease/Flow/Comm/LBGuaranteeUnit/LBGuaranteePerUnitListForContract.jsp?CompClientID=";
dwTemp.replaceColumn("GUARANTEE_LIST", "<iframe type='iframe' id='frame_list' name=\"frame_list\" width=\"100%\" height=\"200px\" frameborder=\"0\" src=\""+sWebRootPath+url+compClientID+"&ContractId="+contractId+"&RightType=ReadOnly\"></iframe>", CurPage.getObjectWindowOutput());
//dwTemp.replaceColumn("INVOICEINFO", "<iframe type='iframe' id='frame_list' name=\"frame_list\" width=\"100%\" height=\"200px\" frameborder=\"0\" src=\""+sWebRootPath+"\Tenwa\Core\InvoiceManager\FundPaymentInvoice\LbInvoiceInfoTemp.jsp\"+compClientID+"&ContractId="+contractId+"&RightType=ReadOnly\"></iframe>", CurPage.getObjectWindowOutput());
dwTemp.replaceColumn("INVOICEINFO", "<iframe type='iframei' id='frame_listi' name=\"frame_listi\" width=\"100%\" height=\"250px\" frameborder=\"0\" src=\""+sWebRootPath+"/Tenwa/Core/InvoiceManager/FundPaymentInvoice/LBInvoiceList.jsp?CompClientID="+compClientID+"&ContractId="+contractId+"&flowunid="+flowunid+"&phaseNo="+phaseNo+"\"></iframe>", CurPage.getObjectWindowOutput());
//租赁物列表信息页面
dwTemp.replaceColumn("EQUIPMENT_LIST", "<iframe type='iframe' id='equipment_list' name=\"frame_list\" width=\"100%\" height=\"200px\" frameborder=\"0\" src=\""+sWebRootPath+"/Tenwa/Lease/Flow/Comm/LBEquipment_Car/PayLBEquipmentList.jsp?CompClientID="+compClientID+"&ContractId="+contractId+"&RightType=ReadOnly\"></iframe>", CurPage.getObjectWindowOutput());
String sButtons[][] ={
{"true","","Button","保存","保存所有修改","save()","","","","btn_icon_save"},
{"true","All","Button","查看GPS定位信息","查看GPS定位信息","queryOrder()","","","","",""},
};
//sButtonPosition = "south";
%><%@ include file="/Frame/resources/include/ui/include_info.jspf"%>
<script type="text/javascript">
function queryOrder(){
var applyNo = "<%=applyNo%>";
var userId = "<%=userId%>";
var orderNo = "<%=orderNo%>";
var projectId = "<%=projectId%>";
var vin = "<%=vin%>";
if(applyNo == 'null' || orderNo == 'null' || vin == 'null'){
alert("查询GPS安装订单不存在该订单暂未安装GPS。");
return;
}
var result =AsControl.RunJavaMethodTrans("com.tenwa.gps.GpsController","queryOrder",
"userId=<%=userId%>,flowUnid=流程外查询,applyNo=<%=applyNo%>,orderNo=<%=orderNo%>,tableName=LM_GPS_ORDER,projectId=<%=projectId%>,vin=<%=vin%>,source=<%=source%>");
AsDialog.PopView("/Tenwa/Gps/LmGpsLocationList.jsp","ProjectNo=<%=applyNo%>","dialogWidth=1300px;dialogHeight=200px;center:yes;status:no;statusbar:no",function(sAreaCodeInfo){
},'GPS定位信息');
}
function save(){
var orgid= "<%=orgId%>".substring(0,4);
if("FundPaymentCarFlow"=="<%=CurPage.getParameter("FlowNo")%>" && "<%=phaseNo%>"!="0010" && orgid != "8006" ){
var HAS_GPS = getItemValue(0,getRow(0),"HAS_GPS");
if(HAS_GPS=="Y"||HAS_GPS=="N"){
var sReturnInfo = RunJavaMethodTrans("com.tenwa.lease.flow.contract.check.ContractInfoCheck","saveGps","contractid=<%=contractId%>,hasGps="+HAS_GPS);
alert("数据保存成功");
};
//frame_listi.window.save(HAS_GPS);
}else{
as_save(0);
}
}
//根据是否网约车显示不同的数据
function changeNetCarInfo(){
var netcar = getItemValue(0,0,"IS_NETCAR");
if("1" == netcar){
$("#A_Group_0080").attr("style","display:block;");
// setItemRequired(0,"IS_OPERATION",true);
// setItemRequired(0,"IS_AFFILIATED",true);
// setItemRequired(0,"IS_OPERATION_QUALIFICATION",true);
// // setItemRequired(0,"TRANSPORTCERTID",true);
setItemRequired(0,"AFFILIATEDNAME",true);
// setItemRequired(0,"NETCERTNAME",true);
setItemRequired(0,"LEGALPERSONNAME",true);
// setItemRequired(0,"AFFILIATEDDATE",true);
// setItemRequired(0,"AFFILIATEDENDDATE",true);
// setItemRequired(0,"REGISTEREDMONEY",true);
// setItemRequired(0,"AFFILIATEDACTUALADDRESS",true);
// setItemRequired(0,"AFFILIATEDADDRESS",true);
// // setItemRequired(0,"",true);
setItemRequired(0,"NETCERTID",true);
// setItemRequired(0,"LEGALPERSONID",true);
document.getElementById("NETCERTNAME").value = '营业执照';
}else{
$("#A_Group_0080").attr("style","display:none;");
setItemRequired(0,"IS_OPERATION",false);
setItemRequired(0,"IS_AFFILIATED",false);
setItemRequired(0,"IS_OPERATION_QUALIFICATION",false);
// setItemRequired(0,"TRANSPORTCERTID",false);
setItemRequired(0,"AFFILIATEDNAME",false);
setItemRequired(0,"NETCERTNAME",false);
setItemRequired(0,"LEGALPERSONNAME",false);
setItemRequired(0,"AFFILIATEDDATE",false);
setItemRequired(0,"AFFILIATEDENDDATE",false);
setItemRequired(0,"REGISTEREDMONEY",false);
setItemRequired(0,"AFFILIATEDACTUALADDRESS",false);
setItemRequired(0,"AFFILIATEDADDRESS",false);
// setItemRequired(0,"TRANSPORTDATE",false);
setItemRequired(0,"NETCERTID",false);
setItemRequired(0,"LEGALPERSONID",false);
document.getElementById("NETCERTNAME").value = '';
}
}
window.onload = function(){
var gps = "<%=gpsVendor%>";
if("null" != gps && gps.length >0){
setItemValue(0,0,"GPS", gps);
}
setItemValue(0,0,"CERTTYPE_CF","Ind01");
var type = getItemValue(0,0,"customertype");
if(type=="03"||type==""||type==null){
hideItem(0,"CERTTYPE_CC");
hideItem(0,"CERTID_CC");
hideItem(0,"TEL_CC");
}else if(type=="01"){
hideItem(0,"SEX_CP");
hideItem(0,"CERTTYPE_CP");
hideItem(0,"CERTID_CP");
hideItem(0,"MOBILE_CP");
}
//判断是否是付款流程,如果不是隐藏扣款卡信息
if("FundPaymentCarFlow"!="<%=CurPage.getParameter("FlowNo")%>"){
$("#A_Group_0060").attr("style","display:none;");
}else{
if("<%=phaseNo%>"=="0020"){
setItemReadOnly(0,0,"has_gps", false);
}
}
var orgid= "<%=orgId%>".substring(0,4);
if(!("FundPaymentCarFlow"=="<%=CurPage.getParameter("FlowNo")%>" && "<%=phaseNo%>"!="0010" && orgid != "8006")){
$("#A_Group_0070").attr("style","display:none;");//隐藏
}
changeNetCarInfo();
//如果是中车合同,显示中车的合同号
var channel = getItemValue(0,0,"channel");
if("ZC" == channel){
$("#A_div_1034").attr("style","display:block;");
$("#A_div_1038").attr("style","display:block;");
}else{
$("#A_div_1034").attr("style","display:none;");
$("#A_div_1038").attr("style","display:none;");
}
}
</script>
<%@ include file="/Frame/resources/include/include_end.jspf"%>