Commit 734c99884b45f37985a2c0e6166ccfea2b9c026b

Authored by wdn127929
1 parent c548a539

已预订列表

@@ -47,6 +47,7 @@ class Notebook { @@ -47,6 +47,7 @@ class Notebook {
47 String operator_openid; 47 String operator_openid;
48 String channel; 48 String channel;
49 String cdate; 49 String cdate;
  50 + String label;
50 String name; 51 String name;
51 OrderInfo orderInfo; 52 OrderInfo orderInfo;
52 String nick_name; 53 String nick_name;
@@ -48,6 +48,7 @@ Notebook _$NotebookFromJson(Map<String, dynamic> json) { @@ -48,6 +48,7 @@ Notebook _$NotebookFromJson(Map<String, dynamic> json) {
48 ..operator_openid = json['operator_openid'] as String 48 ..operator_openid = json['operator_openid'] as String
49 ..channel = json['channel'] as String 49 ..channel = json['channel'] as String
50 ..cdate = json['cdate'] as String 50 ..cdate = json['cdate'] as String
  51 + ..label = json['label'] as String
51 ..name = json['name'] as String 52 ..name = json['name'] as String
52 ..orderInfo = json['order_info'] == null 53 ..orderInfo = json['order_info'] == null
53 ? null 54 ? null
@@ -68,7 +69,7 @@ Map<String, dynamic> _$NotebookToJson(Notebook instance) => <String, dynamic>{ @@ -68,7 +69,7 @@ Map<String, dynamic> _$NotebookToJson(Notebook instance) => <String, dynamic>{
68 'pnum_str': instance.pnum_str, 69 'pnum_str': instance.pnum_str,
69 'rname': instance.rname, 70 'rname': instance.rname,
70 'sex': instance.sex, 71 'sex': instance.sex,
71 - 'aname':instance.aname, 72 + 'aname': instance.aname,
72 'phone': instance.phone, 73 'phone': instance.phone,
73 'cusdem': instance.cusdem, 74 'cusdem': instance.cusdem,
74 'cusman': instance.cusman, 75 'cusman': instance.cusman,
@@ -94,6 +95,7 @@ Map<String, dynamic> _$NotebookToJson(Notebook instance) => <String, dynamic>{ @@ -94,6 +95,7 @@ Map<String, dynamic> _$NotebookToJson(Notebook instance) => <String, dynamic>{
94 'operator_openid': instance.operator_openid, 95 'operator_openid': instance.operator_openid,
95 'channel': instance.channel, 96 'channel': instance.channel,
96 'cdate': instance.cdate, 97 'cdate': instance.cdate,
  98 + 'label': instance.label,
97 'name': instance.name, 99 'name': instance.name,
98 'order_info': instance.orderInfo, 100 'order_info': instance.orderInfo,
99 'nick_name': instance.nick_name, 101 'nick_name': instance.nick_name,
@@ -459,7 +459,7 @@ class _CustomerDetailPageState extends State<CustomerDetailPage> { @@ -459,7 +459,7 @@ class _CustomerDetailPageState extends State<CustomerDetailPage> {
459 color: MyColours.color_333333), 459 color: MyColours.color_333333),
460 ), 460 ),
461 Text( 461 Text(
462 - '${customerProvider.guestInfoSunModel.last.sellerUserNickName} ${customerProvider.guestInfoSunModel.last.sellerUserPhone}', 462 + '${customerProvider.guestInfoSunModel.last.sellerUserNickName ?? ''} ${customerProvider.guestInfoSunModel.last.sellerUserPhone ?? ''}',
463 style: TextStyle( 463 style: TextStyle(
464 fontSize: ScreenUtil().setSp(24), 464 fontSize: ScreenUtil().setSp(24),
465 color: MyColours.color_199095), 465 color: MyColours.color_199095),
@@ -575,7 +575,9 @@ class NoteBookItemFState extends State<NoteBookItemF> @@ -575,7 +575,9 @@ class NoteBookItemFState extends State<NoteBookItemF>
575 maxLines: 1, 575 maxLines: 1,
576 overflow: TextOverflow.ellipsis, 576 overflow: TextOverflow.ellipsis,
577 style: TextStyle( 577 style: TextStyle(
578 - color: MyColours.color_260101, 578 + color: canDo
  579 + ? MyColours.color_260101
  580 + : MyColours.color_BFC4D4,
579 fontWeight: FontWeight.bold, 581 fontWeight: FontWeight.bold,
580 fontSize: ScreenUtil().setSp(28)), 582 fontSize: ScreenUtil().setSp(28)),
581 ), 583 ),
@@ -589,7 +591,9 @@ class NoteBookItemFState extends State<NoteBookItemF> @@ -589,7 +591,9 @@ class NoteBookItemFState extends State<NoteBookItemF>
589 maxLines: 1, 591 maxLines: 1,
590 overflow: TextOverflow.ellipsis, 592 overflow: TextOverflow.ellipsis,
591 style: TextStyle( 593 style: TextStyle(
592 - color: MyColours.color_260101, 594 + color: canDo
  595 + ? MyColours.color_260101
  596 + : MyColours.color_BFC4D4,
593 fontWeight: FontWeight.bold, 597 fontWeight: FontWeight.bold,
594 fontSize: ScreenUtil().setSp(28)), 598 fontSize: ScreenUtil().setSp(28)),
595 ) 599 )
@@ -598,29 +602,36 @@ class NoteBookItemFState extends State<NoteBookItemF> @@ -598,29 +602,36 @@ class NoteBookItemFState extends State<NoteBookItemF>
598 notebook.phoneStr.isEmpty 602 notebook.phoneStr.isEmpty
599 ? SizedBox() 603 ? SizedBox()
600 : HEmptyView(8), 604 : HEmptyView(8),
601 - notebook.rnameStr == '' &&  
602 - notebook.phoneStr.isEmpty 605 + (notebook.rnameStr == '' &&
  606 + notebook.phoneStr.isEmpty) ||
  607 + notebook.label == null
603 ? SizedBox() 608 ? SizedBox()
604 - : Expanded(  
605 - child: Container( 609 + : Container(
606 padding: EdgeInsets.symmetric( 610 padding: EdgeInsets.symmetric(
607 horizontal: 611 horizontal:
608 ScreenUtil().setWidth(12), 612 ScreenUtil().setWidth(12),
609 vertical: ScreenUtil().setWidth(4)), 613 vertical: ScreenUtil().setWidth(4)),
  614 + constraints: BoxConstraints(
  615 + maxWidth:
  616 + ScreenUtil().setWidth(74 * 2)),
610 decoration: BoxDecoration( 617 decoration: BoxDecoration(
611 border: Border.all( 618 border: Border.all(
612 width: ScreenUtil().setWidth(2), 619 width: ScreenUtil().setWidth(2),
613 - color: MyColours.color_A78E44),  
614 - borderRadius:  
615 - BorderRadius.circular(6)), 620 + color: canDo
  621 + ? MyColours.color_A78E44
  622 + : MyColours.color_BFC4D4),
  623 + borderRadius: BorderRadius.circular(
  624 + ScreenUtil().setWidth(6))),
616 child: Text( 625 child: Text(
617 - 'biaoqianvipdsdsbiaoqianvipdsdsbiaoqianvipdsdsbiaoqianvipdsdsbiaoqianvipdsds', 626 + notebook.label,
618 overflow: TextOverflow.ellipsis, 627 overflow: TextOverflow.ellipsis,
619 style: TextStyle( 628 style: TextStyle(
620 - color: MyColours.color_A78E44, 629 + color: canDo
  630 + ? MyColours.color_A78E44
  631 + : MyColours.color_BFC4D4,
621 fontSize: ScreenUtil().setSp(18)), 632 fontSize: ScreenUtil().setSp(18)),
622 ), 633 ),
623 - )) 634 + )
624 ], 635 ],
625 ), 636 ),
626 VEmptyView(6), 637 VEmptyView(6),
@@ -634,11 +645,15 @@ class NoteBookItemFState extends State<NoteBookItemF> @@ -634,11 +645,15 @@ class NoteBookItemFState extends State<NoteBookItemF>
634 maxLines: 1, 645 maxLines: 1,
635 overflow: TextOverflow.ellipsis, 646 overflow: TextOverflow.ellipsis,
636 style: TextStyle( 647 style: TextStyle(
637 - color: MyColours.color_260101, 648 + color: canDo
  649 + ? MyColours.color_260101
  650 + : MyColours.color_BFC4D4,
638 fontWeight: FontWeight.bold, 651 fontWeight: FontWeight.bold,
639 fontSize: ScreenUtil().setSp(28)), 652 fontSize: ScreenUtil().setSp(28)),
640 ), 653 ),
641 - detail == '' ? SizedBox() : VEmptyView(6), 654 + notebook.nick_name == null
  655 + ? SizedBox()
  656 + : VEmptyView(6),
642 notebook.nick_name == null 657 notebook.nick_name == null
643 ? SizedBox() 658 ? SizedBox()
644 : Text( 659 : Text(
@@ -646,12 +661,12 @@ class NoteBookItemFState extends State<NoteBookItemF> @@ -646,12 +661,12 @@ class NoteBookItemFState extends State<NoteBookItemF>
646 maxLines: 1, 661 maxLines: 1,
647 overflow: TextOverflow.ellipsis, 662 overflow: TextOverflow.ellipsis,
648 style: TextStyle( 663 style: TextStyle(
649 - color: MyColours.color_999999, 664 + color: canDo
  665 + ? MyColours.color_999999
  666 + : MyColours.color_BFC4D4,
650 fontSize: ScreenUtil().setSp(24)), 667 fontSize: ScreenUtil().setSp(24)),
651 ), 668 ),
652 - notebook.nick_name == ''  
653 - ? VEmptyView(6)  
654 - : SizedBox(), 669 + detail == '' ? SizedBox() : VEmptyView(6),
655 detail == '' 670 detail == ''
656 ? SizedBox() 671 ? SizedBox()
657 : Text( 672 : Text(
@@ -659,7 +674,9 @@ class NoteBookItemFState extends State<NoteBookItemF> @@ -659,7 +674,9 @@ class NoteBookItemFState extends State<NoteBookItemF>
659 maxLines: 100, 674 maxLines: 100,
660 overflow: TextOverflow.ellipsis, 675 overflow: TextOverflow.ellipsis,
661 style: TextStyle( 676 style: TextStyle(
662 - color: MyColours.color_999999, 677 + color: canDo
  678 + ? MyColours.color_999999
  679 + : MyColours.color_BFC4D4,
663 fontSize: ScreenUtil().setSp(24)), 680 fontSize: ScreenUtil().setSp(24)),
664 ), 681 ),
665 ], 682 ],
@@ -538,7 +538,9 @@ class NoteBookItemSimpleState extends State<NoteBookItemSimple> @@ -538,7 +538,9 @@ class NoteBookItemSimpleState extends State<NoteBookItemSimple>
538 maxLines: 1, 538 maxLines: 1,
539 overflow: TextOverflow.ellipsis, 539 overflow: TextOverflow.ellipsis,
540 style: TextStyle( 540 style: TextStyle(
541 - color: MyColours.color_260101, 541 + color: canDo
  542 + ? MyColours.color_260101
  543 + : MyColours.color_BFC4D4,
542 fontWeight: FontWeight.bold, 544 fontWeight: FontWeight.bold,
543 fontSize: ScreenUtil().setSp(24)), 545 fontSize: ScreenUtil().setSp(24)),
544 ), 546 ),
@@ -552,7 +554,9 @@ class NoteBookItemSimpleState extends State<NoteBookItemSimple> @@ -552,7 +554,9 @@ class NoteBookItemSimpleState extends State<NoteBookItemSimple>
552 maxLines: 1, 554 maxLines: 1,
553 overflow: TextOverflow.ellipsis, 555 overflow: TextOverflow.ellipsis,
554 style: TextStyle( 556 style: TextStyle(
555 - color: MyColours.color_260101, 557 + color: canDo
  558 + ? MyColours.color_260101
  559 + : MyColours.color_BFC4D4,
556 fontWeight: FontWeight.bold, 560 fontWeight: FontWeight.bold,
557 fontSize: ScreenUtil().setSp(24)), 561 fontSize: ScreenUtil().setSp(24)),
558 ) 562 )
@@ -571,7 +575,9 @@ class NoteBookItemSimpleState extends State<NoteBookItemSimple> @@ -571,7 +575,9 @@ class NoteBookItemSimpleState extends State<NoteBookItemSimple>
571 maxLines: 1, 575 maxLines: 1,
572 overflow: TextOverflow.ellipsis, 576 overflow: TextOverflow.ellipsis,
573 style: TextStyle( 577 style: TextStyle(
574 - color: MyColours.color_260101, 578 + color: canDo
  579 + ? MyColours.color_260101
  580 + : MyColours.color_BFC4D4,
575 fontWeight: FontWeight.bold, 581 fontWeight: FontWeight.bold,
576 fontSize: ScreenUtil().setSp(24)), 582 fontSize: ScreenUtil().setSp(24)),
577 ), 583 ),
@@ -597,8 +603,10 @@ class NoteBookItemSimpleState extends State<NoteBookItemSimple> @@ -597,8 +603,10 @@ class NoteBookItemSimpleState extends State<NoteBookItemSimple>
597 maxLines: 1, 603 maxLines: 1,
598 overflow: TextOverflow.ellipsis, 604 overflow: TextOverflow.ellipsis,
599 style: TextStyle( 605 style: TextStyle(
600 - color:  
601 - MyColours.color_999999, 606 + color: canDo
  607 + ? MyColours.color_999999
  608 + : MyColours
  609 + .color_BFC4D4,
602 fontSize: 610 fontSize:
603 ScreenUtil().setSp(24)), 611 ScreenUtil().setSp(24)),
604 )), 612 )),
@@ -88,7 +88,6 @@ class Utils { @@ -88,7 +88,6 @@ class Utils {
88 } else { 88 } else {
89 date = datestr; 89 date = datestr;
90 } 90 }
91 - return date;  
92 91
93 // if (delta < 12 * 4 * ONE_WEEK) { 92 // if (delta < 12 * 4 * ONE_WEEK) {
94 // num months = toMonths(delta); 93 // num months = toMonths(delta);
@@ -98,6 +97,7 @@ class Utils { @@ -98,6 +97,7 @@ class Utils {
98 // return (years <= 0 ? 1 : years).toInt().toString() + ONE_YEAR_AGO; 97 // return (years <= 0 ? 1 : years).toInt().toString() + ONE_YEAR_AGO;
99 // } 98 // }
100 } 99 }
  100 + return date;
101 } 101 }
102 102
103 static String formatFromYmd(String datestr) { 103 static String formatFromYmd(String datestr) {