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
c6562608
Commit
c6562608
authored
Oct 01, 2020
by
GitLab Bot
Browse files
Options
Browse Files
Download
Plain Diff
Automatic merge of gitlab-org/gitlab master
parents
66690c55
5de212ae
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
26 additions
and
6 deletions
+26
-6
app/services/issuable/clone/attributes_rewriter.rb
app/services/issuable/clone/attributes_rewriter.rb
+1
-1
app/views/projects/ci/builds/_build.html.haml
app/views/projects/ci/builds/_build.html.haml
+5
-5
changelogs/unreleased/gitlab_buttons_ci_builds.yml
changelogs/unreleased/gitlab_buttons_ci_builds.yml
+5
-0
ee/changelogs/unreleased/215549-skip-copying-weight-events-when-promoting-issue.yml
...15549-skip-copying-weight-events-when-promoting-issue.yml
+5
-0
ee/spec/services/ee/issuable/clone/attributes_rewriter_spec.rb
...ec/services/ee/issuable/clone/attributes_rewriter_spec.rb
+10
-0
No files found.
app/services/issuable/clone/attributes_rewriter.rb
View file @
c6562608
...
...
@@ -56,7 +56,7 @@ module Issuable
end
def
copy_resource_weight_events
return
unless
original_entity
.
respond_to?
(
:resource_weight_events
)
return
unless
both_
respond_to?
(
:resource_weight_events
)
copy_events
(
ResourceWeightEvent
.
table_name
,
original_entity
.
resource_weight_events
)
do
|
event
|
event
.
attributes
...
...
app/views/projects/ci/builds/_build.html.haml
View file @
c6562608
...
...
@@ -101,11 +101,11 @@
=
sprite_icon
(
'download'
)
-
if
can?
(
current_user
,
:update_build
,
job
)
-
if
job
.
active?
=
link_to
cancel_project_job_path
(
job
.
project
,
job
,
continue:
{
to:
request
.
fullpath
}),
method: :post
,
title:
_
(
'Cancel'
),
class:
'btn btn-build'
do
=
link_to
cancel_project_job_path
(
job
.
project
,
job
,
continue:
{
to:
request
.
fullpath
}),
method: :post
,
title:
_
(
'Cancel'
),
class:
'btn
gl-button
btn-build'
do
=
sprite_icon
(
'close'
)
-
elsif
job
.
scheduled?
.btn-group
.btn.btn-default
{
disabled:
true
}
.btn.
gl-button.
btn-default
{
disabled:
true
}
=
sprite_icon
(
'planning'
)
%time
.js-remaining-time
{
datetime:
job
.
scheduled_at
.
utc
.
iso8601
}
=
duration_in_numbers
(
job
.
execute_in
)
...
...
@@ -113,17 +113,17 @@
=
link_to
play_project_job_path
(
job
.
project
,
job
,
return_to:
request
.
original_url
),
method: :post
,
title:
s_
(
'DelayedJobs|Start now'
),
class:
'btn btn-default btn-build has-tooltip'
,
class:
'btn
gl-button
btn-default btn-build has-tooltip'
,
data:
{
confirm:
confirmation_message
}
do
=
sprite_icon
(
'play'
)
=
link_to
unschedule_project_job_path
(
job
.
project
,
job
,
return_to:
request
.
original_url
),
method: :post
,
title:
s_
(
'DelayedJobs|Unschedule'
),
class:
'btn btn-default btn-build has-tooltip'
do
class:
'btn
gl-button
btn-default btn-build has-tooltip'
do
=
sprite_icon
(
'time-out'
)
-
elsif
allow_retry
-
if
job
.
playable?
&&
!
admin
&&
can?
(
current_user
,
:update_build
,
job
)
=
link_to
play_project_job_path
(
job
.
project
,
job
,
return_to:
request
.
original_url
),
method: :post
,
title:
_
(
'Play'
),
class:
'btn btn-build'
do
=
link_to
play_project_job_path
(
job
.
project
,
job
,
return_to:
request
.
original_url
),
method: :post
,
title:
_
(
'Play'
),
class:
'btn
gl-button
btn-build'
do
=
custom_icon
(
'icon_play'
)
-
elsif
job
.
retryable?
=
link_to
retry_project_job_path
(
job
.
project
,
job
,
return_to:
request
.
original_url
),
method: :post
,
title:
_
(
'Retry'
),
class:
'btn btn-build gl-button btn-icon btn-default'
do
...
...
changelogs/unreleased/gitlab_buttons_ci_builds.yml
0 → 100644
View file @
c6562608
---
title
:
Apply GitLab UI button styles to HAML buttons app/views/projects/ci/builds
merge_request
:
43728
author
:
Andrei Kyrnich @kyrnich
type
:
other
ee/changelogs/unreleased/215549-skip-copying-weight-events-when-promoting-issue.yml
0 → 100644
View file @
c6562608
---
title
:
Do not try to copy issue weight events when promoting an issue to epic
merge_request
:
43891
author
:
type
:
fixed
ee/spec/services/ee/issuable/clone/attributes_rewriter_spec.rb
View file @
c6562608
...
...
@@ -39,6 +39,16 @@ RSpec.describe Issuable::Clone::AttributesRewriter do
subject
.
execute
end
end
context
'when issue has weight events'
do
it
'ignores copying weight events'
do
create_list
(
:resource_weight_event
,
2
,
issue:
original_issue
)
expect
(
subject
).
not_to
receive
(
:copy_events
).
with
(
ResourceWeightEvent
.
table_name
,
any_args
)
expect
{
subject
.
execute
}.
not_to
change
{
ResourceWeightEvent
.
count
}
end
end
end
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