public async Task <int> CountAsync(string predicate, Guid identityWorkId)
 {
     using var context     = new CotorraContext(ConnectionManager.ConfigConnectionString);
     using var iRepository = new RepositoryStorage <T, CotorraContext>(context, true);
     return(await iRepository.GetCountAsync(predicate, identityWorkID : identityWorkId));
 }
 public async Task <int> CountAsync(Expression <Func <T, bool> > predicate, Guid identityWorkId)
 {
     using var context     = new CotorraGeneralContext(ConnectionManager.ConfigConnectionStringGeneral);
     using var iRepository = new RepositoryStorage <T, CotorraGeneralContext>(context, true);
     return(await iRepository.GetCountAsync(predicate, identityWorkID : identityWorkId));
 }