|
...
|
...
|
@@ -3,6 +3,7 @@ import 'dart:convert'; |
|
|
|
import 'dart:io';
|
|
|
|
import 'package:cached_network_image/cached_network_image.dart';
|
|
|
|
import 'package:common_utils/common_utils.dart';
|
|
|
|
import 'package:device_info/device_info.dart';
|
|
|
|
import 'package:flutter/cupertino.dart';
|
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
import 'package:flutter/services.dart';
|
|
...
|
...
|
@@ -943,7 +944,22 @@ class HomePageState extends State<HomePage> with WidgetsBindingObserver { |
|
|
|
}
|
|
|
|
|
|
|
|
//初始化信鸽推送
|
|
|
|
initPlatformState() {
|
|
|
|
initPlatformState() async {
|
|
|
|
//安卓弹窗提示使用通知权限目的,仅提示一次
|
|
|
|
|
|
|
|
//全局提示权限使用目的
|
|
|
|
// if (Platform.isAndroid) {
|
|
|
|
// DeviceInfoPlugin deviceInfo = DeviceInfoPlugin();
|
|
|
|
// AndroidDeviceInfo androidInfo = await deviceInfo.androidInfo;
|
|
|
|
// if (androidInfo.manufacturer == 'HUAWEI') {
|
|
|
|
// if (!(App.sp.getBool("h_notification") ?? false)) {
|
|
|
|
// DialogUtil.showAuthorityDestination(context, 'h_notification',
|
|
|
|
// '通知权限使用说明', '在客户预订以及店内营销需要的时候,给您发送通知消息。');
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
// }
|
|
|
|
// App.sp.setBool("h_notification", true);
|
|
|
|
|
|
|
|
/// 开启DEBUG
|
|
|
|
XgFlutterPlugin().setEnableDebug(false);
|
|
|
|
|
...
|
...
|
|