-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
4 changed files
with
160 additions
and
1 deletion.
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
21 changes: 21 additions & 0 deletions
21
server/priv/repo/migrations/20240327003711_allow_username_nil.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,21 @@ | ||
defmodule Orcasite.Repo.Migrations.AllowUsernameNil do | ||
@moduledoc """ | ||
Updates resources based on their most recent snapshots. | ||
This file was autogenerated with `mix ash_postgres.generate_migrations` | ||
""" | ||
|
||
use Ecto.Migration | ||
|
||
def up do | ||
alter table(:users) do | ||
modify :username, :text, null: true | ||
end | ||
end | ||
|
||
def down do | ||
alter table(:users) do | ||
modify :username, :text, null: false | ||
end | ||
end | ||
end |
File renamed without changes.
138 changes: 138 additions & 0 deletions
138
server/priv/resource_snapshots/repo/users/20240327003711.json
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,138 @@ | ||
{ | ||
"attributes": [ | ||
{ | ||
"default": "nil", | ||
"size": null, | ||
"type": "uuid", | ||
"source": "id", | ||
"references": null, | ||
"allow_nil?": false, | ||
"primary_key?": true, | ||
"generated?": false | ||
}, | ||
{ | ||
"default": "nil", | ||
"size": null, | ||
"type": "citext", | ||
"source": "email", | ||
"references": null, | ||
"allow_nil?": false, | ||
"primary_key?": false, | ||
"generated?": false | ||
}, | ||
{ | ||
"default": "nil", | ||
"size": null, | ||
"type": "text", | ||
"source": "hashed_password", | ||
"references": null, | ||
"allow_nil?": false, | ||
"primary_key?": false, | ||
"generated?": false | ||
}, | ||
{ | ||
"default": "nil", | ||
"size": null, | ||
"type": "text", | ||
"source": "first_name", | ||
"references": null, | ||
"allow_nil?": true, | ||
"primary_key?": false, | ||
"generated?": false | ||
}, | ||
{ | ||
"default": "nil", | ||
"size": null, | ||
"type": "text", | ||
"source": "last_name", | ||
"references": null, | ||
"allow_nil?": true, | ||
"primary_key?": false, | ||
"generated?": false | ||
}, | ||
{ | ||
"default": "false", | ||
"size": null, | ||
"type": "boolean", | ||
"source": "admin", | ||
"references": null, | ||
"allow_nil?": false, | ||
"primary_key?": false, | ||
"generated?": false | ||
}, | ||
{ | ||
"default": "false", | ||
"size": null, | ||
"type": "boolean", | ||
"source": "moderator", | ||
"references": null, | ||
"allow_nil?": false, | ||
"primary_key?": false, | ||
"generated?": false | ||
}, | ||
{ | ||
"default": "nil", | ||
"size": null, | ||
"type": "text", | ||
"source": "username", | ||
"references": null, | ||
"allow_nil?": true, | ||
"primary_key?": false, | ||
"generated?": false | ||
}, | ||
{ | ||
"default": "fragment(\"now()\")", | ||
"size": null, | ||
"type": "utc_datetime_usec", | ||
"source": "inserted_at", | ||
"references": null, | ||
"allow_nil?": false, | ||
"primary_key?": false, | ||
"generated?": false | ||
}, | ||
{ | ||
"default": "fragment(\"now()\")", | ||
"size": null, | ||
"type": "utc_datetime_usec", | ||
"source": "updated_at", | ||
"references": null, | ||
"allow_nil?": false, | ||
"primary_key?": false, | ||
"generated?": false | ||
} | ||
], | ||
"table": "users", | ||
"hash": "91403CD4D2917E7800C44400B4C877BF297E35698C43621B11C9011D076A98CE", | ||
"repo": "Elixir.Orcasite.Repo", | ||
"identities": [ | ||
{ | ||
"name": "unique_email", | ||
"keys": [ | ||
"email" | ||
], | ||
"base_filter": null, | ||
"all_tenants?": false, | ||
"index_name": "users_unique_email_index" | ||
}, | ||
{ | ||
"name": "unique_username", | ||
"keys": [ | ||
"username" | ||
], | ||
"base_filter": null, | ||
"all_tenants?": false, | ||
"index_name": "users_unique_username_index" | ||
} | ||
], | ||
"schema": null, | ||
"check_constraints": [], | ||
"custom_indexes": [], | ||
"multitenancy": { | ||
"global": null, | ||
"attribute": null, | ||
"strategy": null | ||
}, | ||
"base_filter": null, | ||
"custom_statements": [], | ||
"has_create_action": true | ||
} |