|
|
|
@ -1,7 +1,7 @@ |
|
|
|
|
<template> |
|
|
|
|
<div class="app-container home"> |
|
|
|
|
<h1>{{data.name}}</h1> |
|
|
|
|
<h1>运行状态:{{data.status}}</h1> |
|
|
|
|
<!-- <h1>{{data.name}}</h1>--> |
|
|
|
|
<h1>运行状态:<span :class="{'green':data.status == '正在运行','red':data.status == '停止运行'}">{{data.status}}</span></h1> |
|
|
|
|
<img src="../../../assets/images/shapan.png" class="img"> |
|
|
|
|
</div> |
|
|
|
|
</template> |
|
|
|
@ -21,9 +21,9 @@ export default { |
|
|
|
|
if(res.data!=null) { |
|
|
|
|
data.name = res.data.deviceName |
|
|
|
|
if (res.data.deviceRunstatus == true) { |
|
|
|
|
data.status = '开启' |
|
|
|
|
data.status = '正在运行' |
|
|
|
|
} else { |
|
|
|
|
data.status = '关闭' |
|
|
|
|
data.status = '停止运行' |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
}) |
|
|
|
@ -40,8 +40,17 @@ export default { |
|
|
|
|
|
|
|
|
|
<style scoped lang="scss"> |
|
|
|
|
.img{ |
|
|
|
|
margin-left: 250px; |
|
|
|
|
margin-left: 250px; |
|
|
|
|
margin-top: 100px; |
|
|
|
|
} |
|
|
|
|
h1{ |
|
|
|
|
font-size: 16px; |
|
|
|
|
} |
|
|
|
|
.green{ |
|
|
|
|
color: #14FF00; |
|
|
|
|
} |
|
|
|
|
.red{ |
|
|
|
|
color: red; |
|
|
|
|
} |
|
|
|
|
</style> |
|
|
|
|
|
|
|
|
|