One of my modules in my app that I am developing is a workflow type piece where a member calls up with a problem and a step by step process is done to complete the solution. Throughout the process the user selects steps from a drop down list that signify what was done to complete it. There are two types of steps that can be done, generics steps that can occur in any order throughout the process and specfic steps that have to occur in order and certain steps can only follow other steps.
I have two tables in the database, one called AvailableGenericSteps which has a TypeCd and a ResponseCd. The other table is called AvailableNonGenericSteps which has a TypeCd, an origincd and a responsecd. Basically the typecd indicates the type of case it is.
So now I need to figure out to fill the drop down list. At the point that I am ready to fill it, I know two things, The type of problem it is and the previous step.
So in VB I did a query on the first table, AvailableGenericSteps where typecd was equal to the typecd of the case and retrieved back all the rows that qualified. I then queried the second table, AvailableNonGenericSteps with the typecd and the previous step code. I then retrieved back all the rows that qualified and unioned them with the query from the first table. Using this union, I then populated my drop down box.
In IdeaBlade I don't have a union, so any suggestions on how to do this using 2 entity lists. One entityList will have the steps retrieved back the from the AvailableGenericSteps and the other entityList will have the steps retrieved back from the AvailableNonGenericSteps. Now do I combine the two entitylists and populate the datasource of the ComboBox?
Here is what I have so far.
public void BuildStepsList()
{
RdbQuery query1 = new Query(typeof(AvailableGenericStep));
query1.AddClause(AvailableGenericStep.EventTypeCdEntityColumn, EntityTypeQueryOp.EQ, currentEvent.EventTypeCd);
EntityList<AvailableGenericStep> gSteps = myPM.GetEntities<AvailableGenericStep>(query1);
RdbQuery query2 = new Query(typeof(AvailableNonGenericStep));
query2.AddClause(AvailableNonGenericStep.EventTypeCdEntityColumn, EntityTypeQueryOp.EQ, currentEvent.EventTypeCd);
EntityList<AvailableNonGenericStep> ngSteps = myPM.GetEntities<AvailableNonGenericStep>(query2);
}
A thought just occured to me, can I do the following?
EntityList<Entity> list = new EntityList();
list.Add(nSteps);
list.Add(ngSteps);
but then how do I bind the binding source object to that????
Is this a place for a Dynamic Entity?