You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
119 lines
4.2 KiB
119 lines
4.2 KiB
import 'package:flutter/material.dart'; |
|
import 'package:flutter_screenutil/flutter_screenutil.dart'; |
|
import 'package:flutter_smart_dialog/flutter_smart_dialog.dart'; |
|
import 'package:huixiang/generated/l10n.dart'; |
|
import 'package:huixiang/retrofit/data/login_info.dart'; |
|
import 'package:huixiang/utils/flutter_utils.dart'; |
|
import 'package:huixiang/utils/font_weight.dart'; |
|
import 'package:huixiang/view_widget/round_button.dart'; |
|
|
|
class InviteSuccessDialog extends StatefulWidget { |
|
final String invite; |
|
final InterviewCouponList interviewCouponList; |
|
|
|
InviteSuccessDialog(this.invite,this.interviewCouponList); |
|
|
|
@override |
|
State<StatefulWidget> createState() { |
|
return _InviteSuccessDialog(); |
|
} |
|
|
|
} |
|
|
|
class _InviteSuccessDialog extends State<InviteSuccessDialog> { |
|
@override |
|
Widget build(BuildContext context) { |
|
return SimpleDialog( |
|
titlePadding: EdgeInsets.all(10), |
|
backgroundColor: Colors.transparent, |
|
elevation: 0, |
|
shape: RoundedRectangleBorder( |
|
borderRadius: BorderRadius.circular(6), |
|
), |
|
children: [ |
|
Column(children: [ |
|
Container( |
|
decoration: BoxDecoration( |
|
color: Colors.white, |
|
borderRadius: BorderRadius.circular(8.w), |
|
), |
|
padding: EdgeInsets.only(top:20.h,left: 12,right: 12), |
|
margin: EdgeInsets.only(left:60.w,right:60.w), |
|
child: Container( |
|
padding: EdgeInsets.symmetric(vertical: 10.h), |
|
child: Column( |
|
mainAxisAlignment: MainAxisAlignment.spaceAround, |
|
crossAxisAlignment: CrossAxisAlignment.center, |
|
children: [ |
|
Image.asset( |
|
"assets/image/yq.webp", |
|
width: 61, |
|
height: 65, |
|
), |
|
SizedBox(height: 9.h,), |
|
Text( |
|
S.of(context).yaoqingwancheng, |
|
style: TextStyle( |
|
color: Color(0xFF353535), |
|
fontSize: 16.sp, |
|
fontWeight: MyFontWeight.medium, |
|
), |
|
), |
|
SizedBox(height: 6.h), |
|
RichText( |
|
textAlign: TextAlign.center, |
|
text: TextSpan( |
|
text: |
|
"通过${widget.invite}的邀请码完成邀请,获得", |
|
style: TextStyle( |
|
color: Color(0xFF1A1A1A), |
|
fontSize: 14.sp, |
|
fontWeight: MyFontWeight.regular, |
|
height: 1.5.h), |
|
children: [ |
|
TextSpan( |
|
text:"${widget.interviewCouponList.storeName}${widget.interviewCouponList.couponName} * ${widget.interviewCouponList.bizType}张", |
|
style: TextStyle(color: Color(0xFF32A060),fontSize: 14.sp,fontWeight: MyFontWeight.regular), |
|
), |
|
] |
|
),), |
|
SizedBox(height: 13,), |
|
GestureDetector( |
|
onTap: (){ |
|
setState(() { |
|
Navigator.of(context).pop(); |
|
}); |
|
}, |
|
child:RoundButton( |
|
text: S.of(context).queren, |
|
textColor: Colors.white, |
|
width: 130.w, |
|
height: 34.h, |
|
padding: EdgeInsets.symmetric(vertical: 6.h), |
|
fontSize: 16.sp, |
|
fontWeight: MyFontWeight.semi_bold, |
|
backgroup: Color(0xFF32A060), |
|
radius: 4.w, |
|
), |
|
), |
|
SizedBox(height:20), |
|
], |
|
), |
|
), |
|
), |
|
SizedBox(height:35), |
|
GestureDetector(onTap: (){ |
|
setState(() { |
|
Navigator.of(context).pop(); |
|
}); |
|
},child:Image.asset( |
|
"assets/image/yq_qx.webp", |
|
width: 34, |
|
height: 34, |
|
),) |
|
|
|
],), |
|
], |
|
); |
|
} |
|
}
|
|
|