fix defect
This commit is contained in:
parent
c798439c19
commit
0a080b09e4
4 changed files with 57 additions and 12 deletions
|
|
@ -51,13 +51,20 @@ namespace BMA.EHR.Application.Repositories
|
|||
{
|
||||
try
|
||||
{
|
||||
var profile = await _dbContext.Set<Profile>().FirstOrDefaultAsync(x => x.Id == profileId);
|
||||
var profile = await _dbContext.Set<Profile>()
|
||||
.AsQueryable()
|
||||
.Include(x => x.Prefix)
|
||||
.FirstOrDefaultAsync(x => x.Id == profileId);
|
||||
|
||||
if (profile == null)
|
||||
{
|
||||
throw new Exception(GlobalMessages.DataNotFound);
|
||||
}
|
||||
else
|
||||
{
|
||||
var fullName = $"{profile.Prefix.Name}{profile.FirstName} {profile.LastName}";
|
||||
Console.WriteLine(fullName);
|
||||
|
||||
profile.DutyTimeId = roundId;
|
||||
profile.DutyTimeEffectiveDate = effectiveDate;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue