File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
WebAPI/LearningHub.Nhs.Repository/Hierarchy Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -81,10 +81,10 @@ public async Task<List<CatalogueNodeVersion>> GetPublishedCatalogues()
8181 /// <returns>The <see cref="Task"/>.</returns>
8282 public IQueryable < CatalogueNodeVersion > GetPublishedCataloguesForUserAsync ( int userId )
8383 {
84- var communityCatalogue = this . DbContext . CatalogueNodeVersion . AsNoTracking ( )
85- . Include ( cnv => cnv . NodeVersion . Node )
86- . Where ( cnv => cnv . NodeVersion . VersionStatusEnum == VersionStatusEnum . Published
87- && cnv . NodeVersion . NodeId == 1 /* Community Catalogue */ ) ;
84+ //// var communityCatalogue = this.DbContext.CatalogueNodeVersion.AsNoTracking()
85+ //// .Include(cnv => cnv.NodeVersion.Node)
86+ //// .Where(cnv => cnv.NodeVersion.VersionStatusEnum == VersionStatusEnum.Published
87+ //// && cnv.NodeVersion.NodeId == 1 /* Community Catalogue */);
8888
8989 var cataloguesForUser = from cnv in this . DbContext . CatalogueNodeVersion . Include ( cnv => cnv . NodeVersion . Node ) . AsNoTracking ( )
9090 join nv in this . DbContext . NodeVersion . Where ( cnv => cnv . VersionStatusEnum == VersionStatusEnum . Published && ! cnv . Deleted ) // .Include(nv => nv.Node)
@@ -99,7 +99,7 @@ join n in this.DbContext.Node.Where(x => !x.Deleted)
9999 on nv . Id equals n . CurrentNodeVersionId
100100 select cnv ;
101101
102- var returnedCatalogues = communityCatalogue . Union ( cataloguesForUser ) . Distinct ( )
102+ var returnedCatalogues = cataloguesForUser . Distinct ( )
103103 . OrderBy ( cnv => cnv . NodeVersion . NodeId != 1 )
104104 . ThenBy ( cnv => cnv . Name ) ;
105105
You can’t perform that action at this time.
0 commit comments