|
|
@ -16,9 +16,10 @@ class NewCouponWidget extends StatelessWidget { |
|
|
|
|
|
|
|
|
|
|
|
@override |
|
|
|
@override |
|
|
|
Widget build(BuildContext context) { |
|
|
|
Widget build(BuildContext context) { |
|
|
|
return buildCoupon(context); |
|
|
|
return homeCoupon(context); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
///优惠券ui |
|
|
|
Widget buildCoupon(BuildContext context) { |
|
|
|
Widget buildCoupon(BuildContext context) { |
|
|
|
// if(coupon != null) { |
|
|
|
// if(coupon != null) { |
|
|
|
// coupon.isEx = fa; |
|
|
|
// coupon.isEx = fa; |
|
|
@ -368,6 +369,414 @@ class NewCouponWidget extends StatelessWidget { |
|
|
|
); |
|
|
|
); |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
///首页优惠券ui |
|
|
|
|
|
|
|
Widget homeCoupon(BuildContext context) { |
|
|
|
|
|
|
|
return Container( |
|
|
|
|
|
|
|
height: 100.h, |
|
|
|
|
|
|
|
width: double.infinity, |
|
|
|
|
|
|
|
margin: EdgeInsets.fromLTRB(14.w, 6.h, 14.w, 6.h), |
|
|
|
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
|
|
|
image: DecorationImage( |
|
|
|
|
|
|
|
fit: BoxFit.fill, |
|
|
|
|
|
|
|
image: AssetImage("assets/image/week_coupons.webp"), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
child: Row( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Expanded( |
|
|
|
|
|
|
|
flex: 1, |
|
|
|
|
|
|
|
child:Container( |
|
|
|
|
|
|
|
margin: EdgeInsets.only(top: 12,bottom: 12), |
|
|
|
|
|
|
|
child: Column( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Expanded(child: Container( |
|
|
|
|
|
|
|
child:homeWidget(context), |
|
|
|
|
|
|
|
)), |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
)), |
|
|
|
|
|
|
|
Expanded( |
|
|
|
|
|
|
|
flex: 2, |
|
|
|
|
|
|
|
child:Container( |
|
|
|
|
|
|
|
margin: EdgeInsets.only(top: 12,left: 12,bottom: 12), |
|
|
|
|
|
|
|
child: Column( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.start, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Expanded(child: |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
coupon != null ? coupon.couponName ?? "" : "", |
|
|
|
|
|
|
|
maxLines: 1, |
|
|
|
|
|
|
|
overflow: TextOverflow.ellipsis, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 14.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: Color(0xFF353535), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
)), |
|
|
|
|
|
|
|
Expanded(child: |
|
|
|
|
|
|
|
(coupon.useStartTime == null && |
|
|
|
|
|
|
|
coupon.useEndTime == null)? |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
S.of(context).quantian, |
|
|
|
|
|
|
|
maxLines: 1, |
|
|
|
|
|
|
|
overflow: TextOverflow.ellipsis, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.regular, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3) :Color(0xFF4D4D4D), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
):Text( |
|
|
|
|
|
|
|
"有效期至 ${coupon?.useEndTime ?? ""}", |
|
|
|
|
|
|
|
maxLines:1, |
|
|
|
|
|
|
|
overflow: TextOverflow.ellipsis, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.regular, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3) :Color(0xFF4D4D4D), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
)), |
|
|
|
|
|
|
|
GestureDetector( |
|
|
|
|
|
|
|
onTap: (){ |
|
|
|
|
|
|
|
// showDeleteDialog(); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
child: Row( |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
"使用详情", |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.regular, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xFF4D4D4D), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
Icon( |
|
|
|
|
|
|
|
Icons.keyboard_arrow_right, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3) :Color(0xFF4D4D4D), |
|
|
|
|
|
|
|
size: 20, |
|
|
|
|
|
|
|
) |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
) |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
)), |
|
|
|
|
|
|
|
Column( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.end, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.end, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Container( |
|
|
|
|
|
|
|
margin: EdgeInsets.only(right:12.w,bottom: 12), |
|
|
|
|
|
|
|
child: homeBtn(context), |
|
|
|
|
|
|
|
) |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
) |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Widget homeWidget(BuildContext context) { |
|
|
|
|
|
|
|
if (coupon.bizType == 1) { |
|
|
|
|
|
|
|
return Column( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Row( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.baseline, |
|
|
|
|
|
|
|
textBaseline: TextBaseline.alphabetic, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
"¥", |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 16.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.medium, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
SizedBox( |
|
|
|
|
|
|
|
height: 4.h, |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
coupon != null |
|
|
|
|
|
|
|
? double.tryParse("${coupon.discountAmount}" ?? "0") |
|
|
|
|
|
|
|
.toInt() |
|
|
|
|
|
|
|
.toString() |
|
|
|
|
|
|
|
: "", |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 26.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
S.of(context).manyuankeyong(coupon != null |
|
|
|
|
|
|
|
? ("${coupon.fullAmount}" ?? "0") |
|
|
|
|
|
|
|
.toString() |
|
|
|
|
|
|
|
: ""), |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} else if (coupon.bizType == 3) { |
|
|
|
|
|
|
|
return Column( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Container( |
|
|
|
|
|
|
|
padding: EdgeInsets.only(bottom:10,top: 7), |
|
|
|
|
|
|
|
child: Row( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
S.of(context).duihuanquan, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 26.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
S.of(context).xianshangshiyong, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} else if (coupon.bizType == 5) { |
|
|
|
|
|
|
|
return Column( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Container( |
|
|
|
|
|
|
|
padding: EdgeInsets.only(bottom:10,top: 7), |
|
|
|
|
|
|
|
child: Row( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
S.of(context).duihuanquan, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 26.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
S.of(context).xianxiashiyong, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
return Column( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.start, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.center, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Row( |
|
|
|
|
|
|
|
mainAxisAlignment: MainAxisAlignment.center, |
|
|
|
|
|
|
|
crossAxisAlignment: CrossAxisAlignment.baseline, |
|
|
|
|
|
|
|
textBaseline: TextBaseline.alphabetic, |
|
|
|
|
|
|
|
children: [ |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
coupon != null |
|
|
|
|
|
|
|
? "${(coupon.discountPercent / 10.0 >= 10) ? 10 : coupon.discountPercent / 10.0}" ?? |
|
|
|
|
|
|
|
"0" |
|
|
|
|
|
|
|
: "", |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 40.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
SizedBox( |
|
|
|
|
|
|
|
height: 4.h, |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
"折", |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 20.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
Text( |
|
|
|
|
|
|
|
S.of(context).quanchangtongyong, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: coupon.status == 3 ? Color(0xFFB3B3B3):Color(0xff32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
], |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Widget homeBtn(context) { |
|
|
|
|
|
|
|
if (type == 1) { |
|
|
|
|
|
|
|
if (coupon != null && coupon.status == 0) { |
|
|
|
|
|
|
|
return Align( |
|
|
|
|
|
|
|
alignment: Alignment.centerRight, |
|
|
|
|
|
|
|
child: InkWell( |
|
|
|
|
|
|
|
onTap: () { |
|
|
|
|
|
|
|
callback(type); |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
child: Container( |
|
|
|
|
|
|
|
padding: EdgeInsets.symmetric(horizontal: 14,vertical: 2), |
|
|
|
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
|
|
|
borderRadius: BorderRadius.circular(3), |
|
|
|
|
|
|
|
color: Color(0xFF32A060), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
child: Text( |
|
|
|
|
|
|
|
S.of(context).lingqu, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.medium, |
|
|
|
|
|
|
|
color: Colors.white, |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
return Align( |
|
|
|
|
|
|
|
alignment: Alignment.centerRight, |
|
|
|
|
|
|
|
child: Container( |
|
|
|
|
|
|
|
padding: EdgeInsets.symmetric(horizontal: 14,vertical: 2), |
|
|
|
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
|
|
|
borderRadius: BorderRadius.circular(3), |
|
|
|
|
|
|
|
color: Colors.grey, |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
child: Text( |
|
|
|
|
|
|
|
S.of(context).yilingqu, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.medium, |
|
|
|
|
|
|
|
color: Colors.white, |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
if (coupon != null && coupon.status == 1) { |
|
|
|
|
|
|
|
return Align( |
|
|
|
|
|
|
|
alignment: Alignment.centerRight, |
|
|
|
|
|
|
|
child: InkWell( |
|
|
|
|
|
|
|
onTap: () { |
|
|
|
|
|
|
|
callback(type); |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
child: Container( |
|
|
|
|
|
|
|
width: 56.w, |
|
|
|
|
|
|
|
height: 19.h, |
|
|
|
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
|
|
|
color: Color(0xFF32A060), |
|
|
|
|
|
|
|
borderRadius: BorderRadius.circular(3), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
alignment: Alignment.center, |
|
|
|
|
|
|
|
child:Text( |
|
|
|
|
|
|
|
"立即使用", |
|
|
|
|
|
|
|
maxLines: 1, |
|
|
|
|
|
|
|
overflow: TextOverflow.ellipsis, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.regular, |
|
|
|
|
|
|
|
color: Color(0xFFFFFFFF), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
// Container( |
|
|
|
|
|
|
|
// padding: EdgeInsets.fromLTRB(16.w, 2.h, 16.w, 2.h), |
|
|
|
|
|
|
|
// decoration: BoxDecoration( |
|
|
|
|
|
|
|
// borderRadius: BorderRadius.circular(10.5), |
|
|
|
|
|
|
|
// color: Color(0xFF32A060), |
|
|
|
|
|
|
|
// ), |
|
|
|
|
|
|
|
// child: Text( |
|
|
|
|
|
|
|
// (coupon.bizType == 5 || coupon.bizType == 3) |
|
|
|
|
|
|
|
// ? S.of(context).quhexiao |
|
|
|
|
|
|
|
// : S.of(context).qushiyong, |
|
|
|
|
|
|
|
// style: TextStyle( |
|
|
|
|
|
|
|
// fontSize: 12.sp, |
|
|
|
|
|
|
|
// fontWeight: MyFontWeight.medium, |
|
|
|
|
|
|
|
// color: Colors.white, |
|
|
|
|
|
|
|
// ), |
|
|
|
|
|
|
|
// ), |
|
|
|
|
|
|
|
// ), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} else if (coupon != null && coupon.status == 2) { |
|
|
|
|
|
|
|
return Align( |
|
|
|
|
|
|
|
alignment: Alignment.centerRight, |
|
|
|
|
|
|
|
child: Container( |
|
|
|
|
|
|
|
padding: EdgeInsets.symmetric(horizontal: 14,vertical: 2), |
|
|
|
|
|
|
|
decoration: BoxDecoration( |
|
|
|
|
|
|
|
borderRadius: BorderRadius.circular(3), |
|
|
|
|
|
|
|
// border: Border.all( |
|
|
|
|
|
|
|
// width: 1, color: Color(0xFFA0A0A0), style: BorderStyle.solid) |
|
|
|
|
|
|
|
color: Color(0xFFA0A0A0), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
child: Text( |
|
|
|
|
|
|
|
S.of(context).yishiyong, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.medium, |
|
|
|
|
|
|
|
color: Colors.white, |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} else { |
|
|
|
|
|
|
|
return Align( |
|
|
|
|
|
|
|
alignment: Alignment.centerRight, |
|
|
|
|
|
|
|
child: Container( |
|
|
|
|
|
|
|
padding: EdgeInsets.symmetric(horizontal: 14,vertical: 2), |
|
|
|
|
|
|
|
// decoration: BoxDecoration( |
|
|
|
|
|
|
|
// borderRadius: BorderRadius.circular(10.5), |
|
|
|
|
|
|
|
// // border: Border.all( |
|
|
|
|
|
|
|
// // width: 1, color: Color(0xFFA0A0A0), style: BorderStyle.solid) |
|
|
|
|
|
|
|
// color: Color(0xFFA0A0A0), |
|
|
|
|
|
|
|
// ), |
|
|
|
|
|
|
|
child: Text( |
|
|
|
|
|
|
|
S.of(context).yishixiao, |
|
|
|
|
|
|
|
style: TextStyle( |
|
|
|
|
|
|
|
fontSize: 12.sp, |
|
|
|
|
|
|
|
fontWeight: MyFontWeight.semi_bold, |
|
|
|
|
|
|
|
color: Color(0xFFB3B3B3), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
), |
|
|
|
|
|
|
|
); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
Widget priceWidget(BuildContext context) { |
|
|
|
Widget priceWidget(BuildContext context) { |
|
|
|
if (coupon.bizType == 1) { |
|
|
|
if (coupon.bizType == 1) { |
|
|
|
return Column( |
|
|
|
return Column( |
|
|
|