add validation in request
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
package com.billpaymentservice.bbps.dto.request;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Getter;
|
||||
import lombok.Setter;
|
||||
|
||||
@@ -7,9 +9,16 @@ import lombok.Setter;
|
||||
@Setter
|
||||
public class ComplaintRequestDTO extends BaseClass {
|
||||
|
||||
private String ticketDescription; // Complaint description that the user enters
|
||||
private String ticketDisposition; // Complaint disposition
|
||||
private String ticketDispositionCode; // Type of complaint
|
||||
private String txnId; // Transaction ID (optional)
|
||||
@NotBlank(message = "Ticket description cannot be null.")
|
||||
private String ticketDescription;
|
||||
|
||||
@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;
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user