Browse Source

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

 Conflicts:
	lib/generated/intl/messages_en.dart
	lib/generated/intl/messages_zh_CN.dart
	lib/generated/intl/messages_zh_TW.dart
	lib/main.dart
	lib/mine/coupons_page.dart
	lib/retrofit/data/member_rank.dart
	lib/retrofit/data/page.dart
	lib/retrofit/data/sign_in.dart
	lib/retrofit/data/sign_info.dart
	lib/retrofit/data/store.dart
	lib/retrofit/data/store_info.dart
	lib/retrofit/data/store_type.dart
	lib/retrofit/data/upload_result.dart
	lib/retrofit/data/user_entity.dart
	lib/retrofit/data/user_info.dart
	lib/view_widget/new_coupon_widget.dart
	pubspec.lock
null_safety
fmk 4 years ago
parent
commit
d31124346d
  1. 188
      lib/generated/l10n.dart
  2. 501
      lib/home/founder_story_page.dart
  3. 7
      lib/home/home_page.dart
  4. 2
      lib/home/huixiang_brand_page.dart
  5. 16
      lib/l10n/intl_en.arb
  6. 10
      lib/l10n/intl_zh_CN.arb
  7. 3
      lib/l10n/intl_zh_TW.arb
  8. 11
      lib/login/login_page.dart
  9. 70
      lib/main.dart
  10. 1
      lib/mine/mine_vip_level_page.dart
  11. 2
      lib/retrofit/data/coupon.dart
  12. 2
      pubspec.yaml

188
lib/generated/l10n.dart

@ -585,13 +585,13 @@ class S {
);
}
/// `使{date}`
String shiyongriqi(Object date) {
/// `使`
String get shiyongriqi {
return Intl.message(
'使用日期$date',
'使用日期',
name: 'shiyongriqi',
desc: '',
args: [date],
args: [],
);
}
@ -1975,21 +1975,21 @@ class S {
);
}
/// ``
String get yishiming {
/// ``
String get shixiaoquan {
return Intl.message(
'已实名',
name: 'yishiming',
'失效券',
name: 'shixiaoquan',
desc: '',
args: [],
);
}
/// ``
String get shixiaoquan {
/// ``
String get wenzhangxiangqing {
return Intl.message(
'失效券',
name: 'shixiaoquan',
'文章详情',
name: 'wenzhangxiangqing',
desc: '',
args: [],
);
@ -2005,11 +2005,11 @@ class S {
);
}
/// ``
String get wenzhangxiangqing {
/// ``
String get yishiming {
return Intl.message(
'文章详情',
name: 'wenzhangxiangqing',
'已实名',
name: 'yishiming',
desc: '',
args: [],
);
@ -2345,21 +2345,21 @@ class S {
);
}
/// ``
String get xuni {
/// ``
String get keyongquan {
return Intl.message(
'虚拟',
name: 'xuni',
'可用券',
name: 'keyongquan',
desc: '',
args: [],
);
}
/// ``
String get keyongquan {
/// ``
String get xuni {
return Intl.message(
'可用券',
name: 'keyongquan',
'虚拟',
name: 'xuni',
desc: '',
args: [],
);
@ -2575,6 +2575,76 @@ class S {
);
}
/// ``
String get meiyougengduohuiyuanka {
return Intl.message(
'没有更多会员卡',
name: 'meiyougengduohuiyuanka',
desc: '',
args: [],
);
}
/// ``
String get huiyuankaxiangqing {
return Intl.message(
'会员卡详情',
name: 'huiyuankaxiangqing',
desc: '',
args: [],
);
}
/// ``
String get yuemingxi {
return Intl.message(
'余额明细',
name: 'yuemingxi',
desc: '',
args: [],
);
}
/// ``
String get kelingqudeyouhuiquan {
return Intl.message(
'可领取的优惠券',
name: 'kelingqudeyouhuiquan',
desc: '',
args: [],
);
}
/// ``
String get shangjiaquan {
return Intl.message(
'商家券',
name: 'shangjiaquan',
desc: '',
args: [],
);
}
/// `{yuan}`
String manyuankeyong(Object yuan) {
return Intl.message(
'$yuan可用',
name: 'manyuankeyong',
desc: '',
args: [yuan],
);
}
/// ``
String get chakanwodekaquan {
return Intl.message(
'查看我的卡券',
name: 'chakanwodekaquan',
desc: '',
args: [],
);
}
/// ``
String get guanyu {
return Intl.message(
@ -2635,26 +2705,6 @@ class S {
);
}
/// ``
String get shangjiaquan {
return Intl.message(
'商家券',
name: 'shangjiaquan',
desc: '',
args: [],
);
}
/// `{yuan}`
String manyuankeyong(Object yuan) {
return Intl.message(
'$yuan可用',
name: 'manyuankeyong',
desc: '',
args: [yuan],
);
}
/// ``
String get tijiao {
return Intl.message(
@ -2725,56 +2775,6 @@ class S {
);
}
/// ``
String get huiyuankaxiangqing {
return Intl.message(
'会员卡详情',
name: 'huiyuankaxiangqing',
desc: '',
args: [],
);
}
/// ``
String get meiyougengduohuiyuanka {
return Intl.message(
'没有更多会员卡',
name: 'meiyougengduohuiyuanka',
desc: '',
args: [],
);
}
/// ``
String get yuemingxi {
return Intl.message(
'余额明细',
name: 'yuemingxi',
desc: '',
args: [],
);
}
/// ``
String get chakanwodekaquan {
return Intl.message(
'查看我的卡券',
name: 'chakanwodekaquan',
desc: '',
args: [],
);
}
/// ``
String get kelingqudeyouhuiquan {
return Intl.message(
'可领取的优惠券',
name: 'kelingqudeyouhuiquan',
desc: '',
args: [],
);
}
/// ``
String get xiayidengji {
return Intl.message(

501
lib/home/founder_story_page.dart

@ -0,0 +1,501 @@
import 'package:flutter/cupertino.dart';
import 'package:flutter/material.dart';
import 'package:huixiang/generated/l10n.dart';
import 'package:huixiang/utils/MyPainter.dart';
import 'package:huixiang/view_widget/separator.dart';
class FounderStoryPage extends StatefulWidget {
@override
State<StatefulWidget> createState() {
return _FounderStoryPage();
}
}
class _FounderStoryPage extends State<FounderStoryPage> {
var controller = new ScrollController();
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
backgroundColor: Color(0xFFFFFFFF),
elevation: 0,
centerTitle: false,
leading: GestureDetector(
onTap: () {
Navigator.of(context).pop();
},
child: Container(
alignment: Alignment.centerRight,
margin: EdgeInsets.only(left: 10),
padding: EdgeInsets.all(6),
child: Icon(
Icons.arrow_back_ios,
color: Colors.black,
size: 24,
),
),
),
titleSpacing: 2,
leadingWidth: 56,
automaticallyImplyLeading: true,
),
body: Container(
child: SingleChildScrollView(
physics: BouncingScrollPhysics(),
child: Column(
children: [
Container(
margin: EdgeInsets.only(bottom: 20),
padding: EdgeInsets.only(left: 32,right: 32,top: 24),
decoration: BoxDecoration(
color: Colors.white,
boxShadow: [
BoxShadow(
color: Colors.black.withAlpha(12),
offset: Offset(0, 2),
blurRadius: 14,
spreadRadius: 0)
],
),
child: Column(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Image.asset("assets/image/icon_story_bj.png",alignment: Alignment.center,),
SizedBox(
height: 16,
),
Text("关于创始人",
style: TextStyle(
fontSize: 24,
color: Color(0xff565656))),
SizedBox(
height: 18,
),
Container(
width: double.infinity,
child:Stack(
children: [
RichText(
textAlign: TextAlign.start,
text: TextSpan(
text: "1993年,台胞李旭清在台湾创建“一心回乡”团队,吸引包括蔡三益在内的30余位伙伴加入。"
"他们致力于实践自然生态农耕,创造与环境共存共荣的绿色发展模式。经过多年探索,形成三产融合的完整产业链和成熟运营模式。",
style: TextStyle(color:Color(0xFF1A1A1A), fontSize: 12,height: 1.5),
)),
Padding(padding: EdgeInsets.only(top: 50),child: Align(
alignment: Alignment.bottomRight,
child:Image.asset("assets/image/icon_story_1.png",width: 222,height: 52,),
),),
],
),
),
SizedBox(
height: 16,
),
RichText(
text: TextSpan(
text: "2018年在台湾生活了五十七年的李旭清女士决定回到父亲的家乡湖北寻根。在这里为了延续台湾回乡的经验,李姐在湖北武汉创立了,与此同行的还有李姐的两个女儿。"
"为了推广更多的好食物,让更多的人参与到环境保护中,一心回乡遇到了知音,在大力支持下,“海峡姐妹餐饮诞生了!",
style: TextStyle(color:Color(0xFF1A1A1A), fontSize: 12,height: 1.5),
)),
Image.asset("assets/image/icon_story_2.png",alignment: Alignment.centerRight,),
SizedBox(
height: 16,
),
Image.asset("assets/image/laoban.png",
fit: BoxFit.cover,
width: double.infinity,
height: 228,),
SizedBox(
height: 50,
),
Image.asset("assets/image/icon_story_bj.png",alignment: Alignment.center,),
SizedBox(
height: 16,
),
Text("回乡之路",
style: TextStyle(
fontSize: 24,
color: Color(0xff565656))),
SizedBox(
height: 20,
),
_textWidget("1994年,为推广生机饮食,在台中逢甲大学开台湾第一家「青青小镇」自然蔬食餐厅。"),
_textWidget("1997年,为了实践减碳生活,邀约一群大学应届毕业生共同生活彼此学习,落实自然饮食新生活,开始推动有机小铺与小区讲座的教育推广模式。"),
_textWidget("2000年 为推广自然饮食概念,及照顾有机农民,开始做保价保证,成立「甘露自然蔬食餐厅」。"),
_textWidget("2005年,不忍农村凋零、土地被农药化肥毒化,带领年轻伙伴回乡购地,成立「回乡有机生活农场」,实践自然生态农耕,以复育生态、改良土壤为目的,创造一个与万物和谐共生的农耕模式。"),
Padding(padding: EdgeInsets.only(bottom: 20,left: 18),child:Text("",
style: TextStyle(
fontSize: 16,
color: Color(0xff565656))),),
_textWidget("2019年,在武汉成立湖北海峡姐妹餐饮有限公司。"
"成为百年川椒火锅(光谷店)运营方,通过“素食煮义”和“蔬食之力”推广有机永续美好生活,"
"打造“新国民火锅”。在“未来之光”和“创意天地”开设的「海峡姐妹」茶吧,坚持纯天然的食材,"
"推动茶饮与健康养生同时兼具的新茶饮文化。"),
_textWidget("2019年,在武汉江夏成立旭清回乡生态农业发展有限公司,"
"在山坡街拥有1200亩农业生产基地,"
"将台湾实践多年并有成功经验的生态农法, 天然食品加工技术, 农业旅游输出落地。"),
Image.asset("assets/image/icon_story_bj.png",alignment: Alignment.center,),
SizedBox(
height: 16,
),
Text("早期团队",
style: TextStyle(
fontSize: 24,
color: Color(0xff565656))),
SizedBox(
height: 26,
),
Image.asset("assets/image/icon_story_td.png",
fit: BoxFit.cover,
width: double.infinity,
height: 228,),
SizedBox(
height: 24,
),
Padding(
padding: EdgeInsets.only(top: 10,),
child: MySeparator(
width: 5,
height: 2,
color: Color(0xFF32A060),
),
),
SizedBox(
height: 17,
),
Container(
margin: EdgeInsets.only(bottom: 20),
padding: EdgeInsets.all(12),
decoration: BoxDecoration(
color: Color(0xff32A060),
boxShadow: [
BoxShadow(
color: Colors.black.withAlpha(12),
offset: Offset(0, 2),
blurRadius: 14,
spreadRadius: 0)
],
),
child:RichText(
text: TextSpan(
text: "回乡有机团队(早期照片),当年,他们也都是企业高管、IT精英、大学毕业生。日出而作,日落而息,结婚生子,"
"子女们一起玩耍,上学读书。转眼间,孩子们都已长大,有些大学毕业后也加入了“回乡”。",
style: TextStyle(color:Colors.white, fontSize: 12,height: 1.5),
)),
),
Padding(
padding: EdgeInsets.only(top: 10,),
child: MySeparator(
width: 5,
height: 2,
color: Color(0xFF32A060),
),
),
SizedBox(
height: 27,
),
Text("传递理念",
style: TextStyle(
fontSize: 24,
color: Color(0xff565656))),
SizedBox(
height: 20,
),
Row(
children: [
_ideaWidget("友爱", "https://tva1.sinaimg.cn/large/006y8mN6gy1g7aa03bmfpj3069069mx8.jpg"),
_ideaWidget("友爱", "https://tva1.sinaimg.cn/large/006y8mN6gy1g7aa03bmfpj3069069mx8.jpg"),
_ideaWidget("友爱", "https://tva1.sinaimg.cn/large/006y8mN6gy1g7aa03bmfpj3069069mx8.jpg"),
],
),
SizedBox(
height: 20,
),
Row(
children: [
_ideaWidget("友爱", "https://tva1.sinaimg.cn/large/006y8mN6gy1g7aa03bmfpj3069069mx8.jpg"),
_ideaWidget("友爱", "https://tva1.sinaimg.cn/large/006y8mN6gy1g7aa03bmfpj3069069mx8.jpg"),
_ideaWidget("友爱", "https://tva1.sinaimg.cn/large/006y8mN6gy1g7aa03bmfpj3069069mx8.jpg"),
],
),
SizedBox(
height: 20,
),
],
),
),
Container(
// margin: EdgeInsets.only(bottom: 20),
// padding: EdgeInsets.all(16),
decoration: BoxDecoration(
color: Colors.white,
boxShadow: [
BoxShadow(
color: Colors.black.withAlpha(12),
offset: Offset(0, 2),
blurRadius: 14,
spreadRadius: 0)
],
),
child: Column(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Padding(padding: EdgeInsets.all(16),child:Text("评论 (58) 喜欢 (58)",
style: TextStyle(
fontSize: 16,
fontWeight: FontWeight.bold,
color: Color(0xff1A1A1A))),),
SizedBox(
height: 600,
child: ListView.builder(
itemCount: 6,
scrollDirection: Axis.vertical,
physics: BouncingScrollPhysics(),
itemBuilder: (context, position) {
return _commentItem(position);
},
),
),
],
),
),
SizedBox(
height: 12,
),
Container(
padding: EdgeInsets.all(16),
decoration: BoxDecoration(
color: Colors.white,
boxShadow: [
BoxShadow(
color: Colors.black.withAlpha(12),
offset: Offset(0, 2),
blurRadius: 14,
spreadRadius: 0)
],
borderRadius: new BorderRadius.only(
topLeft: Radius.circular(8.0),
topRight: Radius.circular(8.0),
),
),
child: Row(
children: [
Expanded(
flex: 1,
child: Container(
decoration: new BoxDecoration(
color: Color(0xffF2F2F2),
borderRadius: BorderRadius.circular(2.0)),
child: Column(
children: [
Container(
margin: const EdgeInsets.fromLTRB(4, 0, 4, 0),
alignment: Alignment.topLeft,
child: TextField(
maxLines: 8,
minLines: 1,
decoration: InputDecoration(
border: InputBorder.none,
hintText: "留下您精彩的评论吧~",
hintStyle: TextStyle(
fontSize: 14,
color: Color(0xffCDCCCC),
),
),
),
),
],
),
),
),
Padding(
padding: EdgeInsets.only(left: 20, right: 20),
child: Text(
"发送",
style: TextStyle(
fontSize: 16,
fontWeight: FontWeight.bold,
color: Color(0XFF1A1A1A)),
),
),
Image.asset("assets/image/icon_like_h.png")
],
),
),
],
),
),
),
);
}
Widget _textWidget(var text){
return Padding(padding: EdgeInsets.only(bottom: 20),child: Row(
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text("",style: TextStyle(fontSize: 10,color: Color(0xff32A060)),),
SizedBox(
width: 5,
),
Expanded(child: Text(text,style: TextStyle(fontSize: 12,color: Colors.black))),
],
),);
}
Widget _ideaWidget(var text,var img){
return Expanded(
flex: 1,
child: Stack(
alignment: Alignment.center,
children: [
Container(
width: 63,
height: 63,
child:CircleAvatar(
radius: 100,
backgroundImage: NetworkImage(img),
child: Container(
alignment: Alignment.center,
child: Text(text,style: TextStyle(fontSize:18,fontWeight: FontWeight.w300,color: Colors.white),)
),
),
),
Container(
width: 73,
height: 73,
child: CustomPaint(
painter:MyPainter(lineColor: Color(0xff32A060),width:2,isDividerRound:true),
),
)
],
),);
}
Widget _commentItem(var position) {
return Container(
child: Column(
children: [
Padding(padding: EdgeInsets.all(16),child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
crossAxisAlignment: CrossAxisAlignment.center,
children: [
ClipOval(
child: Image.network(
"https://t7.baidu.com/it/u=2841334870,333581502&fm=193&f=GIF",
fit: BoxFit.cover,
width: 40,
height: 40,
),
clipBehavior: Clip.hardEdge,
),
SizedBox(
width: 12,
),
Expanded(
child: Container(
height: 60,
child: Column(
mainAxisAlignment: MainAxisAlignment.spaceEvenly,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text.rich(
TextSpan(children: [
TextSpan(
text: "张三",
style: TextStyle(
fontWeight: FontWeight.bold,
fontSize: 14,
color: Colors.black),
),
]),
textDirection: TextDirection.ltr,
),
Text(
"2021.04.12 12:12",
overflow: TextOverflow.ellipsis,
maxLines: 2,
style: TextStyle(
fontSize: 12,
color: Color(0xff808080),
),
),
],
),
),
flex: 1,
),
Container(
alignment: Alignment.topRight,
child: Row(
children: [
Image.asset(
"assets/image/icon_like.png",
width: 16,
height: 16,
),
Text(
"58",
style: TextStyle(fontSize: 12, color: Color(0xff1A1A1A)),
),
],
),
),
],
),),
Padding(
padding: EdgeInsets.only(left: 68,right: 16),
child: Text(
"文本,是指书面语言的表现形式,从文学角度说,通常是具有完整、系统含义(Mess…",
style: TextStyle(fontSize: 14, color: Color(0xff1A1A1A)),
),
),
SizedBox(
height: 12,
),
Container(
width: double.infinity,
margin: EdgeInsets.only(left: 68,right: 16),
decoration: new BoxDecoration(
color: Color(0xffF2F2F2),
borderRadius: BorderRadius.circular(2.0),
),
child: Padding(
padding: EdgeInsets.only(left: 4, top: 4, bottom: 4),
child: Text(
"文本,是指书面语言的表现形式文本,是指、",
style: TextStyle(fontSize: 12, color: Color(0xff808080)),
),
),
),
if (position == 5)
Container(
height: 63,
decoration: BoxDecoration(
color: Color(0xffF2F2F2),
boxShadow: [
BoxShadow(
color: Colors.black.withAlpha(12),
offset: Offset(0, 2),
blurRadius: 14,
spreadRadius: 0)
],
),
margin: EdgeInsets.only(top: 30),
alignment: Alignment.center,
child: Text(
"-已显示全部评论-",
style: TextStyle(fontSize: 14, color: Color(0xff353535)),
),
),
],
),
);
}
}

7
lib/home/home_page.dart

@ -160,7 +160,12 @@ class _HomePage extends State<HomePage> with AutomaticKeepAliveClientMixin {
text: S.of(context).chuangshirendegushi,
imgPath: "assets/image/icon_today_task.png",
),
founderStore(),
GestureDetector(
onTap: () {
Navigator.of(context).pushNamed('/router/founder_story_page');
},
child: founderStore(),
),
ItemTitle(
text: S.of(context).pinpaijieshao,
imgPath: "assets/image/icon_brand_introduction.png",

2
lib/home/huixiang_brand_page.dart

@ -410,7 +410,7 @@ class _BrandPage extends State<BrandPage>
height: 40,
),
Text(
S.of(context).linian,
S.of(context).tixian,
style: TextStyle(
fontSize: 16.sp,
fontWeight: FontWeight.bold,

16
lib/l10n/intl_en.arb

@ -54,7 +54,7 @@
"shezhi": "设置",
"youhuiquan": "优惠券",
"bangzhuyufankui": "帮助与反馈",
"shiyongriqi": "使用日期{date}",
"shiyongriqi": "使用日期",
"keyongyouhuiquan": "可用优惠券",
"yishixiao": "已失效",
"quanbudingdan": "全部订单",
@ -193,10 +193,10 @@
"duihuanshangpinxiangqing": "兑换商品详情",
"querenduihuan": "确认兑换",
"yiwanchengdingdan": "已完成订单",
"yishiming": "已实名",
"shixiaoquan": "失效券",
"shouhuodizhi": "收货地址",
"wenzhangxiangqing": "文章详情",
"shouhuodizhi": "收货地址",
"yishiming": "已实名",
"chakanshixiaoquan": "查看失效券",
"meiyougengduoyouhuiquan": "没有更多优惠券了",
"shixiaoyouhuiquan": "失效优惠券",
@ -230,8 +230,8 @@
"weixinzhifu": "微信支付",
"querenchongzhi": "确认充值",
"peisong": "配送",
"xuni": "虚拟",
"keyongquan": "可用券",
"xuni": "虚拟",
"qingxuanzeshouhuodizhi": "请选择收货地址",
"feishiwushangpin": "非实物商品兑换后领取到卡包即可使用!",
"duihuanhoufahuo": "兑换后五个工作日内发货",
@ -253,6 +253,14 @@
"meiyougengduoshujule": "没有更多的数据了",
"shangpinxiangqing": "商品详情",
"kaiqiquanxian": "开启权限",
"meiyougengduohuiyuanka": "没有更多会员卡了",
"huiyuankaxiangqing": "会员卡详情",
"yuemingxi": "余额明细",
"kelingqudeyouhuiquan": "可领取的优惠券",
"shangjiaquan": "商家券",
"manyuankeyong": "满{man}元可用",
"jifen": "积分",
"chakanwodekaquan": "查看我的卡券",
"guanyu": "关于",
"linian": "理念",
"jingbilianmenghuiyuandian": "净币联盟会员店",

10
lib/l10n/intl_zh_CN.arb

@ -54,7 +54,7 @@
"shezhi": "设置",
"youhuiquan": "优惠券",
"bangzhuyufankui": "帮助与反馈",
"shiyongriqi": "使用日期{date}",
"shiyongriqi": "使用日期",
"keyongyouhuiquan": "可用优惠券",
"yishixiao": "已失效",
"quanbudingdan": "全部订单",
@ -253,6 +253,14 @@
"meiyougengduoshujule": "没有更多的数据了",
"shangpinxiangqing": "商品详情",
"kaiqiquanxian": "开启权限",
"meiyougengduohuiyuanka": "没有更多会员卡了",
"huiyuankaxiangqing": "会员卡详情",
"yuemingxi": "余额明细",
"kelingqudeyouhuiquan": "可领取的优惠券",
"shangjiaquan": "商家券",
"manyuankeyong": "满{man}元可用",
"jifen": "积分",
"chakanwodekaquan": "查看我的卡券",
"guanyu": "关于",
"linian": "理念",
"jingbilianmenghuiyuandian": "净币联盟会员店",

3
lib/l10n/intl_zh_TW.arb

@ -45,7 +45,6 @@
"jifendaoxiayidengji": "{jifen}積分 到下一個等級",
"kaitongriqi": "開通日期:{date}",
"kabao": "卡包",
"kaquan": "卡券",
"dingdan": "訂單",
"ninyouyigedingdanyaolingqu": "您有一個訂單需要前往門店領取",
"wodeqianbao": "我的錢包",
@ -56,7 +55,7 @@
"youhuiquan": "優惠券",
"bangzhuyufankui": "幫助與反饋",
"fankui": "反馈",
"shiyongriqi": "使用日期{date}",
"shiyongriqi": "使用日期",
"keyongyouhuiquan": "可用優惠券",
"keyongquan": "可用券",
"shixiaoquan": "失效券",

11
lib/login/login_page.dart

@ -15,7 +15,6 @@ import 'package:huixiang/generated/l10n.dart';
import 'package:flutter_screenutil/flutter_screenutil.dart';
import 'package:dio/dio.dart';
import 'package:huixiang/view_widget/loading_view.dart';
import 'package:photo_view/photo_view.dart';
// import 'package:photo_view/photo_view.dart';
import 'package:shared_preferences/shared_preferences.dart';
@ -376,11 +375,11 @@ class _MyLoginPageState extends State<LoginPage> with TickerProviderStateMixin {
child: Stack(
alignment: Alignment.center,
children: [
PhotoView(
imageProvider: AssetImage("assets/image/laoban.png"),
initialScale: Platform.isAndroid ? 1.02 : 1.2,
basePosition: alignmentProgress,
),
// PhotoView(
// imageProvider: AssetImage("assets/image/laoban.png"),
// initialScale: Platform.isAndroid ? 1.02 : 1.2,
// basePosition: alignmentProgress,
// ),
Container(
decoration: BoxDecoration(
color: Color(0xFF32A060).withAlpha(changeAlpha),

70
lib/main.dart

@ -11,6 +11,7 @@ import 'package:huixiang/article/hot_article_details_page.dart';
import 'package:huixiang/article/hot_article_item.dart';
import 'package:huixiang/article/video_playback_page.dart';
import 'package:huixiang/generated/l10n.dart';
import 'package:huixiang/home/founder_story_page.dart';
import 'package:huixiang/integral/integral_detailed_page.dart';
import 'package:huixiang/integral/integral_page.dart';
import 'package:huixiang/integral_store/integral_store_details_page.dart';
@ -207,6 +208,7 @@ Map<String, WidgetBuilder> routers = <String, WidgetBuilder>{
LogisticsInformationPage(),
'/router/hot_article_details_page': (context, {arguments}) =>
HotArticleDetailsPage(),
'/router/founder_story_page': (context, {arguments}) => FounderStoryPage(),
'/router/video_playback_page': (context, {arguments}) => VideoPlaybackPage(),
'/router/roll_center_page': (context, {arguments}) => RollCenterPage(),
'/router/edit_name': (context, {arguments}) => EditName(
@ -215,3 +217,71 @@ Map<String, WidgetBuilder> routers = <String, WidgetBuilder>{
// '/router/hot_article_details_page': (context, {arguments}) => HotArticleDetailsPage(),
// '/router/ui_test': (context, {arguments}) => UITest(),
};
EventBus eventBus = EventBus(sync: true);
class MyApp extends StatelessWidget {
@override
Widget build(BuildContext context) {
return ScreenUtilInit(
designSize: Size(375, 812),
builder: () => MaterialApp(
debugShowCheckedModeBanner: false,
theme: ThemeData(
primarySwatch: Colors.blue,
textTheme: TextTheme(
button: TextStyle(fontSize: 24.sp),
bodyText1: TextStyle(fontSize: 12.sp),
bodyText2: TextStyle(fontSize: 16.sp),
),
),
// locale: locale,
localeResolutionCallback: (locale, supportedLocales) {
print("locale: $locale");
print("supportedLocales: $supportedLocales");
// Localizations.maybeLocaleOf(context)
return Locale.fromSubtags(languageCode: 'zh', countryCode: 'TW');
},
localizationsDelegates: [
GlobalMaterialLocalizations.delegate,
GlobalCupertinoLocalizations.delegate,
GlobalWidgetsLocalizations.delegate,
S.delegate
],
supportedLocales: S.delegate.supportedLocales,
home: LoginPage(),
onGenerateRoute: (settings) {
final String name = settings.name;
final Function pageContentBuilder = routers[name];
if (pageContentBuilder != null) {
final Route route = MaterialPageRoute(
builder: (context) {
return pageContentBuilder(context,
arguments: settings.arguments);
},
settings: settings,
);
return route;
}
return MaterialPageRoute(
//
builder: (context) {
return LoginPage();
},
settings: settings,
);
},
),
);
}
}
// : zh_Hans_TW
// : zh_Hant_TW
// : zh_Hant_HK
// : zh_Hant_CN
// : zh_Hans_CN
// : en_TW

1
lib/mine/mine_vip_level_page.dart

@ -63,6 +63,7 @@ class _MineVipLevelPage extends State<MineVipLevelPage> {
Expanded(
flex: 1,
child: Container(
height: double.infinity,
width: double.infinity,
margin: EdgeInsets.fromLTRB(0, 16, 0, 0),
padding: EdgeInsets.fromLTRB(16, 16, 16, 16),

2
lib/retrofit/data/coupon.dart

@ -91,4 +91,4 @@ class Coupon {
'status': this.status,
'storeList': this.storeList.map((e) => e.toJson()).toList()
};
}
}

2
pubspec.yaml

@ -71,7 +71,7 @@ dependencies:
cached_network_image: ^2.0.0
flutter_html: ^1.3.0 #2.1.0
photo_view: ^0.11.1
# photo_view: ^0.11.1
chewie: ^0.12.2
video_player: ^1.0.1

Loading…
Cancel
Save