<template>
  <div>
    <div class="topbar">
      <div class="topbar_left" @click="goback">
        <svg class="icon" aria-hidden="true">
          <use xlink:href="#icon-fanhui"></use>
        </svg>
      </div>
      <div class="topbar_middle">
        电竞椅 <svg class="icon" aria-hidden="true">
          <use xlink:href="#icon-xiala"></use>
        </svg>
      </div>
      <div class="topbar_right">
        <svg class="icon" aria-hidden="true">
          <use xlink:href="#icon-caidan"></use>
        </svg>
      </div>
    </div>

    <div id="quotelist">

      <div class="quote_search">
        <svg class="icon" aria-hidden="true">
          <use xlink:href="#icon-sousuo"></use>
        </svg>
        搜索
      </div>

      <div v-for="(item,index) in qlist" :key="index">
        <quote-list :qlist="item"></quote-list>
      </div>

    </div>

    <div class="quote_mask"  v-show="ifch==1"></div>
    <div class="quote_mtrltype_ch" v-show="ifch==1">
      <div class="quote_mtrltype_ch_his">报价历史</div>
      <div class="quote_mtrltype_ch_title">产品分类</div>
      <div class="quote_mtrltype_ch_type">
        <div>经理椅</div>
        <div>职员椅</div>
        <div>会议椅</div>
        <div>休闲椅</div>
        <div>电竞椅</div>
        <div>办公网椅</div>
        <div>办公布椅</div>

      </div>
    </div>

  </div>
</template>
<script>
  import QuoteList from "./components/quotelist";
  export default {
    name: 'quote',
    components: {
      QuoteList
    },
    data() {
      return {
        qlist: [{mtrlname:"S-102电竞椅",mtrlmode:"58*69*130CM",nw:"18KG",gw:"19.8KG",pack:'40Q":420箱',price:421,saleqty:12356,picurl:"S-102.jpg"},
        {mtrlname:"S-103电竞椅",mtrlmode:"55.5*66*129CM",nw:"17.5KG",gw:"19KG",pack:'40Q":424箱',price:380,saleqty:22491,picurl:"S-103.jpg"},
        {mtrlname:"S-150电竞椅",mtrlmode:"55.5*66*129CM",nw:"17.5KG",gw:"19KG",pack:'40Q":424箱',price:375,saleqty:34512,picurl:"S-150.jpg"},
        {mtrlname:"S-152电竞椅",mtrlmode:"55.5*66*129CM",nw:"17.5KG",gw:"19KG",pack:'40Q":424箱',price:385,saleqty:12478,picurl:"S-152.jpg"},
        {mtrlname:"S-156电竞椅",mtrlmode:"55.5*66*129CM",nw:"17.5KG",gw:"19KG",pack:'40Q":424箱',price:365,saleqty:16843,picurl:"S-156.jpg"},
        {mtrlname:"S-200电竞椅",mtrlmode:"55.5*66*108CM",nw:"16.5KG",gw:"18.7KG",pack:'40Q":435箱',price:321,saleqty:18791,picurl:"S-200.jpg"}
        ],
        ifch: 0 //点击顶部选择类别 0-没有显示  1-显示 
      }
    },
    methods: {
      goback() {
        {
          history.back();
        }
      }
    }
  }

</script>
<style>
  body {
    margin: 0;
    padding: 0;
    /* background-color: #fff; */
    font-family: "微软雅黑";
  }

  .topbar {
    min-height: 44px;
    border-bottom: 1px solid #e5e5e5;
    background: #fff;
    position: fixed;
    width: 100%;
    z-index: 9999;
    display: flex;
    font-size: 18px;
    align-items: center;
  }

  .topbar_left {
    flex: 0 0 20px;
    margin-left: 10px;
  }

  .topbar_middle {
    text-align: center;
    flex: 0 0 89%;
  }

  .topbar_right {
    flex: 0 0 20px;
    position: absolute;
    right: 10px;
  }

  #quotelist {
    position: absolute;
    top: 44px;
    width: 100%;
  }
  .quote_search {
    background-color: #f7f7f7;
    margin: 5px 10px;
    padding: 0px 5px 0px 20px;
    font-size: 14px;
    line-height: 30px;
    border-radius: 15px;
    color: #777777
  }
  .quote_mask {
    height: 100%;
    width: 100%;
    background-color: #1d1d1d;
     opacity: 0.8;  
    position: fixed;
    top: 0px;
    z-index: 9998;
  }

  .quote_mtrltype_ch {
    z-index: 9999;
    background-color: #ffffff;
    position: fixed;
    top: 40px;
    /* height: 220px; */
    width: 100%;
    border-bottom-left-radius: 15px;
    border-bottom-right-radius: 15px;
    padding: 10px 0;
    /* border-bottom: 1px solid #e5e5e5; */
  }

.quote_mtrltype_ch_his{
    margin: 0 20px 10px 20px;
    border-radius: 15px;
    color: #888;
    background-color: #f8f8f8;
    padding: 5px 15px;
    font-size: 12px;
    width:50px;
}

.quote_mtrltype_ch_title{
    font-size: 15px;
    font-weight: bold;
    margin: 5px 10px;
}

  .quote_mtrltype_ch_type {
    display: flex;
    flex-wrap: wrap;
    justify-content:space-between;
  }

  .quote_mtrltype_ch_type div {
    margin: 10px 20px 10px 20px;
    border-radius: 15px;
    color: #888;
    background-color: #f8f8f8;
    padding: 5px 15px;
    font-size: 12px;

  }

</style>
