Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

Get Project Area ItemID in reportContext for a custom report

Hi all,
to make my custom reports more reusable, I need to get from the context the value of project area ItemID .

I tried with reportContext.getAppContext().get(" PROJECT_AREA ") but I need only the value of ItemID. Is there some method or I have to parse the result of getAppContext().get(" PROJECT_AREA ") method?

Thanks
Andrea

0 votes



2 answers

Permanent link
On 3/11/2010 6:23 AM, aianni wrote:
Hi all,
to make my custom reports more reusable, I need to get from the
context the value of project area ItemID .

I tried with reportContext.getAppContext().get(" PROJECT_AREA
") but I need only the value of ItemID. Is there some method or
I have to parse the result of getAppContext().get(" PROJECT_AREA
") method?

Thanks
Andrea


Hi Andrea,

Sorry for the delay in responding.

To do this, create a data source on COMMON_SNAPSHOT. Now create a data
set on PROJECT_AREA. Select PROJECT_AREA_ITEMID as a column, and
PROJECT_AREA_NAME as a parameter. Pass the default value '{Current
Project Area}' (including the single quotes) as the value for the
PROJECT_AREA_NAME parameter. This should always return a single row,
where the item id for the current project area is located. You can use
onFetch to store this value in a global javascript variable for use
elsewhere in your report.

james
RTC Reports Team Lead

0 votes


Permanent link
On 3/11/2010 6:23 AM, aianni wrote:

Hi Andrea,

Sorry for the delay in responding.

To do this, create a data source on COMMON_SNAPSHOT. Now create a data
set on PROJECT_AREA. Select PROJECT_AREA_ITEMID as a column, and
PROJECT_AREA_NAME as a parameter. Pass the default value '{Current
Project Area}' (including the single quotes) as the value for the
PROJECT_AREA_NAME parameter. This should always return a single row,
where the item id for the current project area is located. You can use
onFetch to store this value in a global javascript variable for use
elsewhere in your report.

james
RTC Reports Team Lead


Thanks james, it works!

0 votes

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 10,943

Question asked: Mar 11 '10, 6:11 a.m.

Question was seen: 7,224 times

Last updated: Mar 11 '10, 6:11 a.m.

Confirmation Cancel Confirm