public void applyGarageFilter(String garage) {
   XxntcInventoriesVOImpl invVo = getXxntcInventoriesVO1();
   invVo.setApplyViewCriteriaName("GarageCriteria");
   VariableValueManager vvm = invVo.ensureVariableManager();
   vvm.setVariableValue("pGarage", garage);
   invVo.executeQuery();
 }
 public void applyProviderFilter(Number resourceId) {
   XxntcCsCalendarProvidersVOImpl providerVo = getXxntcCsCalendarProvidersVO1();
   providerVo.setApplyViewCriteriaName("XxntcCsCalendarProvidersVOCriteria");
   VariableValueManager vvm = providerVo.ensureVariableManager();
   vvm.setVariableValue("pResourceId", resourceId);
   providerVo.executeQuery();
 }
 public RowIterator getSuggestedTitles(String title) {
   XxntcTitlesVOImpl titlesVo = getXxntcTitlesVO1();
   ViewCriteria vc = titlesVo.getViewCriteriaManager().getViewCriteria("SuggestedTitles");
   titlesVo.setApplyViewCriteriaName("SuggestedTitles");
   VariableValueManager vvm = vc.ensureVariableManager();
   vvm.setVariableValue("pTitle", title);
   RowIterator ri =
       titlesVo.findByViewCriteria(vc, 25, ViewObject.QUERY_MODE_SCAN_DATABASE_TABLES);
   return ri;
 }
  public Row findActivityBySrNumber(String incidentNumber) {
    XxntcCsCalendarActivitiesEOVOImpl searchVo = getXxntcCsCalendarActivitiesEOVOSearch();
    searchVo.setApplyViewCriteriaName("GetSrNumberCriteria");
    VariableValueManager vvm = searchVo.ensureVariableManager();
    vvm.setVariableValue("pIncidentNumber", incidentNumber);
    vvm.setVariableValue("pResourceId", getResourceId());
    searchVo.executeQuery();
    if (searchVo.getRowCount() == 0) return null;

    return searchVo.first();
  }
  private Row getFirstDateForPlate(String plate) {
    Map<String, Object> resultMap = new HashMap<String, Object>();
    XxntcCsCalendarActivitiesEOVOImpl searchVo = getXxntcCsCalendarActivitiesEOVOSearch();
    searchVo.setApplyViewCriteriaName("GetDateCriteria");
    VariableValueManager vvm = searchVo.ensureVariableManager();
    vvm.setVariableValue("pTitle", plate);
    vvm.setVariableValue("pResourceId", getResourceId());
    searchVo.executeQuery();
    if (searchVo.getRowCount() == 0) return null;

    RowSetIterator iterator = searchVo.createRowSetIterator(null);
    iterator.reset();
    List<Row> rows = new ArrayList<Row>();
    while (iterator.hasNext()) {
      Row row = iterator.next();
      rows.add(row);
    }
    iterator.closeRowSetIterator();
    return getMaxStartTimeActRow(rows);
  }