Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public class IdentityBeneficiaryServiceImpl implements IdentityBeneficiaryServic
private InputMapper inputMapper = new InputMapper();
private String identityBaseURL = ConfigProperties.getPropertyByName("identity-api-url");
private String identity1097BaseURL = ConfigProperties.getPropertyByName("identity-1097-api-url");
private static final String IDENTITY_BASE_URL = "IDENTITY_BASE_URL";
private static final String IDENTITY_BASE_URL = "https://amritdemo.piramalswasthya.org";

private static final String BEN_GEN = ConfigProperties.getPropertyByName("genben-api");
private static final String BEN_GEN_API_URL = ConfigProperties.getPropertyByName("generateBeneficiaryIDs-api-url");
Expand All @@ -79,8 +79,9 @@ public List<BeneficiariesDTO> getBeneficiaryListByIDs(HashSet benIdList, String
header.put("Authorization", auth);
}


result = httpUtils.post(ConfigProperties.getPropertyByName("identity-api-url-getByBenRegIdList").replace(
IDENTITY_BASE_URL, (is1097 ? identity1097BaseURL : identityBaseURL)), benIdList.toString(), header);
IDENTITY_BASE_URL, (is1097 ? identity1097BaseURL : "https://amritdemo.piramalswasthya.org")), benIdList.toString(), header);
OutputResponse identityResponse = inputMapper.gson().fromJson(result, OutputResponse.class);
if (identityResponse != null && identityResponse.getStatusCode() == OutputResponse.USERID_FAILURE) {
throw new IEMRException(identityResponse.getErrorMessage());
Expand Down Expand Up @@ -401,9 +402,9 @@ public String getIdentityResponse(String request, String auth, Boolean is1097) t
if (auth != null) {
header.put("Authorization", auth);
}
String baseUrl = is1097 ? identity1097BaseURL : identityBaseURL;
String apiUrl = baseUrl + ConfigProperties.getPropertyByName("identity-api-url-benCreate");

String apiUrl = ConfigProperties.getPropertyByName("identity-api-url-benCreate")
.replace(IDENTITY_BASE_URL, (is1097 ? identity1097BaseURL : identityBaseURL));

logger.info("Calling URL: {}", apiUrl);
logger.info("Request Payload: {}", request);
Expand Down
Loading