From 91c30a944463d7178d9039cadd022845c8be17e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=EB=AA=85=EC=A7=84?= <4mj.eo@dsm.hs.kr> Date: Fri, 25 Oct 2024 13:28:26 +0900 Subject: [PATCH 1/4] =?UTF-8?q?=F0=9F=A6=B7=20::=20(#790)=20is=5Fheadquart?= =?UTF-8?q?er=20->=20headquarter?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../dto/response/CompanyMyPageResponse.java | 4 ++-- .../response/QueryCompanyDetailsResponse.java | 4 ++-- .../jobis/domain/company/model/Company.java | 6 +++--- .../domain/company/spi/vo/CompanyDetailsVO.java | 2 +- .../TeacherQueryRecruitmentsUseCase.java | 17 +++++++++++++++-- .../persistence/CompanyPersistenceAdapter.java | 2 +- .../persistence/entity/CompanyEntity.java | 6 +++--- .../persistence/mapper/CompanyMapper.java | 4 ++-- .../repository/vo/QueryCompanyDetailsVO.java | 4 ++-- .../presentation/RecruitmentWebAdapter.java | 14 ++++++++++++-- 10 files changed, 43 insertions(+), 20 deletions(-) diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/company/dto/response/CompanyMyPageResponse.java b/jobis-application/src/main/java/team/retum/jobis/domain/company/dto/response/CompanyMyPageResponse.java index cabdd41c2..f0d6ae438 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/company/dto/response/CompanyMyPageResponse.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/company/dto/response/CompanyMyPageResponse.java @@ -33,7 +33,7 @@ public class CompanyMyPageResponse { private final String businessArea; private final String bizRegistrationUrl; private final List attachmentUrls; - private final boolean isHeadquarter; + private final boolean headquarter; public static CompanyMyPageResponse from(Company company) { return CompanyMyPageResponse.builder() @@ -58,7 +58,7 @@ public static CompanyMyPageResponse from(Company company) { .businessArea(company.getBusinessArea()) .bizRegistrationUrl(company.getBizRegistrationUrl()) .attachmentUrls(company.getAttachmentUrls()) - .isHeadquarter(company.isHeadquarter()) + .headquarter(company.isHeadquarter()) .build(); } } diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/company/dto/response/QueryCompanyDetailsResponse.java b/jobis-application/src/main/java/team/retum/jobis/domain/company/dto/response/QueryCompanyDetailsResponse.java index 87f18b35e..98872bcde 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/company/dto/response/QueryCompanyDetailsResponse.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/company/dto/response/QueryCompanyDetailsResponse.java @@ -36,7 +36,7 @@ public class QueryCompanyDetailsResponse { private final Long businessAreaCode; private final String businessArea; private final String bizRegistrationUrl; - private final boolean isHeadquarter; + private final boolean headquarter; public static QueryCompanyDetailsResponse from(CompanyDetailsVO vo) { return QueryCompanyDetailsResponse.builder() @@ -60,7 +60,7 @@ public static QueryCompanyDetailsResponse from(CompanyDetailsVO vo) { .serviceName(vo.getServiceName()) .businessArea(vo.getBusinessArea()) .bizRegistrationUrl(vo.getBizRegistrationUrl()) - .isHeadquarter(vo.isHeadquarter()) + .headquarter(vo.isHeadquarter()) .build(); } } diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/company/model/Company.java b/jobis-application/src/main/java/team/retum/jobis/domain/company/model/Company.java index c9df06efd..a4dcb4db4 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/company/model/Company.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/company/model/Company.java @@ -53,7 +53,7 @@ public class Company { private final List attachmentUrls; - private final boolean isHeadquarter; + private final boolean headquarter; public static Company of(Long id, RegisterCompanyRequest request, String businessArea) { return Company.builder() @@ -88,7 +88,7 @@ public static Company of(Long id, RegisterCompanyRequest request, String busines .representativePhoneNo(request.representativePhoneNo()) .foundedAt(request.foundedAt()) .attachmentUrls(request.attachmentUrls()) - .isHeadquarter(request.headquarter()) + .headquarter(request.headquarter()) .build(); } @@ -115,7 +115,7 @@ public Company update(UpdateCompanyDetailsRequest request) { .email(request.email()) .serviceName(request.serviceName()) .attachmentUrls(request.attachmentUrls()) - .isHeadquarter(request.headquarter()) + .headquarter(request.headquarter()) .build(); } diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/company/spi/vo/CompanyDetailsVO.java b/jobis-application/src/main/java/team/retum/jobis/domain/company/spi/vo/CompanyDetailsVO.java index 95dfc2eac..81efbb9d2 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/company/spi/vo/CompanyDetailsVO.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/company/spi/vo/CompanyDetailsVO.java @@ -31,5 +31,5 @@ public class CompanyDetailsVO { private final String businessArea; private final List attachmentUrls; private final String bizRegistrationUrl; - private final boolean isHeadquarter; + private final boolean headquarter; } diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/usecase/TeacherQueryRecruitmentsUseCase.java b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/usecase/TeacherQueryRecruitmentsUseCase.java index 5a698ec1d..26d77a44e 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/usecase/TeacherQueryRecruitmentsUseCase.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/usecase/TeacherQueryRecruitmentsUseCase.java @@ -59,8 +59,21 @@ public TeacherQueryRecruitmentsResponse executeWithoutPage(int year, List return new TeacherQueryRecruitmentsResponse(recruitments); } - public RecruitmentCountResponse countRecruitments() { - Long count = queryRecruitmentPort.countRecruitments(); + public RecruitmentCountResponse countRecruitments(String companyName, LocalDate start, LocalDate end, + Integer year, RecruitStatus status, Boolean winterIntern, + Boolean militarySupport, List codeIds) { + RecruitmentFilter filter = RecruitmentFilter.builder() + .companyName(companyName) + .status(status) + .startDate(start) + .endDate(end) + .codes(codeIds) + .year(year) + .winterIntern(winterIntern) + .militarySupport(militarySupport) + .build(); + + Long count = queryRecruitmentPort.getCountBy(filter); return new RecruitmentCountResponse(count); } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/CompanyPersistenceAdapter.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/CompanyPersistenceAdapter.java index 4fc1972e8..926f05094 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/CompanyPersistenceAdapter.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/CompanyPersistenceAdapter.java @@ -196,7 +196,7 @@ public Optional getCompanyDetails(Long companyId) { companyEntity.businessArea, companyEntity.attachmentUrls, companyEntity.bizRegistrationUrl, - companyEntity.isHeadquarter + companyEntity.headquarter ) ) .from(companyEntity) diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/entity/CompanyEntity.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/entity/CompanyEntity.java index 5b7394ac2..8379caad1 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/entity/CompanyEntity.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/entity/CompanyEntity.java @@ -112,14 +112,14 @@ public class CompanyEntity { @NotNull @Column(columnDefinition = "TINYINT(1)") - private boolean isHeadquarter; + private boolean headquarter; @Builder public CompanyEntity(Long id, String name, String mainAddress, String mainAddressDetail, String mainZipCode, List attachmentUrls, String representative, LocalDate foundedAt, double take, int workersCount, String managerName, String managerPhoneNo, String companyIntroduce, String companyLogoUrl, String email, String bizNo, String bizRegistrationUrl, String businessArea, String serviceName, CompanyType type, - boolean isMou, String representativePhoneNo, boolean isHeadquarter) { + boolean isMou, String representativePhoneNo, boolean headquarter) { this.id = id; this.name = name; this.isMou = isMou; @@ -139,6 +139,6 @@ public CompanyEntity(Long id, String name, String mainAddress, String mainAddres this.companyIntroduce = companyIntroduce; this.companyLogoUrl = companyLogoUrl; this.attachmentUrls = attachmentUrls; - this.isHeadquarter = isHeadquarter; + this.headquarter = headquarter; } } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/mapper/CompanyMapper.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/mapper/CompanyMapper.java index 7b4a546f9..4d35c7f3e 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/mapper/CompanyMapper.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/mapper/CompanyMapper.java @@ -35,7 +35,7 @@ public CompanyEntity toEntity(Company domain) { .isMou(domain.isMou()) .workersCount(domain.getWorkersCount()) .attachmentUrls(domain.getAttachmentUrls()) - .isHeadquarter(domain.isHeadquarter()) + .headquarter(domain.isHeadquarter()) .build(); } @@ -71,7 +71,7 @@ public Company toDomain(CompanyEntity entity) { .take(entity.getTake()) .workersCount(entity.getWorkersCount()) .attachmentUrls(entity.getAttachmentUrls()) - .isHeadquarter(entity.isHeadquarter()) + .headquarter(entity.isHeadquarter()) .build(); } } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/repository/vo/QueryCompanyDetailsVO.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/repository/vo/QueryCompanyDetailsVO.java index 150582c80..4c5e45b78 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/repository/vo/QueryCompanyDetailsVO.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/company/persistence/repository/vo/QueryCompanyDetailsVO.java @@ -16,10 +16,10 @@ public QueryCompanyDetailsVO(String businessNumber, String companyName, String c String managerName, String managerPhoneNo, String email, String representativeName, String representativePhoneNo, LocalDate foundedAt, int workerNumber, double take, Long recruitmentId, String serviceName, Long businessAreaCode, - String businessArea, List attachmentUrls, String bizRegistrationUrl, boolean isHeadquarter) { + String businessArea, List attachmentUrls, String bizRegistrationUrl, boolean headquarter) { super(businessNumber, companyName, companyProfileUrl, companyIntroduce, mainZipCode, mainAddress, mainAddressDetail, managerName, managerPhoneNo, email, representativeName, representativePhoneNo, foundedAt, workerNumber, take, recruitmentId, - serviceName, businessAreaCode, businessArea, attachmentUrls, bizRegistrationUrl, isHeadquarter); + serviceName, businessAreaCode, businessArea, attachmentUrls, bizRegistrationUrl, headquarter); } } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/RecruitmentWebAdapter.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/RecruitmentWebAdapter.java index 483aa70a4..d53e73cfb 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/RecruitmentWebAdapter.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/RecruitmentWebAdapter.java @@ -181,8 +181,18 @@ public TeacherQueryRecruitmentsResponse getRecruitmentListWithoutPage( } @GetMapping("/count") - public RecruitmentCountResponse countRecruitments() { - return teacherQueryRecruitmentsUseCase.countRecruitments(); + public RecruitmentCountResponse countRecruitments( + @RequestParam(required = false) String companyName, + @RequestParam(required = false) LocalDate start, + @RequestParam(required = false) LocalDate end, + @RequestParam(required = false) Integer year, + @RequestParam(required = false) RecruitStatus status, + @RequestParam(required = false) Boolean winterIntern, + @RequestParam(required = false) Boolean militarySupport, + @RequestParam(required = false) List codeIds) { + return teacherQueryRecruitmentsUseCase.countRecruitments( + companyName, start, end, year, status, winterIntern, militarySupport, codeIds + ); } @Cacheable From 01e1cea917d36bbc2774f6d7b964ed12dda5807b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=EB=AA=85=EC=A7=84?= <4mj.eo@dsm.hs.kr> Date: Fri, 25 Oct 2024 13:31:24 +0900 Subject: [PATCH 2/4] =?UTF-8?q?=F0=9F=A6=B7=20::=20(#790)=20=EC=8A=A4?= =?UTF-8?q?=ED=81=AC=EB=A6=BD=ED=8A=B8=20=EC=9E=91=EC=84=B1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../resources/db/migration/V17__rename_column_in_company.sql | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 jobis-infrastructure/src/main/resources/db/migration/V17__rename_column_in_company.sql diff --git a/jobis-infrastructure/src/main/resources/db/migration/V17__rename_column_in_company.sql b/jobis-infrastructure/src/main/resources/db/migration/V17__rename_column_in_company.sql new file mode 100644 index 000000000..2b9e2515b --- /dev/null +++ b/jobis-infrastructure/src/main/resources/db/migration/V17__rename_column_in_company.sql @@ -0,0 +1,3 @@ +alter table tbl_company rename column is_headquarter to headquarter; + +alter table tbl_recruitment rename column is_hire_convertible to hire_convertible; From 64ceb11d63fdb7a8dcfbbc30ce7c186e2bf6ab76 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=EB=AA=85=EC=A7=84?= <4mj.eo@dsm.hs.kr> Date: Fri, 25 Oct 2024 13:36:24 +0900 Subject: [PATCH 3/4] =?UTF-8?q?=F0=9F=A6=B7=20::=20(#790)=20is=5Fhire=5Fco?= =?UTF-8?q?nvertible=20->=20hire=5Fconvertible?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../recruitment/dto/request/ApplyRecruitmentRequest.java | 2 +- .../dto/response/QueryRecruitmentDetailResponse.java | 4 ++-- .../dto/response/TeacherQueryRecruitmentsResponse.java | 4 ++-- .../retum/jobis/domain/recruitment/model/Recruitment.java | 6 +++--- .../domain/recruitment/spi/vo/RecruitmentDetailVO.java | 2 +- .../domain/recruitment/spi/vo/TeacherRecruitmentVO.java | 2 +- .../persistence/RecruitmentPersistenceAdapter.java | 6 +++--- .../recruitment/persistence/entity/RecruitmentEntity.java | 6 +++--- .../recruitment/persistence/mapper/RecruitmentMapper.java | 4 ++-- .../persistence/repository/vo/QueryRecruitmentDetailVO.java | 4 ++-- .../repository/vo/QueryTeacherRecruitmentsVO.java | 4 ++-- .../dto/request/ApplyRecruitmentWebRequest.java | 4 ++-- 12 files changed, 24 insertions(+), 24 deletions(-) diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/request/ApplyRecruitmentRequest.java b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/request/ApplyRecruitmentRequest.java index 721d5de04..ceaffd420 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/request/ApplyRecruitmentRequest.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/request/ApplyRecruitmentRequest.java @@ -23,7 +23,7 @@ public record ApplyRecruitmentRequest( LocalDate startDate, LocalDate endDate, boolean winterIntern, - Boolean isHireConvertible, + Boolean hireConvertible, String etc ) { diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/response/QueryRecruitmentDetailResponse.java b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/response/QueryRecruitmentDetailResponse.java index d2a6b5b9d..6f11550ea 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/response/QueryRecruitmentDetailResponse.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/response/QueryRecruitmentDetailResponse.java @@ -36,7 +36,7 @@ public class QueryRecruitmentDetailResponse { private final String etc; private final Boolean isApplicable; private final boolean isBookmarked; - private final Boolean isHireConvertible; + private final Boolean hireConvertible; public static QueryRecruitmentDetailResponse of( RecruitmentDetailVO recruitmentDetail, List recruitAreas, @@ -63,7 +63,7 @@ public static QueryRecruitmentDetailResponse of( .etc(recruitmentDetail.getEtc()) .isApplicable(isApplicable) .isBookmarked(recruitmentDetail.isBookmarked()) - .isHireConvertible(recruitmentDetail.getIsHireConvertible()) + .hireConvertible(recruitmentDetail.getHireConvertible()) .build(); } } diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/response/TeacherQueryRecruitmentsResponse.java b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/response/TeacherQueryRecruitmentsResponse.java index 6b1434e97..a0c755703 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/response/TeacherQueryRecruitmentsResponse.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/dto/response/TeacherQueryRecruitmentsResponse.java @@ -46,7 +46,7 @@ public static class TeacherRecruitmentResponse { private long companyId; - private Boolean isHireConvertible; + private Boolean hireConvertible; public static TeacherRecruitmentResponse from(TeacherRecruitmentVO recruitment) { return TeacherRecruitmentResponse.builder() @@ -61,7 +61,7 @@ public static TeacherRecruitmentResponse from(TeacherRecruitmentVO recruitment) .totalHiringCount(recruitment.getTotalHiringCount()) .hiringJobs(recruitment.getJobCodes()) .companyId(recruitment.getCompanyId()) - .isHireConvertible(recruitment.getIsHireConvertible()) + .hireConvertible(recruitment.getHireConvertible()) .build(); } } diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/model/Recruitment.java b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/model/Recruitment.java index 046abf0ba..f26297da7 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/model/Recruitment.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/model/Recruitment.java @@ -52,7 +52,7 @@ public class Recruitment { private final boolean winterIntern; - private final Boolean isHireConvertible; + private final Boolean hireConvertible; private final Long companyId; @@ -76,7 +76,7 @@ public static Recruitment of(ApplyRecruitmentRequest request, Long currentCompan .etc(request.etc()) .hiringProgress(request.hiringProgress()) .winterIntern(request.winterIntern()) - .isHireConvertible(request.isHireConvertible()) + .hireConvertible(request.hireConvertible()) .build(); } @@ -144,7 +144,7 @@ public Recruitment update(UpdateRecruitmentRequest request) { .militarySupport(request.military()) .submitDocument(request.submitDocument()) .recruitingPeriod(new RecruitingPeriod(request.startDate(), request.endDate())) - .isHireConvertible(request.hireConvertible()) + .hireConvertible(request.hireConvertible()) .etc(request.etc()) .build(); } diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/spi/vo/RecruitmentDetailVO.java b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/spi/vo/RecruitmentDetailVO.java index 92e28196b..f64de89af 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/spi/vo/RecruitmentDetailVO.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/spi/vo/RecruitmentDetailVO.java @@ -31,5 +31,5 @@ public class RecruitmentDetailVO { private final String companyBizNo; private final boolean winterIntern; private final boolean isBookmarked; - private final Boolean isHireConvertible; + private final Boolean hireConvertible; } diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/spi/vo/TeacherRecruitmentVO.java b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/spi/vo/TeacherRecruitmentVO.java index 52417017c..f6e5a0819 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/spi/vo/TeacherRecruitmentVO.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/spi/vo/TeacherRecruitmentVO.java @@ -22,6 +22,6 @@ public class TeacherRecruitmentVO { private final long requestedApplicationCount; private final long approvedApplicationCount; private final long companyId; - private final Boolean isHireConvertible; + private final Boolean hireConvertible; } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/RecruitmentPersistenceAdapter.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/RecruitmentPersistenceAdapter.java index 456ee67cc..2c7897e60 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/RecruitmentPersistenceAdapter.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/RecruitmentPersistenceAdapter.java @@ -116,7 +116,7 @@ public List getTeacherRecruitmentsBy(RecruitmentFilter fil requestedApplication.countDistinct(), approvedApplication.countDistinct(), companyEntity.id, - recruitmentEntity.isHireConvertible + recruitmentEntity.hireConvertible ) ) .from(recruitmentEntity) @@ -176,7 +176,7 @@ public List getTeacherRecruitmentsWithoutPageBy(Recruitmen requestedApplication.countDistinct(), approvedApplication.countDistinct(), companyEntity.id, - recruitmentEntity.isHireConvertible + recruitmentEntity.hireConvertible ) ) .from(recruitmentEntity) @@ -238,7 +238,7 @@ public RecruitmentDetailVO getByIdAndStudentIdOrThrow(Long recruitmentId, Long s companyEntity.bizNo, recruitmentEntity.winterIntern, bookmarkEntity.isNotNull(), - recruitmentEntity.isHireConvertible + recruitmentEntity.hireConvertible ) ) .from(recruitmentEntity) diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/entity/RecruitmentEntity.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/entity/RecruitmentEntity.java index d3e1b22f9..c7e8dc70a 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/entity/RecruitmentEntity.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/entity/RecruitmentEntity.java @@ -102,7 +102,7 @@ public class RecruitmentEntity extends BaseTimeEntity { private boolean winterIntern; @Column(columnDefinition = "TINYINT(1)") - private Boolean isHireConvertible; + private Boolean hireConvertible; @ManyToOne(fetch = FetchType.LAZY) @JoinColumn(name = "company_id", nullable = false) @@ -113,7 +113,7 @@ public RecruitmentEntity(Long id, int recruitYear, RecruitStatus status, String String submitDocument, LocalDate startDate, LocalDate endDate, CompanyEntity companyEntity, String benefits, boolean militarySupport, List requiredLicenses, String etc, List hiringProgress, Integer requiredGrade, boolean flexibleWorking, - boolean personalContact, boolean winterIntern, Boolean isHireConvertible) { + boolean personalContact, boolean winterIntern, Boolean hireConvertible) { this.id = id; this.workingHours = workingHours; this.flexibleWorking = flexibleWorking; @@ -130,7 +130,7 @@ public RecruitmentEntity(Long id, int recruitYear, RecruitStatus status, String this.requiredLicenses = requiredLicenses; this.militarySupport = militarySupport; this.winterIntern = winterIntern; - this.isHireConvertible = isHireConvertible; + this.hireConvertible = hireConvertible; this.etc = etc; } } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/mapper/RecruitmentMapper.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/mapper/RecruitmentMapper.java index b7f76c1da..ce67ab24d 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/mapper/RecruitmentMapper.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/mapper/RecruitmentMapper.java @@ -39,7 +39,7 @@ public RecruitmentEntity toEntity(Recruitment domain) { .workingHours(domain.getWorkingHours()) .flexibleWorking(domain.isFlexibleWorking()) .winterIntern(domain.isWinterIntern()) - .isHireConvertible(domain.getIsHireConvertible()) + .hireConvertible(domain.getHireConvertible()) .build(); } @@ -73,7 +73,7 @@ public Recruitment toDomain(RecruitmentEntity entity) { .submitDocument(entity.getSubmitDocument()) .submitDocument(entity.getSubmitDocument()) .winterIntern(entity.isWinterIntern()) - .isHireConvertible(entity.getIsHireConvertible()) + .hireConvertible(entity.getHireConvertible()) .createdAt(entity.getCreatedAt()) .build(); } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/repository/vo/QueryRecruitmentDetailVO.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/repository/vo/QueryRecruitmentDetailVO.java index ee9b71a7b..c4f42177b 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/repository/vo/QueryRecruitmentDetailVO.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/repository/vo/QueryRecruitmentDetailVO.java @@ -14,10 +14,10 @@ public QueryRecruitmentDetailVO(Long recruitmentId, Long companyId, String compa Integer requiredGrade, String workingHours, boolean flexibleWorking, List requiredLicenses, List hiringProgress, Integer trainPay, String pay, String benefits, Boolean military, String submitDocument, LocalDate startDate, LocalDate endDate, - String etc, String companyBizNo, boolean winterIntern, boolean isBookmarked, Boolean isHireConvertible) { + String etc, String companyBizNo, boolean winterIntern, boolean isBookmarked, Boolean hireConvertible) { super(recruitmentId, companyId, companyProfileUrl, companyName, requiredGrade, workingHours, flexibleWorking, requiredLicenses, hiringProgress, trainPay, pay, benefits, military, - submitDocument, startDate, endDate, etc, companyBizNo, winterIntern, isBookmarked, isHireConvertible); + submitDocument, startDate, endDate, etc, companyBizNo, winterIntern, isBookmarked, hireConvertible); } } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/repository/vo/QueryTeacherRecruitmentsVO.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/repository/vo/QueryTeacherRecruitmentsVO.java index 82b2f5d63..1af490562 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/repository/vo/QueryTeacherRecruitmentsVO.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/persistence/repository/vo/QueryTeacherRecruitmentsVO.java @@ -16,10 +16,10 @@ public QueryTeacherRecruitmentsVO(long recruitmentId, RecruitStatus recruitStatu LocalDate startDate, LocalDate endDate, String companyName, CompanyType companyType, String jobCodes, long totalHiring, long requestedApplicationCount, long approvedApplicationCount, - long companyId, Boolean isHireConvertible) { + long companyId, Boolean hireConvertible) { super(recruitmentId, recruitStatus, startDate, endDate, companyName, companyType, jobCodes, totalHiring, requestedApplicationCount, approvedApplicationCount, - companyId, isHireConvertible); + companyId, hireConvertible); } } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/dto/request/ApplyRecruitmentWebRequest.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/dto/request/ApplyRecruitmentWebRequest.java index 19788ef8d..37c8e6f38 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/dto/request/ApplyRecruitmentWebRequest.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/dto/request/ApplyRecruitmentWebRequest.java @@ -64,7 +64,7 @@ public class ApplyRecruitmentWebRequest { @NotNull private Boolean winterIntern; - private Boolean isHireConvertible; + private Boolean hireConvertible; @Size(max = 350) private String etc; @@ -89,7 +89,7 @@ public ApplyRecruitmentRequest toDomainRequest() { .startDate(this.startDate) .endDate(this.endDate) .winterIntern(this.winterIntern) - .isHireConvertible(this.isHireConvertible) + .hireConvertible(this.hireConvertible) .etc(this.etc) .build(); } From 378dbb7945d52d60b56b6b82f2a27d1ee65f6c7a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=B9=80=EB=AA=85=EC=A7=84?= <4mj.eo@dsm.hs.kr> Date: Fri, 25 Oct 2024 14:36:57 +0900 Subject: [PATCH 4/4] =?UTF-8?q?=E2=9A=99=EF=B8=8F=20::=20(#790)=20?= =?UTF-8?q?=EA=B4=80=EB=A0=A8=20=EC=97=86=EB=8A=94=20=EC=BD=94=EB=93=9C=20?= =?UTF-8?q?=EC=82=AD=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../TeacherQueryRecruitmentsUseCase.java | 17 ++--------------- .../presentation/RecruitmentWebAdapter.java | 14 ++------------ 2 files changed, 4 insertions(+), 27 deletions(-) diff --git a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/usecase/TeacherQueryRecruitmentsUseCase.java b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/usecase/TeacherQueryRecruitmentsUseCase.java index 26d77a44e..5a698ec1d 100644 --- a/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/usecase/TeacherQueryRecruitmentsUseCase.java +++ b/jobis-application/src/main/java/team/retum/jobis/domain/recruitment/usecase/TeacherQueryRecruitmentsUseCase.java @@ -59,21 +59,8 @@ public TeacherQueryRecruitmentsResponse executeWithoutPage(int year, List return new TeacherQueryRecruitmentsResponse(recruitments); } - public RecruitmentCountResponse countRecruitments(String companyName, LocalDate start, LocalDate end, - Integer year, RecruitStatus status, Boolean winterIntern, - Boolean militarySupport, List codeIds) { - RecruitmentFilter filter = RecruitmentFilter.builder() - .companyName(companyName) - .status(status) - .startDate(start) - .endDate(end) - .codes(codeIds) - .year(year) - .winterIntern(winterIntern) - .militarySupport(militarySupport) - .build(); - - Long count = queryRecruitmentPort.getCountBy(filter); + public RecruitmentCountResponse countRecruitments() { + Long count = queryRecruitmentPort.countRecruitments(); return new RecruitmentCountResponse(count); } diff --git a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/RecruitmentWebAdapter.java b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/RecruitmentWebAdapter.java index d53e73cfb..483aa70a4 100644 --- a/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/RecruitmentWebAdapter.java +++ b/jobis-infrastructure/src/main/java/team/retum/jobis/domain/recruitment/presentation/RecruitmentWebAdapter.java @@ -181,18 +181,8 @@ public TeacherQueryRecruitmentsResponse getRecruitmentListWithoutPage( } @GetMapping("/count") - public RecruitmentCountResponse countRecruitments( - @RequestParam(required = false) String companyName, - @RequestParam(required = false) LocalDate start, - @RequestParam(required = false) LocalDate end, - @RequestParam(required = false) Integer year, - @RequestParam(required = false) RecruitStatus status, - @RequestParam(required = false) Boolean winterIntern, - @RequestParam(required = false) Boolean militarySupport, - @RequestParam(required = false) List codeIds) { - return teacherQueryRecruitmentsUseCase.countRecruitments( - companyName, start, end, year, status, winterIntern, militarySupport, codeIds - ); + public RecruitmentCountResponse countRecruitments() { + return teacherQueryRecruitmentsUseCase.countRecruitments(); } @Cacheable