mirror of
https://github.com/idanoo/autobrr
synced 2025-07-23 00:39:13 +00:00
fix(filters): could not delete with postgres (#1021)
* fix(filters): could not delete with postgres * fix(migrations): add actions constraint to base schema
This commit is contained in:
parent
1637c6209d
commit
56d3603505
1 changed files with 8 additions and 1 deletions
|
@ -283,7 +283,7 @@ CREATE TABLE release_action_status
|
|||
raw TEXT,
|
||||
log TEXT,
|
||||
release_id INTEGER NOT NULL,
|
||||
FOREIGN KEY (action_id) REFERENCES "action"(id),
|
||||
FOREIGN KEY (action_id) REFERENCES "action"(id) ON DELETE SET NULL,
|
||||
FOREIGN KEY (release_id) REFERENCES "release"(id) ON DELETE CASCADE,
|
||||
FOREIGN KEY (filter_id) REFERENCES "filter"(id) ON DELETE SET NULL
|
||||
);
|
||||
|
@ -706,4 +706,11 @@ ADD COLUMN use_bouncer BOOLEAN DEFAULT FALSE;
|
|||
|
||||
ALTER TABLE irc_network
|
||||
ADD COLUMN bouncer_addr TEXT;`,
|
||||
`ALTER TABLE release_action_status
|
||||
DROP CONSTRAINT release_action_status_action_id_fkey;
|
||||
|
||||
ALTER TABLE release_action_status
|
||||
ADD FOREIGN KEY (action_id) REFERENCES action
|
||||
ON DELETE SET NULL;
|
||||
`,
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue