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;
|
if (item.CitizanId == null) continue;
|
||||||
var pf = _userProfileRepository.GetOfficerProfileByCitizenId(item.CitizanId, AccessToken);
|
var pf = _userProfileRepository.GetOfficerProfileByCitizenId(item.CitizanId, AccessToken);
|
||||||
|
|
||||||
|
if (pf == null) continue;
|
||||||
var profile = insigniaNote.InsigniaNoteProfiles.FirstOrDefault(x => x.ProfileId == pf.Id);
|
var profile = insigniaNote.InsigniaNoteProfiles.FirstOrDefault(x => x.ProfileId == pf.Id);
|
||||||
if (profile == null)
|
if (profile == null)
|
||||||
continue;
|
continue;
|
||||||
|
|
@ -2243,11 +2245,11 @@ namespace BMA.EHR.Insignia.Service.Controllers
|
||||||
new
|
new
|
||||||
{
|
{
|
||||||
profile.Id,
|
profile.Id,
|
||||||
Prefix = _userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).Prefix,
|
Prefix = pf.Prefix,
|
||||||
Position = _userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).Position,
|
Position = pf.Position,
|
||||||
_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).CitizenId,
|
pf.CitizenId,
|
||||||
_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).ProfileType,
|
pf.ProfileType,
|
||||||
FullName = $"{_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).Prefix}{_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).FirstName} {_userProfileRepository.GetOfficerProfileById(profile.Id, AccessToken).LastName}",
|
FullName = $"{pf.Prefix}{pf.FirstName} {pf.LastName}",
|
||||||
RequestInsignia = profile.RequestInsignia == null ? null : profile.RequestInsignia.Name,
|
RequestInsignia = profile.RequestInsignia == null ? null : profile.RequestInsignia.Name,
|
||||||
RequestInsigniaId = profile.RequestInsignia == null ? Guid.Parse("00000000-0000-0000-0000-000000000000") : profile.RequestInsignia.Id,
|
RequestInsigniaId = profile.RequestInsignia == null ? Guid.Parse("00000000-0000-0000-0000-000000000000") : profile.RequestInsignia.Id,
|
||||||
RequestInsigniaShortName = profile.RequestInsignia == null ? null : profile.RequestInsignia.ShortName,
|
RequestInsigniaShortName = profile.RequestInsignia == null ? null : profile.RequestInsignia.ShortName,
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue