| | |
| | | name="cluster" |
| | | :style="`height:${height - 56}px;`" |
| | | v-if="showCluster" |
| | | ></el-tab-pane> |
| | | > |
| | | <div class="local-vedio-area"> |
| | | <!-- 搜索 --> |
| | | <div class="navTopSelect"> |
| | | <div class="search-input flex-box"> |
| | | <el-select |
| | | v-model="TreeDataPool.searchCamType" |
| | | placeholder="请选择" |
| | | @change="searchClusterData" |
| | | > |
| | | <el-option |
| | | v-for="item in searchTypeOptions" |
| | | :key="item.value" |
| | | :label="item.label" |
| | | :value="item.value" |
| | | ></el-option> |
| | | </el-select> |
| | | <span style="display: inline-block;padding: 0px 3px;"></span> |
| | | <el-input |
| | | v-model="TreeDataPool.searchInput" |
| | | placeholder="搜索" |
| | | clearable |
| | | @input="querySearchAsync('cluster')" |
| | | > |
| | | <i |
| | | class="el-icon-search el-input__icon" |
| | | style="color:#DCDFE6" |
| | | slot="prefix" |
| | | @click="searchClusterData" |
| | | ></i> |
| | | </el-input> |
| | | </div> |
| | | </div> |
| | | <div class="cluster-list"> |
| | | <tree-menu |
| | | ref="tree" |
| | | :app="appName" |
| | | :treeName="'localTree'" |
| | | :node="TreeDataPool.clusterData" |
| | | :height="height" |
| | | @addDevice="addCamera" |
| | | @import="importCameras" |
| | | /> |
| | | </div> |
| | | </div> |
| | | </el-tab-pane> |
| | | <el-tab-pane |
| | | label="数据栈" |
| | | name="dataStack" |
| | |
| | | return true; |
| | | }, |
| | | showCam() { |
| | | return this.appName === "Camera" || (this.appName === "Search" && (this.buttonAuthority.indexOf("search:camera") >= 0 || this.isAdmin)); |
| | | return this.appName === "Camera" || this.appName === 'Cluster' || (this.appName === "Search" && (this.buttonAuthority.indexOf("search:camera") >= 0 || this.isAdmin)); |
| | | }, |
| | | showCluster() { |
| | | return this.appName === "Cluster"; |
| | |
| | | }; |
| | | }, |
| | | created() { |
| | | console.log(this.appName) |
| | | console.log(this.showCam) |
| | | if (this.showCam) { |
| | | this.TreeDataPool.treeActiveName = "camera" |
| | | this.TreeDataPool.fetchTreeData(); |
| | |
| | | this.DataStackPool.fetchFiles(); |
| | | |
| | | } |
| | | if (this.showCluster) { |
| | | this.TreeDataPool.treeActiveName = "cluster" |
| | | this.TreeDataPool.fetchClusterTree(); |
| | | } |
| | | }, |
| | | methods: { |
| | | searchAreaData() { |
| | |
| | | }, |
| | | searchDataStack() { |
| | | this.DataStackPool.fetchFiles(); |
| | | }, |
| | | searchClusterData () { |
| | | this.TreeDataPool.fetchClusterTree(); |
| | | }, |
| | | lockSwitch() { |
| | | this.TreeDataPool.readonly = !this.TreeDataPool.readonly; |
| | |
| | | color: #606266; |
| | | } |
| | | } |
| | | .flex-box{ |
| | | display: flex; |
| | | } |
| | | </style> |