This commit is contained in:
2025-06-18 18:03:32 +08:00
parent 3f5b1a08bd
commit a9d651822a
7 changed files with 206 additions and 367 deletions

View File

@@ -18,7 +18,6 @@
<view class="site_item" v-for="(el, i) in e.pointArr" :key="i">
<view class="site_item_box" :class="['bggray', 'bggreen'][Number(el.status)]" @click="setcode(el)">
<text class="title_1">{{el.device_name}}</text>
<text class="title_2">来源:{{el.source_device}}</text>
</view>
</view>
</view>
@@ -28,11 +27,11 @@
<view class="submit-bar">
<view class="dot_item">
<view class="p1">起始点</view>
<view class="p2">设备号{{sObj.device_name}}</view>
<view class="p2">{{sObj.device_name}}</view>
</view>
<view class="dot_item">
<view class="p1">目标点</view>
<view class="p2">设备号{{nObj.device_name}}</view>
<view class="p2">{{nObj.device_name}}</view>
</view>
<view class="btn_block">
<button class="submit-button" :class="{'btn-disabled': JSON.stringify(sObj) === '{}' && JSON.stringify(nObj) === '{}'}" @click="cancle">清空</button>
@@ -59,8 +58,7 @@
regobj: {},
disabled1: false,
sObj: {},
nObj: {},
isS: false
nObj: {}
};
},
created () {
@@ -111,12 +109,10 @@
}
},
setcode (el) {
if (this.isS === false) {
if (JSON.stringify(this.sObj) === '{}') {
this.sObj = el
this.isS = true
} else if (this.isS) {
} else if (JSON.stringify(this.sObj) !== '{}' && JSON.stringify(this.nObj) === '{}') {
this.nObj = el
this.isS = false
}
},
/** 清空点位选择 */
@@ -199,17 +195,10 @@
_font(30rpx,40rpx,#333,bold)
font-style italic
.title_1
_wh(100%, 60%)
_wh(100%, 100%)
_fj(center)
overflow hidden
_font(28rpx,28rpx,#303133,500, center)
.title_2
_wh(100%, 40%)
_fj(center)
overflow hidden
_font(24rpx,25rpx,#303133,500, center)
opacity .69
white-space: nowrap
.submit-bar
justify-content space-between
padding 10rpx