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

[NDD-132] video api mocking 추가 (2h / 2h) #39

Merged
merged 3 commits into from
Nov 15, 2023
Merged

Conversation

milk717
Copy link
Collaborator

@milk717 milk717 commented Nov 13, 2023

NDD-132 Powered by Pull Request Badge

  • 일단 명세대로 만들었으나 의문이 드는 부분과 변경 요청을 드리고 싶은 부분이 있어서 2023.11.14일에 대면으로 만나서 의논할 예정

Why

  • 명세대로 mocking만 진행한다면 1시간도 안걸릴 일이었겠지만, 변경 사항이 생길 것 같아서 넉넉하게 스토리포인트를 2로 산정했습니다.

How

api 명세에서 궁금한 것과 수정 요청할 것

api 명세서에 나와있는대로 mocking 작업을 진행하던 중 아래와 같은 의문점이 생겼습니다.

/api/video/all => 마이페이지에서 전체 동영상 리스트를 불러오는 api

현재 응답 형식

[
  {
    id: 비디오 ID,
    questionId: 질문 ID,
    thumbnail: 썸네일 이미지,
    videoName: 비디오의 이름,
    videoLength: 비디오의 길이,
    isPublic: 비디오 공개 여부
    createdAt: 비디오 촬영 날짜,
  },
  ...
]

궁금한 것과 요청사항

  • videoLength 형식은 어떤지? hh:mm:ss 예상하고있습니다.
  • createdAt 날짜 형식은 어떻게 되나요? ISO 8601 예상하고있습니다.
  • questionId는 왜 응답에 포함하신건지 궁금합니다.

/api/video/${videoId}

현재 응답 형식

{
  id: 비디오의 ID,
  url: 비디오의 URL,
  hash: 해싱된 비디오의 URL / 비디오가 private면 null
}

궁금한 것과 요청사항

  • 요기도 이름과 날짜를 내려주세요
    • 리스트 보기에서 받아왔던 정보를 넘겨도 되긴 하는데 이렇게 되면 영상 공개 url을 통해서 접근했을 때는 이름과 날짜를 알 수 없습니다.

Result

api 의논 결과

/api/video/all

  • id: number
  • videoName: string
  • thumbnail: 썸네일 url
  • videoLength: mm:ss 형식의 문자열
  • isPublic: boolean
  • createdAt: UNIX time

questionId를 포함했던 이유는 나중에 동영상과 관련된 질문 등을 표시하기 위해서 넣었던건데
아직 기획에 없는 부분이므로 현재 단계에서는 응답에서 제외하기로 결정했습니다.

/api/video/${videoId}

  • id: number
  • url: 비디오 링크
  • hash: 해시 스트링
  • videoName: string
  • createdAt: UNIX time

비디오 상세보기 페이지에서 영상을 전체 링크 공유로 설정했을 경우를 대비해서 videoName과 createdAt 필드가 추가되었습니다.

- 일단 명세대로 만들었으나 의문이 드는 부분과 변경 요청을 드리고 싶은 부분이 있어서 2023.11.14일에 대면으로 만나서 의논할 예정
@milk717 milk717 added FE 프론트엔드 코드 변경사항 feature 새로운 기능이 추가 된 경우 labels Nov 13, 2023
@milk717 milk717 self-assigned this Nov 13, 2023
@adultlee
Copy link
Collaborator

완성되기 전이군요 우선 발견했으니 도장찍구 갑니다!😎

@crongro
Copy link

crongro commented Nov 14, 2023

pr을 열어두는 것도 진행사항을 공유하는 것이라 좋네요.
그런데 너무 오랫동안 유지 않도록 주의하세요~ (작업의 크기가 커질 수 있어서요)

Copy link

cloudflare-workers-and-pages bot commented Nov 14, 2023

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: c359e29
Status: ✅  Deploy successful!
Preview URL: https://1a05cd72.gomterview.pages.dev
Branch Preview URL: https://feature-ndd-132.gomterview.pages.dev

View logs

@milk717 milk717 changed the title [NDD-132] 🚧진행중 (리뷰 안해도 됩니다!!)🚧 video api mocking 추가 (0.5h ~ / 2h) [NDD-132] video api mocking 추가 (2h / 2h) Nov 14, 2023
@milk717 milk717 marked this pull request as ready for review November 14, 2023 06:32
Copy link
Collaborator

@Yoon-Hae-Min Yoon-Hae-Min left a comment

Choose a reason for hiding this comment

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

video 어떻게 처리할지 몰라서 전에 작업 때 안했었는데 이번에 작업이 되니 아주 좋습니다!!

FE/src/mocks/handlers/video.ts Show resolved Hide resolved
Copy link
Collaborator

@Yoon-Hae-Min Yoon-Hae-Min left a comment

Choose a reason for hiding this comment

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

video 어떻게 처리할지 몰라서 전에 작업 때 안했었는데 이번에 작업이 되니 아주 좋습니다!!

@Yoon-Hae-Min
Copy link
Collaborator

뭐야 왜 입력이 2번된거죠 ㅋㅋㅋㅋ

Copy link
Collaborator

@adultlee adultlee left a comment

Choose a reason for hiding this comment

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

왜 한줄 알았지!! 늦어서 너무 죄송합니다 ㅠ

@milk717 milk717 merged commit 80f7b9b into dev Nov 15, 2023
1 check passed
@delete-merged-branch delete-merged-branch bot deleted the feature/NDD-132 branch November 15, 2023 04:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FE 프론트엔드 코드 변경사항 feature 새로운 기능이 추가 된 경우
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants