Forums

Home » Liferay Portal » English » 3. Development

Combination View Flat View Tree View
Threads [ Previous | Next ]
toggle
Priyanka Dhingra
onclick for row in a search container
November 8, 2012 1:18 AM
Answer

Priyanka Dhingra

Rank: Liferay Master

Posts: 501

Join Date: December 19, 2011

Recent Posts

I want to implement an onclick call for rows in the searchcontainer table. I want to show the details of the clicked row in some other page

Thanks in Advance

Regards
Priyanka
Priyanka Dhingra
RE: onclick for row in a search container
November 8, 2012 9:40 PM
Answer

Priyanka Dhingra

Rank: Liferay Master

Posts: 501

Join Date: December 19, 2011

Recent Posts

Any help plz
KK rajput
RE: onclick for row in a search container
November 8, 2012 9:53 PM
Answer

KK rajput

Rank: Expert

Posts: 266

Join Date: April 10, 2008

Recent Posts

You can use ResultRow object on jsp for this.
example:
ResultRow row = new ResultRow(...);
row.addJSP([Your_jsp_page_path], application, request, response);

HTH
KamalKant
Priyanka Dhingra
RE: onclick for row in a search container
November 8, 2012 10:04 PM
Answer

Priyanka Dhingra

Rank: Liferay Master

Posts: 501

Join Date: December 19, 2011

Recent Posts

How does that help...can u be more detailed @Kamalkant?
KK rajput
RE: onclick for row in a search container
November 26, 2012 1:16 AM
Answer

KK rajput

Rank: Expert

Posts: 266

Join Date: April 10, 2008

Recent Posts

Priyanka Dhingra:
How does that help...can u be more detailed @Kamalkant?

In the listing page some thing like this

List resultRows = searchContainer.getResultRows();

for (int i = 0; i < results.size(); i++) {
SDataReminder sdr = results.get(i);

ResultRow row = new ResultRow(sdr, sdr.getScheduleId(), i);

row.addJSP("/html/record/record_display.jsp", application, request, response);



// Add result row

resultRows.add(row);
}


in record_display.page you can get info

<%
ResultRow row = (ResultRow)request.getAttribute(WebKeys.SEARCH_CONTAINER_RESULT_ROW);

SDataReminder sdr = (SDataReminder)row.getObject();


%>