Открыть боковую панель
nt_test121
nt_project_9da4a5yt9x4b
Коммиты
3a86a7d1
Не подтверждена
Коммит
3a86a7d1
создал
Сен 12, 2019
по автору
Andreas Brandl
Просмотр файлов
Ignore add_reference rubocop offenses for existing migrations
владелец
c5ed8c91
Изменения
4
Скрыть пробелы
Построчно
Рядом
db/migrate/20190611161641_add_target_project_id_to_merge_trains.rb
Просмотр файла @
3a86a7d1
...
...
@@ -6,9 +6,9 @@ class AddTargetProjectIdToMergeTrains < ActiveRecord::Migration[5.1]
DOWNTIME
=
false
def
change
# rubocop:
disable Rails/NotNullColumn
# rubocop:disable Rails/NotNullColumn
, Migration/AddReference
add_reference
:merge_trains
,
:target_project
,
null:
false
,
index:
true
,
foreign_key:
{
on_delete: :cascade
,
to_table: :projects
},
type: :integer
add_column
:merge_trains
,
:target_branch
,
:text
,
null:
false
# rubocop:
enable Rails/NotNullColumn
# rubocop:enable Rails/NotNullColumn
, Migration/AddReference
end
end
db/migrate/20190712040400_add_environment_id_to_clusters_kubernetes_namespaces.rb
Просмотр файла @
3a86a7d1
...
...
@@ -4,7 +4,9 @@ class AddEnvironmentIdToClustersKubernetesNamespaces < ActiveRecord::Migration[5
DOWNTIME
=
false
def
change
# rubocop:disable Migration/AddReference
add_reference
:clusters_kubernetes_namespaces
,
:environment
,
index:
true
,
type: :bigint
,
foreign_key:
{
on_delete: :nullify
}
# rubocop:enable Migration/AddReference
end
end
db/migrate/20190715042813_add_issue_id_to_versions.rb
Просмотр файла @
3a86a7d1
...
...
@@ -4,7 +4,9 @@ class AddIssueIdToVersions < ActiveRecord::Migration[5.2]
DOWNTIME
=
false
def
up
# rubocop:disable Migration/AddReference
add_reference
:design_management_versions
,
:issue
,
index:
true
,
foreign_key:
{
on_delete: :cascade
}
# rubocop:enable Migration/AddReference
end
def
down
...
...
db/migrate/20190724112147_add_column_for_self_monitoring_project_id.rb
Просмотр файла @
3a86a7d1
...
...
@@ -4,11 +4,13 @@ class AddColumnForSelfMonitoringProjectId < ActiveRecord::Migration[5.2]
DOWNTIME
=
false
def
change
# rubocop:disable Migration/AddReference
add_reference
(
:application_settings
,
:instance_administration_project
,
index:
{
name:
'index_applicationsettings_on_instance_administration_project_id'
},
foreign_key:
{
to_table: :projects
,
on_delete: :nullify
}
)
# rubocop:enable Migration/AddReference
end
end
Редактирование
Предварительный просмотр
Поддерживает Markdown
0%
Попробовать снова
или
прикрепить новый файл
.
Отмена
You are about to add
0
people
to the discussion. Proceed with caution.
Сначала завершите редактирование этого сообщения!
Отмена
Пожалуйста,
зарегистрируйтесь
или
войдите
чтобы прокомментировать