Commit be14cefd39ab25d1109ab75fb7b3618f5d5d3269

Authored by weixin_45529955
1 parent a9fd3ffd

我的页面越界

@@ -112,6 +112,8 @@ class _CustomerHomePageState extends State<CustomerHomePage> { @@ -112,6 +112,8 @@ class _CustomerHomePageState extends State<CustomerHomePage> {
112 } else { 112 } else {
113 NavigatorUtil.goStoreCustomerPage(context); 113 NavigatorUtil.goStoreCustomerPage(context);
114 } 114 }
  115 + } else {
  116 + Utils.showToast('您还没有操作权限,请联系管理员');
115 } 117 }
116 }, 118 },
117 child: Padding( 119 child: Padding(
@@ -619,7 +619,7 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver { @@ -619,7 +619,7 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver {
619 ), 619 ),
620 child: Text( 620 child: Text(
621 '${model.user!.nickName} ${model.user!.role_name} >', 621 '${model.user!.nickName} ${model.user!.role_name} >',
622 - maxLines: 1, 622 + maxLines: 2,
623 overflow: TextOverflow.ellipsis, 623 overflow: TextOverflow.ellipsis,
624 style: TextStyle( 624 style: TextStyle(
625 letterSpacing: 0.2, 625 letterSpacing: 0.2,
@@ -640,8 +640,9 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver { @@ -640,8 +640,9 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver {
640 ], 640 ],
641 )), 641 )),
642 HEmptyView(22), 642 HEmptyView(22),
643 - Spacer(),  
644 - Column( 643 + // Spacer(),
  644 + Expanded(
  645 + child: Column(
645 crossAxisAlignment: CrossAxisAlignment.end, 646 crossAxisAlignment: CrossAxisAlignment.end,
646 mainAxisAlignment: MainAxisAlignment.center, 647 mainAxisAlignment: MainAxisAlignment.center,
647 children: [ 648 children: [
@@ -665,6 +666,8 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver { @@ -665,6 +666,8 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver {
665 // json.encode(user.toJson())); 666 // json.encode(user.toJson()));
666 // print(userModel.user); 667 // print(userModel.user);
667 setState(() {}); 668 setState(() {});
  669 + } else {
  670 + Utils.showToast('您还没有操作权限,请联系管理员!');
668 } 671 }
669 }, 672 },
670 child: Container( 673 child: Container(
@@ -672,7 +675,8 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver { @@ -672,7 +675,8 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver {
672 EdgeInsets.only(bottom: w(6)), 675 EdgeInsets.only(bottom: w(6)),
673 child: Text( 676 child: Text(
674 '${model.user!.sellername} >', 677 '${model.user!.sellername} >',
675 - maxLines: 1, 678 + maxLines: 2,
  679 + textAlign: TextAlign.end,
676 overflow: TextOverflow.ellipsis, 680 overflow: TextOverflow.ellipsis,
677 style: TextStyle( 681 style: TextStyle(
678 letterSpacing: 0.2, 682 letterSpacing: 0.2,
@@ -723,7 +727,7 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver { @@ -723,7 +727,7 @@ class MyPageState extends State<MyPage> with WidgetsBindingObserver {
723 }, 727 },
724 ), 728 ),
725 ], 729 ],
726 - ) 730 + ))
727 ])), 731 ])),
728 ), 732 ),
729 Positioned( 733 Positioned(
@@ -411,8 +411,11 @@ class MenuManageProvider extends ChangeNotifier { @@ -411,8 +411,11 @@ class MenuManageProvider extends ChangeNotifier {
411 .cast<CookbookCategorySunModel>(); 411 .cast<CookbookCategorySunModel>();
412 categorySunModel! 412 categorySunModel!
413 .removeWhere((element) => element.classType == '1'); 413 .removeWhere((element) => element.classType == '1');
414 -  
415 - pageStateCategory = PageState.Success; 414 + if (categorySunModel!.length == 0) {
  415 + pageStateCategory = PageState.Empty;
  416 + } else {
  417 + pageStateCategory = PageState.Success;
  418 + }
416 } 419 }
417 } else { 420 } else {
418 pageStateCategory = PageState.Empty; 421 pageStateCategory = PageState.Empty;