mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-13 04:00:21 +00:00
Require associations of CoordinatorFee
This commit is contained in:
@@ -0,0 +1,8 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class RequireOrderCycleAndEnterpriseFeeOnCoordinatorFees < ActiveRecord::Migration[7.0]
|
||||
def change
|
||||
change_column_null :coordinator_fees, :order_cycle_id, false
|
||||
change_column_null :coordinator_fees, :enterprise_fee_id, false
|
||||
end
|
||||
end
|
||||
@@ -64,8 +64,8 @@ ActiveRecord::Schema[7.0].define(version: 2023_05_22_120633) do
|
||||
end
|
||||
|
||||
create_table "coordinator_fees", id: :serial, force: :cascade do |t|
|
||||
t.integer "order_cycle_id"
|
||||
t.integer "enterprise_fee_id"
|
||||
t.integer "order_cycle_id", null: false
|
||||
t.integer "enterprise_fee_id", null: false
|
||||
t.index ["enterprise_fee_id"], name: "index_coordinator_fees_on_enterprise_fee_id"
|
||||
t.index ["order_cycle_id"], name: "index_coordinator_fees_on_order_cycle_id"
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user