Files
deskhub/Plugins/plugins/schichtuebergabe/migrations/001_notizen.mysql.sql
T
2026-10-24 20:15:15 +00:00

16 lines
557 B
SQL

CREATE TABLE IF NOT EXISTS plugin_schichtuebergabe_notes (
id INT AUTO_INCREMENT PRIMARY KEY,
staff_id INT NOT NULL,
department_id INT NULL,
message TEXT NOT NULL,
is_important TINYINT(1) NOT NULL DEFAULT 0,
created_at DATETIME NOT NULL,
KEY idx_plugin_schichtuebergabe_created (created_at)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4;
CREATE TABLE IF NOT EXISTS plugin_schichtuebergabe_reads (
note_id INT NOT NULL,
staff_id INT NOT NULL,
read_at DATETIME NOT NULL,
PRIMARY KEY (note_id, staff_id)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4