Commit 5f0aea70 authored by Phil Hughes's avatar Phil Hughes

Fixed incorrect class names used in merge request widget

parent 182d1525
...@@ -143,7 +143,9 @@ ...@@ -143,7 +143,9 @@
MergeRequestWidget.prototype.getMergeStatus = function() { MergeRequestWidget.prototype.getMergeStatus = function() {
return $.get(this.opts.merge_check_url, function(data) { return $.get(this.opts.merge_check_url, function(data) {
return $('.mr-state-widget').replaceWith(data); var $html = $(data);
$('.mr-widget-body').replaceWith($html.find('.mr-widget-body'));
$('.mr-widget-footer:not(.mr-approvals-footer)').replaceWith($html.find('.mr-widget-footer:not(.mr-approvals-footer)'));
}); });
}; };
......
...@@ -76,7 +76,7 @@ ...@@ -76,7 +76,7 @@
gl.ApprovalsStore.initStoreOnce(); gl.ApprovalsStore.initStoreOnce();
}, },
template: ` template: `
<div class='approvals-body mr-widget-footer'> <div class='approvals-body mr-widget-footer mr-approvals-footer'>
<h4> Requires {{ approvalsRequiredStringified }} <h4> Requires {{ approvalsRequiredStringified }}
<span v-if='showSuggestedApprovers'> (from {{ approverNamesStringified }}) </span> <span v-if='showSuggestedApprovers'> (from {{ approverNamesStringified }}) </span>
</h4> </h4>
......
...@@ -57,7 +57,7 @@ ...@@ -57,7 +57,7 @@
gl.ApprovalsStore.initStoreOnce(); gl.ApprovalsStore.initStoreOnce();
}, },
template: ` template: `
<div class='mr-widget-footer approved-by-users approvals-footer clearfix'> <div class='mr-widget-footer approved-by-users approvals-footer clearfix mr-approvals-footer'>
<span class='approvers-prefix'> Approved by </span> <span class='approvers-prefix'> Approved by </span>
<span v-for='approver in approvedBy'> <span v-for='approver in approvedBy'>
<link-to-member-avatar <link-to-member-avatar
...@@ -90,4 +90,3 @@ ...@@ -90,4 +90,3 @@
`, `,
}); });
})(); })();
...@@ -56,11 +56,9 @@ ...@@ -56,11 +56,9 @@
#{mr_issues_mentioned_but_not_closing.size > 1 ? 'are' : 'is'} mentioned but will not be closed. #{mr_issues_mentioned_but_not_closing.size > 1 ? 'are' : 'is'} mentioned but will not be closed.
- if @merge_request.requires_approve? - if @merge_request.requires_approve?
.mr-widget-footer{ 'v-show' => '!showApprovals' } .mr-widget-footer.mr-approvals-footer{ 'v-show' => '!showApprovals' }
= icon("spinner spin") = icon("spinner spin")
Checking approval status for this merge request. Checking approval status for this merge request.
.approvals-components{ 'v-show' => 'showApprovals' } .approvals-components{ 'v-show' => 'showApprovals' }
= render 'projects/merge_requests/widget/open/approvals_body' = render 'projects/merge_requests/widget/open/approvals_body'
= render 'projects/merge_requests/widget/open/approvals_footer' = render 'projects/merge_requests/widget/open/approvals_footer'
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment