hanbaoshan
2021-02-28 72f553661a74b225c89310d3fb3d78f3ebe35f82
src/pages/shuohuangMonitorAnalyze/components/searchForVideoAnalyze.vue
@@ -112,6 +112,7 @@
                  :key="ind"
                  :index="index + '-' + ind"
                  @click="checkOption(config, option)"
                  class="highlevel-option"
                >{{ option.name }}</el-menu-item>
              </el-submenu>
            </el-menu>
@@ -153,7 +154,7 @@
        </div>
      </div>
      <div class="content" v-show="showType == 'menu'">
        <el-row :gutter="20" :align="bottom">
        <el-row :gutter="20" >
          <el-col :xs="8" :sm="6" :md="6" :lg="6" v-for="data in tabData" :key="data.id">
            <div class="card">
              <div class="video-wrap" @click="checkVideoDetail(data)">
@@ -181,6 +182,7 @@
                <div class="mark-info">
                  <div class="abnormal" v-if="data.LableLst && data.LableLst.length">
                    <span
                      class="abnormal-label"
                      v-for="(label, index) in data.LableLst"
                      :key="index"
                    >{{ label.Desc +(index==data.LableLst.length-1?"":",")}}</span>
@@ -204,7 +206,7 @@
                </div>
              </div>
              <div class="star" @click="toggleFollow(data)">
                <i :class="[data.IsFollow ? 'follow' : '', 'el-icon-star-off']"></i>
                <i class="iconfont" :class="[data.IsFollow ? 'follow' : '', 'iconguanzhu']"></i>
              </div>
            </div>
          </el-col>
@@ -231,13 +233,18 @@
              >{{ scope.row.VideoName }}</div>
            </template>
          </el-table-column>
          <el-table-column label="大小" prop="VideoSize" sortable></el-table-column>
          <el-table-column label="修改日期" prop="UpdatedAt" sortable></el-table-column>
          <el-table-column label="创建日期" prop="CreatedAt" sortable></el-table-column>
          <el-table-column label="修改日期" prop="VideoUpdateDate" sortable></el-table-column>
          <el-table-column label="创建日期" prop="VideoCreateDate" sortable></el-table-column>
          <el-table-column label="操作">
            <template slot-scope="scope">
              <div class="operation">
                <i class="el-icon-star-off" @click="toggleFollow(scope.row)"></i>
                <div class="star" @click="toggleFollow(scope.row)">
                  <i class="iconfont" :class="[scope.row.IsFollow ? 'follow' : '', 'iconguanzhu']"></i>
                </div>
                <!-- <i class="el-icon-star-off" @click="toggleFollow(scope.row)"></i> -->
              </div>
            </template>
          </el-table-column>
@@ -271,11 +278,11 @@
        :visible="eventDialogVisible"
        @close="eventDialogVisible = false"
      >
      <div class="title" slot="title">
        <i class="el-icon-connection"></i>
        <span>shoubi视频</span>
      </div>
        <event-videos :eventDetail="curEventDetail"></event-videos>
        <div class="title" slot="title">
          <i class="el-icon-connection"></i>
          <span>{{curEvName}}视频</span>
        </div>
        <event-videos :eventVideoArr="eventVideoArr"></event-videos>
      </el-dialog>
    </div>
  </div>
@@ -290,6 +297,7 @@
  getLabelMap,
  delLabel,
  editLabel,
  getEventVideo
} from "@/api/shuohuang";
import VideoAnalyze from "./videoAnalyze";
import EventVideos from "./eventVideos";
@@ -312,7 +320,7 @@
      curTabPage: 1,
      curTablePage: 1,
      tabPageSize: 8,
      pageSizes: [2, 8, 12, 24],
      pageSizes: [ 8, 12, 24],
      tabTotal: 0,
      tablePageSize: 8,
      tableTotal: 0,
@@ -412,7 +420,8 @@
      labelDialogVisible: false,
      selectedVideo: {},
      eventDialogVisible: false,
      curEventDetail: {}
      curEvName: '',
      eventVideoArr: []
    };
  },
  watch: {
@@ -430,6 +439,11 @@
    checkEventVideo (label) {
      this.eventDialogVisible = true;
      this.curEventDetail = label;
      let _this = this;
      getEventVideo({ Event: label.Event, LkgID: label.ParentID }).then(res => {
        _this.eventVideoArr = res.data;
        _this.curEvName = label.Event;
      })
    },
    handleTabSizeChange (size) {
      this.tabPageSize = size;
@@ -526,7 +540,6 @@
        } else {
          _this.tabTotal = res.total;
          _this.tabData = res.data;
          // debugger
          _this.tabData = _this.tabData.map(function (item) {
            const set = new Set()
            item.LableLst.forEach(function (label) {
@@ -682,7 +695,9 @@
<style lang="scss">
.search-for-video-analyze {
  padding: 20px 30px;
  //padding: 20px 30px;
  //出横向滚动条
  padding: 20px 40px;
  .flex-box {
    display: flex;
  }
@@ -745,6 +760,8 @@
          width: 100px;
          text-align: left;
          background: #f3f3f3;
          color: rgb(133, 133, 133);
          background: #ecf0fc;
        }
        .options-wrap {
          flex: 1;
@@ -776,23 +793,25 @@
          justify-content: flex-end;
          .more {
            margin-top: 6px;
            padding: 0px 12px;
            padding: 0px 6px;
            border: 1px solid #ccc;
            margin-right: 10px;
            width: 48px;
            width: 44px;
            height: 26px;
            line-height: 26px;
            border-radius: 2px;
            &:hover {
              color: #6486e7;
            }
          }
          .multCheck {
            margin-top: 6px;
            width: 48px;
            width: 44px;
            height: 26px;
            line-height: 26px;
            padding: 0px 12px;
            padding: 0px 6px;
            border: 1px solid #ccc;
            border-radius: 2px;
            &:hover {
              color: #7695ec;
              border-color: #7695ec;
@@ -819,6 +838,8 @@
            height: 40px;
            line-height: 40px;
            border: none;
            color: #2c3e50;
            font-size: 12px;
          }
          .el-menu--popup {
            display: flex;
@@ -826,6 +847,13 @@
            li.el-menu-item {
              display: inline-block;
              min-width: auto;
            }
          }
          .highlevel-option {
            font-size: 12px;
            color: #2c3e50;
            &:hover {
              color: #6486e7;
            }
          }
        }
@@ -838,8 +866,7 @@
  .data-list {
    margin-top: 20px;
    .header-bar {
      padding-bottom: 5px;
      border-bottom: 1px solid #ddd;
      padding-bottom: 10px;
      .left {
        float: left;
        display: flex;
@@ -872,11 +899,20 @@
      }
    }
    .content {
      padding-top: 14px;
      //padding-top: 14px;
      background: #f5f5f5;
      background: #fff;
      margin: 0 -30px;
      margin-bottom: -30px;
      padding: 0;
      // .el-row {
      //   display: flex;
      //   flex-wrap: wrap;
      // }
      .el-row {
        padding-top: 20px;
        background: #f5f5f5;
      }
      .el-col {
        margin-bottom: 10px;
      }
@@ -884,9 +920,13 @@
        cursor: pointer;
        position: relative;
        text-align: left;
        border: 1px solid #dedede;
        background: #fff;
        border-radius: 5px;
        height: 420px;
        height: 360px;
        margin-bottom: 10px;
        &:hover {
          box-shadow: 3px 2px 5px 1px rgba(0, 0, 0, 0.3);
        }
        .video-wrap {
          border-radius: 3px;
          width: 100%;
@@ -908,7 +948,7 @@
          padding: 10px;
          .base-info {
            > div {
              margin-bottom: 5px;
              margin-bottom: 1px;
            }
            label {
              color: #999;
@@ -920,6 +960,9 @@
            color: #3d68e1;
            .abnormal {
              color: red;
              overflow: hidden;
              text-overflow: ellipsis;
              white-space: nowrap;
            }
            .event-tag {
              margin-top: 10px;
@@ -955,11 +998,19 @@
        }
        .operation {
          cursor: pointer;
          .star{
            color: #ccc;
          }
          .follow{
            color: #409eff;
          }
        }
      }
      .pagination-center {
        text-align: center;
        margin: 10px auto;
        margin: 0 -10px;
        padding: 10px 0 20px;
        background: #f5f5f5;
      }
    }
    .dialog-video {
@@ -997,7 +1048,7 @@
        width: 1000px;
        height: 800px;
        background: #efefef;
        .el-dialog__body{
        .el-dialog__body {
          padding: 0;
        }
      }