feat: 将多个页面从JavaScript转换为TypeScript

- 将 agreement.js、no-auth-plugin.js、processEntry.js、https.js、
  menuConfig.js、voiceUtil.js 文件重命名为对应的 .ts 扩展名

- 在 agreement.ts 中引入配置并动态设置标题
- 在 no-auth-plugin.ts 中使用工具函数替代硬编码跳转
- 为 processEntry.ts 添加类型注解并重构代码结构
- 为 https.ts 添加类型定义并优化错误处理
- 创建 menuConfig.ts 并迁移导航配置
- 为 voiceUtil.ts 添加类型注解
This commit is contained in:
zhengw
2026-01-12 10:59:13 +08:00
parent d36c005100
commit f0c68126dc
7 changed files with 206 additions and 145 deletions

View File

@@ -1,4 +1,5 @@
// pages/agreement/agreement.js
import { base } from "@/utils/config";
Page({
/**
*
@@ -11,14 +12,12 @@ Page({
* --
*/
onLoad(options) {
this.setData({
type: options.type,
});
const appletName = base.appletName;
this.setData({ type: options.type });
wx.setNavigationBarTitle({
title:
options.type == "user"
? "易宝赞数据化管理系统平台用户服务协议"
: "易宝赞数据化管理系统隐私权政策",
title: `${appletName}${
options.type == "user" ? "平台用户服务协议" : "隐私权政策"
}`,
});
},