|
1
|
import 'package:flutter/material.dart';
|
1
|
import 'package:flutter/material.dart';
|
|
2
|
import 'package:flutter_screenutil/screenutil.dart';
|
2
|
import 'package:flutter_screenutil/screenutil.dart';
|
|
|
|
3
|
+import 'package:one_key/constant/state.dart';
|
|
|
|
4
|
+import 'package:one_key/models/guest_manage_model.dart';
|
|
|
|
5
|
+import 'package:one_key/provider/customer_provider.dart';
|
|
3
|
import 'package:one_key/res/colors.dart';
|
6
|
import 'package:one_key/res/colors.dart';
|
|
4
|
import 'package:one_key/route/navigator_util.dart';
|
7
|
import 'package:one_key/route/navigator_util.dart';
|
|
5
|
import 'package:one_key/utils/event_bus.dart';
|
8
|
import 'package:one_key/utils/event_bus.dart';
|
|
6
|
import 'package:one_key/utils/utils.dart';
|
9
|
import 'package:one_key/utils/utils.dart';
|
|
7
|
import 'package:one_key/widgets/h_empty_view.dart';
|
10
|
import 'package:one_key/widgets/h_empty_view.dart';
|
|
|
|
11
|
+import 'package:one_key/widgets/page_exception.dart';
|
|
8
|
import 'package:one_key/widgets/round_button.dart';
|
12
|
import 'package:one_key/widgets/round_button.dart';
|
|
9
|
import 'package:one_key/widgets/system_app_bar.dart';
|
13
|
import 'package:one_key/widgets/system_app_bar.dart';
|
|
10
|
import 'package:one_key/widgets/v_empty_view.dart';
|
14
|
import 'package:one_key/widgets/v_empty_view.dart';
|
|
|
|
15
|
+import 'package:provider/provider.dart';
|
|
11
|
|
16
|
|
|
12
|
class MyCustomerPage extends StatefulWidget {
|
17
|
class MyCustomerPage extends StatefulWidget {
|
|
13
|
MyCustomerPage({Key key}) : super(key: key);
|
18
|
MyCustomerPage({Key key}) : super(key: key);
|
|
@@ -18,12 +23,30 @@ class MyCustomerPage extends StatefulWidget { |
|
@@ -18,12 +23,30 @@ class MyCustomerPage extends StatefulWidget { |
|
18
|
|
23
|
|
|
19
|
class _MyCustomerPageState extends State<MyCustomerPage> {
|
24
|
class _MyCustomerPageState extends State<MyCustomerPage> {
|
|
20
|
ScrollController _controller = ScrollController();
|
25
|
ScrollController _controller = ScrollController();
|
|
|
|
26
|
+ CustomerProvider customerProvider;
|
|
|
|
27
|
+ @override
|
|
|
|
28
|
+ void initState() {
|
|
|
|
29
|
+ super.initState();
|
|
|
|
30
|
+
|
|
|
|
31
|
+ WidgetsBinding.instance.addPostFrameCallback((_) {
|
|
|
|
32
|
+ _getGuestManageData();
|
|
|
|
33
|
+ });
|
|
|
|
34
|
+ }
|
|
|
|
35
|
+
|
|
|
|
36
|
+ ///我的客户首页
|
|
|
|
37
|
+ _getGuestManageData() async {
|
|
|
|
38
|
+ GuestManageSunModel model =
|
|
|
|
39
|
+ await customerProvider.getGuestManageData(context);
|
|
|
|
40
|
+ // setState(() {});
|
|
|
|
41
|
+ }
|
|
21
|
|
42
|
|
|
22
|
///活跃客户、沉睡客户、流失客户
|
43
|
///活跃客户、沉睡客户、流失客户
|
|
23
|
Widget _percentWidget(String pnum, String btnTitle, String percent) {
|
44
|
Widget _percentWidget(String pnum, String btnTitle, String percent) {
|
|
24
|
return Container(
|
45
|
return Container(
|
|
25
|
color: MyColours.color_ffffff,
|
46
|
color: MyColours.color_ffffff,
|
|
26
|
// height: ScreenUtil().setWidth(230),
|
47
|
// height: ScreenUtil().setWidth(230),
|
|
|
|
48
|
+ width: (ScreenUtil.screenWidthDp - ScreenUtil().setWidth(20)) / 3,
|
|
|
|
49
|
+ height: (ScreenUtil.screenWidthDp - ScreenUtil().setWidth(20)) / 3,
|
|
27
|
child: Column(
|
50
|
child: Column(
|
|
28
|
mainAxisAlignment: MainAxisAlignment.center,
|
51
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
29
|
children: [
|
52
|
children: [
|
|
@@ -71,169 +94,348 @@ class _MyCustomerPageState extends State<MyCustomerPage> { |
|
@@ -71,169 +94,348 @@ class _MyCustomerPageState extends State<MyCustomerPage> { |
|
71
|
|
94
|
|
|
72
|
@override
|
95
|
@override
|
|
73
|
Widget build(BuildContext context) {
|
96
|
Widget build(BuildContext context) {
|
|
|
|
97
|
+ customerProvider = Provider.of<CustomerProvider>(context, listen: false);
|
|
74
|
return Scaffold(
|
98
|
return Scaffold(
|
|
75
|
- backgroundColor: Color.fromRGBO(246, 248, 250, 1),
|
|
|
|
76
|
- appBar: SystemAppBar('我的客情', onTap: () {
|
|
|
|
77
|
- EventBus().emit('changeStatusColor');
|
|
|
|
78
|
- Navigator.pop(context);
|
|
|
|
79
|
- }),
|
|
|
|
80
|
- body: WillPopScope(
|
|
|
|
81
|
- onWillPop: () async {
|
|
|
|
82
|
- EventBus().emit('changeStatusColor');
|
|
|
|
83
|
- return true;
|
|
|
|
84
|
- },
|
|
|
|
85
|
- child: Column(children: [
|
|
|
|
86
|
- Expanded(
|
|
|
|
87
|
- child: SingleChildScrollView(
|
|
|
|
88
|
- controller: _controller,
|
|
|
|
89
|
- child: Column(
|
|
|
|
90
|
- children: [
|
|
|
|
91
|
- Container(
|
|
|
|
92
|
- color: MyColours.color_ffffff,
|
|
|
|
93
|
- padding: EdgeInsets.symmetric(
|
|
|
|
94
|
- vertical: ScreenUtil().setWidth(30)),
|
|
|
|
95
|
- child: Column(
|
99
|
+ backgroundColor: Color.fromRGBO(246, 248, 250, 1),
|
|
|
|
100
|
+ appBar: SystemAppBar('我的客情', onTap: () {
|
|
|
|
101
|
+ EventBus().emit('changeStatusColor');
|
|
|
|
102
|
+ Navigator.pop(context);
|
|
|
|
103
|
+ }),
|
|
|
|
104
|
+ body: WillPopScope(onWillPop: () async {
|
|
|
|
105
|
+ EventBus().emit('changeStatusColor');
|
|
|
|
106
|
+ return true;
|
|
|
|
107
|
+ }, child: Consumer<CustomerProvider>(builder: (context, model, _) {
|
|
|
|
108
|
+ if (model.pageStateMyHome != PageState.Success) {
|
|
|
|
109
|
+ return ExceptionPage(
|
|
|
|
110
|
+ pageState: model.pageStateMyHome,
|
|
|
|
111
|
+ callback: () {
|
|
|
|
112
|
+ // getTableList();
|
|
|
|
113
|
+ },
|
|
|
|
114
|
+ emptyMsg: "暂时没有桌位哦",
|
|
|
|
115
|
+ emptyImg: "empty_search",
|
|
|
|
116
|
+ showMsg: "加载中,请稍后...",
|
|
|
|
117
|
+ );
|
|
|
|
118
|
+ } else {
|
|
|
|
119
|
+ return Column(children: [
|
|
|
|
120
|
+ Expanded(
|
|
|
|
121
|
+ child: SingleChildScrollView(
|
|
|
|
122
|
+ controller: _controller,
|
|
|
|
123
|
+ child: Column(
|
|
|
|
124
|
+ children: [
|
|
|
|
125
|
+ Container(
|
|
|
|
126
|
+ color: MyColours.color_ffffff,
|
|
|
|
127
|
+ padding: EdgeInsets.symmetric(
|
|
|
|
128
|
+ vertical: ScreenUtil().setWidth(30)),
|
|
|
|
129
|
+ child: Column(
|
|
|
|
130
|
+ children: [
|
|
|
|
131
|
+ Row(
|
|
|
|
132
|
+ mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
133
|
+ children: [
|
|
|
|
134
|
+ Text(
|
|
|
|
135
|
+ '${customerProvider.guestSunmodel.myCustomer}',
|
|
|
|
136
|
+ style: TextStyle(
|
|
|
|
137
|
+ color: MyColours.color_199095,
|
|
|
|
138
|
+ fontSize: ScreenUtil().setSp(60),
|
|
|
|
139
|
+ fontWeight: FontWeight.bold),
|
|
|
|
140
|
+ ),
|
|
|
|
141
|
+ Text(
|
|
|
|
142
|
+ '位',
|
|
|
|
143
|
+ style: TextStyle(
|
|
|
|
144
|
+ color: MyColours.color_199095,
|
|
|
|
145
|
+ fontWeight: FontWeight.bold,
|
|
|
|
146
|
+ fontSize: ScreenUtil().setSp(30)),
|
|
|
|
147
|
+ )
|
|
|
|
148
|
+ ],
|
|
|
|
149
|
+ ),
|
|
|
|
150
|
+ VEmptyView(10),
|
|
|
|
151
|
+ RoundButton(
|
|
|
|
152
|
+ onPressed: () async {
|
|
|
|
153
|
+ NavigatorUtil.goCustomerListPage(context);
|
|
|
|
154
|
+ },
|
|
|
|
155
|
+ text: '我的客户',
|
|
|
|
156
|
+ fontSize: 24,
|
|
|
|
157
|
+ isBold: false,
|
|
|
|
158
|
+ textColor: MyColours.color_333333,
|
|
|
|
159
|
+ gradientStart: MyColours.color_ffffff,
|
|
|
|
160
|
+ gradientEnd: MyColours.color_ffffff,
|
|
|
|
161
|
+ borderColor: Color.fromRGBO(118, 118, 118, 1),
|
|
|
|
162
|
+ height: ScreenUtil().setWidth(45),
|
|
|
|
163
|
+ width: ScreenUtil().setWidth(160),
|
|
|
|
164
|
+ radius: ScreenUtil().setWidth(30),
|
|
|
|
165
|
+ )
|
|
|
|
166
|
+ ],
|
|
|
|
167
|
+ ),
|
|
|
|
168
|
+ ),
|
|
|
|
169
|
+ VEmptyView(10),
|
|
|
|
170
|
+ // GridView.builder(
|
|
|
|
171
|
+ // controller: _controller,
|
|
|
|
172
|
+ // shrinkWrap: true,
|
|
|
|
173
|
+ // cacheExtent: ScreenUtil().setWidth(0),
|
|
|
|
174
|
+ // itemCount: 3,
|
|
|
|
175
|
+ // gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
|
|
|
176
|
+ // crossAxisCount: 3,
|
|
|
|
177
|
+ // childAspectRatio: 1,
|
|
|
|
178
|
+ // mainAxisSpacing: ScreenUtil().setWidth(10),
|
|
|
|
179
|
+ // crossAxisSpacing: ScreenUtil().setWidth(10)),
|
|
|
|
180
|
+ // itemBuilder: (BuildContext context, int index) {
|
|
|
|
181
|
+ // // locationState = state;
|
|
|
|
182
|
+ // return _percentWidget(
|
|
|
|
183
|
+ // '${customerProvider.guestSunmodel.active.count}',
|
|
|
|
184
|
+ // '活跃客户',
|
|
|
|
185
|
+ // '${customerProvider.guestSunmodel.active.scale}');
|
|
|
|
186
|
+ // }),
|
|
|
|
187
|
+ Row(
|
|
96
|
children: [
|
188
|
children: [
|
|
97
|
- Row(
|
|
|
|
98
|
- mainAxisAlignment: MainAxisAlignment.center,
|
|
|
|
99
|
- children: [
|
|
|
|
100
|
- Text(
|
|
|
|
101
|
- '19',
|
|
|
|
102
|
- style: TextStyle(
|
|
|
|
103
|
- color: MyColours.color_199095,
|
|
|
|
104
|
- fontSize: ScreenUtil().setSp(60),
|
|
|
|
105
|
- fontWeight: FontWeight.bold),
|
|
|
|
106
|
- ),
|
|
|
|
107
|
- Text(
|
|
|
|
108
|
- '位',
|
|
|
|
109
|
- style: TextStyle(
|
|
|
|
110
|
- color: MyColours.color_199095,
|
|
|
|
111
|
- fontWeight: FontWeight.bold,
|
|
|
|
112
|
- fontSize: ScreenUtil().setSp(30)),
|
|
|
|
113
|
- )
|
|
|
|
114
|
- ],
|
|
|
|
115
|
- ),
|
|
|
|
116
|
- VEmptyView(10),
|
|
|
|
117
|
- RoundButton(
|
|
|
|
118
|
- onPressed: () async {
|
|
|
|
119
|
- NavigatorUtil.goCustomerListPage(context);
|
|
|
|
120
|
- },
|
|
|
|
121
|
- text: '我的客户',
|
|
|
|
122
|
- fontSize: 24,
|
|
|
|
123
|
- isBold: false,
|
|
|
|
124
|
- textColor: MyColours.color_333333,
|
|
|
|
125
|
- gradientStart: MyColours.color_ffffff,
|
|
|
|
126
|
- gradientEnd: MyColours.color_ffffff,
|
|
|
|
127
|
- borderColor: Color.fromRGBO(118, 118, 118, 1),
|
|
|
|
128
|
- height: ScreenUtil().setWidth(45),
|
|
|
|
129
|
- width: ScreenUtil().setWidth(160),
|
|
|
|
130
|
- radius: ScreenUtil().setWidth(30),
|
|
|
|
131
|
- )
|
189
|
+ _percentWidget(
|
|
|
|
190
|
+ '${customerProvider.guestSunmodel.active.count}',
|
|
|
|
191
|
+ '活跃客户',
|
|
|
|
192
|
+ '${customerProvider.guestSunmodel.active.scale}'),
|
|
|
|
193
|
+ HEmptyView(10),
|
|
|
|
194
|
+ _percentWidget(
|
|
|
|
195
|
+ '${customerProvider.guestSunmodel.sleep.count}',
|
|
|
|
196
|
+ '沉睡客户',
|
|
|
|
197
|
+ '${customerProvider.guestSunmodel.sleep.scale}'),
|
|
|
|
198
|
+ HEmptyView(10),
|
|
|
|
199
|
+ _percentWidget(
|
|
|
|
200
|
+ '${customerProvider.guestSunmodel.drain.count}',
|
|
|
|
201
|
+ '流失客户',
|
|
|
|
202
|
+ '${customerProvider.guestSunmodel.drain.scale}'),
|
|
132
|
],
|
203
|
],
|
|
133
|
),
|
204
|
),
|
|
134
|
- ),
|
|
|
|
135
|
- VEmptyView(10),
|
|
|
|
136
|
- GridView.builder(
|
|
|
|
137
|
- controller: _controller,
|
|
|
|
138
|
- shrinkWrap: true,
|
|
|
|
139
|
- cacheExtent: ScreenUtil().setWidth(0),
|
|
|
|
140
|
- itemCount: 3,
|
|
|
|
141
|
- gridDelegate: SliverGridDelegateWithFixedCrossAxisCount(
|
|
|
|
142
|
- crossAxisCount: 3,
|
|
|
|
143
|
- childAspectRatio: 1,
|
|
|
|
144
|
- mainAxisSpacing: ScreenUtil().setWidth(10),
|
|
|
|
145
|
- crossAxisSpacing: ScreenUtil().setWidth(10)),
|
|
|
|
146
|
- itemBuilder: (BuildContext context, int index) {
|
|
|
|
147
|
- // locationState = state;
|
|
|
|
148
|
- return _percentWidget('1999', '活跃客户', '39.20');
|
|
|
|
149
|
- }),
|
|
|
|
150
|
- // Row(
|
|
|
|
151
|
- // children: [
|
|
|
|
152
|
- // _percentWidget('19992', '活跃客户', '90.90'),
|
|
|
|
153
|
- // HEmptyView(10),
|
|
|
|
154
|
- // _percentWidget('19992', '沉睡客户', '90.90'),
|
|
|
|
155
|
- // HEmptyView(10),
|
|
|
|
156
|
- // _percentWidget('19992', '流失客户', '5.90'),
|
|
|
|
157
|
- // ],
|
|
|
|
158
|
- // ),
|
205
|
+ ListView.builder(
|
|
|
|
206
|
+ controller: _controller,
|
|
|
|
207
|
+ shrinkWrap: true,
|
|
|
|
208
|
+ cacheExtent: ScreenUtil().setWidth(0),
|
|
|
|
209
|
+ itemCount:
|
|
|
|
210
|
+ customerProvider.guestSunmodel.tips.task.length,
|
|
|
|
211
|
+ itemBuilder: (BuildContext context, int index) {
|
|
|
|
212
|
+ // locationState = state;
|
|
|
|
213
|
+ List<String> data =
|
|
|
|
214
|
+ customerProvider.guestSunmodel.tips.task[index];
|
|
|
|
215
|
+ return Column(
|
|
|
|
216
|
+ children: [
|
|
|
|
217
|
+ VEmptyView(10),
|
|
|
|
218
|
+ Stack(children: [
|
|
|
|
219
|
+ Container(
|
|
|
|
220
|
+ color: MyColours.color_ffffff,
|
|
|
|
221
|
+ padding: EdgeInsets.symmetric(
|
|
|
|
222
|
+ horizontal: ScreenUtil().setWidth(20),
|
|
|
|
223
|
+ vertical: ScreenUtil().setWidth(30)),
|
|
|
|
224
|
+ child: Row(
|
|
|
|
225
|
+ children: [
|
|
|
|
226
|
+ Image.asset(
|
|
|
|
227
|
+ Utils.getImgPath('warning'),
|
|
|
|
228
|
+ width: ScreenUtil().setWidth(42),
|
|
|
|
229
|
+ ),
|
|
|
|
230
|
+ HEmptyView(15),
|
|
|
|
231
|
+ Expanded(
|
|
|
|
232
|
+ child: Column(
|
|
|
|
233
|
+ crossAxisAlignment:
|
|
|
|
234
|
+ CrossAxisAlignment.start,
|
|
|
|
235
|
+ children: [
|
|
|
|
236
|
+ Text(
|
|
|
|
237
|
+ '${data[0]}',
|
|
|
|
238
|
+ maxLines: 1,
|
|
|
|
239
|
+ overflow: TextOverflow.ellipsis,
|
|
|
|
240
|
+ style: TextStyle(
|
|
|
|
241
|
+ color: MyColours.color_333333,
|
|
|
|
242
|
+ fontSize:
|
|
|
|
243
|
+ ScreenUtil().setSp(32)),
|
|
|
|
244
|
+ ),
|
|
|
|
245
|
+ VEmptyView(8),
|
|
|
|
246
|
+ Text(
|
|
|
|
247
|
+ '${data[1]}',
|
|
|
|
248
|
+ maxLines: 1,
|
|
|
|
249
|
+ overflow: TextOverflow.ellipsis,
|
|
|
|
250
|
+ style: TextStyle(
|
|
|
|
251
|
+ color: MyColours.color_333333,
|
|
|
|
252
|
+ fontSize:
|
|
|
|
253
|
+ ScreenUtil().setSp(24)),
|
|
|
|
254
|
+ ),
|
|
|
|
255
|
+ VEmptyView(8),
|
|
|
|
256
|
+ Text(
|
|
|
|
257
|
+ '${data[2]}',
|
|
|
|
258
|
+ maxLines: 1,
|
|
|
|
259
|
+ overflow: TextOverflow.ellipsis,
|
|
|
|
260
|
+ style: TextStyle(
|
|
|
|
261
|
+ color: MyColours.color_333333,
|
|
|
|
262
|
+ fontSize:
|
|
|
|
263
|
+ ScreenUtil().setSp(26)),
|
|
|
|
264
|
+ )
|
|
|
|
265
|
+ ],
|
|
|
|
266
|
+ )),
|
|
|
|
267
|
+ HEmptyView(20),
|
|
|
|
268
|
+ RoundButton(
|
|
|
|
269
|
+ text: '立即完成',
|
|
159
|
|
270
|
|
|
160
|
- ListView.builder(
|
|
|
|
161
|
- controller: _controller,
|
|
|
|
162
|
- shrinkWrap: true,
|
|
|
|
163
|
- cacheExtent: ScreenUtil().setWidth(0),
|
|
|
|
164
|
- itemCount: 20,
|
|
|
|
165
|
- itemBuilder: (BuildContext context, int index) {
|
|
|
|
166
|
- // locationState = state;
|
|
|
|
167
|
- return Column(
|
|
|
|
168
|
- children: [
|
|
|
|
169
|
- VEmptyView(10),
|
|
|
|
170
|
- Container(
|
|
|
|
171
|
- color: MyColours.color_ffffff,
|
|
|
|
172
|
- padding: EdgeInsets.symmetric(
|
|
|
|
173
|
- horizontal: ScreenUtil().setWidth(20),
|
|
|
|
174
|
- vertical: ScreenUtil().setWidth(30)),
|
|
|
|
175
|
- child: Row(
|
|
|
|
176
|
- children: [
|
|
|
|
177
|
- Image.asset(
|
|
|
|
178
|
- Utils.getImgPath('warning'),
|
|
|
|
179
|
- width: ScreenUtil().setWidth(34),
|
271
|
+ padding: EdgeInsets.symmetric(
|
|
|
|
272
|
+ horizontal:
|
|
|
|
273
|
+ ScreenUtil().setWidth(26)),
|
|
|
|
274
|
+ gradientStart: MyColours.color_199095,
|
|
|
|
275
|
+ gradientEnd: MyColours.color_199095,
|
|
|
|
276
|
+ // borderColor: MyColours.color_999999,
|
|
|
|
277
|
+ radius: ScreenUtil().setWidth(40),
|
|
|
|
278
|
+ height: ScreenUtil().setWidth(64),
|
|
|
|
279
|
+ fontSize: 26,
|
|
|
|
280
|
+ isBold: false,
|
|
|
|
281
|
+ onPressed: () {
|
|
|
|
282
|
+ // NavigatorUtil.goEnterStoreEnvironmentPage(context);
|
|
|
|
283
|
+ },
|
|
|
|
284
|
+ ),
|
|
|
|
285
|
+ ],
|
|
180
|
),
|
286
|
),
|
|
181
|
- HEmptyView(10),
|
|
|
|
182
|
- Expanded(
|
|
|
|
183
|
- child: Text(
|
|
|
|
184
|
- '2为顾客马上快递费哈健身房哈尽快发货阿花房间卡都会发觉客服哈空间发哈尽快发货卡上的房间卡上发哈尽快',
|
|
|
|
185
|
- maxLines: 10,
|
|
|
|
186
|
- overflow: TextOverflow.ellipsis,
|
|
|
|
187
|
- style: TextStyle(
|
|
|
|
188
|
- color: MyColours.color_333333,
|
|
|
|
189
|
- fontSize: ScreenUtil().setSp(28)),
|
|
|
|
190
|
- )),
|
|
|
|
191
|
- HEmptyView(30),
|
|
|
|
192
|
- RoundButton(
|
|
|
|
193
|
- text: '立即完成',
|
287
|
+ ),
|
|
|
|
288
|
+ Positioned(
|
|
|
|
289
|
+ bottom: ScreenUtil().setWidth(24),
|
|
|
|
290
|
+ right: ScreenUtil().setWidth(70),
|
|
|
|
291
|
+ child: Text(
|
|
|
|
292
|
+ '${data[3]}',
|
|
|
|
293
|
+ maxLines: 1,
|
|
|
|
294
|
+ overflow: TextOverflow.ellipsis,
|
|
|
|
295
|
+ style: TextStyle(
|
|
|
|
296
|
+ color: Color.fromRGBO(215, 30, 40, 1),
|
|
|
|
297
|
+ fontSize: ScreenUtil().setSp(26)),
|
|
|
|
298
|
+ ))
|
|
|
|
299
|
+ ])
|
|
|
|
300
|
+ ],
|
|
|
|
301
|
+ );
|
|
|
|
302
|
+ }),
|
|
|
|
303
|
+ ListView.builder(
|
|
|
|
304
|
+ controller: _controller,
|
|
|
|
305
|
+ shrinkWrap: true,
|
|
|
|
306
|
+ cacheExtent: ScreenUtil().setWidth(0),
|
|
|
|
307
|
+ itemCount:
|
|
|
|
308
|
+ customerProvider.guestSunmodel.tips.recover.length,
|
|
|
|
309
|
+ itemBuilder: (BuildContext context, int index) {
|
|
|
|
310
|
+ // locationState = state;
|
|
194
|
|
311
|
|
|
195
|
- padding: EdgeInsets.symmetric(
|
|
|
|
196
|
- horizontal: ScreenUtil().setWidth(26)),
|
|
|
|
197
|
- gradientStart: MyColours.color_199095,
|
|
|
|
198
|
- gradientEnd: MyColours.color_199095,
|
|
|
|
199
|
- // borderColor: MyColours.color_999999,
|
|
|
|
200
|
- radius: ScreenUtil().setWidth(40),
|
|
|
|
201
|
- height: ScreenUtil().setWidth(64),
|
|
|
|
202
|
- fontSize: 26,
|
|
|
|
203
|
- isBold: false,
|
|
|
|
204
|
- onPressed: () {
|
|
|
|
205
|
- // NavigatorUtil.goEnterStoreEnvironmentPage(context);
|
|
|
|
206
|
- },
|
|
|
|
207
|
- ),
|
|
|
|
208
|
- ],
|
312
|
+ return Column(
|
|
|
|
313
|
+ children: [
|
|
|
|
314
|
+ VEmptyView(10),
|
|
|
|
315
|
+ Container(
|
|
|
|
316
|
+ color: MyColours.color_ffffff,
|
|
|
|
317
|
+ padding: EdgeInsets.symmetric(
|
|
|
|
318
|
+ horizontal: ScreenUtil().setWidth(20),
|
|
|
|
319
|
+ vertical: ScreenUtil().setWidth(30)),
|
|
|
|
320
|
+ child: Row(
|
|
|
|
321
|
+ children: [
|
|
|
|
322
|
+ Image.asset(
|
|
|
|
323
|
+ Utils.getImgPath('warning'),
|
|
|
|
324
|
+ width: ScreenUtil().setWidth(42),
|
|
|
|
325
|
+ ),
|
|
|
|
326
|
+ HEmptyView(15),
|
|
|
|
327
|
+ Expanded(
|
|
|
|
328
|
+ child: Text(
|
|
|
|
329
|
+ '${customerProvider.guestSunmodel.tips.recover[index]}',
|
|
|
|
330
|
+ maxLines: 10,
|
|
|
|
331
|
+ overflow: TextOverflow.ellipsis,
|
|
|
|
332
|
+ style: TextStyle(
|
|
|
|
333
|
+ color: MyColours.color_333333,
|
|
|
|
334
|
+ fontSize: ScreenUtil().setSp(32)),
|
|
|
|
335
|
+ )),
|
|
|
|
336
|
+ HEmptyView(20),
|
|
|
|
337
|
+ RoundButton(
|
|
|
|
338
|
+ text: '一键追回',
|
|
|
|
339
|
+ padding: EdgeInsets.symmetric(
|
|
|
|
340
|
+ horizontal:
|
|
|
|
341
|
+ ScreenUtil().setWidth(26)),
|
|
|
|
342
|
+ gradientStart: MyColours.color_199095,
|
|
|
|
343
|
+ gradientEnd: MyColours.color_199095,
|
|
|
|
344
|
+ // borderColor: MyColours.color_999999,
|
|
|
|
345
|
+ radius: ScreenUtil().setWidth(40),
|
|
|
|
346
|
+ height: ScreenUtil().setWidth(64),
|
|
|
|
347
|
+ fontSize: 26,
|
|
|
|
348
|
+ isBold: false,
|
|
|
|
349
|
+ onPressed: () {
|
|
|
|
350
|
+ // NavigatorUtil.goEnterStoreEnvironmentPage(context);
|
|
|
|
351
|
+ },
|
|
|
|
352
|
+ ),
|
|
|
|
353
|
+ ],
|
|
|
|
354
|
+ ),
|
|
209
|
),
|
355
|
),
|
|
210
|
- )
|
|
|
|
211
|
- ],
|
|
|
|
212
|
- );
|
|
|
|
213
|
- })
|
|
|
|
214
|
- ],
|
|
|
|
215
|
- ),
|
|
|
|
216
|
- )),
|
|
|
|
217
|
- Padding(
|
|
|
|
218
|
- padding: EdgeInsets.only(bottom: ScreenUtil().setWidth(30)),
|
|
|
|
219
|
- child: RoundButton(
|
|
|
|
220
|
- onPressed: () {
|
|
|
|
221
|
- NavigatorUtil.goMarketingRecordsPage(context);
|
|
|
|
222
|
- },
|
|
|
|
223
|
- text: '营销记录',
|
|
|
|
224
|
- fontSize: 24,
|
|
|
|
225
|
- isBold: false,
|
|
|
|
226
|
- textColor: MyColours.color_199095,
|
|
|
|
227
|
- gradientStart: MyColours.color_ffffff,
|
|
|
|
228
|
- gradientEnd: MyColours.color_ffffff,
|
|
|
|
229
|
- borderColor: MyColours.color_199095,
|
|
|
|
230
|
- height: ScreenUtil().setWidth(75),
|
|
|
|
231
|
- width: ScreenUtil().setWidth(260),
|
|
|
|
232
|
- radius: ScreenUtil().setWidth(10),
|
|
|
|
233
|
- // image: Utils.getImgPath('add_area')
|
|
|
|
234
|
- ),
|
|
|
|
235
|
- )
|
|
|
|
236
|
- ])),
|
|
|
|
237
|
- );
|
356
|
+ ],
|
|
|
|
357
|
+ );
|
|
|
|
358
|
+ }),
|
|
|
|
359
|
+ ListView.builder(
|
|
|
|
360
|
+ controller: _controller,
|
|
|
|
361
|
+ shrinkWrap: true,
|
|
|
|
362
|
+ cacheExtent: ScreenUtil().setWidth(0),
|
|
|
|
363
|
+ itemCount:
|
|
|
|
364
|
+ customerProvider.guestSunmodel.tips.recover.length,
|
|
|
|
365
|
+ itemBuilder: (BuildContext context, int index) {
|
|
|
|
366
|
+ // locationState = state;
|
|
|
|
367
|
+
|
|
|
|
368
|
+ return Column(
|
|
|
|
369
|
+ children: [
|
|
|
|
370
|
+ VEmptyView(10),
|
|
|
|
371
|
+ Container(
|
|
|
|
372
|
+ color: MyColours.color_ffffff,
|
|
|
|
373
|
+ padding: EdgeInsets.symmetric(
|
|
|
|
374
|
+ horizontal: ScreenUtil().setWidth(20),
|
|
|
|
375
|
+ vertical: ScreenUtil().setWidth(30)),
|
|
|
|
376
|
+ child: Row(
|
|
|
|
377
|
+ children: [
|
|
|
|
378
|
+ Image.asset(
|
|
|
|
379
|
+ Utils.getImgPath('warning'),
|
|
|
|
380
|
+ width: ScreenUtil().setWidth(42),
|
|
|
|
381
|
+ ),
|
|
|
|
382
|
+ HEmptyView(15),
|
|
|
|
383
|
+ Expanded(
|
|
|
|
384
|
+ child: Text(
|
|
|
|
385
|
+ '${customerProvider.guestSunmodel.tips.awaken[index]}',
|
|
|
|
386
|
+ maxLines: 10,
|
|
|
|
387
|
+ overflow: TextOverflow.ellipsis,
|
|
|
|
388
|
+ style: TextStyle(
|
|
|
|
389
|
+ color: MyColours.color_333333,
|
|
|
|
390
|
+ fontSize: ScreenUtil().setSp(32)),
|
|
|
|
391
|
+ )),
|
|
|
|
392
|
+ HEmptyView(20),
|
|
|
|
393
|
+ RoundButton(
|
|
|
|
394
|
+ text: '一键唤醒',
|
|
|
|
395
|
+ padding: EdgeInsets.symmetric(
|
|
|
|
396
|
+ horizontal:
|
|
|
|
397
|
+ ScreenUtil().setWidth(26)),
|
|
|
|
398
|
+ gradientStart: MyColours.color_199095,
|
|
|
|
399
|
+ gradientEnd: MyColours.color_199095,
|
|
|
|
400
|
+ // borderColor: MyColours.color_999999,
|
|
|
|
401
|
+ radius: ScreenUtil().setWidth(40),
|
|
|
|
402
|
+ height: ScreenUtil().setWidth(64),
|
|
|
|
403
|
+ fontSize: 26,
|
|
|
|
404
|
+ isBold: false,
|
|
|
|
405
|
+ onPressed: () {
|
|
|
|
406
|
+ // NavigatorUtil.goEnterStoreEnvironmentPage(context);
|
|
|
|
407
|
+ },
|
|
|
|
408
|
+ ),
|
|
|
|
409
|
+ ],
|
|
|
|
410
|
+ ),
|
|
|
|
411
|
+ ),
|
|
|
|
412
|
+ ],
|
|
|
|
413
|
+ );
|
|
|
|
414
|
+ })
|
|
|
|
415
|
+ ],
|
|
|
|
416
|
+ ),
|
|
|
|
417
|
+ )),
|
|
|
|
418
|
+ Padding(
|
|
|
|
419
|
+ padding: EdgeInsets.only(bottom: ScreenUtil().setWidth(30)),
|
|
|
|
420
|
+ child: RoundButton(
|
|
|
|
421
|
+ onPressed: () {
|
|
|
|
422
|
+ NavigatorUtil.goMarketingRecordsPage(context);
|
|
|
|
423
|
+ },
|
|
|
|
424
|
+ text: '营销记录',
|
|
|
|
425
|
+ fontSize: 24,
|
|
|
|
426
|
+ isBold: false,
|
|
|
|
427
|
+ textColor: MyColours.color_199095,
|
|
|
|
428
|
+ gradientStart: MyColours.color_ffffff,
|
|
|
|
429
|
+ gradientEnd: MyColours.color_ffffff,
|
|
|
|
430
|
+ borderColor: MyColours.color_199095,
|
|
|
|
431
|
+ height: ScreenUtil().setWidth(75),
|
|
|
|
432
|
+ width: ScreenUtil().setWidth(260),
|
|
|
|
433
|
+ radius: ScreenUtil().setWidth(10),
|
|
|
|
434
|
+ // image: Utils.getImgPath('add_area')
|
|
|
|
435
|
+ ),
|
|
|
|
436
|
+ )
|
|
|
|
437
|
+ ]);
|
|
|
|
438
|
+ }
|
|
|
|
439
|
+ })));
|
|
238
|
}
|
440
|
}
|
|
239
|
} |
441
|
} |