5 Replies Latest reply on May 9, 2014 2:53 PM by Erik Hooper

    Custom Crew Filter in 10.1

    Preston Kitzmann

      I see starting in 10.3 Responder for trees uses the new Data View Filter and  no longer supports vbs.  Are custom evaluators not supported in the new Data View Filter?  Specifically I am trying to create a new crew filter...

       

      Below is my configuration in the ControlStylesConfig.xml for the Crews table:

       

      <FilterFinder Key="Assigned_Crews" FilterFinderType="Filter">

              <Evaluator>Obj:DEA.OMS.Evaluators.CrewAvailable,DEA.OMS.Evaluators</Evaluator>

              <Caption>Assigned Crews</Caption>

              <Description>Assigned Crews</Description>

      </FilterFinder>

       

      Here is the code:

       

      namespace DEA.OMS.Evaluators
      {
          public class CrewAvailable : EvaluatorBase
          {
              public override bool EvaluateToBool(DataRow dataRow, bool isTableSpecific)
              {
                  bool flag = false;
                  if (DataSetConfig.GetRepresents(dataRow.Table) == RxDb.TableRepresents.Crews)
                  {
                      int StatusID = DbConvert.ToInt32(dataRow[RxDb.Tables.Crews.Status], -1);

                      if (StatusID == 0)
                      {
                          return (true);
                      }
                      else
                      {
                          return (false);
                      }
                  }

                  if (!isTableSpecific)
                  {
                      flag = true;
                  }

                  return flag;
              }
          }
      }

       

      What am I missing?