Skip to content

Commit 84d638a

Browse files
committed
refactor[law]: law, law-word, precedent 리펙토링
1 parent 04182b8 commit 84d638a

File tree

6 files changed

+507
-317
lines changed

6 files changed

+507
-317
lines changed

backend/src/main/java/com/ai/lawyer/domain/law/controller/LawController.java

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,11 @@ public class LawController {
2424
@GetMapping(value = "/list/save")
2525
@Operation(summary = "키워드 관련 법령 데이터 저장(벡엔드 전용 API)", description = "벡엔드 데이터 저장용 API입니다")
2626
public ResponseEntity<?> getStatisticsCard(
27-
@RequestParam String query,
28-
@RequestParam int page
27+
@RequestParam String query
2928
) throws Exception {
3029
long startTime = System.currentTimeMillis();
3130

32-
lawService.saveLaw(query, page);
31+
lawService.saveLaw(query);
3332

3433
long endTime = System.currentTimeMillis();
3534
long elapsedTime = endTime - startTime;

backend/src/main/java/com/ai/lawyer/domain/law/repository/LawRepositoryCustomImpl.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -107,12 +107,12 @@ public Page<LawsDto> searchLaws(LawSearchRequestDto searchRequest) {
107107
return new PageImpl<>(content, pageable, 0);
108108
}
109109

110-
// 2. 조회한 법령 ID 목록 추출
110+
// 조회한 법령 ID 목록 추출
111111
List<Long> lawIds = content.stream()
112112
.map(LawsDto::getId)
113-
.collect(Collectors.toList());
113+
.toList();
114114

115-
// 3. 법령별 첫 번째 조 내용 조회 - 반복문으로 각각 조회
115+
// 3. 법령별 첫 번째 조 내용 조회 - 반복문으로 각각 조회
116116
Map<Long, String> firstJoContentMap = new HashMap<>();
117117
for (Long lawId : lawIds) {
118118
String firstJoContent = queryFactory

0 commit comments

Comments
 (0)