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
1
Merge Requests
1
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
nexedi
gitlab-ce
Commits
85cdde8d
Commit
85cdde8d
authored
Jun 09, 2017
by
Felipe Artur
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Migration - Remove position field from issues and merge requests
parent
2e3f0b08
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
15 additions
and
3 deletions
+15
-3
app/models/issue.rb
app/models/issue.rb
+3
-0
app/models/merge_request.rb
app/models/merge_request.rb
+3
-0
db/post_migrate/20170609183112_remove_position_from_issuables.rb
..._migrate/20170609183112_remove_position_from_issuables.rb
+8
-0
db/schema.rb
db/schema.rb
+1
-3
No files found.
app/models/issue.rb
View file @
85cdde8d
...
...
@@ -9,6 +9,9 @@ class Issue < ActiveRecord::Base
include
Spammable
include
FasterCacheKeys
include
RelativePositioning
include
IgnorableColumn
ignore_column
:position
DueDateStruct
=
Struct
.
new
(
:title
,
:name
).
freeze
NoDueDate
=
DueDateStruct
.
new
(
'No Due Date'
,
'0'
).
freeze
...
...
app/models/merge_request.rb
View file @
85cdde8d
...
...
@@ -4,6 +4,9 @@ class MergeRequest < ActiveRecord::Base
include
Noteable
include
Referable
include
Sortable
include
IgnorableColumn
ignore_column
:position
belongs_to
:target_project
,
class_name:
"Project"
belongs_to
:source_project
,
class_name:
"Project"
...
...
db/post_migrate/20170609183112_remove_position_from_issuables.rb
0 → 100644
View file @
85cdde8d
class
RemovePositionFromIssuables
<
ActiveRecord
::
Migration
DOWNTIME
=
false
def
change
remove_column
:issues
,
:position
,
:integer
remove_column
:merge_requests
,
:position
,
:integer
end
end
db/schema.rb
View file @
85cdde8d
...
...
@@ -11,7 +11,7 @@
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord
::
Schema
.
define
(
version:
2017060
7121233
)
do
ActiveRecord
::
Schema
.
define
(
version:
2017060
9183112
)
do
# These are extensions that must be enabled in order to support this database
enable_extension
"plpgsql"
...
...
@@ -547,7 +547,6 @@ ActiveRecord::Schema.define(version: 20170607121233) do
t
.
integer
"project_id"
t
.
datetime
"created_at"
t
.
datetime
"updated_at"
t
.
integer
"position"
,
default:
0
t
.
string
"branch_name"
t
.
text
"description"
t
.
integer
"milestone_id"
...
...
@@ -738,7 +737,6 @@ ActiveRecord::Schema.define(version: 20170607121233) do
t
.
integer
"target_project_id"
,
null:
false
t
.
integer
"iid"
t
.
text
"description"
t
.
integer
"position"
,
default:
0
t
.
datetime
"locked_at"
t
.
integer
"updated_by_id"
t
.
text
"merge_error"
...
...
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