Skip to content

Conversation

@Soundbar91
Copy link
Collaborator

@Soundbar91 Soundbar91 commented Sep 5, 2025

🔍 개요


🚀 주요 변경 내용

주문 & 결제 테이블 수정

Untitled (1)
  • ERD 링크
  • String으로 관리되던 order 테이블의 pk를 Integer으로 변경했습니다.
  • 차후에 고려될 가능성이 있는 시간 데이터 컬럼을 order, order_takeout, order_delivery 테이블에 추가했습니다.
  • 동일한 메뉴 담기 기능을 위해 주문 메뉴 관련 테이블에 fk를 추가했습니다.
    • order_menu : orderable_shop_menu_price_id, orderable_shop_menu_id
    • order_meun_option : orderable_shop_menu_option_id, orderable_shop_menu_option_group_id
  • payment 테이블에 컬럼을 추가했습니다.
    • description : 주문 요약 설명 (ex. 족발 외 1개)
    • easy_pay_company : 간편 결제사 (ex. 삼성페이)
    • recipt : 토스 페이먼츠에서 내려주는 payment 객체를 파싱해서 json 형태로 저장
  • 각 테이블에 메타 데이터 (is_deleted, created_at, updated_at)를 추가했습니다.

주문 정보 저장 로직 수정

  • order_menu와 order_menu_option에 주문 가능 상점 메뉴, 가격, 옵션과 연간관계가 생기면서 임시 정보 저장 과정에서 주문 메뉴를 저장하는 로직을 삭제했습니다.
  • 결제 승인 이후에 장바구니에 접근하여 변환하도록 수정했습니다.

주문 주소 컬럼 추가 및 검증 로직 추가

  • 단일로 받는 address를 address, address_detail으로 분리했습니다.
  • RoadNameAddressValidator 검증 로직을 추가했습니다.

💬 참고 사항

  • 테이블 설계를 잘 해야함을 느끼는 순간이였습니다.
  • 커밋 단위로 보시면 편하실겁니다.

✅ Checklist (완료 조건)

  • 코드 스타일 가이드 준수
  • 테스트 코드 포함됨
  • Reviewers / Assignees / Labels 지정 완료
  • 보안 및 민감 정보 검증 (API 키, 환경 변수, 개인정보 등)

@github-actions github-actions bot added DB DB 마이그레이션을 위한 라벨입니다. 버그 정상적으로 동작하지 않는 문제상황입니다. labels Sep 5, 2025
@Soundbar91 Soundbar91 self-assigned this Sep 5, 2025
@github-actions
Copy link

github-actions bot commented Sep 5, 2025

Unit Test Results

528 tests   527 ✔️  1m 10s ⏱️
109 suites      1 💤
109 files        0

Results for commit e10e965.

♻️ This comment has been updated with latest results.

Copy link
Collaborator

@BaeJinho4028 BaeJinho4028 left a comment

Choose a reason for hiding this comment

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

테이블 삭제는 새로운 테이블로 완전히 이전이 되면 해주시면 좋겠습니다.
하위호환성을 무시하고 삭제하려고하면 배포시에 Blue WAS에서 삭제된 테이블을 참조하게되어 오류가 발생합니다. 그래서 완전히 v2로 옮겨졌을 때 삭제를 해야하므로 옮겨지기 전까지는 cleanup 패키지에 넣어두시면 좋을 것 같습니다.

Copy link
Collaborator

@DHkimgit DHkimgit left a comment

Choose a reason for hiding this comment

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

수고하셨습니다!!

@dldb-chamchi
Copy link
Contributor

모두 확인하였습니다! 늦은시간까지 정말 고생많으셨습니다 🙇

Copy link
Contributor

@dldb-chamchi dldb-chamchi left a comment

Choose a reason for hiding this comment

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

새벽까지 정말 수고 많으셨습니다! 🙇

@Soundbar91 Soundbar91 merged commit d2dda56 into develop Sep 6, 2025
5 checks passed
@Soundbar91 Soundbar91 deleted the fix/1929-payment-order-table branch September 6, 2025 18:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

DB DB 마이그레이션을 위한 라벨입니다. 버그 정상적으로 동작하지 않는 문제상황입니다.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[sprint] 결제 & 주문 테이블 수정

5 participants