|
@@ -311,7 +311,7 @@ class bleManager {
|
|
|
var that = this;
|
|
|
|
|
|
///限制搜索没有打开蓝牙一直询问打开蓝牙
|
|
|
- const time_util = require('./../utils/time_util');
|
|
|
+ const time_util = require('../utils/timeUtil');
|
|
|
if (!that.isAvailable) {
|
|
|
if (callBackConnect == null) {
|
|
|
return;
|
|
@@ -391,7 +391,7 @@ class bleManager {
|
|
|
|
|
|
search(connectWillDevice, boolean, callBackConnect) {
|
|
|
var that = this;
|
|
|
- const time_util = require('./../utils/time_util');
|
|
|
+ const timeUtil = require('../utils/timeUtil');
|
|
|
wx.startBluetoothDevicesDiscovery({
|
|
|
allowDuplicatesKey: true,
|
|
|
success: function (res) {
|
|
@@ -399,7 +399,7 @@ class bleManager {
|
|
|
that.getConnectedDevices();
|
|
|
|
|
|
that.doStartScaning = false;
|
|
|
- that.requestBlueTime = time_util.getCurrentMills();
|
|
|
+ that.requestBlueTime = timeUtil.getCurrentMills();
|
|
|
if (boolean != null) {
|
|
|
boolean(true);
|
|
|
}
|
|
@@ -410,7 +410,7 @@ class bleManager {
|
|
|
fail(err) {
|
|
|
console.log("开始搜索设备失败", err);
|
|
|
that.doStartScaning = false;
|
|
|
- that.requestBlueTime = time_util.getCurrentMills();
|
|
|
+ that.requestBlueTime = timeUtil.getCurrentMills();
|
|
|
if (err.errMsg.indexOf("location") >= 0) {
|
|
|
wx.showToast({
|
|
|
title: '搜索失败,请检查下手机设置的微信定位权限是否开启',
|