|
@@ -24,7 +24,7 @@
|
|
|
icon="el-icon-plus"
|
|
|
size="mini"
|
|
|
@click="handleClick('','','add')"
|
|
|
- v-hasPermi="['airbottle:flowDetail:add']"
|
|
|
+ v-hasPermi="['algorithm:firedevice:add']"
|
|
|
>新增</el-button>
|
|
|
</el-col>
|
|
|
</el-form-item>
|
|
@@ -39,13 +39,14 @@
|
|
|
<span v-if="scope.row.deviceStatus==1">离线</span>
|
|
|
<span v-if="scope.row.deviceStatus==2">在线</span>
|
|
|
<span v-if="scope.row.deviceStatus==3">异常</span>
|
|
|
+ <span v-if="scope.row.deviceStatus==3" style="color: #E6A23C"> {{'('+scope.row.describe+')'}}</span>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
|
<el-table-column label="操作" align="left" class-name="small-padding fixed-width" width="180">
|
|
|
<template slot-scope="scope">
|
|
|
<div class="button-box">
|
|
|
- <p class="table-min-button" v-hasPermi="['laboratory:hardware5:edit']" @click="handleClick('',scope.row,'edit')">编辑</p>
|
|
|
- <p class="table-min-button" v-hasPermi="['laboratory:hardware5:remove']" @click="handleClick('',scope.row,'delete')">删除</p>
|
|
|
+ <p class="table-min-button" v-hasPermi="['algorithm:firedevice:edit']" @click="handleClick('',scope.row,'edit')">编辑</p>
|
|
|
+ <p class="table-min-button" v-hasPermi="['algorithm:firedevice:remove']" @click="handleClick('',scope.row,'delete')">删除</p>
|
|
|
</div>
|
|
|
</template>
|
|
|
</el-table-column>
|
|
@@ -59,7 +60,7 @@
|
|
|
/>
|
|
|
</div>
|
|
|
<!--弹框-->
|
|
|
- <el-dialog title='新增准入实验室' @close="handleClose" :visible.sync="dialogVisible" width="600px">
|
|
|
+ <el-dialog :title='dialogTitle' @close="handleClose" :visible.sync="dialogVisible" width="600px" append-to-body>
|
|
|
<el-form :model="dialogForm" ref="dialogForm" :rules="rules" :inline="true" label-width="140px">
|
|
|
<el-form-item label="设备名称:" prop="deviceName" >
|
|
|
<el-input
|
|
@@ -96,7 +97,7 @@
|
|
|
style="width: 400px"
|
|
|
v-model="dialogForm.deviceUrl"
|
|
|
placeholder="请输入设备地址"
|
|
|
- maxLength="300"
|
|
|
+ maxLength="3"
|
|
|
clearable
|
|
|
size="small"
|
|
|
/>
|
|
@@ -158,6 +159,7 @@ export default {
|
|
|
dialogVisible :false,
|
|
|
//页面状态
|
|
|
pageType:1,
|
|
|
+ dialogTitle:'新增智能灭火设备',
|
|
|
loading:false,
|
|
|
// 查询参数
|
|
|
queryParams: {
|
|
@@ -168,7 +170,14 @@ export default {
|
|
|
total:0,
|
|
|
tableData:[],
|
|
|
dialogForm:{
|
|
|
-
|
|
|
+ id:'',
|
|
|
+ deviceName:'',
|
|
|
+ deviceCode:'',
|
|
|
+ relayCode:'',
|
|
|
+ deviceUrl:'',
|
|
|
+ deviceCountDown:'',
|
|
|
+ subjectId:'',
|
|
|
+ location:'',
|
|
|
},
|
|
|
laboratoryOptions:[],
|
|
|
// 表单校验
|
|
@@ -231,10 +240,18 @@ export default {
|
|
|
|
|
|
let _this=this;
|
|
|
if(doType=='add'){//添加
|
|
|
+ _this.dialogTitle='新增智能灭火设备';
|
|
|
_this.dialogVisible=true;
|
|
|
- _this.dialogForm={}
|
|
|
_this.dialogForm.deviceCountDown=30
|
|
|
+ _this.dialogForm.id='';
|
|
|
+ _this.dialogForm.deviceName='';
|
|
|
+ _this.dialogForm.deviceCode='';
|
|
|
+ _this.dialogForm.relayCode='';
|
|
|
+ _this.dialogForm.deviceUrl='';
|
|
|
+ _this.dialogForm.subjectId='';
|
|
|
+ _this.dialogForm.location='';
|
|
|
}else if(doType=='edit'){//编辑
|
|
|
+ _this.dialogTitle='编辑智能灭火设备';
|
|
|
_this.dialogVisible=true;
|
|
|
_this.dialogForm.id=row.id;
|
|
|
_this.dialogForm.deviceName=row.deviceName;
|