fix preview invoice api
This commit is contained in:
parent
619f54d8a9
commit
509aefabff
1 changed files with 7 additions and 5 deletions
|
|
@ -2228,6 +2228,8 @@ namespace BMA.EHR.Insignia.Service.Controllers
|
|||
{
|
||||
if (item.CitizanId == null) continue;
|
||||
var pf = _userProfileRepository.GetOfficerProfileByCitizenId(item.CitizanId, AccessToken);
|
||||
|
||||
if (pf == null) continue;
|
||||
var profile = insigniaNote.InsigniaNoteProfiles.FirstOrDefault(x => x.ProfileId == pf.Id);
|
||||
if (profile == null)
|
||||
continue;
|
||||
|
|
@ -2243,11 +2245,11 @@ namespace BMA.EHR.Insignia.Service.Controllers
|
|||
new
|
||||
{
|
||||
profile.Id,
|
||||
Prefix = _userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).Prefix,
|
||||
Position = _userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).Position,
|
||||
_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).CitizenId,
|
||||
_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).ProfileType,
|
||||
FullName = $"{_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).Prefix}{_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).FirstName} {_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).LastName}",
|
||||
Prefix = pf.Prefix,
|
||||
Position = pf.Position,
|
||||
pf.CitizenId,
|
||||
pf.ProfileType,
|
||||
FullName = $"{pf.Prefix}{pf.FirstName} {pf.LastName}",
|
||||
RequestInsignia = profile.RequestInsignia == null ? null : profile.RequestInsignia.Name,
|
||||
RequestInsigniaId = profile.RequestInsignia == null ? Guid.Parse("00000000-0000-0000-0000-000000000000") : profile.RequestInsignia.Id,
|
||||
RequestInsigniaShortName = profile.RequestInsignia == null ? null : profile.RequestInsignia.ShortName,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue