戴余标 2 years ago
parent b3fc551780
commit fa00407e13

@ -15,6 +15,7 @@ import 'package:project_telephony/utils/permissionutils.dart';
import 'package:telephony/telephony.dart'; import 'package:telephony/telephony.dart';
import '../../permission.dart'; import '../../permission.dart';
import '../home/home_page.dart';
class UserPage extends StatefulWidget { class UserPage extends StatefulWidget {
const UserPage({Key? key}) : super(key: key); const UserPage({Key? key}) : super(key: key);
@ -32,7 +33,6 @@ class _UserPageState extends State<UserPage> {
bool vle = false; bool vle = false;
bool tooken = true; bool tooken = true;
@override @override
Widget build(BuildContext context) { Widget build(BuildContext context) {
return CloudScaffold( return CloudScaffold(
@ -56,9 +56,7 @@ class _UserPageState extends State<UserPage> {
PloneBottom( PloneBottom(
border: false, border: false,
onTap: () { onTap: () {
PermissionUtils.requestAllPermission(); Get.to(() => const HomePage());
// Get.to(() => const HomePage());
}, },
textColor: const Color(0xFF1890FF), textColor: const Color(0xFF1890FF),
color1: const Color(0xFFEBF5FF), color1: const Color(0xFFEBF5FF),
@ -253,8 +251,7 @@ class _UserPageState extends State<UserPage> {
Permission.sms, Permission.sms,
Permission.phone, Permission.phone,
]; ];
PermissionHelper.check(permissions, PermissionHelper.check(permissions, onSuccess: () {
onSuccess: () {
print('onSuccess'); print('onSuccess');
}, onFailed: () { }, onFailed: () {
print('onFailed'); print('onFailed');

Loading…
Cancel
Save