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
20004e85
Commit
20004e85
authored
Jun 08, 2021
by
Robert May
Committed by
Phil Hughes
Jun 08, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add caching around widget JSON [RUN ALL RSPEC] [RUN AS-IF-FOSS]
parent
62f03812
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
27 additions
and
18 deletions
+27
-18
app/views/projects/merge_requests/_widget.html.haml
app/views/projects/merge_requests/_widget.html.haml
+19
-18
config/feature_flags/development/cached_mr_widget.yml
config/feature_flags/development/cached_mr_widget.yml
+8
-0
No files found.
app/views/projects/merge_requests/_widget.html.haml
View file @
20004e85
-
artifacts_endpoint_placeholder
=
':pipeline_artifacts_id'
=
cache_if
(
Feature
.
enabled?
(
:cached_mr_widget
,
@merge_request
.
project
),
[
@merge_request
.
project
,
@merge_request
,
current_user
],
expires_in:
10
.
minutes
)
do
-
artifacts_endpoint_placeholder
=
':pipeline_artifacts_id'
=
javascript_tag
do
=
javascript_tag
do
:plain
:plain
window.gl = window.gl || {};
window.gl = window.gl || {};
window.gl.mrWidgetData =
#{
serialize_issuable
(
@merge_request
,
serializer:
'widget'
,
issues_links:
true
)
}
window.gl.mrWidgetData =
#{
serialize_issuable
(
@merge_request
,
serializer:
'widget'
,
issues_links:
true
)
}
window.gl.mrWidgetData.artifacts_endpoint = '
#{
downloadable_artifacts_project_pipeline_path
(
@project
,
artifacts_endpoint_placeholder
,
format: :json
)
}
';
window.gl.mrWidgetData.artifacts_endpoint = '
#{
downloadable_artifacts_project_pipeline_path
(
@project
,
artifacts_endpoint_placeholder
,
format: :json
)
}
';
window.gl.mrWidgetData.artifacts_endpoint_placeholder = '
#{
artifacts_endpoint_placeholder
}
';
window.gl.mrWidgetData.artifacts_endpoint_placeholder = '
#{
artifacts_endpoint_placeholder
}
';
window.gl.mrWidgetData.squash_before_merge_help_path = '
#{
help_page_path
(
"user/project/merge_requests/squash_and_merge"
)
}
';
window.gl.mrWidgetData.squash_before_merge_help_path = '
#{
help_page_path
(
"user/project/merge_requests/squash_and_merge"
)
}
';
window.gl.mrWidgetData.ci_troubleshooting_docs_path = '
#{
help_page_path
(
'ci/troubleshooting.md'
)
}
';
window.gl.mrWidgetData.ci_troubleshooting_docs_path = '
#{
help_page_path
(
'ci/troubleshooting.md'
)
}
';
window.gl.mrWidgetData.mr_troubleshooting_docs_path = '
#{
help_page_path
(
'user/project/merge_requests/reviews/index.md'
,
anchor:
'troubleshooting'
)
}
';
window.gl.mrWidgetData.mr_troubleshooting_docs_path = '
#{
help_page_path
(
'user/project/merge_requests/reviews/index.md'
,
anchor:
'troubleshooting'
)
}
';
window.gl.mrWidgetData.pipeline_must_succeed_docs_path = '
#{
help_page_path
(
'user/project/merge_requests/merge_when_pipeline_succeeds.md'
,
anchor:
'only-allow-merge-requests-to-be-merged-if-the-pipeline-succeeds'
)
}
';
window.gl.mrWidgetData.pipeline_must_succeed_docs_path = '
#{
help_page_path
(
'user/project/merge_requests/merge_when_pipeline_succeeds.md'
,
anchor:
'only-allow-merge-requests-to-be-merged-if-the-pipeline-succeeds'
)
}
';
window.gl.mrWidgetData.security_approvals_help_page_path = '
#{
help_page_path
(
'user/application_security/index.md'
,
anchor:
'security-approvals-in-merge-requests'
)
}
';
window.gl.mrWidgetData.security_approvals_help_page_path = '
#{
help_page_path
(
'user/application_security/index.md'
,
anchor:
'security-approvals-in-merge-requests'
)
}
';
window.gl.mrWidgetData.license_compliance_docs_path = '
#{
help_page_path
(
'user/compliance/license_compliance/index.md'
,
anchor:
'policies'
)
}
';
window.gl.mrWidgetData.license_compliance_docs_path = '
#{
help_page_path
(
'user/compliance/license_compliance/index.md'
,
anchor:
'policies'
)
}
';
window.gl.mrWidgetData.eligible_approvers_docs_path = '
#{
help_page_path
(
'user/project/merge_requests/merge_request_approvals'
,
anchor:
'eligible-approvers'
)
}
';
window.gl.mrWidgetData.eligible_approvers_docs_path = '
#{
help_page_path
(
'user/project/merge_requests/merge_request_approvals'
,
anchor:
'eligible-approvers'
)
}
';
window.gl.mrWidgetData.approvals_help_path = '
#{
help_page_path
(
"user/project/merge_requests/merge_request_approvals"
)
}
';
window.gl.mrWidgetData.approvals_help_path = '
#{
help_page_path
(
"user/project/merge_requests/merge_request_approvals"
)
}
';
window.gl.mrWidgetData.pipelines_empty_svg_path = '
#{
image_path
(
'illustrations/pipelines_empty.svg'
)
}
';
window.gl.mrWidgetData.pipelines_empty_svg_path = '
#{
image_path
(
'illustrations/pipelines_empty.svg'
)
}
';
window.gl.mrWidgetData.codequality_help_path = '
#{
help_page_path
(
"user/project/merge_requests/code_quality"
,
anchor:
"code-quality-reports"
)
}
';
window.gl.mrWidgetData.codequality_help_path = '
#{
help_page_path
(
"user/project/merge_requests/code_quality"
,
anchor:
"code-quality-reports"
)
}
';
#js-vue-mr-widget
.mr-widget
#js-vue-mr-widget
.mr-widget
config/feature_flags/development/cached_mr_widget.yml
0 → 100644
View file @
20004e85
---
name
:
cached_mr_widget
introduced_by_url
:
https://gitlab.com/gitlab-org/gitlab/-/merge_requests/61584
rollout_issue_url
:
https://gitlab.com/gitlab-org/gitlab/-/issues/330803
milestone
:
'
13.12'
type
:
development
group
:
group::code review
default_enabled
:
false
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