73 lines
1.3 KiB
Vue
73 lines
1.3 KiB
Vue
<script>
|
|
var call
|
|
var data_call
|
|
var ble_id = "1231"
|
|
var ble_url
|
|
|
|
var user_info
|
|
|
|
// 在文件顶部添加一个变量来存储当前连接的MAC地址
|
|
var current_connected_mac = null;
|
|
|
|
export default {
|
|
globalData: {
|
|
userInfo: null,
|
|
topicTypeIndex: 0,
|
|
token: "",
|
|
isShow: true,
|
|
bleInfo: {
|
|
current_connected_mac: null,
|
|
ble_id: "1231",
|
|
ble_url: null,
|
|
devicesList: [],
|
|
}
|
|
},
|
|
created() {
|
|
// #ifdef APP-PLUS
|
|
plus.navigator.closeSplashscreen()
|
|
// #endif
|
|
console.log('App @@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@Launch')
|
|
// #ifndef APP-PLUS
|
|
console.log('App 1111111111111Launch')
|
|
// #endif
|
|
// 添加以下代码,将方法绑定到 uni 全局对象
|
|
uni.$emit('init_app_methods', {
|
|
set_ble_mac: this.set_ble_mac.bind(this)
|
|
})
|
|
},
|
|
onLaunch(options) {
|
|
uni.setInnerAudioOption({
|
|
obeyMuteSwitch: false
|
|
})
|
|
},
|
|
onShow: function () {
|
|
|
|
},
|
|
onHide: function () {
|
|
|
|
},
|
|
methods: {
|
|
get_ble_name(callback) {
|
|
if (callback != undefined) {
|
|
console.log('关闭蓝牙接口', ble_id);
|
|
}
|
|
},
|
|
}
|
|
}
|
|
</script>
|
|
|
|
|
|
<style lang="scss">
|
|
/*每个页面公共css */
|
|
@import "uview-ui/index.scss";
|
|
@import "./common/css/iconfont.css";
|
|
// 自定义tabar样式修改
|
|
/deep/.u-tabbar__content__item__text{
|
|
font-size: 20rpx !important;
|
|
bottom: 10rpx !important;
|
|
}
|
|
page{
|
|
background-color: #f8f8f8;
|
|
}
|
|
</style>
|