Hi!
I want to use Metrics like in Incident Tracking app on apex.oracle.com
For instance, when I click on the OPEN, to get results in a report where status=’OPEN’, instead of using an item in where clause like in question here. Where I had a problem with reset value on reload. I’d like to use IR on the same page as badge list.
Thanks in advance!
You can refresh the interactive report on the same page using the JavaScript as follows:
Make a link column in your badge list report and set the Link target as URL type and add the following URL in it:
Change the EMPNO column to your column name.
Create the following JavaScript function in the function and global variable declaration section of the page:
Create a page item, for example, P2_EMPNO, and make the item as the hidden item.
Specify a static ID to your IR report, for example, IRemp.
Specify the where clause in your IR report, for example, empno = :p2_empno and specify the page item to page items to submit field.
I think you don’t want to specify the where clause for the IR report. But without it, how will you filter the report?
Also, using the above method, it will not show the parameter and its value in the URL.
You try this approach and let me know if it is not ok for you.
Then just follow the first example. It will work. Below I am briefing again:
JavaScript function:
If you still not able to do it, then create a demo app and let me know.
Works now, thanks a lot 🙂
I changed #STATUS# with a value which I need to use for the status item.
For example, the link for the NEW column:
I added before header process, to clear all items when the user reloads the page and works well. 🙂
Thanks for response Vinish!
I tried to create, but when I click on link in badge list nothing happened.
I want get search results , like in screenshot below:
You must be missing something because the above example is tested.
Have you specified the static ID to the IR report? And changed that static ID in the JavaScript function?
Also, check if you specified the page item to items to submit the field.
You’re right I typed wrong column name.
What is “pempno” in the function code?
I have 4 columns, and they have different values. When I change pempno to the setValue(“NEW”), I got results for status=’NEW’. How to get value for other columns in badge list?
The pempno is the function parameter, which we are passing as EMPNO from the URL. But if you require to pass multiple parameters, you can change the code as follows:
Modify the JS function:
Now the above function will accept 3 parameters and will set the page items with these parameter values.
Also, I am assuming that you will use other page items in the where clause of the report, and don’t forget to specify the items for items to submit property.
Now change the URL to pass the other column values:
Notice in the above URL that column ENAME is supplied within single quotes. So if you are passing any character fields, use the single quotes.
Vinish, thanks a lot for your effort to help me, I think that my explanation was bad. Sorry about that.
I have 4 columns in the badge list but, these columns are values from the same table column.
For instance, columns: status=’NEW’, status=’OPEN’, status=’CLOSED’, status=’DONE’ are displayed in badge list.