-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: 🎸 「開票イラスト状況」の列のユニーク制限を緩和した (#115)
- Loading branch information
1 parent
e496d6d
commit 9bcb0e4
Showing
2 changed files
with
15 additions
and
2 deletions.
There are no files selected for viewing
13 changes: 13 additions & 0 deletions
13
db/migrate/20220621233304_change_unique_to_on_raw_sheet_result_illustration_totallings.rb
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,13 @@ | ||
class ChangeUniqueToOnRawSheetResultIllustrationTotallings < ActiveRecord::Migration[7.0] | ||
def up | ||
# ユニーク制約を除外するため、インデックスを外してから付け直す | ||
remove_index :on_raw_sheet_result_illustration_totallings, :character_name_for_public | ||
add_index :on_raw_sheet_result_illustration_totallings, :character_name_for_public, name: 'c_name_for_public_index' | ||
end | ||
|
||
def down | ||
# ユニーク制約を付与するため、インデックスを外してから付け直す | ||
remove_index :on_raw_sheet_result_illustration_totallings, :character_name_for_public | ||
add_index :on_raw_sheet_result_illustration_totallings, :character_name_for_public, unique: true, name: 'c_name_for_public_index' | ||
end | ||
end |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.