您好,在每次切换Tab的时候需要刷新一下,这样在展示的时候就能重新渲染数据。具体参照demo的代码:
$scope.tabdata = function(tap){
if(tap == 1){
debugger
$('#s2').css("display","none");
$("#s1").css("display","block");
$scope.cdata.pageSize = 15;
$scope.cdata.refresh(false);
}else if(tap == 2){
debugger
$('#s1').css("display","none");
$("#s2").css("display","block");
$scope.flexs.collectionView.pageSize = 15;
//$scope.flexs.collectionView.refresh(false);
$scope.flexs.invalidate();
}
} |