|  | @@ -43,6 +43,7 @@ import com.cooleshow.student.bean.HomeStyleBean;
 | 
	
		
			
				|  |  |  import com.cooleshow.student.bean.HotAlbumBean;
 | 
	
		
			
				|  |  |  import com.cooleshow.student.bean.RecommendTalentListBean;
 | 
	
		
			
				|  |  |  import com.cooleshow.student.bean.StudentUserInfo;
 | 
	
		
			
				|  |  | +import com.cooleshow.student.constants.CommonConfig;
 | 
	
		
			
				|  |  |  import com.cooleshow.student.constants.CourseConstants;
 | 
	
		
			
				|  |  |  import com.cooleshow.student.contract.HomeContract;
 | 
	
		
			
				|  |  |  import com.cooleshow.student.databinding.FragmentNewHomeLayoutBinding;
 | 
	
	
		
			
				|  | @@ -97,7 +98,6 @@ public class NewHomeFragment extends BaseMVPFragment<FragmentNewHomeLayoutBindin
 | 
	
		
			
				|  |  |      private HotNewsFragment mHotNewsFragment;
 | 
	
		
			
				|  |  |      private ValueAnimator bottomTabValueAnimator;
 | 
	
		
			
				|  |  |      private boolean isCollapsed = false;//控制底部tab
 | 
	
		
			
				|  |  | -    private boolean isShowFlashPage = false;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |      private ViewPager2.OnPageChangeCallback onPageChangeCallback = new ViewPager2.OnPageChangeCallback() {
 | 
	
		
			
				|  |  |          @Override
 | 
	
	
		
			
				|  | @@ -219,10 +219,6 @@ public class NewHomeFragment extends BaseMVPFragment<FragmentNewHomeLayoutBindin
 | 
	
		
			
				|  |  |                      }
 | 
	
		
			
				|  |  |                  });
 | 
	
		
			
				|  |  |          initListener();
 | 
	
		
			
				|  |  | -        //获取热门专辑
 | 
	
		
			
				|  |  | -        presenter.userAccountPage();
 | 
	
		
			
				|  |  | -        //获取热门曲目
 | 
	
		
			
				|  |  | -        presenter.getHotMusicSheetList();
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |      private void initListener() {
 | 
	
	
		
			
				|  | @@ -375,14 +371,20 @@ public class NewHomeFragment extends BaseMVPFragment<FragmentNewHomeLayoutBindin
 | 
	
		
			
				|  |  |      public void onResume() {
 | 
	
		
			
				|  |  |          super.onResume();
 | 
	
		
			
				|  |  |          if (presenter != null) {
 | 
	
		
			
				|  |  | +            //红点
 | 
	
		
			
				|  |  | +            presenter.queryCountOfUnread();
 | 
	
		
			
				|  |  |              presenter.appHome();
 | 
	
		
			
				|  |  |              //获取课程信息
 | 
	
		
			
				|  |  |              presenter.queryLiveAndVideo();
 | 
	
		
			
				|  |  |              refreshBottomData();
 | 
	
		
			
				|  |  | -            //获取推荐达人列表
 | 
	
		
			
				|  |  | -            presenter.getRecommendTalentList();
 | 
	
		
			
				|  |  |              //查询个人信息
 | 
	
		
			
				|  |  |              presenter.queryUserInfo();
 | 
	
		
			
				|  |  | +            //获取推荐达人列表
 | 
	
		
			
				|  |  | +            presenter.getRecommendTalentList();
 | 
	
		
			
				|  |  | +            //获取热门专辑
 | 
	
		
			
				|  |  | +            presenter.userAccountPage();
 | 
	
		
			
				|  |  | +            //获取热门曲目
 | 
	
		
			
				|  |  | +            presenter.getHotMusicSheetList();
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |  
 | 
	
	
		
			
				|  | @@ -414,11 +416,11 @@ public class NewHomeFragment extends BaseMVPFragment<FragmentNewHomeLayoutBindin
 | 
	
		
			
				|  |  |          if (null == flashPage || flashPage.size() == 0) {
 | 
	
		
			
				|  |  |              return;
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  | -        if (isShowFlashPage) {
 | 
	
		
			
				|  |  | +        if (!CommonConfig.isShowHomeFlashPage) {
 | 
	
		
			
				|  |  |              return;
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |          DialogUtils.showHomeDialog(getContext(), flashPage.get(0));
 | 
	
		
			
				|  |  | -        isShowFlashPage = true;
 | 
	
		
			
				|  |  | +        CommonConfig.isShowHomeFlashPage = false;
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |      /**
 | 
	
	
		
			
				|  | @@ -472,7 +474,12 @@ public class NewHomeFragment extends BaseMVPFragment<FragmentNewHomeLayoutBindin
 | 
	
		
			
				|  |  |              return;
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |          if (mAlbumAdapter != null) {
 | 
	
		
			
				|  |  | -            mAlbumAdapter.setNewInstance(homeHotAlbumListBean.rows);
 | 
	
		
			
				|  |  | +            if (homeHotAlbumListBean != null && homeHotAlbumListBean.rows != null && homeHotAlbumListBean.rows.size() > 0) {
 | 
	
		
			
				|  |  | +                mViewBinding.clHotAlbum.setVisibility(View.VISIBLE);
 | 
	
		
			
				|  |  | +                mAlbumAdapter.setNewInstance(homeHotAlbumListBean.rows);
 | 
	
		
			
				|  |  | +            } else {
 | 
	
		
			
				|  |  | +                mViewBinding.clHotAlbum.setVisibility(View.GONE);
 | 
	
		
			
				|  |  | +            }
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |  
 | 
	
	
		
			
				|  | @@ -614,6 +621,7 @@ public class NewHomeFragment extends BaseMVPFragment<FragmentNewHomeLayoutBindin
 | 
	
		
			
				|  |  |          ArrayList<HomeHotMusicSheetItemBean> itemBeans = new ArrayList<>();
 | 
	
		
			
				|  |  |          List<HomeHotMusicSheetBean.RowsBean> rows = homeHotMusicSheetBean.rows;
 | 
	
		
			
				|  |  |          if (rows != null && rows.size() > 0) {
 | 
	
		
			
				|  |  | +            mViewBinding.clHotTrack.setVisibility(View.VISIBLE);
 | 
	
		
			
				|  |  |              int pageCount = 0;
 | 
	
		
			
				|  |  |              int pageResult = rows.size() % MAX_HOT_MUSIC_LIST_PAGE;
 | 
	
		
			
				|  |  |              if (pageResult == 0) {
 | 
	
	
		
			
				|  | @@ -631,6 +639,8 @@ public class NewHomeFragment extends BaseMVPFragment<FragmentNewHomeLayoutBindin
 | 
	
		
			
				|  |  |              if (mHomeHotMusicSheetAdapter != null) {
 | 
	
		
			
				|  |  |                  mHomeHotMusicSheetAdapter.setNewInstance(itemBeans);
 | 
	
		
			
				|  |  |              }
 | 
	
		
			
				|  |  | +        } else {
 | 
	
		
			
				|  |  | +            mViewBinding.clHotTrack.setVisibility(View.GONE);
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  |      }
 | 
	
		
			
				|  |  |  
 |