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
84f4165d
Commit
84f4165d
authored
Oct 30, 2019
by
leiminghuan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
change datatype of merge_requests.squash_commit_sha to binary
parent
c08c6e1c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
2 deletions
+5
-2
app/models/merge_request.rb
app/models/merge_request.rb
+3
-0
db/migrate/20191013100213_add_squash_commit_sha_to_merge_requests.rb
...20191013100213_add_squash_commit_sha_to_merge_requests.rb
+1
-1
db/schema.rb
db/schema.rb
+1
-1
No files found.
app/models/merge_request.rb
View file @
84f4165d
...
...
@@ -16,6 +16,9 @@ class MergeRequest < ApplicationRecord
include
ReactiveCaching
include
FromUnion
include
DeprecatedAssignee
include
ShaAttribute
sha_attribute
:squash_commit_sha
self
.
reactive_cache_key
=
->
(
model
)
{
[
model
.
project
.
id
,
model
.
iid
]
}
self
.
reactive_cache_refresh_interval
=
10
.
minutes
...
...
db/migrate/20191013100213_add_squash_commit_sha_to_merge_requests.rb
View file @
84f4165d
...
...
@@ -5,6 +5,6 @@ class AddSquashCommitShaToMergeRequests < ActiveRecord::Migration[5.2]
DOWNTIME
=
false
def
change
add_column
:merge_requests
,
:squash_commit_sha
,
:
varchar
add_column
:merge_requests
,
:squash_commit_sha
,
:
binary
end
end
db/schema.rb
View file @
84f4165d
...
...
@@ -2258,7 +2258,7 @@ ActiveRecord::Schema.define(version: 2019_10_16_072826) do
t
.
boolean
"allow_maintainer_to_push"
t
.
integer
"state_id"
,
limit:
2
t
.
string
"rebase_jid"
t
.
string
"squash_commit_sha"
t
.
binary
"squash_commit_sha"
t
.
index
[
"assignee_id"
],
name:
"index_merge_requests_on_assignee_id"
t
.
index
[
"author_id"
],
name:
"index_merge_requests_on_author_id"
t
.
index
[
"created_at"
],
name:
"index_merge_requests_on_created_at"
...
...
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