Saturday, February 5, 2011

Highlight current record in Interactive Report

- Create an interactive report with an ID column. On the page must be an item (Pxx_ID which holds the ID, for example an item in a form region to edit the details of a selected record, based on the same table on the same page.
- Don't define a link in the reports attribute page, but do it at the ID column. The reason is that you can't use the #ID# syntax in the link icon property.
- At the property of the link icon of the column with the ID, define the image tag with an additional attribute:  value="#ID#". When the user clicks on the link, the value of the ID must be stored in the previously defined id-item. Also define the rest of the brach logic when a user clicks on the link. 

At page level include in the 'Execute when Page Loads' property, the following jQuery javascript:

$('img[value=' + $v('Pxx_ID') +']').parents('tr:first').children('td').css('background-color','#CCFFFF');


Unknown said...

What I do wrong?

select id,id MYID from table
(MYID id hidden)

$('img[value=' + $v('MYID') +']').parents('tr:first').children('td').css('background-color','#CCFFFF');

Dont work.

Unknown said...

on first time I am create page item P12_ID.
and on IR link column P12_ID=#ID#

execute on page load
$('img[value=' + $v('P12_ID') +']').parents('tr:first').children('td').css('background-color','#CCFFFF');

I have debug session P12_ID holds table id.
But not works

Unknown said...

I have understood.
I have in region

.apexir_WORKSHEET_DATA tr.odd

fillikir72518 said...

Would you be involved in exchanging links? online casino real money