Skip to Main Content

APEX

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to collapse/expand a collapsible template depending the return of IR

Soukaina IDRISSINov 21 2017 — edited Nov 23 2017

Hi everyone,

I want to collapse the collapsible region, if the return of the IR is NULL, else collapse the specific region, by Default.

I did this steps:

  1. Give unique static ID to the reports (autreEng)
  2. Specify error message if no record found in report attributes
  3. Write Jquery code as follow in the "Execute when Page Loads" section of the page for each report as follow

jQuery(document).ready(function() { 

if ($('.nodatafound','#autreEng').length) { 

$("#autreEng").removeClass('is-expanded').addClass('is-collapsed'); 

$("#a_Collapsible3_autreEng_content").attr("aria-hidden","true"); 

else{ 

$("#autreEng").removeClass('is-collapsed').addClass('is-expanded'); 

$("#a_Collapsible3_autreEng_content").attr("aria-hidden","false"); 

});

But i have one problem, this code works only if i use Classic Report, but if i have Interactive Report it doesnt.

Thank you for help.

This post has been answered by -W. on Nov 23 2017
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Dec 21 2017
Added on Nov 21 2017
7 comments
1,397 views