Merge pull request 'fix : 细节优化' (#269) from dengjie into dev

Reviewed-on: http://git.feashow.cn/clay/tunnel-cloud-web/pulls/269
This commit is contained in:
2024-02-22 13:34:21 +00:00

View File

@@ -11,7 +11,7 @@
<!-- echarts -->
<div class="echart"></div>
<!-- 风机名 -->
<div class="fan-name">{{ changeNum(index + 1) }}号风机</div>
<div class="fan-name">{{ changeNum(item) }}号风机</div>
<!-- 功能 -->
<div class="option-nav">
<div>
@@ -24,14 +24,14 @@
<div
id="auto"
:class="{ active: item.running }"
@click="item.running = true;editOperate(item)"
@click="item.running = true;editOperate(item,'启动')"
>
启动
</div>
<div
id="stop"
:class="{ active: !item.running }"
@click="item.running = false;editOperate(item)"
@click="item.running = false;editOperate(item,'停止')"
>
停止
</div>
@@ -65,7 +65,7 @@
</div>
</div>
</div>
<div class="current" @click="handleOpenChart(item,index)">
<div class="current" @click="handleOpenChart(item)">
<fan-info-item :wp="transducerData[index]"/>
</div>
<div class="line"></div>
@@ -85,7 +85,7 @@
</div>
<div class="digital-tunnel">
<el-dialog :close-on-click-modal="false" v-model="isVisited" :title="changeNum(fanIndex)+'号风机电流监控数据'"
<el-dialog :close-on-click-modal="false" v-model="isVisited" :title="fanIndex+'号风机电流监控数据'"
width="2175px"
:modal="false">
<div class="left-top-icon"></div>
@@ -157,7 +157,7 @@ const stateB = ref(false)
const stateC = ref(false)
const isVisited = ref(false)
const showLoading = ref(false)
const fanIndex = ref(0)
const fanIndex = ref('')
const openEquipmentId = ref(0)
let myEcharts = reactive({});
watch(() => props.loading, (now) => {
@@ -230,8 +230,8 @@ const packageData = (item, type, flag) => {
}
}
//启动/停止
const editOperate = (item) => {
ElMessageBox.confirm('是否启动/停止该风机?','系统提示',{
const editOperate = (item,type) => {
ElMessageBox.confirm(`是否${type}该风机?`,'系统提示',{
type: 'warning',
closeOnClickModal: false
}).then(()=>{
@@ -265,10 +265,14 @@ const getFanInfo = (equipmentId, type = 'day') => {
}
})
}
const handleOpenChart = (item, index) => {
const handleOpenChart = (item) => {
openEquipmentId.value = item.equipmentId
getFanInfo(item.equipmentId, 'day')
fanIndex.value = index + 1
if(item.equipmentId===22){
fanIndex.value='一'
}else {
fanIndex.value='二'
}
}
const getTransData = (data) => {
let tranObj = {}
@@ -301,14 +305,13 @@ const getImage = (type) => {
return "red-state-icon.png";
}
}
const changeNum = (index) => {
switch (index) {
case 1:
const changeNum = (item) => {
console.log('1号变频器')
switch (item.equipmentId) {
case 22:
return '一';
case 2:
case 23:
return '二';
case 3:
return '三';
}
}
const getBasicData = (data) => {
@@ -317,6 +320,7 @@ const getBasicData = (data) => {
data?.map(item => {
tranObj = {
equipmentId: item.equipmentId,
equipmentName: item.equipmentName,
equipmentType: item.equipmentType,
autoMode: item.autoMode,//自动模式
breakdown: item.breakdown,//故障
@@ -421,7 +425,7 @@ const handleOnMounted = () => {
},
data: [
{
value: socketData.value[i].frequencyFeedback,
value: socketData.value[i].frequencySetting,
fontSize: 2100,
detail: {
valueAnimation: true,
@@ -780,7 +784,7 @@ input[type="number"] {
color: #38cafb;
line-height: 35px;
text-align: center;
margin-right: 42px;
margin-right: 25px;
transform: translateY(33%);
}
@@ -814,7 +818,7 @@ input[type="number"] {
height: 45px;
margin-right: 15px;
color: #fff;
background-color: #127399;
background-color: #3eab3f;
padding-left: 10px;
border-radius: 8px;
margin-left: -5px;
@@ -860,7 +864,7 @@ input[type="number"] {
font-size: 28px;
color: #38cafb;
line-height: 37px;
gap: 33px;
gap: 40px;
.check-box {
display: flex;
@@ -884,7 +888,7 @@ input[type="number"] {
// }
//}
:deep(.el-input__wrapper) {
width: 130px;
width: 160px;
height: 44px;
background-color: transparent;
box-shadow: none;