| 1234567891011121314151617181920212223242526272829303132 |
- const API = require("../../lib/API");
- const { BaseStdResponse } = require("../../BaseStdResponse");
- class GetAndroidAppVersion extends API {
- constructor() {
- super();
- this.setPath('/Public/GetAndroidAppVersion')
- this.setMethod('GET')
- }
- async onRequest(req, res) {
- const data = {
- describe: '<p>1、修复已知问题</p> <p>2、优化用户体验</p><p><small style="color: red">更新过程中请勿关闭程序或切到后台,以免导致升级失败</small></p>',
- edition_url: 'https://lepao-cloud.xxoo365.top/down.php/8264e8bf6cec9b41f2d181b128e7ab77.wgt', //apk、wgt包下载地址或者应用市场地址 安卓应用市场 market://details?id=xxxx 苹果store itms-apps://itunes.apple.com/cn/app/xxxxxx
- edition_force: 1, //是否强制更新 0代表否 1代表是
- package_type: 1, //0是整包升级(apk或者appstore或者安卓应用市场) 1是wgt升级
- edition_issue: 1, //是否发行 0否 1是 为了控制上架应用市场审核时不能弹出热更新框
- edition_number: 103, //版本号 最重要的manifest里的版本号 (检查更新主要以服务器返回的edition_number版本号是否大于当前app的版本号来实现是否更新)
- edition_name: '1.0.3', // 版本名称 manifest里的版本名称
- edition_silence: 0, // 是否静默更新 0代表否 1代表是
- log: '1、修复已知问题; 2、优化用户体验' //系统设置内日志
- }
- res.json({
- ...BaseStdResponse.OK,
- data
- })
- }
- }
- module.exports.GetAndroidAppVersion = GetAndroidAppVersion
|