Hexagon Geospatial
MENU

GMSC Q&A

GeoMedia Smart Client provides tools for building and delivering highly-constrained, map-based workflows for the office or the field.
Showing results for 
Search instead for 
Do you mean 

How to use Javascript to make workflow form tabs visible by default

by sclow on ‎10-25-2017 09:08 AM (333 Views)

Question

There are multiple forms shown as tabs in my GMSC workflow. When the workflow form is invoked from the client all the tabs are not visible and the user needs to click on the 'tab' icon at top right to make them visible. How can these tabs be shown automatically when the workflow form loads?

Answer

The result here is by way of responsive design. Below a specific frame size the 'tab' icon will be shown to turn on/off the tabs in the workflow. The user may avoid this my increasing the frame size manually or automatically by way of 'maximize' button.

The workflow creator may choose to have the tabs visible by default by adding the following Javascript code to the 'Javascript' value-editor for the 'Visible' property of the tab.

IG.vent.on('form:ready', function ()
{
try
{
var oToggleBTN = $('#ig-tabs-toggle');
if (oToggleBTN != undefined)
{
if (oToggleBTN != null)
{
if (oToggleBTN.length > 0 )
{
var oToggleInnerCtrl = oToggleBTN[0];
if (typeof oToggleInnerCtrl.click == "function")
{
oToggleInnerCtrl.click();
}

}
}
}
}
catch(e)
{

}
finally
{

}
});
Contributors