-
Notifications
You must be signed in to change notification settings - Fork 51
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add detections json api endpoint (#501)
* Add detection json api, update some deps * Allow relationship includes for detections' feed, candidate relationships. Add feed_streams to includes for feed
- Loading branch information
Showing
9 changed files
with
86 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
# TODO: Try removing this once upgrading ash > 3.0 and ash_json_api > 1 | ||
defimpl Jason.Encoder, for: Ash.ForbiddenField do | ||
def encode(_, _), do: "null" | ||
def encode!(_, _), do: "null" | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
19 changes: 19 additions & 0 deletions
19
server/priv/repo/migrations/20240613213452_install_1_extensions.exs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
defmodule Orcasite.Repo.Migrations.Install1Extensions do | ||
@moduledoc """ | ||
Installs any extensions that are mentioned in the repo's `installed_extensions/0` callback | ||
This file was autogenerated with `mix ash_postgres.generate_migrations` | ||
""" | ||
|
||
use Ecto.Migration | ||
|
||
def up do | ||
execute("CREATE EXTENSION IF NOT EXISTS \"pg_stat_statements\"") | ||
end | ||
|
||
def down do | ||
# Uncomment this if you actually want to uninstall the extensions | ||
# when this migration is rolled back: | ||
# execute("DROP EXTENSION IF EXISTS \"pg_stat_statements\"") | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,7 @@ | |
"citext", | ||
"uuid-ossp", | ||
"postgis", | ||
"ash-uuid_v1" | ||
"ash-uuid_v1", | ||
"pg_stat_statements" | ||
] | ||
} |