Beispiel #1
0
        public virtual IOrderable[] GetChildren(CohortAggregateContainer parent)
        {
            var containers = CatalogueRepository.SelectAllWhere <CohortAggregateContainer>("SELECT CohortAggregateContainer_ChildID FROM CohortAggregateSubContainer WHERE CohortAggregateContainer_ParentID=@CohortAggregateContainer_ParentID",
                                                                                           "CohortAggregateContainer_ChildID",
                                                                                           new Dictionary <string, object>
            {
                { "CohortAggregateContainer_ParentID", parent.ID }
            }).ToArray();

            var configs = CatalogueRepository.SelectAll <AggregateConfiguration>("SELECT AggregateConfiguration_ID FROM CohortAggregateContainer_AggregateConfiguration where CohortAggregateContainer_ID=" + parent.ID).OrderBy(config => config.Order).ToArray();

            return(containers.Cast <IOrderable>().Union(configs).OrderBy(o => o.Order).ToArray());
        }
 public virtual IContainer[] GetSubContainers(IContainer container)
 {
     return
         (_catalogueRepository.SelectAll <AggregateFilterContainer>("SELECT AggregateFilterContainer_ChildID FROM AggregateFilterSubContainer WHERE AggregateFilterContainer_ParentID=" + container.ID,
                                                                    "AggregateFilterContainer_ChildID").ToArray());
 }
Beispiel #3
0
 public IEnumerable <ICatalogue> GetAllGovernedCatalogues(GovernancePeriod governancePeriod)
 {
     return(_catalogueRepository.SelectAll <Catalogue>(@"SELECT Catalogue_ID FROM GovernancePeriod_Catalogue where GovernancePeriod_ID=" + governancePeriod.ID, "Catalogue_ID"));
 }