Hexagon Geospatial
MENU

GeoMedia Smart Client

GeoMedia Smart Client community discussion board is where you can create, contribute and share information and knowledge in regards to configuring as well as working with GeoMedia Smart Client. Find your answers, share your knowledge and help build a strong GeoMedia Smart Client community.
Showing results for 
Search instead for 
Do you mean 
Reply
Contributor
Posts: 40
Registered: ‎04-12-2016
Accepted Solution

Retrieving parameters from the URL

Hi,

 

I'm using some redirections between workflow forms, and in some situation I'm adding an additional parameter - istask - to the target url, to use latter on.

 

This is ths js function that i'm using ..

navigateIntoWFTask = function(Workflow,NodeId,Id,IsTask){
var url = IG.url('APLWFPROCESSOSPENDENTES/GetFollowNode').includeWorkflowContext();
var targetUrl = IG.url('Workflow/Index').includeWorkflowContext();
targetUrl.urlParams({nodeid:NodeId,workflow:Workflow,Id:Id,istask:IsTask});
IG.redirect(targetUrl.toString());
};

 

...and looking at the java console, this is working, because the additional parameter is there:

 

http://localhost/GMSC/Workflows/Form?workflow=APLWFOCORRENCIAS&lang=pt-PT&sessionid=8dacb616-91ae-4707-a59c-2983db5a6a89&WORKFLOW_PROJECT=f3caf72d-4e69-4820-afa9-877d3c8e73f9&WORKFLOW_SITE=GMSC&nodeid=310&Id=3&istask=1

 

 

On the target form, i'm using a script to chech if the url contains that parameter, but the problem is that although the parameter in the url, according to the java console, when using this function ...

 

checkWFOrigin = function(){
var loadurl = IG.url('Form').includeWorkflowContext();
alert(loadurl);
loadurl.hasUrlParam('istask');
alert(loadurl.hasUrlParam('istask'));
};

 

... I'm getting the url without the non-standard parameter

 

http://localhost/GMSC/Workflows/Form?workflow=APLWFOCORRENCIAS&lang=pt-PT&sessionid=8dacb616-91ae-4707-a59c-2983db5a6a89&WORKFLOW_PROJECT=f3caf72d-4e69-4820-afa9-877d3c8e73f9&WORKFLOW_SITE=GMSC&nodeid=310&Id=3

 

What do I have wrong to in the js function?

 

Any ideias?

 

Tks in advance.

Staff
Posts: 807
Registered: ‎10-18-2015

Re: Retrieving parameters from the URL

Hi Nuno,

 

how about using a session variable?

 

ciao,

Stefano

Stefano Turcato
Presale Engineer
Hexagon Geospatial
Highlighted
Contributor
Posts: 40
Registered: ‎04-12-2016

Re: Retrieving parameters from the URL

 

Hi Stefano,

 

Thanks for the suggestion.

 

I've created a dummy field with defaultvalue="{REQUESTCONTEXT.istask}", to check if there is a valkue for this parameter in the url, and then created a visible condition for the action based on the result of this field.

 

Tks,

 

Nuno

Do you need immediate support?
If you encounter a critical issue and need immediate assistance please submit a Service Request through our Support Portal.