Compare commits
74
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
38979f0f94 | ||
|
|
46e50acc88 | ||
|
|
95e1c8b45d | ||
|
|
6126bc1d81 | ||
|
|
5d0f043848 | ||
|
|
a4842788c1 | ||
|
|
a9d04ee757 | ||
|
|
e3fdca6f72 | ||
|
|
0197f6951f | ||
|
|
7fac2cb590 | ||
|
|
596f519d1e | ||
|
|
705af33f1e | ||
|
|
ae298a35f6 | ||
|
|
f752ed269f | ||
|
|
d34b2e1b84 | ||
|
|
c8bc6e7f12 | ||
|
|
67be2acbc4 | ||
|
|
d3ae7decc8 | ||
|
|
a41dca5693 | ||
|
|
499bb1e995 | ||
|
|
4b5f81d0d5 | ||
|
|
0e747ed2a7 | ||
|
|
f9ba70414b | ||
|
|
d133fc0c75 | ||
|
|
a2f9ee8ed7 | ||
|
|
98ca620bb4 | ||
|
|
8ae11f86d4 | ||
|
|
eeb326a221 | ||
|
|
efd6a58b62 | ||
|
|
78c0e023d9 | ||
|
|
28cf0aa98d | ||
|
|
b3c507338e | ||
|
|
6079ce48a3 | ||
|
|
67404c2279 | ||
|
|
870c37e7f5 | ||
|
|
66a7677917 | ||
|
|
2da63b2f11 | ||
|
|
06cb102aed | ||
|
|
825e309785 | ||
|
|
abf89ce7f0 | ||
|
|
eb28221b96 | ||
|
|
29bce40c65 | ||
|
|
e21039090d | ||
|
|
699d8572a9 | ||
|
|
bb0aee2b2b | ||
|
|
13bfd34bbd | ||
|
|
fb3c5d2e96 | ||
|
|
2c4855d59a | ||
|
|
0e56b4de7b | ||
|
|
74e4f86d67 | ||
|
|
896ff1722a | ||
|
|
6ea6dc4775 | ||
|
|
1cfe331ff1 | ||
|
|
c25382bd5c | ||
|
|
fe4f653065 | ||
|
|
597f6b10d4 | ||
|
|
7e7b8ae9cf | ||
|
|
1e38efe3c0 | ||
|
|
66fceb95a1 | ||
|
|
a28f70d2a9 | ||
|
|
f15e967e58 | ||
|
|
693b0b7801 | ||
|
|
812aa3c2ff | ||
|
|
1ab2768226 | ||
|
|
08b0689209 | ||
|
|
aea3d0d3a8 | ||
|
|
c0dbf531bd | ||
|
|
d88c624d50 | ||
|
|
28708d1d74 | ||
|
|
003dd9325c | ||
|
|
9a9a07875c | ||
|
|
a210c86bcd | ||
|
|
78c38e6d74 | ||
|
|
58d450b22e |
@@ -45,6 +45,12 @@
|
|||||||
</exclusions>
|
</exclusions>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>io.github.resilience4j</groupId>
|
||||||
|
<artifactId>resilience4j-spring-boot3</artifactId>
|
||||||
|
<version>2.2.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.springframework.boot</groupId>
|
<groupId>org.springframework.boot</groupId>
|
||||||
<artifactId>spring-boot-starter-data-jpa</artifactId>
|
<artifactId>spring-boot-starter-data-jpa</artifactId>
|
||||||
@@ -159,6 +165,12 @@
|
|||||||
<version>0.11.5</version>
|
<version>0.11.5</version>
|
||||||
<scope>runtime</scope>
|
<scope>runtime</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.jsoup</groupId>
|
||||||
|
<artifactId>jsoup</artifactId>
|
||||||
|
<version>1.17.1</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
<!-- Test -->
|
<!-- Test -->
|
||||||
<dependency>
|
<dependency>
|
||||||
@@ -174,6 +186,8 @@
|
|||||||
<optional>true</optional>
|
<optional>true</optional>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|
||||||
<build>
|
<build>
|
||||||
|
|||||||
@@ -1,42 +0,0 @@
|
|||||||
package com.billpaymentservice.bbps.audit;
|
|
||||||
|
|
||||||
import java.io.Serializable;
|
|
||||||
import java.util.Date;
|
|
||||||
|
|
||||||
import org.springframework.data.annotation.CreatedBy;
|
|
||||||
import org.springframework.data.annotation.CreatedDate;
|
|
||||||
import org.springframework.data.annotation.LastModifiedBy;
|
|
||||||
import org.springframework.data.annotation.LastModifiedDate;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
|
||||||
import jakarta.persistence.MappedSuperclass;
|
|
||||||
import jakarta.persistence.Temporal;
|
|
||||||
import jakarta.persistence.TemporalType;
|
|
||||||
import lombok.Data;
|
|
||||||
|
|
||||||
@Data
|
|
||||||
@MappedSuperclass
|
|
||||||
public abstract class Auditable<U> implements Serializable {
|
|
||||||
private static final long serialVersionUID = 1L;
|
|
||||||
|
|
||||||
@CreatedDate
|
|
||||||
@Temporal(TemporalType.TIMESTAMP)
|
|
||||||
@Column(name = "create_date_time")
|
|
||||||
protected Date createDateTime;
|
|
||||||
|
|
||||||
@LastModifiedDate
|
|
||||||
@Temporal(TemporalType.TIMESTAMP)
|
|
||||||
@Column(name = "updated_date_time")
|
|
||||||
protected Date updatedDateTime;
|
|
||||||
|
|
||||||
@LastModifiedBy
|
|
||||||
@Column(name = "updated_by")
|
|
||||||
protected U updatedBy;
|
|
||||||
|
|
||||||
@CreatedBy
|
|
||||||
@Column(name = "create_by")
|
|
||||||
protected U createdBy;
|
|
||||||
|
|
||||||
@Column(name = "is_deleted")
|
|
||||||
protected boolean isDeleted = false;
|
|
||||||
}
|
|
||||||
@@ -11,9 +11,7 @@ import org.springframework.security.core.userdetails.UsernameNotFoundException;
|
|||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.entites.UserEntity;
|
import com.billpaymentservice.bbps.entites.UserEntity;
|
||||||
import com.billpaymentservice.bbps.entites.UsersDetails;
|
|
||||||
import com.billpaymentservice.bbps.repository.UserRepository;
|
import com.billpaymentservice.bbps.repository.UserRepository;
|
||||||
import com.billpaymentservice.bbps.repository.UsersDetailsRepository;
|
|
||||||
|
|
||||||
@Service
|
@Service
|
||||||
public class CustomUserDetailsService implements UserDetailsService {
|
public class CustomUserDetailsService implements UserDetailsService {
|
||||||
|
|||||||
@@ -2,13 +2,14 @@ package com.billpaymentservice.bbps.config;
|
|||||||
|
|
||||||
import java.security.cert.X509Certificate;
|
import java.security.cert.X509Certificate;
|
||||||
|
|
||||||
|
import javax.net.ssl.HttpsURLConnection;
|
||||||
import javax.net.ssl.SSLContext;
|
import javax.net.ssl.SSLContext;
|
||||||
import javax.net.ssl.TrustManager;
|
import javax.net.ssl.TrustManager;
|
||||||
import javax.net.ssl.X509TrustManager;
|
import javax.net.ssl.X509TrustManager;
|
||||||
|
|
||||||
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Bean;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
import org.springframework.http.client.HttpComponentsClientHttpRequestFactory;
|
import org.springframework.http.client.SimpleClientHttpRequestFactory;
|
||||||
import org.springframework.web.client.RestClient;
|
import org.springframework.web.client.RestClient;
|
||||||
|
|
||||||
@Configuration
|
@Configuration
|
||||||
@@ -16,24 +17,31 @@ public class RestClientConfig {
|
|||||||
|
|
||||||
@Bean
|
@Bean
|
||||||
public RestClient restClient() throws Exception {
|
public RestClient restClient() throws Exception {
|
||||||
// ✅ Create trust all SSL context
|
|
||||||
SSLContext sslContext = SSLContext.getInstance("TLS");
|
// Create Trust-All SSL context
|
||||||
TrustManager[] trustAllCerts = new TrustManager[]{
|
TrustManager[] trustAllCerts = new TrustManager[]{
|
||||||
new X509TrustManager() {
|
new X509TrustManager() {
|
||||||
public X509Certificate[] getAcceptedIssuers() {
|
public X509Certificate[] getAcceptedIssuers() {
|
||||||
return new X509Certificate[0];
|
return new X509Certificate[0];
|
||||||
}
|
}
|
||||||
public void checkClientTrusted(X509Certificate[] certs, String authType) {
|
public void checkClientTrusted(X509Certificate[] certs, String authType) {}
|
||||||
}
|
public void checkServerTrusted(X509Certificate[] certs, String authType) {}
|
||||||
public void checkServerTrusted(X509Certificate[] certs, String authType) {
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
SSLContext sslContext = SSLContext.getInstance("TLS");
|
||||||
sslContext.init(null, trustAllCerts, new java.security.SecureRandom());
|
sslContext.init(null, trustAllCerts, new java.security.SecureRandom());
|
||||||
|
|
||||||
// ✅ Create RestClient with custom SSL context
|
// Use JDK's Simple HTTP client with custom SSL context
|
||||||
|
SimpleClientHttpRequestFactory requestFactory = new SimpleClientHttpRequestFactory();
|
||||||
|
requestFactory.setBufferRequestBody(false);
|
||||||
|
|
||||||
|
// Apply SSL context to HttpsURLConnection globally
|
||||||
|
HttpsURLConnection.setDefaultSSLSocketFactory(sslContext.getSocketFactory());
|
||||||
|
HttpsURLConnection.setDefaultHostnameVerifier((hostname, session) -> true);
|
||||||
|
|
||||||
return RestClient.builder()
|
return RestClient.builder()
|
||||||
.requestFactory(new HttpComponentsClientHttpRequestFactory())
|
.requestFactory(requestFactory)
|
||||||
.build();
|
.build();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -2,6 +2,7 @@ package com.billpaymentservice.bbps.config;
|
|||||||
|
|
||||||
import java.util.Arrays;
|
import java.util.Arrays;
|
||||||
|
|
||||||
|
import com.billpaymentservice.bbps.controller.AgentController;
|
||||||
import org.springframework.context.annotation.Bean;
|
import org.springframework.context.annotation.Bean;
|
||||||
import org.springframework.context.annotation.Configuration;
|
import org.springframework.context.annotation.Configuration;
|
||||||
import org.springframework.http.HttpMethod;
|
import org.springframework.http.HttpMethod;
|
||||||
@@ -18,13 +19,16 @@ import org.springframework.web.cors.UrlBasedCorsConfigurationSource;
|
|||||||
@EnableWebSecurity
|
@EnableWebSecurity
|
||||||
public class SecurityConfig {
|
public class SecurityConfig {
|
||||||
|
|
||||||
|
private final AgentController agentController;
|
||||||
|
|
||||||
private final JwtAuthenticationEntryPoint jwtAuthenticationEntryPoint;
|
private final JwtAuthenticationEntryPoint jwtAuthenticationEntryPoint;
|
||||||
|
|
||||||
private final JwtFilter jwtFilter;
|
private final JwtFilter jwtFilter;
|
||||||
|
|
||||||
public SecurityConfig(JwtAuthenticationEntryPoint jwtAuthenticationEntryPoint, JwtFilter jwtFilter) {
|
public SecurityConfig(JwtAuthenticationEntryPoint jwtAuthenticationEntryPoint, JwtFilter jwtFilter, AgentController agentController) {
|
||||||
this.jwtAuthenticationEntryPoint = jwtAuthenticationEntryPoint;
|
this.jwtAuthenticationEntryPoint = jwtAuthenticationEntryPoint;
|
||||||
this.jwtFilter = jwtFilter;
|
this.jwtFilter = jwtFilter;
|
||||||
|
this.agentController = agentController;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Bean
|
@Bean
|
||||||
@@ -39,7 +43,9 @@ public class SecurityConfig {
|
|||||||
"/swagger-resources/**",
|
"/swagger-resources/**",
|
||||||
"/webjars/**",
|
"/webjars/**",
|
||||||
"/error")
|
"/error")
|
||||||
.permitAll().requestMatchers(HttpMethod.OPTIONS, "/**").permitAll()
|
.permitAll()
|
||||||
|
.requestMatchers("/payment/callback/startPayment","/complaints/checkTicketStatus")
|
||||||
|
.permitAll().requestMatchers(HttpMethod.OPTIONS, "/**").permitAll()
|
||||||
.anyRequest().authenticated())
|
.anyRequest().authenticated())
|
||||||
.exceptionHandling(ex -> ex.authenticationEntryPoint(jwtAuthenticationEntryPoint))
|
.exceptionHandling(ex -> ex.authenticationEntryPoint(jwtAuthenticationEntryPoint))
|
||||||
.sessionManagement(session -> session.sessionCreationPolicy(SessionCreationPolicy.STATELESS));
|
.sessionManagement(session -> session.sessionCreationPolicy(SessionCreationPolicy.STATELESS));
|
||||||
|
|||||||
@@ -9,7 +9,6 @@ import org.springframework.web.bind.annotation.RequestBody;
|
|||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.dto.GeneralResp;
|
|
||||||
import com.billpaymentservice.bbps.dto.ResponseModel;
|
import com.billpaymentservice.bbps.dto.ResponseModel;
|
||||||
import com.billpaymentservice.bbps.dto.request.BillFetchByBillIdRequest;
|
import com.billpaymentservice.bbps.dto.request.BillFetchByBillIdRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.BillFetchByClientIdRequest;
|
import com.billpaymentservice.bbps.dto.request.BillFetchByClientIdRequest;
|
||||||
@@ -19,6 +18,14 @@ import com.billpaymentservice.bbps.dto.request.FetchBillValidatestRequest;
|
|||||||
import com.billpaymentservice.bbps.dto.response.BillDataResponse;
|
import com.billpaymentservice.bbps.dto.response.BillDataResponse;
|
||||||
import com.billpaymentservice.bbps.dto.response.FetchBillValidateResponse;
|
import com.billpaymentservice.bbps.dto.response.FetchBillValidateResponse;
|
||||||
import com.billpaymentservice.bbps.service.AgentService;
|
import com.billpaymentservice.bbps.service.AgentService;
|
||||||
|
import com.billpaymentservice.bbps.util.ApiDocCommonResponses;
|
||||||
|
import com.billpaymentservice.bbps.util.BBPSConstant;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Content;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponses;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/agent")
|
@RequestMapping("/agent")
|
||||||
@@ -31,20 +38,22 @@ public class AgentController {
|
|||||||
this.agentService = agentService;
|
this.agentService = agentService;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/requestBillFetch")
|
||||||
* Fetches bill details from external BBPS service
|
@Operation(summary = "Initiate bill fetch request", description = "This API initiates a bill fetch request for the given customer/biller details.")
|
||||||
*/
|
@ApiResponses(value = {
|
||||||
@PostMapping(value = "/requestBillFetch", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Bill fetch request initiated successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> requestBillFetch(@Validated @RequestBody FetchBillRequest fetchBillRequest) {
|
public ResponseEntity<ResponseModel> requestBillFetch(@Validated @RequestBody FetchBillRequest fetchBillRequest) {
|
||||||
|
|
||||||
ResponseModel response = agentService.initiateBillFetch(fetchBillRequest);
|
ResponseModel response = agentService.initiateBillFetch(fetchBillRequest);
|
||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/fetchBillById")
|
||||||
* Fetches bill details from external BBPS service
|
@Operation(summary = "Fetch bill details by bill ID", description = "This API retrieves bill details from the BBPS system using the provided bill ID.")
|
||||||
*/
|
@ApiResponses(value = {
|
||||||
@PostMapping(value = "/fetchBillById", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Bill details fetched successfully by bill ID", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> fetchBillById(
|
public ResponseEntity<ResponseModel> fetchBillById(
|
||||||
@Validated @RequestBody BillFetchByBillIdRequest billFetchByBillIdRequest) {
|
@Validated @RequestBody BillFetchByBillIdRequest billFetchByBillIdRequest) {
|
||||||
|
|
||||||
@@ -52,10 +61,11 @@ public class AgentController {
|
|||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/requestBillValidate")
|
||||||
* Fetches bill details validate from external BBPS service
|
@Operation(summary = "Initiate bill validation request", description = "This API validates customer input and bill details .")
|
||||||
*/
|
@ApiResponses(value = {
|
||||||
@PostMapping(value = "/requestBillValidate", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Bill validation initiated successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> requestBillValidate(
|
public ResponseEntity<ResponseModel> requestBillValidate(
|
||||||
@Validated @RequestBody FetchBillValidatestRequest fetchBillValidateRequest) {
|
@Validated @RequestBody FetchBillValidatestRequest fetchBillValidateRequest) {
|
||||||
|
|
||||||
@@ -63,10 +73,11 @@ public class AgentController {
|
|||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/requestBillValidateByBillId")
|
||||||
* Fetches bill details by bill Id from external BBPS service
|
@Operation(summary = "Bill validate by details by bill ID", description = "This API retrieves bill details from BBPS using the provided bill ID.")
|
||||||
*/
|
@ApiResponses(value = {
|
||||||
@PostMapping(value = "/requestBillValidateByBillId", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Bill details fetched successfully by bill ID", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> requestBillByBillId(
|
public ResponseEntity<ResponseModel> requestBillByBillId(
|
||||||
@Validated @RequestBody BillFetchByBillIdRequest billRequest) {
|
@Validated @RequestBody BillFetchByBillIdRequest billRequest) {
|
||||||
|
|
||||||
@@ -74,32 +85,49 @@ public class AgentController {
|
|||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/fetchBillByClientReqId", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/fetchBillByClientReqId")
|
||||||
|
@Operation(summary = "Fetch bill details by client request ID", description = "This API fetches bill details using the client-generated request ID (clientReqId).")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Bill details fetched successfully using client request ID", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> fetchBillByClientReqId(
|
public ResponseEntity<ResponseModel> fetchBillByClientReqId(
|
||||||
@Validated @RequestBody BillFetchByClientIdRequest billFetchByClientIdRequest) {
|
@Validated @RequestBody BillFetchByClientIdRequest billFetchByClientIdRequest) {
|
||||||
|
|
||||||
ResponseModel response = agentService.fetchBillByClientReqId(billFetchByClientIdRequest);
|
ResponseModel response = agentService.fetchBillByClientReqId(billFetchByClientIdRequest);
|
||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/fetchBillValidateByClientReqId", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/fetchBillValidateByClientReqId")
|
||||||
|
@Operation(summary = "Fetch bill details by client request ID", description = "This API retrieves bill details using the client's request ID (clientReqId).")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Bill details fetched successfully using client request ID", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> fetchBillValidateByClientReqId(
|
public ResponseEntity<ResponseModel> fetchBillValidateByClientReqId(
|
||||||
@Validated @RequestBody BillValidateByClientIdRequest billValidateByClientIdRequest) {
|
@Validated @RequestBody BillValidateByClientIdRequest billValidateByClientIdRequest) {
|
||||||
|
|
||||||
ResponseModel response = agentService.fetchBillValidateByClientReqId(billValidateByClientIdRequest);
|
ResponseModel response = agentService.fetchBillValidateByClientReqId(billValidateByClientIdRequest);
|
||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value="/callback/billFetch", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/callback/billFetch")
|
||||||
public ResponseEntity<ResponseModel> handleBillFetchCallback(@RequestBody BillDataResponse billDataResponse) {
|
@Operation(summary = "Handle bill fetch callback", description = "This callback API is invoked by BBPS/Biller to send bill fetch response.")
|
||||||
ResponseModel genralResp=agentService.processBillFetchCallback(billDataResponse);
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Callback received and processed successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
|
public ResponseEntity<ResponseModel> handleBillFetchCallback(@RequestBody BillDataResponse billDataResponse) {
|
||||||
|
ResponseModel genralResp = agentService.processBillFetchCallback(billDataResponse);
|
||||||
// Return a response indicating successful receipt
|
// Return a response indicating successful receipt
|
||||||
return ResponseEntity.ok(genralResp);
|
return ResponseEntity.ok(genralResp);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value="/callback/billValidate", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/callback/billValidate")
|
||||||
public ResponseEntity<ResponseModel> handleBillValidateCallback(@RequestBody FetchBillValidateResponse fetchBillValidateResponse) {
|
@Operation(summary = "Handle bill validate callback", description = "This callback API is triggered by BBPS/Biller to send bill validation response.")
|
||||||
ResponseModel genralResp=agentService.processBillValidateCallback(fetchBillValidateResponse);
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Callback received and processed successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
|
public ResponseEntity<ResponseModel> handleBillValidateCallback(
|
||||||
|
@RequestBody FetchBillValidateResponse fetchBillValidateResponse) {
|
||||||
|
ResponseModel genralResp = agentService.processBillValidateCallback(fetchBillValidateResponse);
|
||||||
// Return a response indicating successful receipt
|
// Return a response indicating successful receipt
|
||||||
return ResponseEntity.ok(genralResp);
|
return ResponseEntity.ok(genralResp);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -10,14 +10,18 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.dto.ResponseModel;
|
import com.billpaymentservice.bbps.dto.ResponseModel;
|
||||||
import com.billpaymentservice.bbps.dto.auth.AuthResponse;
|
|
||||||
import com.billpaymentservice.bbps.dto.response.AuthResponses;
|
|
||||||
import com.billpaymentservice.bbps.dto.auth.LoginRequest;
|
import com.billpaymentservice.bbps.dto.auth.LoginRequest;
|
||||||
import com.billpaymentservice.bbps.dto.auth.OtpSendResponse;
|
|
||||||
import com.billpaymentservice.bbps.dto.auth.RegisterRequest;
|
import com.billpaymentservice.bbps.dto.auth.RegisterRequest;
|
||||||
import com.billpaymentservice.bbps.dto.auth.VerifyOtpRequest;
|
import com.billpaymentservice.bbps.dto.auth.VerifyOtpRequest;
|
||||||
import com.billpaymentservice.bbps.service.AuthService;
|
import com.billpaymentservice.bbps.service.AuthService;
|
||||||
|
import com.billpaymentservice.bbps.util.ApiDocCommonResponses;
|
||||||
|
import com.billpaymentservice.bbps.util.BBPSConstant;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Content;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponses;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@@ -32,25 +36,42 @@ public class AuthController {
|
|||||||
this.authService = authService;
|
this.authService = authService;
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/sendOtp", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/sendOtp")
|
||||||
|
@Operation(summary = "Send OTP to user", description = "This API sends an OTP to the user's registered mobile number for authentication.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "OTP sent successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> sendOtp(@Validated @RequestBody LoginRequest request) {
|
public ResponseEntity<ResponseModel> sendOtp(@Validated @RequestBody LoginRequest request) {
|
||||||
log.info("Received sendOtp request for mobile: {}", request.getMobile());
|
log.info("Received sendOtp request for mobile: {}", request.getMobile());
|
||||||
return ResponseEntity.ok(authService.sendOtp(request));
|
return ResponseEntity.ok(authService.sendOtp(request));
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/verifyOtp", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/verifyOtp")
|
||||||
|
@Operation(summary = "Verify OTP", description = "This API verifies the OTP entered by the user and validates the authentication flow.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "OTP verified successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
|
|
||||||
public ResponseEntity<ResponseModel> verifyOtp(@Validated @RequestBody VerifyOtpRequest request) {
|
public ResponseEntity<ResponseModel> verifyOtp(@Validated @RequestBody VerifyOtpRequest request) {
|
||||||
|
|
||||||
return ResponseEntity.ok(authService.verifyOtp(request));
|
return ResponseEntity.ok(authService.verifyOtp(request));
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/register", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/register")
|
||||||
|
@Operation(summary = "Register a new user", description = "This API registers a new user into the system by validating the provided registration details.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "User registered successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> register(@Validated @RequestBody RegisterRequest request) {
|
public ResponseEntity<ResponseModel> register(@Validated @RequestBody RegisterRequest request) {
|
||||||
|
|
||||||
return ResponseEntity.ok(authService.registerUser(request));
|
return ResponseEntity.ok(authService.registerUser(request));
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping("/loginWithoutDecryption")
|
@PostMapping("/loginWithoutDecryption")
|
||||||
|
@Operation(summary = "Login without decryption (Testing Only)", description = "This API is used only for testing purposes. It authenticates the user without decrypting the credentials, typically used when token generation fails or decryption flow is not enabled.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "User authenticated successfully (Testing Only)", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> login(@RequestBody LoginRequest loginRequest) {
|
public ResponseEntity<ResponseModel> login(@RequestBody LoginRequest loginRequest) {
|
||||||
|
|
||||||
return ResponseEntity.ok(authService.authenticateUser(loginRequest));
|
return ResponseEntity.ok(authService.authenticateUser(loginRequest));
|
||||||
|
|||||||
@@ -16,10 +16,16 @@ import com.billpaymentservice.bbps.dto.request.AllMasterOptionsRequest;
|
|||||||
import com.billpaymentservice.bbps.dto.request.ComplainStatusRequest;
|
import com.billpaymentservice.bbps.dto.request.ComplainStatusRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.ComplaintRequestDTO;
|
import com.billpaymentservice.bbps.dto.request.ComplaintRequestDTO;
|
||||||
import com.billpaymentservice.bbps.dto.request.GetTicketLatestStausRequest;
|
import com.billpaymentservice.bbps.dto.request.GetTicketLatestStausRequest;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.dto.request.ViewAllComplaintsRequest;
|
|
||||||
import com.billpaymentservice.bbps.dto.request.ViewAllComplaintsTicketsRequest;
|
import com.billpaymentservice.bbps.dto.request.ViewAllComplaintsTicketsRequest;
|
||||||
import com.billpaymentservice.bbps.service.ComplainService;
|
import com.billpaymentservice.bbps.service.ComplainService;
|
||||||
|
import com.billpaymentservice.bbps.util.ApiDocCommonResponses;
|
||||||
|
import com.billpaymentservice.bbps.util.BBPSConstant;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Content;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponses;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/complaints")
|
@RequestMapping("/complaints")
|
||||||
@@ -31,19 +37,26 @@ public class ComplainController {
|
|||||||
|
|
||||||
private final ComplainService complainService;
|
private final ComplainService complainService;
|
||||||
|
|
||||||
// ✅ Constructor name fixed and variable consistent
|
|
||||||
public ComplainController(ComplainService complainService) {
|
public ComplainController(ComplainService complainService) {
|
||||||
this.complainService = complainService;
|
this.complainService = complainService;
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/addComplainTicket", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/addComplainTicket")
|
||||||
|
@Operation(summary = "Add complaint ticket", description = "This API creates a new complaint ticket based on the provided request details.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Complaint ticket created successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> addComplain(@Validated @RequestBody ComplaintRequestDTO complainRequestDTO) {
|
public ResponseEntity<ResponseModel> addComplain(@Validated @RequestBody ComplaintRequestDTO complainRequestDTO) {
|
||||||
|
|
||||||
ResponseModel response = complainService.addComplain(complainRequestDTO);
|
ResponseModel response = complainService.addComplain(complainRequestDTO);
|
||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/checkTicketStatus", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/checkTicketStatus")
|
||||||
|
@Operation(summary = "Fetch latest complaint ticket status", description = "This API retrieves the latest status of a complaint ticket based on the provided ticket ID.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Complaint ticket status fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> getComplaintStatus(
|
public ResponseEntity<ResponseModel> getComplaintStatus(
|
||||||
@Validated @RequestBody GetTicketLatestStausRequest request) {
|
@Validated @RequestBody GetTicketLatestStausRequest request) {
|
||||||
log.info("Received complaint status request for complaintId: {}", request.getTicketId());
|
log.info("Received complaint status request for complaintId: {}", request.getTicketId());
|
||||||
@@ -51,7 +64,11 @@ public class ComplainController {
|
|||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/viewComplainsTicketHistory", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/viewComplainsTicketHistory")
|
||||||
|
@Operation(summary = "View complaint ticket history", description = "This API retrieves the full complaint history for the provided ticket ID.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Complaint ticket history fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> viewComplaintHistory(@Validated @RequestBody ComplainStatusRequest request) {
|
public ResponseEntity<ResponseModel> viewComplaintHistory(@Validated @RequestBody ComplainStatusRequest request) {
|
||||||
log.info("Received complaint View Complaint History request for ticketId: {}", request.getTicketId());
|
log.info("Received complaint View Complaint History request for ticketId: {}", request.getTicketId());
|
||||||
ResponseModel response = complainService.viewComplaintHistory(request);
|
ResponseModel response = complainService.viewComplaintHistory(request);
|
||||||
@@ -59,6 +76,10 @@ public class ComplainController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping("/viewTicketById")
|
@PostMapping("/viewTicketById")
|
||||||
|
@Operation(summary = "View complaint details by ID", description = "This API retrieves the complaint details for the given complaint ticket ID.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Complaint details fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> viewComplaintById(@Validated @RequestBody ComplainStatusRequest request) {
|
public ResponseEntity<ResponseModel> viewComplaintById(@Validated @RequestBody ComplainStatusRequest request) {
|
||||||
log.info("Received complaint View Complaint By ID request for complaintId: {}", request.getTicketId());
|
log.info("Received complaint View Complaint By ID request for complaintId: {}", request.getTicketId());
|
||||||
ResponseModel response = complainService.viewComplaintById(request);
|
ResponseModel response = complainService.viewComplaintById(request);
|
||||||
@@ -66,19 +87,33 @@ public class ComplainController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping("/allMasterOptions")
|
@PostMapping("/allMasterOptions")
|
||||||
|
@Operation(summary = "Fetch all master options by ID", description = "This API retrieves all master option values based on the provided ID.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Master options fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> getAllStatuses(@Validated @RequestBody AllMasterOptionsRequest request) {
|
public ResponseEntity<ResponseModel> getAllStatuses(@Validated @RequestBody AllMasterOptionsRequest request) {
|
||||||
return ResponseEntity.ok(complainService.getAllActiveStatuses(request));
|
return ResponseEntity.ok(complainService.getAllActiveStatuses(request));
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping("/viewAllComplaints")
|
@PostMapping("/viewAllComplaints")
|
||||||
public ResponseEntity<ResponseModel> viewAllComplaints(@RequestBody ViewAllComplaintsTicketsRequest request) {
|
@Operation(summary = "View all complaints by status type", description = "This API retrieves all complaints filtered by the provided status type.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "All complaints fetched successfully based on status type", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
|
public ResponseEntity<ResponseModel> viewAllComplaints(
|
||||||
|
@Validated @RequestBody ViewAllComplaintsTicketsRequest request) {
|
||||||
log.info("Received request complaint View All Complaints for Status Type={}", request.getStatusType());
|
log.info("Received request complaint View All Complaints for Status Type={}", request.getStatusType());
|
||||||
ResponseModel response = complainService.ViewAllComplaints(request);
|
ResponseModel response = complainService.ViewAllComplaints(request);
|
||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/viewAllComplaintsByUserId", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/viewAllComplaintsByUserId")
|
||||||
public ResponseEntity<ResponseModel> viewAllComplaintsByUserId(@Validated @RequestBody AllMasterOptionsRequest request) {
|
@Operation(summary = "View all complaints by user ID", description = "This API retrieves all complaint tickets associated with the provided user ID.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "All complaints fetched successfully by user ID", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
|
public ResponseEntity<ResponseModel> viewAllComplaintsByUserId(
|
||||||
|
@Validated @RequestBody AllMasterOptionsRequest request) {
|
||||||
ResponseModel response = complainService.viewAllComplaintsByUserId(request);
|
ResponseModel response = complainService.viewAllComplaintsByUserId(request);
|
||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -16,13 +16,18 @@ import com.billpaymentservice.bbps.dto.request.BillerDetailRequest;
|
|||||||
import com.billpaymentservice.bbps.dto.request.ContactMasterRequest;
|
import com.billpaymentservice.bbps.dto.request.ContactMasterRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.CustomParamRequest;
|
import com.billpaymentservice.bbps.dto.request.CustomParamRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.DispositionRequest;
|
import com.billpaymentservice.bbps.dto.request.DispositionRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.LoginRequest;
|
|
||||||
import com.billpaymentservice.bbps.dto.request.MasterCategoryRequest;
|
import com.billpaymentservice.bbps.dto.request.MasterCategoryRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.MasterRequest;
|
import com.billpaymentservice.bbps.dto.request.MasterRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.PlanRequest;
|
import com.billpaymentservice.bbps.dto.request.PlanRequest;
|
||||||
import com.billpaymentservice.bbps.dto.response.AuthResponses;
|
|
||||||
import com.billpaymentservice.bbps.service.MasterDataService;
|
import com.billpaymentservice.bbps.service.MasterDataService;
|
||||||
|
import com.billpaymentservice.bbps.util.ApiDocCommonResponses;
|
||||||
|
import com.billpaymentservice.bbps.util.BBPSConstant;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Content;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponses;
|
||||||
import jakarta.validation.Valid;
|
import jakarta.validation.Valid;
|
||||||
|
|
||||||
@RequestMapping("/masterData")
|
@RequestMapping("/masterData")
|
||||||
@@ -39,8 +44,12 @@ public class MasterDataController {
|
|||||||
this.masterDataService = masterDataService;
|
this.masterDataService = masterDataService;
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Get Details of the biller by billId **/
|
@PostMapping(value = "/getBillerDetails")
|
||||||
@PostMapping(value = "/getBillerDetails", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@Operation(summary = "Fetch biller details", description = "Get biller details by biller id and returns the result")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Biller details fetch successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> getBillerDetails(@Valid @RequestBody BillerDetailRequest billerDetailRequest) {
|
public ResponseEntity<ResponseModel> getBillerDetails(@Valid @RequestBody BillerDetailRequest billerDetailRequest) {
|
||||||
|
|
||||||
log.info("Received biller details request for billerId: {}", billerDetailRequest.getBillerId());
|
log.info("Received biller details request for billerId: {}", billerDetailRequest.getBillerId());
|
||||||
@@ -48,32 +57,41 @@ public class MasterDataController {
|
|||||||
return ResponseEntity.ok(masterDataService.getBillerByBillerId(billerDetailRequest));
|
return ResponseEntity.ok(masterDataService.getBillerByBillerId(billerDetailRequest));
|
||||||
}
|
}
|
||||||
|
|
||||||
/** Get Master Contact **/
|
@PostMapping(value = "/getContactMasterResponse")
|
||||||
@PostMapping(value = "/getContactMasterResponse", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@Operation(summary = "Fetch contact master data", description = "Fetch contact master and returns the response")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Fetch contact master response fetch successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> getContactMaster(
|
public ResponseEntity<ResponseModel> getContactMaster(
|
||||||
@Validated @RequestBody ContactMasterRequest contactMasterRequest) {
|
@Validated @RequestBody ContactMasterRequest contactMasterRequest) {
|
||||||
|
|
||||||
return ResponseEntity.ok(masterDataService.getContactMaster(contactMasterRequest));
|
return ResponseEntity.ok(masterDataService.getContactMaster(contactMasterRequest));
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/getDispostionDetail", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/getDispostionDetail")
|
||||||
|
@Operation(summary = "Fetch disposition details", description = "Fetch disposition details for a given ticket and return the response")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Disposition details fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
public ResponseEntity<ResponseModel> getDispostionDetail(
|
public ResponseEntity<ResponseModel> getDispostionDetail(
|
||||||
@Validated @RequestBody DispositionRequest dispositionDetailRequest) {
|
@Validated @RequestBody DispositionRequest dispositionDetailRequest) {
|
||||||
return ResponseEntity.ok(masterDataService.getDispositionDetails(dispositionDetailRequest));
|
return ResponseEntity.ok(masterDataService.getDispositionDetails(dispositionDetailRequest));
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/getTicketDispositions", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/getTicketDispositions")
|
||||||
|
@Operation(summary = "Fetch ticket disposition details", description = "Fetch ticket disposition details for a given ticket and return the response")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Ticket disposition details fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
public ResponseEntity<ResponseModel> getTicketDispositions(
|
public ResponseEntity<ResponseModel> getTicketDispositions(
|
||||||
@Validated @RequestBody DispositionRequest dispositionDetailRequest) {
|
@Validated @RequestBody DispositionRequest dispositionDetailRequest) {
|
||||||
return ResponseEntity.ok(masterDataService.getTicketDispositions(dispositionDetailRequest));
|
return ResponseEntity.ok(masterDataService.getTicketDispositions(dispositionDetailRequest));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/getCustomerParamDetails")
|
||||||
* Get CustomerParam by billerId.The parameter is different from the data we are
|
@Operation(summary = "Fetch customer parameter details by biller ID", description = "API fetches the customer parameter configuration based on the provided biller ID.")
|
||||||
* getting in the billerDetail
|
@ApiResponses(value = {
|
||||||
**/
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Customer parameter details fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
@PostMapping(value = "/getCustomerParamDetails", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
|
||||||
public ResponseEntity<ResponseModel> getCustomerParamDetails(
|
public ResponseEntity<ResponseModel> getCustomerParamDetails(
|
||||||
@Validated @RequestBody CustomParamRequest customerParamRequest) {
|
@Validated @RequestBody CustomParamRequest customerParamRequest) {
|
||||||
|
|
||||||
@@ -82,68 +100,68 @@ public class MasterDataController {
|
|||||||
return ResponseEntity.ok(masterDataService.getCustomerParamByBillerId(customerParamRequest));
|
return ResponseEntity.ok(masterDataService.getCustomerParamByBillerId(customerParamRequest));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* Get All Master Data .The parameter is different from the data we are getting
|
|
||||||
* Made By Arham in the MasterRequest
|
|
||||||
**/
|
|
||||||
@PostMapping("/getAllMastersData")
|
@PostMapping("/getAllMastersData")
|
||||||
|
@Operation(summary = "Fetch all master data", description = "API retrieves all the master data based on the provided .")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Master data fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseModel fetchMasterData(@Validated @RequestBody MasterRequest masterRequest) {
|
public ResponseModel fetchMasterData(@Validated @RequestBody MasterRequest masterRequest) {
|
||||||
return masterDataService.getMasterData(masterRequest);
|
return masterDataService.getMasterData(masterRequest);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/getMasterCategoryWise")
|
||||||
* POST Master CategoryResponseList Wise API Fetch CategoryResponseList Wise
|
@Operation(summary = "Fetch master data category-wise", description = "API retrieves master data based on the selected category.")
|
||||||
* from BBPS URL Made By Arham
|
@ApiResponses(value = {
|
||||||
**/
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Category-wise master data fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
@PostMapping(value = "/getMasterCategoryWise", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> getMasterDataCategoryWise(
|
public ResponseEntity<ResponseModel> getMasterDataCategoryWise(
|
||||||
@Valid @RequestBody MasterCategoryRequest masterRequest) {
|
@Valid @RequestBody MasterCategoryRequest masterRequest) {
|
||||||
return ResponseEntity.ok(masterDataService.fetchMasterDataCategoryWise(masterRequest));
|
return ResponseEntity.ok(masterDataService.fetchMasterDataCategoryWise(masterRequest));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/customerParamGroupsByBillerId")
|
||||||
* POST Customer Param Groups API Fetch CategoryResponseList Wise from BBPS URL
|
@Operation(summary = "Fetch customer parameter groups by biller ID", description = "API retrieves all customer parameter groups configured for the specified biller ID.")
|
||||||
* Made By Arham
|
@ApiResponses(value = {
|
||||||
**/
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Customer parameter groups fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
@PostMapping(value = "/customerParamGroupsByBillerId", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> getCustomerParamGroup(
|
public ResponseEntity<ResponseModel> getCustomerParamGroup(
|
||||||
@Validated @RequestBody BillerDetailRequest requestModel) {
|
@Validated @RequestBody BillerDetailRequest requestModel) {
|
||||||
return ResponseEntity.ok(masterDataService.fetchCustomerParamGroup(requestModel));
|
return ResponseEntity.ok(masterDataService.fetchCustomerParamGroup(requestModel));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/fetchAmountOptionsByBillerId")
|
||||||
* POST Fetch All AMount Options By Biller Id API Fetch CategoryResponseList
|
@Operation(summary = "Fetch all master amount options by biller ID", description = "API retrieves all the master amount options configured for the given biller ID.")
|
||||||
* Wise from BBPS URL Made By Arham
|
@ApiResponses(value = {
|
||||||
**/
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Master amount options fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
@PostMapping(value = "/fetchAmountOptionsByBillerId", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> fetchAllMasterAmountOptionsByBillerId(
|
public ResponseEntity<ResponseModel> fetchAllMasterAmountOptionsByBillerId(
|
||||||
@Validated @RequestBody BillerDetailRequest requestModel) {
|
@Validated @RequestBody BillerDetailRequest requestModel) {
|
||||||
return ResponseEntity.ok(masterDataService.fetchAllMasterAmountOption(requestModel));
|
return ResponseEntity.ok(masterDataService.fetchAllMasterAmountOption(requestModel));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/fetchAllPlanCategoriesByBillerId")
|
||||||
* POST Fetch All AMount Options By Biller Id API Fetch CategoryResponseList
|
@Operation(summary = "Fetch plan categories by biller ID", description = "API retrieves all plan categories available for the specified biller ID.")
|
||||||
* Wise from BBPS URL Made By Arham
|
@ApiResponses(value = {
|
||||||
**/
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Plan categories fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
@PostMapping(value = "/fetchAllPlanCategoriesByBillerId", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> fetchPlanCategories(@Validated @RequestBody BillerDetailRequest requestModel) {
|
public ResponseEntity<ResponseModel> fetchPlanCategories(@Validated @RequestBody BillerDetailRequest requestModel) {
|
||||||
return ResponseEntity.ok(masterDataService.fetchPlanCategorie(requestModel));
|
return ResponseEntity.ok(masterDataService.fetchPlanCategorie(requestModel));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/initiatingChannel")
|
||||||
* POST Fetch Initiating Channel API Fetch CategoryResponseList Wise from BBPS
|
@Operation(summary = "Fetch initiating channel details by biller ID", description = "API retrieves initiating channel information configured for the specified biller ID.")
|
||||||
* URL Made By Arham
|
@ApiResponses(value = {
|
||||||
**/
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Initiating channel details fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
@PostMapping(value = "/initiatingChannel", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> initiatingChannel(@Validated @RequestBody BillerDetailRequest requestModel) {
|
public ResponseEntity<ResponseModel> initiatingChannel(@Validated @RequestBody BillerDetailRequest requestModel) {
|
||||||
return ResponseEntity.ok(masterDataService.fetchInitiatingChannel(requestModel));
|
return ResponseEntity.ok(masterDataService.fetchInitiatingChannel(requestModel));
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
@PostMapping(value = "/fetchPlanByCategoryName")
|
||||||
* POST Fetch All AMount Options By Biller Id API Fetch CategoryResponseList
|
@Operation(summary = "Fetch plans by category name", description = "API retrieves all available plans for the specified category name.")
|
||||||
* Wise from BBPS Made By Arham URL
|
@ApiResponses(value = {
|
||||||
**/
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Plans fetched successfully based on category name", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
@PostMapping(value = "/fetchPlanByCategoryName", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> fetchPlanByCategory(@Validated @RequestBody PlanRequest requestModel) {
|
public ResponseEntity<ResponseModel> fetchPlanByCategory(@Validated @RequestBody PlanRequest requestModel) {
|
||||||
return ResponseEntity.ok(masterDataService.fetchPlanByCategories(requestModel));
|
return ResponseEntity.ok(masterDataService.fetchPlanByCategories(requestModel));
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,10 +12,16 @@ import com.billpaymentservice.bbps.dto.ResponseModel;
|
|||||||
import com.billpaymentservice.bbps.dto.request.BillPaymentRequest;
|
import com.billpaymentservice.bbps.dto.request.BillPaymentRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.TransactionStatusRequest;
|
import com.billpaymentservice.bbps.dto.request.TransactionStatusRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.TrasactionStatusByClientReqIdRequest;
|
import com.billpaymentservice.bbps.dto.request.TrasactionStatusByClientReqIdRequest;
|
||||||
import com.billpaymentservice.bbps.dto.response.TransactionStatusResponse;
|
|
||||||
import com.billpaymentservice.bbps.service.PaymentService;
|
import com.billpaymentservice.bbps.service.PaymentService;
|
||||||
import com.billpaymentservice.bbps.service.PaymentStartService;
|
import com.billpaymentservice.bbps.service.PaymentStartService;
|
||||||
import com.billpaymentservice.bbps.dto.request.PaymentStartUserRequest;
|
import com.billpaymentservice.bbps.util.ApiDocCommonResponses;
|
||||||
|
import com.billpaymentservice.bbps.util.BBPSConstant;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Content;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponses;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/agent/payment")
|
@RequestMapping("/agent/payment")
|
||||||
@@ -28,21 +34,27 @@ public class PaymentController {
|
|||||||
private final PaymentService paymentService;
|
private final PaymentService paymentService;
|
||||||
private final PaymentStartService paymentStartService;
|
private final PaymentStartService paymentStartService;
|
||||||
|
|
||||||
// New constructor used by Spring to inject both services
|
|
||||||
public PaymentController(PaymentService paymentService, PaymentStartService paymentStartService) {
|
public PaymentController(PaymentService paymentService, PaymentStartService paymentStartService) {
|
||||||
this.paymentService = paymentService;
|
this.paymentService = paymentService;
|
||||||
this.paymentStartService = paymentStartService;
|
this.paymentStartService = paymentStartService;
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/intiatePayment", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/intiatePayment")
|
||||||
|
@Operation(summary = "Initiate payment request", description = "This API initiates the payment process for the provided bill payment request.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Payment initiated successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> requestBillFetch(
|
public ResponseEntity<ResponseModel> requestBillFetch(
|
||||||
@Validated @RequestBody BillPaymentRequest billPaymentRequest) {
|
@RequestBody BillPaymentRequest billPaymentRequest) {
|
||||||
|
|
||||||
ResponseModel response = paymentService.initiatePayment(billPaymentRequest);
|
ResponseModel response = paymentService.initiatePayment(billPaymentRequest);
|
||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/checkTransactionStatus", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/checkTransactionStatus")
|
||||||
|
@Operation(summary = "Check transaction status", description = "This API checks the current status of a bill payment transaction using transactionId or clientReqId.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Transaction status fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> checkTransactionStatus(
|
public ResponseEntity<ResponseModel> checkTransactionStatus(
|
||||||
@Validated @RequestBody TransactionStatusRequest transactionStatusRequest) {
|
@Validated @RequestBody TransactionStatusRequest transactionStatusRequest) {
|
||||||
|
|
||||||
@@ -50,7 +62,11 @@ public class PaymentController {
|
|||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/checkTransactionStatusByClientReqId", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/checkTransactionStatusByClientReqId")
|
||||||
|
@Operation(summary = "Check transaction status by client request ID", description = "This API checks the payment transaction status using the client-generated request ID (clientReqId).")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Transaction status fetched successfully using clientReqId", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> checkTransactionStatusByClientReqId(
|
public ResponseEntity<ResponseModel> checkTransactionStatusByClientReqId(
|
||||||
@Validated @RequestBody TrasactionStatusByClientReqIdRequest transactionStatusRequest) {
|
@Validated @RequestBody TrasactionStatusByClientReqIdRequest transactionStatusRequest) {
|
||||||
|
|
||||||
@@ -58,8 +74,4 @@ public class PaymentController {
|
|||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package com.billpaymentservice.bbps.controller;
|
||||||
|
|
||||||
|
import org.springframework.http.MediaType;
|
||||||
|
import org.springframework.http.ResponseEntity;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import com.billpaymentservice.bbps.dto.ResponseModel;
|
||||||
|
import com.billpaymentservice.bbps.dto.request.PollBackRequest;
|
||||||
|
import com.billpaymentservice.bbps.service.PollBackService;
|
||||||
|
import com.billpaymentservice.bbps.util.ApiDocCommonResponses;
|
||||||
|
import com.billpaymentservice.bbps.util.BBPSConstant;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Content;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponses;
|
||||||
|
|
||||||
|
@RequestMapping("/payment")
|
||||||
|
@RestController
|
||||||
|
public class PaymentPollBackController {
|
||||||
|
|
||||||
|
private final PollBackService pollBackService;
|
||||||
|
|
||||||
|
public PaymentPollBackController(PollBackService pollBackService) {
|
||||||
|
this.pollBackService = pollBackService;
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping(value = "/pollback")
|
||||||
|
@Operation(summary = "Process poll-back request", description = "This API handles the poll-back request from biller.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Poll Back processed successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
|
public ResponseEntity<ResponseModel> startIntentPayment(@Validated @RequestBody PollBackRequest pollBackRequest) {
|
||||||
|
ResponseModel response = pollBackService.managePollBack(pollBackRequest);
|
||||||
|
return ResponseEntity.ok(response);
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -12,9 +12,17 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.dto.ResponseModel;
|
import com.billpaymentservice.bbps.dto.ResponseModel;
|
||||||
import com.billpaymentservice.bbps.dto.request.PaymentStartUserRequest;
|
|
||||||
import com.billpaymentservice.bbps.dto.request.CallbackRequest;
|
import com.billpaymentservice.bbps.dto.request.CallbackRequest;
|
||||||
|
import com.billpaymentservice.bbps.dto.request.PaymentStartUserRequest;
|
||||||
import com.billpaymentservice.bbps.service.PaymentStartService;
|
import com.billpaymentservice.bbps.service.PaymentStartService;
|
||||||
|
import com.billpaymentservice.bbps.util.ApiDocCommonResponses;
|
||||||
|
import com.billpaymentservice.bbps.util.BBPSConstant;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Content;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponses;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/payment")
|
@RequestMapping("/payment")
|
||||||
@@ -25,14 +33,23 @@ public class PaymentStartController {
|
|||||||
this.paymentStartService = paymentStartService;
|
this.paymentStartService = paymentStartService;
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/startWebPayment", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/startWebPayment")
|
||||||
public ResponseEntity<ResponseModel> startWebPayment(@Validated @RequestBody PaymentStartUserRequest paymentStartUserRequest) {
|
@Operation(summary = "Start web payment process", description = "This API initiates the payment process for a web-based transaction using user and bill details.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Payment process started successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
|
public ResponseEntity<ResponseModel> startWebPayment(
|
||||||
|
@Validated @RequestBody PaymentStartUserRequest paymentStartUserRequest) {
|
||||||
|
|
||||||
ResponseModel response = paymentStartService.startWebPayment(paymentStartUserRequest);
|
ResponseModel response = paymentStartService.startWebPayment(paymentStartUserRequest);
|
||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/callback/startPayment", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/callback/startPayment")
|
||||||
|
@Operation(summary = "Handle start payment callback", description = "This callback API is invoked by the payment gateway/BBPS to confirm the payment initiation status.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Start Payment Callback handled successfully", content = @Content(mediaType = "application/json")) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<Map<String, String>> handleCallback(@RequestBody CallbackRequest callbackRequest) {
|
public ResponseEntity<Map<String, String>> handleCallback(@RequestBody CallbackRequest callbackRequest) {
|
||||||
ResponseModel resp = paymentStartService.handleStartCallback(callbackRequest);
|
ResponseModel resp = paymentStartService.handleStartCallback(callbackRequest);
|
||||||
Map<String, String> result = new HashMap<>();
|
Map<String, String> result = new HashMap<>();
|
||||||
@@ -41,13 +58,16 @@ public class PaymentStartController {
|
|||||||
return ResponseEntity.ok(result);
|
return ResponseEntity.ok(result);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/startIntentPayment", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/startIntentPayment")
|
||||||
public ResponseEntity<ResponseModel> startIntentPayment(@Validated @RequestBody PaymentStartUserRequest paymentStartUserRequest) {
|
@Operation(summary = "Start intent payment process", description = "This API initiates the intent-based payment process for a user.")
|
||||||
if (this.paymentStartService == null) {
|
@ApiResponses(value = {
|
||||||
// Defensive: if bean not injected, return failure
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Intent payment started successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))), })
|
||||||
return ResponseEntity.badRequest().body(new ResponseModel("PaymentStartService not available", "FAILED", 400, null));
|
@ApiDocCommonResponses
|
||||||
}
|
public ResponseEntity<ResponseModel> startIntentPayment(
|
||||||
ResponseModel response = paymentStartService.startIntentPayment(paymentStartUserRequest);
|
@Validated @RequestBody PaymentStartUserRequest paymentStartUserRequest) {
|
||||||
return ResponseEntity.ok(response);
|
ResponseEntity.badRequest().body(new ResponseModel("PaymentStartService not available", "FAILED", 400, null));
|
||||||
}
|
|
||||||
|
ResponseModel response = paymentStartService.startIntentPayment(paymentStartUserRequest);
|
||||||
|
return ResponseEntity.ok(response);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@@ -13,7 +13,14 @@ import com.billpaymentservice.bbps.dto.ResponseModel;
|
|||||||
import com.billpaymentservice.bbps.dto.request.PaymentHistoryByTxnRequest;
|
import com.billpaymentservice.bbps.dto.request.PaymentHistoryByTxnRequest;
|
||||||
import com.billpaymentservice.bbps.dto.request.PaymentHistoryRequest;
|
import com.billpaymentservice.bbps.dto.request.PaymentHistoryRequest;
|
||||||
import com.billpaymentservice.bbps.service.TxnHistoryService;
|
import com.billpaymentservice.bbps.service.TxnHistoryService;
|
||||||
|
import com.billpaymentservice.bbps.util.ApiDocCommonResponses;
|
||||||
|
import com.billpaymentservice.bbps.util.BBPSConstant;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Content;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponse;
|
||||||
|
import io.swagger.v3.oas.annotations.responses.ApiResponses;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
@RestController
|
@RestController
|
||||||
@@ -29,7 +36,11 @@ public class TxnHistoryController {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/paymentHistoryDetails", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/paymentHistoryDetails")
|
||||||
|
@Operation(summary = "Get payment history details", description = "This API retrieves the payment history for a user based.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Payment history fetched successfully", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> getPaymentHistory(
|
public ResponseEntity<ResponseModel> getPaymentHistory(
|
||||||
@Validated @RequestBody PaymentHistoryRequest paymentHistoryRequest) {
|
@Validated @RequestBody PaymentHistoryRequest paymentHistoryRequest) {
|
||||||
|
|
||||||
@@ -37,7 +48,11 @@ public class TxnHistoryController {
|
|||||||
return ResponseEntity.ok(response);
|
return ResponseEntity.ok(response);
|
||||||
}
|
}
|
||||||
|
|
||||||
@PostMapping(value = "/paymentHistoryByTxnId", consumes = MediaType.APPLICATION_JSON_VALUE, produces = MediaType.APPLICATION_JSON_VALUE)
|
@PostMapping(value = "/paymentHistoryByTxnId")
|
||||||
|
@Operation(summary = "Get payment history by transaction ID", description = "This API retrieves the payment details for a specific transaction using the provided transaction ID.")
|
||||||
|
@ApiResponses(value = {
|
||||||
|
@ApiResponse(responseCode = BBPSConstant.OK_STR, description = "Payment history fetched successfully by transaction ID", content = @Content(mediaType = "application/json", schema = @Schema(implementation = ResponseModel.class))) })
|
||||||
|
@ApiDocCommonResponses
|
||||||
public ResponseEntity<ResponseModel> getPaymentHistoryByTxnId(
|
public ResponseEntity<ResponseModel> getPaymentHistoryByTxnId(
|
||||||
@Validated @RequestBody PaymentHistoryByTxnRequest request) {
|
@Validated @RequestBody PaymentHistoryByTxnRequest request) {
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package com.billpaymentservice.bbps.dto;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
public class ComplaintResponseDto {
|
||||||
|
|
||||||
|
private String ticketId;
|
||||||
|
private String ticketType;
|
||||||
|
private String txnNpciId;
|
||||||
|
private String status;
|
||||||
|
private String userId;
|
||||||
|
private String ticketDesp;
|
||||||
|
private String ticketDesr;
|
||||||
|
|
||||||
|
private List<ComplaintStatusDto> complaintStatusList;
|
||||||
|
private List<ComplaintHistoryDTO> historyList;
|
||||||
|
private List<ComplaintStatusDetailsDto> statusDetailsList;
|
||||||
|
private List<ViewAllComplaintDto> viewAllList;
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
package com.billpaymentservice.bbps.dto;
|
||||||
|
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
public class ComplaintStatusDetailsDto {
|
||||||
|
|
||||||
|
private String ticketStatus;
|
||||||
|
private String ticketType;
|
||||||
|
private String txnAmount;
|
||||||
|
private String billerName;
|
||||||
|
private String ticketId;
|
||||||
|
private String totalTxnAmount;
|
||||||
|
private String billCategory;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package com.billpaymentservice.bbps.dto;
|
||||||
|
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
public class ComplaintStatusDto {
|
||||||
|
|
||||||
|
private String ticketId;
|
||||||
|
private String npciTicketStatus;
|
||||||
|
private String ticketDespo;
|
||||||
|
private String createdTime;
|
||||||
|
private String npciTicketType;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,13 @@
|
|||||||
|
package com.billpaymentservice.bbps.dto;
|
||||||
|
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
public class PaymentPollBackResponse {
|
||||||
|
private String txnId;
|
||||||
|
private String orderId;
|
||||||
|
private String txnStatus;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,5 +1,6 @@
|
|||||||
package com.billpaymentservice.bbps.dto;
|
package com.billpaymentservice.bbps.dto;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
@@ -10,6 +11,7 @@ import lombok.Setter;
|
|||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
public class Tag {
|
public class Tag {
|
||||||
private String name;
|
|
||||||
private String value;
|
private String name;
|
||||||
|
private String value;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -66,9 +66,12 @@ public class TransactionDTO {
|
|||||||
private String planType;
|
private String planType;
|
||||||
|
|
||||||
// ✅ Date fields as String (for JSON compatibility)
|
// ✅ Date fields as String (for JSON compatibility)
|
||||||
private String creationDate;
|
@JsonProperty("creationDate")
|
||||||
private String modifiedDate;
|
private String creationDateBank;
|
||||||
|
@JsonProperty("modifiedDate")
|
||||||
private Long createdEpochDate;
|
private String modifiedDateBank;
|
||||||
private Long modifiedEpochDate;
|
@JsonProperty("createdEpochDate")
|
||||||
|
private Long createdEpochDateBank;
|
||||||
|
@JsonProperty("modifiedEpochDate")
|
||||||
|
private Long modifiedEpochDateBank;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,8 +22,8 @@ public class TransactionHistoryMasterDTO {
|
|||||||
private String billId;
|
private String billId;
|
||||||
private String userType;
|
private String userType;
|
||||||
private String userId;
|
private String userId;
|
||||||
private Double txnAmount;
|
private String txnAmount;
|
||||||
private Double totalTxnAmount;
|
private String totalTxnAmount;
|
||||||
private String billerId;
|
private String billerId;
|
||||||
private String billerCategory;
|
private String billerCategory;
|
||||||
private String billerName;
|
private String billerName;
|
||||||
@@ -33,15 +33,15 @@ public class TransactionHistoryMasterDTO {
|
|||||||
private String quickPay;
|
private String quickPay;
|
||||||
private String paymentMode;
|
private String paymentMode;
|
||||||
private String agentPaymentInformation;
|
private String agentPaymentInformation;
|
||||||
private Double custConvFee;
|
private String custConvFee;
|
||||||
private String currency;
|
private String currency;
|
||||||
private String status;
|
private String status;
|
||||||
private String requestedIp;
|
private String requestedIp;
|
||||||
private String customerMobNo;
|
private String customerMobNo;
|
||||||
private String macAddress;
|
private String macAddress;
|
||||||
private Double splitPayAmount;
|
private String splitPayAmount;
|
||||||
private Double couCustConvFee;
|
private String couCustConvFee;
|
||||||
private Boolean settlementVerification;
|
private String settlementVerification;
|
||||||
private String fundTxnType;
|
private String fundTxnType;
|
||||||
private String reason;
|
private String reason;
|
||||||
private String amountTags;
|
private String amountTags;
|
||||||
|
|||||||
+1
-1
@@ -11,7 +11,7 @@ public class TransactionHistoryParticularDetailsDTO {
|
|||||||
|
|
||||||
private String billerName;
|
private String billerName;
|
||||||
|
|
||||||
private Double totalTxnAmount;
|
private String totalTxnAmount;
|
||||||
|
|
||||||
private String bankTxnId;
|
private String bankTxnId;
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,20 @@
|
|||||||
|
package com.billpaymentservice.bbps.dto;
|
||||||
|
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
public class ViewAllComplaintDto {
|
||||||
|
|
||||||
|
private String ticketStatus;
|
||||||
|
private String txnAmount;
|
||||||
|
private String billerName;
|
||||||
|
private String ticketId;
|
||||||
|
private String txnNpciId;
|
||||||
|
private String ticketType;
|
||||||
|
private String createdTime;
|
||||||
|
private String billCategory;
|
||||||
|
private String totalTxnAmount;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -13,19 +13,20 @@ import lombok.Setter;
|
|||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@JsonInclude(JsonInclude.Include.NON_NULL)
|
@JsonInclude(JsonInclude.Include.NON_NULL)
|
||||||
public class AuthResponse {
|
public class AuthResponse {
|
||||||
private boolean success;
|
private boolean success;
|
||||||
private String message;
|
private String message;
|
||||||
private boolean userExists;
|
private boolean userExists;
|
||||||
private UserDto user;
|
private Object user;
|
||||||
private String token;
|
private String token;
|
||||||
|
|
||||||
public AuthResponse(boolean success, String message, boolean userExists, UserDto user) {
|
public AuthResponse(boolean success, String message, String token, Object user) {
|
||||||
this.success = success;
|
this.success = success;
|
||||||
this.message = message;
|
this.message = message;
|
||||||
this.userExists = userExists;
|
this.token = token;
|
||||||
this.user = user;
|
this.user = user;
|
||||||
}
|
}
|
||||||
public AuthResponse(boolean success, String message, String token) {
|
|
||||||
|
public AuthResponse(boolean success, String message, String token) {
|
||||||
this.success = success;
|
this.success = success;
|
||||||
this.message = message;
|
this.message = message;
|
||||||
this.token = token;
|
this.token = token;
|
||||||
|
|||||||
@@ -1,19 +1,24 @@
|
|||||||
package com.billpaymentservice.bbps.dto.auth;
|
package com.billpaymentservice.bbps.dto.auth;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotNull;
|
||||||
|
import jakarta.validation.constraints.Pattern;
|
||||||
|
import jakarta.validation.constraints.Size;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
|
||||||
|
@AllArgsConstructor
|
||||||
|
@NoArgsConstructor
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
public class LoginRequest {
|
public class LoginRequest {
|
||||||
private String mobile;
|
|
||||||
|
|
||||||
public LoginRequest() {}
|
@NotNull(message = "Mobile number cannot be null.")
|
||||||
|
@Size(min = 10, max = 10, message = "Mobile number must be exactly 10 digits.")
|
||||||
|
@Pattern(regexp = "^[0-9]{10}$", message = "Mobile number must contain only digits.")
|
||||||
|
private String mobile;
|
||||||
|
|
||||||
public LoginRequest(String mobile) {
|
|
||||||
this.mobile = mobile;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getMobile() {
|
|
||||||
return mobile;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setMobile(String mobile) {
|
|
||||||
this.mobile = mobile;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,29 +1,17 @@
|
|||||||
package com.billpaymentservice.bbps.dto.auth;
|
package com.billpaymentservice.bbps.dto.auth;
|
||||||
|
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@AllArgsConstructor
|
||||||
|
@NoArgsConstructor
|
||||||
public class OtpSendResponse {
|
public class OtpSendResponse {
|
||||||
private boolean success;
|
private boolean success;
|
||||||
private String message;
|
private String message;
|
||||||
|
|
||||||
public OtpSendResponse() {}
|
|
||||||
|
|
||||||
public OtpSendResponse(boolean success, String message) {
|
|
||||||
this.success = success;
|
|
||||||
this.message = message;
|
|
||||||
}
|
|
||||||
|
|
||||||
public boolean isSuccess() {
|
|
||||||
return success;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setSuccess(boolean success) {
|
|
||||||
this.success = success;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getMessage() {
|
|
||||||
return message;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setMessage(String message) {
|
|
||||||
this.message = message;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,15 +2,35 @@ package com.billpaymentservice.bbps.dto.auth;
|
|||||||
|
|
||||||
import com.billpaymentservice.bbps.dto.request.BaseClass;
|
import com.billpaymentservice.bbps.dto.request.BaseClass;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.Email;
|
||||||
|
import jakarta.validation.constraints.NotNull;
|
||||||
|
import jakarta.validation.constraints.Pattern;
|
||||||
|
import jakarta.validation.constraints.Size;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
public class RegisterRequest extends BaseClass {
|
public class RegisterRequest extends BaseClass {
|
||||||
|
|
||||||
|
@NotNull(message = "Mobile number cannot be null.")
|
||||||
|
@Size(min = 10, max = 10, message = "Mobile number must be exactly 10 digits.")
|
||||||
|
@Pattern(regexp = "^[0-9]{10}$", message = "Mobile number must contain only 10 digits.")
|
||||||
private String mobile;
|
private String mobile;
|
||||||
|
|
||||||
|
@NotNull(message = "Name cannot be null.")
|
||||||
|
@Size(min = 2, max = 100, message = "Name must be between 2 and 100 characters.")
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
|
@NotNull(message = "Email cannot be null.")
|
||||||
|
@Email(message = "Email must be a valid email address.")
|
||||||
private String email;
|
private String email;
|
||||||
|
|
||||||
|
@NotNull(message = "Registration token cannot be null.")
|
||||||
private String registrationToken;
|
private String registrationToken;
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -10,7 +10,7 @@ import lombok.Setter;
|
|||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
public class UserDto {
|
public class UserDto {
|
||||||
private Long id;
|
private String userId;
|
||||||
private String mobile;
|
private String mobile;
|
||||||
private String name;
|
private String name;
|
||||||
private String email;
|
private String email;
|
||||||
|
|||||||
@@ -1,30 +1,28 @@
|
|||||||
package com.billpaymentservice.bbps.dto.auth;
|
package com.billpaymentservice.bbps.dto.auth;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotNull;
|
||||||
|
import jakarta.validation.constraints.Pattern;
|
||||||
|
import jakarta.validation.constraints.Size;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
public class VerifyOtpRequest {
|
public class VerifyOtpRequest {
|
||||||
private String mobile;
|
|
||||||
private String otp;
|
|
||||||
|
|
||||||
public VerifyOtpRequest() {
|
@NotNull(message = "Mobile number cannot be null.")
|
||||||
}
|
@Size(min = 10, max = 10, message = "Mobile number must be exactly 10 digits.")
|
||||||
|
@Pattern(regexp = "^[0-9]{10}$", message = "Mobile number must contain only digits.")
|
||||||
|
private String mobile;
|
||||||
|
|
||||||
public VerifyOtpRequest(String mobile, String otp) {
|
@NotNull(message = "OTP cannot be null.")
|
||||||
this.mobile = mobile;
|
@Size(min = 6, max = 6, message = "OTP must be exactly 6 digits.")
|
||||||
this.otp = otp;
|
@Pattern(regexp = "^[0-9]{6}$", message = "OTP must contain only 6 digits.")
|
||||||
}
|
private String otp;
|
||||||
|
|
||||||
public String getMobile() {
|
|
||||||
return mobile;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setMobile(String mobile) {
|
|
||||||
this.mobile = mobile;
|
|
||||||
}
|
|
||||||
|
|
||||||
public String getOtp() {
|
|
||||||
return otp;
|
|
||||||
}
|
|
||||||
|
|
||||||
public void setOtp(String otp) {
|
|
||||||
this.otp = otp;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.Min;
|
||||||
|
import jakarta.validation.constraints.NotNull;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@@ -7,4 +9,10 @@ import lombok.Setter;
|
|||||||
@Setter
|
@Setter
|
||||||
public class AllMasterOptionsRequest extends BaseClass {
|
public class AllMasterOptionsRequest extends BaseClass {
|
||||||
|
|
||||||
|
private Integer pageNo = 0;
|
||||||
|
|
||||||
|
@NotNull(message = "pageEnd is required")
|
||||||
|
@Min(value = 1, message = "pageEnd must be greater than 0")
|
||||||
|
private Integer pageSize;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
import jakarta.validation.constraints.NotNull;
|
import jakarta.validation.constraints.NotBlank;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
@@ -12,7 +12,7 @@ import lombok.Setter;
|
|||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
public class BillFetchByBillIdRequest extends BaseClass {
|
public class BillFetchByBillIdRequest extends BaseClass {
|
||||||
|
|
||||||
@NotNull
|
@NotBlank(message = "bill id not be null")
|
||||||
private String billId;
|
private String billId;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,9 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
|
import jakarta.validation.constraints.NotNull;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@@ -8,25 +11,37 @@ import lombok.Setter;
|
|||||||
@Setter
|
@Setter
|
||||||
public class BillPaymentRequest extends BaseClass {
|
public class BillPaymentRequest extends BaseClass {
|
||||||
|
|
||||||
private String tenantId;
|
private String refId;
|
||||||
private String refId;
|
|
||||||
private String billId;
|
|
||||||
private boolean amountOptions;
|
|
||||||
private String paymentMode;
|
|
||||||
private String paymentInformation;
|
|
||||||
private String billerId;
|
|
||||||
private String billerName;
|
|
||||||
private String billerCategory;
|
|
||||||
private String macAdress;
|
|
||||||
private String customerMobNo;
|
|
||||||
private Integer txnAmount;
|
|
||||||
private String paymentRefId;
|
|
||||||
private String clientReqId;
|
|
||||||
private String paymentChannel;
|
|
||||||
|
|
||||||
private List<DeviceBlockTagRequest> deviceBlockTags;
|
private String billId;
|
||||||
private List<CustomerParamTagRequest> customerParamsRequest;
|
|
||||||
private List<RemitterIdentityRequest> remitterIdentity;
|
// Change the field to Boolean (wrapper) type to allow @NotNull validation
|
||||||
private List<AmountBreakRequest> amountBreakSet;
|
private boolean amountOptions; // Changed to Boolean (wrapper type)
|
||||||
|
|
||||||
|
private String paymentMode;
|
||||||
|
|
||||||
|
private String paymentInformation;
|
||||||
|
|
||||||
|
private String billerId;
|
||||||
|
|
||||||
|
private String billerName;
|
||||||
|
|
||||||
|
private String billerCategory;
|
||||||
|
|
||||||
|
private String macAdress;
|
||||||
|
|
||||||
|
private String customerMobNo;
|
||||||
|
|
||||||
|
private Integer txnAmount; // Changed to @NotNull as it's an Integer (non-nullable)
|
||||||
|
|
||||||
|
private String paymentRefId;
|
||||||
|
|
||||||
|
private String clientReqId;
|
||||||
|
|
||||||
|
private String paymentChannel;
|
||||||
|
|
||||||
|
private List<DeviceBlockTagRequest> deviceBlockTags;
|
||||||
|
private List<CustomerParamTagRequest> customerParams;
|
||||||
|
private List<RemitterIdentityRequest> remitterIdentity;
|
||||||
|
private List<AmountBreakRequest> amountBreakSet;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
import jakarta.validation.constraints.NotNull;
|
import jakarta.validation.constraints.NotNull;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
@@ -10,7 +11,7 @@ import lombok.ToString;
|
|||||||
@ToString(callSuper = true)
|
@ToString(callSuper = true)
|
||||||
public class BillerDetailRequest extends BaseClass{
|
public class BillerDetailRequest extends BaseClass{
|
||||||
|
|
||||||
@NotNull
|
@NotBlank(message = "biller id not be null")
|
||||||
private String billerId;
|
private String billerId;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,8 +1,13 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
|
|
||||||
public class CallbackRequest {
|
public class CallbackRequest {
|
||||||
|
@NotBlank(message = "mid is mandatory")
|
||||||
private String mid;
|
private String mid;
|
||||||
|
@NotBlank(message = "data is mandatory")
|
||||||
private String data;
|
private String data;
|
||||||
|
@NotBlank(message = "signature is mandatory")
|
||||||
private String signature;
|
private String signature;
|
||||||
|
|
||||||
public String getMid() {
|
public String getMid() {
|
||||||
|
|||||||
@@ -1,7 +1,6 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
import jakarta.validation.constraints.NotBlank;
|
import jakarta.validation.constraints.NotBlank;
|
||||||
import jakarta.validation.constraints.NotNull;
|
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
|
import jakarta.validation.constraints.NotNull;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@@ -7,9 +9,16 @@ import lombok.Setter;
|
|||||||
@Setter
|
@Setter
|
||||||
public class ComplaintRequestDTO extends BaseClass {
|
public class ComplaintRequestDTO extends BaseClass {
|
||||||
|
|
||||||
private String ticketDescription; // Complaint description that the user enters
|
@NotBlank(message = "Ticket description cannot be null.")
|
||||||
private String ticketDisposition; // Complaint disposition
|
private String ticketDescription;
|
||||||
private String ticketDispositionCode; // Type of complaint
|
|
||||||
private String txnId; // Transaction ID (optional)
|
@NotBlank(message = "Ticket disposition cannot be null.")
|
||||||
|
private String ticketDisposition;
|
||||||
|
|
||||||
|
@NotBlank(message = "Ticket disposition code cannot be null.")
|
||||||
|
private String ticketDispositionCode;
|
||||||
|
|
||||||
|
@NotBlank(message = "Transaction ID cannot be null.")
|
||||||
|
private String txnId;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
import jakarta.validation.constraints.NotNull;
|
import jakarta.validation.constraints.NotBlank;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
@@ -14,6 +14,6 @@ import lombok.ToString;
|
|||||||
@ToString
|
@ToString
|
||||||
public class CustomParamRequest extends BaseClass {
|
public class CustomParamRequest extends BaseClass {
|
||||||
|
|
||||||
@NotNull
|
@NotBlank(message = "biller id not be null")
|
||||||
private String billerId;
|
private String billerId;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -6,11 +6,13 @@ import com.billpaymentservice.bbps.dto.CustomerParamsRequest;
|
|||||||
import com.billpaymentservice.bbps.dto.RemitterIdentity;
|
import com.billpaymentservice.bbps.dto.RemitterIdentity;
|
||||||
import com.billpaymentservice.bbps.dto.Tag;
|
import com.billpaymentservice.bbps.dto.Tag;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
import lombok.ToString;
|
import lombok.ToString;
|
||||||
|
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@@ -18,19 +20,29 @@ import lombok.ToString;
|
|||||||
@ToString
|
@ToString
|
||||||
public class FetchBillRequest extends BaseClass {
|
public class FetchBillRequest extends BaseClass {
|
||||||
|
|
||||||
// private String tenantId; // M
|
@NotBlank(message = "biller id not be null")
|
||||||
private String billerId; // M
|
private String billerId;
|
||||||
private String billerName; //M
|
|
||||||
// private String digiledgeKey; // M
|
@NotBlank(message = "biller name not be null")
|
||||||
// private String agentId; // M
|
private String billerName;
|
||||||
private String billerCategory; // M
|
|
||||||
private String clientReqId; // C
|
@NotBlank(message = "biller category not be null")
|
||||||
private String macAdress; // C
|
private String billerCategory;
|
||||||
private String customerMobNo; // M
|
|
||||||
private String remitterName; // O
|
private String clientReqId;
|
||||||
private String paymentChannel; // M
|
private String macAdress;
|
||||||
private List<Tag> deviceBlockTags; // M
|
|
||||||
private CustomerParamsRequest customerParamsRequest; // M
|
@NotBlank(message = "customer mob no not be null")
|
||||||
private List<RemitterIdentity> remitterIdentity; // O
|
private String customerMobNo;
|
||||||
|
|
||||||
|
private String remitterName;
|
||||||
|
|
||||||
|
@NotBlank(message = "payment channel not be null")
|
||||||
|
private String paymentChannel;
|
||||||
|
|
||||||
|
private List<Tag> deviceBlockTags;
|
||||||
|
|
||||||
|
private CustomerParamsRequest customerParamsRequest;
|
||||||
|
private List<RemitterIdentity> remitterIdentity;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+11
-10
@@ -2,6 +2,7 @@ package com.billpaymentservice.bbps.dto.request;
|
|||||||
|
|
||||||
import com.billpaymentservice.bbps.dto.CustomerParamsRequest;
|
import com.billpaymentservice.bbps.dto.CustomerParamsRequest;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
import jakarta.validation.constraints.NotNull;
|
import jakarta.validation.constraints.NotNull;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
@@ -14,18 +15,18 @@ import lombok.Setter;
|
|||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
public class FetchBillValidatestRequest extends BaseClass {
|
public class FetchBillValidatestRequest extends BaseClass {
|
||||||
|
|
||||||
@NotNull
|
@NotBlank(message = "biller id not be null")
|
||||||
private String billerId; // Alphanumeric, Unique ID assigned by NPCI
|
private String billerId;
|
||||||
@NotNull
|
@NotBlank(message = "biller name not be null")
|
||||||
private String billerName; // String, Name of the biller
|
private String billerName;
|
||||||
@NotNull
|
@NotBlank(message = "biller category not be null")
|
||||||
private String billerCategory; // String, CategoryResponseList of the biller
|
private String billerCategory;
|
||||||
@NotNull
|
@NotBlank(message = "biller mob no not be null")
|
||||||
private String customerMobNo; // String, Mobile of the Customer
|
private String customerMobNo;
|
||||||
private String clientReqId;
|
private String clientReqId;
|
||||||
|
|
||||||
// Optional Fields
|
// Optional Fields
|
||||||
private String macAddress; // Alphanumeric MAC Address of the Agent Server
|
private String macAddress;
|
||||||
//private String clientReqId; // String, Unique id provided by the client
|
// private String clientReqId;
|
||||||
private CustomerParamsRequest customerParamsRequest; // Customer parameters for identifying the bill
|
private CustomerParamsRequest customerParamsRequest; // Customer parameters for identifying the bill
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,7 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
import jakarta.validation.constraints.Min;
|
import jakarta.validation.constraints.Min;
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
import jakarta.validation.constraints.NotNull;
|
import jakarta.validation.constraints.NotNull;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
@@ -15,7 +16,7 @@ public class MasterCategoryRequest extends BaseClass {
|
|||||||
|
|
||||||
private String billerName;
|
private String billerName;
|
||||||
|
|
||||||
@NotNull
|
@NotBlank(message = "category name not be null")
|
||||||
private String category;
|
private String category;
|
||||||
|
|
||||||
private Integer pageNo = 0;
|
private Integer pageNo = 0;
|
||||||
|
|||||||
@@ -1,5 +1,7 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.Min;
|
||||||
|
import jakarta.validation.constraints.NotNull;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@@ -7,4 +9,10 @@ import lombok.Setter;
|
|||||||
@Setter
|
@Setter
|
||||||
public class PaymentHistoryRequest extends BaseClass {
|
public class PaymentHistoryRequest extends BaseClass {
|
||||||
|
|
||||||
|
private Integer pageNo = 0;
|
||||||
|
|
||||||
|
@NotNull(message = "pageEnd is required")
|
||||||
|
@Min(value = 1, message = "pageEnd must be greater than 0")
|
||||||
|
private Integer pageSize;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ package com.billpaymentservice.bbps.dto.request;
|
|||||||
|
|
||||||
import java.io.Serializable;
|
import java.io.Serializable;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
@@ -13,13 +14,20 @@ import lombok.Setter;
|
|||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
// DTO representing the user request payload described by the user
|
// DTO representing the user request payload described by the user
|
||||||
public class PaymentStartUserRequest extends BaseClass implements Serializable {
|
public class PaymentStartUserRequest extends BaseClass implements Serializable {
|
||||||
|
@NotBlank(message = "amount can not be null")
|
||||||
private String amount;
|
private String amount;
|
||||||
private String currency;
|
@NotBlank(message = "currency can not be null")
|
||||||
private String emailId;
|
String currency;
|
||||||
|
@NotBlank(message = "customerVpa can not be null")
|
||||||
private String customerVpa;
|
private String customerVpa;
|
||||||
private String mobileNo;
|
@NotBlank(message = "txnReqType can not be null")
|
||||||
private String respUrl;
|
|
||||||
private String txnReqType;
|
private String txnReqType;
|
||||||
|
@NotBlank(message = "udf1(Latitude) can not be null")
|
||||||
|
private String udf1;
|
||||||
|
@NotBlank(message = "udf2(Longitude) can not be null")
|
||||||
|
private String udf2;
|
||||||
|
private String emailId;
|
||||||
|
private String mobileNo;
|
||||||
private String name;
|
private String name;
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,8 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.Min;
|
||||||
import jakarta.validation.constraints.NotBlank;
|
import jakarta.validation.constraints.NotBlank;
|
||||||
|
import jakarta.validation.constraints.NotNull;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
@@ -26,8 +28,9 @@ public class PlanRequest extends BaseClass {
|
|||||||
|
|
||||||
private String circle;
|
private String circle;
|
||||||
|
|
||||||
// ✅ Optional pagination parameters
|
private Integer page = 0;
|
||||||
private Integer page;
|
|
||||||
|
|
||||||
|
@NotNull(message = "pageEnd is required")
|
||||||
|
@Min(value = 1, message = "pageEnd must be greater than 0")
|
||||||
private Integer pagesize;
|
private Integer pagesize;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,13 @@
|
|||||||
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.NotBlank;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
public class PollBackRequest extends BaseClass {
|
||||||
|
|
||||||
|
@NotBlank(message = "order Id not be null")
|
||||||
|
private String orderId;
|
||||||
|
}
|
||||||
+6
-3
@@ -1,15 +1,18 @@
|
|||||||
package com.billpaymentservice.bbps.dto.request;
|
package com.billpaymentservice.bbps.dto.request;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.Min;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class ViewAllComplaintsTicketsRequest extends BaseClass{
|
public class ViewAllComplaintsTicketsRequest extends BaseClass {
|
||||||
|
|
||||||
private String statusType; // e.g. COMPLAINT_OPEN_SUCCESS
|
private String statusType; // e.g. COMPLAINT_OPEN_SUCCESS
|
||||||
private Integer pageNo; // default 0
|
@Min(value = 0, message = "Page number must be a non-negative integer.")
|
||||||
private Integer pageSize; // default 10
|
private Integer pageNo;
|
||||||
|
@Min(value = 1, message = "Page size must be at least 1.")
|
||||||
|
private Integer pageSize;
|
||||||
private String ticketType; // default 10
|
private String ticketType; // default 10
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+17
@@ -0,0 +1,17 @@
|
|||||||
|
package com.billpaymentservice.bbps.dto.response;
|
||||||
|
|
||||||
|
import com.billpaymentservice.bbps.entites.PaymentStartRecord;
|
||||||
|
import com.billpaymentservice.bbps.entites.TransactionMaster;
|
||||||
|
import lombok.AllArgsConstructor;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.NoArgsConstructor;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
public class PaymentStartWithTransactionDto {
|
||||||
|
private PaymentStartRecord paymentStartRecord;
|
||||||
|
private TransactionMaster transactionMaster;
|
||||||
|
}
|
||||||
@@ -1,6 +1,7 @@
|
|||||||
package com.billpaymentservice.bbps.dto.response;
|
package com.billpaymentservice.bbps.dto.response;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.dto.TicketDetailsDTO;
|
import com.billpaymentservice.bbps.dto.TicketDetailsDTO;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||||
|
|
||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
|
|
||||||
@@ -9,9 +10,13 @@ public class TicketCheckStatusResponse {
|
|||||||
|
|
||||||
private String refId;
|
private String refId;
|
||||||
private TicketDetailsDTO ticketDetails;
|
private TicketDetailsDTO ticketDetails;
|
||||||
|
@JsonProperty(access = JsonProperty.Access.WRITE_ONLY)
|
||||||
private String message;
|
private String message;
|
||||||
|
@JsonProperty(access = JsonProperty.Access.WRITE_ONLY)
|
||||||
private String remarks;
|
private String remarks;
|
||||||
|
@JsonProperty(access = JsonProperty.Access.WRITE_ONLY)
|
||||||
private String status;
|
private String status;
|
||||||
|
@JsonProperty(access = JsonProperty.Access.WRITE_ONLY)
|
||||||
private String statusCode;
|
private String statusCode;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ import lombok.ToString;
|
|||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@ToString
|
@ToString
|
||||||
@Table(name = "additional_info")
|
@Table(name = "bbps_additional_info")
|
||||||
public class AdditionalInfo {
|
public class AdditionalInfo {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@@ -26,11 +26,9 @@ public class AdditionalInfo {
|
|||||||
private Long id; // primary key for the table
|
private Long id; // primary key for the table
|
||||||
|
|
||||||
@Column(name = "param_config_id", nullable = false)
|
@Column(name = "param_config_id", nullable = false)
|
||||||
@NotBlank(message = "Param Config ID cannot be blank")
|
|
||||||
private String paramConfigId;
|
private String paramConfigId;
|
||||||
|
|
||||||
@Column(name = "param_name", nullable = false)
|
@Column(name = "param_name", nullable = false)
|
||||||
@NotBlank(message = "Param name cannot be blank")
|
|
||||||
private String paramName;
|
private String paramName;
|
||||||
|
|
||||||
@Column(name = "data_type_dao")
|
@Column(name = "data_type_dao")
|
||||||
|
|||||||
@@ -12,10 +12,10 @@ import lombok.Setter;
|
|||||||
|
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "additional_info_bill")
|
@Table(name = "bbps_additional_info_bill")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class AdditionalInfoBill {
|
public class AdditionalInfoBill extends Auditable {
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue
|
@GeneratedValue
|
||||||
private Long id;
|
private Long id;
|
||||||
|
|||||||
@@ -11,10 +11,10 @@ import lombok.Getter;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "additional_info_bill_validate")
|
@Table(name = "bbps_additional_info_bill_validate")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class AdditionalInfoBillValidate {
|
public class AdditionalInfoBillValidate extends Auditable {
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue
|
@GeneratedValue
|
||||||
private Long id;
|
private Long id;
|
||||||
|
|||||||
@@ -16,10 +16,10 @@ import lombok.Getter;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "plan_additional_info")
|
@Table(name = "bbps_plan_additional_info")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class AdditionalInfoPlans {
|
public class AdditionalInfoPlans extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -10,12 +10,12 @@ import lombok.NoArgsConstructor;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "agent_fund_transfer_Txn_Status")
|
@Table(name = "bbps_agent_fund_transfer_Txn_Status")
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
public class AgentFundTransfer {
|
public class AgentFundTransfer extends Auditable {
|
||||||
|
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
|
|||||||
@@ -13,8 +13,8 @@ import lombok.Setter;
|
|||||||
@Entity
|
@Entity
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Table(name = "agent_fund_transfer")
|
@Table(name = "bbps_agent_fund_transfer")
|
||||||
public class AgentFundTransferEntity {
|
public class AgentFundTransferEntity extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -34,4 +34,3 @@ public class AgentFundTransferEntity {
|
|||||||
private String txnRefId;
|
private String txnRefId;
|
||||||
private String fundStatus;
|
private String fundStatus;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -16,10 +16,10 @@ import lombok.Getter;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "amount_option")
|
@Table(name = "bbps_amount_option")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class AmountOption {
|
public class AmountOption extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "amount_option_id")
|
@Column(name = "amount_option_id")
|
||||||
|
|||||||
@@ -2,8 +2,6 @@ package com.billpaymentservice.bbps.entites;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.CascadeType;
|
import jakarta.persistence.CascadeType;
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
@@ -19,8 +17,9 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "amount_option_biller_id")
|
|
||||||
public class AmountOptionByBillerId extends Auditable<String> {
|
@Table(name = "bbps_amount_option_biller_id")
|
||||||
|
public class AmountOptionByBillerId extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -12,8 +12,9 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "amount_option_details")
|
@Table(name = "bbps_amount_option_details")
|
||||||
public class AmountOptionDetails {
|
|
||||||
|
public class AmountOptionDetails extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -35,4 +36,7 @@ public class AmountOptionDetails {
|
|||||||
@Column(name = "txn_id")
|
@Column(name = "txn_id")
|
||||||
private String txnId;
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
|
import java.lang.reflect.Field;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import jakarta.persistence.PrePersist;
|
||||||
|
import jakarta.persistence.PreUpdate;
|
||||||
|
|
||||||
|
import java.lang.reflect.Field;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
import jakarta.persistence.PrePersist;
|
||||||
|
import jakarta.persistence.PreUpdate;
|
||||||
|
|
||||||
|
public class AuditListener {
|
||||||
|
|
||||||
|
@PrePersist
|
||||||
|
public void prePersist(Object entity) {
|
||||||
|
Date now = new Date(); // current date + time
|
||||||
|
|
||||||
|
// creation fields
|
||||||
|
setIfNull(entity, "createDateTime", now);
|
||||||
|
setIfNull(entity, "createdBy", null);
|
||||||
|
setIfNull(entity, "createdEpochDate", now.getTime());
|
||||||
|
|
||||||
|
// default soft delete flag
|
||||||
|
setAlways(entity, "isDeleted", Boolean.FALSE);
|
||||||
|
}
|
||||||
|
|
||||||
|
@PreUpdate
|
||||||
|
public void preUpdate(Object entity) {
|
||||||
|
Date now = new Date();
|
||||||
|
|
||||||
|
// update fields
|
||||||
|
setAlways(entity, "updatedDateTime", now);
|
||||||
|
setIfNull(entity, "updatedBy", null);
|
||||||
|
setAlways(entity, "modifiedEpochDate", now.getTime());
|
||||||
|
}
|
||||||
|
|
||||||
|
private void setIfNull(Object entity, String fieldName, Object value) {
|
||||||
|
try {
|
||||||
|
Field f = findField(entity.getClass(), fieldName);
|
||||||
|
if (f == null) return;
|
||||||
|
|
||||||
|
boolean accessible = f.canAccess(entity);
|
||||||
|
f.setAccessible(true);
|
||||||
|
|
||||||
|
if (f.get(entity) == null) {
|
||||||
|
f.set(entity, value);
|
||||||
|
}
|
||||||
|
|
||||||
|
f.setAccessible(accessible);
|
||||||
|
} catch (Exception ignored) {}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void setAlways(Object entity, String fieldName, Object value) {
|
||||||
|
try {
|
||||||
|
Field f = findField(entity.getClass(), fieldName);
|
||||||
|
if (f == null) return;
|
||||||
|
|
||||||
|
boolean accessible = f.canAccess(entity);
|
||||||
|
f.setAccessible(true);
|
||||||
|
f.set(entity, value);
|
||||||
|
f.setAccessible(accessible);
|
||||||
|
} catch (Exception ignored) {}
|
||||||
|
}
|
||||||
|
|
||||||
|
private Field findField(Class<?> cls, String name) {
|
||||||
|
Class<?> current = cls;
|
||||||
|
while (current != null && current != Object.class) {
|
||||||
|
try {
|
||||||
|
return current.getDeclaredField(name);
|
||||||
|
} catch (NoSuchFieldException e) {
|
||||||
|
current = current.getSuperclass();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,43 @@
|
|||||||
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
import jakarta.persistence.Column;
|
||||||
|
import jakarta.persistence.EntityListeners;
|
||||||
|
import jakarta.persistence.MappedSuperclass;
|
||||||
|
import lombok.Getter;
|
||||||
|
import lombok.Setter;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Base mapped superclass for audit fields. All JPA entities should extend this
|
||||||
|
* to get automatic population of createdAt/updatedAt/isDeleted via
|
||||||
|
* AuditListener.
|
||||||
|
*/
|
||||||
|
@MappedSuperclass
|
||||||
|
@EntityListeners(AuditListener.class)
|
||||||
|
@Getter
|
||||||
|
@Setter
|
||||||
|
public abstract class Auditable implements Serializable {
|
||||||
|
@Column(name = "create_date_time")
|
||||||
|
private Date createDateTime;
|
||||||
|
|
||||||
|
@Column(name = "updated_date_time")
|
||||||
|
private Date updatedDateTime;
|
||||||
|
|
||||||
|
@Column(name = "create_by")
|
||||||
|
private String createdBy;
|
||||||
|
|
||||||
|
@Column(name = "updated_by")
|
||||||
|
private String updatedBy;
|
||||||
|
|
||||||
|
@Column(name = "created_epoch_date")
|
||||||
|
private Long createdEpochDate;
|
||||||
|
|
||||||
|
@Column(name = "modified_epoch_date")
|
||||||
|
private Long modifiedEpochDate;
|
||||||
|
|
||||||
|
@Column(name = "is_deleted")
|
||||||
|
private Boolean isDeleted = Boolean.FALSE;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,7 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
@@ -21,7 +19,7 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Table(name = "bbps_master_data")
|
@Table(name = "bbps_master_data")
|
||||||
public class BBPSMastersData extends Auditable<String> {
|
public class BBPSMastersData extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ import lombok.NoArgsConstructor;
|
|||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@Builder
|
@Builder
|
||||||
@Table(name = "bbps_merchant_validation")
|
@Table(name = "bbps_merchant_validation")
|
||||||
public class BBPSMerchantValidation {
|
public class BBPSMerchantValidation extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -42,5 +42,5 @@ public class BBPSMerchantValidation {
|
|||||||
|
|
||||||
private String txtId;
|
private String txtId;
|
||||||
|
|
||||||
private boolean is_deleted;
|
// Removed local is_deleted field, now handled by Auditable
|
||||||
}
|
}
|
||||||
@@ -1,7 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import jakarta.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
@@ -17,8 +15,8 @@ import lombok.Setter;
|
|||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "Bharat_connect_master")
|
@Table(name = "bbps_bharat_connect_master")
|
||||||
public class BharatConnectMaster extends Auditable<String> {
|
public class BharatConnectMaster extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "org_id", nullable = false, unique = true, length = 50)
|
@Column(name = "org_id", nullable = false, unique = true, length = 50)
|
||||||
|
|||||||
@@ -13,8 +13,9 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "bill_additional_info")
|
@Table(name = "bbps_bill_additional_info")
|
||||||
public class BillAdditionalInfo {
|
|
||||||
|
public class BillAdditionalInfo extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -1,5 +1,6 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
|
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
import jakarta.persistence.GenerationType;
|
import jakarta.persistence.GenerationType;
|
||||||
@@ -13,8 +14,8 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "bill_customer_params")
|
@Table(name = "bbps_bill_customer_params")
|
||||||
public class BillCustomerParams {
|
public class BillCustomerParams extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import jakarta.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
@@ -11,16 +12,20 @@ import lombok.NoArgsConstructor;
|
|||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "bill_initiate")
|
@Table(name = "bbps_bill_initiate")
|
||||||
public class BillInitiate {
|
|
||||||
@Id
|
|
||||||
@Column(name = "req_id")
|
|
||||||
private String reqId;
|
|
||||||
|
|
||||||
@Column(name = "bill_id", nullable = false)
|
public class BillInitiate extends Auditable {
|
||||||
private String billId;
|
@Id
|
||||||
|
@Column(name = "req_id")
|
||||||
|
private String reqId;
|
||||||
|
|
||||||
@Column(name = "txn_id")
|
@Column(name = "bill_id", nullable = false)
|
||||||
private String txnId;
|
private String billId;
|
||||||
|
|
||||||
|
@Column(name = "txn_id")
|
||||||
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "client_user_id")
|
||||||
|
private String clientUserId;
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -1,8 +1,12 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import jakarta.persistence.CascadeType;
|
import jakarta.persistence.CascadeType;
|
||||||
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
|
import jakarta.persistence.GeneratedValue;
|
||||||
|
import jakarta.persistence.GenerationType;
|
||||||
import jakarta.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
import jakarta.persistence.JoinColumn;
|
import jakarta.persistence.JoinColumn;
|
||||||
import jakarta.persistence.OneToMany;
|
import jakarta.persistence.OneToMany;
|
||||||
@@ -15,35 +19,38 @@ import lombok.NoArgsConstructor;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "bill_master")
|
@Table(name = "bbps_bill_master")
|
||||||
@Builder
|
@Builder
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
public class BillMaster {
|
public class BillMaster extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
private String billId; // primary key
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
private Long id;
|
||||||
|
|
||||||
private String reqId; // client se aaya hua
|
@Column(name = "bill_id", unique = true)
|
||||||
private String txnId; // system-generated
|
private String billId; // primary key
|
||||||
private String refId;
|
private String reqId; // client se aaya hua
|
||||||
private String billerId;
|
private String txnId; // system-generated
|
||||||
private String status;
|
private String refId;
|
||||||
private String actionType;
|
private String billerId;
|
||||||
private String userId;
|
private String status;
|
||||||
@OneToOne(cascade = CascadeType.ALL)
|
private String mid;
|
||||||
@JoinColumn(name = "biller_response_id")
|
private String actionType;
|
||||||
private BillerResponse billerResponse;
|
private String clientUserId;
|
||||||
@OneToMany(mappedBy = "billMaster", cascade = CascadeType.ALL)
|
private String userId;
|
||||||
private List<AdditionalInfoBill> additionalInfo;
|
@Column(name = "initiator_txn_id")
|
||||||
@OneToMany(mappedBy = "billMaster", cascade = CascadeType.ALL)
|
private String initiatorTxnId;
|
||||||
private List<CustomerParamBill> customerParams;
|
@Column(name = "checker_txn_id")
|
||||||
private String creationDate;
|
private String checkerTxnId;
|
||||||
private String modifiedDate;
|
@OneToOne(cascade = CascadeType.ALL)
|
||||||
private Long createdEpochDate;
|
@JoinColumn(name = "biller_response_id")
|
||||||
private Long modifiedEpochDate;
|
private BillerResponse billerResponse;
|
||||||
|
@OneToMany(mappedBy = "billMaster", cascade = CascadeType.ALL)
|
||||||
// getters and setters
|
private List<AdditionalInfoBill> additionalInfo;
|
||||||
|
@OneToMany(mappedBy = "billMaster", cascade = CascadeType.ALL)
|
||||||
|
private List<CustomerParamBill> customerParams;
|
||||||
}
|
}
|
||||||
@@ -1,6 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import java.time.LocalDateTime;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import jakarta.persistence.CascadeType;
|
import jakarta.persistence.CascadeType;
|
||||||
@@ -16,8 +15,9 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "bill_payment")
|
@Table(name = "bbps_bill_payment")
|
||||||
public class BillPayment {
|
|
||||||
|
public class BillPayment extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "txn_id")
|
@Column(name = "txn_id")
|
||||||
@@ -53,9 +53,6 @@ public class BillPayment {
|
|||||||
@Column(name = "customer_mobile")
|
@Column(name = "customer_mobile")
|
||||||
private String customerMobNo;
|
private String customerMobNo;
|
||||||
|
|
||||||
@Column(name = "created_at")
|
|
||||||
private LocalDateTime createdAt = LocalDateTime.now();
|
|
||||||
|
|
||||||
// 🔗 One bill payment has many remitter identities
|
// 🔗 One bill payment has many remitter identities
|
||||||
@OneToMany(mappedBy = "billPayment", cascade = CascadeType.ALL, fetch = FetchType.LAZY, orphanRemoval = true)
|
@OneToMany(mappedBy = "billPayment", cascade = CascadeType.ALL, fetch = FetchType.LAZY, orphanRemoval = true)
|
||||||
private List<RemitterIdentity> remitterIdentities;
|
private List<RemitterIdentity> remitterIdentities;
|
||||||
|
|||||||
@@ -13,8 +13,9 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "bill_tag_list")
|
@Table(name = "bbps_bill_tag_list")
|
||||||
public class BillTag {
|
|
||||||
|
public class BillTag extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -1,6 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import jakarta.persistence.*;
|
import jakarta.persistence.*;
|
||||||
@@ -9,53 +8,60 @@ import lombok.Data;
|
|||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "bill_validation")
|
@Table(name = "bbps_bill_validation_master")
|
||||||
@Data
|
@Data
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
public class BillValidation {
|
public class BillValidation extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "bill_id", nullable = false, length = 100)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
private String billId;
|
private Long id;
|
||||||
|
|
||||||
@Column(name = "ref_id", length = 100)
|
@Column(name = "bill_id", unique = true)
|
||||||
private String refId;
|
private String billId;
|
||||||
|
|
||||||
@Column(name = "biller_id", length = 100)
|
private String mid;
|
||||||
private String billerId;
|
|
||||||
|
|
||||||
@Column(name = "status", length = 100)
|
private String initiatorTxnId;
|
||||||
private String status;
|
|
||||||
|
|
||||||
@Column(name = "action_type", length = 100)
|
private String checkerTxnId;
|
||||||
private String actionType;
|
|
||||||
|
|
||||||
@Column(name = "user_id", length = 100)
|
@Column(name = "ref_id", length = 100)
|
||||||
private String userId;
|
private String refId;
|
||||||
|
|
||||||
@Column(name = "biller_response", columnDefinition = "TEXT")
|
@Column(name = "biller_id", length = 100)
|
||||||
private String billerResponse;
|
private String billerId;
|
||||||
|
|
||||||
@OneToMany(mappedBy = "bill", cascade = CascadeType.ALL, fetch = FetchType.LAZY)
|
@Column(name = "status", length = 100)
|
||||||
private List<AdditionalInfoBillValidate> additionalInfo;
|
private String status;
|
||||||
|
|
||||||
// 👇 Proper nested customer params (OneToMany)
|
@Column(name = "action_type", length = 100)
|
||||||
@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "bill")
|
private String actionType;
|
||||||
private List<CustomerParamBillValidation> customerParams;
|
|
||||||
|
|
||||||
@Column(name = "plan_info_daos", columnDefinition = "TEXT")
|
@Column(name = "user_id", length = 100)
|
||||||
private String planInfoDaos;
|
private String userId;
|
||||||
|
|
||||||
@Column(name = "creation_date", length = 50)
|
@Column(name = "biller_response", columnDefinition = "TEXT")
|
||||||
private String creationDate;
|
private String billerResponse;
|
||||||
|
|
||||||
@Column(name = "modified_date", length = 50)
|
@OneToMany(mappedBy = "bill", cascade = CascadeType.ALL, fetch = FetchType.LAZY)
|
||||||
private String modifiedDate;
|
private List<AdditionalInfoBillValidate> additionalInfo;
|
||||||
|
|
||||||
@Column(name = "created_epoch_date", length = 50)
|
// 👇 Proper nested customer params (OneToMany)
|
||||||
private String createdEpochDate;
|
@OneToMany(cascade = CascadeType.ALL, fetch = FetchType.LAZY, mappedBy = "bill")
|
||||||
|
private List<CustomerParamBillValidation> customerParams;
|
||||||
|
|
||||||
|
@Column(name = "plan_info_daos", columnDefinition = "TEXT")
|
||||||
|
private String planInfoDaos;
|
||||||
|
|
||||||
|
@Column(name = "txn_id")
|
||||||
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "req_id")
|
||||||
|
private String reqId;
|
||||||
|
|
||||||
|
@Column(name = "client_user_id")
|
||||||
|
private String clientUserId;
|
||||||
|
|
||||||
@Column(name = "modified_epoch_date", length = 50)
|
|
||||||
private String modifiedEpochDate;
|
|
||||||
}
|
}
|
||||||
@@ -13,19 +13,17 @@ import lombok.Getter;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Table(name = "biller_additional_info_payment")
|
@Table(name = "bbps_biller_additional_info_payment")
|
||||||
@Entity
|
@Entity
|
||||||
public class BillerAdditionalInfoPayment {
|
public class BillerAdditionalInfoPayment extends Auditable {
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
private Long id; // primary key for the table
|
private Long id; // primary key for the table
|
||||||
|
|
||||||
@Column(name = "param_config_id", nullable = false)
|
@Column(name = "param_config_id", nullable = false)
|
||||||
@NotBlank(message = "Param Config ID cannot be blank")
|
|
||||||
private String paramConfigId;
|
private String paramConfigId;
|
||||||
|
|
||||||
@Column(name = "param_name", nullable = false)
|
@Column(name = "param_name", nullable = false)
|
||||||
@NotBlank(message = "Param name cannot be blank")
|
|
||||||
private String paramName;
|
private String paramName;
|
||||||
|
|
||||||
@Column(name = "data_type_dao")
|
@Column(name = "data_type_dao")
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import jakarta.persistence.FetchType;
|
import jakarta.persistence.FetchType;
|
||||||
@@ -18,12 +16,12 @@ import lombok.NoArgsConstructor;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "biller_category_icon")
|
@Table(name = "bbps_biller_category_icon")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
public class BillerCategoryIcon extends Auditable<String>{
|
public class BillerCategoryIcon extends Auditable{
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.CascadeType;
|
import jakarta.persistence.CascadeType;
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
@@ -15,12 +13,12 @@ import lombok.NoArgsConstructor;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "biller_category_wise")
|
@Table(name = "bbps_biller_category_wise")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
public class BillerCategoryWise extends Auditable<String> {
|
public class BillerCategoryWise extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "biller_id")
|
@Column(name = "biller_id")
|
||||||
@@ -59,6 +57,9 @@ public class BillerCategoryWise extends Auditable<String> {
|
|||||||
@Column(name = "txn_id")
|
@Column(name = "txn_id")
|
||||||
private String txnId;
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
// One-to-One mapping with icon
|
// One-to-One mapping with icon
|
||||||
@OneToOne(mappedBy = "biller", cascade = CascadeType.ALL, orphanRemoval = true, fetch = FetchType.LAZY)
|
@OneToOne(mappedBy = "biller", cascade = CascadeType.ALL, orphanRemoval = true, fetch = FetchType.LAZY)
|
||||||
private BillerCategoryIcon icon;
|
private BillerCategoryIcon icon;
|
||||||
|
|||||||
@@ -2,12 +2,12 @@ package com.billpaymentservice.bbps.entites;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
|
||||||
|
|
||||||
import jakarta.persistence.CascadeType;
|
import jakarta.persistence.CascadeType;
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
|
import jakarta.persistence.EntityListeners;
|
||||||
import jakarta.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
import jakarta.persistence.OneToMany;
|
import jakarta.persistence.OneToMany;
|
||||||
import jakarta.persistence.OneToOne;
|
import jakarta.persistence.OneToOne;
|
||||||
@@ -21,6 +21,7 @@ import lombok.ToString;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
|
@EntityListeners(AuditListener.class)
|
||||||
@ToString(exclude = {
|
@ToString(exclude = {
|
||||||
"billerPaymentModes",
|
"billerPaymentModes",
|
||||||
"billerPaymentChannels",
|
"billerPaymentChannels",
|
||||||
@@ -34,9 +35,9 @@ import lombok.ToString;
|
|||||||
"billerAdditionalInfoPayments"
|
"billerAdditionalInfoPayments"
|
||||||
})
|
})
|
||||||
|
|
||||||
@Table(name = "biller_details")
|
@Table(name = "bbps_biller_details")
|
||||||
@JsonIgnoreProperties(ignoreUnknown = true)
|
@JsonIgnoreProperties(ignoreUnknown = true)
|
||||||
public class BillerDetails{
|
public class BillerDetails extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "biller_id", length = 14, nullable = false, unique = true)
|
@Column(name = "biller_id", length = 14, nullable = false, unique = true)
|
||||||
@@ -45,18 +46,15 @@ public class BillerDetails{
|
|||||||
private String billerId;
|
private String billerId;
|
||||||
|
|
||||||
@Column(name = "biller_name")
|
@Column(name = "biller_name")
|
||||||
@NotBlank(message = "Biller name cannot be blank")
|
|
||||||
private String billerName;
|
private String billerName;
|
||||||
|
|
||||||
@Column(name = "biller_alias_name")
|
@Column(name = "biller_alias_name")
|
||||||
private String billerAliasName;
|
private String billerAliasName;
|
||||||
|
|
||||||
@Column(name = "biller_category_name", nullable = false)
|
@Column(name = "biller_category_name")
|
||||||
@NotBlank(message = "Biller category name cannot be blank")
|
|
||||||
private String billerCategoryName;
|
private String billerCategoryName;
|
||||||
|
|
||||||
@Column(name = "biller_mode")
|
@Column(name = "biller_mode")
|
||||||
@NotBlank(message = "Biller mode cannot be blank")
|
|
||||||
private String billerMode;
|
private String billerMode;
|
||||||
|
|
||||||
@Column(name = "biller_accepts_adhoc")
|
@Column(name = "biller_accepts_adhoc")
|
||||||
@@ -69,14 +67,12 @@ public class BillerDetails{
|
|||||||
private String parentBillerId;
|
private String parentBillerId;
|
||||||
|
|
||||||
@Column(name = "biller_ownership")
|
@Column(name = "biller_ownership")
|
||||||
@NotBlank(message = "Biller ownership is required (PSU or Private)")
|
|
||||||
private String billerOwnerShp;
|
private String billerOwnerShp;
|
||||||
|
|
||||||
@Column(name = "biller_coverage")
|
@Column(name = "biller_coverage")
|
||||||
private String billerCoverage;
|
private String billerCoverage;
|
||||||
|
|
||||||
@Column(name = "fetch_requirement")
|
@Column(name = "fetch_requirement")
|
||||||
@NotBlank(message = "Fetch requirement is mandatory")
|
|
||||||
private String fetchRequirement;
|
private String fetchRequirement;
|
||||||
|
|
||||||
@Column(name = "payment_amount_exactness")
|
@Column(name = "payment_amount_exactness")
|
||||||
|
|||||||
@@ -17,14 +17,14 @@ import lombok.ToString;
|
|||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@ToString
|
@ToString
|
||||||
@Table(name = "biller_plan_response_params")
|
@Table(name = "bbps_biller_plan_response_params")
|
||||||
public class BillerPlanResponseParams {
|
|
||||||
|
public class BillerPlanResponseParams extends Auditable {
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
private Long id; // Primary Key
|
private Long id; // Primary Key
|
||||||
|
|
||||||
@Column(name = "biller_plan_response_id", nullable = false, unique = true)
|
@Column(name = "biller_plan_response_id", nullable = false, unique = true)
|
||||||
@NotBlank(message = "Biller Plan Response ID cannot be blank")
|
|
||||||
private String billerPlanResponseId;
|
private String billerPlanResponseId;
|
||||||
// ✅ params list — since it's not a separate table, we can store as JSON or text
|
// ✅ params list — since it's not a separate table, we can store as JSON or text
|
||||||
@Column(name = "params", columnDefinition = "TEXT")
|
@Column(name = "params", columnDefinition = "TEXT")
|
||||||
@@ -38,4 +38,3 @@ public class BillerPlanResponseParams {
|
|||||||
@JoinColumn(name = "biller_id", nullable = false)
|
@JoinColumn(name = "biller_id", nullable = false)
|
||||||
private BillerDetails biller;
|
private BillerDetails biller;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -11,10 +11,10 @@ import lombok.Getter;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "biller_response")
|
@Table(name = "bbps_biller_response")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class BillerResponse {
|
public class BillerResponse extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue
|
@GeneratedValue
|
||||||
|
|||||||
@@ -20,8 +20,9 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "biller_response_params")
|
@Table(name = "bbps_biller_response_params")
|
||||||
public class BillerResponseParams {
|
|
||||||
|
public class BillerResponseParams extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "biller_response_id", nullable = false, unique = true)
|
@Column(name = "biller_response_id", nullable = false, unique = true)
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
@@ -12,10 +10,10 @@ import lombok.Getter;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "category_response_list")
|
@Table(name = "bbps_category_response_list")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class CategoryResponseList extends Auditable<String> {
|
public class CategoryResponseList extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -30,4 +28,7 @@ public class CategoryResponseList extends Auditable<String> {
|
|||||||
@Column(name = "txn_id")
|
@Column(name = "txn_id")
|
||||||
private String txnId;
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -16,10 +16,10 @@ import lombok.Getter;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "check_client_biller_data")
|
@Table(name = "bbps_check_client_biller_data")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class CheckClientBillerData {
|
public class CheckClientBillerData extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -10,10 +10,10 @@ import lombok.Getter;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "check_client_status_req_id")
|
@Table(name = "bbps_check_client_status_req_id")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class CheckClientStatusReqId {
|
public class CheckClientStatusReqId extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "bill_id", length = 200)
|
@Column(name = "bill_id", length = 200)
|
||||||
@@ -34,18 +34,6 @@ public class CheckClientStatusReqId {
|
|||||||
@Column(name = "user_id")
|
@Column(name = "user_id")
|
||||||
private String userId;
|
private String userId;
|
||||||
|
|
||||||
@Column(name = "creation_date")
|
|
||||||
private String creationDate;
|
|
||||||
|
|
||||||
@Column(name = "modified_date")
|
|
||||||
private String modifiedDate;
|
|
||||||
|
|
||||||
@Column(name = "created_epoch_date")
|
|
||||||
private Long createdEpochDate;
|
|
||||||
|
|
||||||
@Column(name = "modified_epoch_date")
|
|
||||||
private Long modifiedEpochDate;
|
|
||||||
|
|
||||||
@Column(name = "req_id")
|
@Column(name = "req_id")
|
||||||
private String reqId;
|
private String reqId;
|
||||||
|
|
||||||
|
|||||||
@@ -1,7 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
@@ -13,11 +11,11 @@ import lombok.Data;
|
|||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "complaints")
|
@Table(name = "bbps_complaints")
|
||||||
@Data
|
@Data
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
public class CloseComplaint extends Auditable<String> {
|
public class CloseComplaint extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -1,21 +1,22 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
|
import jakarta.persistence.FetchType;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
import jakarta.persistence.GenerationType;
|
import jakarta.persistence.GenerationType;
|
||||||
import jakarta.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
|
import jakarta.persistence.JoinColumn;
|
||||||
|
import jakarta.persistence.ManyToOne;
|
||||||
import jakarta.persistence.Table;
|
import jakarta.persistence.Table;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "complaint_status")
|
@Table(name = "bbps_complaint_status")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
public class ComplainStatus extends Auditable<String> {
|
public class ComplainStatus extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -68,4 +69,7 @@ public class ComplainStatus extends Auditable<String> {
|
|||||||
|
|
||||||
@Column(name = "txn_id")
|
@Column(name = "txn_id")
|
||||||
private String txnId;
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -5,11 +5,11 @@ import lombok.Setter;
|
|||||||
import lombok.ToString;
|
import lombok.ToString;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "complaint_details")
|
@Table(name = "bbps_complaint_details")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@ToString
|
@ToString
|
||||||
public class ComplaintDetails {
|
public class ComplaintDetails extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "complaint_id", nullable = false, unique = true)
|
@Column(name = "complaint_id", nullable = false, unique = true)
|
||||||
|
|||||||
@@ -1,12 +1,13 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
|
import jakarta.persistence.FetchType;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
import jakarta.persistence.GenerationType;
|
import jakarta.persistence.GenerationType;
|
||||||
import jakarta.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
|
import jakarta.persistence.JoinColumn;
|
||||||
|
import jakarta.persistence.ManyToOne;
|
||||||
import jakarta.persistence.Table;
|
import jakarta.persistence.Table;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
@@ -14,27 +15,27 @@ import lombok.NoArgsConstructor;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "complaints_history")
|
@Table(name = "bbps_complaints_history")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
public class ComplaintHistory extends Auditable<String> {
|
public class ComplaintHistory extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
private Long id;
|
private Long id;
|
||||||
|
|
||||||
@Column(name="history_id")
|
@Column(name = "history_id")
|
||||||
private String historyId;
|
private String historyId;
|
||||||
|
|
||||||
@Column(name="ticket_id")
|
@Column(name = "ticket_id")
|
||||||
private String ticketId;
|
private String ticketId;
|
||||||
|
|
||||||
@Column(name="time")
|
@Column(name = "time")
|
||||||
private String time;
|
private String time;
|
||||||
|
|
||||||
@Column(name="history_status")
|
@Column(name = "history_status")
|
||||||
private String historyStatus;
|
private String historyStatus;
|
||||||
|
|
||||||
@Column(name = "txn_id")
|
@Column(name = "txn_id")
|
||||||
@@ -43,5 +44,8 @@ public class ComplaintHistory extends Auditable<String> {
|
|||||||
@Column(name = "req_id")
|
@Column(name = "req_id")
|
||||||
private String reqId;
|
private String reqId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,21 +1,29 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
import java.util.HashSet;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Set;
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
|
import jakarta.persistence.FetchType;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
import jakarta.persistence.GenerationType;
|
import jakarta.persistence.GenerationType;
|
||||||
import jakarta.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
|
import jakarta.persistence.JoinColumn;
|
||||||
|
import jakarta.persistence.OneToMany;
|
||||||
import jakarta.persistence.Table;
|
import jakarta.persistence.Table;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
import lombok.ToString;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Table(name = "complaint_responses")
|
@ToString
|
||||||
public class ComplaintResponseEntity extends Auditable<String> {
|
@Table(name = "bbps_complaint_responses")
|
||||||
|
|
||||||
|
public class ComplaintResponseEntity extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.AUTO)
|
@GeneratedValue(strategy = GenerationType.AUTO)
|
||||||
@@ -24,6 +32,9 @@ public class ComplaintResponseEntity extends Auditable<String> {
|
|||||||
@Column(name = "ref_id")
|
@Column(name = "ref_id")
|
||||||
private String refId;
|
private String refId;
|
||||||
|
|
||||||
|
@Column(name = "request_txn_id")
|
||||||
|
private String requestTxnId;
|
||||||
|
|
||||||
@Column(name = "txn_npci_id")
|
@Column(name = "txn_npci_id")
|
||||||
private String txnNpciId;
|
private String txnNpciId;
|
||||||
|
|
||||||
@@ -66,4 +77,23 @@ public class ComplaintResponseEntity extends Auditable<String> {
|
|||||||
@Column(name = "user_id")
|
@Column(name = "user_id")
|
||||||
private String userId;
|
private String userId;
|
||||||
|
|
||||||
|
@Column(name = "mid")
|
||||||
|
private String mid;
|
||||||
|
|
||||||
|
@OneToMany(fetch = FetchType.LAZY)
|
||||||
|
@JoinColumn(name = "ticket_id", referencedColumnName = "ticket_id", insertable = false, updatable = false)
|
||||||
|
private Set<ComplainStatus> complaintStatusList = new HashSet<>();
|
||||||
|
|
||||||
|
@OneToMany(fetch = FetchType.LAZY)
|
||||||
|
@JoinColumn(name = "ticket_id", referencedColumnName = "ticket_id", insertable = false, updatable = false)
|
||||||
|
private Set<ComplaintHistory> historyList = new HashSet<>();
|
||||||
|
|
||||||
|
@OneToMany(fetch = FetchType.LAZY)
|
||||||
|
@JoinColumn(name = "ticket_id", referencedColumnName = "ticket_id", insertable = false, updatable = false)
|
||||||
|
private Set<ComplaintStatusDetails> statusDetailsList = new HashSet<>();
|
||||||
|
|
||||||
|
@OneToMany(fetch = FetchType.LAZY)
|
||||||
|
@JoinColumn(name = "ticket_id", referencedColumnName = "ticket_id", insertable = false, updatable = false)
|
||||||
|
private Set<ViewAllComplaintTicketStatusDetails> viewAllList = new HashSet<>();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,12 +1,13 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
|
import jakarta.persistence.FetchType;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
import jakarta.persistence.GenerationType;
|
import jakarta.persistence.GenerationType;
|
||||||
import jakarta.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
|
import jakarta.persistence.JoinColumn;
|
||||||
|
import jakarta.persistence.ManyToOne;
|
||||||
import jakarta.persistence.Table;
|
import jakarta.persistence.Table;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
@@ -14,8 +15,9 @@ import lombok.Setter;
|
|||||||
@Entity
|
@Entity
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Table(name = "view_ticket_status")
|
@Table(name = "bbps_view_ticket_status")
|
||||||
public class ComplaintStatusDetails extends Auditable<String>{
|
|
||||||
|
public class ComplaintStatusDetails extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -27,6 +29,9 @@ public class ComplaintStatusDetails extends Auditable<String>{
|
|||||||
@Column(name = "txn_id")
|
@Column(name = "txn_id")
|
||||||
private String systemTxnId;
|
private String systemTxnId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
@Column(name = "total_elements")
|
@Column(name = "total_elements")
|
||||||
private String totalElements;
|
private String totalElements;
|
||||||
|
|
||||||
@@ -84,4 +89,6 @@ public class ComplaintStatusDetails extends Auditable<String>{
|
|||||||
@Column(name = "biller_name")
|
@Column(name = "biller_name")
|
||||||
private String billerName;
|
private String billerName;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -11,11 +11,11 @@ import lombok.Setter;
|
|||||||
import lombok.ToString;
|
import lombok.ToString;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "complaint_options_status_master")
|
@Table(name = "bbps_complaint_options_status_master")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@ToString
|
@ToString
|
||||||
public class ComplaintStatusOptionsMaster {
|
public class ComplaintStatusOptionsMaster extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -24,7 +24,5 @@ public class ComplaintStatusOptionsMaster {
|
|||||||
@Column(name = "status_label_name")
|
@Column(name = "status_label_name")
|
||||||
private String statusLabelName;
|
private String statusLabelName;
|
||||||
|
|
||||||
@Column(name = "is_deleted")
|
// Removed local isDeleted field, now handled by Auditable
|
||||||
private Boolean isDeleted = false;
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -1,7 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
@@ -14,12 +12,12 @@ import lombok.NoArgsConstructor;
|
|||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "contact_master_data")
|
@Table(name = "bbps_contact_master_data")
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
public class ContactMasterData extends Auditable<String> {
|
public class ContactMasterData extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -33,4 +31,7 @@ public class ContactMasterData extends Auditable<String> {
|
|||||||
|
|
||||||
@Column(name = "txn_id")
|
@Column(name = "txn_id")
|
||||||
private String txnId;
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
}
|
}
|
||||||
@@ -14,33 +14,43 @@ import lombok.ToString;
|
|||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@ToString
|
@ToString
|
||||||
@Table(name = "custom_param")
|
@Table(name = "bbps_custom_param")
|
||||||
public class CustomParam {
|
|
||||||
|
|
||||||
@Id
|
public class CustomParam extends Auditable {
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
|
||||||
private Long id;
|
|
||||||
|
|
||||||
@Column(name = "custom_param_name")
|
|
||||||
private String customParamName;
|
|
||||||
|
|
||||||
@Column(name = "data_type")
|
@Id
|
||||||
private String dataType;
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
private Long id;
|
||||||
|
|
||||||
@Column(name = "optional")
|
@Column(name = "custom_param_name")
|
||||||
private Boolean optional;
|
private String customParamName;
|
||||||
|
|
||||||
@Column(name = "min_length")
|
@Column(name = "data_type")
|
||||||
private Integer minLength;
|
private String dataType;
|
||||||
|
|
||||||
@Column(name = "max_length")
|
@Column(name = "optional")
|
||||||
private Integer maxLength;
|
private Boolean optional;
|
||||||
|
|
||||||
@Column(name = "regex")
|
@Column(name = "min_length")
|
||||||
private String regex;
|
private Integer minLength;
|
||||||
|
|
||||||
@Column(name = "visibility")
|
@Column(name = "max_length")
|
||||||
private Boolean visibility;
|
private Integer maxLength;
|
||||||
|
|
||||||
|
@Column(name = "regex")
|
||||||
|
private String regex;
|
||||||
|
|
||||||
|
@Column(name = "visibility")
|
||||||
|
private Boolean visibility;
|
||||||
|
|
||||||
|
@Column(name = "req_id")
|
||||||
|
private String reqId;
|
||||||
|
|
||||||
|
@Column(name = "txn_id")
|
||||||
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -22,9 +22,9 @@ import lombok.ToString;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "customer_param")
|
@Table(name = "bbps_customer_param")
|
||||||
@ToString
|
@ToString
|
||||||
public class CustomerParam {
|
public class CustomerParam extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -12,8 +12,9 @@ import lombok.Setter;
|
|||||||
@Entity
|
@Entity
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Table(name = "customer_param_bill")
|
@Table(name = "bbps_customer_param_bill")
|
||||||
public class CustomerParamBill {
|
|
||||||
|
public class CustomerParamBill extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue
|
@GeneratedValue
|
||||||
|
|||||||
@@ -6,11 +6,11 @@ import lombok.Data;
|
|||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "customer_params_bill_validate")
|
@Table(name = "bbps_customer_params_bill_validate")
|
||||||
@Data
|
@Data
|
||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
public class CustomerParamBillValidation {
|
public class CustomerParamBillValidation extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -12,8 +12,9 @@ import lombok.Setter;
|
|||||||
@Entity
|
@Entity
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Table(name = "customer_params")
|
@Table(name = "bbps_customer_params")
|
||||||
public class CustomerParamDAO {
|
|
||||||
|
public class CustomerParamDAO extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -2,8 +2,6 @@ package com.billpaymentservice.bbps.entites;
|
|||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.CascadeType;
|
import jakarta.persistence.CascadeType;
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
@@ -20,8 +18,10 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "customer_param_group_by_biller_id")
|
@Table(name = "bbps_customer_param_group_by_biller_id")
|
||||||
public class CustomerParamGroupById extends Auditable<String> {
|
|
||||||
|
|
||||||
|
public class CustomerParamGroupById extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -56,4 +56,6 @@ public class CustomerParamGroupById extends Auditable<String> {
|
|||||||
@Column(name = "txn_id")
|
@Column(name = "txn_id")
|
||||||
private String txnId;
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
}
|
}
|
||||||
@@ -21,8 +21,9 @@ import lombok.ToString;
|
|||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@ToString
|
@ToString
|
||||||
@Table(name = "customer_param_groups")
|
@Table(name = "bbps_customer_param_groups")
|
||||||
public class CustomerParamGroups {
|
|
||||||
|
public class CustomerParamGroups extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -38,4 +39,3 @@ public class CustomerParamGroups {
|
|||||||
@OneToMany(mappedBy = "customerParamGroups", cascade = CascadeType.ALL, orphanRemoval = true)
|
@OneToMany(mappedBy = "customerParamGroups", cascade = CascadeType.ALL, orphanRemoval = true)
|
||||||
private List<Group> groups;
|
private List<Group> groups;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -14,8 +14,9 @@ import lombok.Setter;
|
|||||||
@Entity
|
@Entity
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Table(name = "customer_params_transaction")
|
@Table(name = "bbps_customer_params_transaction")
|
||||||
public class CustomerParamTransaction {
|
|
||||||
|
public class CustomerParamTransaction extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -30,4 +31,3 @@ public class CustomerParamTransaction {
|
|||||||
@JoinColumn(name = "txn_id", referencedColumnName = "bank_txn_id")
|
@JoinColumn(name = "txn_id", referencedColumnName = "bank_txn_id")
|
||||||
private TransactionMaster transactionMaster;
|
private TransactionMaster transactionMaster;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -15,8 +15,9 @@ import lombok.Setter;
|
|||||||
@Entity
|
@Entity
|
||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Table(name = "device_block_tag")
|
@Table(name = "bbps_device_block_tag")
|
||||||
public class DeviceBlockTag {
|
|
||||||
|
public class DeviceBlockTag extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -11,17 +11,26 @@ import lombok.ToString;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "disposition_details")
|
@Table(name = "bbps_disposition_details")
|
||||||
@ToString
|
@ToString
|
||||||
public class DispositionDetails {
|
public class DispositionDetails extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@Column(name = "disposition_id", nullable = false, unique = true)
|
@Column(name = "disposition_id", nullable = false, unique = true)
|
||||||
private String dispositionId; // UUID type string
|
private String dispositionId; // UUID type string
|
||||||
|
|
||||||
@Column(name = "disposition_descr", nullable = false)
|
@Column(name = "disposition_descr", nullable = false)
|
||||||
private String dispositionDescr;
|
private String dispositionDescr;
|
||||||
|
|
||||||
@Column(name = "tenant_id")
|
@Column(name = "tenant_id")
|
||||||
private String tenantId;
|
private String tenantId;
|
||||||
|
|
||||||
|
@Column(name = "req_id")
|
||||||
|
private String reqId;
|
||||||
|
|
||||||
|
@Column(name = "txn_id")
|
||||||
|
private String txnId;
|
||||||
|
|
||||||
|
@Column(name = "user_id")
|
||||||
|
private String userId;
|
||||||
}
|
}
|
||||||
@@ -1,7 +1,5 @@
|
|||||||
package com.billpaymentservice.bbps.entites;
|
package com.billpaymentservice.bbps.entites;
|
||||||
|
|
||||||
import com.billpaymentservice.bbps.audit.Auditable;
|
|
||||||
|
|
||||||
import jakarta.persistence.Column;
|
import jakarta.persistence.Column;
|
||||||
import jakarta.persistence.Entity;
|
import jakarta.persistence.Entity;
|
||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
@@ -18,8 +16,9 @@ import lombok.Setter;
|
|||||||
@AllArgsConstructor
|
@AllArgsConstructor
|
||||||
@NoArgsConstructor
|
@NoArgsConstructor
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "fetch_bill_validate_response")
|
@Table(name = "bbps_fetch_bill_validate_response")
|
||||||
public class FetchBillValidate extends Auditable<String> {
|
|
||||||
|
public class FetchBillValidate extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
@@ -63,10 +62,10 @@ public class FetchBillValidate extends Auditable<String> {
|
|||||||
private String modifiedDate;
|
private String modifiedDate;
|
||||||
|
|
||||||
@Column(name = "created_epoch_date")
|
@Column(name = "created_epoch_date")
|
||||||
private long createdEpochDate;
|
private Long createdEpochDate;
|
||||||
|
|
||||||
@Column(name = "modified_epoch_date")
|
@Column(name = "modified_epoch_date")
|
||||||
private long modifiedEpochDate;
|
private Long modifiedEpochDate;
|
||||||
|
|
||||||
@Column(name = "request_id")
|
@Column(name = "request_id")
|
||||||
private String requestId;
|
private String requestId;
|
||||||
|
|||||||
@@ -25,8 +25,9 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "biller_groups")
|
@Table(name = "bbps_biller_groups")
|
||||||
public class Group {
|
|
||||||
|
public class Group extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -14,8 +14,9 @@ import lombok.Setter;
|
|||||||
@Getter
|
@Getter
|
||||||
@Setter
|
@Setter
|
||||||
@Entity
|
@Entity
|
||||||
@Table(name = "group_params")
|
@Table(name = "bbps_group_params")
|
||||||
public class GroupParam {
|
|
||||||
|
public class GroupParam extends Auditable {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
|
|||||||
@@ -7,57 +7,62 @@ import jakarta.persistence.Entity;
|
|||||||
import jakarta.persistence.GeneratedValue;
|
import jakarta.persistence.GeneratedValue;
|
||||||
import jakarta.persistence.GenerationType;
|
import jakarta.persistence.GenerationType;
|
||||||
import jakarta.persistence.Id;
|
import jakarta.persistence.Id;
|
||||||
|
import jakarta.persistence.Table;
|
||||||
import lombok.Getter;
|
import lombok.Getter;
|
||||||
import lombok.NoArgsConstructor;
|
import lombok.NoArgsConstructor;
|
||||||
import lombok.Setter;
|
import lombok.Setter;
|
||||||
import lombok.ToString;
|
import lombok.ToString;
|
||||||
|
|
||||||
@Entity
|
@Entity
|
||||||
@Getter @Setter @NoArgsConstructor @ToString
|
@Getter
|
||||||
|
@Setter
|
||||||
|
@NoArgsConstructor
|
||||||
|
@ToString
|
||||||
|
@Table(name = "bbps_inbound_trace_log")
|
||||||
public class InboundTraceLog {
|
public class InboundTraceLog {
|
||||||
|
|
||||||
@Id
|
@Id
|
||||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||||
private Long id;
|
private Long id;
|
||||||
|
|
||||||
// 🔹 Identifiers
|
// 🔹 Identifiers
|
||||||
@Column(length = 50, unique = true)
|
@Column(length = 50, unique = true)
|
||||||
private String requestId; // external requestId (from client)
|
private String requestId; // external requestId (from client)
|
||||||
@Column(length = 35)
|
@Column(length = 35)
|
||||||
private String txnId; // internally generated transaction id
|
private String txnId; // internally generated transaction id
|
||||||
|
|
||||||
// 🔹 Source & API info
|
// 🔹 Source & API info
|
||||||
private String orgId; // tumhara org code (like ORG001)
|
private String orgId; // tumhara org code (like ORG001)
|
||||||
private String mid; // merchant id from request
|
private String mid; // merchant id from request
|
||||||
private String apiName; // e.g. getBillerByBillerId
|
private String apiName; // e.g. getBillerByBillerId
|
||||||
private String httpMethod; // GET / POST
|
private String httpMethod; // GET / POST
|
||||||
|
|
||||||
// 🔹 Request/Response data
|
// 🔹 Request/Response data
|
||||||
@Column(columnDefinition = "TEXT")
|
@Column(columnDefinition = "TEXT")
|
||||||
private String requestPayload; // jo external ne bheja
|
private String requestPayload; // jo external ne bheja
|
||||||
@Column(columnDefinition = "TEXT")
|
@Column(columnDefinition = "TEXT")
|
||||||
private String responsePayload; // jo tumne wapas bheja
|
private String responsePayload; // jo tumne wapas bheja
|
||||||
|
|
||||||
// 🔹 Status & timing
|
// 🔹 Status & timing
|
||||||
private String status; // SUCCESS / FAILED
|
private String status; // SUCCESS / FAILED
|
||||||
private String responseCode; // like 200, 400 etc.
|
private String responseCode; // like 200, 400 etc.
|
||||||
private LocalDateTime requestTime; // jab request aayi
|
private LocalDateTime requestTime; // jab request aayi
|
||||||
private LocalDateTime responseTime; // jab response gaya
|
private LocalDateTime responseTime; // jab response gaya
|
||||||
private LocalDateTime createdAt = LocalDateTime.now();
|
private LocalDateTime createdAt = LocalDateTime.now();
|
||||||
|
|
||||||
@Column(length = 255)
|
@Column(length = 255)
|
||||||
private String remark; // error ya note
|
private String remark; // error ya note
|
||||||
|
|
||||||
public InboundTraceLog(String requestId, String txnId, String apiName, String mid,
|
public InboundTraceLog(String requestId, String txnId, String apiName, String mid, String orgId, String httpMethod,
|
||||||
String orgId, String httpMethod, String requestPayload) {
|
String requestPayload) {
|
||||||
this.requestId = requestId;
|
this.requestId = requestId;
|
||||||
this.txnId = txnId;
|
this.txnId = txnId;
|
||||||
this.apiName = apiName;
|
this.apiName = apiName;
|
||||||
this.mid = mid;
|
this.mid = mid;
|
||||||
this.orgId = orgId;
|
this.orgId = orgId;
|
||||||
this.httpMethod = httpMethod;
|
this.httpMethod = httpMethod;
|
||||||
this.requestPayload = requestPayload;
|
this.requestPayload = requestPayload;
|
||||||
this.requestTime = LocalDateTime.now();
|
this.requestTime = LocalDateTime.now();
|
||||||
this.createdAt = LocalDateTime.now();
|
this.createdAt = LocalDateTime.now();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user