Skip to content

Commit

Permalink
Modified tnxId keyword to txnId
Browse files Browse the repository at this point in the history
  • Loading branch information
KA40094929 authored and KA40094929 committed Dec 13, 2024
1 parent 1a2b18b commit 41a4bc0
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 11 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ public class LoginMethod {
private String loginId;
private String loginMethod;
private String pId;
private String tnxId;
private String txnId;
private String mobileNumber;
private String createdBy;
private int providerServiceMapId;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
@Data
public class RequestOTPEnrollment {

String tnxId;
String txnId;
String[] scope;
String loginHint;
String loginId;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ public String verifyOTP(String request) throws FHIRException {
JsonParser jsnParser = new JsonParser();
JsonElement jsnElmnt = jsnParser.parse(responseStrLogin);
jsnOBJ = jsnElmnt.getAsJsonObject();
resMap.put("tnxId", jsnOBJ.get("txnId").getAsString());
resMap.put("txnId", jsnOBJ.get("txnId").getAsString());
res = new Gson().toJson(resMap);
} else
throw new FHIRException("NDHM_FHIR Error while verifying the OTP");
Expand Down Expand Up @@ -210,7 +210,7 @@ public String checkAndGenerateMobileOTP(String request) throws FHIRException {
jsnOBJ = jsnElmnt.getAsJsonObject();
//String mobileLinked = jsnOBJ.get("mobileLinked").getAsString();
resMap.put("mobileLinked", jsnOBJ.get("mobileLinked").getAsString());
resMap.put("tnxId", jsnOBJ.get("txnId").getAsString());
resMap.put("txnId", jsnOBJ.get("txnId").getAsString());
res = new Gson().toJson(resMap);

} else
Expand Down Expand Up @@ -242,7 +242,7 @@ public String verifyMobileOTP(String request) throws FHIRException {
JsonParser jsnParser = new JsonParser();
JsonElement jsnElmnt = jsnParser.parse(responseStrLogin);
jsnOBJ = jsnElmnt.getAsJsonObject();
resMap.put("tnxId", jsnOBJ.get("txnId").getAsString());
resMap.put("txnId", jsnOBJ.get("txnId").getAsString());
res = new Gson().toJson(resMap);
} else
throw new FHIRException("NDHM_FHIR Error while verifiying mobile OTP");
Expand Down Expand Up @@ -367,7 +367,7 @@ public String generateMobileOTP(String request) throws FHIRException {
jsnOBJ = jsnElmnt.getAsJsonObject();
// String mobileLinked = jsnOBJ.get("mobileLinked").getAsString();
// resMap.put("mobileLinked", jsnOBJ.get("mobileLinked").getAsString());
resMap.put("tnxId", jsnOBJ.get("txnId").getAsString());
resMap.put("txnId", jsnOBJ.get("txnId").getAsString());
res = new Gson().toJson(resMap);

} else
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ public String getOtpForEnrollment(String request) throws FHIRException {
reqOtpEnrollment.setScope(new String[] { "abha-enrol" });
} else if ("MOBILE".equalsIgnoreCase(loginMethod.getLoginMethod())) {
reqOtpEnrollment.setLoginId(encryptedLoginId);
reqOtpEnrollment.setTnxId(loginMethod.getTnxId());
reqOtpEnrollment.setTxnId(loginMethod.getTxnId());
reqOtpEnrollment.setOtpSystem("abdm");
reqOtpEnrollment.setLoginHint("mobile");
reqOtpEnrollment.setScope(new String[] { "abha-enrol", "mobile-verify" });
Expand Down Expand Up @@ -276,7 +276,7 @@ public String verifyAuthByAbdm(String request) throws FHIRException {
String formattedTimestamp = now.format(formatter);
otp.setTimestamp(formattedTimestamp);

otp.setTxnId(loginMethod.getTnxId());
otp.setTxnId(loginMethod.getTxnId());
otp.setOtpValue(encryptedLoginId);

String[] scope;
Expand Down Expand Up @@ -327,7 +327,7 @@ public String formAadharEnrollReqObjByAadhar(LoginMethod loginData, String encry
String formattedTimestamp = now.format(formatter);
otp.setTimestamp(formattedTimestamp);

otp.setTxnId(loginData.getTnxId());
otp.setTxnId(loginData.getTxnId());
otp.setOtpValue(encryptedLoginId);
otp.setMobile(loginData.getMobileNumber());

Expand Down Expand Up @@ -359,7 +359,7 @@ public String formAadharEnrollReqObjByBiometric(LoginMethod loginData, String en
String formattedTimestamp = now.format(formatter);
bio.setTimestamp(formattedTimestamp);

bio.setTxnId(loginData.getTnxId());
bio.setTxnId(loginData.getTxnId());

bio.setAadhaar(encryptedLoginId);
bio.setFingerPrintAuthPid(loginData.getPId());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ public String verifyAbhaLogin(String request) throws FHIRException {

OtpRequest otp = new OtpRequest();

otp.setTxnId(loginData.getTnxId());
otp.setTxnId(loginData.getTxnId());
otp.setOtpValue(encryptedLoginId);

Map<String, Object> authDataMap = new HashMap<>();
Expand Down

0 comments on commit 41a4bc0

Please sign in to comment.