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
10c96cfd
Commit
10c96cfd
authored
Aug 02, 2021
by
Mario Celi
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove ignore_column :remove_on_close from Label model
parent
6a1d05d4
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
6 deletions
+1
-6
app/models/label.rb
app/models/label.rb
+0
-4
app/models/project.rb
app/models/project.rb
+1
-2
No files found.
app/models/label.rb
View file @
10c96cfd
...
...
@@ -9,10 +9,6 @@ class Label < ApplicationRecord
include
Sortable
include
FromUnion
include
Presentable
include
IgnorableColumns
# TODO: Project#create_labels can remove column exception when this column is dropped from all envs
ignore_column
:remove_on_close
,
remove_with:
'14.1'
,
remove_after:
'2021-06-22'
cache_markdown_field
:description
,
pipeline: :single_line
...
...
app/models/project.rb
View file @
10c96cfd
...
...
@@ -1426,8 +1426,7 @@ class Project < ApplicationRecord
# rubocop: disable CodeReuse/ServiceClass
def
create_labels
Label
.
templates
.
each
do
|
label
|
# TODO: remove_on_close exception can be removed after the column is dropped from all envs
params
=
label
.
attributes
.
except
(
'id'
,
'template'
,
'created_at'
,
'updated_at'
,
'type'
,
'remove_on_close'
)
params
=
label
.
attributes
.
except
(
'id'
,
'template'
,
'created_at'
,
'updated_at'
,
'type'
)
Labels
::
FindOrCreateService
.
new
(
nil
,
self
,
params
).
execute
(
skip_authorization:
true
)
end
end
...
...
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