UMC week1
테이블 (13)
Untitled (perfer_categories)
- Key (id) — bigint — 기본 키 — NOT NULL
- 카테고리 명 (name) — enum
Untitled (mission_mapping)
- 아이디 (user_id) — bigint — 외래 키 → 사용자.아이디 — NOT NULL
- 아이디 (mission_id) — bigint — 외래 키 → 미션.아이디 — NOT NULL
- 상태 (status) — enum('진행중, '완료')
- 생성일 (created_at) — datetime(6)
- 수정일 (updated_at) — datetime(6)
- 제한시간 (limited_at) — int
가게 (stores)
- 아이디 (id) — bigint — 기본 키 — NOT NULL
- 가게 이름 (name) — varchar(25)
- 가게 주소 (address) — varchar(255)
- 별점 (stars) — double
- 리뷰 수 (reviews) — bigint
- 가게 유형 (store_type) — enum
- 가격 (price) — int
- 메뉴 이름 (menu_name) — text
가게 리뷰 (store_review)
- Key (id) — bigint — 기본 키 — NOT NULL
- 아이디 (store_id) — bigint — 외래 키 → 가게.아이디 — NOT NULL
- 아이디 (user_id) — bigint — 외래 키 → 사용자.아이디 — NOT NULL
- Field (title) — varchar(255)
- Field (context) — text
- Field (score) — int
- Field (created_at) — datetime(6)
- Field (updated_at) — datetime(6)
리뷰 답변 (review_answer)
- Key (id) — bigint — 기본 키 — NOT NULL
- Key (review_id) — bigint — 외래 키 → 가게 리뷰.Key — NOT NULL
- Field (context) — text
- Field (created_at) — datetime(6)
- Field (updated_at) — datetime(6)
리뷰 사진 (review_imgs)
- idi (id) — bigint — 기본 키 — NOT NULL
- 리뷰 id (review_id) — bigint — 외래 키 → 가게 리뷰.아이디 — NOT NULL
- 리뷰 아이디 (reciew_img) — varchar(255)
문의 (inquiries)
- Key (id) — bigint — 기본 키 — NOT NULL
- 사용자 id (user_id) — bigint — 외래 키 → 사용자.아이디 — NOT NULL
- 문의 제목 (title) — varchar(255)
- 문의 내용 (context) — text
- 문의 유형 (type) — enum
- 문의 상태 (status) — enum
- 생성일 (created_at) — datetime(6)
- 수정일 (updated_at) — datetime(6)
문의 사진 (inquiries_img)
- id — bigint — 기본 키 — NOT NULL
- 문의 아이디 (inquiry_id) — bigint — 외래 키 → 문의.사용자 id — NOT NULL
- 문의 사진 주소 (img) — varchar(255)
미션 (missions)
- 아이디 (id) — bigint — 기본 키 — NOT NULL
- 미션 포인트 (point) — bigint
- 가게 id (store_id) — bigint — 외래 키 → 가게.아이디 — NOT NULL
- 시작일 (start_date) — datetime
- 완료일 (end_date) — datetime
- 지역 (region) — enum
미션 완료 여부 (complete_mission)
- Key (id) — bigint — 기본 키 — NOT NULL
- 아이디 (user_id) — bigint — 외래 키 → 사용자.아이디 — NOT NULL
- Field (count) — int
사용자 (users)
- 아이디 (id) — bigint — 기본 키 — NOT NULL
- 이름 (name) — varchar(20)
- 성별 (gender) — enum
- 생년월일 (birth) — date
- 주소 (address) — text
- 서비스 동의 여부 (service) — enum
- 생성일 (created_at) — datetime(6)
- 수정일 (updated_at) — datetime(6)
- 상태 (status) — varchar(15)
- 최종 접속 일자 (inactive_date) — datetime
- 포인트 (point) — int
- 닉네임 (nickname) — varchar(255)
- 비밀번호 (password) — varchar(255)
- 이메일 (email) — varchar(255)
약관 동의 (agreements)
- 약관 동의 (id) — bigint — 기본 키 — NOT NULL
- 사용자 id (user_id) — bigint — 외래 키 → 사용자.아이디 — NOT NULL
- 서비스 동의 (is_service_agreed) — boolean
- 개인정보 동의 (is_personal_agreed) — bollean
- 위치정보 동의 (is_location_agreed) — boolean
- 마케팅 수진 동의 (is_alram_agreed) — boolean
- 14세 이상 (if_fourteen_agreed) — boolean
- 생성일자 (is_created) — datetime(6)
- 수정일자 (is_updated) — datetiem(6)
유저 카테고리 매핑 (mapping)
- Key (id) — bigint — 기본 키 — NOT NULL
- 아이디 (user_id) — bigint — 외래 키 → 사용자.아이디 — NOT NULL
- Key (category_id) — bigint — 외래 키 → Untitled.Key — NOT NULL