Browse Source

Merge branches 'dev' and 'master' of https://git.lotus-wallet.com/fmk/huixiang_app

 Conflicts:
	lib/generated/l10n.dart
	lib/l10n/intl_en.arb
	lib/l10n/intl_zh_CN.arb
	lib/l10n/intl_zh_Hans_CN.arb
	lib/l10n/intl_zh_Hant_CN.arb
	lib/l10n/intl_zh_TW.arb
null_safety
fmk 4 years ago
parent
commit
a027d04061
  1. BIN
      assets/image/2x/icon_shop.png
  2. BIN
      assets/image/3x/icon_shop.png
  3. BIN
      assets/image/icon_shop.png
  4. 3
      lib/generated/intl/messages_en.dart
  5. 3
      lib/generated/intl/messages_zh_CN.dart
  6. 3
      lib/generated/intl/messages_zh_Hans_CN.dart
  7. 3
      lib/generated/intl/messages_zh_Hant_CN.dart
  8. 3
      lib/generated/intl/messages_zh_TW.dart
  9. 60
      lib/generated/l10n.dart
  10. 167
      lib/home/huixiang_brand_page.dart
  11. 8
      lib/home/points_mall_page.dart
  12. 3
      lib/l10n/intl_en.arb
  13. 3
      lib/l10n/intl_zh_CN.arb
  14. 3
      lib/l10n/intl_zh_Hans_CN.arb
  15. 3
      lib/l10n/intl_zh_Hant_CN.arb
  16. 3
      lib/l10n/intl_zh_TW.arb
  17. 222
      lib/mine/vip_detail_page.dart

BIN
assets/image/2x/icon_shop.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

BIN
assets/image/3x/icon_shop.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.1 KiB

BIN
assets/image/icon_shop.png

Binary file not shown.

After

Width:  |  Height:  |  Size: 785 B

3
lib/generated/intl/messages_en.dart

@ -351,6 +351,7 @@ class MessageLookup extends MessageLookupByLibrary {
"shixiaoquan" : MessageLookupByLibrary.simpleMessage("失效券"),
"shixiaoyouhuiquan" : MessageLookupByLibrary.simpleMessage("失效优惠券"),
"shiyongbangzhu" : MessageLookupByLibrary.simpleMessage("使用帮助"),
"shiyongmendian" : MessageLookupByLibrary.simpleMessage("适用门店"),
"shiyongriqi" : MessageLookupByLibrary.simpleMessage("使用日期"),
"shiyongshuoming" : MessageLookupByLibrary.simpleMessage("使用说明"),
"shiyongtiaojian" : MessageLookupByLibrary.simpleMessage("使用条件"),
@ -410,6 +411,7 @@ class MessageLookup extends MessageLookupByLibrary {
"xiaofeijifen" : MessageLookupByLibrary.simpleMessage("消费积分"),
"xiaoxi" : MessageLookupByLibrary.simpleMessage("消息"),
"xiayidengji" : MessageLookupByLibrary.simpleMessage("下一等级"),
"xieyitanchuang" : MessageLookupByLibrary.simpleMessage("一心回乡用户隐私政策"),
"xindianhuodong" : MessageLookupByLibrary.simpleMessage("星店活动"),
"xitongtongzhi" : MessageLookupByLibrary.simpleMessage("系统通知"),
"xitongxiaoxi" : MessageLookupByLibrary.simpleMessage("系统消息"),
@ -423,6 +425,7 @@ class MessageLookup extends MessageLookupByLibrary {
"yingyeshijian" : m26,
"yinshi" : MessageLookupByLibrary.simpleMessage("饮食"),
"yinsishengming" : MessageLookupByLibrary.simpleMessage("隐私声明"),
"yinsixieyi" : MessageLookupByLibrary.simpleMessage("《隐私协议》"),
"yiqiandao" : MessageLookupByLibrary.simpleMessage("已签到"),
"yiquxiao" : MessageLookupByLibrary.simpleMessage(" 已取消 "),
"yishijiao" : MessageLookupByLibrary.simpleMessage("已失效"),

3
lib/generated/intl/messages_zh_CN.dart

@ -350,6 +350,7 @@ class MessageLookup extends MessageLookupByLibrary {
"shixiaoquan" : MessageLookupByLibrary.simpleMessage("失效券"),
"shixiaoyouhuiquan" : MessageLookupByLibrary.simpleMessage("失效优惠券"),
"shiyongbangzhu" : MessageLookupByLibrary.simpleMessage("使用帮助"),
"shiyongmendian" : MessageLookupByLibrary.simpleMessage("适用门店"),
"shiyongriqi" : MessageLookupByLibrary.simpleMessage("使用日期"),
"shiyongshuoming" : MessageLookupByLibrary.simpleMessage("使用说明"),
"shiyongtiaojian" : MessageLookupByLibrary.simpleMessage("使用条件"),
@ -409,6 +410,7 @@ class MessageLookup extends MessageLookupByLibrary {
"xiaofeijifen" : MessageLookupByLibrary.simpleMessage("消费积分"),
"xiaoxi" : MessageLookupByLibrary.simpleMessage("消息"),
"xiayidengji" : MessageLookupByLibrary.simpleMessage("下一等级"),
"xieyitanchuang" : MessageLookupByLibrary.simpleMessage("一心回乡用户隐私政策"),
"xindianhuodong" : MessageLookupByLibrary.simpleMessage("星店活动"),
"xitongtongzhi" : MessageLookupByLibrary.simpleMessage("系统通知"),
"xitongxiaoxi" : MessageLookupByLibrary.simpleMessage("系统消息"),
@ -422,6 +424,7 @@ class MessageLookup extends MessageLookupByLibrary {
"yingyeshijian" : m26,
"yinshi" : MessageLookupByLibrary.simpleMessage("饮食"),
"yinsishengming" : MessageLookupByLibrary.simpleMessage("隐私声明"),
"yinsixieyi" : MessageLookupByLibrary.simpleMessage("《隐私协议》"),
"yiqiandao" : MessageLookupByLibrary.simpleMessage("已签到"),
"yiquxiao" : MessageLookupByLibrary.simpleMessage(" 已取消 "),
"yishijiao" : MessageLookupByLibrary.simpleMessage("已失效"),

3
lib/generated/intl/messages_zh_Hans_CN.dart

@ -350,6 +350,7 @@ class MessageLookup extends MessageLookupByLibrary {
"shixiaoquan" : MessageLookupByLibrary.simpleMessage("失效券"),
"shixiaoyouhuiquan" : MessageLookupByLibrary.simpleMessage("失效优惠券"),
"shiyongbangzhu" : MessageLookupByLibrary.simpleMessage("使用帮助"),
"shiyongmendian" : MessageLookupByLibrary.simpleMessage("适用门店"),
"shiyongriqi" : MessageLookupByLibrary.simpleMessage("使用日期"),
"shiyongshuoming" : MessageLookupByLibrary.simpleMessage("使用说明"),
"shiyongtiaojian" : MessageLookupByLibrary.simpleMessage("使用条件"),
@ -409,6 +410,7 @@ class MessageLookup extends MessageLookupByLibrary {
"xiaofeijifen" : MessageLookupByLibrary.simpleMessage("消费积分"),
"xiaoxi" : MessageLookupByLibrary.simpleMessage("消息"),
"xiayidengji" : MessageLookupByLibrary.simpleMessage("下一等级"),
"xieyitanchuang" : MessageLookupByLibrary.simpleMessage("一心回乡用户隐私政策"),
"xindianhuodong" : MessageLookupByLibrary.simpleMessage("星店活动"),
"xitongtongzhi" : MessageLookupByLibrary.simpleMessage("系统通知"),
"xitongxiaoxi" : MessageLookupByLibrary.simpleMessage("系统消息"),
@ -422,6 +424,7 @@ class MessageLookup extends MessageLookupByLibrary {
"yingyeshijian" : m26,
"yinshi" : MessageLookupByLibrary.simpleMessage("饮食"),
"yinsishengming" : MessageLookupByLibrary.simpleMessage("隐私声明"),
"yinsixieyi" : MessageLookupByLibrary.simpleMessage("《隐私协议》"),
"yiqiandao" : MessageLookupByLibrary.simpleMessage("已签到"),
"yiquxiao" : MessageLookupByLibrary.simpleMessage(" 已取消 "),
"yishijiao" : MessageLookupByLibrary.simpleMessage("已失效"),

3
lib/generated/intl/messages_zh_Hant_CN.dart

@ -350,6 +350,7 @@ class MessageLookup extends MessageLookupByLibrary {
"shixiaoquan" : MessageLookupByLibrary.simpleMessage("失效券"),
"shixiaoyouhuiquan" : MessageLookupByLibrary.simpleMessage("失效优惠券"),
"shiyongbangzhu" : MessageLookupByLibrary.simpleMessage("使用幫助"),
"shiyongmendian" : MessageLookupByLibrary.simpleMessage("適用門店"),
"shiyongriqi" : MessageLookupByLibrary.simpleMessage("使用日期"),
"shiyongshuoming" : MessageLookupByLibrary.simpleMessage("使用说明"),
"shiyongtiaojian" : MessageLookupByLibrary.simpleMessage("使用条件"),
@ -409,6 +410,7 @@ class MessageLookup extends MessageLookupByLibrary {
"xiaofeijifen" : MessageLookupByLibrary.simpleMessage("消费积分"),
"xiaoxi" : MessageLookupByLibrary.simpleMessage("消息"),
"xiayidengji" : MessageLookupByLibrary.simpleMessage("下一等級"),
"xieyitanchuang" : MessageLookupByLibrary.simpleMessage("一心回鄉用戶隱私協議"),
"xindianhuodong" : MessageLookupByLibrary.simpleMessage("星店活動"),
"xitongtongzhi" : MessageLookupByLibrary.simpleMessage("系統通知"),
"xitongxiaoxi" : MessageLookupByLibrary.simpleMessage("系統消息"),
@ -422,6 +424,7 @@ class MessageLookup extends MessageLookupByLibrary {
"yingyeshijian" : m26,
"yinshi" : MessageLookupByLibrary.simpleMessage("飲食"),
"yinsishengming" : MessageLookupByLibrary.simpleMessage("隱私聲明"),
"yinsixieyi" : MessageLookupByLibrary.simpleMessage("《隱私協議》"),
"yiqiandao" : MessageLookupByLibrary.simpleMessage("已簽到"),
"yiquxiao" : MessageLookupByLibrary.simpleMessage(" 已取消 "),
"yishijiao" : MessageLookupByLibrary.simpleMessage("已失效"),

3
lib/generated/intl/messages_zh_TW.dart

@ -350,6 +350,7 @@ class MessageLookup extends MessageLookupByLibrary {
"shixiaoquan" : MessageLookupByLibrary.simpleMessage("失效券"),
"shixiaoyouhuiquan" : MessageLookupByLibrary.simpleMessage("失效优惠券"),
"shiyongbangzhu" : MessageLookupByLibrary.simpleMessage("使用幫助"),
"shiyongmendian" : MessageLookupByLibrary.simpleMessage("適用門店"),
"shiyongriqi" : MessageLookupByLibrary.simpleMessage("使用日期"),
"shiyongshuoming" : MessageLookupByLibrary.simpleMessage("使用说明"),
"shiyongtiaojian" : MessageLookupByLibrary.simpleMessage("使用条件"),
@ -409,6 +410,7 @@ class MessageLookup extends MessageLookupByLibrary {
"xiaofeijifen" : MessageLookupByLibrary.simpleMessage("消费积分"),
"xiaoxi" : MessageLookupByLibrary.simpleMessage("消息"),
"xiayidengji" : MessageLookupByLibrary.simpleMessage("下一等級"),
"xieyitanchuang" : MessageLookupByLibrary.simpleMessage("一心回鄉用戶隱私協議"),
"xindianhuodong" : MessageLookupByLibrary.simpleMessage("星店活動"),
"xitongtongzhi" : MessageLookupByLibrary.simpleMessage("系統通知"),
"xitongxiaoxi" : MessageLookupByLibrary.simpleMessage("系統消息"),
@ -422,6 +424,7 @@ class MessageLookup extends MessageLookupByLibrary {
"yingyeshijian" : m26,
"yinshi" : MessageLookupByLibrary.simpleMessage("飲食"),
"yinsishengming" : MessageLookupByLibrary.simpleMessage("隱私聲明"),
"yinsixieyi" : MessageLookupByLibrary.simpleMessage("《隱私協議》"),
"yiqiandao" : MessageLookupByLibrary.simpleMessage("已簽到"),
"yiquxiao" : MessageLookupByLibrary.simpleMessage(" 已取消 "),
"yishijiao" : MessageLookupByLibrary.simpleMessage("已失效"),

60
lib/generated/l10n.dart

@ -3955,6 +3955,66 @@ class S {
);
}
/// ``
String get xieyitanchuang {
return Intl.message(
'一心回乡用户隐私政策',
name: 'xieyitanchuang',
desc: '',
args: [],
);
}
/// ``
String get yinsixieyi {
return Intl.message(
'《隐私协议》',
name: 'yinsixieyi',
desc: '',
args: [],
);
}
/// ``
String get shiyongmendian {
return Intl.message(
'适用门店',
name: 'shiyongmendian',
desc: '',
args: [],
);
}
/// ``
String get xieyitanchuang {
return Intl.message(
'一心回乡用户隐私政策',
name: 'xieyitanchuang',
desc: '',
args: [],
);
}
/// ``
String get yinsixieyi {
return Intl.message(
'《隐私协议》',
name: 'yinsixieyi',
desc: '',
args: [],
);
}
/// ``
String get shiyongmendian {
return Intl.message(
'适用门店',
name: 'shiyongmendian',
desc: '',
args: [],
);
}
/// `使`
String get privacy_policy4 {
return Intl.message(

167
lib/home/huixiang_brand_page.dart

@ -1,5 +1,6 @@
import 'package:dio/dio.dart';
import 'package:flutter/cupertino.dart';
import 'package:flutter/gestures.dart';
import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
import 'package:flutter_html/flutter_html.dart';
@ -13,9 +14,11 @@ import 'package:huixiang/retrofit/data/brand_data.dart';
import 'package:huixiang/retrofit/retrofit_api.dart';
import 'package:huixiang/utils/MyPainter.dart';
import 'package:huixiang/utils/event_type.dart';
import 'package:huixiang/view_widget/border_text.dart';
import 'package:huixiang/view_widget/classic_header.dart';
import 'package:huixiang/view_widget/custom_image.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:huixiang/view_widget/round_button.dart';
import 'package:huixiang/view_widget/store_title_tab.dart';
import 'package:pull_to_refresh/pull_to_refresh.dart';
import 'package:shared_preferences/shared_preferences.dart';
@ -73,7 +76,9 @@ class _BrandPage extends State<BrandPage>
apiService = ApiService(Dio(),
context: context, token: value.getString('token')),
queryHome(),
});
if(value.getBool("isFristLogin")){
showAlertDialog(),
}});
eventBus.on<EventType>().listen((event) {
print("object: BrandPage");
@ -90,7 +95,10 @@ class _BrandPage extends State<BrandPage>
super.build(context);
return Scaffold(
appBar: AppBar(
toolbarHeight: 40.h - MediaQuery.of(context).padding.top,
toolbarHeight: 40.h - MediaQuery
.of(context)
.padding
.top,
backgroundColor: Colors.white,
elevation: 0,
),
@ -235,7 +243,9 @@ class _BrandPage extends State<BrandPage>
),
),
TextSpan(
text: " ${S.of(context).jituanchuangbanren}",
text: " ${S
.of(context)
.jituanchuangbanren}",
style: TextStyle(
fontSize: 10.sp,
color: Colors.black,
@ -268,7 +278,9 @@ class _BrandPage extends State<BrandPage>
mainAxisSize: MainAxisSize.max,
children: [
Text(
S.of(context).gengduo,
S
.of(context)
.gengduo,
style: TextStyle(
fontSize: 12.sp,
color: Colors.black,
@ -328,7 +340,9 @@ class _BrandPage extends State<BrandPage>
height: 40.h,
),
Text(
S.of(context).linian,
S
.of(context)
.linian,
style: TextStyle(
fontSize: 16.sp,
fontWeight: FontWeight.bold,
@ -474,6 +488,149 @@ class _BrandPage extends State<BrandPage>
);
}
showAlertDialog() {
//
showDialog(
context: context,
builder: (BuildContext context) {
return SimpleDialog(
titlePadding: EdgeInsets.all(10),
backgroundColor: Colors.transparent,
elevation: 0,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.all(Radius.circular(6))),
children: <Widget>[
Stack(
alignment: Alignment.bottomCenter,
children: [
Container(
alignment: Alignment.center,
width: double.infinity,
height: 305.h,
// margin: EdgeInsets.only(left: 40.w, right: 40.w),
padding: EdgeInsets.only(left: 16.w, right: 16.w),
decoration: new BoxDecoration(
color: Colors.white,
borderRadius: BorderRadius.all(Radius.circular(8))),
child: Column(
children: [
Padding(
padding: EdgeInsets.only(top: 24.h, bottom: 10.h),
child: Text(
S
.of(context)
.xieyitanchuang,
style: TextStyle(
color: Color(0xff4D4D4D),
fontSize: 18.sp,
fontWeight: FontWeight.bold),
),
),
Text.rich(
TextSpan(children: [
TextSpan(
text:
"     感谢您使用一心回乡APP。我们非常重视您的个人信息和隐私保护。为了更好地保证您的个人权益,在您使用我们的产品前,请务必仔细阅读一心回乡",
style: TextStyle(
fontWeight: FontWeight.w500,
fontSize: 14.sp,
height: 1.3.h,
color: Color(0xff727272)),
),
TextSpan(
text: S
.of(context)
.yinsixieyi,
style: TextStyle(
fontWeight: FontWeight.w500,
fontSize: 14.sp,
color: Color(0xff32A060)),
recognizer: TapGestureRecognizer()
..onTap = () {
debugPrint(
"${Navigator.of(context).popAndPushNamed(
'/router/treaty_page')}");
},
),
]),
),
SizedBox(
height: 10.h,
),
Text(
"     在您同意后,我们才会根据您的使用需求,收集部分可能涉及的数据(地理位置、相机、存储等信息)。",
style: TextStyle(
color: Color(0xff727272),
fontSize: 14.sp,
height: 1.3.h,
fontWeight: FontWeight.w500,
),
),
SizedBox(
height: 16.h,
),
],
),
),
Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
GestureDetector(
onTap: () {
Navigator.of(context).pop();
},
child: Container(
height: 40.h,
alignment: Alignment.bottomCenter,
margin: EdgeInsets.only(bottom: 20.h),
child: BorderText(
padding: EdgeInsets.only(
top: 10.h, bottom: 10.h, left: 36.w, right: 36.w),
text: "拒绝",
fontSize: 12.sp,
textColor: Color(0xFF32A060),
borderColor: Color(0xFF32A060),
borderWidth: 1.w,
radius: 23,
),
),
),
SizedBox(
width: 21.w,
),
Container(
height: 40.h,
margin: EdgeInsets.only(bottom: 20.h),
alignment: Alignment.bottomCenter,
child: RoundButton(
text: "同意并继续",
textColor: Colors.white,
fontSize: 12,
callback: () {
Navigator.of(context).pop();
},
padding: EdgeInsets.only(
top: 10.h,
bottom: 10.h,
left: 21.5.w,
right: 21.5.w),
backgroup: Color(0xff32A060),
radius: 23,
),
),
SizedBox(
height: 20.h,
),
],
),
],
)
],
);
},
);
}
/// contentType 0123
bannerClick(BannerData bannerData) async {
switch (bannerData.contentType) {

8
lib/home/points_mall_page.dart

@ -501,6 +501,9 @@ class _PointsMallPage extends State<PointsMallPage>
fontWeight: FontWeight.bold,
color: Color(0xFF353535)),
),
SizedBox(
height: 8.h,
),
Row(
children: [
Image.asset(
@ -540,6 +543,9 @@ class _PointsMallPage extends State<PointsMallPage>
color: Color(0xFF4C4C4C),
),
),
SizedBox(
height: 4.h,
),
Text(
(userinfo != null) ? "${userinfo.points}" : "",
style: TextStyle(
@ -559,7 +565,7 @@ class _PointsMallPage extends State<PointsMallPage>
banner() {
return Container(
margin: EdgeInsets.only(top: 16, bottom: 16),
margin: EdgeInsets.only(top: 16),
child: AspectRatio(
aspectRatio: 2.0,
child: Swiper(

3
lib/l10n/intl_en.arb

@ -410,6 +410,9 @@
"nihaimeiyouchongzhihuoxiaofeijilu": "你在这儿还没有消费或充值记录哦~",
"haimeiyouxiaoxi": "还没有消息~",
"chakanxiangqing": "查看详情",
"xieyitanchuang": "一心回乡用户隐私政策",
"yinsixieyi": "《隐私协议》",
"shiyongmendian": "适用门店",

3
lib/l10n/intl_zh_CN.arb

@ -411,6 +411,9 @@
"nihaimeiyouchongzhihuoxiaofeijilu": "你在这儿还没有消费或充值记录哦~",
"haimeiyouxiaoxi": "还没有消息~",
"chakanxiangqing": "查看详情",
"xieyitanchuang": "一心回乡用户隐私政策",
"yinsixieyi": "《隐私协议》",
"shiyongmendian": "适用门店",

3
lib/l10n/intl_zh_Hans_CN.arb

@ -411,6 +411,9 @@
"nihaimeiyouchongzhihuoxiaofeijilu": "你在这儿还没有消费或充值记录哦~",
"haimeiyouxiaoxi": "还没有消息~",
"chakanxiangqing": "查看详情",
"xieyitanchuang": "一心回乡用户隐私政策",
"yinsixieyi": "《隐私协议》",
"shiyongmendian": "适用门店",

3
lib/l10n/intl_zh_Hant_CN.arb

@ -405,6 +405,9 @@
"nihaimeiyouchongzhihuoxiaofeijilu": "你在這兒還沒有消費或充值紀錄喔~",
"haimeiyouxiaoxi": "還沒有消息~",
"chakanxiangqing": "查看詳情",
"xieyitanchuang": "一心回鄉用戶隱私協議",
"yinsixieyi": "《隱私協議》",
"shiyongmendian": "適用門店",

3
lib/l10n/intl_zh_TW.arb

@ -403,6 +403,9 @@
"nihaimeiyouchongzhihuoxiaofeijilu": "你在這兒還沒有消費或充值紀錄喔~",
"haimeiyouxiaoxi": "還沒有消息~",
"chakanxiangqing": "查看詳情",
"xieyitanchuang": "一心回鄉用戶隱私協議",
"yinsixieyi": "《隱私協議》",
"shiyongmendian": "適用門店",

222
lib/mine/vip_detail_page.dart

@ -5,6 +5,7 @@ import 'package:huixiang/generated/l10n.dart';
import 'package:huixiang/retrofit/data/base_data.dart';
import 'package:huixiang/retrofit/data/order_info.dart';
import 'package:huixiang/retrofit/data/page.dart';
import 'package:huixiang/retrofit/data/store.dart';
import 'package:huixiang/retrofit/data/vip_card.dart';
import 'package:huixiang/retrofit/retrofit_api.dart';
import 'package:huixiang/utils/painter_bg.dart';
@ -130,7 +131,7 @@ class _VipDetailPage extends State<VipDetailPage> {
child: Row(
children: [
Text(
"历史订单",
S.of(context).shiyongmendian,
overflow: TextOverflow.ellipsis,
style: TextStyle(
fontSize: 16.sp,
@ -142,7 +143,7 @@ class _VipDetailPage extends State<VipDetailPage> {
width: 8.w,
),
Image.asset(
"assets/image/icon_history.png",
"assets/image/icon_shop.png",
),
],
),
@ -162,10 +163,10 @@ class _VipDetailPage extends State<VipDetailPage> {
itemBuilder: (context, position) {
return GestureDetector(
onTap: () {},
child: historyItem(orderInfos[position]),
child: shopItem(),
);
},
itemCount: orderInfos != null ? orderInfos.length : 0,
// itemCount: orderInfos != null ? orderInfos.length : 0,
),
),
),
@ -295,8 +296,9 @@ class _VipDetailPage extends State<VipDetailPage> {
),
GestureDetector(
onTap: () {
Navigator.of(context)
.pushNamed('/router/vip_balance', arguments: {"storeId":vipCard.id});
Navigator.of(context).pushNamed(
'/router/vip_balance',
arguments: {"storeId": vipCard.id});
},
child: Row(
children: [
@ -405,7 +407,7 @@ class _VipDetailPage extends State<VipDetailPage> {
);
}
Widget historyItem(OrderInfo orderInfo) {
Widget shopItem() {
return Container(
margin: EdgeInsets.all(16.w),
child: Column(
@ -413,213 +415,95 @@ class _VipDetailPage extends State<VipDetailPage> {
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.start,
mainAxisAlignment: MainAxisAlignment.start,
children: [
Container(
width: 19.w,
height: 19.h,
margin: EdgeInsets.only(left: 12.w, top: 12.h),
alignment: Alignment.center,
decoration: new BoxDecoration(
color: Color(0xff32A060),
borderRadius: BorderRadius.circular(2),
),
child: Text(
(orderInfo != null && orderInfo.isTakeOut == 0) ? "" : "",
style: TextStyle(
fontSize: 12.sp,
fontWeight: FontWeight.bold,
color: Colors.white,
),
),
),
Expanded(
child: Container(
width: double.infinity,
margin: EdgeInsets.only(left: 6.w, top: 12.h),
alignment: Alignment.centerLeft,
child: Text(
(orderInfo != null) ? orderInfo.storeName : "",
style: TextStyle(
fontWeight: FontWeight.bold,
fontSize: 14.sp,
color: Color(0xFF353535),
),
),
),
flex: 1,
),
Padding(
padding: EdgeInsets.only(top: 12.h, right: 12.w),
child: Text(
(orderInfo != null &&
orderInfo.storeVO != null &&
orderInfo.storeVO.posType != null)
? StatusUtils.statusText(
context,
orderInfo.refundStatus,
orderInfo.orderStatus,
orderInfo.payStatus,
orderInfo.sendStatus,
orderInfo.isTakeOut)
: "",
"百年川椒重庆老火锅(汉街店)",
style: TextStyle(
fontSize: 14.sp,
fontWeight: FontWeight.bold,
color: (orderInfo == null)
? Color(0xFF32A060)
: (orderInfo.refundStatus == 1 ||
orderInfo.orderStatus >= 5)
? Colors.grey
: (orderInfo.orderStatus == 4)
? Color(0xFF32A060)
: Color(0xffFE951E),
),
),
),
],
color: Colors.black,
),
Container(
margin: EdgeInsets.only(left: 37.w),
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
Column(
mainAxisAlignment: MainAxisAlignment.spaceAround,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
S.of(context).xiadanshijian_(
(orderInfo != null) ? orderInfo.createTime : ""),
)),
GestureDetector(
onTap: (){
Navigator.of(context).pushNamed('/router/union_detail_page');
},
child:Text(
"查看",
style: TextStyle(
fontSize: 10.sp,
color: Color(0xFF727272),
),
),
SizedBox(
height: 8.h,
fontSize: 12.sp,
fontWeight: FontWeight.w500,
color: Color(0xff32A060),
),
Row(
mainAxisAlignment: MainAxisAlignment.spaceAround,
crossAxisAlignment: CrossAxisAlignment.start,
children: goodsItem(
(orderInfo != null && orderInfo.productList != null)
? orderInfo.productList
: null),
),
],
),
Padding(
padding: EdgeInsets.only(right: 22.w),
child: Image.asset(
"assets/image/icon_more.png",
fit: BoxFit.fill,
alignment: Alignment.centerRight,
width: 24.w,
height: 24.h,
Icon(
Icons.chevron_right,
color: Color(0xff32A060),
size: 16,
),
)
],
),
),
SizedBox(
height: 12.h,
height: 8.h,
),
Container(
margin: EdgeInsets.only(right: 12.w, bottom: 12.h),
child: Directionality(
textDirection: TextDirection.rtl,
child: Column(
children: [
Row(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text.rich(
TextSpan(
children: [
TextSpan(
text: S.of(context).gong,
style: TextStyle(
fontSize: 12.sp,
color: Color(0xFF868686),
),
),
TextSpan(
text: (orderInfo != null &&
orderInfo.productList != null)
? "${orderInfo.productList.length}"
: "0",
Text(
"地址:",
style: TextStyle(
fontSize: 12.sp,
fontWeight: FontWeight.bold,
color: Colors.black,
fontWeight: FontWeight.w400,
color: Color(0xff353535),
),
),
TextSpan(
text: S.of(context).jian,
Text(
"楚河汉街第一街区万达总部国际C座对面",
style: TextStyle(
fontSize: 12.sp,
color: Color(0xFF868686),
fontWeight: FontWeight.w400,
color: Color(0xff353535),
),
),
],
),
),
SizedBox(
width: 4.w,
height: 4.h,
),
Text.rich(
TextSpan(
Row(
mainAxisAlignment: MainAxisAlignment.start,
children: [
TextSpan(
text: S.of(context).heji,
Text(
"营业时间:",
style: TextStyle(
fontSize: 12.sp,
color: Color(0xFF868686),
fontWeight: FontWeight.w400,
color: Color(0xff353535),
),
),
TextSpan(
text: totalPrice(orderInfo),
Expanded(
flex: 1,
child: Text(
"10:00-22:00",
style: TextStyle(
fontSize: 12.sp,
fontWeight: FontWeight.bold,
color: Colors.black,
),
fontWeight: FontWeight.w400,
color: Color(0xff353535),
),
TextSpan(
text: S.of(context).yuan,
)),
Text(
"3.9km",
style: TextStyle(
fontSize: 12.sp,
color: Color(0xFF868686),
),
),
],
fontWeight: FontWeight.w400,
color: Color(0xff868686),
),
),
],
),
SizedBox(
height: 8.h,
),
Row(
children: (orderInfo != null)
? StatusUtils.statusBtn(
context,
orderInfo.payStatus,
orderInfo.orderStatus,
orderInfo.isTakeOut,
orderInfo.sendStatus,
orderInfo.refundStatus,
orderInfo.dayFlowCode)
: [],
),
],
),
),
),
],
),
);

Loading…
Cancel
Save