FORUM PLAN UPDATE
Date revision: This forum will remain open to new posts and responses until December 1, 2018. (After that date, you will still be able to view and search the forum.) Also, we're taking a second look at the best place to host future conversation. For now, keep using this forum, and stay tuned for more news.



Nov 7, 2012, 11:40 AM
2 Posts

Horizontal layout with repeat inside repeat

  • Category: Other
  • Platform: All
  • Release: 8.5.3
  • Role: Developer
  • Tags: xpages repeating control
  • Replies: 1

I´m new to xpages so it must be simple.
this is a ascii art showing what i want to do with repeat inside repeat control but horizontally, not vertically
Tag comes from table and instrum/period comes from table2 for example 
 
Tag        Instrum      Period                                               
| TI-100 |PT-100|       24
|             |ER-100|       12
|             |EF-100|         6
---------------------------------------------------
I think it cannot be done because the first repeat does not create a div for every record found( here TI-100) but a span.
Then,the next repeat creates a div that sits side to side in the html tree to the previous span and this way i cannot put repeat 2 div  inside repeat 1 span record so i can lay it out nicelly with html positioning tricks
 
All i can do i this 
TI-100 
PT-100 24 
ER-100 12
EF-100  6
 
 
I really apreciate if you help me.
Best regards
António

Nov 8, 2012, 1:34 AM
129 Posts
Re: Horizontal layout with repeat inside repeat
Seems more or less impossible to do column by column rendering due to the structure of a html table..
 
I would rather focus on restructuring the data source for the table.
 
In java, you can use an ArrayList<HashMap<String, String>> as container for the data.
 
In SSJS, you can use an array of objects.
 
Put null or empty string for the columns that doesn't have data in the row. 
 
When you have the data in this structure, you can use a data table. 


FORUM PLAN UPDATE
Date revision: This forum will remain open to new posts and responses until December 1, 2018. (After that date, you will still be able to view and search the forum.) Also, we're taking a second look at the best place to host future conversation. For now, keep using this forum, and stay tuned for more news.