I am trying to create a template that will repeat based on certain value. For example if the total number of pages are 3 and total records are 15 then each page will have 5 records. So essentially it would be a nested ng-repreat.
I create a sample java code
int index = 1;
for(int i =1; i <=5; i++){
System.out.print("#"+i);
for(int j = index; j<=14; j++){
System.out.print("->"+index);
index++;
if(j%3==0){
break;
}
}
System.out.println();
}
These will correctly set number of records of each page. Now I need to first create templates pages based on the how many pages I will need and then inside each page I need a particular number of records. In angular its a bit tricky to write this logic using ng-repeat
<div ng-repeat="i in X" >
<div>
<div ng-repeat="j in Y">
<span></span>
</div>
<div>
</div>