You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
21 lines
635 B
21 lines
635 B
-- name: ListScripts :many
|
|
SELECT * FROM script;
|
|
|
|
-- name: SaveScript :exec
|
|
REPLACE INTO script (name, data) VALUES (?, ?);
|
|
|
|
-- name: ListScriptVariables :many
|
|
SELECT * FROM script_variable;
|
|
|
|
-- name: UpdateScriptVariables :exec
|
|
REPLACE INTO script_variable (scope, name, value) VALUES (?, ?, ?);
|
|
|
|
-- name: ListScriptTriggers :many
|
|
SELECT * FROM script_trigger;
|
|
|
|
-- name: ReplaceScriptTrigger :exec
|
|
REPLACE INTO script_trigger (id, name, event, device_match, parameter, script_target, script_name, script_pre, script_post)
|
|
VALUES (?, ?, ?, ?, ?, ?, ?, ?, ?);
|
|
|
|
-- name: DeleteScriptTrigger :exec
|
|
DELETE FROM script_trigger WHERE id = ?;
|