Closed felaray closed 6 months ago
I'm work for this,it's patty good!
But when I trying to use include to query relation entity,I dont how do this.
Can I use some include method like this?
Repository
public IQueryable<TEntity> List(params string[] includes) { var query = _dbEntitySet.AsQueryable(); foreach (var include in includes) query = query.Include(include); return query; }
Service
var data = _unitOfWork.GetEntityList<User>("Todo","Diary");
Please refer to Microsoft efcore documentation
https://learn.microsoft.com/en-us/ef/core/querying/related-data/eager
I'm work for this,it's patty good!
But when I trying to use include to query relation entity,I dont how do this.
Can I use some include method like this?
Repository
Service
var data = _unitOfWork.GetEntityList<User>("Todo","Diary");