Maintenance.vue 5.31 KB
<template>
  <div class="markeing-box">
    <Phone class="platform-box" :imgName="'work-platform'">
      <div class="dialogue-content" slot="content">
        <div v-for="item in threadData" :key="item.key">
          <div class="dialogue-content-item">
            <div class="dialogue-content-item-top">
              <div class="dialogue-content-item-top-left">
                <div class="dialogue-content-item-top-img">
                  <img src="../../../assets/images/avatar.png" alt="">
                </div>
                <div>
                  <div>{{ item.name }}</div>
                  <div>{{ item.phone }}</div>
                </div>
              </div>
              <div class="call">拨打</div>
            </div>
            <div class="dialogue-content-item-inner">
              <div>
                车牌号码
                <span>{{ item.carNum }}</span>
              </div>
              <div>
                设备类型
                <span>{{ item.type }}</span>
              </div>
              <div>
                碰撞时间
                <span>{{ item.time }}</span>
              </div>
            </div>
          </div>
        </div>
      </div>
    </Phone>
    <Phone class="enterprise-box" :imgName="'customer-detail'">
      <div class="video-content" slot="content">
        <div class="video-click-content" @click="openVideo"></div>
        <video ref="videoRef" id="videos" muted="muted" controls autoplay loop>
          <!-- <source src="/media/cc0-videos/flower.webm" type="video/webm" /> -->
          <source src="../../../assets/images/video(1).mp4" type="video/mp4" />
        </video>
      </div>
    </Phone>
    <div class="markeing-descript">
      <div class="second-title">维保线索推送</div>
      <div class="descript">大模型识别车辆碰撞并将碰撞信息发送给对接的智慧门店系统,门店专员及时和客户联系,引导车辆进厂维修,提升售后维修产值。</div>
    </div>
    <Dialog :isShow="dialogShow" @closeDialog="closeDialog"></Dialog>
  </div>
</template>
<script>
import Phone from './Phone.vue'
import Dialog from './Dialog.vue'
import { threadData } from '../const/index'
export default {
  name: 'Maintenance',
  components: {
    Phone,
    Dialog
  },
  data() {
    return {
      threadData,
      dialogShow: false
    }
  },
  mounted() {
    this.$refs.videoRef.addEventListener('ended', this.replayVideo);
  },
  beforeDestroy() {
    this.$refs.videoRef.removeEventListener('ended', this.replayVideo);
  },
  methods: {
    openVideo() {
      this.dialogShow = true
    },
    closeDialog() { 
      this.dialogShow = false
    },
    replayVideo() {
      const video = this.$refs.videoRef;
      video.currentTime = 0;
      video.play();
    }
  }
}
</script>
<style lang="scss" scoped>
.markeing-box {
  display: flex;
  align-items: center;
  box-sizing: border-box;
  padding: 2.59vh 1.04vw;
  width: 100%;
  height: 38.52vh;
  background-image: url(../../../assets/images/marketing-ask-bg.png);
  background-size: 100% 100%;
}
.platform-box {
  position: relative;
  .dialogue-content {
    position: absolute;
    top: 8.2vh;
    left: 0.31vw;
    max-height: 21.3vh;
    overflow-y: scroll;
    &-item {
      width: 7.28vw;
      border-radius: 4px;
      background-color: #313951;
      padding: 0.2vw 0.3vh;
      box-sizing: border-box;
      margin-bottom: 0.3vh;
      &-top {
        display: flex;
        justify-content: space-between;
        align-items: center;
        font-weight: 500;
        font-size: 10px;
        color: #ffffffe6;
        margin-bottom: 0.4vw;
        &-left {
          display: flex;
        }
        &-img {
          width: 0.89vw;
          height: 0.89vw;
          margin-right: 0.2vw;
        }
        .call {
          width: 1.35vw;
          height: 1.57vh;
          font-size: 7.1px;
          color: #ffffff;
          text-align: center;
          line-height: 1.57vh;
          background: #3582ee;
          border-radius: 1.57vh;
        }
      }
      &-inner {
        background: #262f47;
        border-radius: 4px;
        font-size: 9px;
        color: #ffffffcc;
        padding: 0.4vw 0.2vw;
      }
    }
  }
}

.enterprise-box {
  margin-left: 0.42vw;
  position: relative;
  .video-click-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 8.28vw;
    height: 3.97vh;
    z-index: 9999;
  }
  .video-content {
    position: absolute;
    top: 5.28vh;
    left: 0.31vw;
    width: 7.28vw;
    height: 7.97vh;
    video {
      width: 100%;
      height: 100%;
      object-fit: cover;
    }
  }
}
.enterprise {
  padding-top: 8vh;
  font-size: 5px;
  color: #ffffff;
  &-item {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    margin: 0.53vh 0.36vw;
    padding: 4px;
  }
}
.markeing-descript {
  width: 11.04vw;
  margin-left: 0.83vw;
  .second-title {
    font-size: 20px;
    text-align: center;
    color: #5894ff;
    background-image: -webkit-linear-gradient(left, #0185f9, #53faff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    margin-bottom: 2.5vh;
  }
  .descript {
    color: #09aef2;
    font-size: 12px;
  }
}
</style>