修改弹窗

pull/1/head
张萌 3 years ago
parent a9822f6833
commit 274f77ecb8

@ -0,0 +1,147 @@
import 'package:aku_new_community/base/base_style.dart';
import 'package:aku_new_community/extensions/num_ext.dart';
import 'package:aku_new_community/pages/setting_page/agreement_page/agreement_page.dart';
import 'package:aku_new_community/pages/setting_page/agreement_page/privacy_page.dart';
import 'package:aku_new_community/widget/bee_divider.dart';
import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:get/get.dart';
class AppVerifyDialog extends StatelessWidget {
const AppVerifyDialog({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Center(
child: Container(
width: 600.w,
height: 700.w,
clipBehavior: Clip.antiAliasWithSaveLayer,
decoration: BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.circular(24.w),
),
child: Material(
child: Container(
decoration: BoxDecoration(
gradient: LinearGradient(
begin: Alignment.topCenter,
end: Alignment.bottomCenter,
stops: [
0,
0.3,
],
colors: [
Color(0x33FBE541),
Colors.white,
])),
child: Column(
children: [
Padding(
padding: EdgeInsets.symmetric(horizontal: 40.w),
child: Column(
children: [
52.hb,
Text(
'欢迎使用小蜜蜂',
style: TextStyle(
color: Colors.black.withOpacity(0.85),
fontSize: 28.sp,
fontWeight: FontWeight.bold),
),
45.hb,
Text(
'''
使使
访访
使
''',
style: TextStyle(
color: Colors.black.withOpacity(0.85),
fontSize: 24.sp),
),
30.hb,
RichText(
text: TextSpan(
text: '更多详细信息,请您阅读',
style: TextStyle(
color: Colors.black.withOpacity(0.85),
fontSize: 24.sp),
children: [
TextSpan(
text: '《用户协议》',
style: TextStyle(
color: kPrimaryColor, fontSize: 24.sp),
recognizer: TapGestureRecognizer()
..onTap = () {
Get.to(() => AgreementPage());
},
),
TextSpan(
text: '',
style: TextStyle(
color: Colors.black.withOpacity(0.85),
fontSize: 24.sp),
),
TextSpan(
text: '《小蜜蜂隐私保护政策》',
style: TextStyle(
color: kPrimaryColor, fontSize: 24.sp),
recognizer: TapGestureRecognizer()
..onTap = () {
Get.to(() => PrivacyPage());
},
),
]),
),
],
),
),
Spacer(),
BeeDivider.horizontal(),
ConstrainedBox(
constraints: BoxConstraints(maxHeight: 100.w),
child: Row(
children: [
Expanded(
child: MaterialButton(
padding: EdgeInsets.symmetric(vertical: 30.w),
onPressed: () {
Get.back(result: false);
},
child: Text('退出',
style: TextStyle(
fontSize: 24.sp
),),
),
),
Container(
width: 2.w,
height: double.infinity,
color: Color(0xFFF0F0F0),
),
Expanded(
child: MaterialButton(
padding: EdgeInsets.symmetric(vertical: 20.w),
onPressed: () {
Get.back(result: true);
},
child: Text('确认',style: TextStyle(
fontSize: 24.sp
),),
),
),
],
),
),
],
),
),
),
),
);
}
}

@ -5,6 +5,7 @@ import 'package:aku_new_community/main_initialize.dart';
import 'package:aku_new_community/pages/setting_page/agreement_page/agreement_page.dart';
import 'package:aku_new_community/pages/setting_page/agreement_page/privacy_page.dart';
import 'package:aku_new_community/pages/sign/login/other_login_page.dart';
import 'package:aku_new_community/pages/splash/app_verify_dialog.dart';
import 'package:aku_new_community/utils/developer_util.dart';
import 'package:aku_new_community/utils/headers.dart';
import 'package:aku_new_community/utils/hive_store.dart';
@ -33,52 +34,54 @@ class _SplashPageState extends State<SplashPage> {
TapGestureRecognizer _privacyRecognizer = TapGestureRecognizer();
Future<bool?> _showLoginVerify() async {
return await showCupertinoDialog(
barrierDismissible: false,
context: context,
builder: (context) {
return CupertinoAlertDialog(
title: Text('隐私政策和用户协议'),
content: RichText(
text: TextSpan(
text: '点击登录即表示您已阅读并同意',
style: TextStyle(color: Colors.black),
children: [
TextSpan(
text: '《用户协议》',
style: TextStyle(color: Colors.blue),
recognizer: _agreementRecognizer
..onTap = () {
Get.to(() => AgreementPage());
}),
TextSpan(
text: '《隐私政策》',
style: TextStyle(color: Colors.blue),
recognizer: _privacyRecognizer
..onTap = () {
Get.to(() => PrivacyPage());
}),
TextSpan(
style: TextStyle(color: Colors.black),
text:
'(特别是免除或限制责任、管辖等粗体下划线标注的条款)。如您不同意上述协议的任何条款,您应立即停止登录及使用本软件及服务。')
]),
),
// ),
actions: [
CupertinoDialogAction(
child: Text('拒绝'),
onPressed: () => Get.back(result: false),
),
CupertinoDialogAction(
child: Text('同意'),
onPressed: () => Get.back(result: true),
),
],
);
},
);
var re = await Get.dialog(AppVerifyDialog());
return re;
// return await showCupertinoDialog(
// barrierDismissible: false,
// context: context,
// builder: (context) {
// return CupertinoAlertDialog(
// title: Text('隐私政策和用户协议'),
// content: RichText(
// text: TextSpan(
// text: '点击登录即表示您已阅读并同意',
// style: TextStyle(color: Colors.black),
// children: [
// TextSpan(
// text: '《用户协议》',
// style: TextStyle(color: Colors.blue),
// recognizer: _agreementRecognizer
// ..onTap = () {
// Get.to(() => AgreementPage());
// }),
// TextSpan(
// text: '《隐私政策》',
// style: TextStyle(color: Colors.blue),
// recognizer: _privacyRecognizer
// ..onTap = () {
// Get.to(() => PrivacyPage());
// }),
// TextSpan(
// style: TextStyle(color: Colors.black),
// text:
// '(特别是免除或限制责任、管辖等粗体下划线标注的条款)。如您不同意上述协议的任何条款,您应立即停止登录及使用本软件及服务。')
// ]),
// ),
//
// // ),
// actions: [
// CupertinoDialogAction(
// child: Text('拒绝'),
// onPressed: () => Get.back(result: false),
// ),
// CupertinoDialogAction(
// child: Text('同意'),
// onPressed: () => Get.back(result: true),
// ),
// ],
// );
// },
// );
}
@override

@ -150,7 +150,6 @@ flutter:
- assets/tab/
- assets/applications/
- assets/static/
- assets/json/
- assets/bracelet/
- assets/home/
- assets/newIcon/

@ -16,11 +16,17 @@ buildApk() async {
String date = DateUtil.formatDate(DateTime.now(), format: 'yy_MM_dd_HH_mm');
String version = await getVersion();
await runAsync('rm', arguments: ['-rf', Config.apkDir]);
await runAsync('mkdir', arguments: ['-p', Config.apkDir]);
await runAsync('mv', arguments: [
await runAsync('rmdir', arguments: [ Config.apkDir]);
await runAsync('mkdir', arguments: [ Config.apkDir]);
await runAsync('move', arguments: [
Config.buildPath,
'${Config.apkDir}/${Config.packageName}_${version}_release_$date.apk'
'${Config.apkDir}\\${Config.packageName}_${version}_release_$date.apk'
]);
await runAsync('ren',arguments: [
'${Config.apkDir}\\app-release.apk',
'${Config.apkDir}\\${Config.packageName}_${version}_release_$date.apk',
]);
}

@ -1,19 +1,19 @@
class Config {
///
static const String homeDir = '/users/zhangmeng';
static const String homeDir = 'G:\\apk';
///
static const String packageName = 'aku_new_community';
///
static String get buildPath =>
'./build/app/outputs/flutter-apk/app-release.apk';
'\\build\\app\\outputs\\flutter-apk\\app-release.apk';
///
static String get apkDevDir =>
'/users/zhangmeng/team/bee/app/aku_new_community/dev';
'$homeDir\\aku_new_community\\dev';
///
static String get apkDir =>
'/users/zhangmeng/team/bee/app/aku_new_community/release';
'$homeDir\\aku_new_community\\release';
}

Loading…
Cancel
Save