Commit 329c59d2 authored by Deep Dey's avatar Deep Dey

chore: add default value for session year

parent 6f3af536
......@@ -38,7 +38,9 @@ public class AdmissionFormDAOController {
private final PdfService pdfService;
public boolean addNewAdmissionData(@NotNull AdmissionFormData formData) throws Exception {
if (formData.getSessionYear() == null || formData.getSessionYear().isEmpty()) {
formData.setSessionYear("2026-2027");
}
if (!formData.isDuplicateFatherEmail()) {
List<AdmissionFormData> data = admissionFormDataRepository
.getAdmissionFormDataByEmail(formData.getFatherEmail());
......
......@@ -111,6 +111,5 @@ public class AdmissionFormData {
private boolean existing;
private boolean provisional;
@NotEmpty(message = "Session Year cannot be empty")
private String sessionYear;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment