9 changed files with 775 additions and 76 deletions
			
			
		- 
					29src/assets/styles/archives-manage.scss
 - 
					2src/components/Crud/crud.js
 - 
					107src/views/archiveKeeping/deviceManage/module/autoChildDevice.vue
 - 
					216src/views/archiveKeeping/deviceManage/module/childDevice.vue
 - 
					96src/views/archiveKeeping/deviceManage/module/childForm.vue
 - 
					75src/views/archiveKeeping/deviceManage/module/detail.vue
 - 
					128src/views/archiveKeeping/deviceManage/module/devicePreview.vue
 - 
					68src/views/archiveKeeping/deviceManage/module/videoPreview.vue
 - 
					86src/views/archiveKeeping/deviceManage/tableList.vue
 
@ -0,0 +1,107 @@ | 
			
		|||||
 | 
				<template> | 
			
		||||
 | 
				  <!--表单组件--> | 
			
		||||
 | 
				  <el-dialog class="childDeviceDialog" append-to-body :close-on-click-modal="false" :modal-append-to-body="false" :before-close="handleCloseDialog" :visible="autoDeviceVisible" title="自动获取子设备-环境控制主机"> | 
			
		||||
 | 
				    <div class="setting-dialog"> | 
			
		||||
 | 
				      <div class="childDevice-header"> | 
			
		||||
 | 
				        <div class="childDevice-info"> | 
			
		||||
 | 
				          <p>当前设备:<span>计通 - 环境控制111 - HK001</span></p> | 
			
		||||
 | 
				          <p>IPv4地址:<span>192.168.1.111</span></p> | 
			
		||||
 | 
				          <p>端口:<span>5000</span></p> | 
			
		||||
 | 
				        </div> | 
			
		||||
 | 
				      </div> | 
			
		||||
 | 
				      <el-table | 
			
		||||
 | 
				        ref="table" | 
			
		||||
 | 
				        :data="childDeviceTable" | 
			
		||||
 | 
				        row-key="id" | 
			
		||||
 | 
				        highlight-current-row | 
			
		||||
 | 
				        style="min-width: 100%;" | 
			
		||||
 | 
				        @selection-change="selectionChangeHandler" | 
			
		||||
 | 
				        @row-click="clickRowHandler" | 
			
		||||
 | 
				      > | 
			
		||||
 | 
				        <el-table-column type="selection" align="center" width="55" /> | 
			
		||||
 | 
				        <el-table-column label="序号" type="index" width="55" /> | 
			
		||||
 | 
				        <el-table-column label="设备编号" prop="num" min-width="140" /> | 
			
		||||
 | 
				        <el-table-column label="设备名称" prop="deviceName" min-width="140" /> | 
			
		||||
 | 
				        <el-table-column label="分类名称" prop="deviceTypeId.name" min-width="100" /> | 
			
		||||
 | 
				        <el-table-column label="区域名称" prop="deviceTypeId.name" min-width="100" /> | 
			
		||||
 | 
				      </el-table> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				    <div slot="footer" class="dialog-footer"> | 
			
		||||
 | 
				      <div class="selectionNum">已选中<span>{{ selections.length }}</span>个</div> | 
			
		||||
 | 
				      <el-button type="text" @click="handleCloseDialog">关闭</el-button> | 
			
		||||
 | 
				      <el-button type="primary" @click="autoDeviceVisible=false">确定</el-button> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				  </el-dialog> | 
			
		||||
 | 
				</template> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<script> | 
			
		||||
 | 
				export default { | 
			
		||||
 | 
				  components: { }, | 
			
		||||
 | 
				  data() { | 
			
		||||
 | 
				    return { | 
			
		||||
 | 
				      childDeviceTable: [], | 
			
		||||
 | 
				      selections: [], | 
			
		||||
 | 
				      autoDeviceVisible: false | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  watch: {}, | 
			
		||||
 | 
				  created() { | 
			
		||||
 | 
				    this.childDeviceTable = [{}, {}, {}] | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  methods: { | 
			
		||||
 | 
				    clickRowHandler(row) { | 
			
		||||
 | 
				      this.$refs.table.toggleRowSelection(row) | 
			
		||||
 | 
				    }, | 
			
		||||
 | 
				    selectionChangeHandler(val) { | 
			
		||||
 | 
				      this.selections = val | 
			
		||||
 | 
				    }, | 
			
		||||
 | 
				    handleCloseDialog(done) { | 
			
		||||
 | 
				      this.autoDeviceVisible = false | 
			
		||||
 | 
				      // 关闭弹框 | 
			
		||||
 | 
				      done() | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				</script> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<style lang="scss" scoped> | 
			
		||||
 | 
				.childDeviceDialog{ | 
			
		||||
 | 
				  ::v-deep .el-dialog { | 
			
		||||
 | 
				    width: 860px; | 
			
		||||
 | 
				    .el-dialog__body{ | 
			
		||||
 | 
				      padding: 6px 0 30px 0 !important; | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				.childDevice-info{ | 
			
		||||
 | 
				  display: flex; | 
			
		||||
 | 
				  justify-content: flex-end; | 
			
		||||
 | 
				  padding: 9px 12px 11px 12px; | 
			
		||||
 | 
				  margin-bottom: 24px; | 
			
		||||
 | 
				  background: rgba(151,199,255,0.2); | 
			
		||||
 | 
				  border-radius: 3px; | 
			
		||||
 | 
				  border: 1px solid #97C7FF; | 
			
		||||
 | 
				  color: #0C0E1E; | 
			
		||||
 | 
				  p:first-child{ | 
			
		||||
 | 
				    flex: 1; | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				  span{ | 
			
		||||
 | 
				    color: #545B65; | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				  p:last-child{ | 
			
		||||
 | 
				    margin-left: 26px; | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				.selectionNum{ | 
			
		||||
 | 
				  padding: 0 15px; | 
			
		||||
 | 
				  height: 32px; | 
			
		||||
 | 
				  line-height: 32px; | 
			
		||||
 | 
				  background: rgba(117,197,255,0.2); | 
			
		||||
 | 
				  color: #0C0E1E; | 
			
		||||
 | 
				  margin-right: 16px; | 
			
		||||
 | 
				  span{ | 
			
		||||
 | 
				    padding: 0 3px; | 
			
		||||
 | 
				    color: #FF6F31; | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				</style> | 
			
		||||
@ -0,0 +1,96 @@ | 
			
		|||||
 | 
				<template> | 
			
		||||
 | 
				  <!--表单组件--> | 
			
		||||
 | 
				  <el-dialog append-to-body :close-on-click-modal="false" :modal-append-to-body="false" :before-close="handleCloseDialog" :visible="childFormVisible" :title="childFormTitle"> | 
			
		||||
 | 
				    <div class="setting-dialog"> | 
			
		||||
 | 
				      <el-form ref="form" inline :model="form" :rules="rules" size="small" label-width="100px"> | 
			
		||||
 | 
				        <el-row> | 
			
		||||
 | 
				          <el-form-item label="所属设备" prop="deviceParent"> | 
			
		||||
 | 
				            <el-input v-model="form.deviceParent" style="width: 565px;" disabled /> | 
			
		||||
 | 
				          </el-form-item> | 
			
		||||
 | 
				        </el-row> | 
			
		||||
 | 
				        <el-row v-if="childType"> | 
			
		||||
 | 
				          <el-form-item label="通道名称" prop="channelName"> | 
			
		||||
 | 
				            <el-input v-model="form.channelName" /> | 
			
		||||
 | 
				          </el-form-item> | 
			
		||||
 | 
				          <el-form-item label="通道" prop="channelNum" style="margin-right: 0;"> | 
			
		||||
 | 
				            <el-input v-model="form.channelNum" /> | 
			
		||||
 | 
				          </el-form-item> | 
			
		||||
 | 
				        </el-row> | 
			
		||||
 | 
				        <el-row v-else> | 
			
		||||
 | 
				          <el-form-item label="设备编号" prop="deviceCode"> | 
			
		||||
 | 
				            <el-input v-model="form.deviceCode" /> | 
			
		||||
 | 
				          </el-form-item> | 
			
		||||
 | 
				          <el-form-item label="设备名称" prop="deviceName" style="margin-right: 0;"> | 
			
		||||
 | 
				            <el-input v-model="form.deviceName" /> | 
			
		||||
 | 
				          </el-form-item> | 
			
		||||
 | 
				        </el-row> | 
			
		||||
 | 
				        <el-form-item label="备注" prop="remark"> | 
			
		||||
 | 
				          <el-input v-model="form.remark" type="textarea" :rows="4" style="width: 565px;" /> | 
			
		||||
 | 
				        </el-form-item> | 
			
		||||
 | 
				      </el-form> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				    <div slot="footer" class="dialog-footer" style="margin-top: 0;"> | 
			
		||||
 | 
				      <el-button type="text" @click="handleCloseDialog">取消</el-button> | 
			
		||||
 | 
				      <el-button type="primary" @click="handleComfireVideo">确定</el-button> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				  </el-dialog> | 
			
		||||
 | 
				</template> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<script> | 
			
		||||
 | 
				export default { | 
			
		||||
 | 
				  props: { | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  data() { | 
			
		||||
 | 
				    return { | 
			
		||||
 | 
				      childType: true, | 
			
		||||
 | 
				      childFormVisible: false, | 
			
		||||
 | 
				      childFormTitle: '新增', | 
			
		||||
 | 
				      form: { | 
			
		||||
 | 
				        deviceParent: null, | 
			
		||||
 | 
				        channelName: null, | 
			
		||||
 | 
				        channelNum: null, | 
			
		||||
 | 
				        remark: null | 
			
		||||
 | 
				      }, | 
			
		||||
 | 
				      rules: { | 
			
		||||
 | 
				        deviceParent: [ | 
			
		||||
 | 
				          { required: true, message: '所属设备不可为空', trigger: 'blur' } | 
			
		||||
 | 
				        ], | 
			
		||||
 | 
				        channelName: [ | 
			
		||||
 | 
				          { required: true, message: '通道名称不可为空', trigger: 'blur' } | 
			
		||||
 | 
				        ], | 
			
		||||
 | 
				        channelNum: [ | 
			
		||||
 | 
				          { required: true, message: '通道不可为空', trigger: 'blur' } | 
			
		||||
 | 
				        ], | 
			
		||||
 | 
				        deviceCode: [ | 
			
		||||
 | 
				          { required: true, message: '设备编号不可为空', trigger: 'blur' } | 
			
		||||
 | 
				        ], | 
			
		||||
 | 
				        deviceName: [ | 
			
		||||
 | 
				          { required: true, message: '设备名称不可为空', trigger: 'blur' } | 
			
		||||
 | 
				        ] | 
			
		||||
 | 
				      } | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  watch: { | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  created() { | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  methods: { | 
			
		||||
 | 
				    handleComfireVideo() { | 
			
		||||
 | 
				      this.$refs.form.validate((valid) => { | 
			
		||||
 | 
				        if (valid) { | 
			
		||||
 | 
				          this.childFormVisible = false | 
			
		||||
 | 
				          console.log('success') | 
			
		||||
 | 
				        } else { | 
			
		||||
 | 
				          console.log('error') | 
			
		||||
 | 
				        } | 
			
		||||
 | 
				      }) | 
			
		||||
 | 
				    }, | 
			
		||||
 | 
				    handleCloseDialog() { | 
			
		||||
 | 
				      this.childFormVisible = false | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				</script> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<style lang="scss" scoped> | 
			
		||||
 | 
				</style> | 
			
		||||
@ -0,0 +1,75 @@ | 
			
		|||||
 | 
				<template> | 
			
		||||
 | 
				  <el-dialog class="detail-dialog" :title="detailTitle" append-to-body :close-on-click-modal="false" :modal-append-to-body="false" :visible.sync="detailVisible" :before-close="handleClose"> | 
			
		||||
 | 
				    <span class="dialog-right-top" /> | 
			
		||||
 | 
				    <span class="dialog-left-bottom" /> | 
			
		||||
 | 
				    <div class="setting-dialog"> | 
			
		||||
 | 
				      <div class="detail-tab tab-content"> | 
			
		||||
 | 
				        <!-- tab --> | 
			
		||||
 | 
				        <ul class="tab-nav" style="padding: 0;"> | 
			
		||||
 | 
				          <li :class="{'active-tab-nav': activeIndex == 0}" @click="changeActiveTab(0)">基本信息</li> | 
			
		||||
 | 
				          <li v-if="(selectedDeviceType==='网络视频录像机(NVR)' || selectedDeviceType==='环境监控主机')" :class="{'active-tab-nav': activeIndex == 1}" @click="changeActiveTab(1)">子设备列表</li> | 
			
		||||
 | 
				        </ul> | 
			
		||||
 | 
				        <!-- 基本信息 --> | 
			
		||||
 | 
				        <div v-if="activeIndex==0" class="base-info item-content"> | 
			
		||||
 | 
				          <el-row> | 
			
		||||
 | 
				            <el-col v-for="(item,index) in DetailsInfoData" :key="index" class="base-info-item"> | 
			
		||||
 | 
				              <span>{{ item.fieldCnName }}:</span> | 
			
		||||
 | 
				              <p>{{ item.context }}</p> | 
			
		||||
 | 
				            </el-col> | 
			
		||||
 | 
				          </el-row> | 
			
		||||
 | 
				        </div> | 
			
		||||
 | 
				        <!-- 子设备列表 --> | 
			
		||||
 | 
				        <div v-if="activeIndex==1 && (selectedDeviceType==='网络视频录像机(NVR)' || selectedDeviceType==='环境监控主机')" class="item-content" /> | 
			
		||||
 | 
				      </div> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				    <div slot="footer" class="dialog-footer"> | 
			
		||||
 | 
				      <el-button v-if=" selectedDeviceType === '网络视频录像机(NVR)' || selectedDeviceType ==='环境监控主机'" class="device-child-btn" @click="ChildDevice"><i class="iconfont icon-zishebeiguanli" />子设备管理</el-button> | 
			
		||||
 | 
				      <el-button type="primary" @click="detailVisible=false">确定</el-button> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				  </el-dialog> | 
			
		||||
 | 
				</template> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<script> | 
			
		||||
 | 
				export default { | 
			
		||||
 | 
				  name: 'Detail', | 
			
		||||
 | 
				  components: { }, | 
			
		||||
 | 
				  mixins: [], | 
			
		||||
 | 
				  props: { | 
			
		||||
 | 
				    selectedDeviceType: { | 
			
		||||
 | 
				      type: String, | 
			
		||||
 | 
				      default: function() { | 
			
		||||
 | 
				        return '' | 
			
		||||
 | 
				      } | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  data() { | 
			
		||||
 | 
				    return { | 
			
		||||
 | 
				      detailTitle: '', | 
			
		||||
 | 
				      activeIndex: 0, | 
			
		||||
 | 
				      detailVisible: false, | 
			
		||||
 | 
				      DetailsInfoData: [] | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  mounted() { | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  methods: { | 
			
		||||
 | 
				    changeActiveTab(index) { | 
			
		||||
 | 
				      this.activeIndex = index | 
			
		||||
 | 
				    }, | 
			
		||||
 | 
				    ChildDevice() { | 
			
		||||
 | 
				      this.$emit('childDevice') | 
			
		||||
 | 
				    }, | 
			
		||||
 | 
				    // 删除 - 关闭 | 
			
		||||
 | 
				    handleClose(done) { | 
			
		||||
 | 
				      this.detailVisible = false | 
			
		||||
 | 
				      done() | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				</script> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<style lang="scss" scoped> | 
			
		||||
 | 
				.base-info{ | 
			
		||||
 | 
				  background: #F6F8FC; | 
			
		||||
 | 
				} | 
			
		||||
 | 
				</style> | 
			
		||||
@ -0,0 +1,128 @@ | 
			
		|||||
 | 
				<template> | 
			
		||||
 | 
				  <!--表单组件--> | 
			
		||||
 | 
				  <el-dialog append-to-body :close-on-click-modal="false" :modal-append-to-body="false" :before-close="handleCloseDialog" :visible="deviceVisible" title="实时数速览-子设备"> | 
			
		||||
 | 
				    <div class="setting-dialog"> | 
			
		||||
 | 
				      <div class="preview-info"> | 
			
		||||
 | 
				        <p>当前设备:<span>空气质量检测设备01 - jt01#S3101</span></p> | 
			
		||||
 | 
				        <p>数据获取时间:<span>2016-09-21 08:50:08 <i class="iconfont icon-shuaxin" /></span></p> | 
			
		||||
 | 
				      </div> | 
			
		||||
 | 
				      <el-table | 
			
		||||
 | 
				        ref="table" | 
			
		||||
 | 
				        :data="tableData" | 
			
		||||
 | 
				        row-key="id" | 
			
		||||
 | 
				        highlight-current-row | 
			
		||||
 | 
				        style="min-width: 100%;" | 
			
		||||
 | 
				        @selection-change="selectionChangeHandler" | 
			
		||||
 | 
				        @row-click="clickRowHandler" | 
			
		||||
 | 
				      > | 
			
		||||
 | 
				        <el-table-column type="index" label="序号" align="center" width="55" /> | 
			
		||||
 | 
				        <el-table-column label="参数编号" prop="code" min-width="80" /> | 
			
		||||
 | 
				        <el-table-column label="参数名称" prop="name" width="90" /> | 
			
		||||
 | 
				        <el-table-column label="当前值" prop="value" min-width="100" align="center"> | 
			
		||||
 | 
				          <template slot-scope="scope"> | 
			
		||||
 | 
				            <span :class="['row-state', scope.row.value > 60 ? 'cancel-state': 'end-state']">{{ scope.row.value }}</span> | 
			
		||||
 | 
				          </template> | 
			
		||||
 | 
				        </el-table-column> | 
			
		||||
 | 
				        <el-table-column label="值单位" prop="unit" min-width="60" /> | 
			
		||||
 | 
				        <el-table-column label="描述" prop="remark" min-width="140"> | 
			
		||||
 | 
				          <template slot-scope="scope"> | 
			
		||||
 | 
				            {{ scope.row.remark ? scope.row.remark : '-' }} | 
			
		||||
 | 
				          </template> | 
			
		||||
 | 
				        </el-table-column> | 
			
		||||
 | 
				      </el-table> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				    <div slot="footer" class="dialog-footer" style="margin-top: 0;"> | 
			
		||||
 | 
				      <el-button type="primary" @click="deviceVisible=false">关闭</el-button> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				  </el-dialog> | 
			
		||||
 | 
				</template> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<script> | 
			
		||||
 | 
				export default { | 
			
		||||
 | 
				  props: { | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  data() { | 
			
		||||
 | 
				    return { | 
			
		||||
 | 
				      deviceVisible: false, | 
			
		||||
 | 
				      tableData: [], | 
			
		||||
 | 
				      selections: [] | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  watch: { | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  created() { | 
			
		||||
 | 
				    this.tableData = [ | 
			
		||||
 | 
				      { | 
			
		||||
 | 
				        'code': 'D_HA4_001', | 
			
		||||
 | 
				        'name': '温度', | 
			
		||||
 | 
				        'value': 24, | 
			
		||||
 | 
				        'unit': '°C', | 
			
		||||
 | 
				        'remark': null | 
			
		||||
 | 
				      }, | 
			
		||||
 | 
				      { | 
			
		||||
 | 
				        'code': 'D_HA4_002', | 
			
		||||
 | 
				        'name': '湿度', | 
			
		||||
 | 
				        'value': 62, | 
			
		||||
 | 
				        'unit': '%', | 
			
		||||
 | 
				        'remark': null | 
			
		||||
 | 
				      }, | 
			
		||||
 | 
				      { | 
			
		||||
 | 
				        'code': 'D_HA4_003', | 
			
		||||
 | 
				        'name': '二氧化碳', | 
			
		||||
 | 
				        'value': 33.3, | 
			
		||||
 | 
				        'unit': 'ppm', | 
			
		||||
 | 
				        'remark': null | 
			
		||||
 | 
				      }, | 
			
		||||
 | 
				      { | 
			
		||||
 | 
				        'code': 'D_HA4_004', | 
			
		||||
 | 
				        'name': 'PM2.5', | 
			
		||||
 | 
				        'value': 15.6, | 
			
		||||
 | 
				        'unit': 'ug/m3', | 
			
		||||
 | 
				        'remark': null | 
			
		||||
 | 
				      }, | 
			
		||||
 | 
				      { | 
			
		||||
 | 
				        'code': 'D_HA4_005', | 
			
		||||
 | 
				        'name': 'PM10', | 
			
		||||
 | 
				        'value': 16.2, | 
			
		||||
 | 
				        'unit': 'ug/m3', | 
			
		||||
 | 
				        'remark': null | 
			
		||||
 | 
				      } | 
			
		||||
 | 
				    ] | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  methods: { | 
			
		||||
 | 
				    clickRowHandler(row) { | 
			
		||||
 | 
				      this.$refs.table.toggleRowSelection(row) | 
			
		||||
 | 
				    }, | 
			
		||||
 | 
				    selectionChangeHandler(val) { | 
			
		||||
 | 
				      this.selections = val | 
			
		||||
 | 
				    }, | 
			
		||||
 | 
				    handleCloseDialog() { | 
			
		||||
 | 
				      this.deviceVisible = false | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				</script> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<style lang="scss" scoped> | 
			
		||||
 | 
				::v-deep .el-dialog { | 
			
		||||
 | 
				  width: 860px; | 
			
		||||
 | 
				  .el-dialog__body{ | 
			
		||||
 | 
				    padding: 14px 0 30px 0 !important; | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				.preview-info{ | 
			
		||||
 | 
				  display: flex; | 
			
		||||
 | 
				  justify-content: space-between; | 
			
		||||
 | 
				  align-items: center; | 
			
		||||
 | 
				  color: #0C0E1E; | 
			
		||||
 | 
				  margin-bottom: 18px; | 
			
		||||
 | 
				  span{ | 
			
		||||
 | 
				    color: #545B65; | 
			
		||||
 | 
				    i{ | 
			
		||||
 | 
				      font-size: 12px; | 
			
		||||
 | 
				      padding-left: 3px; | 
			
		||||
 | 
				      color: #A6ADB6; | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				</style> | 
			
		||||
@ -0,0 +1,68 @@ | 
			
		|||||
 | 
				<template> | 
			
		||||
 | 
				  <!--表单组件--> | 
			
		||||
 | 
				  <el-dialog append-to-body :close-on-click-modal="false" :modal-append-to-body="false" :before-close="handleCloseDialog" :visible="videoVisible" title="实时监控"> | 
			
		||||
 | 
				    <div class="setting-dialog"> | 
			
		||||
 | 
				      <div class="preview-info">当前设备:<span>视频监控110-SP001 [ 1#摄像机 ]</span></div> | 
			
		||||
 | 
				      <div class="default-img"> | 
			
		||||
 | 
				        <img :src="'data:image/jpeg;base64,'+ srcImg" alt="" :onerror="defaultImg"> | 
			
		||||
 | 
				      </div> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				    <div slot="footer" class="dialog-footer" style="margin-top: 0;"> | 
			
		||||
 | 
				      <el-button type="primary" @click="videoVisible=false">关闭</el-button> | 
			
		||||
 | 
				    </div> | 
			
		||||
 | 
				  </el-dialog> | 
			
		||||
 | 
				</template> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<script> | 
			
		||||
 | 
				export default { | 
			
		||||
 | 
				  props: { | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  data() { | 
			
		||||
 | 
				    return { | 
			
		||||
 | 
				      videoVisible: false, | 
			
		||||
 | 
				      defaultImg: 'this.src="' + require('@/assets/images/system/default-img2.png') + '"', | 
			
		||||
 | 
				      srcImg: '' | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  watch: { | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  created() { | 
			
		||||
 | 
				  }, | 
			
		||||
 | 
				  methods: { | 
			
		||||
 | 
				    handleCloseDialog() { | 
			
		||||
 | 
				      this.videoVisible = false | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				</script> | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				<style lang="scss" scoped> | 
			
		||||
 | 
				::v-deep .el-dialog { | 
			
		||||
 | 
				  width: 860px; | 
			
		||||
 | 
				  .el-dialog__body{ | 
			
		||||
 | 
				    padding: 14px 0 30px 0 !important; | 
			
		||||
 | 
				    .default-img{ | 
			
		||||
 | 
				      display: flex; | 
			
		||||
 | 
				      justify-content: center; | 
			
		||||
 | 
				      align-items: center; | 
			
		||||
 | 
				      width: 820px; | 
			
		||||
 | 
				      height: 442px; | 
			
		||||
 | 
				      background-color: #F9F9F9; | 
			
		||||
 | 
				      border: 1px solid #E6E8ED; | 
			
		||||
 | 
				      border-radius: 3px; | 
			
		||||
 | 
				      overflow: hidden; | 
			
		||||
 | 
				      img{ | 
			
		||||
 | 
				        display: block; | 
			
		||||
 | 
				      } | 
			
		||||
 | 
				    } | 
			
		||||
 | 
				
 | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				.preview-info{ | 
			
		||||
 | 
				  color: #0C0E1E; | 
			
		||||
 | 
				  margin-bottom: 18px; | 
			
		||||
 | 
				  span{ | 
			
		||||
 | 
				    color: #545B65; | 
			
		||||
 | 
				  } | 
			
		||||
 | 
				} | 
			
		||||
 | 
				</style> | 
			
		||||
						Write
						Preview
					
					
					Loading…
					
					Cancel
						Save
					
		Reference in new issue