Change Call Org
All checks were successful
Build & Deploy Leave Service / build (push) Successful in 1m15s
All checks were successful
Build & Deploy Leave Service / build (push) Successful in 1m15s
This commit is contained in:
parent
e80f89117c
commit
46504c9e30
2 changed files with 18 additions and 9 deletions
|
|
@ -79,7 +79,8 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
||||||
|
|
||||||
public async Task UpdateLeaveUsageAsync(int year, Guid typeId, Guid userId, double day)
|
public async Task UpdateLeaveUsageAsync(int year, Guid typeId, Guid userId, double day)
|
||||||
{
|
{
|
||||||
var pf = await _userProfileRepository.GetProfileByKeycloakIdAsync(userId, AccessToken);
|
// var pf = await _userProfileRepository.GetProfileByKeycloakIdAsync(userId, AccessToken);
|
||||||
|
var pf = await _userProfileRepository.GetProfileByKeycloakIdNewAsync(userId, AccessToken);
|
||||||
if (pf == null)
|
if (pf == null)
|
||||||
{
|
{
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
|
|
@ -100,7 +101,8 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
||||||
|
|
||||||
public async Task<LeaveBeginning?> GetByYearAndTypeIdForUserAsync(int year, Guid typeId, Guid userId)
|
public async Task<LeaveBeginning?> GetByYearAndTypeIdForUserAsync(int year, Guid typeId, Guid userId)
|
||||||
{
|
{
|
||||||
var pf = await _userProfileRepository.GetProfileByKeycloakIdAsync(userId, AccessToken);
|
// var pf = await _userProfileRepository.GetProfileByKeycloakIdAsync(userId, AccessToken);
|
||||||
|
var pf = await _userProfileRepository.GetProfileByKeycloakIdNewAsync(userId, AccessToken);
|
||||||
if (pf == null)
|
if (pf == null)
|
||||||
{
|
{
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
|
|
@ -238,7 +240,8 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
||||||
|
|
||||||
public async Task<LeaveBeginning?> GetByYearAndTypeIdForUser2Async(int year, Guid typeId, Guid userId)
|
public async Task<LeaveBeginning?> GetByYearAndTypeIdForUser2Async(int year, Guid typeId, Guid userId)
|
||||||
{
|
{
|
||||||
var pf = await _userProfileRepository.GetProfileByKeycloakIdAsync(userId, AccessToken);
|
// var pf = await _userProfileRepository.GetProfileByKeycloakIdAsync(userId, AccessToken);
|
||||||
|
var pf = await _userProfileRepository.GetProfileByKeycloakIdNewAsync(userId, AccessToken);
|
||||||
if (pf == null)
|
if (pf == null)
|
||||||
{
|
{
|
||||||
return null;
|
return null;
|
||||||
|
|
|
||||||
|
|
@ -496,7 +496,8 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
||||||
|
|
||||||
public async Task<double> GetSumLeaveByTypeForUserAsync(Guid keycloakUserId, Guid leaveTypeId, int year)
|
public async Task<double> GetSumLeaveByTypeForUserAsync(Guid keycloakUserId, Guid leaveTypeId, int year)
|
||||||
{
|
{
|
||||||
var pf = await _userProfileRepository.GetProfileByKeycloakIdAsync(keycloakUserId, AccessToken);
|
// var pf = await _userProfileRepository.GetProfileByKeycloakIdAsync(keycloakUserId, AccessToken);
|
||||||
|
var pf = await _userProfileRepository.GetProfileByKeycloakIdNewAsync(keycloakUserId, AccessToken);
|
||||||
if (pf == null)
|
if (pf == null)
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
|
|
||||||
|
|
@ -632,7 +633,8 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(data.KeycloakUserId, AccessToken ?? "");
|
// var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(data.KeycloakUserId, AccessToken ?? "");
|
||||||
|
var profile = await _userProfileRepository.GetProfileByKeycloakIdNewAsync(data.KeycloakUserId, AccessToken ?? "");
|
||||||
if (profile == null)
|
if (profile == null)
|
||||||
{
|
{
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
|
|
@ -705,7 +707,8 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
}
|
}
|
||||||
|
|
||||||
var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(rawData.KeycloakUserId, AccessToken ?? "");
|
// var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(rawData.KeycloakUserId, AccessToken ?? "");
|
||||||
|
var profile = await _userProfileRepository.GetProfileByKeycloakIdNewAsync(rawData.KeycloakUserId, AccessToken ?? "");
|
||||||
if (profile == null)
|
if (profile == null)
|
||||||
{
|
{
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
|
|
@ -791,7 +794,8 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
}
|
}
|
||||||
|
|
||||||
var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(rawData.KeycloakUserId, AccessToken ?? "");
|
// var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(rawData.KeycloakUserId, AccessToken ?? "");
|
||||||
|
var profile = await _userProfileRepository.GetProfileByKeycloakIdNewAsync(rawData.KeycloakUserId, AccessToken ?? "");
|
||||||
if (profile == null)
|
if (profile == null)
|
||||||
{
|
{
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
|
|
@ -1215,7 +1219,8 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(rawData.KeycloakUserId, AccessToken);
|
// var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(rawData.KeycloakUserId, AccessToken);
|
||||||
|
var profile = await _userProfileRepository.GetProfileByKeycloakIdNewAsync(rawData.KeycloakUserId, AccessToken);
|
||||||
if (profile == null)
|
if (profile == null)
|
||||||
{
|
{
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
|
|
@ -1378,7 +1383,8 @@ namespace BMA.EHR.Application.Repositories.Leaves.LeaveRequests
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(rawData.KeycloakUserId, AccessToken);
|
// var profile = await _userProfileRepository.GetProfileByKeycloakIdAsync(rawData.KeycloakUserId, AccessToken);
|
||||||
|
var profile = await _userProfileRepository.GetProfileByKeycloakIdNewAsync(rawData.KeycloakUserId, AccessToken);
|
||||||
if (profile == null)
|
if (profile == null)
|
||||||
{
|
{
|
||||||
throw new Exception(GlobalMessages.DataNotFound);
|
throw new Exception(GlobalMessages.DataNotFound);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue