예제 #1
0
 public Task <IResultList <IContentEntity> > QueryAsync(IAppEntity app, ISchemaEntity schema, Status[] status, ODataUriParser odataQuery)
 {
     if (RequiresPublished(status))
     {
         return(contentsPublished.QueryAsync(app, schema, odataQuery));
     }
     else
     {
         return(contentsDraft.QueryAsync(app, schema, odataQuery, status, true));
     }
 }
예제 #2
0
 public async Task <IResultList <IContentEntity> > QueryAsync(IAppEntity app, ISchemaEntity schema, Status[] status, Query query)
 {
     using (Profiler.TraceMethod <MongoContentRepository>("QueryAsyncByQuery"))
     {
         if (RequiresPublished(status))
         {
             return(await contentsPublished.QueryAsync(app, schema, query));
         }
         else
         {
             return(await contentsDraft.QueryAsync(app, schema, query, status, true));
         }
     }
 }