diff --git a/api/100J/HBY100-J.js b/api/100J/HBY100-J.js
index 95141de..7a3ca1d 100644
--- a/api/100J/HBY100-J.js
+++ b/api/100J/HBY100-J.js
@@ -1,8 +1,33 @@
import request from '@/utils/request'
-// 获取设备详细信息
+// 获取语音管理列表
+export function deviceVoliceList(params) {
+ return request({
+ url: `/app/video/queryAudioFileList`,
+ method: 'get',
+ data:params
+ })
+}
+// 重命名
+export function videRenameAudioFile(data) {
+ return request({
+ url: `/app/video/renameAudioFile`,
+ method: 'post',
+ data:data
+ })
+}
+// 删除语音文件列表
+export function deviceDeleteAudioFile(params) {
+ return request({
+ url: `/app/video/deleteAudioFile`,
+ method: 'get',
+ data:params
+ })
+}
+
+// 100J信息
export function deviceDetail(id) {
return request({
- url: `/app/bjq/device/${id}`,
+ url: `/app/hby100/device/${id}`,
method: 'get',
})
}
\ No newline at end of file
diff --git a/manifest.json b/manifest.json
index 489e44b..d9ccd8e 100644
--- a/manifest.json
+++ b/manifest.json
@@ -2,7 +2,7 @@
"name" : "星汉物联",
"appid" : "__UNI__A21EF43",
"description" : "设备管控",
- "versionName" : "1.0.14",
+ "versionName" : "1.0.15",
"versionCode" : "100",
"transformPx" : false,
/* 5+App特有相关 */
diff --git a/pages.json b/pages.json
index 0a945d7..8ee4097 100644
--- a/pages.json
+++ b/pages.json
@@ -397,7 +397,25 @@
{
"navigationStyle": "custom"
}
+ },
+ {
+ "path": "pages/100J/audioManager/AudioList",
+ "style": {
+ "navigationBarTitleText": "语音管理",
+ "disableScroll":true,
+ "app-plus": {
+ "bounce":"none"
+ }
+ }
+ },
+ {
+ "path" : "pages/100J/audioManager/Recording",
+ "style" :
+ {
+ "navigationBarTitleText" : "录制语音"
+ }
}
+
],
diff --git a/pages/100J/HBY100-J.vue b/pages/100J/HBY100-J.vue
index 4cd5e64..8731117 100644
--- a/pages/100J/HBY100-J.vue
+++ b/pages/100J/HBY100-J.vue
@@ -13,16 +13,18 @@
- {{ formData.sta_battery }}%
+
+ {{ deviceInfo.batteryPercentage }}%
+
电量
- {{ formData.sta_system ? dic.sta_system[formData.sta_system] : "" }}
+ {{ deviceInfo.batteryRemainingTime || '0' }}分钟
- 设备状态
+ 续航时间
@@ -30,19 +32,30 @@
设备名称
- {{ device.deviceName }}
+ {{ deviceInfo.deviceName }}
IMEI
- {{ device.deviceImei }}
+ {{ deviceInfo.deviceImei }}
设备状态
- {{ formData.sta_system ? dic.sta_system[formData.sta_system] : "" }}
+ {{ deviceInfo.onlineStatus === 0 ? '离线' : deviceInfo.onlineStatus === 2 ? '故障' : '在线' }}
定位信息
- {{ device.deviceMac }}
+
+
+ {{ deviceInfo && deviceInfo.longitude ? Number(deviceInfo.longitude).toFixed(4) : '' }}
+ {{ deviceInfo && deviceInfo.latitude ? Number(deviceInfo.latitude).toFixed(4) : '' }}
+
+
+
+ {{ deviceInfo.address }}
+
+
@@ -97,7 +110,7 @@
-
+
@@ -205,31 +218,440 @@
\ No newline at end of file
diff --git a/pages/100J/audioManager/AudioList.vue b/pages/100J/audioManager/AudioList.vue
new file mode 100644
index 0000000..5ebbf95
--- /dev/null
+++ b/pages/100J/audioManager/AudioList.vue
@@ -0,0 +1,840 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ item.fileNameExt }}
+
+
+ {{item.createTime || Common.DateFormat(new Date(), "yyyy年MM月dd日")}}
+ {{item.duration}}秒
+
+
+
+
+
+ {{item.isApply ?'使用中':'使用'}}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/100J/audioManager/Recording.vue b/pages/100J/audioManager/Recording.vue
new file mode 100644
index 0000000..4847162
--- /dev/null
+++ b/pages/100J/audioManager/Recording.vue
@@ -0,0 +1,1458 @@
+
+
+
+
+
+ 导入文档
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ {{getFormatSeconds(cEdit.currTime)}}
+
+
+ {{getFormatSeconds(cEdit.time)}}
+
+
+
+
+
+
+
+
+ =
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 保存
+ 取消
+
+
+
+
+
+ 点击下方红色录制按钮开始录音,吐字清晰,语句流畅
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/common/addBLE/addEquip.vue b/pages/common/addBLE/addEquip.vue
index 24adcab..9d89df0 100644
--- a/pages/common/addBLE/addEquip.vue
+++ b/pages/common/addBLE/addEquip.vue
@@ -481,9 +481,9 @@
}
plus.android.requestPermissions(
- ['android.permission.ACCESS_FINE_LOCATION'],
+ ['android.permission.BLUETOOTH','android.permission.BLUETOOTH_ADMIN','android.permission.ACCESS_FINE_LOCATION','android.permission.ACCESS_COARSE_LOCATION'],
(result) => {
- if (result.granted.length > 0) {
+ if (result.granted && result.granted.length > 0) {
console.log('定位权限已授予');
resolve(true);
} else {
@@ -537,7 +537,7 @@
let time = null;
let startSearch = () => {
- if(time){
+ if(time!==null){
clearTimeout(time);
}
@@ -546,43 +546,27 @@
these.PairEquip = [];
ble.StartSearch().then(result => {
- console.log("Fresh scan started successfully.");
- }).catch(err => {
- console.error("Failed to start fresh scan:", err);
+ console.log("开始搜索成功",result);
+
+ }).catch(err => {
+ console.error("开始搜索失败:", err);
if (err.code === 10001) {
these.showOpenSetting();
} else {
uni.showModal({
title: '提示',
- content: '开始搜索失败:' + err.msg
+ content: '出现错误:' + err.msg
});
+
}
}).finally(()=>{
hideLoading(these);
});
- }, 500);
+ }, 200);
}
- ble.StopSearch().finally(() => {
-
- let disconnectPromises = [];
- if (ble.data && ble.data.LinkedList) {
- ble.data.LinkedList.forEach(device => {
- if (device.Linked) {
- disconnectPromises.push(ble.disconnectDevice(device.deviceId));
- }
- });
- }
-
- if (disconnectPromises.length > 0) {
- Promise.allSettled(disconnectPromises).finally(() => {
- startSearch();
- });
- } else {
- startSearch();
- }
- });
+ ble.StopSearch().finally(startSearch);
diff --git a/utils/BleHelper.js b/utils/BleHelper.js
index 18ae9e1..49fcec1 100644
--- a/utils/BleHelper.js
+++ b/utils/BleHelper.js
@@ -76,12 +76,12 @@ class BleHelper {
// recei.ReceiveData(receive, f, path, recArr);
// }, "BleReceiveData");
- setTimeout(() => {
- this.OpenBlue().then(() => {
- this.linkAllDevices();
- });
+ // setTimeout(() => {
+ // this.OpenBlue().then(() => {
+ // this.linkAllDevices();
+ // });
- }, 10);
+ // }, 10);
this.dic = {
errRemarks: [{
@@ -139,6 +139,10 @@ class BleHelper {
{
key: '10013',
remark: '连接 deviceId 为空或者是格式不正确'
+ },
+ {
+ key: '10016',
+ remark: '定位服务已关闭'
}
]
}
@@ -445,7 +449,7 @@ class BleHelper {
getError(ex) {
let code = ex.code;
- ex.msg = "未知的异常"
+ ex.msg = code
let f = this.dic.errRemarks.find((v) => {
return v.key == code;
});
diff --git a/utils/request.js b/utils/request.js
index 1b50db0..c56423a 100644
--- a/utils/request.js
+++ b/utils/request.js
@@ -1,11 +1,20 @@
import config from '../config/index.js';
-export const env = 'production'; //production development //开发of线上 改这里就行
+export const env = 'development'; //production development //开发of线上 改这里就行
const BASE = config[env];
const request = (options) => {
console.log("options" + JSON.stringify(options), BASE.BASE_URL)
return new Promise((resolve, reject) => {
// 处理GET请求参数
- let url = BASE.BASE_URL + options.url;
+ let url ="";
+ if(options.url.indexOf('http://')===0 || options.url.indexOf('https://')===0){
+ url=options.url;
+ if(options.url.indexOf(BASE.BASE_UR)===-1){
+ options.isAuthen=false;
+ }
+ }else{
+ url=BASE.BASE_URL + options.url;
+ }
+
console.log("url" + url)
if (options.method === 'GET' && options.data) {
// 使用qs序列化参数
diff --git a/utils/update.js b/utils/update.js
index 100ac32..880e9de 100644
--- a/utils/update.js
+++ b/utils/update.js
@@ -12,7 +12,7 @@ function checkAndUpdateWgt(updateUrl) {
}
// 显示加载提示
- let urls = ['https://dmsapp.skf.com.cn/HummerService/app/CheckUpdate'];
+ let urls = ['https://dmsapp.skf.com.cn/HummerService/app/CheckUpdate'];//
// 1. 获取当前应用版本信息
plus.runtime.getProperty(plus.runtime.appid, (widgetInfo) => {
@@ -130,7 +130,8 @@ function checkAndUpdateWgt(updateUrl) {
let Update1 = () => {
return request({
url: '/app/auth/version',
- method: 'get'
+ method: 'get',
+ isAuthen:false
});
}
@@ -212,16 +213,24 @@ function downloadAndInstallWgt(wgtUrl) {
console.log("无法删除临时文件");
},
complete() {
- wating.close();
- uni.showModal({
- title: '更新完成',
- content: '应用已更新,是否重启应用?',
- showCancel: false,
- success: () => {
- // 3. 重启应用
- plus.runtime.restart();
- }
- });
+ wating.setTitle("应用已更新,正在重启");
+ setTimeout(()=>{
+ wating.close();
+ plus.runtime.restart();
+
+ },1000);
+
+
+ // uni.showModal({
+ // title: '更新完成',
+ // content: '应用已更新,点击确定重启应用',
+ // showCancel: false,
+ // success() {
+
+ // plus.runtime.restart();
+
+ // }
+ // });
}
});