Skip to content
Merged
Changes from all commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
104547d
Reverted Changes
ravishanigarapu Dec 24, 2024
85ca627
removed Unused imports
ravishanigarapu Dec 24, 2024
efe5412
Merge branch 'PSMRI:develop' into develop
ravishanigarapu Jan 9, 2025
f30feda
Merge branch 'PSMRI:develop' into develop
ravishanigarapu Feb 24, 2025
25d6cbe
Merge branch 'PSMRI:develop' into develop
ravishanigarapu Feb 28, 2025
1e675d9
Merge branch 'PSMRI:develop' into develop
ravishanigarapu Apr 7, 2025
6f93e13
Update application.properties
ravishanigarapu Apr 7, 2025
9ea499d
Merge branch 'PSMRI:develop' into develop
ravishanigarapu Apr 17, 2025
fe1908c
Swagger changes
ravishanigarapu Apr 17, 2025
3602722
Merge branch 'PSMRI:develop' into develop
ravishanigarapu May 14, 2025
e37d6ba
Null Condition Added
ravishanigarapu May 14, 2025
2e2d733
Merge branch 'PSMRI:develop' into develop
ravishanigarapu May 20, 2025
35237c1
AMM-1456
ravishanigarapu May 20, 2025
36dbe68
Indent format
ravishanigarapu May 20, 2025
3498d85
User-Agent validation
ravishanigarapu May 22, 2025
681977d
wrapper class added
ravishanigarapu May 22, 2025
f29182e
RestTemplateUtil class created for Headers
ravishanigarapu May 22, 2025
44a9c0e
code rabbit issues fixed
ravishanigarapu May 22, 2025
4d24d28
if condition added
ravishanigarapu May 22, 2025
97659e7
null check
ravishanigarapu May 22, 2025
0987627
Merge branch 'develop' into develop
ravishanigarapu May 22, 2025
72e5839
loggers Added
ravishanigarapu May 23, 2025
b6c2e1d
Merge branch 'PSMRI:develop' into develop
ravishanigarapu May 23, 2025
3375310
Merge branch 'develop' of https://github.com/ravishanigarapu/TM-API i…
ravishanigarapu May 23, 2025
8f00997
null check
ravishanigarapu May 23, 2025
338b0ae
Merge branch 'PSMRI:develop' into develop
ravishanigarapu May 23, 2025
81c0e8b
Added BenRegID in response
ravishanigarapu May 23, 2025
3c74457
TM-API registration api responce structure modified
ravishanigarapu May 24, 2025
242294e
unused variable removed
ravishanigarapu May 24, 2025
c050ae8
Merge branch 'develop' into develop
ravishanigarapu May 24, 2025
115db15
Coderabbit comments addressed
ravishanigarapu May 24, 2025
5bcd216
message
ravishanigarapu May 24, 2025
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 @@ -657,7 +657,8 @@ public String registerBeneficiary(String comingRequest, String Authorization) th
OutputResponse response1 = new OutputResponse();
Long beneficiaryRegID = null;
Long beneficiaryID = null;

Map<String, Object> responseMap = new HashMap<>();

RestTemplate restTemplate = new RestTemplate();
HttpEntity<Object> request = RestTemplateUtil.createRequestEntity(comingRequest, Authorization);
logger.info("Before Calling Common-API registration : "+request.getHeaders());
Expand All @@ -668,23 +669,24 @@ public String registerBeneficiary(String comingRequest, String Authorization) th
JSONObject responseOBJ = new JSONObject(responseStr);
beneficiaryRegID = responseOBJ.getJSONObject("data").getLong("beneficiaryRegID");
beneficiaryID = responseOBJ.getJSONObject("data").getLong("beneficiaryID");
// System.out.println("hello");
responseMap.put("benGenId", beneficiaryID);
responseMap.put("benRegId", beneficiaryRegID);

BeneficiaryFlowStatus obj = InputMapper.gson().fromJson(comingRequest, BeneficiaryFlowStatus.class);
if (obj != null && obj.getIsMobile() != null && obj.getIsMobile()) {
response1.setResponse("Beneficiary successfully registered. Beneficiary ID is : " + beneficiaryID +"and BenRegID is : "+beneficiaryRegID);
responseMap.put("response", "Beneficiary successfully registered. Beneficiary ID is : "+beneficiaryID);
response1.setResponse(new Gson().toJson(responseMap));

} else {
int i = commonBenStatusFlowServiceImpl.createBenFlowRecord(comingRequest, beneficiaryRegID,
beneficiaryID);

if (i > 0) {
if (i == 1)
response1.setResponse(
"Beneficiary successfully registered. Beneficiary ID is : " + beneficiaryID +"and BenRegID is : "+beneficiaryRegID);
responseMap.put("response", "Beneficiary successfully registered. Beneficiary ID is : "+beneficiaryID);
response1.setResponse(new Gson().toJson(responseMap));

} else {
response1.setError(5000, "Error in registration; please contact administrator");
// log error that beneficiaryID generated but flow part is not
// done successfully.
}
}
} else {
Expand Down
Loading