In a custom booking wizard we want to provide a drop down of all the IRD equipment. This will make sure that all the required functionality is done by the same equipment.
We are able to find the eligible resources but we would need the Link element name.
How do we retrieve this?
Keep in mind that the DVE state is not always enabled.
We found that when we set the result of the GetEligibleResources as FunctionResource we can get the DMAId and ElementId of the Main element. Doing an extra looking to get the name feels like adding a lot of overhead on the system.
List<string> irds = new List<string>();
foreach (var matchingIrdResource in matchingDemodResources)
{
var fr = matchingIrdResource as FunctionResource;
var irdMain = _engine.FindElement(fr.MainDVEDmaID, fr.MainDVEElementID);
if (irdMain != null)
{
irds.Add(irdMain.ElementName);
}
}
Hi Mieke,
If possible, set, like Jens, suggested a property in your resources that will hold the Main Element name, that will save you the extra calls.
If that is not possible, improve your algorithm by storing all the distinct ids and then only make a call for each element.