Skip to content

Commit

Permalink
[feat]나의 주문폼 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
yunji118 committed Dec 28, 2023
1 parent 12110b1 commit dd37c72
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@
public class MySalesProjectController {
private final MySalesProjectService mySalesProjectService;

//판매 등록폼 전체보기
@GetMapping()
public MySalesListResponseDto getMySalesList(@RequestParam(value = "page", defaultValue = "1", required = false)int page, @AuthenticationPrincipal User user){
Pageable pageable = PageRequest.of(page - 1, 10);
Expand All @@ -29,6 +30,7 @@ public ResponseEntity finishMySales(@PathVariable Long project_id){
return mySalesProjectService.finishMySalesForm(project_id);
}

//판매 등록폼 상세보기
@GetMapping("/detail/{project_id}")
public MySalesDetailResponseDto getMySalesDetail(@PathVariable Long project_id){
return mySalesProjectService.findMySalesDetail(project_id);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,11 @@ public class MySalesDetailResponseDto {
private String seller_account;
private String seller_account_name;
private String seller_nickname;
private Long delivery_fee;
private String seller_phone_number;
private String seller_email;
private String seller_etc;


public MySalesDetailResponseDto(Project project, List<MySalesItemDto> itemDtos){
this.projectId = project.getId();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,15 @@ public class MySalesFormDto {
private String name;
private LocalDateTime createdtime;
private int status;
private String description;
private String thumbnail;

public MySalesFormDto(Project project){
this.id = project.getId();
this.name = project.getName();
this.createdtime = project.getCreated_time();
this.status = (project.isEnd() == false? 0 : 1);
this.description = project.getDescription();
this.thumbnail = project.getThumbnail();
}
}

0 comments on commit dd37c72

Please sign in to comment.