Skip to content

Commit 1fc11d7

Browse files
authoredDec 16, 2024··
컨트롤러 레이어 리팩토링 (#55)
* refactor: Question관련 Service 빈을 동적으로 추출하는 QuestionServiceFactory 추가 - questionType, Field, Act를 기반으로 Question Service 관련 빈을 반환 - 이를 통해 중복 URL API 감소 - MultipleChoiceQuestionGradeService에 적용(questionType : multiple, questionField: license,major, act:grade) * refactor: QuestionServiceFactory가 Service 빈을 제네릭 타입으로 반환하도록 수정 - 메소드 재사용성 극대화 * refactor: Question Update 관련 API 통일 - 본문 업데이트, 개시 허용, 해설 업데이트 API 축소 * refactor: Question Image Update API 수정 - 통일 * test: QuestionCommonUpdateController Test 추가 - 기존 공통된 Question Update관련 로직 테스트를 구현 * test: 기존 Update 관련 테스트를 QuestionCommonUpdateController로 이동 * refactor: QuestionChoice를 엔티티로 분리하고 조인 전략 적용 * style: 코드 컨벤션 적용 * refactor: QuestionCommonChoiceUpdate 로직을 통일 * style: 패키지 구조 수정 - 도메인 단위 구별-> 레이어별 구별 에서 레이어별 구별 -> 도메인 단위 구별로 수정 * refactor: Major Question 업데이트 페이지 API를 하나로 축소 및 제거 * refactor: 문제 조회시 분류 작업에 대하여 제너릭 와일드카드를 적용 - 호출부에선 Question으로 호출하여 재사용 극대화 - QuestionClassifyCategoryService에서 인자로 와일드카드를 받고 Question 명시적 반환 * test: 전공 문제 생성과 관련된 Test 수정 - URL 수정 * refactor: QuestonViewController 유지보수성 향상 - HTML 태그는 클래스단위로 관리 - 재사용 가능한 함수 분리 * refactor: Question 업데이트 페이지 API를 QuestionUpdateViewController로 통일 * test: Test 수정 * style: 코드 컨벤션 적용
1 parent 9f1ca7b commit 1fc11d7

File tree

95 files changed

+1292
-1396
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

95 files changed

+1292
-1396
lines changed
 

‎application/src/main/java/com/comssa/api/question/common/config/S3Config.java ‎application/src/main/java/com/comssa/api/config/S3Config.java

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package com.comssa.api.question.common.config;
1+
package com.comssa.api.config;
22

33
import com.amazonaws.auth.AWSCredentials;
44
import com.amazonaws.auth.AWSStaticCredentialsProvider;
+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package com.comssa.api.question.major.common.exception;
1+
package com.comssa.api.exception;
22

33
public class DuplicateQuestionException extends Exception {
44
public DuplicateQuestionException() {

0 commit comments

Comments
 (0)
Please sign in to comment.