upload project

This commit is contained in:
unknown 2025-12-27 17:16:03 +08:00
commit 06961cae04
422 changed files with 110626 additions and 0 deletions

23
utils/version-helper.js Normal file
View file

@ -0,0 +1,23 @@
// 全局版本检查帮助函数
const versionManager = require('./simple-version-manager.js');
/**
* 在页面中添加版本检查
* 使用方法在页面的 onShow 中调用 checkVersionOnShow()
*/
function checkVersionOnShow() {
try {
const hasVersionUpdate = versionManager.checkVersionUpdate();
if (hasVersionUpdate) {
return true; // 返回 true 表示有版本更新
}
return false; // 返回 false 表示无版本更新
} catch (error) {
console.error('页面版本检查失败:', error);
return false;
}
}
module.exports = {
checkVersionOnShow
};