Koggili Farm

테이블 (32)

Detail

  • _id — String — 외래 키 → 가져온 상품.상품 ID — NOT NULL
  • 링크 — String
  • 상품설명 — String
  • 조회수 — String
  • 찜 — String
  • 상품이미지 — Array

가격 제시 (price_offers)

  • 가격 제시 ID (id) — bigint — 기본 키 — NOT NULL
  • 제시 회원 ID (offerer_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
  • 상품 ID (goods_id) — bigint — 외래 키 → 상품.상품 ID — NOT NULL
  • 제시 가액 (offered_price) — int4 — NOT NULL
  • 수락 여부 (accept_or_not) — bool
  • 생성 일자 (created_at) — timestamp — NOT NULL
  • 카테고리 영문 (nameEng) — 외래 키 → 상품.카테고리 영문 — NOT NULL

가져온 상품 (Items)

  • 상품 ID (_id) — String — 기본 키 — NOT NULL
  • link (href) — string
  • category (카테고리) — string
  • categoryName (카테고리명) — string
  • community (플랫폼) — string
  • communityName (플랫폼한글명) — string
  • parentCommunity (상위플랫폼) — string
  • parentCommunityName (상위플랫폼명) — string
  • salePrice (가격) — Integer
  • saleStatus (상태) — String
  • title (제목) — String
  • seller (업자확인) — boolean
  • regions (위치) — Array
  • name (위치이름) — String
  • coords (좌표) — Dict
  • lat (위도) — Double
  • lon (경도) — Double
  • shoppingMethod (구매방법) — Array
  • uploadTime (등록시간) — Timestamp
  • thumbId (썸네일) — string

거래 후기 (transaction_reviews)

  • 후기 ID (id) — bigint — 기본 키 — NOT NULL
  • 회원 ID (author_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
  • 상품 ID (goods_id) — bigint — 외래 키 → 상품.상품 ID — NOT NULL
  • 후기 메시지 (message) — varchar(255) — NOT NULL
  • 평가 항목 (evaluation_items) — int4[] — NOT NULL
  • 생성 일자 (created_at) — timestamp — NOT NULL
  • 카테고리 영문 (nameEng) — 외래 키 → 상품.카테고리 영문 — NOT NULL

결제취소 (PaymentCancel)

  • 취소ID (id) — string — 기본 키 — NOT NULL
  • 주문ID (id2) — string — 외래 키 → 주문.주문ID — NOT NULL
  • 취소상태 (cancelStatus) — ENUM — NOT NULL
  • 취소일시 (createdAt) — timestamp — NOT NULL

계정 (Account)

  • _id — string — 기본 키 — NOT NULL
  • 회원 ID (userId) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
  • 타입 (type) — String
  • 제공자 (provider) — String
  • 제공ID (providerAccountId) — String
  • refresh_token — String
  • access_token — String
  • refresh_token_expires_in — bigint
  • expires_at — bigint
  • token_type — String
  • scope — String

계좌 (BankAccount)

  • 계좌ID (id) — string — 기본 키 — NOT NULL
  • 예금주 (name) — string — NOT NULL
  • 은행 (bank) — string — NOT NULL
  • 계좌번호 (account_number) — string — NOT NULL
  • 기본계좌 (deefault) — Boolean — NOT NULL
  • 생성 일자 (created_at) — timestamp — NOT NULL

관심 상품 (wish_lists)

  • 관심 상품 ID (id) — bigint — 기본 키 — NOT NULL
  • 회원 ID (register_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
  • 상품 ID (goods_id) — bigint — 외래 키 → 상품.상품 ID — NOT NULL
  • 생성 일자 (created_at) — timestamp — NOT NULL
  • 카테고리 영문 (nameEng) — 외래 키 → 상품.카테고리 영문 — NOT NULL

모아보기 (follow_users)

  • 회원 ID (user_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
  • 대상 회원 ID (target_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
  • 생성 일자 (created_at) — timestamp — NOT NULL

상품 (goods)

  • 상품 ID (id) — string — 기본 키 — NOT NULL
  • 판매자 ID (seller_id) — string — 외래 키 → 회원.회원 ID — NOT NULL — BTREE IDX
  • 카테고리 영문 (category) — string — 외래 키 → 카테고리.카테고리 영문 — NOT NULL
  • 판매지역 ID (regions) — Array — 외래 키 → 지역테이블.지역 id — NOT NULL
  • 상품 제목 (title) — varchar(100) — NOT NULL — GIN IDX (TRIGRAM)
  • 상품 상태 (status) — enum — NOT NULL
  • 판매 가액 (salePrice) — int4
  • 조회수 (view_count) — int4 — NOT NULL
  • 상품 설명 (description) — text — NOT NULL
  • 끌올 일자 (refreshed_at) — timestamp — NOT NULL — GIN IDX
  • 생성 일자 (created_at) — timestamp — NOT NULL
  • 커뮤니티 이름 (communityName) — string — NOT NULL
  • 커뮤니티 (community) — string — NOT NULL

상품 사진 (goods_images)

  • 상품 ID (goods_id) — string — 외래 키 → 상품.상품 ID — NOT NULL
  • 파일 ID (file_id) — string — 외래 키 → 파일.파일 ID — NOT NULL
  • 삭제된날짜 (deletedAt) — timestamp
  • 수정일자 (modifiedAt) — timestamp — NOT NULL
  • 생성일자 (createdAt) — timestamp — NOT NULL

세션 (Session)

  • _id — string — 기본 키 — NOT NULL
  • 회원 ID (userId) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
  • sessionToken — String
  • expires — DateString

시세 (Untitled)

    알림 (notifications)

    • 알림 ID (id) — bigint — 기본 키 — NOT NULL
    • 수신 회원 ID (receiver_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
    • 알림 메시지 (message) — varchar(255) — NOT NULL
    • 읽기 여부 (readOrNot) — bool — NOT NULL
    • 알림 타입 (type) — enum — NOT NULL
    • 참조 ID (referenceId) — bigint — NOT NULL
    • 생성 일자 (created_at) — timestamp — NOT NULL

    알림 키워드 (notification_keywords)

    • 키워드 ID (id) — bigint — 기본 키 — NOT NULL
    • 등록 회원 ID (register_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
    • 키워드 (keyword) — varchar(10) — NOT NULL
    • 생성 일자 (created_at) — timestamp — NOT NULL

    연관키워드 (RelatedKeywords)

    • 키워드 ID (_id) — string — 기본 키 — NOT NULL
    • 키워드 (word) — NOT NULL
    • 연관검색어 (similarKeywords) — Array — NOT NULL

    유저 채팅방 (UserChatRoom)

    • 고유 ID (id) — bigint — 기본 키 — NOT NULL
    • 채팅방 ID (chatRoomId) — string — 외래 키 → 채팅방.채팅방 ID — NOT NULL
    • 회원 ID (userId) — string — 외래 키 → 회원.회원 ID — NOT NULL
    • 삭제 일자 (deletedAt) — timestamp
    • 수정일자 (modifiedAt) — timeStamp — NOT NULL
    • 생성일자 (createdAt) — timeStamp — NOT NULL

    자주쓰는 문구 (Cites)

    • 문구ID (id) — string — 기본 키 — NOT NULL
    • 회원 ID (userId) — string — 외래 키 → 회원.회원 ID — NOT NULL
    • 제목 (title) — string — NOT NULL
    • 문구 (cite) — string — NOT NULL
    • 생성 일자 (created_at) — timestamp — NOT NULL

    정산내역 (Settlement)

    • 정산ID (id) — string — 기본 키 — NOT NULL
    • 주문ID (payment_id) — string — 외래 키 → 주문.주문ID — NOT NULL
    • 계좌ID (account_id) — string — 외래 키 → 계좌.계좌ID — NOT NULL
    • 회원 ID (register_id) — string — 외래 키 → 회원.회원 ID — NOT NULL
    • 정산일자 (created_at) — timestamp — NOT NULL

    주문 (Payment)

    • 주문ID (id) — string — 기본 키 — NOT NULL
    • 회원 ID (register_id) — string — 외래 키 → 회원.회원 ID — NOT NULL
    • 상품 ID (product_id) — string — 외래 키 → 상품.상품 ID — NOT NULL
    • 주소ID (address_id) — string — 외래 키 → 주소.주소ID — NOT NULL
    • 주문금액 (payPrice) — int — NOT NULL
    • 주문상태 (payStatus) — ENUM — NOT NULL
    • 주문일시 (createdAt) — timestamp — NOT NULL

    주소 (Address)

    • 주소ID (id) — string — 기본 키 — NOT NULL
    • 회원 ID (register_id) — string — 외래 키 → 회원.회원 ID — NOT NULL
    • 이름 (name) — string — NOT NULL
    • 휴대폰번호 (phone_number) — string — NOT NULL
    • 주소 (address) — string — NOT NULL
    • 상세주소 (address_detail) — string — NOT NULL

    지역테이블 (regions)

    • 지역 id (_id) — string — 기본 키 — NOT NULL
    • 좌표 (coords) — string — NOT NULL
    • 위도 (lat) — double — NOT NULL
    • 경도 (lng) — double — NOT NULL
    • 시 (city) — string — NOT NULL
    • 시군구 (district) — string — NOT NULL
    • 동 (town) — string — NOT NULL
    • 읍면리 (sub) — string

    차단하기 (block_users)

    • 회원 ID (user_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
    • 대상 회원 ID (target_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
    • 생성 일자 (created_at) — timestamp — NOT NULL

    채팅 메시지 (chat_messages)

    • 채팅 메시지 ID (id) — string — 기본 키 — NOT NULL
    • 채팅방 ID (chat_room_id) — string — 외래 키 → 채팅방.채팅방 ID — NOT NULL
    • 발신 회원 ID (sender_id) — string — 외래 키 → 회원.회원 ID
    • 채팅 메시지 (message) — varchar(500) — NOT NULL
    • 읽기 여부 (read_or_not) — bool — NOT NULL
    • 메시지 타입 (messageType) — ENUM — NOT NULL
    • 생성 일자 (created_at) — timestamp — NOT NULL

    채팅 메시지파일 (MessageFile)

    • 채팅 메시지 ID (chatMessageId) — string — 외래 키 → 채팅 메시지.채팅 메시지 ID — NOT NULL
    • 파일 ID (fileId) — string — 외래 키 → 파일.파일 ID — NOT NULL

    채팅방 (chat_room)

    • 채팅방 ID (id) — bigint — 기본 키 — NOT NULL
    • 상품 ID (goods_id) — bigint — 외래 키 → 상품.상품 ID — NOT NULL
    • 구매자 ID (buyer_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
    • 생성 일자 (created_at) — timestamp — NOT NULL

    카테고리 (categories)

    • 카테고리 ID (id) — int4 — 기본 키 — NOT NULL
    • 카테고리 영문 (nameEng) — 기본 키 — NOT NULL
    • 카테고리 (name) — varchar(20) — NOT NULL

    키워드 (Keyword)

    • 키워드 ID (_id) — string — 기본 키 — NOT NULL
    • 키워드 (word) — NOT NULL
    • 스코어 (score) — NOT NULL

    파일 (files)

    • 파일 ID (id) — string — 기본 키 — NOT NULL
    • 회원 ID (uploader_id) — string — 외래 키 → 회원.회원 ID — NOT NULL
    • 파일 타입 (type) — varchar(50) — NOT NULL
    • 파일 이름 (name) — varchar(255) — NOT NULL
    • 생성 일자 (created_at) — timestamp — NOT NULL

    평가 항목 (evaluation_items)

    • 항목 ID (id) — int4 — 기본 키 — NOT NULL
    • 항목 점수 (score) — numeric(3, 1) — NOT NULL
    • 항목 내용 (text) — varchar(20) — NOT NULL

    활동 지역 설정 (activity_areas)

    • 회원 ID (user_id) — bigint — 외래 키 → 회원.회원 ID — NOT NULL
    • 활동 범위 (distance_meters) — int2 — NOT NULL
    • 활동 지역 (emd_area_ids) — int4[] — NOT NULL — GIN IDX
    • 인증 일자 (authenticated_at) — timestamp

    회원 (users)

    • 회원 ID (id) — string — 기본 키 — NOT NULL
    • 회원 권한 (role) — enum — NOT NULL — GIN IDX
    • 휴대폰 번호 (mobile_number) — varchar(11) — NOT NULL — UNQUE
    • 활성화 상태 (activated) — bool — NOT NULL
    • 평가 점수 (rating_score) — numeric(3,1) — NOT NULL
    • 생성 일자 (created_at) — timestamp — NOT NULL
    • 회원 email (email) — string — NOT NULL
    • 이메일 확인 (email_verified) — bool — NOT NULL
    • 프로필사진 (image) — string — NOT NULL
    • 상점배경사진 (profile_back_image) — NOT NULL
    • 닉네임 (nickname) — string — NOT NULL
    • 소개글 (intro) — string
    • 판매횟수 (count_sell) — int — NOT NULL
    • 상점방문수 (count_visit) — int — NOT NULL