PJT-02
Tables (8)
ai_suggestions
- suggestion_id — INT
- event_id — INT — Foreign key → events.event_id — NOT NULL
- suggested_threshold — FLOAT — NOT NULL
- reason — TEXT
- status — VARCHAR(20)
- created_at — DATETIME
events
- event_id — INT
- user_id — INT — Foreign key → users.user_id — NOT NULL
- room_id — INT — Foreign key → rooms.room_id — NOT NULL
- condition_type — VARCHAR(50) — NOT NULL
- condition_operator — VARCHAR(10) — NOT NULL
- threshold_value — FLOAT — NOT NULL
- action_module_type — VARCHAR(50) — NOT NULL
- is_active — BOOLEAN
modules
- module_id — INT
- type — VARCHAR(50) — NOT NULL
- status — VARCHAR(50) — NOT NULL
robots
- robot_id — INT
- user_id — INT — Foreign key → users.user_id — NOT NULL
- status — VARCHAR(50) — NOT NULL
- battery_level — FLOAT — NOT NULL
- current_room_id — INT — Foreign key → rooms.room_id
- current_module_id — INT — Foreign key → modules.module_id
room_conditions
- condition_id — INT
- room_id — INT — Foreign key → rooms.room_id — NOT NULL
- temperature — FLOAT — NOT NULL
- humidity — FLOAT — NOT NULL
- fine_dust — FLOAT — NOT NULL
- updated_at — DATETIME
rooms
- room_id — INT
- user_id — INT — Foreign key → users.user_id — NOT NULL
- name — VARCHAR(50) — NOT NULL
- map_data — JSON
schedules
- schedule_id — INT
- user_id — INT — Foreign key → users.user_id — NOT NULL
- room_id — INT — Foreign key → rooms.room_id — NOT NULL
- action_module_type — VARCHAR(50) — NOT NULL
- start_time — TIME — NOT NULL
- duration_minutes — INT — NOT NULL
- is_active — BOOLEAN
users
- user_id — INT
- email — VARCHAR(100) — NOT NULL
- password_hash — VARCHAR(255) — NOT NULL
- name — VARCHAR(50) — NOT NULL
- created_at — DATETIME