1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-11-29 10:24:20 +01:00
fab-manager/db/migrate/20230113145632_add_not_null_to_slots_reservation.rb

12 lines
448 B
Ruby
Raw Normal View History

2023-01-12 17:48:52 +01:00
# frozen_string_literal: true
# From this migration, the slot_id and reservation_id of the SlotsReservation won't be allowed to be null,
# otherwise this could result in error
class AddNotNullToSlotsReservation < ActiveRecord::Migration[5.2]
def change
change_column_null :slots_reservations, :slot_id, false
change_column_null :slots_reservations, :reservation_id, false
change_column_null :slots, :availability_id, false
end
end