Browse Source

更新改动

remove_uniapp
w-R 3 years ago
parent
commit
1b7dd38b22
  1. 2
      lib/main_page.dart
  2. 2
      lib/view_widget/update_dialog.dart

2
lib/main_page.dart

@ -337,7 +337,7 @@ class _MainPage extends State<MainPage> with WidgetsBindingObserver {
PackageInfo packageInfo = await PackageInfo.fromPlatform(); PackageInfo packageInfo = await PackageInfo.fromPlatform();
BaseData<AppUpdate> baseData = await apiService.appVersion().catchError((onError) {}); BaseData<AppUpdate> baseData = await apiService.appVersion().catchError((onError) {});
if (baseData != null && baseData.isSuccess) { if (baseData != null && baseData.isSuccess) {
baseData.data.appLastVersion = "1.0.4"; baseData.data.appLastVersion = "1.0.5";
baseData.data.appLastVersionUp = "1.0.1"; baseData.data.appLastVersionUp = "1.0.1";
if(AppUtils.versionCompare(packageInfo.version,baseData.data?.appLastVersion) if(AppUtils.versionCompare(packageInfo.version,baseData.data?.appLastVersion)
&& AppUtils.versionCompare(value.getString("appLastVersion")??"1.0.0",baseData.data?.appLastVersion)){ && AppUtils.versionCompare(value.getString("appLastVersion")??"1.0.0",baseData.data?.appLastVersion)){

2
lib/view_widget/update_dialog.dart

@ -140,7 +140,7 @@ class _UpdateDialog extends State<UpdateDialog> {
} }
androidUpdate() async { androidUpdate() async {
String url = "http://application.lotus-wallet.com/huixaing?release_id=627cadff23389f2fe6d57cb1"; String url = Platform.isIOS ? "itms-apps://itunes.apple.com/app/id1575124838":"http://application.lotus-wallet.com/huixaing?release_id=627cadff23389f2fe6d57cb1";
if (await canLaunch(url)) { if (await canLaunch(url)) {
await launch(url); await launch(url);
} else { } else {

Loading…
Cancel
Save