-
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.
Merge pull request #180 from PawWithU/feat/177-application-api-modify
[Feature] 이동봉사 신청 관련 API 수정
- Loading branch information
Showing
12 changed files
with
122 additions
and
106 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
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
12 changes: 9 additions & 3 deletions
12
...thu/connectdog/domain/application/dto/response/ApplicationIntermediaryGetOneResponse.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,12 +1,18 @@ | ||
package com.pawwithu.connectdog.domain.application.dto.response; | ||
|
||
import com.fasterxml.jackson.annotation.JsonFormat; | ||
import com.pawwithu.connectdog.domain.application.entity.Application; | ||
|
||
public record ApplicationIntermediaryGetOneResponse(Long id, String volunteerName, String phone, String transportation, String content) { | ||
import java.time.LocalDate; | ||
|
||
public record ApplicationIntermediaryGetOneResponse(Long id, | ||
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy.MM.dd", timezone = "Asia/Seoul") | ||
LocalDate createdDate, | ||
String volunteerName, String phone, String content) { | ||
|
||
public static ApplicationIntermediaryGetOneResponse from(Application application) { | ||
return new ApplicationIntermediaryGetOneResponse(application.getId(), application.getVolunteerName(), | ||
application.getPhone(), application.getTransportation(), application.getContent()); | ||
return new ApplicationIntermediaryGetOneResponse(application.getId(), application.getCreatedDate().toLocalDate(), | ||
application.getVolunteerName(), application.getPhone(), application.getContent()); | ||
} | ||
|
||
} |
14 changes: 10 additions & 4 deletions
14
...wwithu/connectdog/domain/application/dto/response/ApplicationVolunteerGetOneResponse.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,12 +1,18 @@ | ||
package com.pawwithu.connectdog.domain.application.dto.response; | ||
|
||
import com.fasterxml.jackson.annotation.JsonFormat; | ||
import com.pawwithu.connectdog.domain.application.entity.Application; | ||
|
||
public record ApplicationVolunteerGetOneResponse(Long id, String volunteerName, String phone, String transportation, String content) { | ||
import java.time.LocalDate; | ||
|
||
public record ApplicationVolunteerGetOneResponse(Long id, | ||
@JsonFormat(shape = JsonFormat.Shape.STRING, pattern = "yyyy.MM.dd", timezone = "Asia/Seoul") | ||
LocalDate createdDate, | ||
String volunteerName, String phone, String content) { | ||
|
||
public static ApplicationVolunteerGetOneResponse from(Application application) { | ||
return new ApplicationVolunteerGetOneResponse(application.getId(), application.getVolunteerName(), application.getPhone(), application.getTransportation(), application.getContent()); | ||
return new ApplicationVolunteerGetOneResponse(application.getId(), application.getCreatedDate().toLocalDate(), | ||
application.getVolunteerName(), application.getPhone(), application.getContent()); | ||
} | ||
|
||
} | ||
|
||
} |
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
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
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
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
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
Oops, something went wrong.