แก้ path call ฟยร

This commit is contained in:
Kittapath 2024-07-07 10:25:29 +07:00
parent 0b13d5ccf2
commit e556eeb314
21 changed files with 60 additions and 60 deletions

View file

@ -352,7 +352,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
var profiles = new List<OrgRequestArrayData>();
if (req.Type.Trim().ToUpper().Contains("OFFICER"))
{
var apiUrl = $"{_configuration["API"]}org/profile/profileid/retire/{req.Year}";
var apiUrl = $"{_configuration["API"]}/org/profile/profileid/retire/{req.Year}";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
@ -368,7 +368,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
}
else
{
var apiUrl = $"{_configuration["API"]}org/profile-employee/profileid/retire/{req.Year}";
var apiUrl = $"{_configuration["API"]}/org/profile-employee/profileid/retire/{req.Year}";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
@ -889,7 +889,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
if (retire.Type == "OFFICER")
{
var apiUrl = $"{_configuration["API"]}org/profile/profileid/position/{req.ProfileId}";
var apiUrl = $"{_configuration["API"]}/org/profile/profileid/position/{req.ProfileId}";
using (var client = new HttpClient())
{
var data = new RetirementProfile
@ -958,7 +958,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
}
else
{
var apiUrl = $"{_configuration["API"]}org/profile-employee/profileid/position/{req.ProfileId}";
var apiUrl = $"{_configuration["API"]}/org/profile-employee/profileid/position/{req.ProfileId}";
using (var client = new HttpClient())
{
var data = new RetirementProfile

View file

@ -83,7 +83,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
var child2Id = "";
var child3Id = "";
var child4Id = "";
var apiUrl = $"{_configuration["API"]}org/profile/keycloak/position";
var apiUrl = $"{_configuration["API"]}/org/profile/keycloak/position";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
@ -279,7 +279,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
LastUpdateUserId = UserId ?? "",
LastUpdatedAt = DateTime.Now,
};
var apiUrl = $"{_configuration["API"]}org/profile/profileid/position/{req.ProfileId}";
var apiUrl = $"{_configuration["API"]}/org/profile/profileid/position/{req.ProfileId}";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
@ -323,7 +323,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
//await _context.SaveChangesAsync();
var _baseAPI = _configuration["API"];
var _apiUrl = $"{_baseAPI}org/profile/leave/{req.ProfileId}";
var _apiUrl = $"{_baseAPI}/org/profile/leave/{req.ProfileId}";
using (var client = new HttpClient())
{
@ -567,7 +567,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
LastUpdatedAt = DateTime.Now,
};
var apiUrl = $"{_configuration["API"]}org/profile/profileid/position/{item.ProfileId}";
var apiUrl = $"{_configuration["API"]}/org/profile/profileid/position/{item.ProfileId}";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));

View file

@ -72,7 +72,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
var child2Id = "";
var child3Id = "";
var child4Id = "";
var apiUrl = $"{_configuration["API"]}org/profile/keycloak/position";
var apiUrl = $"{_configuration["API"]}/org/profile/keycloak/position";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
@ -304,7 +304,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
LastUpdateUserId = UserId ?? "",
LastUpdatedAt = DateTime.Now,
};
var apiUrl = $"{_configuration["API"]}org/profile/profileid/position/{req.Id}";
var apiUrl = $"{_configuration["API"]}/org/profile/profileid/position/{req.Id}";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));

View file

@ -72,7 +72,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
var child2Id = "";
var child3Id = "";
var child4Id = "";
var apiUrl = $"{_configuration["API"]}org/profile/keycloak/position";
var apiUrl = $"{_configuration["API"]}/org/profile/keycloak/position";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
@ -265,7 +265,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
LastUpdateUserId = UserId ?? "",
LastUpdatedAt = DateTime.Now,
};
var apiUrl = $"{_configuration["API"]}org/profile/profileid/position/{req.Id}";
var apiUrl = $"{_configuration["API"]}/org/profile/profileid/position/{req.Id}";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));

View file

@ -124,7 +124,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
[HttpGet("user")]
public async Task<ActionResult<ResponseObject>> GetListByProfile()
{
var apiUrl = $"{_configuration["API"]}org/profile/keycloak/position";
var apiUrl = $"{_configuration["API"]}/org/profile/keycloak/position";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));
@ -413,7 +413,7 @@ namespace BMA.EHR.Retirement.Service.Controllers
LastUpdatedAt = DateTime.Now,
};
var apiUrl = $"{_configuration["API"]}org/profile/keycloak/position";
var apiUrl = $"{_configuration["API"]}/org/profile/keycloak/position";
using (var client = new HttpClient())
{
client.DefaultRequestHeaders.Authorization = new AuthenticationHeaderValue("Bearer", token.Replace("Bearer ", ""));