credit order

Tables (12)

branch (크레딧오더 지점)

  • branch_uid — NOT NULL — Primary key — NOT NULL
  • 지점명 (display_name) — NOT NULL
  • 지점 유형 (카페/주차장/상품코드) (type) — NOT NULL
  • 설명 (description) — NULLABLE
  • 위도 (latitude) — NULLABLE
  • 경도 (longitude) — NULLABLE
  • 지번 주소 (jibun_address) — NULLABLE
  • 도로명 주소 (street_address) — NULLABLE
  • 운영 여부 (운영/폐점) (is_opened) — NOT NULL
  • 노출/활성여부 (is_active) — NOT NULL
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL

branch_image_file (크레딧 오더 지점 이미지)

  • branch_image_file_uid — NOT NULL — Primary key — NOT NULL
  • branch_uid — NOT NULL — Foreign key → branch.branch_uid — NOT NULL
  • url — NOT NULL
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL

branch_time_policy (크레딧 오더 지점별 운영시간)

  • branch_time_policy_uid — NOT NULL — Primary key — NOT NULL
  • branch_uid — NOT NULL — Foreign key → branch.branch_uid — NOT NULL
  • day_of_week — NOT NULL
  • 영업 시작시간 (start_time) — NOT NULL
  • 영업 종료시간 (end_time) — NOT NULL
  • 새벽운영여부 (is_next_day) — NOT NULL
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL

fulfillment (주문 추가 정보)

  • fulfillment_uid (delivery_uid) — NOT NULL — Primary key — NOT NULL
  • order_uid (FK) (order_uid) — NOT NULL
  • 수령 주소 (shipping_address) — NULLABLE
  • 받는사람 전화번호 (recipient_contact) — NOT NULL
  • 받는사람 (recipient_name) — NOT NULL
  • 차량번호 (vehicle_number) — NULLABLE
  • 요청사항 (memo) — NULLABLE
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL

product (상품)

  • product_uid — NOT NULL — Primary key — NOT NULL
  • product_category_uid — NOT NULL — Foreign key → product_category.product_category_uid — NOT NULL
  • branch_uid — NOT NULL — Foreign key → product_category.branch_uid — NOT NULL
  • 상품명 (product_name) — NOT NULL
  • 설명 (description) — NULLABLE
  • 정규 가격 (크레딧) (regular_price) — NOT NULL
  • 실 판매 가격 (크레딧) (selling_price) — NOT NULL
  • 실제 현장 판매가 (krw) (krw_price) — NOT NULL
  • 상태 (판매중/품절) (status) — NOT NULL
  • 태그 (인기/신규/none) (tag) — NULLABLE
  • 판매 순서 (product_sort_order) — NOT NULL
  • 판매방식 (배송지값 필요/불필요) (fulfillment_type) — NOT NULL
  • 노출/활성여부 (is_active) — NOT NULL
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL

product_category (상품 카테고리(스무디/커피/논커피/정기권/일회권 등))

  • product_category_uid — NOT NULL — Primary key — NOT NULL
  • branch_uid — NOT NULL — Foreign key → branch.branch_uid — NOT NULL
  • 상품 카테고리 (category_name) — NOT NULL
  • 정렬 순서 (category_sort_order) — NOT NULL
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL

product_image_file (크레딧 오더 상품 이미지)

  • product_image_file_uid — NOT NULL — Primary key — NOT NULL
  • product_uid — NOT NULL — Foreign key → product.product_uid — NOT NULL
  • product_category_uid — NOT NULL — Foreign key → product.product_category_uid — NOT NULL
  • branch_uid — NOT NULL — Foreign key → product.branch_uid — NOT NULL
  • url — NOT NULL
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL

product_option (상품 무료 옵션 (미정))

  • product_option_uid — NOT NULL — Primary key — NOT NULL
  • Field

shop_order (주문)

  • shop_order_uid (order_uid) — NOT NULL — Primary key — NOT NULL
  • branch_uid — NOT NULL — Foreign key → branch.branch_uid — NOT NULL
  • member_group_uid (cms FK) (member_group_uid) — NOT NULL
  • member_uid (cms FK) (member_uid) — NOT NULL
  • 주문 상태 (결제전/결제완/취소/배치처리) (status) — NOT NULL
  • 결제 총 액 (total_price) — NOT NULL
  • 결제 총 액 (krw) (total_krw_price) — NOT NULL
  • 주문번호 (order_no) — NOT NULL
  • 주문 취소 여부 (is_canceled) — NOT NULL
  • 취소한 사람 (member/user/admin) (canceled_by) — NULLABLE
  • 크레딧 차감 시간 (credit_used_at) — NOT NULL
  • 메모 (memo) — NULLABLE
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL
  • canceled_at — NULLABLE

shop_order_item (주문 내역)

  • shop_order_item_uid (order_item_uid) — NOT NULL — Primary key — NOT NULL
  • order_uid — NOT NULL — Foreign key → shop_order.shop_order_uid — NOT NULL
  • branch_uid — NOT NULL — Foreign key → shop_order.branch_uid — NOT NULL
  • product_uid (FK) (product_uid) — NOT NULL
  • 상품명 [스냅샷] (product_name) — NOT NULL
  • 가격 (크레딧) [스냅샷] (price) — NOT NULL
  • 실제 현장 판매가 (krw) [스냅샷] (krw_price) — NOT NULL
  • 수량 (quantity) — NOT NULL
  • 수량 x 가격 [스냅샷] (line_price) — NOT NULL
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL

user (사장님용 페이지 유저)

  • user_uid — NOT NULL — Primary key — NOT NULL
  • 이름 (name) — NOT NULL
  • 이메일 (email) — NOT NULL
  • 비밀번호 (password) — NOT NULL
  • 전화번호 (phone_number) — NOT NULL
  • 유저 상태(활성/탈퇴) (user_status) — NOT NULL
  • 어드민 (패파인(전체관리자)) (is_admin) — NOT NULL
  • 마지막 로그인 시간 (last_login_at) — NULLABLE
  • 탈퇴 시간 (leaved_at) — NULLABLE
  • 탈퇴 사유 (leave_message) — NULLABLE
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL

user_branch (유저가 속한 지점)

  • user_branch_uid — NOT NULL — Primary key — NOT NULL
  • branch_uid — NOT NULL — Foreign key → branch.branch_uid — NOT NULL
  • user_uid — NOT NULL — Foreign key → user.user_uid — NOT NULL
  • created_at — NOT NULL
  • updated_at — NOT NULL
  • is_deleted — NOT NULL