|
|
|
import 'package:flutter/cupertino.dart';
|
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
import 'package:huixiang/utils/font_weight.dart';
|
|
|
|
import 'package:flutter_screenutil/flutter_screenutil.dart';
|
|
|
|
|
|
|
|
import '../../generated/l10n.dart';
|
|
|
|
import '../../view_widget/my_appbar.dart';
|
|
|
|
|
|
|
|
class ExclusiveCoupon extends StatefulWidget {
|
|
|
|
@override
|
|
|
|
State<StatefulWidget> createState() {
|
|
|
|
return _ExclusiveCoupon();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
class _ExclusiveCoupon extends State<ExclusiveCoupon> {
|
|
|
|
@override
|
|
|
|
Widget build(BuildContext context) {
|
|
|
|
return Container(
|
|
|
|
margin: EdgeInsets.only(left: 14.w, right: 14.w, bottom: 40.h),
|
|
|
|
width: double.infinity,
|
|
|
|
padding: EdgeInsets.only(top: 20.h,left: 20.h,bottom: 10.h,right: 20.w),
|
|
|
|
decoration: BoxDecoration(
|
|
|
|
borderRadius: BorderRadius.circular(6.w),
|
|
|
|
color: Colors.white,
|
|
|
|
boxShadow: [
|
|
|
|
BoxShadow(
|
|
|
|
color: Colors.black.withAlpha(12),
|
|
|
|
offset: Offset(0, 3),
|
|
|
|
blurRadius: 14,
|
|
|
|
spreadRadius: 0,
|
|
|
|
)
|
|
|
|
],
|
|
|
|
),
|
|
|
|
child: Column(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
Row(
|
|
|
|
children: [
|
|
|
|
SizedBox(width: 7.w,),
|
|
|
|
Image.asset(
|
|
|
|
"assets/image/vip_title.webp",
|
|
|
|
fit: BoxFit.fill, //填充剩余空间
|
|
|
|
height:13.h,
|
|
|
|
width: 27.w,
|
|
|
|
),
|
|
|
|
SizedBox(width: 4.w,),
|
|
|
|
Text(
|
|
|
|
S.of(context).zhuanxiangyouhuiquan,
|
|
|
|
style: TextStyle(
|
|
|
|
color: Colors.black,
|
|
|
|
fontSize: 15.sp,
|
|
|
|
fontWeight: MyFontWeight.semi_bold,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
GestureDetector(
|
|
|
|
behavior: HitTestBehavior.translucent,
|
|
|
|
onTap: (){
|
|
|
|
showAlertDialog();
|
|
|
|
},
|
|
|
|
child:Container(
|
|
|
|
padding: EdgeInsets.only(left: 8.w,right:30.w,top: 3.h,bottom: 3.h),
|
|
|
|
child: Image.asset(
|
|
|
|
"assets/image/vip_tips.webp",
|
|
|
|
fit: BoxFit.fill, //填充剩余空间
|
|
|
|
height:14,
|
|
|
|
width: 14,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
SizedBox(
|
|
|
|
height: 10.h,
|
|
|
|
),
|
|
|
|
Container(
|
|
|
|
height: 124.h,
|
|
|
|
margin: EdgeInsets.only(bottom: 16.h),
|
|
|
|
child: Stack(
|
|
|
|
children: [
|
|
|
|
Image.asset(
|
|
|
|
"assets/image/vip_shop_bj.webp",
|
|
|
|
fit: BoxFit.fill, //填充剩余空间
|
|
|
|
height:double.infinity,
|
|
|
|
width: double.infinity,
|
|
|
|
),
|
|
|
|
Container(
|
|
|
|
child: Row(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
children: [
|
|
|
|
Expanded(child:Padding(
|
|
|
|
padding:EdgeInsets.only(top:25.h,left: 19.w),
|
|
|
|
child: Column(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
Text(
|
|
|
|
"海峡姐妹饮品券",
|
|
|
|
style: TextStyle(
|
|
|
|
color: Color(0xff32A060),
|
|
|
|
fontSize: 15.sp,
|
|
|
|
fontWeight: MyFontWeight.semi_bold,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
SizedBox(height: 5.h,),
|
|
|
|
Text.rich(
|
|
|
|
TextSpan(
|
|
|
|
children: [
|
|
|
|
TextSpan(
|
|
|
|
text: "6",
|
|
|
|
style: TextStyle(
|
|
|
|
fontWeight: MyFontWeight.extra_bold,
|
|
|
|
fontSize: 36.sp,
|
|
|
|
fontFamily: 'JDZhengHT',
|
|
|
|
color: Color(0xffFF7E12),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
TextSpan(
|
|
|
|
text: " 折",
|
|
|
|
style: TextStyle(
|
|
|
|
fontSize: 24.sp,
|
|
|
|
color: Color(0xffFF7E12),
|
|
|
|
fontWeight: MyFontWeight.semi_bold,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
textDirection: TextDirection.ltr,
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),)),
|
|
|
|
Image.asset(
|
|
|
|
"assets/image/vip_shop_hx.webp",
|
|
|
|
fit: BoxFit.fill, //填充剩余空间
|
|
|
|
height:85,
|
|
|
|
width: 85,
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
)
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Container(
|
|
|
|
height: 124.h,
|
|
|
|
margin: EdgeInsets.only(bottom: 16.h),
|
|
|
|
child: Stack(
|
|
|
|
children: [
|
|
|
|
Image.asset(
|
|
|
|
"assets/image/vip_shop_bj.webp",
|
|
|
|
fit: BoxFit.fill, //填充剩余空间
|
|
|
|
height:double.infinity,
|
|
|
|
width: double.infinity,
|
|
|
|
),
|
|
|
|
Container(
|
|
|
|
child: Row(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
children: [
|
|
|
|
Expanded(child:Padding(
|
|
|
|
padding:EdgeInsets.only(top:25.h,left: 19.w),
|
|
|
|
child: Column(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
Text(
|
|
|
|
"前进麦味烘焙券",
|
|
|
|
style: TextStyle(
|
|
|
|
color: Color(0xff32A060),
|
|
|
|
fontSize: 15.sp,
|
|
|
|
fontWeight: MyFontWeight.semi_bold,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
SizedBox(height: 5.h,),
|
|
|
|
Text.rich(
|
|
|
|
TextSpan(
|
|
|
|
children: [
|
|
|
|
TextSpan(
|
|
|
|
text: "7",
|
|
|
|
style: TextStyle(
|
|
|
|
fontWeight: MyFontWeight.extra_bold,
|
|
|
|
fontSize: 36.sp,
|
|
|
|
fontFamily: 'JDZhengHT',
|
|
|
|
color: Color(0xffFF7E12),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
TextSpan(
|
|
|
|
text: " 折",
|
|
|
|
style: TextStyle(
|
|
|
|
fontSize: 24.sp,
|
|
|
|
color: Color(0xffFF7E12),
|
|
|
|
fontWeight: MyFontWeight.semi_bold,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
textDirection: TextDirection.ltr,
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),)),
|
|
|
|
Image.asset(
|
|
|
|
"assets/image/vip_shop_qj.webp",
|
|
|
|
fit: BoxFit.fill, //填充剩余空间
|
|
|
|
height:85,
|
|
|
|
width: 85,
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
)
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
Container(
|
|
|
|
height: 124.h,
|
|
|
|
margin: EdgeInsets.only(bottom: 22.h),
|
|
|
|
child: Stack(
|
|
|
|
children: [
|
|
|
|
Image.asset(
|
|
|
|
"assets/image/vip_shop_bj.webp",
|
|
|
|
fit: BoxFit.fill, //填充剩余空间
|
|
|
|
height:double.infinity,
|
|
|
|
width: double.infinity,
|
|
|
|
),
|
|
|
|
Container(
|
|
|
|
child: Row(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center,
|
|
|
|
children: [
|
|
|
|
Expanded(child:Padding(
|
|
|
|
padding:EdgeInsets.only(top:25.h,left: 19.w),
|
|
|
|
child: Column(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
Text(
|
|
|
|
"门店火锅券",
|
|
|
|
style: TextStyle(
|
|
|
|
color: Color(0xff32A060),
|
|
|
|
fontSize: 15.sp,
|
|
|
|
fontWeight: MyFontWeight.semi_bold,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
SizedBox(height: 5.h,),
|
|
|
|
Text.rich(
|
|
|
|
TextSpan(
|
|
|
|
children: [
|
|
|
|
TextSpan(
|
|
|
|
text: "8",
|
|
|
|
style: TextStyle(
|
|
|
|
fontWeight: MyFontWeight.extra_bold,
|
|
|
|
fontSize: 36.sp,
|
|
|
|
fontFamily: 'JDZhengHT',
|
|
|
|
color: Color(0xffFF7E12),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
TextSpan(
|
|
|
|
text: " 折",
|
|
|
|
style: TextStyle(
|
|
|
|
fontSize: 24.sp,
|
|
|
|
color: Color(0xffFF7E12),
|
|
|
|
fontWeight: MyFontWeight.semi_bold,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
textDirection: TextDirection.ltr,
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),)),
|
|
|
|
Image.asset(
|
|
|
|
"assets/image/vip_shop_hg.webp",
|
|
|
|
fit: BoxFit.fill, //填充剩余空间
|
|
|
|
height:85,
|
|
|
|
width: 85,
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
)
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
),
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
///会员优惠规则弹窗
|
|
|
|
showAlertDialog() {
|
|
|
|
//显示对话框
|
|
|
|
showDialog(
|
|
|
|
context: context,
|
|
|
|
builder: (BuildContext context) {
|
|
|
|
return SimpleDialog(
|
|
|
|
backgroundColor: Colors.transparent,
|
|
|
|
elevation: 0,
|
|
|
|
shape: RoundedRectangleBorder(
|
|
|
|
borderRadius: BorderRadius.circular(6),
|
|
|
|
),
|
|
|
|
children: <Widget>[
|
|
|
|
Container(
|
|
|
|
width: double.infinity,
|
|
|
|
height:470.h,
|
|
|
|
padding: EdgeInsets.only(left: 14.w,right: 14.w,bottom: 16.h),
|
|
|
|
decoration: new BoxDecoration(
|
|
|
|
color: Colors.white,
|
|
|
|
borderRadius: BorderRadius.circular(8),
|
|
|
|
),
|
|
|
|
child: Scaffold(
|
|
|
|
appBar: MyAppBar(
|
|
|
|
title:"",
|
|
|
|
titleColor: Colors.black,
|
|
|
|
titleSize: 10.sp,
|
|
|
|
background: Colors.white,
|
|
|
|
leadingColor: Colors.white,
|
|
|
|
actions: [
|
|
|
|
GestureDetector(
|
|
|
|
onTap: () {
|
|
|
|
Navigator.of(context).pop();
|
|
|
|
},
|
|
|
|
child: Icon(
|
|
|
|
Icons.clear,
|
|
|
|
color: Colors.black,
|
|
|
|
),
|
|
|
|
)
|
|
|
|
],
|
|
|
|
),
|
|
|
|
body: Container(
|
|
|
|
color: Colors.white,
|
|
|
|
child: SingleChildScrollView(
|
|
|
|
physics: BouncingScrollPhysics(),
|
|
|
|
child: Container(
|
|
|
|
child:Column(
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start,
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start,
|
|
|
|
children: [
|
|
|
|
// Row(
|
|
|
|
// children: [
|
|
|
|
// Spacer(),
|
|
|
|
// GestureDetector(
|
|
|
|
// onTap: () {
|
|
|
|
// Navigator.of(context).pop();
|
|
|
|
// },
|
|
|
|
// child: Icon(
|
|
|
|
// Icons.clear,
|
|
|
|
// color: Colors.black,
|
|
|
|
// ),
|
|
|
|
// )
|
|
|
|
// ],
|
|
|
|
// ),
|
|
|
|
SizedBox(height: 10.h,),
|
|
|
|
Text(
|
|
|
|
"VIP会员专享优惠券:"
|
|
|
|
"\n ①海峡姐妹饮品券"
|
|
|
|
"\n *用户开通回乡VIP卡,可享全单饮品6折优惠。"
|
|
|
|
"\n *适用饮品:门店现制奶茶类饮品及现制咖啡类饮品。"
|
|
|
|
"\n *适用门店:海峡姐妹茶汉街店、前进麦味*海峡姐妹茶哈乐城店"
|
|
|
|
"\n ②前进麦味烘焙券"
|
|
|
|
"\n *用户开通回乡VIP卡,可享全单面包7折优惠。"
|
|
|
|
"\n *适用产品:门店现制面包类产品及甜品类产品。"
|
|
|
|
"\n *适用门店:前进麦味凯德1818店、前进麦味*海峡姐妹茶哈乐城店"
|
|
|
|
"\n ③回乡农场火锅券"
|
|
|
|
"\n *用户开通回乡VIP卡,可享全单菜品(小料、酒水、饮品不参与)8折优惠。"
|
|
|
|
"\n *适用产品:门店现制菜品"
|
|
|
|
"\n *适用门店:回乡农场火锅汉街店"
|
|
|
|
"\n ④百年川椒火锅券"
|
|
|
|
"\n *用户开通回乡VIP卡,可享全单菜品(小料、酒水、饮品不参与)8折优惠。"
|
|
|
|
"\n *适用产品:门店现制菜品"
|
|
|
|
"\n *适用门店:百年川椒重庆老火锅光谷店",
|
|
|
|
style: TextStyle(
|
|
|
|
fontWeight: MyFontWeight.medium,
|
|
|
|
fontSize: 14.sp,
|
|
|
|
height: 1.7.h,
|
|
|
|
color: Colors.black,
|
|
|
|
),
|
|
|
|
),
|
|
|
|
SizedBox(height: 15.h,)
|
|
|
|
],
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
),
|
|
|
|
],
|
|
|
|
);
|
|
|
|
},
|
|
|
|
);
|
|
|
|
}
|
|
|
|
}
|