added a column to link to a settings version and to store the settings.json file from the device.
parent
ce7fa1a193
commit
beecb4a4f2
|
@ -1,13 +1,22 @@
|
||||||
CREATE TABLE device.device_skill (
|
CREATE TABLE device.device_skill (
|
||||||
id uuid PRIMARY KEY DEFAULT gen_random_uuid(),
|
id uuid PRIMARY KEY
|
||||||
device_id uuid NOT NULL REFERENCES device.device ON DELETE CASCADE,
|
DEFAULT gen_random_uuid(),
|
||||||
skill_id uuid NOT NULL REFERENCES skill.skill,
|
device_id uuid NOT NULL
|
||||||
install_method text NOT NULL DEFAULT 'msm',
|
REFERENCES device.device
|
||||||
install_status text NOT NULL DEFAULT 'installed',
|
ON DELETE CASCADE,
|
||||||
|
skill_id uuid NOT NULL
|
||||||
|
REFERENCES skill.skill,
|
||||||
|
install_method text NOT NULL
|
||||||
|
DEFAULT 'msm',
|
||||||
|
install_status text NOT NULL
|
||||||
|
DEFAULT 'installed',
|
||||||
install_failure_reason text,
|
install_failure_reason text,
|
||||||
install_ts timestamp,
|
install_ts TIMESTAMP,
|
||||||
update_ts timestamp,
|
update_ts TIMESTAMP,
|
||||||
beta boolean NOT NULL DEFAULT FALSE,
|
skill_setting_meta_id uuid
|
||||||
insert_ts TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
REFERENCES skill.setting_meta,
|
||||||
|
settings json,
|
||||||
|
insert_ts TIMESTAMP NOT NULL
|
||||||
|
DEFAULT CURRENT_TIMESTAMP,
|
||||||
UNIQUE (device_id, skill_id)
|
UNIQUE (device_id, skill_id)
|
||||||
);
|
);
|
||||||
|
|
Loading…
Reference in New Issue