Reclo ERD
Tables (8)
carbon_savings
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → users.id — NOT NULL
- saving_date — DATE — NOT NULL
- saved_kg_co2 — DECIMAL(8, 2) — NOT NULL
- basis — VARCHAR(30) — NOT NULL
- created_at — DATETIME — NOT NULL
clothes
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → users.id — NOT NULL
- name — VARCHAR(100) — NOT NULL
- image_url — VARCHAR(1000) — NOT NULL
- category — VARCHAR(20) — NOT NULL
- color — VARCHAR(50)
- style — VARCHAR(50)
- seasons — JSON
- brand — VARCHAR(100)
- size — VARCHAR(50)
- purchased_at — DATE
- last_worn_at — DATE
- wear_count — INT — NOT NULL
- ai_tagged — BOOLEAN — NOT NULL
- created_at — DATETIME — NOT NULL
- updated_at — DATETIME — NOT NULL
clothing_ai_tags
- id — BIGINT — Primary key — NOT NULL
- clothing_id — BIGINT — Foreign key → clothes.id — NOT NULL
- detected_category — VARCHAR(20)
- detected_color — VARCHAR(50)
- detected_style — VARCHAR(50)
- detected_seasons — JSON
- confidence — DECIMAL(5, 4)
- raw_response — JSON
- created_at — DATETIME — NOT NULL
donations
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → users.id — NOT NULL
- clothing_id — BIGINT — Foreign key → clothes.id — NOT NULL
- status — VARCHAR(30) — NOT NULL
- requested_at — DATETIME — NOT NULL
outfit_items
- id — BIGINT — Primary key — NOT NULL
- outfit_id — BIGINT — Foreign key → outfits.id — NOT NULL
- clothing_id — BIGINT — Foreign key → clothes.id — NOT NULL
- slot — VARCHAR(20) — NOT NULL
- created_at — DATETIME — NOT NULL
outfits
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → users.id — NOT NULL
- source — VARCHAR(30) — NOT NULL
- recommendation_reason — VARCHAR(500)
- recommendation_score — INT
- weather_condition — VARCHAR(50)
- temperature_min — DECIMAL(4, 1)
- temperature_max — DECIMAL(4, 1)
- precipitation — DECIMAL(5, 2)
- recommendation_date — DATE
- recommendation_order — INT
- is_current — BOOLEAN — NOT NULL
- created_at — DATETIME — NOT NULL
- updated_at — DATETIME — NOT NULL
users
- id — BIGINT — Primary key — NOT NULL
- email — VARCHAR(255) — NOT NULL
- password — VARCHAR(255) — NOT NULL
- nickname — VARCHAR(50) — NOT NULL
- created_at — DATETIME — NOT NULL
- updated_at — DATETIME — NOT NULL
wear_logs
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → users.id — NOT NULL
- clothing_id — BIGINT — Foreign key → clothes.id — NOT NULL
- worn_date — DATE — NOT NULL
- source — VARCHAR(30) — NOT NULL
- created_at — DATETIME — NOT NULL