Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
digit-joinup-reference
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Code review analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
ec-europa
digit-joinup-reference
Commits
bcfcca88
Commit
bcfcca88
authored
4 months ago
by
Claudiu Cristea
Browse files
Options
Downloads
Patches
Plain Diff
ISAICP-9282: Don't show reports on collection overview page.
parent
79892bdc
No related branches found
Branches containing commit
No related tags found
Tags containing commit
2 merge requests
!205
Update ephemeral with develop
,
!204
Release 2.1.0
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
tests/features/joinup_assessment/assessment.feature
+4
-0
4 additions, 0 deletions
tests/features/joinup_assessment/assessment.feature
web/modules/custom/joinup_assessment/joinup_assessment.deploy.php
+17
-0
17 additions, 0 deletions
...les/custom/joinup_assessment/joinup_assessment.deploy.php
with
21 additions
and
0 deletions
tests/features/joinup_assessment/assessment.feature
+
4
−
0
View file @
bcfcca88
...
@@ -119,6 +119,10 @@ Feature: Assessments
...
@@ -119,6 +119,10 @@ Feature: Assessments
When
I visit
"/collection/assessments/manage-content"
When
I visit
"/collection/assessments/manage-content"
Then
I should not see
"Assessment report"
Then
I should not see
"Assessment report"
# Make sure assessment reports are not leaking in collection overview page.
When
I visit
"/collection/assessments"
Then
I should not see
"Assessment report #"
Given
I mark all emails as read
Given
I mark all emails as read
And
I am logged in as Regular
And
I am logged in as Regular
# After approval, the submission cannot be edite anymore.
# After approval, the submission cannot be edite anymore.
...
...
This diff is collapsed.
Click to expand it.
web/modules/custom/joinup_assessment/joinup_assessment.deploy.php
+
17
−
0
View file @
bcfcca88
...
@@ -7,6 +7,7 @@
...
@@ -7,6 +7,7 @@
declare
(
strict_types
=
1
);
declare
(
strict_types
=
1
);
use
Drupal\collection\Entity\CollectionInterface
;
use
Drupal\custom_page
\Entity\CustomPageInterface
;
use
Drupal\custom_page
\Entity\CustomPageInterface
;
use
Drupal\joinup_assessment
\AssessmentInterface
;
use
Drupal\joinup_assessment
\AssessmentInterface
;
...
@@ -64,3 +65,19 @@ function joinup_assessment_deploy_200100(): void {
...
@@ -64,3 +65,19 @@ function joinup_assessment_deploy_200100(): void {
->
set
(
'field_paragraphs_body'
,
[
$layout
,
$block
])
->
set
(
'field_paragraphs_body'
,
[
$layout
,
$block
])
->
save
();
->
save
();
}
}
/**
* Update 'Assessments' collection content listing.
*/
function
joinup_assessment_deploy_200101
():
void
{
$collection
=
\Drupal
::
getContainer
()
->
get
(
'entity.repository'
)
->
loadEntityByUuid
(
'node'
,
AssessmentInterface
::
GROUP_UUID
);
if
(
!
$collection
instanceof
CollectionInterface
)
{
throw
new
\RuntimeException
(
"Can't load a collection with UUID '"
.
AssessmentInterface
::
GROUP_UUID
.
"'"
);
}
$listing
=
$collection
->
get
(
'listing_content'
)
->
getValue
();
$listing
[
0
][
'value'
][
'query_presets'
]
=
'entity_bundle|assessment_report|<>'
;
$collection
->
set
(
'listing_content'
,
$listing
);
$collection
->
skip_notification
=
TRUE
;
$collection
->
save
();
}
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment