Add basic mastodon notification support.
This commit is contained in:
parent
7616b202ea
commit
61adf676d5
8 changed files with 108 additions and 6 deletions
15
priv/repo/migrations/20170911123607_create_notifications.exs
Normal file
15
priv/repo/migrations/20170911123607_create_notifications.exs
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
defmodule Pleroma.Repo.Migrations.CreateNotifications do
|
||||
use Ecto.Migration
|
||||
|
||||
def change do
|
||||
create table(:notifications) do
|
||||
add :user_id, references(:users, on_delete: :delete_all)
|
||||
add :activity_id, references(:activities, on_delete: :delete_all)
|
||||
add :seen, :boolean, default: false
|
||||
|
||||
timestamps()
|
||||
end
|
||||
|
||||
create index(:notifications, [:user_id])
|
||||
end
|
||||
end
|
||||
Loading…
Add table
Add a link
Reference in a new issue