QPR Knowledge Base 2017.1

GetPortalUrl

GetPortalUrl

Previous topic Next topic No directory for this topic  

GetPortalUrl

Previous topic Next topic Topic directory requires JavaScript Mail us feedback on this topic!  

Revision history:

Introduced in QPR 8.1

Last changed in QPR 2015.1

 

Returns a valid URL for the requested Portal view from a Portal installation running on the same machine with QPR Web Services Foundation.

 

Synopsis:

 

string GetPortalUrl(string sessionId, string objectId, string viewName, string options)

 

Return Value:

 

URL as a string.

 

Parameters:

 

sessionId: String. ID of an authenticated session.

objectId: String. ID of an object for which a view URL is fetched.

viewName: String. Name of the view. Supported view names:

 

Common views:

Default. Returns the default view configured for the user in the Portal tab defined by the Navigation option. Portal home page is returned if Navigation is left undefined. Supported Navigation values are HeaderIds defined in tabhierarchy.ini. By default there are the following options available:

omycontents

oprocesses

oscorecards

oactions

 

QPR Metrics views:

Details

HierarchyViews

Dashboards

Navigator

Analysis

Actions

All QPR Metrics views support Period and Series ID options in the options parameter.

All QPR Metrics views for scorecard objects support ViewSettings ID options in the options parameter.

Details view for measure element objects supports the following options:

ShowDetails=true|false

GraphSettings_periodsbefore

GraphSettings_periodsafter

GraphLayout (graph template ID)

RecentActions=true|false

 

Availability of views by level:

product: all (opens the default model for user and its root scorecard, Details is the same as Scorecards)

model: all (opens root scorecard of the model, Details opens model properties)

scorecard object: all (Details behaves similarly as Scorecards)

measure element object: Details and Actions

linked element/information item object: Details

 

QPR Modeling Client views:

Details

Diagrams: View Settings (ID) can be supplied in the options parameter

Resources

Notes

InfoItems

Navigator: View Settings (ID) can be supplied in the options parameter

Analysis: View Settings (ID) can be supplied in the options parameter

Actions: View Settings (ID) can be supplied in the options parameter

Diagrams views support also the following options:

ShowDetails=true|false

GraphSettings_zoom

 

Availability of views by level:

product: all (opens the default model for user and the root diagram or the first object of needed type that is available. Details is the same as Diagrams)

model: all (opens the default model for user and the root diagram or the first object of needed type that is available. Details opens model properties)

subprocess object: Details, Diagrams, Analysis, Actions (Details is the same as Diagrams)

organization/resource/note/information item object: Details or Organization/Resources/Notes/InfoItems (the same as Details)

other model objects: Details

 

Portal views:

Details

Discussion

ActionsByUser. User (ID) can be supplied in the options parameter

ActionsByTime. TimePeriod (string, the following values are valid: "today", "this_week", "last_week", "this_month", "this_quarter", "this_year", and "all") can be supplied in the options parameter

Analysis

 

Availability of views by level:

product: all (no action selected in view, Details is the same as Discussion)

action object: all (Details is the same as Discussion)

booklet object: Details (opens the booklet in My Briefings Portal tab)

bookmark object: Details (opens the bookmark in Portal as it is)

All Portal views on product and action object level support the ViewSettings (ID) option.

 

Also Portal internal view names (found in tabhierarchy.ini) are valid ViewName parameters:

PGPLUGIN_diagrams

PGPLUGIN_organizations

PGPLUGIN_resources

PGPLUGIN_notes

PGPLUGIN_infoitems

PGPLUGIN_navigator

PGPLUGIN_analysis

PGPLUGIN_actions

SCPLUGIN_scorecards

SCPLUGIN_strategymaps

SCPLUGIN_analysis

SCPLUGIN_navigator

SCPLUGIN_reports

SCPLUGIN_actions

discussions

byuser

bytime

actionanalysis

home

whatsnew

myresponsibilities

mybooklets

alerts

The view names above support the following options:

Object (Full ID)

HierarchyParameters (URL parameters string)

 

If ViewName is an empty string, "Details" is used.

 

Note: If the provided ViewName is not valid for the given full ID (for example Details for a user object), an empty string is returned.

 

options: String. List of comma-separated options for the view in question. Common options for all views:

Language (common QPR Web Services Foundation language ID format, e.g. "ru", "fi", or "en,1"): Language for the view.

HidePortalFrameset=true|false: Used for getting URL without Portal frameset information (PMAIN, PSUB, and PPRM URL parameters). Note that this option is not supported for Portal internal view names (found in tabhiearchy.ini, see the listing in ViewName section)

IncludeUIP=true|false: Used for getting URL with the UIP parameter (includes login information of the current QPR Web Services Foundation user into the URL)

DetailsPaneMode=disabled|minimized (default)|open: State of the Details pane.

UrlParameter(parameter="<parameter name>", operation="operation") = <parameter value>: Override any URL parameter. <parameter name> defines the parameter to modify, <operation> defines the operation that is performed. Supported operations are add (default), remove, and replace. <parameter value> is the parameter value that is added, removed, or replaced. In the add operation the parameter is added regardless of whether the parameter has an existing value, and in the case an existing value is found, the old and the new values are combined with the new value starting the combined value. In the remove operation <parameter value> can be left empty as the whole parameter is removed. In the replace operation an existing value is replaced with the new one defined in <parameter value>. In both add and replace operations the parameter value is encoded before including it in the URL. For example UrlParameter(parameter="PBFO", operation="replace")=1 replaces the current value of PBFO parameter with 1.

PortalFrameSetOnly=true|false: If this option is set to true, only Portal frameset information parameters (e.g. PMAIN, PSUB, and PPRM URL parameters) can exist in the generated URL.

 

See the ViewName parameter description for information about view-specific options.

 

 

Example Procedure:

 

ServiceClient client = new ServiceClient("WSHttpBinding_IService");

string sessionId = client.Authenticate("qpr", "demo");

string analysisViewUrl = client.GetPortalUrl(sessionId, "SC.1938773693", "Analysis", "Language=fi,HidePortalFrameSet=true");

MessageBox.Show("Analysis View URL: " + analysisViewUrl);

client.Close();