添加-添加设备调试按钮
This commit is contained in:
parent
5e49c058cd
commit
033300f027
|
|
@ -29,19 +29,19 @@
|
|||
type="text"
|
||||
/>
|
||||
</view>
|
||||
<!-- <view class="iptbox" @click="kashow = true">-->
|
||||
<!-- <view v-if="kaname" class=""> 卡商:{{ kaname }}</view>-->
|
||||
<!-- <view v-else class=""> 请点击选择卡商</view>-->
|
||||
<!-- </view>-->
|
||||
<!-- <u-select v-model="kashow" :list="kalist" title="选择卡商" @confirm="confirmka"></u-select>-->
|
||||
<!-- <view class="iptbox" @click="show = true">-->
|
||||
<!-- <view v-if="hardwareInfo.version" class=""> 版本:{{ hardwareInfo.version }}</view>-->
|
||||
<!-- <view v-else class=""> 请点击选择版本</view>-->
|
||||
<!-- </view>-->
|
||||
<!-- <view v-if="hardwareInfo.version" class="tips">-->
|
||||
<!-- 版本介绍:{{ hardwareInfo.instructions }}-->
|
||||
<!-- </view>-->
|
||||
<!-- <u-select v-model="show" :list="list" title="选择版本" @confirm="confirm"></u-select>-->
|
||||
<view class="iptbox" @click="kashow = true">
|
||||
<view v-if="kaname" class=""> 卡商:{{ kaname }}</view>
|
||||
<view v-else class=""> 请点击选择卡商</view>
|
||||
</view>
|
||||
<u-select v-model="kashow" :list="kalist" title="选择卡商" @confirm="confirmka"></u-select>
|
||||
<view class="iptbox" @click="show = true">
|
||||
<view v-if="hardwareInfo.version" class=""> 版本:{{ hardwareInfo.version }}</view>
|
||||
<view v-else class=""> 请点击选择版本</view>
|
||||
</view>
|
||||
<view v-if="hardwareInfo.version" class="tips">
|
||||
版本介绍:{{ hardwareInfo.instructions }}
|
||||
</view>
|
||||
<u-select v-model="show" :list="list" title="选择版本" @confirm="confirm"></u-select>
|
||||
|
||||
<view class="imgs" style="margin-top: 30rpx">
|
||||
<image
|
||||
|
|
@ -51,17 +51,17 @@
|
|||
></image>
|
||||
</view>
|
||||
<view class="btn" @click="bind()"> 确认添加</view>
|
||||
<!-- <view class="bot_btn">-->
|
||||
<!-- <view class="btn1" @click="btnfh"> 返回</view>-->
|
||||
<!-- <view class="btn1" @click="findDevice()"> 蓝牙链接</view>-->
|
||||
<!-- <view v-if="carstause" class="btn1" @click="ring()"> 响铃寻车</view>-->
|
||||
<view class="bot_btn">
|
||||
<view class="btn1" @click="btnfh"> 返回</view>
|
||||
<view class="btn1" @click="findDevice()"> 蓝牙链接</view>
|
||||
<view v-if="carstause" class="btn1" @click="ring()"> 响铃寻车</view>
|
||||
|
||||
<!-- <view v-if="carstause" class="btn1" @click="open()"> 蓝牙开锁</view>-->
|
||||
<!-- <view v-if="carstause" class="btn1" @click="close()"> 蓝牙关锁</view>-->
|
||||
<!-- <view v-if="carstause" class="btn1" @click="shaoru"> 进入烧录</view>-->
|
||||
<!-- <view v-if="carstause" class="btn1" @click="reboot()"> 设备重启</view>-->
|
||||
<!-- <view v-if="isbands" class="btn1" @click="Binddevice()"> 接口响铃</view>-->
|
||||
<!-- </view>-->
|
||||
<view v-if="carstause" class="btn1" @click="open()"> 蓝牙开锁</view>
|
||||
<view v-if="carstause" class="btn1" @click="close()"> 蓝牙关锁</view>
|
||||
<view v-if="carstause" class="btn1" @click="shaoru"> 进入烧录</view>
|
||||
<view v-if="carstause" class="btn1" @click="reboot()"> 设备重启</view>
|
||||
<view v-if="isbands" class="btn1" @click="Binddevice()"> 接口响铃</view>
|
||||
</view>
|
||||
<u-mask :show="showbind" :z-index="100" />
|
||||
<view v-if="showbind" class="tip_box">
|
||||
<view v-if="showbind" class="top">
|
||||
|
|
@ -498,27 +498,31 @@ export default {
|
|||
})
|
||||
},
|
||||
open() {
|
||||
let vm = this // 将外部的 this 绑定到 vm 上
|
||||
uni.getNetworkType({
|
||||
success(res) {
|
||||
if (res.networkType !== 'none') {
|
||||
uni.getConnectedBluetoothDevices({
|
||||
success(res) {
|
||||
console.log('已连接的蓝牙设备信息:', res)
|
||||
xBlufi.notifySendCustomData({
|
||||
customData: '11open',
|
||||
})
|
||||
},
|
||||
fail(err) {
|
||||
uni.hideLoading()
|
||||
console.error('获取已连接蓝牙设备信息失败:', err)
|
||||
},
|
||||
})
|
||||
} else {
|
||||
console.log('手机未连接网络')
|
||||
}
|
||||
},
|
||||
})
|
||||
xBlufi.notifySendCustomData({
|
||||
customData: '11open',
|
||||
})
|
||||
xBlufi.notifySendCustomData({
|
||||
customData: 'open',
|
||||
})
|
||||
// let vm = this // 将外部的 this 绑定到 vm 上
|
||||
// uni.getNetworkType({
|
||||
// success(res) {
|
||||
// if (res.networkType !== 'none') {
|
||||
// uni.getConnectedBluetoothDevices({
|
||||
// success(res) {
|
||||
// console.log('已连接的蓝牙设备信息:', res)
|
||||
|
||||
// },
|
||||
// fail(err) {
|
||||
// uni.hideLoading()
|
||||
// console.error('获取已连接蓝牙设备信息失败:', err)
|
||||
// },
|
||||
// })
|
||||
// } else {
|
||||
// console.log('手机未连接网络')
|
||||
// }
|
||||
// },
|
||||
// })
|
||||
},
|
||||
shaoru() {
|
||||
let vm = this // 将外部的 this 绑定到 vm 上
|
||||
|
|
@ -544,27 +548,33 @@ export default {
|
|||
})
|
||||
},
|
||||
close() {
|
||||
let vm = this // 将外部的 this 绑定到 vm 上
|
||||
uni.getNetworkType({
|
||||
success(res) {
|
||||
if (res.networkType !== 'none') {
|
||||
uni.getConnectedBluetoothDevices({
|
||||
success(res) {
|
||||
console.log('已连接的蓝牙设备信息:', res)
|
||||
xBlufi.notifySendCustomData({
|
||||
customData: '11close',
|
||||
})
|
||||
},
|
||||
fail(err) {
|
||||
uni.hideLoading()
|
||||
console.error('获取已连接蓝牙设备信息失败:', err)
|
||||
},
|
||||
})
|
||||
} else {
|
||||
console.log('手机未连接网络')
|
||||
}
|
||||
},
|
||||
})
|
||||
xBlufi.notifySendCustomData({
|
||||
customData: '11close',
|
||||
})
|
||||
xBlufi.notifySendCustomData({
|
||||
customData: 'close',
|
||||
})
|
||||
// let vm = this // 将外部的 this 绑定到 vm 上
|
||||
// uni.getNetworkType({
|
||||
// success(res) {
|
||||
// if (res.networkType !== 'none') {
|
||||
// uni.getConnectedBluetoothDevices({
|
||||
// success(res) {
|
||||
// console.log('已连接的蓝牙设备信息:', res)
|
||||
// xBlufi.notifySendCustomData({
|
||||
// customData: '11close',
|
||||
// })
|
||||
// },
|
||||
// fail(err) {
|
||||
// uni.hideLoading()
|
||||
// console.error('获取已连接蓝牙设备信息失败:', err)
|
||||
// },
|
||||
// })
|
||||
// } else {
|
||||
// console.log('手机未连接网络')
|
||||
// }
|
||||
// },
|
||||
// })
|
||||
},
|
||||
ring() {
|
||||
let vm = this // 将外部的 this 绑定到 vm 上
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user