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] 상점 엔티티 설계 #47

Merged
merged 17 commits into from
Oct 7, 2024
Merged

[Feat] 상점 엔티티 설계 #47

merged 17 commits into from
Oct 7, 2024

Conversation

david-parkk
Copy link
Member

@david-parkk david-parkk commented Oct 3, 2024

✏️ 작업 개요

⛳ 작업 분류

  • 상점 조회 API
  • 상점 아이템 추가 API
  • 상점 구매 엔드포인트 변경

10/07 추가됨

  • 아이템 착용 API

🔨 작업 상세 내용

  1. 상점 엔티티 및 API 생성
  2. 상점 구매 엔드포인트를 POST /items -> POST /inventorys 로 변경하였습니다
  3. 상점 구매 request를 enum -> string 으로 변경하였습니다 (KICK_BOARD -> 킥보드)

💡 생각해볼 문제

  • 현재 상점과 인벤토리의 의존성이 아에 없는 상황입니다. 따라서 상점에 있는 데이터와 상관없이 ItemType에 있는 값이면 추가 됩니다.
  • 상점 관련 도메인은 어드민에서 사용될것으로 보이는데 상점 아이템 갯수 조정, 아이템 구매자 추적 말고 어떤 기능을 제공할 수 있을까요?

10/07 추가됨

  • 유저가 착용한 아이템은 인벤토리에서 관리하도록 하였습니다.(캐릭터에서 관리되는 것이 맞을까요?

image

  • 수정된 ERD 입니다. 연관 관계를 맺지 않는 경우 외래키가 있어도 선을 제거 하였습니다. (보시면 양옆으로 외래키를 가지고 있어요,
  • 최대한 연관관계를 제거하였습니다. 연관관계가 딱하나있는데, invertory_item이 item을 단방향 연관관계를 가지고 있습니다. 근거는 생명주기입니다.(invertory_item는 캐릭터가 가지고 있는 아이템)
  • 아이템id AI로 하면 안되기 때문에 별도로 index 칼럼을 두는 것을 고려하려다 직접 Id값을 지정하도록 변경하였습니다. (삭제 추가가 빈번히 일어나지 않는다고 생각하기 때문에)
  • 배포할때 데이터도 넣어야 되서 같이 작업 하시죠

@david-parkk david-parkk added the 기능구현 Good for newcomers label Oct 3, 2024
@david-parkk david-parkk requested a review from kamothi October 3, 2024 15:45
@david-parkk david-parkk self-assigned this Oct 3, 2024
Copy link

github-actions bot commented Oct 3, 2024

Test Results

22 tests   22 ✅  2s ⏱️
 5 suites   0 💤
 5 files     0 ❌

Results for commit 041a419.

♻️ This comment has been updated with latest results.

Copy link
Member

@kamothi kamothi left a comment

Choose a reason for hiding this comment

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

수고하셨습니다. 오늘 회의를 해보니 아이템에 탈 것이 빠지는 것 같아 해당 부분을 수정해야할 것 같습니다.

Copy link
Member

@kamothi kamothi left a comment

Choose a reason for hiding this comment

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

상점 관련 도메인은 어드민에서 사용될것으로 보이는데 상점 아이템 갯수 조정, 아이템 구매자 추적 말고 어떤 기능을 제공할 수 있을까요?

현재 생각하는 기능들은 위에서 언급하신 기능과 함께 아이템 삭제 정도로 생각하였습니다. 이정도면 현재는 충분한 것 같아요.

@kamothi kamothi merged commit a79f1e7 into main Oct 7, 2024
3 checks passed
@kamothi
Copy link
Member

kamothi commented Oct 7, 2024

/쿠타버스 배포

@kamothi kamothi deleted the feat/shop branch October 7, 2024 07:47
@kamothi
Copy link
Member

kamothi commented Oct 7, 2024

🌎 배포하였습니다.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants