|
|
|
@ -126,13 +126,13 @@ |
|
|
|
|
<div class="dev_control_table"> |
|
|
|
|
<div class="control_header"><span>调控日志</span></div> |
|
|
|
|
<div class="control_table"> |
|
|
|
|
<el-table :data="controlList"> |
|
|
|
|
<el-table :data="controlLogList" height="305px"> |
|
|
|
|
<el-table-column label="序号" align="center" width="50"/> |
|
|
|
|
<el-table-column label="设备名称" align="center" prop="devName"/> |
|
|
|
|
<el-table-column label="操作内容" align="center" prop="content" width="700"/> |
|
|
|
|
<el-table-column label="操作时间" align="center" prop="time"/> |
|
|
|
|
<el-table-column label="操作人员" align="center" prop="person"/> |
|
|
|
|
<el-table-column label="操作结果" align="center" prop="result"></el-table-column> |
|
|
|
|
<el-table-column label="设备名称" align="center" prop="deviceName"/> |
|
|
|
|
<el-table-column label="操作内容" align="center" prop="controlValue" width="700"/> |
|
|
|
|
<el-table-column label="操作时间" align="center" prop="createTime"/> |
|
|
|
|
<el-table-column label="操作人员" align="center" prop="createBy"/> |
|
|
|
|
<el-table-column label="操作结果" align="center" prop="controlResult"></el-table-column> |
|
|
|
|
</el-table> |
|
|
|
|
<el-pagination |
|
|
|
|
v-model:current-page="currentPage" |
|
|
|
@ -142,7 +142,7 @@ |
|
|
|
|
:disabled="disabled" |
|
|
|
|
:background="background" |
|
|
|
|
layout="total, sizes, prev, pager, next, jumper" |
|
|
|
|
:total="controlList.length" |
|
|
|
|
:total="tableLength" |
|
|
|
|
@size-change="handleSizeChange" |
|
|
|
|
@current-change="handleCurrentChange"/> |
|
|
|
|
</div> |
|
|
|
@ -167,10 +167,11 @@ |
|
|
|
|
import { Download } from '@element-plus/icons-vue' //element字体图标 |
|
|
|
|
import { ref,reactive,onMounted } from 'vue' |
|
|
|
|
import { ElMessageBox } from 'element-plus' |
|
|
|
|
import { getDevice } from '@/api/control/manual' |
|
|
|
|
import { getDevice,getControlLogList } from '@/api/control/manual' |
|
|
|
|
|
|
|
|
|
onMounted(()=>{ |
|
|
|
|
getDeviceFun(); |
|
|
|
|
getControlLogListFun(); |
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
/** 获取所有设备*/ |
|
|
|
@ -179,6 +180,13 @@ function getDeviceFun(){ |
|
|
|
|
getDevice().then((res)=>{ |
|
|
|
|
console.log(res.data) |
|
|
|
|
deviceArr.value = res.data |
|
|
|
|
for(let i = 0;i < res.data.length;i++){ |
|
|
|
|
if(res.data[i].deviceRunstatus == 1){ |
|
|
|
|
res.data[i].deviceRunstatus = '开启' |
|
|
|
|
}else{ |
|
|
|
|
res.data[i].deviceRunstatus = '关闭' |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
@ -212,47 +220,36 @@ const onSubmit3 = () => { |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
/** 数据表格处理*/ |
|
|
|
|
const controlList = reactive([ |
|
|
|
|
{ |
|
|
|
|
devName:'11', |
|
|
|
|
content:'22', |
|
|
|
|
time:'33', |
|
|
|
|
person:'44', |
|
|
|
|
result:'55', |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
devName:'11', |
|
|
|
|
content:'22', |
|
|
|
|
time:'33', |
|
|
|
|
person:'44', |
|
|
|
|
result:'55', |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
devName:'11', |
|
|
|
|
content:'22', |
|
|
|
|
time:'33', |
|
|
|
|
person:'44', |
|
|
|
|
result:'55', |
|
|
|
|
}, |
|
|
|
|
{ |
|
|
|
|
devName:'11', |
|
|
|
|
content:'22', |
|
|
|
|
time:'33', |
|
|
|
|
person:'44', |
|
|
|
|
result:'55', |
|
|
|
|
} |
|
|
|
|
]) |
|
|
|
|
const controlLogList = ref([]) |
|
|
|
|
const tableLength = ref() |
|
|
|
|
const currentPage = ref(1) |
|
|
|
|
const pageSize = ref(5) |
|
|
|
|
const small = ref(false) |
|
|
|
|
const background = ref(false) |
|
|
|
|
const disabled = ref(false) |
|
|
|
|
const handleSizeChange = (val) => { |
|
|
|
|
console.log(`${val} items per page`) |
|
|
|
|
getControlLogListFun() |
|
|
|
|
} |
|
|
|
|
const handleCurrentChange = (val) => { |
|
|
|
|
console.log(`current page: ${val}`) |
|
|
|
|
getControlLogListFun() |
|
|
|
|
} |
|
|
|
|
function getControlLogListFun(){ |
|
|
|
|
getControlLogList({ |
|
|
|
|
"deviceId": null, |
|
|
|
|
"deviceName": null, |
|
|
|
|
"deviceSn": null, |
|
|
|
|
"controlKey": null, |
|
|
|
|
"controlValue": null, |
|
|
|
|
"controlResult": null, |
|
|
|
|
"controlContext": null, |
|
|
|
|
"pageNum": currentPage.value, |
|
|
|
|
"pageSize": pageSize.value |
|
|
|
|
}).then((res)=>{ |
|
|
|
|
tableLength.value = res.total |
|
|
|
|
controlLogList.value = res.rows |
|
|
|
|
}) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
/** 策略导入处理*/ |
|
|
|
|
const drawerIshow = ref(false) |
|
|
|
@ -277,7 +274,7 @@ function confirmClick() { |
|
|
|
|
height: 50%; |
|
|
|
|
overflow-y: auto; |
|
|
|
|
.dev_control_item{ |
|
|
|
|
width: 24.45%; |
|
|
|
|
width: 24%; |
|
|
|
|
height: 47%; |
|
|
|
|
margin-right: 12px; |
|
|
|
|
margin-bottom: 12px; |
|
|
|
@ -396,5 +393,8 @@ function confirmClick() { |
|
|
|
|
::v-deep .el-pager{ |
|
|
|
|
margin: 0 5px; |
|
|
|
|
} |
|
|
|
|
::v-deep .el-table--fit{ |
|
|
|
|
background-color: #2D3D88; |
|
|
|
|
} |
|
|
|
|
</style> |
|
|
|
|
|
|
|
|
|