12 Added notes and colours to customers

This commit is contained in:
2025-07-23 15:35:19 +02:00
parent 84d43f0dac
commit 541b181c87
17 changed files with 362 additions and 20 deletions

View File

@@ -0,0 +1,5 @@
class AddColorToCustomers < ActiveRecord::Migration[7.1]
def change
add_column :customers, :color, :string
end
end

View File

@@ -0,0 +1,9 @@
class UpdateExistingCustomersColor < ActiveRecord::Migration[7.1]
def up
Customer.where(color: nil).update_all(color: 'green')
end
def down
# No rollback needed - we don't want to set colors back to nil
end
end