You need to sign in to do that
Don't have an account?
anshu
Common header of parent and child line items in Vf page
Hi All,
I need little help in developing below pattern:
I tried so many things but keeping header as common means , we need to work with HTML tables .
So, i have used Html table with nested repeats, but I want that child line item should also come in different rows , but in my case , I am getting all line items in same row.Please suggest , how to resolve this??
column1 column2 column3 column4 column5
p1 p2 plineitem1 plineitem12 plineitem112
a1 a2
c1 c2 clineitem1 clineitem11 plineitem112
clineitem2 clineitem12 clineitem112
clineitem3 clineitem13 clineitem112
d1 d2 dlineitem1 dlineitem12 dlineitem112
currently,
<table width="100%" cellspacing="0" cellpadding="0" style="border:solid 1px #cccccc" class="list " rules="all" >
<thead>
<tr class="headerRow">
<th class="headerRow"> column1 </th>
<th class="headerRow"> column2</th>
<th class="headerRow">column3</th>
<th class="headerRow" >column4</th>
<th class="headerRow" >column5</th>
</thead>
<tbody>
<apex:repeat value="{!items_to_approve}" var="item_to_approve" >
<apex:repeat value="{!wrapper}" var="qlist" >
<tr class="dataRow">
<td>{!item_to_approve.name}</td>
<td>{!item_to_approve.id}</td>
<td>{!qlist.qrec.id}</td>
<td>{!qlist.qrec.name}</td>
<td>{!qlist.qrec.phone}</td>
</tr>
</apex:repeat>
</apex:repeat>
</tbody>
</table>
but still , m not able to get the desired output.please help
I need little help in developing below pattern:
I tried so many things but keeping header as common means , we need to work with HTML tables .
So, i have used Html table with nested repeats, but I want that child line item should also come in different rows , but in my case , I am getting all line items in same row.Please suggest , how to resolve this??
column1 column2 column3 column4 column5
p1 p2 plineitem1 plineitem12 plineitem112
a1 a2
c1 c2 clineitem1 clineitem11 plineitem112
clineitem2 clineitem12 clineitem112
clineitem3 clineitem13 clineitem112
d1 d2 dlineitem1 dlineitem12 dlineitem112
currently,
<table width="100%" cellspacing="0" cellpadding="0" style="border:solid 1px #cccccc" class="list " rules="all" >
<thead>
<tr class="headerRow">
<th class="headerRow"> column1 </th>
<th class="headerRow"> column2</th>
<th class="headerRow">column3</th>
<th class="headerRow" >column4</th>
<th class="headerRow" >column5</th>
</thead>
<tbody>
<apex:repeat value="{!items_to_approve}" var="item_to_approve" >
<apex:repeat value="{!wrapper}" var="qlist" >
<tr class="dataRow">
<td>{!item_to_approve.name}</td>
<td>{!item_to_approve.id}</td>
<td>{!qlist.qrec.id}</td>
<td>{!qlist.qrec.name}</td>
<td>{!qlist.qrec.phone}</td>
</tr>
</apex:repeat>
</apex:repeat>
</tbody>
</table>
but still , m not able to get the desired output.please help
have all the data. wrapper should have empty value for column1 and column2 based on the number of child.
All Answers
have all the data. wrapper should have empty value for column1 and column2 based on the number of child.
I was just missed with the approach and tried working with two repats and two wrappers.
I eliminate everything else and put everything in one wrapper and under one repeat as you suggested and it works like a charm..
Sometimes small guidance is of very much help.thanks again.