DashboardRelationships GetDashboardRelationships(string mon, DashboardRelationships tArg)
mon. Moniker for working with relations.
tArg. Operation execution parameters.
The GetDashboardRelationships operation gets relations settings.
To execute the operation, in the mon field specify moniker of opened information panel instance with the !Sources!data source key!Relationships postfix, and in the tArg field specify empty values or default values of the fields, which values should be obtained. Specify one element for collections. The moniker can be obtained on executing the OpenDashboard operation.
The operation results in the obtained relation settings.
Below is the example of getting the list of relations that can be used in calculated fact formulas. The request contains the moniker for working with relations and the list of settings, which values should be obtained. The response contains the obtained settings.
{
"GetDashboardRelationships" :
{
"mon" : "LKACHLFPHPFFGOAEFAJMIHOHCKLEPLKEEIENANDBMODOBJMH!M!S!PHOONDMFPHPFFGOAEGILOHDKLDDEDFAAEEJAAJAMKHGKPJBCK!Sources!1!Relationships",
"tArg" :
{
"its" :
{
"Item" :
{
"k" : "0"
}
}
}
}
}
{
"GetDashboardRelationshipsResult" :
{
"its" :
{
"Item" :
[
{
"k" : "0"
},
{
"k" : "1",
"id" : "C_PREV",
"n" : "C_PREV",
"isValid" : "1",
"isSystem" : "1"
},
{
"k" : "2",
"id" : "MONTH_PREV",
"n" : "MONTH_PREV",
"isValid" : "1",
"isSystem" : "1"
},
{
"k" : "3",
"id" : "DAY_PREV",
"n" : "DAY_PREV",
"isValid" : "1",
"isSystem" : "1"
},
{
"k" : "4",
"id" : "DOWN_PREV",
"n" : "Previous element of previous level",
"isValid" : "1",
"isSystem" : "0"
}
]
}
}
}
public static DashboardRelationships GetDashboardRelationships(string moniker, uint sourceKey)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tGet = new GetDashboardRelationships()
{
tArg = new DashboardRelationships()
{
its = new DashboardRelationship[] { new DashboardRelationship() }
},
// Moniker for working with relation
mon = moniker + "!Sources!" + sourceKey + "!Relationships"
};
// Get relation settings
var result = somClient.GetDashboardRelationships(tGet);
return result;
}
See also: