Skip to content
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-10939 Add Reusable Q&As to Campaign Landing Pages #1748

Merged
merged 1 commit into from
Oct 18, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 12 additions & 1 deletion src/site/layouts/campaign_landing_page.drupal.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -458,7 +458,7 @@
<p class="va-u-text-transform--uppercase vads-u-color--gray-medium vads-u-font-size--sm vads-u-margin-bottom--0">FAQ</p>
<h2 class="vads-u-margin-top--0">Frequently asked questions</h2>

<!-- Questions/Answers -->
<!-- Page-specific Questions/Answers -->
<va-accordion bordered>
{% for faqParagraph in fieldClpFaqParagraphs %}
{% if faqParagraph.entity %}
Expand All @@ -477,6 +477,17 @@
{% endif %}
{% endfor %}
</va-accordion>

<!-- Reusable QAs -->
{% for reusableQA in fieldClpReusableQA %}
{% if reusableQA.entity.entityBundle == "q_a_group" %}
{% if reusableQA.entity.fieldAccordionDisplay %}
{% include "src/site/paragraphs/q_a_group_collapsible_content.drupal.liquid" with entity = reusableQA.entity %}
{% else %}
{% include "src/site/paragraphs/q_a_group_content.drupal.liquid" with entity = reusableQA.entity %}
{% endif %}
{% endif %}
{% endfor %}
</div>
</div>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,40 @@ const nodeCampaignLandingPage = `
}
}
}
fieldClpReusableQA {
entity {
entityType
entityBundle
entityId
... on ParagraphQAGroup {
fieldSectionHeader
fieldRichWysiwyg {
processed
}
fieldAccordionDisplay
queryFieldQAs {
entities {
entityId
entityLabel
entityBundle
... on NodeQA {
fieldAnswer {
entity {
entityBundle
entityId
... on ParagraphRichTextCharLimit1000 {
fieldWysiwyg {
processed
}
}
}
}
}
}
}
}
}
}
fieldClpResources {
entity {
entityType
Expand Down
Loading