jsp一个

<%@ page language="java"  import="java.util.*,com.wudaosoft.weixin.oauth2.*"  pageEncoding="UTF-8"%>
<%@ page import="com.wudaosoft.weixin.CommonApi"%>
<%@ page import="org.apache.commons.lang.StringUtils"%>
<%@ page import="java.lang.String"%>

<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ taglib uri="http://java.sun.com/jsp/jstl/functions" prefix="fn"%>
<%
    String path = request.getContextPath();
    String basePath = request.getScheme() + "://"
            + request.getServerName() + ":" + request.getServerPort()
            + path + "/";
    String source = (String)request.getParameter("source");

%>
<!DOCTYPE html>
<html lang="zh-CN">
<head>
<title  style = "text-align:center;">新车优惠嘉年华</title>
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate"/>
<meta http-equiv="Pragma" content="no-cache" />
<meta http-equiv="Expires" content="0" />
<meta http-equiv="keywords" content="keyword1,keyword2,keyword3">
<meta http-equiv="description" content="This is my page">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta name="apple-mobile-web-app-capable" content="yes">
<meta id="viewport" name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=no"/>
<link href="<%=request.getContextPath()%>/newLayout/css/style.css" rel="stylesheet" type="text/css" /> 
<script src="<%=request.getContextPath()%>/newLayout/js/jquery-1.8.1.min.js" type="text/javascript" language="javascript"></script>
<script src="http://res.wx.qq.com/open/js/jweixin-1.0.0.js"></script>
<script type="text/javascript" src="<%=request.getContextPath()%>/displace/css/common.js"></script>
<script src="<%=request.getContextPath()%>/displace/css/normalize.css" type="text/css"></script>
<script src="<%=request.getContextPath()%>/displace/css/demo.css" type="text/css"></script>
<script src="<%=request.getContextPath()%>/displace/js/icontains.js"  type="text/javascript"></script>
<script src="<%=request.getContextPath()%>/displace/js/comboTreePlugin.js"  type="text/javascript"></script>

<script type="text/javascript">
var customerNo="";
var from="<%=request.getParameter("from") %>"
 $(function () { 
    searchYouHui(this);
     $("select").change(function(){

         searchYouHui(this);

    })
    $.ajax({
        url : "<%=request.getContextPath()%>/api/book!ajaxAddSitePositionLog.action",
        dataType : "html",
        data : {from:from},
        success : function(res) {
                console.log(res);
        },
        error : function(res) {
            
        }
    })
});
 
 
 function dianhualianxi(e){
     
      if(customerNo==""||customerNo==null){
            showModel();
            return;
        } 
        var replaceAllowanceTel = $(e).attr("id");
        

     window.location.href = "tel:"+replaceAllowanceTel;
     
     
     
 }

 
 
 function myactivity(){
     
      if(customerNo==""||customerNo==null){
            showModel();
            return;
        }     
      $(location).attr('href', '<%=request.getContextPath()%>/displace/get_discount.jsp?customerNo='+customerNo);           

 

 /*获取验证码*/
 var isPhone = 1;

 function getCode(e){    
     
     checkPhone(); //验证手机号码
     if(isPhone){
         sendMobileCode();
         resetCode(); //倒计时
     }else{
         $('#phone').focus();
     }
     
 }
 //验证手机号码
 function checkPhone(){
     var phone = $('#phone').val();
     var pattern = /^1[0-9]{10}$/;
     isPhone = 1;
     if(phone == '') {
         alert('请输入手机号码');
         isPhone = 0;
         return;
     }
     if(!pattern.test(phone)){
         alert('请输入正确的手机号码');
         isPhone = 0;
         return;
     }
 }
 //倒计时
 function resetCode(){
     $('#codebtn').hide();
     $('#J_second').html('30');
     $('#J_resetCode').show();
     var second = 30;
     var timer = null;
     timer = setInterval(function(){
         second -= 1;
         if(second >0 ){
             $('#J_second').html(second);
         }else{
             clearInterval(timer);
             $('#codebtn').show();
             $('#J_resetCode').hide();
         }
     },1000);
 }

 
 var openId="${wxUser.openID}";
 var nickName="${wxUser.nickName}";
 function sendYH(){
     
        var phone =$('#phone').val();
        var code =$('#code').val();
        if(!phone||phone==""||phone=="请输入手机号码"){
            alert("请输入手机号");
            return;
        }
        if(!code||code==""||code=="请输入验证码"){
            alert("请输入验证码");
            return;
        }
        
                //进行估价
                 $.ajax({
                    type: "POST",
                    url: "<%=request.getContextPath()%>/api/book!getZH.action",
                    //url: "http://api.kx.cn/Account/commCode",
                    data: {
                        
                        "phone":phone,
                        "code":code,
                       "openId":openId,
                       "nickName":nickName
                        },
                    success: function(data){
                        
                       
                        var data = eval("("+data+")"); 
                        if(data.code =="200" ){
                        customerNo = data.customerNo;
                       
                        var num = data.num;
                           
                          
                                    closeModel();
                           
                        }else{
                           alert("验证码不正确!");
                       }
                    },error:function (data){
                       alert("系统异常");
                    }
                }); 
           

    }


function showSqcgModel() {
    document.getElementById('sqcgModel').style.display = 'block';
    scrollTo(0,0);
    
}

function closeSqcgModel() {
    document.getElementById('sqcgModel').style.display = 'none';
}

function showZytjModel() {
    scrollTo(0,0);
    document.getElementById('zytjModel').style.display = 'block';
     
    
}

function closeZytjModel() {
    document.getElementById('zytjModel').style.display = 'none';
}
function showTjcgModel() {
    scrollTo(0,0);
    document.getElementById('tjcgModel').style.display = 'block';
     
    
}

function closeTjcgModel() {
    document.getElementById('tjcgModel').style.display = 'none';
}

function showTjiaocgModel() {
    
    document.getElementById('tjiaocgModel').style.display = 'block';
    scrollTo(0,0);
    
}

function closeTjiaocgModel() {
    document.getElementById('tjiaocgModel').style.display = 'none';
}


function showTjiaocgModel2() {
    
     if(customerNo==""||customerNo==null){
            showModel();
            return;
        } 
    
    
    document.getElementById('tjiaocgModel2').style.display = 'block';
    scrollTo(0,0);
    
}

function closeTjiaocgModel2() {
    document.getElementById('tjiaocgModel2').style.display = 'none';
}
 function clickidzhu(e) {
    
    
     if($(e).is(':checked')){    
            $(e).parents("table").find("input.zi").prop('checked',true);    
        }
        if(!$(e).is(':checked')){

            $(e).parents("table").find("input.zi").prop('checked',false);            
        }
 

     function clickidzi(e) {
         if($(e).is(':checked')){
             $(e).parents("table").find("input.zhu").prop('checked',true);    
         }else{
              var num=$(e).parents("table").find("input.zi:checked").length;
             
             if(num>0){
                 $(e).parents("table").find("input.zhu").prop('checked',true);
             }else{
                 $(e).parents("table").find("input.zhu").prop('checked',false);
             } 
             
             
         }
         
    }
     
     function tjcg(){
         
         $(location).attr('href', '<%=request.getContextPath()%>/displace/get_discount.jsp?customerNo='+customerNo); 

     }
     
    function tjiaocg(){
         
         $(location).attr('href', '<%=request.getContextPath()%>/displace/get_discount.jsp?customerNo='+customerNo); 

     }
     
    function helpme(){
         if(customerNo==""||customerNo==null){
                showModel();
                return;
            } 
        
        
        //提交一次后取消点击事件,避免重复提交
         $(e).attr("onclick",null);
        
        $.ajax({
             type: "POST",
             url: "<%=request.getContextPath()%>/api/book!getHelp.action",
    
             data: {
                 
                 "customerNo":customerNo
            
                 },
             success: function(data){
    
                 showTjcgModel();
        
             },error:function (data){
                alert("系统异常");
             }
         });

    }
    
     function lianxiwo() {
         
         if(customerNo==""||customerNo==null){
             
             showModel();
             return;
         }  

         var zinum=$(".zi:checked").length;
                if(zinum<1){
             
             alert("请选择活动商家和车型");
             }
        $("#lianxiwo").attr("onclick",null);
         
         var jxsdh="";
         
         $(".zhu:checked").each(function(i,val){
             var zz =  $(this).attr("name");
             jxsdh+= zz+",";
             });
         
         
         $.ajax({
             type: "POST",
             url: "<%=request.getContextPath()%>/api/book!getLXW.action",
             //url: "http://api.kx.cn/Account/commCode",
             data: {
                 "customerNo":customerNo,
                 "jxsdh":jxsdh
                 },
             success: function(data){
                 /*  alert(data); */
                 var data=eval("("+data+")");
                 if(data.code=="200"){
                    /*  showZytjModel();      */
                 }else{
                     alert("联系失败!");
                 }
 
             },error:function (data){
                alert("系统异常");
             }
         });
         

         $(".zhu:checked").each(function(i,val){
             var selectAllowance="";
             var companyName="";
             $(this).parents("table").find("input.zi:checked").each(function(i,val){
                 var zz=  $(this).attr("id");
                 selectAllowance+= zz+",";
             });
             
             companyName=$(this).parents("table").prev("ul").find(".companyName").attr("id");
             
             $.ajax({
                  type: "POST",
                  url: "<%=request.getContextPath()%>/api/book!getSQYH.action",
                  //url: "http://api.kx.cn/Account/commCode",
                  data: {
                      "customerNo":customerNo,
                      
                      "companyName":companyName,
                      "selectAllowance":selectAllowance
                      },
                  success: function(data){
                     showSqcgModel() ;
                  },error:function (data){
                     alert("系统异常");
                  }
              });
                 
         });
         
         
          

    }
 
     function showModel() {

         document.getElementById('myModel').style.display = 'block';
          /* document.getElementById('diban').style.backgroundColor="rgba(9, 9, 9, 0.63)"; */
        scrollTo(0,0);
     }
     function closeModel() {
         document.getElementById('myModel').style.display = 'none';
     }
 
    <%--  function shenqingyouhui(e) {
        
         alert(customerNo);
        if(customerNo==""||customerNo==null){
            
            showModel();
            return;
        }

         var status = "10";
        var companyName = $(e).attr("id");
        var selectAllowance="";

        $(e).parents("ul").next().find("input.zi:checked").each(function(i,val){
          var zz=  $(this).attr("id");
          selectAllowance+= zz+","
        });
        if(selectAllowance==null||selectAllowance==""){
            alert("请选择活动车型");
            return;
        }
        /* alert(selectAllowance); */
        //提交一次后取消点击事件,避免重复提交
         $(e).attr("onclick",null);
        
         
        $.ajax({
             type: "POST",
             url: "<%=request.getContextPath()%>/api/book!getSQYH.action",
             //url: "http://api.kx.cn/Account/commCode",
             data: {
                 "customerNo":customerNo,
                 "status":status,
                 "companyName":companyName,
                 "selectAllowance":selectAllowance
                 },
             success: function(data){
                
                /*  alert(data); */
                /*  var data = eval("("+data+")");  */
                showSqcgModel() 
                
             },error:function (data){
                alert("系统异常");
             }
         });
        
        
   

    }     --%>
    
    
     function chongzhi(){
          
        
         $(location).attr('href', '<%=request.getContextPath()%>/displace/displace_activity.jsp?customerNo='+customerNo);
         
     }

     
     function lastPage(){
             
         var  page =$('#page').val();
             if(page==1){
                 alert("当前已是首页");
                 return;
             }
             
             page=parseInt(page)-1;
             $('#page').val(page);
             
            if(imagepinpainame!=""){
                pinpai=imagepinpainame;
            }else if(selectpinpainame!=""){
                pinpai=selectpinpainame;
            }else{
                pinpai="";
            }
             
                $.ajax({
                     type: "POST",
                     url: "<%=request.getContextPath()%>/api/book!getYH.action",
                   
                     data: {
                         "page":page,
                         
                         "brandNms":pinpai
                        
                         },
                     success: function(data){
                            
                         var data1 = eval("("+data+")"); 
                         console.log(data1.data);
                         var listPrivate = data1.data.listPrivate;
                         var listRecommend = data1.data.listRecommend;
                         maxPage = data1.data.maxPage;
                         var html = "";
                         if(listPrivate.length > 0){
                         for (var i in listPrivate){
                             var item=listPrivate[i];
                             
                          html +="<hr style='position:relative;width:90%;left:5%;'/><ul style='margin-top:-5%'><li  style='margin-top:1px'> "
                                 
                                +"<img  id='"+item.replaceAllowanceTel+"'  style='float:right;position:absolute;width:25%;right:5%; height:4%;'  οnclick='dianhualianxi(this);' src='<%=request.getContextPath()%>/displace/images/3_22.png' />"
                                
                                 +"</li><br/><br/>";
                                
                                 if(typeof item.companyName != "undefined") {
                                 
                                 
                                     html +="<li style='margin-top:-5%'><div align='left' class='companyName' id='"+item.companyName+"' style='position:relative;left:5%'>" + item.companyName + "</div></li><br/>";
                                
                                 }
                                
                            
                                 if("undefined" != typeof item.address ) {
                                     html +="<li style='margin-top:-5%'><div align='left' style='position:relative;left:5%' > 地址:"+item.address+"</div></li>";
                                 }
                                
                                 html +="</ul>";
                            
                             if(item.listDetail.length > 0){
                                 html +=    "<table border='0' cellspacing='10' style='margin-top:-10%; position:relative;left:5%;width:90%;'><tr><td align='left' style='position:relative;width:30%;'>活动车型</td><td style='position:relative;width:40%;'></td>"
                                      + "<td style='position:relative;width:30%;'><input class='zhu' οnclick='clickidzhu(this)'  type='checkbox' name='"+item.replaceAllowanceTel+"'  id='id01"+i+  "'/><label for='id01"+i+"' >全选</label></td></tr>" ; 
                                for (var n in item.listDetail){
                                    var item2=item.listDetail[n];

                                    html +=    "<tr><td valign='top' align='left' style='position:relative;;width:20%;;'>" +item2.styleNm + "</td>"
                                
                              +" <td  valign='top'  align='left' style='position:relative;width:60%;'>优惠金额:"+item2.allowanceFee + "</td>"
                              +"   <td  valign='top'  align='left' style='position:relative;width:20%;'><input class='zi' οnclick='clickidzi(this)' style='position:relative;float:right;' type='checkbox'   id='"+item2.idDetail+"'  /><label for='"+item2.idDetail+"'   >.</label> </td>"
                              +"</tr>";
                              
             
                                }
                                
                                html +="</table><br/>";
                            }

                             }

                         
                         }
                         

                         if(listRecommend.length > 0){
                            
                             html +="<div><img style=' position:relative;width:100%;'  src='<%=request.getContextPath()%>/displace/images/3_40.png' /></div><br/>";
                             for (var i in listRecommend){
                                 var item=listRecommend[i];
                                
                                
                                  html +="<ul style='margin-top:-5%'><li>"
                                 
                            +"<img  id='"+item.replaceAllowanceTel+"'  style=' float:right;position:absolute;width:25%;right:5%; height:4%;'  οnclick='dianhualianxi(this);' src='<%=request.getContextPath()%>/displace/images/3_22.png' />"
                            
                             +"</li><br/><br/>";
                            
                             if(typeof item.companyName != "undefined") {
                             
                             
                                 html +="<li><div align='left' style='margin-top:-5%;position:relative;left:5%'>" + item.companyName + "</div></li><br/>";
                            
                             }
                            
                        
                             if("undefined" != typeof item.companyName ) {
                                 html +="<li><div align='left' style='margin-top:-5% ;position:relative;left:5%' > 地址:"+item.address+"</div></li>";
                             }
                            
                             html +="</ul>";
                                
                            if(item.listDetail.length > 0){
                                 html +=    "<table border='0' cellspacing='10' style='margin-top:-10%;position:relative;left:5%;width:90%;'><tr><td align='left' style='position:relative;width:30%;'>活动车型</td><td style='position:relative;width:40%;'></td>"
                                     + "<td style='position:relative;width:30%;'><input class='zhu' οnclick='clickidzhu(this)'  type='checkbox' name='"+item.replaceAllowanceTel+"'  id='id02"+i+  "'/><label for='id02"+i+"' >全选</label></td></tr>" ; 
                                for (var n in item.listDetail){
                                    var item2=item.listDetail[n];

                                    html +=    "<tr><td valign='top' align='left' style='position:relative;;width:20%;;'>" +item2.styleNm + "</td>"
                                
                              +" <td  valign='top'  align='left' style='position:relative;width:60%;'>优惠金额:"+item2.allowanceFee + "</td>"
                              +"   <td  valign='top'  align='left' style='position:relative;width:20%;'><input class='zi' οnclick='clickidzi(this)' style='position:relative;float:right;' type='checkbox'   id='"+item2.idDetail+"'  /><label for='"+item2.idDetail+"'   >.</label> </td>"
                              +"</tr>";
                              
             
                                }
                                
                                html +="</table><br/><hr style='position:relative;width:90%;left:5%;'/>";
                            } 
                             }
                             
                         }
                         html +="<hr style='position:relative;width:90%;left:5%;'/>";
                         $("#ulul").html(html);
                         
                         
                         var html2 = "";
                         
                         
                         html2 +="<div><img   style=' float:left;position:relative;width:5%; height:5%;left:30%;' οnclick='lastPage();' src='<%=request.getContextPath()%>/displace/images/3_42.png' />"
                             +"<span  style=' float:left;position:relative;width:15%; height:5%;left:37%;'>分页</span>"
                             +"<img style=' float:right;;position:relative;width:5%; height:5%; right:30%'  οnclick='nextPage();' src='<%=request.getContextPath()%>/displace/images/3_43.png' /><br/>"
                        
                             +"</div><br/><div align='left' style='position:relative; left:5% ;width:90%;  ' >"
                        
                             +" 如您无从选择,点击“帮我推荐”,我们将为您自动推荐最优方案。<br/><br/>"
                             +" <img   id='lianxiwo'  style=' float:left;position:relative;width:40%; height:40%;left:8%;' οnclick='lianxiwo();' src='<%=request.getContextPath()%>/displace/images/3_36.png' />"
                    
                             +" <img style=' float:right;;position:relative;width:40%; height:40%; right:8%'  οnclick='showTjiaocgModel2();ajaxAddcrmServiceNote();' src='<%=request.getContextPath()%>/displace/images/3_33.png' /><br/>"
                             +"        <br/><hr /><div align='left'> 实际优惠政策以当日公布为准。</div><br/></div>";
                                         
                         $("#xia").html(html2);               
                                             

                         
                     },error:function (data){
                        alert("系统异常");
                     }
                 });
           
                scrollTo(0,0);
                 
             } 
     
    
     
     
     
     function nextPage(){
        
         var  page =$('#page').val();
         if(page==maxPage){
             alert("当前已是尾页");
             return;
         }
         
             page=parseInt(page)+1;
             
             $('#page').val(page);
        
            if(imagepinpainame!=""){
                pinpai=imagepinpainame;
            }else if(selectpinpainame!=""){
                pinpai=selectpinpainame;
            }else{
                pinpai="";
            }
        
            $.ajax({
                 type: "POST",
                 url: "<%=request.getContextPath()%>/api/book!getYH.action",

                 data: {
                     "page":page,
                     
                     "brandNms":pinpai
                    
                     },
                 success: function(data){
                        
                     var data1 = eval("("+data+")"); 
                     console.log(data1.data);
                     var listPrivate = data1.data.listPrivate;
                     var listRecommend = data1.data.listRecommend;
                     maxPage = data1.data.maxPage;
                     var html = "";
                     if(listPrivate.length > 0){
                     for (var i in listPrivate){
                         var item=listPrivate[i];
                         
                      html +="<hr style='position:relative;width:90%;left:5%;'/><ul style='margin-top:-5%'><li  style='margin-top:1px'>"
                             
                            +"<img  id='"+item.replaceAllowanceTel+"'  style='float:right;position:absolute;width:25%;right:5%; height:4%;'  οnclick='dianhualianxi(this);' src='<%=request.getContextPath()%>/displace/images/3_22.png' />"
                            
                             +"</li><br/><br/>";
                            
                             if(typeof item.companyName != "undefined") {
                             
                             
                                 html +="<li style='margin-top:-5%'><div align='left' class='companyName' id='"+item.companyName+"' style='position:relative;left:5%'>" + item.companyName + "</div></li><br/>";
                            
                             }
                            

                             if("undefined" != typeof item.address ) {
                                 html +="<li style='margin-top:-5%'><div align='left' style='position:relative;left:5%' > 地址:"+item.address+"</div></li>";
                             }
                            
                             html +="</ul>";
                        
                         if(item.listDetail.length > 0){
                             html +=    "<table border='0' cellspacing='10' style='margin-top:-10%; position:relative;left:5%;width:90%;'><tr><td align='left' style='position:relative;width:30%;'>活动车型</td><td style='position:relative;width:40%;'></td>"
                                  + "<td style='position:relative;width:30%;'><input class='zhu' οnclick='clickidzhu(this)'  type='checkbox' name='"+item.replaceAllowanceTel+"'  id='id01"+i+  "'/><label for='id01"+i+"' >全选</label></td></tr>" ; 
                            for (var n in item.listDetail){
                                var item2=item.listDetail[n];

                                html +=    "<tr><td valign='top' align='left' style='position:relative;;width:20%;;'>" +item2.styleNm + "</td>"
                            
                          +" <td  valign='top'  align='left' style='position:relative;width:60%;'>优惠金额:"+item2.allowanceFee + "</td>"
                          +"   <td  valign='top'  align='left' style='position:relative;width:20%;'><input class='zi' οnclick='clickidzi(this)' style='position:relative;float:right;' type='checkbox'   id='"+item2.idDetail+"'  /><label for='"+item2.idDetail+"'   >.</label> </td>"
                          +"</tr>";
                          
         
                            }
                            
                            html +="</table><br/>";
                        }

                         }

                     
                     }
                     

                     if(listRecommend.length > 0){
                        
                         html +="<div><img style=' position:relative;width:100%;'  src='<%=request.getContextPath()%>/displace/images/3_40.png' /></div><br/>";
                         for (var i in listRecommend){
                             var item=listRecommend[i];
                            
                            
                              html +="<ul style='margin-top:-5%'><li>"

                        +"<img  id='"+item.replaceAllowanceTel+"'  style=' float:right;position:absolute;width:25%;right:5%; height:4%;'  οnclick='dianhualianxi(this);' src='<%=request.getContextPath()%>/displace/images/3_22.png' />"
                        
                         +"</li><br/><br/>";
                        
                         if(typeof item.companyName != "undefined") {
                         
                         
                             html +="<li><div align='left' style='margin-top:-5%;position:relative;left:5%'>" + item.companyName + "</div></li><br/>";
                        
                         }
                        
                        
                        
                         if("undefined" != typeof item.companyName ) {
                             html +="<li><div align='left' style='margin-top:-5% ;position:relative;left:5%' > 地址:"+item.address+"</div></li>";
                         }
                        
                         html +="</ul>";
                            
                        if(item.listDetail.length > 0){
                             html +=    "<table border='0' cellspacing='10' style='margin-top:-10%;position:relative;left:5%;width:90%;'><tr><td align='left' style='position:relative;width:30%;'>活动车型</td><td style='position:relative;width:40%;'></td>"
                                 + "<td style='position:relative;width:30%;'><input class='zhu' οnclick='clickidzhu(this)'  type='checkbox' name='"+item.replaceAllowanceTel+"'  id='id02"+i+  "'/><label for='id02"+i+"' >全选</label></td></tr>" ; 
                            for (var n in item.listDetail){
                                var item2=item.listDetail[n];

                                html +=    "<tr><td valign='top' align='left' style='position:relative;;width:20%;;'>" +item2.styleNm + "</td>"
                            
                          +" <td  valign='top'  align='left' style='position:relative;width:60%;'>优惠金额:"+item2.allowanceFee + "</td>"
                          +"   <td  valign='top'  align='left' style='position:relative;width:20%;'><input class='zi' οnclick='clickidzi(this)' style='position:relative;float:right;' type='checkbox'   id='"+item2.idDetail+"'  /><label for='"+item2.idDetail+"'   >.</label> </td>"
                          +"</tr>";
                          
         
                            }
                            
                            html +="</table><br/><hr style='position:relative;width:90%;left:5%;'/>";
                        } 
                         }
                         
                     }
                     html +="<hr style='position:relative;width:90%;left:5%;'/>";
                     $("#ulul").html(html);
                     
                     
                     var html2 = "";
                     
                     
                     html2 +="<div><img   style=' float:left;position:relative;width:5%; height:5%;left:30%;' οnclick='lastPage();' src='<%=request.getContextPath()%>/displace/images/3_42.png' />"
                         +"<span  style=' float:left;position:relative;width:15%; height:5%;left:37%;'>分页</span>"
                         +"<img style=' float:right;;position:relative;width:5%; height:5%; right:30%'  οnclick='nextPage();' src='<%=request.getContextPath()%>/displace/images/3_43.png' /><br/>"
                    
                         +"</div><br/><div align='left' style='position:relative; left:5% ;width:90%;  ' >"
                    
                         +" 如您无从选择,点击“帮我推荐”,我们将为您自动推荐最优方案。<br/><br/>"
                         +" <img   id='lianxiwo'  style=' float:left;position:relative;width:40%; height:40%;left:8%;' οnclick='lianxiwo();' src='<%=request.getContextPath()%>/displace/images/3_36.png' />"
                
                         +" <img style=' float:right;;position:relative;width:40%; height:40%; right:8%'  οnclick='showTjiaocgModel2();ajaxAddcrmServiceNote();' src='<%=request.getContextPath()%>/displace/images/3_33.png' /><br/>"
                         +"        <br/><hr /><div align='left'> 实际优惠政策以当日公布为准。</div><br/></div>";
                                     
                     $("#xia").html(html2);               
                                         

                     
                 },error:function (data){
                    alert("系统异常");
                 }
             });
       
            scrollTo(0,0);
             
         }
     
     var imagepinpainame="";
     var selectpinpainame="";
     var maxPage="";
     
     var pinpai="";
    function searchYouHui(e) {
        
        
        var classname = $(e).attr("class");
        
        if(classname=="carimage"){
            pinpai=$(e).attr("id");
            imagepinpainame=pinpai;
            selectpinpainame="";
            
        }else if(classname=="xialakuang"){
            pinpai = $('#xialakuang').val();
            selectpinpainame=pinpai;
            imagepinpainame="";
            
        }
        
        
        var page =$('#page').val(1).val();
        
        $.ajax({
             type: "POST",
             url: "<%=request.getContextPath()%>/api/book!getYH.action",
             
             
             data: {
                 "page":page,
                 
                 "brandNms":pinpai
                 
                 },
             success: function(data){
                
                 var data1 = eval("("+data+")"); 
                 console.log(data1.data);
                 var listPrivate = data1.data.listPrivate;
                 var listRecommend = data1.data.listRecommend;
                 maxPage = data1.data.maxPage;
                 var html = "";
                 if(listPrivate.length > 0){
                 for (var i in listPrivate){
                     var item=listPrivate[i];
                     
                  html +="<hr style='position:relative;width:90%;left:5%;'/><ul style='margin-top:-5%'><li  style='margin-top:1px'>"

                        +"<img  id='"+item.replaceAllowanceTel+"'  style='float:right;position:absolute;width:25%;right:5%; height:4%;'  οnclick='dianhualianxi(this);' src='<%=request.getContextPath()%>/displace/images/3_22.png' />"
                        
                         +"</li><br/><br/>";
                        
                         if(typeof item.companyName != "undefined") {
                         
                         
                             html +="<li style='margin-top:-5%'><div align='left' class='companyName' id='"+item.companyName+"' style='position:relative;left:5%'>" + item.companyName + "</div></li><br/>";
                        
                         }
                        

                        
                         if("undefined" != typeof item.address ) {
                             html +="<li style='margin-top:-5%'><div align='left' style='position:relative;left:5%' > 地址:"+item.address+"</div></li>";
                         }
                        
                         html +="</ul>";
                    
                     if(item.listDetail.length > 0){
                         html +=    "<table border='0' cellspacing='10' style='margin-top:-10%; position:relative;left:5%;width:90%;'><tr><td align='left' style='position:relative;width:30%;'>活动车型</td><td style='position:relative;width:40%;'></td>"
                              + "<td style='position:relative;width:30%;'><input class='zhu' οnclick='clickidzhu(this)'  type='checkbox' name='"+item.replaceAllowanceTel+"'  id='id01"+i+  "'/><label for='id01"+i+"' >全选</label></td></tr>" ; 
                        for (var n in item.listDetail){
                            var item2=item.listDetail[n];

                            html +=    "<tr><td valign='top' align='left' style='position:relative;;width:20%;;'>" +item2.styleNm + "</td>"
                        
                      +" <td  valign='top'  align='left' style='position:relative;width:60%;'>优惠金额:"+item2.allowanceFee + "</td>"
                      +"   <td  valign='top'  align='left' style='position:relative;width:20%;'><input class='zi' οnclick='clickidzi(this)' style='position:relative;float:right;' type='checkbox'   id='"+item2.idDetail+"'  /><label for='"+item2.idDetail+"'   >.</label> </td>"
                      +"</tr>";
                      
     
                        }
                        
                        html +="</table><br/>";
                    }

                     }

                 
                 }
                 

                 if(listRecommend.length > 0){
                    
                     html +="<div><img style=' position:relative;width:100%;'  src='<%=request.getContextPath()%>/displace/images/3_40.png' /></div><br/>";
                     for (var i in listRecommend){
                         var item=listRecommend[i];
                        
                        
                          html +="<ul style='margin-top:-5%'><li>"

                    +"<img  id='"+item.replaceAllowanceTel+"'  style=' float:right;position:absolute;width:25%;right:5%; height:4%;'  οnclick='dianhualianxi(this);' src='<%=request.getContextPath()%>/displace/images/3_22.png' />"
                    
                     +"</li><br/><br/>";
                    
                     if(typeof item.companyName != "undefined") {
                     
                     
                         html +="<li><div align='left' style='margin-top:-5%;position:relative;left:5%'>" + item.companyName + "</div></li><br/>";
                    
                     }
                    

                    
                     if("undefined" != typeof item.companyName ) {
                         html +="<li><div align='left' style='margin-top:-5% ;position:relative;left:5%' > 地址:"+item.address+"</div></li>";
                     }
                    
                     html +="</ul>";
                        
                    if(item.listDetail.length > 0){
                         html +=    "<table border='0' cellspacing='10' style='margin-top:-10%;position:relative;left:5%;width:90%;'><tr><td align='left' style='position:relative;width:30%;'>活动车型</td><td style='position:relative;width:40%;'></td>"
                             + "<td style='position:relative;width:30%;'><input class='zhu' οnclick='clickidzhu(this)'  type='checkbox' name='"+item.replaceAllowanceTel+"'  id='id02"+i+  "'/><label for='id02"+i+"' >全选</label></td></tr>" ; 
                        for (var n in item.listDetail){
                            var item2=item.listDetail[n];

                            html +=    "<tr><td valign='top' align='left' style='position:relative;;width:20%;;'>" +item2.styleNm + "</td>"
                        
                      +" <td  valign='top'  align='left' style='position:relative;width:60%;'>优惠金额:"+item2.allowanceFee + "</td>"
                      +"   <td  valign='top'  align='left' style='position:relative;width:20%;'><input class='zi' οnclick='clickidzi(this)' style='position:relative;float:right;' type='checkbox'   id='"+item2.idDetail+"'  /><label for='"+item2.idDetail+"'   >.</label> </td>"
                      +"</tr>";
                      
     
                        }
                        
                        html +="</table><br/><hr style='position:relative;width:90%;left:5%;'/>";
                    } 
                     }
                     
                 }
                 html +="<hr style='position:relative;width:90%;left:5%;'/>";
                 $("#ulul").html(html);
                 
                 
                 var html2 = "";
                 
                 
                 html2 +="<div><img   style=' float:left;position:relative;width:5%; height:5%;left:30%;' οnclick='lastPage();' src='<%=request.getContextPath()%>/displace/images/3_42.png' />"
                     +"<span  style=' float:left;position:relative;width:15%; height:5%;left:37%;'>分页</span>"
                     +"<img style=' float:right;;position:relative;width:5%; height:5%; right:30%'  οnclick='nextPage();' src='<%=request.getContextPath()%>/displace/images/3_43.png' /><br/>"
                
                     +"</div><br/><div align='left' style='position:relative; left:5% ;width:90%;  ' >"
                
                     +" 如您无从选择,点击“帮我推荐”,我们将为您自动推荐最优方案。<br/><br/>"
                     +" <img   id='lianxiwo'  style=' float:left;position:relative;width:40%; height:40%;left:8%;' οnclick='lianxiwo();' src='<%=request.getContextPath()%>/displace/images/3_36.png' />"
            
                     +" <img style=' float:right;;position:relative;width:40%; height:40%; right:8%'  οnclick='showTjiaocgModel2();ajaxAddcrmServiceNote();' src='<%=request.getContextPath()%>/displace/images/3_33.png' /><br/>"
                     +"        <br/><hr /><div align='left'> 实际优惠政策以当日公布为准。</div><br/></div>";
                                 
                 $("#xia").html(html2);               
                                     

                 
             },error:function (data){
                alert("系统异常");
             }
         });
   

    }
    function ajaxAddcrmServiceNote(){
        $.ajax({
            url : "<%=request.getContextPath()%>/api/book!ajaxAddcrmServiceNote.action",
            dataType : "html",
            data : {"customerNo":customerNo},
            success : function(res) {
                var data = eval("(" + res + ")");
                if (data.code == "200") {
                    
                }
            },
            error : function(res) {
                alert("error:" + res);
            }
        })
    }

</script>
<style>

/* .ziti{font-family:黑体;} */
body{
  font-size:14px;
  font-family: PingFangSC-Medium,PingFang SC;;
  font-weight: 500;
}

.container {
            width: 100%;
            height: 100%;
            text-align: center;
            margin: 0px auto;
           
        }
        
    #tjiaocgModel2 {
            position: absolute;
            top: 0;
            left: 0;
            display: none;
             background-color: rgba(9, 9, 9, 0.63); 
            width: 100%;
            height: 100%;
           /*  z-index: 1000; */
        }

        .tjiaocgModel2-content {
            width: 680px;
            height: 620px;
            text-align: center;
               background: #ffffff; 
            border-radius: 6px;
            margin: 100px auto;
            line-height: 30px;
           /*  z-index: 10001; */
        }           
        
      
     #tjiaocgModel {
            position: absolute;
            top: 0;
            left: 0;
            display: none;
             background-color: rgba(9, 9, 9, 0.63); 
            width: 100%;
            height: 100%;
           /*  z-index: 1000; */
        }

        .tjiaocgModel-content {
            width: 680px;
            height: 620px;
            text-align: center;
               background: #ffffff; 
            border-radius: 6px;
            margin: 100px auto;
            line-height: 30px;
           /*  z-index: 10001; */
        }       
         
      
        
         
     #tjcgModel {
            position: absolute;
            top: 0;
            left: 0;
            display: none;
             background-color: rgba(9, 9, 9, 0.63); 
            width: 100%;
            height: 100%;
           /*  z-index: 1000; */
        }

        .tjcgModel-content {
            width: 680px;
            height: 620px;
            text-align: center;
               background: #ffffff; 
            border-radius: 6px;
            margin: 100px auto;
            line-height: 30px;
           /*  z-index: 10001; */
        }       
        
        
        
        
 #zytjModel {
            position: absolute;
            top: 0;
            left: 0;
            display: none;
             background-color: rgba(9, 9, 9, 0.63); 
            width: 100%;
            height: 100%;
           /*  z-index: 1000; */
        }

        .zytjModel-content {
            width: 680px;
            height: 620px;
            text-align: center;
               background: #ffffff; 
            border-radius: 6px;
            margin: 100px auto;
            line-height: 30px;
           /*  z-index: 10001; */
        }
        
        
        
 #sqcgModel {
            position: absolute;
            top: 0;
            left: 0;
            display: none;
             background-color: rgba(9, 9, 9, 0.63); 
            width: 100%;
            height: 100%;
            /* z-index: 1000; */
        }

        .sqcgModel-content {
            width: 680px;
            height: 620px;
            text-align: center;
               background: #ffffff; 
            border-radius: 6px;
            margin: 100px auto;
            line-height: 30px;
           /*  z-index: 10001; */
        }

         #myModel {
            position: absolute;
            top: 0;
            left: 0;
            display: none;
             background-color: rgba(9, 9, 9, 0.63); 
            width: 100%;
            height: 100%;
            z-index: 1000;
        }

        .model-content {
            width: 680px;
            height: 620px;
            text-align: center;
               background: #ffffff; 
            border-radius: 6px;
            margin: 100px auto;
            line-height: 30px;
            z-index: 10001;
        }


</style>
</head>
<body>

<div id="yemian">

 <input id="page" hidden="hidden"  name="page"/>
 <input id="maxPage" hidden="hidden"  name="maxPage"/>
<div>
    <div id="diban" class="container"  >
        <div>
            
                <ul>            
                    <li>
                        <img style="position:relative;width:100%; height:100%;" src="<%=request.getContextPath()%>/displace/images/1.png" />
                        <span></span>
                    </li>
                    
                    
                    
                    
                    <div>
                    <div style="position:relative;background:#BEBFC3;;width:100%;">
    <strong style="width:100%;">请点选所需品牌</strong>
    </div>
                <table border="0" cellspacing="10" style="position:relative;left:5%;width:90%;">    
                    <tr>

                        <td  style="position:relative;width:25%;" >
                            <img id="凯迪拉克" class="carimage" οnclick="searchYouHui(this);" style="position:relative;width:80%; height:64%;" src="<%=request.getContextPath()%>/displace/images/5_01.png" />
                        </td>
                        <td  style="position:relative;width:25%;">
                            <img id="奥迪" class="carimage"  οnclick="searchYouHui(this);" style="position:relative;width:80%; height:40%;" src="<%=request.getContextPath()%>/displace/images/5_02.png" />
                        </td>
                        <td  style="position:relative;width:25%;">
                            <img id="大众"  class="carimage"  οnclick="searchYouHui(this);" style="position:relative;width:80%; height:64%;" src="<%=request.getContextPath()%>/displace/images/5_03.png" />
                        </td>
                        <td  style="position:relative;width:25%;">
                            <img id="沃尔沃"  class="carimage"  οnclick="searchYouHui(this);" style="position:relative;width:80%; height:64%;" src="<%=request.getContextPath()%>/displace/images/5_04.png" />
                        </td>
                        
                    </tr>
                    <tr>
                        <td>
                            <img id="丰田"  class="carimage"  οnclick="searchYouHui(this);" style="position:relative;width:80%; height:64%;" src="<%=request.getContextPath()%>/displace/images/5_05.png" />
                        </td>
                        <td>
                            <img id="广汽本田"  class="carimage"  οnclick="searchYouHui(this);" style="position:relative;width:80%; height:64%;" src="<%=request.getContextPath()%>/displace/images/5_06.png" />
                        </td>
                        <td>
                            <img id="宝马"  class="carimage"  οnclick="searchYouHui(this);" style="position:relative;width:80%; height:56%;" src="<%=request.getContextPath()%>/displace/images/5_07.png" />
                        </td>
                        <td>
                            <img id="奔驰"  class="carimage"  οnclick="searchYouHui(this);" style="position:relative;width:80%; height:56%;" src="<%=request.getContextPath()%>/displace/images/5_08.png" />
                        </td>
                    </tr>

                </table>    
                    
                    <select id="xialakuang" class="xialakuang"    style=" margin-top: 20px; position:relative;width:90%;height:30px;" >
                         <option value="" selected >查看更多</option>
                          <option value="雷诺">雷诺</option>
                          <option value ="斯柯达">斯柯达</option>
                          <option value ="东风本田">东风本田</option>
                          <option value="讴歌">讴歌</option>
                          <option value ="捷豹路虎">捷豹路虎</option>
                          <option value ="日产">日产</option>
                          <option value="福特">福特</option>
                          <option value ="吉利">吉利</option>
                          <option value ="别克">别克</option>
                          <option value="荣威">荣威</option>
                          <option value ="北京现代">北京现代</option>
                          <option value ="雪铁龙">雪铁龙</option>
                          <option value="斯柯达">斯柯达</option>
                          <option value ="广汽三菱">广汽三菱</option>
                         
                          <option value="红旗">红旗</option>
                          <option value ="JEEP 克莱斯勒">JEEP 克莱斯勒</option>
                          <option value ="英菲尼迪">英菲尼迪</option>
                          <option value="红旗">红旗</option>
                          <option value ="吉利">吉利</option>
                          <option value ="奇瑞">奇瑞</option>

                    </select>

                </div>


            </ul>
        

        </div> 
        <div style="position:relative;background:#BEBFC3;;width:100%;">
            <strong style="width:100%;">请勾选所需4S店</strong>
        </div>
        
    <div class="ziti"  style="font-family:Simsun">
        
        
        <ul id="ulul"></ul>

    
    <div>

    
    
    
    <div id="xia" class="ziti" style="font-family:Simsun" >    
                
        </div>

    </div>
    

    <div style="position:relative;">
      <img style="width:100%;left:0%;"  src="<%=request.getContextPath()%>/displace/images/9.png" /> 
    <img style="position:absolute;width:30%;height:5%;z-index:2;right:5%;top:1%;" οnclick="myactivity();" src="<%=request.getContextPath()%>/displace/images/8.png" />
    </div><br/><br/><br/>


</div> 


<div id="zytjModel" >
         <div class="zytjModel-content"  style="position:absolute; left:5% ; width: 90%;height: 40%;  ">
            <div >
                <img style="position:relative;width:100%;" src="<%=request.getContextPath()%>/displace/images/11_03.png" />
                <div style="position:relative; left:80%; top:4%;"><img style="height: 10%" οnclick="closeZytjModel()"  src="<%=request.getContextPath()%>/displace/images/2_15.png" /></div> 
            </div>
             <br/>
            <div align="left" style="position:relative;width:80%;left:10%; ">
            车开新更多更好的优惠方案,推荐给您?
            
            
            </div>
            <br/> 
             <div >  
             <span>    
                 <img style="position:relative;height: 40%; width:40%;top:80% " οnclick="showTjcgModel();closeZytjModel();" src="<%=request.getContextPath()%>/displace/images/11_07.png" />
                <img style="position:relative;height: 40%; width:40%;top:80%" οnclick="showTjiaocgModel();closeZytjModel();"  src="<%=request.getContextPath()%>/displace/images/11_09.png" />
            </span>  
            </div> 
        </div> 
</div>


 <div id="sqcgModel" >
        <div class="sqcgModel-content"  style="position:absolute; left:5% ; width: 90%;height: 40%;  ">
            <div >
                <img style="position:relative;width:100%;" src="<%=request.getContextPath()%>/displace/images/4_03_01.png" />
                <div style="position:absolute; left:80%; top:4%;"><img style="height: 10%" οnclick="closeSqcgModel()"  src="<%=request.getContextPath()%>/displace/images/2_15.png" /></div> 
            </div>
            
            <div align="left" style="position:relative;width:80%;left:10%; ">
            您的信息已提交,参与活动的编号已短信发送给您,请注意查看。稍后会有销售跟您联系,请保持手机畅通并注意接听,感谢!

            
            
            </div>
            
             <div style="position:relative; top:8%">
                 
                     <img οnclick="closeSqcgModel()"  style="position:relative; width:80%;top:60%" src="<%=request.getContextPath()%>/displace/images/6_07.png" />
                
            </div> 
        </div>
</div> 


 <div id="tjcgModel" >
        <div class="tjcgModel-content"  style="position:absolute; left:5% ; width: 90%;height: 40%;  ">
            <div >
                <img style="position:relative;width:100%;" src="<%=request.getContextPath()%>/displace/images/6_03.png" />
                <div style="position:absolute; left:80%; top:4%;"><img style="height: 10%" οnclick="closeTjcgModel()"  src="<%=request.getContextPath()%>/displace/images/2_15.png" /></div> 
            </div>
            
            <div align="left"  style="position:relative;width:90%;left:5%; ">
            您的信息已提交,参与活动的编号已短信发送给您,请注意查看。稍后会有销售跟您联系,请保持手机畅通并注意接听,感谢!

            </div>
            
             <div > 
                 
                     <img   οnclick="closeTjcgModel()"     style="position:relative; width:80%;top:60%" src="<%=request.getContextPath()%>/displace/images/6_07.png" />
                
            </div> 
        </div>
</div>


<div id="tjiaocgModel" >
        <div class="tjiaocgModel-content"  style="position:absolute; left:5% ; width: 90%;height: 40%;  ">
            <div >
                <img style="position:relative;width:100%;" src="<%=request.getContextPath()%>/displace/images/4_03_01.png" />
                <div style="position:absolute; left:80%; top:4%;"><img style="height: 10%" οnclick="closeTjiaocgModel()"  src="<%=request.getContextPath()%>/displace/images/2_15.png" /></div> 
            </div>
            
            <div align="left" style="position:relative;width:80%;left:10%; ">
            您的选择已提交,您的专属销售将尽快与您联系,请保持手机畅通,并注意接听,谢谢!


            </div>
            <br/>
             <div > 
                
                     <img   οnclick="closeTjiaocgModel()"  style="position:relative; width:80%;top:70%" src="<%=request.getContextPath()%>/displace/images/6_07.png" />
                
            </div> 
        </div>
</div>

<div id="tjiaocgModel2" >
        <div class="tjiaocgModel2-content"  style="position:absolute; left:5% ; width: 90%;height: 40%;  ">
            <div >
                <img style="position:relative;width:100%;" src="<%=request.getContextPath()%>/displace/images/4_03_01.png" />
                <div style="position:absolute; left:80%; top:4%;"><img style="height: 10%" οnclick="closeTjiaocgModel2()"  src="<%=request.getContextPath()%>/displace/images/2_15.png" /></div> 
            </div>
            
            <div align="left" style="position:relative;width:80%;left:10%; ">
            您的需求已提交,您的专属顾问将尽快与您联系,帮您推荐最优方案,请保持手机畅通,并注意接听,谢谢!
            </div>
            <br/>
             <div > 
                
                     <img   οnclick="closeTjiaocgModel2();"  style="position:relative; width:80%;top:70%" src="<%=request.getContextPath()%>/displace/images/6_07.png" />
                
            </div> 
        </div>
</div>

<div id="myModel" >
        <div class="model-content"  style="position:absolute; left:5% ; width: 90%;height: 40%;  ">
            <div >
                <img style="position:absolute; width: 100%; left:0%;height: 20%"; src="<%=request.getContextPath()%>/displace/images/2_11.png" />
                <div style="position:absolute; left:80%; top:4%;"><img style="height: 10%" οnclick="closeModel()"  src="<%=request.getContextPath()%>/displace/images/2_15.png" /></div> 
            </div>
            <br/>
            <div>
             <img   style="position:absolute;  left:10%; top:30%;height: 15%; " src="<%=request.getContextPath()%>/displace/images/2_03.png" />
            <input style=" position:absolute;  left:25%; top:30%; ;height: 15%;width: 60%;"  type="text" value="请输入手机号码" id="phone" maxlength="11" οnfοcus="if($.trim($(this).val())=='请输入手机号码'){$(this).val('').focus()}"  placeholder="请输入手机号码">
            </div>  
              
                <br/>
             <div >
             <img style="position:absolute;  left:10%; top:60%;height: 15%; "  src="<%=request.getContextPath()%>/displace/images/2_06.png" />
                       
                             <input style=" position:absolute;  left:25%; top:60%; height: 8.5%;width: 25%;" type="text" value="请输入验证码" id="code" maxlength="4" οnfοcus="if($.trim($(this).val())=='请输入验证码'){$(this).val('').focus()}"  placeholder="请输入验证码"/>
                             <button id="codebtn" οnclick="getCode(this);" style=" position:absolute;  left:60%; top:60%; ;height: 15%;width: 25%;" type="button">获取验证码</button>
                             <button id="J_resetCode"  style=" position:absolute;  left:60%; top:60%; ;height: 15%;width: 25%;display:none;" type="button"><span id="J_second">30</span>秒倒计时</button>
                             
             </div>       
               <br/>
             <div > 
                     <img οnclick="sendYH();"   style="position:absolute; width: 80%; left:10%; top:80%;height: 15%;pointer-events;" src="<%=request.getContextPath()%>/displace/images/2_19.png" />
            
            
            <div> 
        </div>
</div>

</div>

</div>
</div>
</body>
</html>

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值