コード例 #1
0
 public async Task CreateForGroup(AddEmailToGroupViewModel model)
 {
     var recipientIds = (await _repo.GetAll()).Where(rig => rig.GroupId == model.GroupId).Select(g => g.RecipientId);
     var emails       = recipientIds.Select(rId => new Email(rId, model.TemplateId));
     await _emailRepo.CreateBatch(emails);
 }