Skip to content

Commit

Permalink
Merge pull request #551 from bcgov/feature/GRAD2-2761
Browse files Browse the repository at this point in the history
 GRAD2-2761: replaced minCode with schoolId for School v2 endpoint & schoolAtGradId is added in.
  • Loading branch information
infstar authored Nov 21, 2024
2 parents e17cef7 + 4717496 commit 5130620
Show file tree
Hide file tree
Showing 21 changed files with 332 additions and 425 deletions.

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ public class GradAlgorithmGraduationStudentRecord {
private String studentCitizenship;
private UUID studentID;
private String schoolAtGrad;
private UUID schoolAtGradId;
private String consumerEducationRequirementMet;
private String schoolAtGradName;
@JsonFormat(pattern=DEFAULT_DATE_FORMAT)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ public class GradSearchStudent {
private String trueStudentID;
private String program;
private String schoolOfRecord;
private String schoolOfRecordId;
private String schoolOfRecordName;
private String schoolOfRecordindependentAffiliation;
private String studentGrade;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ public class GraduationStudentRecord extends BaseModel {
private String studentStatusName;
private UUID studentID;
private String schoolAtGrad;
private UUID schoolAtGradId;
private String schoolAtGradName;
private String legalFirstName;
private String legalMiddleNames;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ public class ReportGradStudentData implements Serializable {
private UUID graduationStudentRecordId;
private String mincode;
private String mincodeAtGrad;
private String schoolOfRecordId;
private String schoolAtGradId;
private String pen;
private String firstName;
private String middleName;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ public class School {
private String postal;
private String openFlag;
private String schoolCategoryCode;
private String schoolCategoryCodeInstitute;
private String schoolCategoryLegacyCode;

public String getSchoolName() {
return schoolName != null ? schoolName.trim(): null;
Expand Down Expand Up @@ -53,7 +53,7 @@ public String getOpenFlag() {

@Override
public String toString() {
return "School [minCode=" + minCode + ", schoolId=" + schoolId + ", schoolCategoryCode=" + schoolCategoryCode + ", schoolCategoryCodeInstitute=" + schoolCategoryCodeInstitute
return "School [minCode=" + minCode + ", schoolId=" + schoolId + ", schoolCategoryCode=" + schoolCategoryCode + ", schoolCategoryLegacyCode=" + schoolCategoryLegacyCode
+ ", schoolName=" + schoolName + ", districtName=" + districtName + ", transcriptEligibility=" + transcriptEligibility + ", certificateEligibility=" + certificateEligibility
+ ", address1=" + address1 + ", address2=" + address2 + ", city=" + city + ", provCode=" + provCode + ", countryCode=" + countryCode + ", postal=" + postal + ", openFlag=" + openFlag
+ "]";
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
package ca.bc.gov.educ.api.graduation.model.dto.institute;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.stereotype.Component;

@Data
@EqualsAndHashCode
@Component("instituteSchool")
@JsonIgnoreProperties(ignoreUnknown = true)
public class School {

private String schoolId;
private String districtId;
private String mincode;
private String independentAuthorityId;
private String schoolNumber;
private String faxNumber;
private String phoneNumber;
private String email;
private String website;
private String displayName;
private String displayNameNoSpecialChars;
private String schoolReportingRequirementCode;
private String schoolOrganizationCode;
private String schoolCategoryCode;
private String facilityTypeCode;
private String openedDate;
private String closedDate;
private boolean canIssueTranscripts;
private boolean canIssueCertificates;

}
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ public class School implements Serializable {

private static final long serialVersionUID = 2L;

private String schoolId;
private String mincode;
private String name;
private String typeIndicator;
Expand All @@ -27,6 +28,14 @@ public class School implements Serializable {

private List<Student> students;

public String getSchoolId() {
return schoolId;
}

public void setSchoolId(String value) {
this.schoolId = value;
}

public String getMincode() {
return mincode;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,15 +61,15 @@ public ExceptionMessage createStudentCertificateTranscriptReports(GraduationData
}
if(createCertificate) {
reportService.saveStudentCertificateReportJasper(graduationStatusResponse, graduationDataStatus, certType, false);
graduationDataStatus.getSchool().setSchoolCategoryCode(certType.getSchoolCategoryCode());
graduationDataStatus.getSchool().setSchoolCategoryLegacyCode(certType.getSchoolCategoryCode());
graduationDataStatus.getStudentCertificatesTranscript().addCertificateType(GradCertificateType.builder()
.code(certType.getCertificateTypeCode())
.description(certType.getCertificateTypeLabel())
.build());
}
} else {
reportService.saveStudentCertificateReportJasper(graduationStatusResponse, graduationDataStatus, certType, false);
graduationDataStatus.getSchool().setSchoolCategoryCode(certType.getSchoolCategoryCode());
graduationDataStatus.getSchool().setSchoolCategoryLegacyCode(certType.getSchoolCategoryCode());
graduationDataStatus.getStudentCertificatesTranscript().addCertificateType(GradCertificateType.builder()
.code(certType.getCertificateTypeCode())
.description(certType.getCertificateTypeLabel())
Expand Down
Loading

0 comments on commit 5130620

Please sign in to comment.