Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Léo-Paul Géneau
gitlab-ce
Commits
492eaece
Commit
492eaece
authored
Sep 07, 2017
by
Zeger-Jan van de Weg
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix ordering of columns on new table
parent
cd8ea329
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
11 deletions
+6
-11
db/migrate/20170828093725_create_project_auto_dev_ops.rb
db/migrate/20170828093725_create_project_auto_dev_ops.rb
+3
-8
db/schema.rb
db/schema.rb
+3
-3
No files found.
db/migrate/20170828093725_create_project_auto_dev_ops.rb
View file @
492eaece
...
@@ -3,19 +3,14 @@ class CreateProjectAutoDevOps < ActiveRecord::Migration
...
@@ -3,19 +3,14 @@ class CreateProjectAutoDevOps < ActiveRecord::Migration
DOWNTIME
=
false
DOWNTIME
=
false
disable_ddl_transaction!
def
up
def
up
create_table
:project_auto_devops
do
|
t
|
create_table
:project_auto_devops
do
|
t
|
t
.
belongs_to
:project
,
null:
false
,
index:
{
unique:
true
}
t
.
belongs_to
:project
,
null:
false
,
index:
{
unique:
true
},
foreign_key:
{
on_delete: :cascade
}
t
.
datetime_with_timezone
:created_at
,
null:
false
t
.
datetime_with_timezone
:updated_at
,
null:
false
t
.
boolean
:enabled
,
default:
nil
,
null:
true
t
.
boolean
:enabled
,
default:
nil
,
null:
true
t
.
string
:domain
t
.
string
:domain
end
end
add_timestamps_with_timezone
(
:project_auto_devops
,
null:
false
)
# No need to check for violations as its a new table
add_concurrent_foreign_key
(
:project_auto_devops
,
:projects
,
column: :project_id
)
end
end
def
down
def
down
...
...
db/schema.rb
View file @
492eaece
...
@@ -1130,10 +1130,10 @@ ActiveRecord::Schema.define(version: 20170905112933) do
...
@@ -1130,10 +1130,10 @@ ActiveRecord::Schema.define(version: 20170905112933) do
create_table
"project_auto_devops"
,
force: :cascade
do
|
t
|
create_table
"project_auto_devops"
,
force: :cascade
do
|
t
|
t
.
integer
"project_id"
,
null:
false
t
.
integer
"project_id"
,
null:
false
t
.
boolean
"enabled"
t
.
string
"domain"
t
.
datetime_with_timezone
"created_at"
,
null:
false
t
.
datetime_with_timezone
"created_at"
,
null:
false
t
.
datetime_with_timezone
"updated_at"
,
null:
false
t
.
datetime_with_timezone
"updated_at"
,
null:
false
t
.
boolean
"enabled"
t
.
string
"domain"
end
end
add_index
"project_auto_devops"
,
[
"project_id"
],
name:
"index_project_auto_devops_on_project_id"
,
unique:
true
,
using: :btree
add_index
"project_auto_devops"
,
[
"project_id"
],
name:
"index_project_auto_devops_on_project_id"
,
unique:
true
,
using: :btree
...
@@ -1755,7 +1755,7 @@ ActiveRecord::Schema.define(version: 20170905112933) do
...
@@ -1755,7 +1755,7 @@ ActiveRecord::Schema.define(version: 20170905112933) do
add_foreign_key
"personal_access_tokens"
,
"users"
add_foreign_key
"personal_access_tokens"
,
"users"
add_foreign_key
"project_authorizations"
,
"projects"
,
on_delete: :cascade
add_foreign_key
"project_authorizations"
,
"projects"
,
on_delete: :cascade
add_foreign_key
"project_authorizations"
,
"users"
,
on_delete: :cascade
add_foreign_key
"project_authorizations"
,
"users"
,
on_delete: :cascade
add_foreign_key
"project_auto_devops"
,
"projects"
,
name:
"fk_45436b12b2"
,
on_delete: :cascade
add_foreign_key
"project_auto_devops"
,
"projects"
,
on_delete: :cascade
add_foreign_key
"project_features"
,
"projects"
,
name:
"fk_18513d9b92"
,
on_delete: :cascade
add_foreign_key
"project_features"
,
"projects"
,
name:
"fk_18513d9b92"
,
on_delete: :cascade
add_foreign_key
"project_group_links"
,
"projects"
,
name:
"fk_daa8cee94c"
,
on_delete: :cascade
add_foreign_key
"project_group_links"
,
"projects"
,
name:
"fk_daa8cee94c"
,
on_delete: :cascade
add_foreign_key
"project_import_data"
,
"projects"
,
name:
"fk_ffb9ee3a10"
,
on_delete: :cascade
add_foreign_key
"project_import_data"
,
"projects"
,
name:
"fk_ffb9ee3a10"
,
on_delete: :cascade
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment