-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- 이미지 리스트를 빼고, responseDto의 id 필드 이름 변경 및 생성자에 추가 - 페이징 추가
- Loading branch information
Showing
3 changed files
with
12 additions
and
11 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
10 changes: 2 additions & 8 deletions
10
src/main/java/com/mpnp/baechelin/admin/dto/AdminResponseDto.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 |
---|---|---|
@@ -1,37 +1,31 @@ | ||
package com.mpnp.baechelin.admin.dto; | ||
|
||
import com.mpnp.baechelin.store.domain.UserRegisterStore; | ||
import com.mpnp.baechelin.store.dto.userRegisterStore.UserRegisterStoreImgDto; | ||
import lombok.Builder; | ||
import lombok.Getter; | ||
import lombok.NoArgsConstructor; | ||
|
||
import java.util.List; | ||
import java.util.stream.Collectors; | ||
|
||
@Getter | ||
@NoArgsConstructor | ||
public class AdminResponseDto { | ||
private int id; | ||
private int registerStoreId; | ||
private String name; | ||
private String address; | ||
private String elevator; | ||
private String toilet; | ||
private String heightDifferent; | ||
private String approach; | ||
private List<UserRegisterStoreImgDto> userRegisterStoreImageList; | ||
|
||
@Builder | ||
public AdminResponseDto( | ||
UserRegisterStore userRegisterStore | ||
) { | ||
this.registerStoreId = userRegisterStore.getId(); | ||
this.name = userRegisterStore.getName(); | ||
this.address = userRegisterStore.getAddress(); | ||
this.elevator = userRegisterStore.getElevator(); | ||
this.toilet = userRegisterStore.getToilet(); | ||
this.heightDifferent = userRegisterStore.getHeightDifferent(); | ||
this.approach = userRegisterStore.getApproach(); | ||
this.userRegisterStoreImageList = userRegisterStore.getUserRegisterStoreImgList().parallelStream() | ||
.map(UserRegisterStoreImgDto::new).collect(Collectors.toList()); | ||
} | ||
} |
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