fix: 报告 device_id 用 ble.getDeviceId()(修 P2 空归属)+手动入口接入 i18n(P3)

这个提交包含在:
Guoguo
2026-07-18 20:25:57 -07:00
父节点 a7299708e2
当前提交 8e11b2da10
修改 4 个文件,包含 9 行新增4 行删除
+4 -2
查看文件
@@ -18,7 +18,8 @@ module.exports = {
start: '开始护理',
starting: '启动中...',
noRegionSelected: '请至少选择一个区域',
startFailed: '启动失败'
startFailed: '启动失败',
entryLink: '手动选择波长护理 '
},
en: {
navTitle: 'Manual Care',
@@ -37,6 +38,7 @@ module.exports = {
start: 'Start Care',
starting: 'Starting...',
noRegionSelected: 'Please select at least one region',
startFailed: 'Failed to start'
startFailed: 'Failed to start',
entryLink: 'Manual wavelength care '
}
}
+2 -1
查看文件
@@ -175,7 +175,8 @@ Page({
var self = this
var app = getApp()
var mask = self.data.regions || 0x1F
var deviceId = (app.globalData.connectedDevice && app.globalData.connectedDevice.device_id) || null
// Same device-id source the treating page uses (services/ble getDeviceId + currentDevice fallback).
var deviceId = ble.getDeviceId() || (app.globalData.currentDevice && app.globalData.currentDevice.device_id) || null
var scannedAt = Date.now()
function proceed(config) {
@@ -1,4 +1,5 @@
var ble = require('../../services/ble')
var i18n = require('../../i18n/index')
Page({
data: {
statusBarHeight: 44,
@@ -32,6 +33,7 @@ Page({
onLoad: function () {
var app = getApp()
this.setData({ statusBarHeight: app.globalData.statusBarHeight })
i18n.bind(this)
this.checkSubscription()
},
@@ -37,7 +37,7 @@
开始使用
</button>
<view class="manual-entry" bindtap="onManual" style="text-align:center;color:#E8503A;font-size:26rpx;margin-top:28rpx;">手动选择波长护理 </view>
<view class="manual-entry" bindtap="onManual" style="text-align:center;color:#E8503A;font-size:26rpx;margin-top:28rpx;">{{i18n.manual.entryLink}}</view>
<view class="error-text" wx:if="{{error}}">{{error}}</view>
</view>