• 车林通购车之家--购车计算器模块--车型弹窗


    //car-model-select-tanchaung.twig

      <!--对车车型弹出层 S-->
      <div class="select-models">
          <header class="common-header font32">
          <a class="goback close-select" href="javascript:void(0)"><i class="arrow-icon go-back-icon"></i></a>
          车林通<i class="circle-icon"></i><span>选择车款</span>
          <a class="header-search"><i class="common-icon search-icon"></i></a>
        </header>
        <ul class="switch-nav switch-nav-model db-tags bgfff clearfix">
            <li class="active"><a id="cc">奥迪A4L</a></li>
            <li><a><span>按品牌查找<i class="line"></i></span></a></li>
            <li><a><span>历史记录<i class="line"></i></span></a></li>
        </ul>
        <div id="kk" class="switch-item switch-item-model active">
          <div class="year-tt font24 color-gray"></div>
          <ul id="kkd" class="pic-txt-j">  
              <li>
              <a href="javascript:voil(0);">
                <h4 class="font28 color-light-gray"></h4>
                <p class="font24 color-gray"></p>
              </a>
            </li>
          </ul>
        </div>
        <div class="switch-item switch-item-model">
            <div class="blank20"></div>
            <div class="bgfff">
            <div class="tt-small font24 color-blue">热门品牌</div>
            <div class="brand-hot" id="brand-hot">
              <ul class="clearfix">
                {% for i in hotBrands %}
                <li>
                   <a href="#" id="{{i.id}}" class="{{i.name}}">
                    <img class="brand-logo" src="{{i.logo}}" /> 
                    <p class="brand-name">{{i.name}}</p>
                  </a>
                </li> 
                {% endfor %}
              </ul>
            </div>
          </div>
          <div class="bg-wrap">
            {% for initial,brand in brands %}
            <div class="tt-small font24 color-blue" id="char-nav-{{initial}}">{{initial}}</div>
            <div class="bybrand-list" id="bybrand-list">
              <ul> 
                {% for j in brand%}
                <li>
                  <a href="#" id="{{j.id}}" class="{{j.name}}">
                    <img  class="brand-logo" src="{{j.logo}}" />
                    <span class="brand-name">{{j.name}}</span>
                  </a>
                </li>  
                {% endfor %}
              </ul>
            </div>
            {% endfor %} 
          </div>
                    
          <div class="fixed-letter-nav">
            <ul class="rows-box">
              <li><a href="#">热</a></li>
              <li><a href="#char-nav-A">A</a></li>
              <li><a href="#char-nav-B">B</a></li>
              <li><a href="#char-nav-C">C</a></li>
              <li><a href="#char-nav-D">D</a></li>
              <li><a href="#char-nav-F">F</a></li>
              <li><a href="#char-nav-G">G</a></li>
              <li><a href="#char-nav-H">H</a></li>
              <li><a href="#char-nav-J">J</a></li>
              <li><a href="#char-nav-K">K</a></li>
              <li><a href="#char-nav-L">L</a></li>
    
              <li><a href="#char-nav-M">M</a></li>
              <li><a href="#char-nav-N">N</a></li>
              <li><a href="#char-nav-O">O</a></li>
              <li><a href="#char-nav-P">P</a></li>
              <li><a href="#char-nav-Q">Q</a></li>
              <li><a href="#char-nav-R">R</a></li>
              <li><a href="#char-nav-S">S</a></li>
              <li><a href="#char-nav-T">T</a></li>
              <li><a href="#char-nav-W">W</a></li>
              <li><a href="#char-nav-X">X</a></li>
              <li><a href="#char-nav-Y">Y</a></li>
              <li><a href="#char-nav-Z">Z</a></li>
            </ul>
          </div>
          <!--品牌选择弹窗-->
          <div class="left-mask1"></div>
          <div class="left-popup popup-type rand-list">
            <div class="swipe-left">
              <div class="choose-car-name-close">
                
              </div>
              <span id="tt">
                    
              </span>        
          </div>
          </div>
          <!--车系选择弹窗-->
          <div class="left-mask2"></div>
          <div class="left-popup popup-type rand-model-list">
            <div class="swipe-left">
              <p class="dealer-type font26">
              </p>
              <span id="aa">
              </span>
        </div>
      </div>
      </div>
      <!--历史记录-->
      <div class="switch-item switch-item-model">
            <ul id="mm" class="pic-txt-f">
                {% for i in history%}
                <li brandId="{{i.brand_id}}" seriesId="{{i.series_id}}" modelId="{{i.model_id}}" price="{{i.price}}">
                    <a href="javascript:void(0);">
                        <h4 class="font28" style="color:#666666">{{i.name}}</h4>
                        <p class="font24" style="color:#999999">{{i.price}}元</p>
                        <p class="font24" style="color:#999999">{{i.view_time}}</p>
                     </a>
                </li>
                {% endfor %}
            </ul>
      </div>
    </div>
    {{ use('common\widgets\JsBlock') }}
    {{ js_block_begin() }}
    <script> 
         $("#mm li").click(function(){
              bd=$(this).attr("brandId");
              sd=$(this).attr("seriesId");
              md=$(this).attr("modelId");
              $.cookie("brand_id",bd);
              $.cookie("series_id",sd);
              $.cookie("model_id",md);
              var htmg=$(this).find("h4").text();
              $.cookie("htmg",htmg);
              hidCarPrice=$(this).attr("price");
              $.cookie('hidCarPrice',hidCarPrice);
              //设置单机后颜色
              $(".pic-txt-f li").find("h4").attr("style","color:#666666");
              $(".pic-txt-f li").find("p").attr("style","color:#999999");
              $(this).find("a").css("color","#3B5998");                                                  
              $(this).find("h4").removeAttr("style");
              $(this).find("p").removeAttr("style"); 
              if($.cookie("k")==0){  
                     var url=window.location.href;
                     if(url.indexOf("dk")>0){
                           location.href='{{path(['dk'])}}?model_id='+md+'&brand_id='+bd+'&series_id='+sd; 
                     }else if(url.indexOf("qk")>0){
                           location.href='{{path(['qk'])}}?model_id='+md+'&brand_id='+bd+'&series_id='+sd; 
                     }else{
                           location.href='{{path(['bx'])}}?model_id='+md+'&brand_id='+bd+'&series_id='+sd; 
                     } 
              } 
              $("#select_carname2").html(htmg);
              $("#luochePrice3").attr("value",hidCarPrice);
              $(".select-models").hide();
        });
    </script>
    {{ js_block_end() }}   
  • 相关阅读:
    VM启用ISO共享
    部署服务--NLB
    SCVMM问题汇总
    判断文件是否存在(exist)
    函数(Function)作用域 / 远程函数执行
    基于433MHz无线串口,多发一收解决方案
    ZigBee自组网地址分配与路由协议概述
    Zigbee协议栈--Z-Stack的使用
    RT-Thread RTOS
    信息量、互斥信息量和事件标志
  • 原文地址:https://www.cnblogs.com/zouke1220/p/8176483.html
Copyright © 2020-2023  润新知