Commit 4c1ad98e by liimin

fix(timeout): 在handleTouchStart中添加计数器检查

在handleTouchStart方法中添加了对计数器的检查,只有当计数器大于0时才会记录日志。这避免了不必要的日志输出,提高了代码的清晰度。
1 parent 06fdc98c
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* @Author: 前端 qianduan01@didihu.com.cn * @Author: 前端 qianduan01@didihu.com.cn
* @Date: 2024-04-08 11:28:48 * @Date: 2024-04-08 11:28:48
* @LastEditors: liimin 17653212@qq.com * @LastEditors: liimin 17653212@qq.com
* @LastEditTime: 2025-05-16 09:36:30 * @LastEditTime: 2025-05-16 16:44:50
* @FilePath: \gl_tape\mixin\timeout.js * @FilePath: \gl_tape\mixin\timeout.js
* @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
*/ */
...@@ -43,7 +43,9 @@ export default { ...@@ -43,7 +43,9 @@ export default {
} }
}, },
handleTouchStart() { handleTouchStart() {
uni.$logger.local.info(`== ${this.__counter}分钟后触碰平板 == __timer:${this.__timer}`) if (this.__counter > 0) {
uni.$logger.local.info(`== ${this.__counter}分钟后触碰平板,重置计数器 == __timer:${this.__timer}`)
}
this.__counter = 0 this.__counter = 0
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!