Rename image* to cover*

This commit is contained in:
Claudio Ortolina
2024-10-02 16:33:42 +01:00
parent fb978406cd
commit 1e0d5486e0
13 changed files with 86 additions and 71 deletions
@@ -0,0 +1,15 @@
defmodule MusicLibrary.Repo.Migrations.RenameImageColumnsToCover do
use Ecto.Migration
def up do
rename table(:records), :image_url, to: :cover_url
rename table(:records), :image_data, to: :cover_data
rename table(:records), :image_data_hash, to: :cover_hash
end
def down do
rename table(:records), :cover_url, to: :image_url
rename table(:records), :cover_data, to: :image_data
rename table(:records), :cover_hash, to: :image_data_hash
end
end