import 'package:oktoast/oktoast.dart';
import 'package:permission_handler/permission_handler.dart';

/// 请求权限工具

/// 请求位置权限
Future<bool> reqPositionPermission() async {
  final status = await Permission.location.request();
  if (status == PermissionStatus.granted) {
    return true;
  } else {
    showToast('需要定位权限，请去设置中开启');
    return false;
  }
}
