Commit 86acdff252dece54937b4f2bcf23ac12ba28fea2

Authored by wdn127929
1 parent a7734a57

菜单管理图片尺寸调整

@@ -149,6 +149,9 @@ class Cookbooklist extends Object { @@ -149,6 +149,9 @@ class Cookbooklist extends Object {
149 @JsonKey(name: 'num') 149 @JsonKey(name: 'num')
150 String number; 150 String number;
151 151
  152 + @JsonKey(name: 'practice_name')
  153 + String practiceName;
  154 +
152 Cookbooklist( 155 Cookbooklist(
153 this.id, 156 this.id,
154 this.orderid, 157 this.orderid,
@@ -167,6 +170,7 @@ class Cookbooklist extends Object { @@ -167,6 +170,7 @@ class Cookbooklist extends Object {
167 this.identity, 170 this.identity,
168 this.cdate, 171 this.cdate,
169 this.number, 172 this.number,
  173 + this.practiceName
170 ); 174 );
171 175
172 factory Cookbooklist.fromJson(Map<String, dynamic> srcJson) => 176 factory Cookbooklist.fromJson(Map<String, dynamic> srcJson) =>
@@ -85,7 +85,8 @@ Cookbooklist _$CookbooklistFromJson(Map<String, dynamic> json) { @@ -85,7 +85,8 @@ Cookbooklist _$CookbooklistFromJson(Map<String, dynamic> json) {
85 json['status'] as String, 85 json['status'] as String,
86 json['identity'] as String, 86 json['identity'] as String,
87 json['cdate'] as String, 87 json['cdate'] as String,
88 - json['num'] as String); 88 + json['num'] as String,
  89 + json['practice_name'] as String);
89 } 90 }
90 91
91 Map<String, dynamic> _$CookbooklistToJson(Cookbooklist instance) => 92 Map<String, dynamic> _$CookbooklistToJson(Cookbooklist instance) =>
@@ -106,7 +107,8 @@ Map<String, dynamic> _$CookbooklistToJson(Cookbooklist instance) => @@ -106,7 +107,8 @@ Map<String, dynamic> _$CookbooklistToJson(Cookbooklist instance) =>
106 'status': instance.status, 107 'status': instance.status,
107 'identity': instance.identity, 108 'identity': instance.identity,
108 'cdate': instance.cdate, 109 'cdate': instance.cdate,
109 - 'num': instance.number 110 + 'num': instance.number,
  111 + 'practice_name':instance.practiceName
110 }; 112 };
111 113
112 Seller _$SellerFromJson(Map<String, dynamic> json) { 114 Seller _$SellerFromJson(Map<String, dynamic> json) {
@@ -296,9 +296,22 @@ class _MessageHasOrderFoodPageState extends State<MessageHasOrderFoodPage> { @@ -296,9 +296,22 @@ class _MessageHasOrderFoodPageState extends State<MessageHasOrderFoodPage> {
296 width: ScreenUtil().setWidth(150 * 2), 296 width: ScreenUtil().setWidth(150 * 2),
297 child: Text( 297 child: Text(
298 _orderFoodProvider 298 _orderFoodProvider
299 - .orderList[i][_orderFoodProvider  
300 - .orderList[i].keys.first][index]  
301 - .cookname, 299 + .orderList[i][
  300 + _orderFoodProvider
  301 + .orderList[i]
  302 + .keys
  303 + .first][index]
  304 + .cookname +
  305 + (_orderFoodProvider
  306 + .orderList[i][
  307 + _orderFoodProvider
  308 + .orderList[i]
  309 + .keys
  310 + .first][index]
  311 + .practiceName ==
  312 + null
  313 + ? ''
  314 + : "(${_orderFoodProvider.orderList[i][_orderFoodProvider.orderList[i].keys.first][index].practiceName})"),
302 style: TextStyle( 315 style: TextStyle(
303 color: MyColours.color_333333, 316 color: MyColours.color_333333,
304 fontSize: ScreenUtil().setWidth(30)), 317 fontSize: ScreenUtil().setWidth(30)),
@@ -110,7 +110,8 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -110,7 +110,8 @@ class _MenuManagePageState extends State<MenuManagePage> {
110 } 110 }
111 111
112 _getDzSellerConf() async { 112 _getDzSellerConf() async {
113 - bool success = await menuManageProvider.getDzSellerConf(context,showLoading: false); 113 + bool success =
  114 + await menuManageProvider.getDzSellerConf(context, showLoading: false);
114 if (success) { 115 if (success) {
115 themeColerModel1 = themeColorData[menuManageProvider 116 themeColerModel1 = themeColorData[menuManageProvider
116 .dzSellerConfModel.cookStyle == 117 .dzSellerConfModel.cookStyle ==
@@ -244,17 +245,19 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -244,17 +245,19 @@ class _MenuManagePageState extends State<MenuManagePage> {
244 Text( 245 Text(
245 model.name, 246 model.name,
246 style: TextStyle( 247 style: TextStyle(
247 - fontWeight: FontWeight.bold,  
248 - fontSize: font(20),  
249 - color: themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD,  
250 - // shadows: [  
251 - // BoxShadow(  
252 - // color: MyColours.color_FBF6F1,  
253 - // offset: Offset(0, 1),  
254 - // blurRadius: w(2),  
255 - // spreadRadius: w(20))  
256 - // ]  
257 - ), 248 + fontWeight: FontWeight.bold,
  249 + fontSize: font(20),
  250 + color: themeColerModel1.name == '珍珠白'
  251 + ? MyColours.color_515151
  252 + : MyColours.color_F8F9FD,
  253 + // shadows: [
  254 + // BoxShadow(
  255 + // color: MyColours.color_FBF6F1,
  256 + // offset: Offset(0, 1),
  257 + // blurRadius: w(2),
  258 + // spreadRadius: w(20))
  259 + // ]
  260 + ),
258 ), 261 ),
259 if ((model.taste != null && 262 if ((model.taste != null &&
260 model.taste != '' && 263 model.taste != '' &&
@@ -281,37 +284,43 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -281,37 +284,43 @@ class _MenuManagePageState extends State<MenuManagePage> {
281 ? '味型:${model.taste} 烹调:${model.cooks}' 284 ? '味型:${model.taste} 烹调:${model.cooks}'
282 : '', 285 : '',
283 style: TextStyle( 286 style: TextStyle(
284 - fontWeight: FontWeight.bold,  
285 - fontSize: font(12),  
286 - color: themeColerModel1.name == '珍珠白' ? MyColours.color_515151 :MyColours.color_F8F9FD,  
287 - // shadows: [  
288 - // BoxShadow(  
289 - // color: MyColours.color_FBF6F1,  
290 - // offset: Offset(0, 1),  
291 - // blurRadius: w(2),  
292 - // spreadRadius: w(20))  
293 - // ]  
294 - )), 287 + fontWeight: FontWeight.bold,
  288 + fontSize: font(12),
  289 + color: themeColerModel1.name == '珍珠白'
  290 + ? MyColours.color_515151
  291 + : MyColours.color_F8F9FD,
  292 + // shadows: [
  293 + // BoxShadow(
  294 + // color: MyColours.color_FBF6F1,
  295 + // offset: Offset(0, 1),
  296 + // blurRadius: w(2),
  297 + // spreadRadius: w(20))
  298 + // ]
  299 + )),
295 VEmptyView(20), 300 VEmptyView(20),
296 model.spec != null 301 model.spec != null
297 ? Column( 302 ? Column(
298 crossAxisAlignment: CrossAxisAlignment.start, 303 crossAxisAlignment: CrossAxisAlignment.start,
299 children: _priceWidget(model)) 304 children: _priceWidget(model))
300 : Text( 305 : Text(
301 - '¥${model.price}/${model.unit} 会员 ¥${model.price}/${model.unit} ', 306 + model.member_price == '0' || model.member_price == null
  307 + ? '¥${model.price}/${model.unit}'
  308 + : '¥${model.price}/${model.unit} 会员 ¥${model.member_price}/${model.unit} ',
302 textAlign: TextAlign.right, 309 textAlign: TextAlign.right,
303 style: TextStyle( 310 style: TextStyle(
304 - fontWeight: FontWeight.bold,  
305 - fontSize: font(14),  
306 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD,  
307 - // shadows: [  
308 - // BoxShadow(  
309 - // color: MyColours.color_FBF6F1,  
310 - // offset: Offset(0, 1),  
311 - // blurRadius: w(2),  
312 - // spreadRadius: w(20))  
313 - // ]  
314 - ), 311 + fontWeight: FontWeight.bold,
  312 + fontSize: font(14),
  313 + color: themeColerModel1.name == '珍珠白'
  314 + ? MyColours.color_515151
  315 + : MyColours.color_F8F9FD,
  316 + // shadows: [
  317 + // BoxShadow(
  318 + // color: MyColours.color_FBF6F1,
  319 + // offset: Offset(0, 1),
  320 + // blurRadius: w(2),
  321 + // spreadRadius: w(20))
  322 + // ]
  323 + ),
315 ), 324 ),
316 ], 325 ],
317 ), 326 ),
@@ -333,20 +342,24 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -333,20 +342,24 @@ class _MenuManagePageState extends State<MenuManagePage> {
333 tempPrice.forEach((element) { 342 tempPrice.forEach((element) {
334 textWidgetList.add( 343 textWidgetList.add(
335 Text( 344 Text(
336 - '¥${element.price}/${element.specs} 会员 ¥${element.memberPrice ?? ''}/${element.specs} ', 345 + element.memberPrice == '0' || element.memberPrice == null
  346 + ? '¥${element.price}/${element.specs}'
  347 + : '¥${element.price}/${element.specs} 会员 ¥${element.memberPrice ?? ''}/${element.specs} ',
337 textAlign: TextAlign.right, 348 textAlign: TextAlign.right,
338 style: TextStyle( 349 style: TextStyle(
339 - fontWeight: FontWeight.bold,  
340 - fontSize: font(14),  
341 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD,  
342 - // shadows: [  
343 - // BoxShadow(  
344 - // color: MyColours.color_FBF6F1,  
345 - // offset: Offset(0, 1),  
346 - // blurRadius: w(2),  
347 - // spreadRadius: w(20))  
348 - // ]  
349 - ), 350 + fontWeight: FontWeight.bold,
  351 + fontSize: font(14),
  352 + color: themeColerModel1.name == '珍珠白'
  353 + ? MyColours.color_515151
  354 + : MyColours.color_F8F9FD,
  355 + // shadows: [
  356 + // BoxShadow(
  357 + // color: MyColours.color_FBF6F1,
  358 + // offset: Offset(0, 1),
  359 + // blurRadius: w(2),
  360 + // spreadRadius: w(20))
  361 + // ]
  362 + ),
350 ), 363 ),
351 ); 364 );
352 }); 365 });
@@ -362,17 +375,19 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -362,17 +375,19 @@ class _MenuManagePageState extends State<MenuManagePage> {
362 Text( 375 Text(
363 model.name, 376 model.name,
364 style: TextStyle( 377 style: TextStyle(
365 - fontWeight: FontWeight.bold,  
366 - fontSize: font(20),  
367 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD,  
368 - // shadows: [  
369 - // BoxShadow(  
370 - // color: MyColours.color_FBF6F1,  
371 - // offset: Offset(0, 1),  
372 - // blurRadius: w(2),  
373 - // spreadRadius: w(20))  
374 - // ]  
375 - ), 378 + fontWeight: FontWeight.bold,
  379 + fontSize: font(20),
  380 + color: themeColerModel1.name == '珍珠白'
  381 + ? MyColours.color_515151
  382 + : MyColours.color_F8F9FD,
  383 + // shadows: [
  384 + // BoxShadow(
  385 + // color: MyColours.color_FBF6F1,
  386 + // offset: Offset(0, 1),
  387 + // blurRadius: w(2),
  388 + // spreadRadius: w(20))
  389 + // ]
  390 + ),
376 ), 391 ),
377 if ((model.taste != null && 392 if ((model.taste != null &&
378 model.taste != '' && 393 model.taste != '' &&
@@ -401,7 +416,9 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -401,7 +416,9 @@ class _MenuManagePageState extends State<MenuManagePage> {
401 style: TextStyle( 416 style: TextStyle(
402 fontWeight: FontWeight.bold, 417 fontWeight: FontWeight.bold,
403 fontSize: font(12), 418 fontSize: font(12),
404 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 :MyColours.color_F8F9FD 419 + color: themeColerModel1.name == '珍珠白'
  420 + ? MyColours.color_515151
  421 + : MyColours.color_F8F9FD
405 // shadows: [ 422 // shadows: [
406 // BoxShadow( 423 // BoxShadow(
407 // color: MyColours.color_FBF6F1, 424 // color: MyColours.color_FBF6F1,
@@ -416,12 +433,16 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -416,12 +433,16 @@ class _MenuManagePageState extends State<MenuManagePage> {
416 crossAxisAlignment: CrossAxisAlignment.start, 433 crossAxisAlignment: CrossAxisAlignment.start,
417 children: _priceWidget(model)) 434 children: _priceWidget(model))
418 : Text( 435 : Text(
419 - '¥${model.price}/${model.unit} 会员 ¥${model.member_price ?? ''}/${model.unit} ', 436 + model.member_price == '0' || model.member_price == null
  437 + ? '¥${model.price}/${model.unit}'
  438 + : '¥${model.price}/${model.unit} 会员 ¥${model.member_price ?? ''}/${model.unit} ',
420 textAlign: TextAlign.right, 439 textAlign: TextAlign.right,
421 style: TextStyle( 440 style: TextStyle(
422 fontWeight: FontWeight.bold, 441 fontWeight: FontWeight.bold,
423 fontSize: font(14), 442 fontSize: font(14),
424 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD 443 + color: themeColerModel1.name == '珍珠白'
  444 + ? MyColours.color_515151
  445 + : MyColours.color_F8F9FD
425 // shadows: [ 446 // shadows: [
426 // BoxShadow( 447 // BoxShadow(
427 // color: MyColours.color_FBF6F1, 448 // color: MyColours.color_FBF6F1,
@@ -451,17 +472,19 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -451,17 +472,19 @@ class _MenuManagePageState extends State<MenuManagePage> {
451 Text( 472 Text(
452 model.name, 473 model.name,
453 style: TextStyle( 474 style: TextStyle(
454 - fontWeight: FontWeight.bold,  
455 - fontSize: font(20),  
456 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD,  
457 - // shadows: [  
458 - // BoxShadow(  
459 - // color: MyColours.color_FBF6F1,  
460 - // offset: Offset(0, 1),  
461 - // blurRadius: w(2),  
462 - // spreadRadius: w(20))  
463 - // ]  
464 - ), 475 + fontWeight: FontWeight.bold,
  476 + fontSize: font(20),
  477 + color: themeColerModel1.name == '珍珠白'
  478 + ? MyColours.color_515151
  479 + : MyColours.color_F8F9FD,
  480 + // shadows: [
  481 + // BoxShadow(
  482 + // color: MyColours.color_FBF6F1,
  483 + // offset: Offset(0, 1),
  484 + // blurRadius: w(2),
  485 + // spreadRadius: w(20))
  486 + // ]
  487 + ),
465 ), 488 ),
466 if ((model.taste != null && 489 if ((model.taste != null &&
467 model.taste != '' && 490 model.taste != '' &&
@@ -488,17 +511,19 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -488,17 +511,19 @@ class _MenuManagePageState extends State<MenuManagePage> {
488 ? '味型:${model.taste} 烹调:${model.cooks}' 511 ? '味型:${model.taste} 烹调:${model.cooks}'
489 : '', 512 : '',
490 style: TextStyle( 513 style: TextStyle(
491 - fontWeight: FontWeight.bold,  
492 - fontSize: font(12),  
493 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD,  
494 - // shadows: [  
495 - // BoxShadow(  
496 - // color: MyColours.color_FBF6F1,  
497 - // offset: Offset(0, 1),  
498 - // blurRadius: w(2),  
499 - // spreadRadius: w(20))  
500 - // ]  
501 - )) 514 + fontWeight: FontWeight.bold,
  515 + fontSize: font(12),
  516 + color: themeColerModel1.name == '珍珠白'
  517 + ? MyColours.color_515151
  518 + : MyColours.color_F8F9FD,
  519 + // shadows: [
  520 + // BoxShadow(
  521 + // color: MyColours.color_FBF6F1,
  522 + // offset: Offset(0, 1),
  523 + // blurRadius: w(2),
  524 + // spreadRadius: w(20))
  525 + // ]
  526 + ))
502 ], 527 ],
503 ), 528 ),
504 )), 529 )),
@@ -508,20 +533,24 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -508,20 +533,24 @@ class _MenuManagePageState extends State<MenuManagePage> {
508 crossAxisAlignment: CrossAxisAlignment.start, 533 crossAxisAlignment: CrossAxisAlignment.start,
509 children: _priceWidget(model)) 534 children: _priceWidget(model))
510 : Text( 535 : Text(
511 - '¥${model.price}/${model.unit} 会员 ¥${model.price}/${model.unit} ', 536 + model.member_price == '0' || model.member_price == null
  537 + ? '¥${model.price}/${model.unit}'
  538 + : '¥${model.price}/${model.unit} 会员 ¥${model.member_price}/${model.unit} ',
512 textAlign: TextAlign.right, 539 textAlign: TextAlign.right,
513 style: TextStyle( 540 style: TextStyle(
514 - fontWeight: FontWeight.bold,  
515 - fontSize: font(14),  
516 - color: themeColerModel1.name == '珍珠白' ? MyColours.color_515151 :MyColours.color_F8F9FD,  
517 - // shadows: [  
518 - // BoxShadow(  
519 - // color: MyColours.color_FBF6F1,  
520 - // offset: Offset(0, 1),  
521 - // blurRadius: w(2),  
522 - // spreadRadius: w(20))  
523 - // ]  
524 - ), 541 + fontWeight: FontWeight.bold,
  542 + fontSize: font(14),
  543 + color: themeColerModel1.name == '珍珠白'
  544 + ? MyColours.color_515151
  545 + : MyColours.color_F8F9FD,
  546 + // shadows: [
  547 + // BoxShadow(
  548 + // color: MyColours.color_FBF6F1,
  549 + // offset: Offset(0, 1),
  550 + // blurRadius: w(2),
  551 + // spreadRadius: w(20))
  552 + // ]
  553 + ),
525 ), 554 ),
526 ], 555 ],
527 ); 556 );
@@ -540,17 +569,19 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -540,17 +569,19 @@ class _MenuManagePageState extends State<MenuManagePage> {
540 child: Text( 569 child: Text(
541 model.name, 570 model.name,
542 style: TextStyle( 571 style: TextStyle(
543 - fontWeight: FontWeight.bold,  
544 - fontSize: font(20),  
545 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD,  
546 - // shadows: [  
547 - // BoxShadow(  
548 - // color: MyColours.color_FBF6F1,  
549 - // offset: Offset(0, 1),  
550 - // blurRadius: w(2),  
551 - // spreadRadius: w(20))  
552 - // ]  
553 - ), 572 + fontWeight: FontWeight.bold,
  573 + fontSize: font(20),
  574 + color: themeColerModel1.name == '珍珠白'
  575 + ? MyColours.color_515151
  576 + : MyColours.color_F8F9FD,
  577 + // shadows: [
  578 + // BoxShadow(
  579 + // color: MyColours.color_FBF6F1,
  580 + // offset: Offset(0, 1),
  581 + // blurRadius: w(2),
  582 + // spreadRadius: w(20))
  583 + // ]
  584 + ),
554 )), 585 )),
555 if ((model.taste != null && 586 if ((model.taste != null &&
556 model.taste != '' && 587 model.taste != '' &&
@@ -579,17 +610,19 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -579,17 +610,19 @@ class _MenuManagePageState extends State<MenuManagePage> {
579 ? '味型:${model.taste} 烹调:${model.cooks}' 610 ? '味型:${model.taste} 烹调:${model.cooks}'
580 : '', 611 : '',
581 style: TextStyle( 612 style: TextStyle(
582 - fontWeight: FontWeight.bold,  
583 - fontSize: font(12),  
584 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD,  
585 - // shadows: [  
586 - // BoxShadow(  
587 - // color: MyColours.color_FBF6F1,  
588 - // offset: Offset(0, 1),  
589 - // blurRadius: w(2),  
590 - // spreadRadius: w(20))  
591 - // ]  
592 - ), 613 + fontWeight: FontWeight.bold,
  614 + fontSize: font(12),
  615 + color: themeColerModel1.name == '珍珠白'
  616 + ? MyColours.color_515151
  617 + : MyColours.color_F8F9FD,
  618 + // shadows: [
  619 + // BoxShadow(
  620 + // color: MyColours.color_FBF6F1,
  621 + // offset: Offset(0, 1),
  622 + // blurRadius: w(2),
  623 + // spreadRadius: w(20))
  624 + // ]
  625 + ),
593 )), 626 )),
594 VEmptyView(20), 627 VEmptyView(20),
595 Padding( 628 Padding(
@@ -599,29 +632,41 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -599,29 +632,41 @@ class _MenuManagePageState extends State<MenuManagePage> {
599 crossAxisAlignment: CrossAxisAlignment.start, 632 crossAxisAlignment: CrossAxisAlignment.start,
600 children: _priceWidget(model)) 633 children: _priceWidget(model))
601 : Text( 634 : Text(
602 - '¥${model.price}/${model.unit} 会员 ¥${model.member_price}/${model.unit} ', 635 + model.member_price == '0' || model.member_price == null
  636 + ? '¥${model.price}/${model.unit}'
  637 + : '¥${model.price}/${model.unit} 会员 ¥${model.member_price}/${model.unit} ',
603 textAlign: TextAlign.right, 638 textAlign: TextAlign.right,
604 style: TextStyle( 639 style: TextStyle(
605 - fontWeight: FontWeight.bold,  
606 - fontSize: font(14),  
607 - color:themeColerModel1.name == '珍珠白' ? MyColours.color_515151 : MyColours.color_F8F9FD,  
608 - // shadows: [  
609 - // BoxShadow(  
610 - // color: MyColours.color_FBF6F1,  
611 - // offset: Offset(0, 1),  
612 - // blurRadius: w(2),  
613 - // spreadRadius: w(20))  
614 - // ]  
615 - ), 640 + fontWeight: FontWeight.bold,
  641 + fontSize: font(14),
  642 + color: themeColerModel1.name == '珍珠白'
  643 + ? MyColours.color_515151
  644 + : MyColours.color_F8F9FD,
  645 + // shadows: [
  646 + // BoxShadow(
  647 + // color: MyColours.color_FBF6F1,
  648 + // offset: Offset(0, 1),
  649 + // blurRadius: w(2),
  650 + // spreadRadius: w(20))
  651 + // ]
  652 + ),
616 )), 653 )),
617 VEmptyView(30), 654 VEmptyView(30),
618 if (model.image != null) 655 if (model.image != null)
619 - CachedNetworkImage(  
620 - imageUrl: model.image,  
621 - fit: BoxFit.cover,  
622 - width: ScreenUtil().screenWidth / 2,  
623 - height: w(125),  
624 - ), 656 + Container(
  657 + constraints: BoxConstraints(
  658 + maxHeight: ScreenUtil().screenWidth / 2,
  659 + ),
  660 + child: CachedNetworkImage(
  661 + imageUrl: model.image,
  662 + fit: BoxFit.contain,
  663 + // width: double.infinity,
  664 + // height: w(250),
  665 + height: ScreenUtil().screenWidth / 2,
  666 + // fit: BoxFit.cover,
  667 + width: ScreenUtil().screenWidth / 2,
  668 + // height: w(125),
  669 + )),
625 if (model.desc != null && model.desc != '') 670 if (model.desc != null && model.desc != '')
626 Padding( 671 Padding(
627 padding: EdgeInsets.symmetric(horizontal: w(10), vertical: w(10)), 672 padding: EdgeInsets.symmetric(horizontal: w(10), vertical: w(10)),
@@ -1012,12 +1057,24 @@ class _MenuManagePageState extends State<MenuManagePage> { @@ -1012,12 +1057,24 @@ class _MenuManagePageState extends State<MenuManagePage> {
1012 : _topLeft( 1057 : _topLeft(
1013 model)), 1058 model)),
1014 if (model.image != null) 1059 if (model.image != null)
1015 - CachedNetworkImage(  
1016 - imageUrl: model.image,  
1017 - fit: BoxFit.cover,  
1018 - width: double.infinity,  
1019 - height: w(250),  
1020 - ), 1060 + Container(
  1061 + constraints:
  1062 + BoxConstraints(
  1063 + maxHeight:
  1064 + ScreenUtil()
  1065 + .screenWidth,
  1066 + ),
  1067 + child:
  1068 + CachedNetworkImage(
  1069 + imageUrl:
  1070 + model.image,
  1071 + fit: BoxFit.contain,
  1072 + width:
  1073 + double.infinity,
  1074 + // height: w(250),
  1075 + // height: ScreenUtil()
  1076 + // .screenWidth,
  1077 + )),
1021 if (model.desc != null && 1078 if (model.desc != null &&
1022 model.desc != '') 1079 model.desc != '')
1023 Align( 1080 Align(
@@ -311,7 +311,7 @@ class _MenuSetPricePageState extends State<MenuSetPricePage> { @@ -311,7 +311,7 @@ class _MenuSetPricePageState extends State<MenuSetPricePage> {
311 311
312 Map object = 312 Map object =
313 await NavigatorUtil.goMenuUnitPage( 313 await NavigatorUtil.goMenuUnitPage(
314 - context, data[index].specid,specids); 314 + context, data[index].specid, specids);
315 if (object != null) { 315 if (object != null) {
316 // 'specs': menuManageProvider 316 // 'specs': menuManageProvider
317 // .specSunModel[index].name, 317 // .specSunModel[index].name,
@@ -374,7 +374,10 @@ class _MenuSetPricePageState extends State<MenuSetPricePage> { @@ -374,7 +374,10 @@ class _MenuSetPricePageState extends State<MenuSetPricePage> {
374 onPressed: () { 374 onPressed: () {
375 data.forEach((element) { 375 data.forEach((element) {
376 element.price = element.priceC.text; 376 element.price = element.priceC.text;
377 - element.memberPrice = element.memberPriceC.text; 377 + element.memberPrice =
  378 + element.memberPriceC.text.trim().length == 0
  379 + ? null
  380 + : element.memberPriceC.text.trim();
378 }); 381 });
379 bool isContains = data.any((element) => element.select); 382 bool isContains = data.any((element) => element.select);
380 if (!isContains) { 383 if (!isContains) {
@@ -361,7 +361,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> { @@ -361,7 +361,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> {
361 crossAxisAlignment: CrossAxisAlignment.start, 361 crossAxisAlignment: CrossAxisAlignment.start,
362 children: _priceWidget(model)) 362 children: _priceWidget(model))
363 : Text( 363 : Text(
364 - '¥${model.price}/${model.unit} 会员 ¥${model.price}/${model.unit} ', 364 + model.member_price == '0' || model.member_price == null
  365 + ? '¥${model.price}/${model.unit}'
  366 + : '¥${model.price}/${model.unit} 会员 ¥${model.member_price}/${model.unit} ',
365 textAlign: TextAlign.right, 367 textAlign: TextAlign.right,
366 style: TextStyle( 368 style: TextStyle(
367 fontWeight: FontWeight.bold, 369 fontWeight: FontWeight.bold,
@@ -398,7 +400,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> { @@ -398,7 +400,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> {
398 tempPrice.forEach((element) { 400 tempPrice.forEach((element) {
399 textWidgetList.add( 401 textWidgetList.add(
400 Text( 402 Text(
401 - '¥${element.price}/${element.specs} 会员 ¥${element.memberPrice ?? ''}/${element.specs} ', 403 + element.memberPrice == '0' || element.memberPrice == null
  404 + ? '¥${element.price}/${element.specs}'
  405 + : '¥${element.price}/${element.specs} 会员 ¥${element.memberPrice ?? ''}/${element.specs} ',
402 textAlign: TextAlign.right, 406 textAlign: TextAlign.right,
403 style: TextStyle( 407 style: TextStyle(
404 fontWeight: FontWeight.bold, 408 fontWeight: FontWeight.bold,
@@ -487,7 +491,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> { @@ -487,7 +491,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> {
487 crossAxisAlignment: CrossAxisAlignment.start, 491 crossAxisAlignment: CrossAxisAlignment.start,
488 children: _priceWidget(model)) 492 children: _priceWidget(model))
489 : Text( 493 : Text(
490 - '¥${model.price}/${model.unit} 会员 ¥${model.member_price ?? ''}/${model.unit} ', 494 + model.member_price == '0' || model.member_price == null
  495 + ? '¥${model.price}/${model.unit}'
  496 + : '¥${model.price}/${model.unit} 会员 ¥${model.member_price ?? ''}/${model.unit} ',
491 textAlign: TextAlign.right, 497 textAlign: TextAlign.right,
492 style: TextStyle( 498 style: TextStyle(
493 fontWeight: FontWeight.bold, 499 fontWeight: FontWeight.bold,
@@ -585,7 +591,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> { @@ -585,7 +591,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> {
585 crossAxisAlignment: CrossAxisAlignment.start, 591 crossAxisAlignment: CrossAxisAlignment.start,
586 children: _priceWidget(model)) 592 children: _priceWidget(model))
587 : Text( 593 : Text(
588 - '¥${model.price}/${model.unit} 会员 ¥${model.price}/${model.unit} ', 594 + model.member_price == '0' || model.member_price == null
  595 + ? '¥${model.price}/${model.unit}'
  596 + : '¥${model.price}/${model.unit} 会员 ¥${model.member_price}/${model.unit} ',
589 textAlign: TextAlign.right, 597 textAlign: TextAlign.right,
590 style: TextStyle( 598 style: TextStyle(
591 fontWeight: FontWeight.bold, 599 fontWeight: FontWeight.bold,
@@ -682,7 +690,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> { @@ -682,7 +690,9 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> {
682 crossAxisAlignment: CrossAxisAlignment.start, 690 crossAxisAlignment: CrossAxisAlignment.start,
683 children: _priceWidget(model)) 691 children: _priceWidget(model))
684 : Text( 692 : Text(
685 - '¥${model.price}/${model.unit} 会员 ¥${model.member_price}/${model.unit} ', 693 + model.member_price == '0' || model.member_price == null
  694 + ? '¥${model.price}/${model.unit}'
  695 + : '¥${model.price}/${model.unit} 会员 ¥${model.member_price}/${model.unit} ',
686 textAlign: TextAlign.right, 696 textAlign: TextAlign.right,
687 style: TextStyle( 697 style: TextStyle(
688 fontWeight: FontWeight.bold, 698 fontWeight: FontWeight.bold,
@@ -701,12 +711,16 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> { @@ -701,12 +711,16 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> {
701 )), 711 )),
702 VEmptyView(30), 712 VEmptyView(30),
703 if (model.image != null) 713 if (model.image != null)
704 - CachedNetworkImage(  
705 - imageUrl: model.image,  
706 - fit: BoxFit.cover,  
707 - width: ScreenUtil().screenWidth / 2,  
708 - height: w(125),  
709 - ), 714 + Container(
  715 + constraints: BoxConstraints(
  716 + maxHeight: ScreenUtil().screenWidth / 2,
  717 + ),
  718 + child: CachedNetworkImage(
  719 + imageUrl: model.image,
  720 + fit: BoxFit.contain,
  721 + width: ScreenUtil().screenWidth / 2,
  722 + // height: w(125),
  723 + )),
710 if (model.desc != null && model.desc != '') 724 if (model.desc != null && model.desc != '')
711 Padding( 725 Padding(
712 padding: EdgeInsets.symmetric(horizontal: w(10), vertical: w(10)), 726 padding: EdgeInsets.symmetric(horizontal: w(10), vertical: w(10)),
@@ -945,12 +959,17 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> { @@ -945,12 +959,17 @@ class _MenuThemeColorSetPageState extends State<MenuThemeColorSetPage> {
945 : _topLeft( 959 : _topLeft(
946 model)), 960 model)),
947 if (model.image != null) 961 if (model.image != null)
948 - CachedNetworkImage(  
949 - imageUrl: model.image,  
950 - fit: BoxFit.cover,  
951 - width: double.infinity,  
952 - height: w(250),  
953 - ), 962 + Container(
  963 + constraints: BoxConstraints(
  964 + maxHeight: ScreenUtil()
  965 + .screenWidth,
  966 + ),
  967 + child: CachedNetworkImage(
  968 + imageUrl: model.image,
  969 + fit: BoxFit.contain,
  970 + width: double.infinity,
  971 + // height: w(250),
  972 + )),
954 if (model.desc != null && 973 if (model.desc != null &&
955 model.desc != '') 974 model.desc != '')
956 Align( 975 Align(