Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat : [어드민] 발급 티켓 리스트 가져오기 API 개발 #94

Merged
merged 6 commits into from
Jan 12, 2023

Conversation

sanbonai06
Copy link
Member

개요

작업사항

  • 내용을 적어주세요.
  • 페이지네이션 작업까지 완료 했습니다.
  • 검색 조건을 물어봤으나 아직 답변이 오지 않아서 이름 검색까지만 구현해 놓았습니다.
  • 예시
/api/v1/admin/issuedTickets?page=1&eventId=1&userName=민준

{
  "success": true,
  "status": 200,
  "data": {
    "page": 1,
    "totalPage": 1,
    "issuedTickets": [
      {
        "issuedTicketInfo": {
          "issuedTicketId": 1,
          "issuedTicketNo": "T10000001",
          "uuid": "sfasdfasfasdfsdfaf",
          "ticketName": "test",
          "ticketPrice": {
            "amount": 4000
          },
          "createdAt": "2023-01-11 12:08:59",
          "issuedTicketStatus": "ENTRANCE_INCOMPLETE",
          "optionPrice": {
            "amount": 0
          }
        },
        "userInfo": {
          "userId": 1,
          "userName": "김민준",
          "email": "sanbonai06@nate.com",
          "phoneNumber": "+82 10-2623-9201"
        }
      }
    ]
  },
  "timeStamp": "2023-01-12T01:57:21.614969"
}
  • 추가로 발급 티켓 생성 로직에서 옵션에 대한 답변 로직을 추가했습니다.

변경로직

  • 내용을 적어주세요.

@sanbonai06 sanbonai06 added For: API [이슈 대상] 외부 API Type: Feature [이슈 목적] 새로운 기능 추가 labels Jan 11, 2023
@sanbonai06 sanbonai06 self-assigned this Jan 11, 2023
@sonarqubecloud
Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 133 Code Smells

7.9% 7.9% Coverage
0.4% 0.4% Duplication

Copy link
Member

@ImNM ImNM left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

수고하셨어유!

이름이랑 전화번호 두개로 검색 가능 하면 될것 같습니다~!

Comment on lines -39 to +50
return new IssuedTicketDTO(issuedTicket);
List<IssuedTicketOptionAnswer> issuedTicketOptionAnswers =
createIssuedTicketRequest.getOptionAnswers().stream()
.map(
IssuedTicketOptionAnswer
::orderOptionAnswerToIssuedTicketOptionAnswer)
.toList();
/*
티켓 옵션 답변 매핑
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

뭔가 orderOptionAnswer 가져가니깐
orderLine 도메인 객체로 티켓 생성하는것도 나쁘지않을것같아유

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

생각만하고 바꾸질 않았네요ㅠㅠ 수정하겠습니당

public RetrieveIssuedTicketListResponse execute(Long page, Long eventId, String userName) {
Long currentUserId = SecurityUtils.getCurrentUserId();
// 조회 유저 권한 인증
eventService.checkEventHost(currentUserId, eventId);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

민준이 파트는 아니긴하지만
호스트 관리자 목록이있어서 그거까지 나중에 변경해야할듯하긴해용
이벤트가 어그리게이트가 된다면 ( 관리자 관리에 )
event.valid관리자()
뭐이런식으루!

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

흠 일단 아직 이벤트 도메인에 관리자 목록 정보가 없어서 호스트로만 권한 검사하긴 했는데 관리자 목록 추가되면 수정하겠습니다.

Copy link
Member

@kim-wonjin kim-wonjin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM☺️

@sanbonai06 sanbonai06 merged commit 47f41d4 into dev Jan 12, 2023
@sanbonai06 sanbonai06 deleted the feature/85-issued-ticket-list branch January 12, 2023 05:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
For: API [이슈 대상] 외부 API Type: Feature [이슈 목적] 새로운 기능 추가
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

🚀 [feature] 발급 티켓 리스트 가져오기 API 개발 (페이지네이션) (어드민 기능)
3 participants