Commit e84e8ac6eca1b9764305036534516b7be2f5fdbe

Authored by wdn127929
1 parent 93cba33a

新增修改订单的时间显示

... ... @@ -107,6 +107,8 @@ class NotebookDetail {
dynamic is_user_comments; //是否评价过
String up_date; //订单修改时间
String get statuImgAssets {
switch (status) {
case "0":
... ... @@ -301,7 +303,7 @@ class NotebookDetail {
@override
String toString() {
return 'NotebookDetail{id: $id, uid: $uid ,con_amount:$con_amount,abolition: $abolition, tableinfo: $tableinfo,actual_pum:$actual_pum, pnum: $pnum, rname: $rname, sex: $sex, phone: $phone, cusdem: $cusdem, cusman: $cusman, ddate: $ddate, is_set_ddate: $is_set_ddate, ddate_solt: $ddate_solt, status: $status, action: $action, type: $type, note_name: $note_name, seller_user_phone:$seller_user_phone, nick_name: $nick_name,channel: $channel, cdate: $cdate, demands: $demands, tables: $tables, cancel: $cancel, gid: $gid,place_order_name:$place_order_name,is_user_comments:$is_user_comments}';
return 'NotebookDetail{id: $id, uid: $uid ,con_amount:$con_amount,abolition: $abolition, tableinfo: $tableinfo,actual_pum:$actual_pum, pnum: $pnum, rname: $rname, sex: $sex, phone: $phone, cusdem: $cusdem, cusman: $cusman, ddate: $ddate, is_set_ddate: $is_set_ddate, ddate_solt: $ddate_solt, status: $status, action: $action, type: $type, note_name: $note_name, seller_user_phone:$seller_user_phone, nick_name: $nick_name,channel: $channel, cdate: $cdate, demands: $demands, tables: $tables, cancel: $cancel, gid: $gid,place_order_name:$place_order_name,is_user_comments:$is_user_comments,up_date:$up_date}';
}
}
... ...
... ... @@ -51,7 +51,10 @@ NotebookDetail _$NotebookDetailFromJson(Map<String, dynamic> json) {
: OrderInfo.fromJson(json['order_info'] as Map<String, dynamic>)
..gid = json['gid'] as String
..place_order_name = json['place_order_name'] as String
..is_user_comments = json['is_user_comments'] as dynamic;
..is_user_comments = json['is_user_comments'] as dynamic
..up_date = json['up_date'] as String;
}
Map<String, dynamic> _$NotebookDetailToJson(NotebookDetail instance) =>
... ... @@ -88,6 +91,7 @@ Map<String, dynamic> _$NotebookDetailToJson(NotebookDetail instance) =>
'gid': instance.gid,
'place_order_name': instance.place_order_name,
'is_user_comments': instance.is_user_comments,
'up_date':instance.up_date,
};
OrderInfo _$OrderInfoFromJson(Map<String, dynamic> json) {
return OrderInfo(
... ...
... ... @@ -1555,13 +1555,18 @@ class NotebookDetailPageState extends State<NotebookDetailPage> {
style:
TextStyle(color: MyColours.color_515151, fontSize: font(14)),
),
HEmptyView(40),
// HEmptyView(40),
Expanded(
child: Text(
'${detailEntity.nick_name ?? ''}' +
' ' +
'${detailEntity.seller_user_phone ?? ''} xxxx时间/电话范德萨发顺丰?',
' ' +
'${detailEntity.seller_user_phone ?? ''}' +
( detailEntity.up_date ==
null
? ''
: ' ${_getDateTime(detailEntity.up_date)}'),
// overflow: TextOverflow.ellipsis,
textAlign: TextAlign.right,
style:
TextStyle(color: MyColours.color_999999, fontSize: font(14)),
)),
... ... @@ -1582,12 +1587,15 @@ class NotebookDetailPageState extends State<NotebookDetailPage> {
style: TextStyle(
color: MyColours.color_515151, fontSize: font(14)),
),
Text(
HEmptyView(40),
Expanded(
child: Text(
'${detailEntity.abolition == '2' ? '顾客在线取消' : detailEntity.cancel?.uname ?? ""} ${detailEntity.cancel?.cdateStr ?? ""}',
overflow: TextOverflow.ellipsis,
textAlign: TextAlign.right,
style: TextStyle(
color: MyColours.color_999999, fontSize: font(14)),
),
)),
])),
Container(
padding: EdgeInsets.only(left: w(13), top: w(10)),
... ... @@ -1696,115 +1704,135 @@ class NotebookDetailPageState extends State<NotebookDetailPage> {
child: Column(
children: <Widget>[
Column(children: [
Container(
color: MyColours.color_ffffff,
width: double.infinity,
padding: EdgeInsets.symmetric(
vertical: ScreenUtil()
.setWidth(25)),
alignment: Alignment.center,
child: Row(
crossAxisAlignment:
CrossAxisAlignment.center,
mainAxisAlignment:
MainAxisAlignment
.spaceBetween,
children: <Widget>[
Text(
'预订桌位',
style: TextStyle(
color: MyColours
.color_515151,
fontSize: ScreenUtil()
.setSp(30)),
),
detailEntity.tables.length < 3
? Row(
children:
_tableWidget(
detailEntity
.tables),
)
: InkWell(
onTap: () {
DialogUtil
.openFTablesDialog(
context,
detailEntity
.tables);
},
child: Container(
// height: ScreenUtil()
// .setWidth(
// 50),
padding: EdgeInsets.symmetric(
horizontal:
ScreenUtil()
.setWidth(
20),
vertical:
ScreenUtil()
.setWidth(
18)),
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(
ScreenUtil()
.setWidth(
10)),
Stack(
alignment: Alignment.topCenter,
children: [
Column(children: [
Container(
color: MyColours
.color_ffffff,
width: double.infinity,
padding:
EdgeInsets.symmetric(
vertical:
ScreenUtil()
.setWidth(
25)),
alignment:
Alignment.center,
child: Row(
crossAxisAlignment:
CrossAxisAlignment
.center,
mainAxisAlignment:
MainAxisAlignment
.spaceBetween,
children: <Widget>[
Text(
'预订桌位',
style: TextStyle(
color: MyColours
.color_199095),
child: Text(
'${detailEntity.tables.length}桌 查看',
style: TextStyle(
color: MyColours
.color_ffffff,
fontSize:
ScreenUtil()
.setSp(
30)),
),
.color_515151,
fontSize:
ScreenUtil()
.setSp(
30)),
),
)
],
),
),
// RowMultiText(
// "预订桌位",
// (detailEntity.tables.length
// .toString() +
// "个")),
// Align(
// alignment:
// Alignment.centerRight,
// child: Offstage(
// offstage: detailEntity
// .tables.length >
// 0
// ? false
// : true,
// child: Container(
// height: ScreenUtil()
// .setHeight(210),
// child: ListView.builder(
// itemBuilder:
// (BuildContext contxt,
// int index) {
// return TableItem(
// detailEntity
// .tables[index]);
// },
// itemCount: detailEntity
// .tables.length,
// shrinkWrap: true,
// scrollDirection:
// Axis.horizontal,
// ),
// ),
// )),
RowMultiText(
"预订日期", detailEntity.ddateF,
textColor:
MyColours.color_515151),
detailEntity.tables
.length <
3
? Row(
children: _tableWidget(
detailEntity
.tables),
)
: InkWell(
onTap: () {
DialogUtil.openFTablesDialog(
context,
detailEntity
.tables);
},
child:
Container(
// height: ScreenUtil()
// .setWidth(
// 50),
padding: EdgeInsets.symmetric(
horizontal:
ScreenUtil().setWidth(
20),
vertical:
ScreenUtil().setWidth(18)),
decoration: BoxDecoration(
borderRadius:
BorderRadius.circular(ScreenUtil().setWidth(
10)),
color: MyColours
.color_199095),
child: Text(
'${detailEntity.tables.length}桌 查看',
style: TextStyle(
color: MyColours
.color_ffffff,
fontSize:
ScreenUtil().setSp(30)),
),
),
)
],
),
),
// RowMultiText(
// "预订桌位",
// (detailEntity.tables.length
// .toString() +
// "个")),
// Align(
// alignment:
// Alignment.centerRight,
// child: Offstage(
// offstage: detailEntity
// .tables.length >
// 0
// ? false
// : true,
// child: Container(
// height: ScreenUtil()
// .setHeight(210),
// child: ListView.builder(
// itemBuilder:
// (BuildContext contxt,
// int index) {
// return TableItem(
// detailEntity
// .tables[index]);
// },
// itemCount: detailEntity
// .tables.length,
// shrinkWrap: true,
// scrollDirection:
// Axis.horizontal,
// ),
// ),
// )),
RowMultiText("预订日期",
detailEntity.ddateF,
textColor: MyColours
.color_515151)
]),
Positioned(
top: w(20),
child: Image.asset(
detailEntity
.statuImgAssets,
width: ScreenUtil()
.setWidth(114),
height: ScreenUtil()
.setWidth(56),
))
]),
Row(
children: [
... ... @@ -1991,60 +2019,60 @@ class NotebookDetailPageState extends State<NotebookDetailPage> {
// ],
// ),
// ),
Stack(
alignment: Alignment.topCenter,
children: [
Column(
children: [
// Offstage(
// offstage: detailEntity
// .place_order_name ==
// '' ||
// detailEntity
// .place_order_name ==
// null,
// child:
// ),
RowMultiText("下单人",
'${detailEntity.place_order_name ?? ''}',
textColor: MyColours
.color_515151),
// Offstage(
// offstage: detailEntity
// .nick_name ==
// '' ||
// detailEntity
// .nick_name ==
// null,
// child:
RowMultiText(
"记录人",
'${detailEntity.nick_name ?? ''}' +
' ' +
'${detailEntity.seller_user_phone ?? ''}',
textColor: MyColours
.color_515151),
// ),
],
),
Positioned(
top: w(10),
child: Image.asset(
detailEntity
.statuImgAssets,
width: ScreenUtil()
.setWidth(114),
height: ScreenUtil()
.setWidth(56),
))
]),
// Stack(
// alignment: Alignment.topCenter,
// children: [
// // Column(
// // children: [
// // // Offstage(
// // // offstage: detailEntity
// // // .place_order_name ==
// // // '' ||
// // // detailEntity
// // // .place_order_name ==
// // // null,
// // // child:
// // // ),
// // RowMultiText("下单人",
// // '${detailEntity.place_order_name ?? ''}',
// // textColor: MyColours
// // .color_515151),
// // // Offstage(
// // // offstage: detailEntity
// // // .nick_name ==
// // // '' ||
// // // detailEntity
// // // .nick_name ==
// // // null,
// // // child:
// // RowMultiText(
// // "记录人",
// // '${detailEntity.nick_name ?? ''}' +
// // ' ' +
// // '${detailEntity.seller_user_phone ?? ''}',
// // textColor: MyColours
// // .color_515151),
// // // ),
// // ],
// // ),
// Positioned(
// top: w(10),
// child: Image.asset(
// detailEntity
// .statuImgAssets,
// width: ScreenUtil()
// .setWidth(114),
// height: ScreenUtil()
// .setWidth(56),
// ))
// ]),
RowMultiText(
"下单时间",
_getDateTime(
detailEntity.cdate),
textColor:
MyColours.color_515151),
// RowMultiText(
// "下单时间",
// _getDateTime(
// detailEntity.cdate),
// textColor:
// MyColours.color_515151),
detailEntity.cusdem != null &&
detailEntity.cusdem != ''
? RowMultiText(
... ... @@ -2071,47 +2099,47 @@ class NotebookDetailPageState extends State<NotebookDetailPage> {
},
),
Offstage(
offstage:
(detailEntity.status == "4" &&
detailEntity.cancel !=
null)
? false
: true,
child: Column(
children: <Widget>[
MyDivider(
double.infinity,
ScreenUtil()
.setHeight(2)),
RowMultiText(
"取消原因",
detailEntity
.cancel?.desc ??
"",
textAlign: TextAlign.left,
textColor: MyColours
.color_515151),
RowMultiText(
"取消时间",
detailEntity.cancel
?.cdateStr ??
"",
textColor: MyColours
.color_515151),
RowMultiText(
"操作人",
detailEntity.abolition ==
'2'
? '顾客在线取消'
: detailEntity.cancel
?.uname ??
"",
textColor: MyColours
.color_515151),
],
),
),
// Offstage(
// offstage:
// (detailEntity.status == "4" &&
// detailEntity.cancel !=
// null)
// ? false
// : true,
// child: Column(
// children: <Widget>[
// MyDivider(
// double.infinity,
// ScreenUtil()
// .setHeight(2)),
// RowMultiText(
// "取消原因",
// detailEntity
// .cancel?.desc ??
// "",
// textAlign: TextAlign.left,
// textColor: MyColours
// .color_515151),
// RowMultiText(
// "取消时间",
// detailEntity.cancel
// ?.cdateStr ??
// "",
// textColor: MyColours
// .color_515151),
// RowMultiText(
// "操作人",
// detailEntity.abolition ==
// '2'
// ? '顾客在线取消'
// : detailEntity.cancel
// ?.uname ??
// "",
// textColor: MyColours
// .color_515151),
// ],
// ),
// ),
_onlineCheckEditProvider
.orderInfoSunModel !=
null &&
... ...
... ... @@ -383,242 +383,6 @@ class LoginState extends State<LoginPage> with WidgetsBindingObserver {
// // errorText = value ?? "";
// });
});
}
... ...
import 'dart:convert';
import 'dart:io';
import 'dart:ui';
... ... @@ -216,6 +217,13 @@ class _BaseInfoPageState extends State<BaseInfoPage> {
//成功之后跳回前一个页面
// bus.emit('refresh_coupon_list');
Utils.showToast('保存成功');
if (App.sp.containsKey('user')) {
String s = App.sp.getString('user');
User _user = User.fromJson(json.decode(s));
_user.nickName = nameStr;
await UserModel().saveUserInfo(_user);
}
// EventBus().emit('changeStatusColor');
if (widget.fromPage == FromPage.FromPageIfNeedCreateStore) {
_loginStore(context, widget.sunModel);
... ...
... ... @@ -224,9 +224,9 @@ class _MyCustomerHomePageState extends State<MyCustomerHomePage> {
String index = '0';
if (btnTitle == '活跃') {
index = '1';
} else if (btnTitle == '60天未到店') {
} else if (btnTitle == '60天未预订') {
index = '2';
} else if (btnTitle == '120天未到店') {
} else if (btnTitle == '120天未预订') {
index = '3';
}
NavigatorUtil.goMyCustomerListPage(
... ... @@ -254,7 +254,7 @@ class _MyCustomerHomePageState extends State<MyCustomerHomePage> {
style: TextStyle(
color: btnTitle == '活跃'
? MyColours.color_199095
: btnTitle == '60天未到店'
: btnTitle == '60天未预订'
? MyColours.color_E89243
: MyColours.color_E34D59,
fontSize: ScreenUtil().setSp(48),
... ... @@ -272,9 +272,9 @@ class _MyCustomerHomePageState extends State<MyCustomerHomePage> {
String index = '0';
if (btnTitle == '活跃') {
index = '1';
} else if (btnTitle == '60天未到店') {
} else if (btnTitle == '60天未预订') {
index = '2';
} else if (btnTitle == '120天未到店') {
} else if (btnTitle == '120天未预订') {
index = '3';
}
NavigatorUtil.goMyCustomerListPage(
... ... @@ -403,12 +403,12 @@ class _MyCustomerHomePageState extends State<MyCustomerHomePage> {
HEmptyView(10),
_percentWidget(
'${customerProvider.guestSunmodel.sleep.count}',
'60天未到店',
'60天未预订',
'${customerProvider.guestSunmodel.sleep.scale}'),
HEmptyView(10),
_percentWidget(
'${customerProvider.guestSunmodel.drain.count}',
'120天未到店',
'120天未预订',
'${customerProvider.guestSunmodel.drain.scale}'),
],
),
... ...
... ... @@ -61,7 +61,6 @@ class _StoreCustomerHomeLeftPageState extends State<StoreCustomerHomeLeftPage> {
@override
void dispose() {
bus.off('refresh_store_customer_home');
// bus.off("refresh_coupon_list");
super.dispose();
... ... @@ -118,9 +117,9 @@ class _StoreCustomerHomeLeftPageState extends State<StoreCustomerHomeLeftPage> {
String index = '0';
if (btnTitle == '活跃') {
index = '1';
} else if (btnTitle == '60天未到店') {
} else if (btnTitle == '60天未预订') {
index = '2';
} else if (btnTitle == '120天未到店') {
} else if (btnTitle == '120天未预订') {
index = '3';
}
NavigatorUtil.goCustomerListPage(context, FromPage.FromPageHome, uid,
... ... @@ -145,7 +144,7 @@ class _StoreCustomerHomeLeftPageState extends State<StoreCustomerHomeLeftPage> {
style: TextStyle(
color: btnTitle == '活跃'
? MyColours.color_199095
: btnTitle == '60天未到店'
: btnTitle == '60天未预订'
? MyColours.color_E89243
: MyColours.color_E34D59,
fontSize: ScreenUtil().setSp(48),
... ... @@ -163,9 +162,9 @@ class _StoreCustomerHomeLeftPageState extends State<StoreCustomerHomeLeftPage> {
String index = '0';
if (btnTitle == '活跃') {
index = '1';
} else if (btnTitle == '60天未到店') {
} else if (btnTitle == '60天未预订') {
index = '2';
} else if (btnTitle == '120天未到店') {
} else if (btnTitle == '120天未预订') {
index = '3';
}
NavigatorUtil.goCustomerListPage(
... ... @@ -211,9 +210,9 @@ class _StoreCustomerHomeLeftPageState extends State<StoreCustomerHomeLeftPage> {
// if (btnTitle == '活跃') {
// index = '1';
// } else if (btnTitle == '60天未到店') {
// } else if (btnTitle == '60天未预订') {
// index = '2';
// } else if (btnTitle == '120天未到店') {
// } else if (btnTitle == '120天未预订') {
// index = '3';
// }
// if (btnTitle == '未分配') {
... ... @@ -889,9 +888,9 @@ class _StoreCustomerHomeLeftPageState extends State<StoreCustomerHomeLeftPage> {
children: [
_percentWidget('', '活跃', '', tap: false),
HEmptyView(10),
_percentWidget('', '60天未到店', '', tap: false),
_percentWidget('', '60天未预订', '', tap: false),
HEmptyView(10),
_percentWidget('', '120天未到店', '', tap: false),
_percentWidget('', '120天未预订', '', tap: false),
],
),
... ... @@ -1021,12 +1020,12 @@ class _StoreCustomerHomeLeftPageState extends State<StoreCustomerHomeLeftPage> {
HEmptyView(10),
_percentWidget(
'${widget.customerProvider.storeSunmodel.sleep.count}',
'60天未到店',
'60天未预订',
'${widget.customerProvider.storeSunmodel.sleep.scale}'),
HEmptyView(10),
_percentWidget(
'${widget.customerProvider.storeSunmodel.drain.count}',
'120天未到店',
'120天未预订',
'${widget.customerProvider.storeSunmodel.drain.scale}'),
],
),
... ...
... ... @@ -110,9 +110,9 @@
// String index = '0';
// if (btnTitle == '活跃') {
// index = '1';
// } else if (btnTitle == '60天未到店') {
// } else if (btnTitle == '60天未预订') {
// index = '2';
// } else if (btnTitle == '120天未到店') {
// } else if (btnTitle == '120天未预订') {
// index = '3';
// }
// NavigatorUtil.goCustomerListPage(context, FromPage.FromPageHome, uid,
... ... @@ -136,7 +136,7 @@
// style: TextStyle(
// color: btnTitle == '活跃'
// ? MyColours.color_199095
// : btnTitle == '60天未到店'
// : btnTitle == '60天未预订'
// ? MyColours.color_E89243
// : MyColours.color_E34D59,
// fontSize: ScreenUtil().setSp(48),
... ... @@ -154,9 +154,9 @@
// String index = '0';
// if (btnTitle == '活跃') {
// index = '1';
// } else if (btnTitle == '60天未到店') {
// } else if (btnTitle == '60天未预订') {
// index = '2';
// } else if (btnTitle == '120天未到店') {
// } else if (btnTitle == '120天未预订') {
// index = '3';
// }
// NavigatorUtil.goCustomerListPage(
... ... @@ -196,9 +196,9 @@
// // if (btnTitle == '活跃') {
// // index = '1';
// // } else if (btnTitle == '60天未到店') {
// // } else if (btnTitle == '60天未预订') {
// // index = '2';
// // } else if (btnTitle == '120天未到店') {
// // } else if (btnTitle == '120天未预订') {
// // index = '3';
// // }
// // if (btnTitle == '未分配') {
... ... @@ -902,12 +902,12 @@
// HEmptyView(10),
// _percentWidget(
// '${widget.customerProvider.storeSunmodel.sleep.count}',
// '60天未到店',
// '60天未预订',
// '${widget.customerProvider.storeSunmodel.sleep.scale}'),
// HEmptyView(10),
// _percentWidget(
// '${widget.customerProvider.storeSunmodel.drain.count}',
// '120天未到店',
// '120天未预订',
// '${widget.customerProvider.storeSunmodel.drain.scale}'),
// ],
// ),
... ... @@ -1054,7 +1054,7 @@
// child: MonthItem(
// countsListSunModel: countsListSunModel));
// }),
// /**
// /**
// ListView.builder(
// itemCount: 10,
// controller: _controller,
... ...
... ... @@ -70,10 +70,9 @@ class _StoreCustomerHomeRightPageState
messageMenuModel.uid = element.uid;
messageMenuModel.title = element.nickName ?? element.account;
messageMenuModel.select = false;
if(messageMenuModel.title != null){
menuTitle.add(messageMenuModel);
if (messageMenuModel.title != null) {
menuTitle.add(messageMenuModel);
}
});
if (menuTitle.length > 0) {
menuTitle[0].select = true;
... ... @@ -302,9 +301,9 @@ class _StoreCustomerHomeRightPageState
String index = '0';
if (btnTitle == '活跃') {
index = '1';
} else if (btnTitle == '60天未到店') {
} else if (btnTitle == '60天未预订') {
index = '2';
} else if (btnTitle == '120天未到店') {
} else if (btnTitle == '120天未预订') {
index = '3';
}
String uid = '';
... ... @@ -335,7 +334,7 @@ class _StoreCustomerHomeRightPageState
style: TextStyle(
color: btnTitle == '活跃'
? MyColours.color_199095
: btnTitle == '60天未到店'
: btnTitle == '60天未预订'
? MyColours.color_E89243
: MyColours.color_E34D59,
fontSize: ScreenUtil().setSp(48),
... ... @@ -353,9 +352,9 @@ class _StoreCustomerHomeRightPageState
String index = '0';
if (btnTitle == '活跃') {
index = '1';
} else if (btnTitle == '60天未到店') {
} else if (btnTitle == '60天未预订') {
index = '2';
} else if (btnTitle == '120天未到店') {
} else if (btnTitle == '120天未预订') {
index = '3';
}
String uid = '';
... ... @@ -401,669 +400,660 @@ class _StoreCustomerHomeRightPageState
// EventBus().emit('changeStatusColor');
// Navigator.pop(context);
// }),
body: Column(children: [
Container(
color: MyColours.color_ffffff,
height: ScreenUtil().setWidth(70),
padding: EdgeInsets.only(bottom: w(12)),
margin: EdgeInsets.only(bottom: ScreenUtil().setWidth(10)),
child: Row(
children: [
HEmptyView(48),
Expanded(
child: SizedBox(
// height: ScreenUtil().setWidth(30),
child: ListView.builder(
itemCount: menuTitle.length,
shrinkWrap: true,
controller: _controller,
scrollDirection: Axis.horizontal,
itemBuilder: (BuildContext contxt, int index) {
return InkWell(
onTap: () {
for (MessageMenuModel item in menuTitle) {
item.select = false;
}
menuTitle[index].select = true;
setState(() {});
// _getMarketingByUid();
// _getSellerCountsList();
_getSellerCountsList(
isShowLoading: true, callback: () {});
_couponNetworkData(isShowLoading: false);
body: Column(children: [
Container(
color: MyColours.color_ffffff,
height: ScreenUtil().setWidth(70),
padding: EdgeInsets.only(bottom: w(12)),
margin: EdgeInsets.only(bottom: ScreenUtil().setWidth(10)),
child: Row(
children: [
HEmptyView(48),
Expanded(
child: SizedBox(
// height: ScreenUtil().setWidth(30),
child: ListView.builder(
itemCount: menuTitle.length,
shrinkWrap: true,
controller: _controller,
scrollDirection: Axis.horizontal,
itemBuilder: (BuildContext contxt, int index) {
return InkWell(
onTap: () {
for (MessageMenuModel item in menuTitle) {
item.select = false;
}
menuTitle[index].select = true;
setState(() {});
// _getMarketingByUid();
// _getSellerCountsList();
_getSellerCountsList(
isShowLoading: true, callback: () {});
_couponNetworkData(isShowLoading: false);
// offset = 0;
// 1提前点餐/2内部预订/10在线预订/15店内消息传/12在线买单
// offset = 0;
// 1提前点餐/2内部预订/10在线预订/15店内消息传/12在线买单
// if (index == 0) {
// typeid = '';
// } else if (index == 1) {
// //店内消息
// typeid = '15';
// } else if (index == 2) {
// //在线预订
// typeid = '10';
// } else if (index == 3) {
// //提前点餐
// typeid = '1';
// } else if (index == 4) {
// //在线买单
// typeid = '12';
// } else if (index == 5) {
// //会员充值
// typeid = '17';
// } else if (index == 6) {
// //存酒超期
// typeid = '18';
// }
// getMessage(typeid, showLoading: true);
},
child: Container(
// width: ScreenUtil().setWidth(104 * 2),
// if (index == 0) {
// typeid = '';
// } else if (index == 1) {
// //店内消息
// typeid = '15';
// } else if (index == 2) {
// //在线预订
// typeid = '10';
// } else if (index == 3) {
// //提前点餐
// typeid = '1';
// } else if (index == 4) {
// //在线买单
// typeid = '12';
// } else if (index == 5) {
// //会员充值
// typeid = '17';
// } else if (index == 6) {
// //存酒超期
// typeid = '18';
// }
// getMessage(typeid, showLoading: true);
},
child: Container(
// width: ScreenUtil().setWidth(104 * 2),
margin: EdgeInsets.only(
right: ScreenUtil().setWidth(30),
),
padding: EdgeInsets.symmetric(
horizontal: ScreenUtil().setWidth(10),
vertical: ScreenUtil().setWidth(4)),
alignment: Alignment.center,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(
ScreenUtil().setWidth(10)),
// color: menuTitle[index].select
// ? MyColours.color_438E93
// : MyColours.color_999999,
border: Border.all(
color: menuTitle[index].select
? MyColours.color_438E93
: MyColours.color_999999,
width: ScreenUtil().setWidth(2))),
child: Text(
menuTitle[index].title,
overflow: TextOverflow.ellipsis,
style: TextStyle(
color: menuTitle[index].select
? MyColours.color_438E93
: MyColours.color_999999,
fontSize: ScreenUtil().setSp(24),
decoration: TextDecoration.none,
fontWeight: FontWeight.normal),
),
),
);
})))
],
),
),
Consumer<CustomerProvider>(builder: (context, model, _) {
if (model.pageStateMyHome != PageState.Success) {
if (model.pageStateMyHome == PageState.Loading) {
return SingleChildScrollView(
controller: _controller,
child: Stack(alignment: Alignment.center, children: [
Column(children: [
VEmptyView(10),
// Stack(
// children: [
Container(
height: w(80),
color: MyColours.color_ffffff,
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Text(
'',
style: TextStyle(
color: MyColours.color_438E93,
fontSize: ScreenUtil().setSp(64),
fontWeight: FontWeight.bold),
),
Text(
'位',
style: TextStyle(
color: MyColours.color_515151,
// fontWeight: FontWeight.bold,
fontSize: ScreenUtil().setSp(32)),
)
],
margin: EdgeInsets.only(
right: ScreenUtil().setWidth(30),
),
padding: EdgeInsets.symmetric(
horizontal: ScreenUtil().setWidth(10),
vertical: ScreenUtil().setWidth(4)),
alignment: Alignment.center,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(
ScreenUtil().setWidth(10)),
// color: menuTitle[index].select
// ? MyColours.color_438E93
// : MyColours.color_999999,
border: Border.all(
color: menuTitle[index].select
? MyColours.color_438E93
: MyColours.color_999999,
width: ScreenUtil().setWidth(2))),
child: Text(
menuTitle[index].title,
overflow: TextOverflow.ellipsis,
style: TextStyle(
color: menuTitle[index].select
? MyColours.color_438E93
: MyColours.color_999999,
fontSize: ScreenUtil().setSp(24),
decoration: TextDecoration.none,
fontWeight: FontWeight.normal),
),
),
VEmptyView(10),
Row(
children: [
_percentWidget('', '活跃', '', tap: false),
HEmptyView(10),
_percentWidget('', '60天未到店', '', tap: false),
HEmptyView(10),
_percentWidget('', '120天未到店', '', tap: false),
],
),
);
})))
],
),
),
Consumer<CustomerProvider>(builder: (context, model, _) {
if (model.pageStateMyHome != PageState.Success) {
if (model.pageStateMyHome == PageState.Loading) {
return SingleChildScrollView(
controller: _controller,
child: Stack(alignment: Alignment.center, children: [
Column(children: [
VEmptyView(10),
// Stack(
// children: [
Container(
height: w(80),
color: MyColours.color_ffffff,
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
Text(
'',
style: TextStyle(
color: MyColours.color_438E93,
fontSize: ScreenUtil().setSp(64),
fontWeight: FontWeight.bold),
),
Text(
'位',
style: TextStyle(
color: MyColours.color_515151,
// fontWeight: FontWeight.bold,
fontSize: ScreenUtil().setSp(32)),
)
],
),
),
VEmptyView(10),
Row(
children: [
_percentWidget('', '活跃', '', tap: false),
HEmptyView(10),
_percentWidget('', '60天未预订', '', tap: false),
HEmptyView(10),
_percentWidget('', '120天未预订', '', tap: false),
],
),
// VEmptyView(10),
// GridView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: 6,
// gridDelegate:
// SliverGridDelegateWithFixedCrossAxisCount(
// crossAxisCount: 3,
// childAspectRatio: 1.05,
// mainAxisSpacing:
// ScreenUtil().setWidth(10),
// crossAxisSpacing:
// ScreenUtil().setWidth(10)),
// itemBuilder: (BuildContext context, int index) {
// return _managerWidget('', '', null, '',
// uid: '', onTap: () {});
// })
]),
Align(
alignment: Alignment.center,
child: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
ClipRRect(
borderRadius: BorderRadius.circular(10),
child: Container(
width: 200,
height: 200,
color: Colors.transparent,
child: CupertinoActivityIndicator(
color: MyColours.color_000000,
radius: 30,
),
))
// VEmptyView(30),
// Text(
// '加载中,请稍后...',
// style: TextStyle(
// color: MyColours.color_666666,
// fontSize: ScreenUtil().setSp(24)),
// )
],
),
))
]));
}
return Expanded(
child: ExceptionPage(
pageState: model.pageStateMyHome,
callback: () {
_couponNetworkData();
// VEmptyView(10),
// GridView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: 6,
// gridDelegate:
// SliverGridDelegateWithFixedCrossAxisCount(
// crossAxisCount: 3,
// childAspectRatio: 1.05,
// mainAxisSpacing:
// ScreenUtil().setWidth(10),
// crossAxisSpacing:
// ScreenUtil().setWidth(10)),
// itemBuilder: (BuildContext context, int index) {
// return _managerWidget('', '', null, '',
// uid: '', onTap: () {});
// })
]),
Align(
alignment: Alignment.center,
child: Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
ClipRRect(
borderRadius: BorderRadius.circular(10),
child: Container(
width: 200,
height: 200,
color: Colors.transparent,
child: CupertinoActivityIndicator(
color: MyColours.color_000000,
radius: 30,
),
))
// VEmptyView(30),
// Text(
// '加载中,请稍后...',
// style: TextStyle(
// color: MyColours.color_666666,
// fontSize: ScreenUtil().setSp(24)),
// )
],
),
))
]));
}
return Expanded(
child: ExceptionPage(
pageState: model.pageStateMyHome,
callback: () {
_couponNetworkData();
// _getMarketingByUid();
_getSellerCountsList();
},
emptyMsg: "暂时没有我的客情哦",
emptyImg: "empty_search",
showMsg: "加载中,请稍后...",
));
} else {
return Expanded(
child: SingleChildScrollView(
controller: _controller,
child: Column(
children: [
// VEmptyView(10),
// _getMarketingByUid();
_getSellerCountsList();
},
emptyMsg: "暂时没有我的客情哦",
emptyImg: "empty_search",
showMsg: "加载中,请稍后...",
));
} else {
return Expanded(
child: SingleChildScrollView(
controller: _controller,
child: Column(
children: [
// VEmptyView(10),
if (widget.customerProvider.guestSunmodel != null)
Column(
children: [
InkWell(
onTap: () {
String uid = '';
menuTitle.forEach((element) {
if (element.select) {
uid = element.uid;
}
});
NavigatorUtil.goMyCustomerListPage(context,
FromPage.FromPageMyCustomer, uid);
},
child: Container(
height: w(80),
color: MyColours.color_ffffff,
child: Row(
mainAxisAlignment:
MainAxisAlignment.center,
children: [
// Text(
// '累计',
// style: TextStyle(
// color: MyColours.color_515151,
// fontWeight: FontWeight.bold,
// fontSize: ScreenUtil().setSp(32)),
// ),
Text(
'${widget.customerProvider.guestSunmodel.myCustomer}',
style: TextStyle(
color: MyColours.color_199095,
fontSize: ScreenUtil().setSp(64),
fontWeight: FontWeight.bold),
),
Text(
'位',
style: TextStyle(
color: MyColours.color_515151,
fontWeight: FontWeight.bold,
fontSize: ScreenUtil().setSp(32)),
)
],
),
)),
VEmptyView(10),
// GridView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: 3,
// gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
// crossAxisCount: 3,
// childAspectRatio: 1,
// mainAxisSpacing: ScreenUtil().setWidth(10),
// crossAxisSpacing: ScreenUtil().setWidth(10)),
// itemBuilder: (BuildContext context, int index) {
// // locationState = state;
// return _percentWidget(
// '${widget.customerProvider.guestSunmodel.active.count}',
// '活跃客户',
// '${widget.customerProvider.guestSunmodel.active.scale}');
// }),
Row(
children: [
_percentWidget(
'${widget.customerProvider.guestSunmodel.active.count}',
'活跃',
'${widget.customerProvider.guestSunmodel.active.scale}'),
HEmptyView(10),
_percentWidget(
'${widget.customerProvider.guestSunmodel.sleep.count}',
'60天未到店',
'${widget.customerProvider.guestSunmodel.sleep.scale}'),
HEmptyView(10),
_percentWidget(
'${widget.customerProvider.guestSunmodel.drain.count}',
'120天未到店',
'${widget.customerProvider.guestSunmodel.drain.scale}'),
],
),
],
),
if (widget.customerProvider.guestSunmodel != null)
Column(
children: [
InkWell(
onTap: () {
String uid = '';
menuTitle.forEach((element) {
if (element.select) {
uid = element.uid;
}
});
NavigatorUtil.goMyCustomerListPage(
context, FromPage.FromPageMyCustomer, uid);
},
child: Container(
height: w(80),
color: MyColours.color_ffffff,
child: Row(
mainAxisAlignment: MainAxisAlignment.center,
children: [
// Text(
// '累计',
// style: TextStyle(
// color: MyColours.color_515151,
// fontWeight: FontWeight.bold,
// fontSize: ScreenUtil().setSp(32)),
// ),
Text(
'${widget.customerProvider.guestSunmodel.myCustomer}',
style: TextStyle(
color: MyColours.color_199095,
fontSize: ScreenUtil().setSp(64),
fontWeight: FontWeight.bold),
),
Text(
'位',
style: TextStyle(
color: MyColours.color_515151,
fontWeight: FontWeight.bold,
fontSize: ScreenUtil().setSp(32)),
)
],
),
)),
VEmptyView(10),
// GridView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: 3,
// gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
// crossAxisCount: 3,
// childAspectRatio: 1,
// mainAxisSpacing: ScreenUtil().setWidth(10),
// crossAxisSpacing: ScreenUtil().setWidth(10)),
// itemBuilder: (BuildContext context, int index) {
// // locationState = state;
// return _percentWidget(
// '${widget.customerProvider.guestSunmodel.active.count}',
// '活跃客户',
// '${widget.customerProvider.guestSunmodel.active.scale}');
// }),
Row(
children: [
_percentWidget(
'${widget.customerProvider.guestSunmodel.active.count}',
'活跃',
'${widget.customerProvider.guestSunmodel.active.scale}'),
HEmptyView(10),
_percentWidget(
'${widget.customerProvider.guestSunmodel.sleep.count}',
'60天未预订',
'${widget.customerProvider.guestSunmodel.sleep.scale}'),
HEmptyView(10),
_percentWidget(
'${widget.customerProvider.guestSunmodel.drain.count}',
'120天未预订',
'${widget.customerProvider.guestSunmodel.drain.scale}'),
],
),
],
),
// ListView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: widget.customerProvider.guestSunmodel
// .tips.task ==
// null ||
// widget.customerProvider.guestSunmodel.tips
// .task.length ==
// 0
// ? 0
// : widget.customerProvider.guestSunmodel.tips
// .task.length,
// itemBuilder: (BuildContext context, int index) {
// // locationState = state;
// Task data = widget.customerProvider.guestSunmodel
// .tips.task[index];
// return Column(
// children: [
// VEmptyView(10),
// Container(
// color: MyColours.color_ffffff,
// padding: EdgeInsets.symmetric(
// horizontal: ScreenUtil().setWidth(20),
// vertical: ScreenUtil().setWidth(30)),
// child: Row(
// children: [
// Image.asset(
// Utils.getImgPath('warning'),
// width: ScreenUtil().setWidth(42),
// ),
// HEmptyView(15),
// Expanded(
// child: Column(
// crossAxisAlignment:
// CrossAxisAlignment.start,
// children: [
// Text(
// '店内任务:${data.content}',
// maxLines: 1,
// overflow: TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours.color_333333,
// fontSize:
// ScreenUtil().setSp(32)),
// ),
// data.aid != null &&
// data.aidStr != null
// ? Padding(
// padding: EdgeInsets.only(
// top: ScreenUtil()
// .setWidth(8)),
// child: Text(
// '优惠内容:${data.aidStr}',
// maxLines: 1,
// overflow:
// TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours
// .color_333333,
// fontSize: ScreenUtil()
// .setSp(24)),
// ),
// )
// : SizedBox(),
// VEmptyView(8),
// Text(
// '创建人:${data.createUser}',
// maxLines: 1,
// overflow: TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours.color_333333,
// fontSize:
// ScreenUtil().setSp(26)),
// )
// ],
// )),
// HEmptyView(20),
// Column(children: [
// RoundButton(
// text: '立即完成',
// ListView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: widget.customerProvider.guestSunmodel
// .tips.task ==
// null ||
// widget.customerProvider.guestSunmodel.tips
// .task.length ==
// 0
// ? 0
// : widget.customerProvider.guestSunmodel.tips
// .task.length,
// itemBuilder: (BuildContext context, int index) {
// // locationState = state;
// Task data = widget.customerProvider.guestSunmodel
// .tips.task[index];
// return Column(
// children: [
// VEmptyView(10),
// Container(
// color: MyColours.color_ffffff,
// padding: EdgeInsets.symmetric(
// horizontal: ScreenUtil().setWidth(20),
// vertical: ScreenUtil().setWidth(30)),
// child: Row(
// children: [
// Image.asset(
// Utils.getImgPath('warning'),
// width: ScreenUtil().setWidth(42),
// ),
// HEmptyView(15),
// Expanded(
// child: Column(
// crossAxisAlignment:
// CrossAxisAlignment.start,
// children: [
// Text(
// '店内任务:${data.content}',
// maxLines: 1,
// overflow: TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours.color_333333,
// fontSize:
// ScreenUtil().setSp(32)),
// ),
// data.aid != null &&
// data.aidStr != null
// ? Padding(
// padding: EdgeInsets.only(
// top: ScreenUtil()
// .setWidth(8)),
// child: Text(
// '优惠内容:${data.aidStr}',
// maxLines: 1,
// overflow:
// TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours
// .color_333333,
// fontSize: ScreenUtil()
// .setSp(24)),
// ),
// )
// : SizedBox(),
// VEmptyView(8),
// Text(
// '创建人:${data.createUser}',
// maxLines: 1,
// overflow: TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours.color_333333,
// fontSize:
// ScreenUtil().setSp(26)),
// )
// ],
// )),
// HEmptyView(20),
// Column(children: [
// RoundButton(
// text: '立即完成',
// padding: EdgeInsets.symmetric(
// horizontal:
// ScreenUtil().setWidth(26)),
// gradientStart:
// MyColours.color_199095,
// gradientEnd: MyColours.color_199095,
// // borderColor: MyColours.color_999999,
// radius: ScreenUtil().setWidth(40),
// height: ScreenUtil().setWidth(64),
// width: ScreenUtil().setWidth(180),
// fontSize: 26,
// isBold: false,
// onPressed: () {
// SellerList sellerList =
// SellerList.fromJson(
// json.decode(
// json.encode(data)));
// NavigatorUtil
// .goMyMakeMarkingPageOnlyShow(
// context, sellerList);
// },
// ),
// data.remainingTime != null
// ? Padding(
// padding: EdgeInsets.only(
// top: ScreenUtil()
// .setWidth(6)),
// child: Text(
// '${data.remainingTime}天内',
// maxLines: 1,
// overflow:
// TextOverflow.ellipsis,
// style: TextStyle(
// color: Color.fromRGBO(
// 215, 30, 40, 1),
// fontSize: ScreenUtil()
// .setSp(26)),
// ))
// : SizedBox()
// ])
// ],
// ),
// ),
// ],
// );
// }),
// ListView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: widget.customerProvider.guestSunmodel
// .tips.recover ==
// null ||
// widget.customerProvider.guestSunmodel.tips
// .recover.length ==
// 0
// ? 0
// : 1,
// itemBuilder: (BuildContext context, int index) {
// // locationState = state;
// padding: EdgeInsets.symmetric(
// horizontal:
// ScreenUtil().setWidth(26)),
// gradientStart:
// MyColours.color_199095,
// gradientEnd: MyColours.color_199095,
// // borderColor: MyColours.color_999999,
// radius: ScreenUtil().setWidth(40),
// height: ScreenUtil().setWidth(64),
// width: ScreenUtil().setWidth(180),
// fontSize: 26,
// isBold: false,
// onPressed: () {
// SellerList sellerList =
// SellerList.fromJson(
// json.decode(
// json.encode(data)));
// NavigatorUtil
// .goMyMakeMarkingPageOnlyShow(
// context, sellerList);
// },
// ),
// data.remainingTime != null
// ? Padding(
// padding: EdgeInsets.only(
// top: ScreenUtil()
// .setWidth(6)),
// child: Text(
// '${data.remainingTime}天内',
// maxLines: 1,
// overflow:
// TextOverflow.ellipsis,
// style: TextStyle(
// color: Color.fromRGBO(
// 215, 30, 40, 1),
// fontSize: ScreenUtil()
// .setSp(26)),
// ))
// : SizedBox()
// ])
// ],
// ),
// ),
// ],
// );
// }),
// ListView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: widget.customerProvider.guestSunmodel
// .tips.recover ==
// null ||
// widget.customerProvider.guestSunmodel.tips
// .recover.length ==
// 0
// ? 0
// : 1,
// itemBuilder: (BuildContext context, int index) {
// // locationState = state;
// return Column(
// children: [
// VEmptyView(10),
// Container(
// color: MyColours.color_ffffff,
// padding: EdgeInsets.symmetric(
// horizontal: ScreenUtil().setWidth(20),
// vertical: ScreenUtil().setWidth(30)),
// child: Row(
// children: [
// Image.asset(
// Utils.getImgPath('warning'),
// width: ScreenUtil().setWidth(42),
// ),
// HEmptyView(15),
// Expanded(
// child: Text(
// '${widget.customerProvider.guestSunmodel.tips.recover[0]}',
// maxLines: 10,
// overflow: TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours.color_333333,
// fontSize: ScreenUtil().setSp(32)),
// )),
// HEmptyView(20),
// RoundButton(
// text: '一键追回',
// padding: EdgeInsets.symmetric(
// horizontal:
// ScreenUtil().setWidth(26)),
// gradientStart: MyColours.color_199095,
// gradientEnd: MyColours.color_199095,
// // borderColor: MyColours.color_999999,
// radius: ScreenUtil().setWidth(40),
// height: ScreenUtil().setWidth(64),
// width: ScreenUtil().setWidth(180),
// fontSize: 26,
// isBold: false,
// onPressed: () {
// String uid = '';
// menuTitle.forEach((element) {
// if (element.select) {
// uid = element.uid;
// }
// });
// NavigatorUtil.goMyMakeMarkingPage(
// context, uid,
// fromPage: FromPage
// .FromPageMyCustomer,
// homeGid:
// Utils.listToStringEnglish1(
// widget
// .customerProvider
// .guestSunmodel
// .tips
// .recover[1]));
// },
// ),
// ],
// ),
// ),
// ],
// );
// }),
// ListView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: widget.customerProvider.guestSunmodel
// .tips.awaken ==
// null ||
// widget.customerProvider.guestSunmodel.tips
// .awaken.length ==
// 0
// ? 0
// : 1,
// itemBuilder: (BuildContext context, int index) {
// // locationState = state;
// return Column(
// children: [
// VEmptyView(10),
// Container(
// color: MyColours.color_ffffff,
// padding: EdgeInsets.symmetric(
// horizontal: ScreenUtil().setWidth(20),
// vertical: ScreenUtil().setWidth(30)),
// child: Row(
// children: [
// Image.asset(
// Utils.getImgPath('warning'),
// width: ScreenUtil().setWidth(42),
// ),
// HEmptyView(15),
// Expanded(
// child: Text(
// '${widget.customerProvider.guestSunmodel.tips.recover[0]}',
// maxLines: 10,
// overflow: TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours.color_333333,
// fontSize: ScreenUtil().setSp(32)),
// )),
// HEmptyView(20),
// RoundButton(
// text: '一键追回',
// padding: EdgeInsets.symmetric(
// horizontal:
// ScreenUtil().setWidth(26)),
// gradientStart: MyColours.color_199095,
// gradientEnd: MyColours.color_199095,
// // borderColor: MyColours.color_999999,
// radius: ScreenUtil().setWidth(40),
// height: ScreenUtil().setWidth(64),
// width: ScreenUtil().setWidth(180),
// fontSize: 26,
// isBold: false,
// onPressed: () {
// String uid = '';
// menuTitle.forEach((element) {
// if (element.select) {
// uid = element.uid;
// }
// });
// NavigatorUtil.goMyMakeMarkingPage(
// context, uid,
// fromPage: FromPage
// .FromPageMyCustomer,
// homeGid:
// Utils.listToStringEnglish1(
// widget
// .customerProvider
// .guestSunmodel
// .tips
// .recover[1]));
// },
// ),
// ],
// ),
// ),
// ],
// );
// }),
// ListView.builder(
// controller: _controller,
// shrinkWrap: true,
// cacheExtent: ScreenUtil().setWidth(0),
// itemCount: widget.customerProvider.guestSunmodel
// .tips.awaken ==
// null ||
// widget.customerProvider.guestSunmodel.tips
// .awaken.length ==
// 0
// ? 0
// : 1,
// itemBuilder: (BuildContext context, int index) {
// // locationState = state;
// return Column(
// children: [
// VEmptyView(10),
// Container(
// color: MyColours.color_ffffff,
// padding: EdgeInsets.symmetric(
// horizontal: ScreenUtil().setWidth(20),
// vertical: ScreenUtil().setWidth(30)),
// child: Row(
// children: [
// Image.asset(
// Utils.getImgPath('warning'),
// width: ScreenUtil().setWidth(42),
// ),
// HEmptyView(15),
// Expanded(
// child: Text(
// '${widget.customerProvider.guestSunmodel.tips.awaken[0]}',
// maxLines: 10,
// overflow: TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours.color_333333,
// fontSize: ScreenUtil().setSp(32)),
// )),
// HEmptyView(20),
// RoundButton(
// text: '一键唤醒',
// padding: EdgeInsets.symmetric(
// horizontal:
// ScreenUtil().setWidth(26)),
// gradientStart: MyColours.color_199095,
// gradientEnd: MyColours.color_199095,
// // borderColor: MyColours.color_999999,
// radius: ScreenUtil().setWidth(40),
// height: ScreenUtil().setWidth(64),
// width: ScreenUtil().setWidth(180),
// fontSize: 26,
// isBold: false,
// onPressed: () {
// String uid = '';
// menuTitle.forEach((element) {
// if (element.select) {
// uid = element.uid;
// }
// });
// NavigatorUtil.goMyMakeMarkingPage(
// context, uid,
// fromPage: FromPage
// .FromPageMyCustomer,
// homeGid:
// Utils.listToStringEnglish1(
// widget
// .customerProvider
// .guestSunmodel
// .tips
// .awaken[1]));
// },
// ),
// ],
// ),
// ),
// ],
// );
// }),
if (widget.customerProvider.managerStatisticsList !=
null &&
widget.customerProvider.managerStatisticsList
.length >
0)
Column(
children: [
_chart(),
ListView.builder(
itemCount: widget.customerProvider
.managerStatisticsList.length,
shrinkWrap: true,
controller: _controller,
padding:
EdgeInsets.symmetric(horizontal: w(10)),
itemBuilder: (context, index) {
SellerCountsListSunModel
countsListSunModel = widget
.customerProvider
.managerStatisticsList[index];
return InkWell(
onTap: () {
String uid = '';
menuTitle.forEach((element) {
if (element.select) {
uid = element.uid;
}
});
NavigatorUtil.goMonthOrderPage(
context,
year.toString(),
countsListSunModel.monthss
.toString(),
uid: uid);
},
child: MonthItem(
countsListSunModel:
countsListSunModel));
})
],
)
],
),
));
}
})
// Container(
// color: MyColours.color_FAFAFA,
// padding: EdgeInsets.only(
// top: w(13), bottom: w(26), left: w(45), right: (45)),
// child: Stack(
// children: [
// RoundButton(
// onPressed: () {
// NavigatorUtil.goMyMarketingRecordsPage(
// context, FromPage.FromPageMyCustomer);
// },
// text: '历史营销记录',
// fontSize: 32,
// isBold: true,
// // margin: EdgeInsets.only(
// // top: w(13),
// // bottom: w(26),
// // left: w(45),
// // right: (45)),
// textColor: MyColours.color_F8F9FD,
// gradientStart: MyColours.color_199095,
// gradientEnd: MyColours.color_199095,
// borderColor: MyColours.color_199095,
// height: ScreenUtil().setWidth(86),
// // width: ScreenUtil().setWidth(260),
// radius: ScreenUtil().setWidth(10),
// ),
// showWarning
// ? Positioned(
// right: ScreenUtil().setWidth(30),
// top: ScreenUtil().setWidth(45 / 2),
// child: Image.asset(
// Utils.getImgPath('warning'),
// width: ScreenUtil().setWidth(35),
// ))
// : SizedBox()
// ],
// ))
]));
// return Column(
// children: [
// VEmptyView(10),
// Container(
// color: MyColours.color_ffffff,
// padding: EdgeInsets.symmetric(
// horizontal: ScreenUtil().setWidth(20),
// vertical: ScreenUtil().setWidth(30)),
// child: Row(
// children: [
// Image.asset(
// Utils.getImgPath('warning'),
// width: ScreenUtil().setWidth(42),
// ),
// HEmptyView(15),
// Expanded(
// child: Text(
// '${widget.customerProvider.guestSunmodel.tips.awaken[0]}',
// maxLines: 10,
// overflow: TextOverflow.ellipsis,
// style: TextStyle(
// color: MyColours.color_333333,
// fontSize: ScreenUtil().setSp(32)),
// )),
// HEmptyView(20),
// RoundButton(
// text: '一键唤醒',
// padding: EdgeInsets.symmetric(
// horizontal:
// ScreenUtil().setWidth(26)),
// gradientStart: MyColours.color_199095,
// gradientEnd: MyColours.color_199095,
// // borderColor: MyColours.color_999999,
// radius: ScreenUtil().setWidth(40),
// height: ScreenUtil().setWidth(64),
// width: ScreenUtil().setWidth(180),
// fontSize: 26,
// isBold: false,
// onPressed: () {
// String uid = '';
// menuTitle.forEach((element) {
// if (element.select) {
// uid = element.uid;
// }
// });
// NavigatorUtil.goMyMakeMarkingPage(
// context, uid,
// fromPage: FromPage
// .FromPageMyCustomer,
// homeGid:
// Utils.listToStringEnglish1(
// widget
// .customerProvider
// .guestSunmodel
// .tips
// .awaken[1]));
// },
// ),
// ],
// ),
// ),
// ],
// );
// }),
if (widget.customerProvider.managerStatisticsList != null &&
widget.customerProvider.managerStatisticsList.length > 0)
Column(
children: [
_chart(),
ListView.builder(
itemCount: widget
.customerProvider.managerStatisticsList.length,
shrinkWrap: true,
controller: _controller,
padding: EdgeInsets.symmetric(horizontal: w(10)),
itemBuilder: (context, index) {
SellerCountsListSunModel countsListSunModel = widget
.customerProvider.managerStatisticsList[index];
return InkWell(
onTap: () {
String uid = '';
menuTitle.forEach((element) {
if (element.select) {
uid = element.uid;
}
});
NavigatorUtil.goMonthOrderPage(
context,
year.toString(),
countsListSunModel.monthss.toString(),
uid: uid);
},
child: MonthItem(
countsListSunModel: countsListSunModel));
})
],
)
],
),
));
}
})
// Container(
// color: MyColours.color_FAFAFA,
// padding: EdgeInsets.only(
// top: w(13), bottom: w(26), left: w(45), right: (45)),
// child: Stack(
// children: [
// RoundButton(
// onPressed: () {
// NavigatorUtil.goMyMarketingRecordsPage(
// context, FromPage.FromPageMyCustomer);
// },
// text: '历史营销记录',
// fontSize: 32,
// isBold: true,
// // margin: EdgeInsets.only(
// // top: w(13),
// // bottom: w(26),
// // left: w(45),
// // right: (45)),
// textColor: MyColours.color_F8F9FD,
// gradientStart: MyColours.color_199095,
// gradientEnd: MyColours.color_199095,
// borderColor: MyColours.color_199095,
// height: ScreenUtil().setWidth(86),
// // width: ScreenUtil().setWidth(260),
// radius: ScreenUtil().setWidth(10),
// ),
// showWarning
// ? Positioned(
// right: ScreenUtil().setWidth(30),
// top: ScreenUtil().setWidth(45 / 2),
// child: Image.asset(
// Utils.getImgPath('warning'),
// width: ScreenUtil().setWidth(35),
// ))
// : SizedBox()
// ],
// ))
]));
}
}
... ...
... ... @@ -28,7 +28,7 @@
// import '../store_customer/bar_chart_page.dart';
// /**
// *
// *
// */
// class StoreCustomerHomeRightPage extends StatefulWidget {
// final CustomerProvider customerProvider;
... ... @@ -292,9 +292,9 @@
// String index = '0';
// if (btnTitle == '活跃') {
// index = '1';
// } else if (btnTitle == '60天未到店') {
// } else if (btnTitle == '60天未预订') {
// index = '2';
// } else if (btnTitle == '120天未到店') {
// } else if (btnTitle == '120天未预订') {
// index = '3';
// }
// String uid = '';
... ... @@ -325,7 +325,7 @@
// style: TextStyle(
// color: btnTitle == '活跃'
// ? MyColours.color_199095
// : btnTitle == '60天未到店'
// : btnTitle == '60天未预订'
// ? MyColours.color_E89243
// : MyColours.color_E34D59,
// fontSize: ScreenUtil().setSp(48),
... ... @@ -343,9 +343,9 @@
// String index = '0';
// if (btnTitle == '活跃') {
// index = '1';
// } else if (btnTitle == '60天未到店') {
// } else if (btnTitle == '60天未预订') {
// index = '2';
// } else if (btnTitle == '120天未到店') {
// } else if (btnTitle == '120天未预订') {
// index = '3';
// }
// String uid = '';
... ... @@ -581,12 +581,12 @@
// HEmptyView(10),
// _percentWidget(
// '${widget.customerProvider.guestSunmodel.sleep.count}',
// '60天未到店',
// '60天未预订',
// '${widget.customerProvider.guestSunmodel.sleep.scale}'),
// HEmptyView(10),
// _percentWidget(
// '${widget.customerProvider.guestSunmodel.drain.count}',
// '120天未到店',
// '120天未预订',
// '${widget.customerProvider.guestSunmodel.drain.scale}'),
// ],
// ),
... ...
... ... @@ -123,7 +123,8 @@ class NoteBookItemFState extends State<NoteBookItemF>
Map<String, String> params = {
"rid": widget.notebook.id,
"status": status, //5安排包间 2:确认到店(到店),3:用餐完成(离店),4:取消预定,5:分配包间:6:拒单
"uid": userModel.user.openid,
// "uid": userModel.user.openid,
'uid': widget.notebook.uid
};
if (status == '4') {
Map<String, String> causeMap = {
... ...
... ... @@ -135,7 +135,8 @@ class NoteBookItemSimpleState extends State<NoteBookItemSimple>
Map<String, String> params = {
"rid": widget.notebook.id,
"status": status, //5安排包间 2:确认到店(到店),3:用餐完成(离店),4:取消预定,5:分配包间:6:拒单
"uid": userModel.user.openid,
// "uid": userModel.user.openid,
'uid': widget.notebook.uid
};
if (status == '4') {
Map<String, String> causeMap = {
... ...