-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Grad release 1.11.0
- Loading branch information
Showing
35 changed files
with
407 additions
and
144 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
15 changes: 15 additions & 0 deletions
15
api/src/main/java/ca/bc/gov/educ/api/dataconversion/constant/FieldName.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
package ca.bc.gov.educ.api.dataconversion.constant; | ||
|
||
public enum FieldName { | ||
SCHOOL_OF_RECORD, | ||
GRAD_PROGRAM, | ||
ADULT_START_DATE, | ||
SLP_DATE, | ||
STUDENT_GRADE, | ||
CITIZENSHIP, | ||
STUDENT_STATUS, | ||
|
||
RECALC_GRAD_ALG, | ||
RECALC_TVR | ||
|
||
} |
6 changes: 6 additions & 0 deletions
6
api/src/main/java/ca/bc/gov/educ/api/dataconversion/constant/FieldType.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package ca.bc.gov.educ.api.dataconversion.constant; | ||
|
||
public enum FieldType { | ||
STRING, | ||
DATE | ||
} |
39 changes: 39 additions & 0 deletions
39
api/src/main/java/ca/bc/gov/educ/api/dataconversion/exception/ServiceException.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
package ca.bc.gov.educ.api.dataconversion.exception; | ||
|
||
import lombok.Data; | ||
|
||
@Data | ||
public class ServiceException extends RuntimeException { | ||
|
||
private int statusCode; | ||
|
||
public ServiceException() { | ||
super(); | ||
} | ||
|
||
public ServiceException(String message) { | ||
super(message); | ||
} | ||
|
||
public ServiceException(String message, Throwable cause) { | ||
super(message, cause); | ||
} | ||
|
||
public ServiceException(Throwable cause) { | ||
super(cause); | ||
} | ||
|
||
protected ServiceException(String message, Throwable cause, boolean enableSuppression, boolean writableStackTrace) { | ||
super(message, cause, enableSuppression, writableStackTrace); | ||
} | ||
|
||
public ServiceException(String message, int value) { | ||
super(message); | ||
this.statusCode = value; | ||
} | ||
|
||
public ServiceException(String s, int value, Exception e) { | ||
super(s, e); | ||
this.statusCode = value; | ||
} | ||
} |
39 changes: 39 additions & 0 deletions
39
api/src/main/java/ca/bc/gov/educ/api/dataconversion/model/OngoingUpdateFieldDTO.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
package ca.bc.gov.educ.api.dataconversion.model; | ||
|
||
import ca.bc.gov.educ.api.dataconversion.constant.FieldName; | ||
import ca.bc.gov.educ.api.dataconversion.constant.FieldType; | ||
import lombok.Builder; | ||
import lombok.Data; | ||
|
||
import java.util.Objects; | ||
|
||
@Builder | ||
@Data | ||
public class OngoingUpdateFieldDTO { | ||
private FieldType type; | ||
private FieldName name; | ||
private Object value; | ||
|
||
@Override | ||
public boolean equals(Object o) { | ||
if (this == o) return true; | ||
if (o == null || getClass() != o.getClass()) return false; | ||
OngoingUpdateFieldDTO that = (OngoingUpdateFieldDTO) o; | ||
return getName() == that.getName(); | ||
} | ||
|
||
@Override | ||
public int hashCode() { | ||
return Objects.hash(getName()); | ||
} | ||
|
||
@Override | ||
public String toString() { | ||
return "OngoingUpdateField{" + | ||
"type=" + type + | ||
", name=" + name + | ||
", value=" + value + | ||
'}'; | ||
} | ||
|
||
} |
18 changes: 18 additions & 0 deletions
18
api/src/main/java/ca/bc/gov/educ/api/dataconversion/model/OngoingUpdateRequestDTO.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
package ca.bc.gov.educ.api.dataconversion.model; | ||
|
||
import ca.bc.gov.educ.api.dataconversion.constant.EventType; | ||
import lombok.Builder; | ||
import lombok.Data; | ||
import lombok.NoArgsConstructor; | ||
|
||
import java.util.ArrayList; | ||
import java.util.List; | ||
|
||
@NoArgsConstructor | ||
@Data | ||
public class OngoingUpdateRequestDTO { | ||
private String studentID; | ||
private String pen; | ||
private EventType eventType; | ||
private List<OngoingUpdateFieldDTO> updateFields = new ArrayList<>(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.