|
|
@ -3,6 +3,7 @@ import 'dart:math'; |
|
|
|
import 'package:flutter/material.dart'; |
|
|
|
import 'package:flutter/material.dart'; |
|
|
|
import 'package:huixiang/generated/l10n.dart'; |
|
|
|
import 'package:huixiang/generated/l10n.dart'; |
|
|
|
import 'package:huixiang/retrofit/data/coupon.dart'; |
|
|
|
import 'package:huixiang/retrofit/data/coupon.dart'; |
|
|
|
|
|
|
|
import 'package:huixiang/view_widget/custom_image.dart'; |
|
|
|
import 'package:huixiang/view_widget/round_button.dart'; |
|
|
|
import 'package:huixiang/view_widget/round_button.dart'; |
|
|
|
import 'package:huixiang/view_widget/separator.dart'; |
|
|
|
import 'package:huixiang/view_widget/separator.dart'; |
|
|
|
|
|
|
|
|
|
|
@ -70,20 +71,23 @@ class CouponWidget extends StatelessWidget { |
|
|
|
children: [ |
|
|
|
children: [ |
|
|
|
Container( |
|
|
|
Container( |
|
|
|
margin: EdgeInsets.only(left: 20), |
|
|
|
margin: EdgeInsets.only(left: 20), |
|
|
|
child: Image.network( |
|
|
|
child: MImage( |
|
|
|
(coupon == null || |
|
|
|
(coupon == null || |
|
|
|
coupon.couponImg == null || |
|
|
|
coupon.couponImg == null || |
|
|
|
coupon.couponImg == "") |
|
|
|
coupon.couponImg == "") |
|
|
|
? "" |
|
|
|
? "" |
|
|
|
: coupon.couponImg, |
|
|
|
: coupon.couponImg, |
|
|
|
width: 60, |
|
|
|
) |
|
|
|
height: 60, |
|
|
|
// Image.network( |
|
|
|
fit: BoxFit.cover, |
|
|
|
|
|
|
|
errorBuilder: (context, error, e) { |
|
|
|
// width: 60, |
|
|
|
return Image.asset( |
|
|
|
// height: 60, |
|
|
|
"assets/image/default_1.png"); |
|
|
|
// fit: BoxFit.cover, |
|
|
|
}, |
|
|
|
// errorBuilder: (context, error, e) { |
|
|
|
), |
|
|
|
// return Image.asset( |
|
|
|
|
|
|
|
// "assets/image/default_1.png"); |
|
|
|
|
|
|
|
// }, |
|
|
|
|
|
|
|
// ), |
|
|
|
), |
|
|
|
), |
|
|
|
Expanded( |
|
|
|
Expanded( |
|
|
|
flex: 1, |
|
|
|
flex: 1, |
|
|
|