-
Notifications
You must be signed in to change notification settings - Fork 70
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
VACMS-14793: Hide Link Description Field in Footers #15069
Conversation
72bcf04
to
25ad90e
Compare
ed538d9
to
551fc24
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
0e31ab6
to
b1e100b
Compare
@dsasser The PR is failing because the new trait Here is what I was seeing in my browser locally:
It makes sense that this wouldn't have been caught during development because the new module would have been installed already as part of the process. I thought about simply adding a dependency in I propose that I move the new It would be nice if we could avoid having too many dependencies with custom modules toward each other in order to avoid circular dependencies. I know it can't be avoided and I see some like Update: Turns out that there isn't anything left in |
ca578fb
to
0b67e38
Compare
0b67e38
to
70e5bbc
Compare
Ticket created for follow up: |
70e5bbc
to
b421dea
Compare
docroot/modules/custom/va_gov_header_footer/src/Traits/MenuFormAlter.php
Outdated
Show resolved
Hide resolved
b421dea
to
909e431
Compare
docroot/modules/custom/va_gov_header_footer/src/Traits/MenuFormAlterTrait.php
Outdated
Show resolved
Hide resolved
909e431
to
b30241b
Compare
b30241b
to
eec8573
Compare
…and footer menus. Co-authored-by: Daniel Sasser <[email protected]> Co-authored-by: Christia Troyer <[email protected]>
eec8573
to
5fb8549
Compare
677c77b
to
126ec4d
Compare
126ec4d
to
3461a04
Compare
…ov_menus module is installed.
$formId = $event->getFormId(); | ||
$admin = $this->permsService->hasAdminRole(TRUE); | ||
if (in_array($formId, $this->menus) && !$admin) { | ||
$form['description']['#access'] = FALSE; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Note for future us: this line should use the new trait added in va_gov_menus, but we can't roll out a new trait in a new module while also using it elsewhere in the codebase at the same time, as we get a php error:
PHP Fatal error: Trait "Drupal\va_gov_menus\Traits\MenuFormAlterTrait" not found in /var/www/html/docroot/modules/custom/va_gov_header_footer/src/EventSubscriber/FormEventSubscriber.php on line 14
We will want to go back and leverage the trait here, as well as in va_gov_home (after moving va_gov_home's menu alter methods to the trait as well).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Description
Related to #14793
Testing done
Local functional testing
Screenshots
Hides description field:
QA steps
As any
testcontentadmin
with thecontent_admin
roll, go toadmin/structure/menu/manage/footer-bottom-rail
and click to edit any link.Go to
admin/structure/menu/manage/va-gov-footer
and click to edit any link.Definition of Done
Select Team for PR review
CMS Team
Public websites
Facilities
User support
Accelerated Publishing
Is this PR blocked by another PR?
DO NOT MERGE
Does this PR need review from a Product Owner
Needs PO review
CMS user-facing announcement
Is an announcement needed to let editors know of this change?