Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

How to print data in h:dataTable by column wise  RSS feed

 
Venkateswarlu Vadde
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've Arraylist holding of Item objects, in that again one more Arraylist containing Item parameters

My problem is i want to display ItemParams side by side(column wise) not row by row(normal procedure)

Table looks like

ItemNoItemNameItemDescChange
---------------------------------------------------------
234Colgatetoothpastecheckbox
123Pepsodenttoothpastecheckbox

In above table ItemName having different params
colgate have 3params
peopsodent have 2 params

ItemParameters class(bean) containing fields of parameterValue(textBox in UI) and parameterDescription(textArea in UI)

So the total ItemName column looks like

ItemName
--------------------------------------------------------------------------------------------------------------------------------
Colgate
parameterValue parameterDescription,parameterValue parameterDescription,parameterValue parameterDescription

Pepsodent
parameterValue parameterDescription,parameterValue parameterDescription

Cibaca
parameterValue parameterDescription,parameterValue parameterDescription,parameterValue parameterDescription,parameterValue parameterDescription

Please help me
Thanks in advance
 
Ali Gohar
Ranch Hand
Posts: 572
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not understood your problem exactly. Please paste the code of your item class and any classes it contain for parameters?
[ November 02, 2006: Message edited by: Ali Gohar ]
 
Venkateswarlu Vadde
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
All are POJO classed only (having sets and gets)

i want to display ItemName(as shown above) column(with params) in main table( heading: Table looks like )

My question is how should i display params side by side(column wise)

because when your are having multiple objects, normally we put in h:column, so datatable can iterate and prints row by row

but I want this in column wise

paramValue1 paraDesc1, paramValue2,paraDesc2 etc.,
 
Ali Gohar
Ranch Hand
Posts: 572
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I guess try <t:dataList> if you are using MyFaces.
 
Venkateswarlu Vadde
Greenhorn
Posts: 7
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thank you very much Ali Sir
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!