From a7ad54de448f7d07c08c3926a31dd13fbce6da92 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Tue, 1 Aug 2023 22:18:55 +0400 Subject: [PATCH 01/32] Initial changes with section style --- ...ntity_form_display.node.action.default.yml | 4 +- ...ity_form_display.node.advisory.default.yml | 4 +- ...entity_form_display.node.alert.default.yml | 4 +- ...ntity_form_display.node.binder.default.yml | 4 +- ..._display.node.campaign_landing.default.yml | 4 +- ...splay.node.contact_information.default.yml | 4 +- ...form_display.node.curated_list.default.yml | 4 +- ...ity_form_display.node.decision.default.yml | 4 +- ...orm_display.node.decision_tree.default.yml | 4 +- ...play.node.decision_tree_branch.default.yml | 4 +- ....node.decision_tree_conclusion.default.yml | 4 +- ...entity_form_display.node.event.default.yml | 4 +- ...m_display.node.executive_order.default.yml | 4 +- ...ay.node.external_data_resource.default.yml | 4 +- ...e.external_data_resource.inline_entity.yml | 4 +- ...e.entity_form_display.node.fee.default.yml | 4 +- ...ty_form_display.node.fee.inline_entity.yml | 4 +- ...ty_form_display.node.form_page.default.yml | 4 +- ...y_form_display.node.guide_page.default.yml | 4 +- ..._form_display.node.how_to_page.default.yml | 4 +- ...form_display.node.info_details.default.yml | 4 +- ...ity_form_display.node.location.default.yml | 4 +- ..._display.node.location_details.default.yml | 4 +- ....entity_form_display.node.news.default.yml | 4 +- ...ity_form_display.node.org_page.default.yml | 4 +- ....entity_form_display.node.page.default.yml | 4 +- ...ntity_form_display.node.person.default.yml | 4 +- ...y_form_display.node.regulation.default.yml | 4 +- ...entity_form_display.node.rules.default.yml | 4 +- ...m_display.node.service_details.default.yml | 4 +- ...form_display.node.service_page.default.yml | 4 +- ...rm_display.node.sitewide_alert.default.yml | 4 +- ...rm_display.node.stacked_layout.default.yml | 4 +- ...y_form_display.node.topic_page.default.yml | 4 +- ...aragraph.org_section_long_form.default.yml | 11 +- ...aragraph.org_section_long_form.default.yml | 9 ++ ...g_form.field_section_long_form_content.yml | 23 +++- ..._section_long_form.field_section_style.yml | 23 ++++ .../config/views.view.change_collections.yml | 6 +- .../config/views.view.content_performance.yml | 94 ++++++++-------- .../themes/custom/mass_theme/mass_theme.theme | 3 + ...--org-section-long-form--default.html.twig | 101 +++++++++++------- 42 files changed, 247 insertions(+), 159 deletions(-) create mode 100644 conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_style.yml diff --git a/conf/drupal/config/core.entity_form_display.node.action.default.yml b/conf/drupal/config/core.entity_form_display.node.action.default.yml index ff83e436cc..5437b3206b 100644 --- a/conf/drupal/config/core.entity_form_display.node.action.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.action.default.yml @@ -347,8 +347,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 1 diff --git a/conf/drupal/config/core.entity_form_display.node.advisory.default.yml b/conf/drupal/config/core.entity_form_display.node.advisory.default.yml index eff3369376..bc179ad430 100644 --- a/conf/drupal/config/core.entity_form_display.node.advisory.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.advisory.default.yml @@ -357,8 +357,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 11 diff --git a/conf/drupal/config/core.entity_form_display.node.alert.default.yml b/conf/drupal/config/core.entity_form_display.node.alert.default.yml index 0c838f104a..39f9669d67 100644 --- a/conf/drupal/config/core.entity_form_display.node.alert.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.alert.default.yml @@ -460,8 +460,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 4 diff --git a/conf/drupal/config/core.entity_form_display.node.binder.default.yml b/conf/drupal/config/core.entity_form_display.node.binder.default.yml index ad67e5b311..783cf9cade 100644 --- a/conf/drupal/config/core.entity_form_display.node.binder.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.binder.default.yml @@ -549,8 +549,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 10 diff --git a/conf/drupal/config/core.entity_form_display.node.campaign_landing.default.yml b/conf/drupal/config/core.entity_form_display.node.campaign_landing.default.yml index 75765424f1..2911feeecb 100644 --- a/conf/drupal/config/core.entity_form_display.node.campaign_landing.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.campaign_landing.default.yml @@ -434,8 +434,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 56 diff --git a/conf/drupal/config/core.entity_form_display.node.contact_information.default.yml b/conf/drupal/config/core.entity_form_display.node.contact_information.default.yml index d3f396db8f..f5d29bac5c 100644 --- a/conf/drupal/config/core.entity_form_display.node.contact_information.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.contact_information.default.yml @@ -260,8 +260,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 4 diff --git a/conf/drupal/config/core.entity_form_display.node.curated_list.default.yml b/conf/drupal/config/core.entity_form_display.node.curated_list.default.yml index e1ee15474a..363e75b1a0 100644 --- a/conf/drupal/config/core.entity_form_display.node.curated_list.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.curated_list.default.yml @@ -498,8 +498,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 4 diff --git a/conf/drupal/config/core.entity_form_display.node.decision.default.yml b/conf/drupal/config/core.entity_form_display.node.decision.default.yml index 4fcd7f295d..44eb66c2fb 100644 --- a/conf/drupal/config/core.entity_form_display.node.decision.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.decision.default.yml @@ -363,8 +363,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 4 diff --git a/conf/drupal/config/core.entity_form_display.node.decision_tree.default.yml b/conf/drupal/config/core.entity_form_display.node.decision_tree.default.yml index a33516bf62..2f5a9f3326 100644 --- a/conf/drupal/config/core.entity_form_display.node.decision_tree.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.decision_tree.default.yml @@ -190,8 +190,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 5 diff --git a/conf/drupal/config/core.entity_form_display.node.decision_tree_branch.default.yml b/conf/drupal/config/core.entity_form_display.node.decision_tree_branch.default.yml index afb286e50a..d12f2b5fa5 100644 --- a/conf/drupal/config/core.entity_form_display.node.decision_tree_branch.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.decision_tree_branch.default.yml @@ -168,8 +168,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 0 diff --git a/conf/drupal/config/core.entity_form_display.node.decision_tree_conclusion.default.yml b/conf/drupal/config/core.entity_form_display.node.decision_tree_conclusion.default.yml index d0d1a8d782..1e32972469 100644 --- a/conf/drupal/config/core.entity_form_display.node.decision_tree_conclusion.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.decision_tree_conclusion.default.yml @@ -155,8 +155,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 0 diff --git a/conf/drupal/config/core.entity_form_display.node.event.default.yml b/conf/drupal/config/core.entity_form_display.node.event.default.yml index a19c25f21c..0d7be33e12 100644 --- a/conf/drupal/config/core.entity_form_display.node.event.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.event.default.yml @@ -724,8 +724,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 118 diff --git a/conf/drupal/config/core.entity_form_display.node.executive_order.default.yml b/conf/drupal/config/core.entity_form_display.node.executive_order.default.yml index 1c00c3eb8e..dc5be78e10 100644 --- a/conf/drupal/config/core.entity_form_display.node.executive_order.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.executive_order.default.yml @@ -345,8 +345,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } uid: type: entity_reference_autocomplete weight: 1 diff --git a/conf/drupal/config/core.entity_form_display.node.external_data_resource.default.yml b/conf/drupal/config/core.entity_form_display.node.external_data_resource.default.yml index 5f0b26f915..f89c808eed 100644 --- a/conf/drupal/config/core.entity_form_display.node.external_data_resource.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.external_data_resource.default.yml @@ -307,8 +307,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 8 diff --git a/conf/drupal/config/core.entity_form_display.node.external_data_resource.inline_entity.yml b/conf/drupal/config/core.entity_form_display.node.external_data_resource.inline_entity.yml index 35c0c6e2fb..34f3bd1466 100644 --- a/conf/drupal/config/core.entity_form_display.node.external_data_resource.inline_entity.yml +++ b/conf/drupal/config/core.entity_form_display.node.external_data_resource.inline_entity.yml @@ -204,8 +204,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 8 diff --git a/conf/drupal/config/core.entity_form_display.node.fee.default.yml b/conf/drupal/config/core.entity_form_display.node.fee.default.yml index 8b411578ba..3aef1ee422 100644 --- a/conf/drupal/config/core.entity_form_display.node.fee.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.fee.default.yml @@ -135,8 +135,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 0 diff --git a/conf/drupal/config/core.entity_form_display.node.fee.inline_entity.yml b/conf/drupal/config/core.entity_form_display.node.fee.inline_entity.yml index 499b77a1f1..516388580e 100644 --- a/conf/drupal/config/core.entity_form_display.node.fee.inline_entity.yml +++ b/conf/drupal/config/core.entity_form_display.node.fee.inline_entity.yml @@ -132,8 +132,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 0 diff --git a/conf/drupal/config/core.entity_form_display.node.form_page.default.yml b/conf/drupal/config/core.entity_form_display.node.form_page.default.yml index 11fe609fea..d37e3c1e64 100644 --- a/conf/drupal/config/core.entity_form_display.node.form_page.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.form_page.default.yml @@ -267,8 +267,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 7 diff --git a/conf/drupal/config/core.entity_form_display.node.guide_page.default.yml b/conf/drupal/config/core.entity_form_display.node.guide_page.default.yml index 0342a730f3..17354f586a 100644 --- a/conf/drupal/config/core.entity_form_display.node.guide_page.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.guide_page.default.yml @@ -411,8 +411,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: -3 diff --git a/conf/drupal/config/core.entity_form_display.node.how_to_page.default.yml b/conf/drupal/config/core.entity_form_display.node.how_to_page.default.yml index 583e4eff6c..94b0be28b2 100644 --- a/conf/drupal/config/core.entity_form_display.node.how_to_page.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.how_to_page.default.yml @@ -623,8 +623,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: -3 diff --git a/conf/drupal/config/core.entity_form_display.node.info_details.default.yml b/conf/drupal/config/core.entity_form_display.node.info_details.default.yml index dfbc9531f1..3f469931d2 100644 --- a/conf/drupal/config/core.entity_form_display.node.info_details.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.info_details.default.yml @@ -552,8 +552,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 5 diff --git a/conf/drupal/config/core.entity_form_display.node.location.default.yml b/conf/drupal/config/core.entity_form_display.node.location.default.yml index 6da3059f12..b51513e660 100644 --- a/conf/drupal/config/core.entity_form_display.node.location.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.location.default.yml @@ -508,8 +508,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 4 diff --git a/conf/drupal/config/core.entity_form_display.node.location_details.default.yml b/conf/drupal/config/core.entity_form_display.node.location_details.default.yml index 0cd9d58a38..2054d6ab02 100644 --- a/conf/drupal/config/core.entity_form_display.node.location_details.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.location_details.default.yml @@ -206,8 +206,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: -5 diff --git a/conf/drupal/config/core.entity_form_display.node.news.default.yml b/conf/drupal/config/core.entity_form_display.node.news.default.yml index c05d2d7af5..6890833a93 100644 --- a/conf/drupal/config/core.entity_form_display.node.news.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.news.default.yml @@ -475,8 +475,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 2 diff --git a/conf/drupal/config/core.entity_form_display.node.org_page.default.yml b/conf/drupal/config/core.entity_form_display.node.org_page.default.yml index 83a8be8d3d..0b371e92df 100644 --- a/conf/drupal/config/core.entity_form_display.node.org_page.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.org_page.default.yml @@ -612,8 +612,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 142 diff --git a/conf/drupal/config/core.entity_form_display.node.page.default.yml b/conf/drupal/config/core.entity_form_display.node.page.default.yml index 725398e327..eb0f4ac131 100644 --- a/conf/drupal/config/core.entity_form_display.node.page.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.page.default.yml @@ -106,8 +106,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } sticky: type: boolean_checkbox weight: 4 diff --git a/conf/drupal/config/core.entity_form_display.node.person.default.yml b/conf/drupal/config/core.entity_form_display.node.person.default.yml index a0049c0a85..2b22890831 100644 --- a/conf/drupal/config/core.entity_form_display.node.person.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.person.default.yml @@ -498,8 +498,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 7 diff --git a/conf/drupal/config/core.entity_form_display.node.regulation.default.yml b/conf/drupal/config/core.entity_form_display.node.regulation.default.yml index 751e90377c..21a7a2fa35 100644 --- a/conf/drupal/config/core.entity_form_display.node.regulation.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.regulation.default.yml @@ -359,8 +359,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } uid: type: entity_reference_autocomplete weight: 1 diff --git a/conf/drupal/config/core.entity_form_display.node.rules.default.yml b/conf/drupal/config/core.entity_form_display.node.rules.default.yml index 86f9f69bc9..0f76da46ff 100644 --- a/conf/drupal/config/core.entity_form_display.node.rules.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.rules.default.yml @@ -415,8 +415,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 56 diff --git a/conf/drupal/config/core.entity_form_display.node.service_details.default.yml b/conf/drupal/config/core.entity_form_display.node.service_details.default.yml index 4c49cb0f5a..8ee9da281b 100644 --- a/conf/drupal/config/core.entity_form_display.node.service_details.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.service_details.default.yml @@ -451,8 +451,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 56 diff --git a/conf/drupal/config/core.entity_form_display.node.service_page.default.yml b/conf/drupal/config/core.entity_form_display.node.service_page.default.yml index 7921cda0ef..97c23b1036 100644 --- a/conf/drupal/config/core.entity_form_display.node.service_page.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.service_page.default.yml @@ -567,8 +567,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 69 diff --git a/conf/drupal/config/core.entity_form_display.node.sitewide_alert.default.yml b/conf/drupal/config/core.entity_form_display.node.sitewide_alert.default.yml index 1d7b5c5c3e..3417e74007 100644 --- a/conf/drupal/config/core.entity_form_display.node.sitewide_alert.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.sitewide_alert.default.yml @@ -174,8 +174,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 1 diff --git a/conf/drupal/config/core.entity_form_display.node.stacked_layout.default.yml b/conf/drupal/config/core.entity_form_display.node.stacked_layout.default.yml index a7545ae7a7..998ae09af5 100644 --- a/conf/drupal/config/core.entity_form_display.node.stacked_layout.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.stacked_layout.default.yml @@ -313,8 +313,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 116 diff --git a/conf/drupal/config/core.entity_form_display.node.topic_page.default.yml b/conf/drupal/config/core.entity_form_display.node.topic_page.default.yml index 217e98f859..05fb7ac09f 100644 --- a/conf/drupal/config/core.entity_form_display.node.topic_page.default.yml +++ b/conf/drupal/config/core.entity_form_display.node.topic_page.default.yml @@ -271,8 +271,8 @@ content: simple_sitemap: weight: 10 region: content - settings: { } - third_party_settings: { } + settings: { } + third_party_settings: { } title: type: string_textfield weight: 56 diff --git a/conf/drupal/config/core.entity_form_display.paragraph.org_section_long_form.default.yml b/conf/drupal/config/core.entity_form_display.paragraph.org_section_long_form.default.yml index 7973083e55..733fab7fb0 100644 --- a/conf/drupal/config/core.entity_form_display.paragraph.org_section_long_form.default.yml +++ b/conf/drupal/config/core.entity_form_display.paragraph.org_section_long_form.default.yml @@ -6,6 +6,7 @@ dependencies: - field.field.paragraph.org_section_long_form.field_hide_heading - field.field.paragraph.org_section_long_form.field_section_long_form_content - field.field.paragraph.org_section_long_form.field_section_long_form_heading + - field.field.paragraph.org_section_long_form.field_section_style - paragraphs.paragraphs_type.org_section_long_form module: - field_group @@ -18,7 +19,7 @@ third_party_settings: label: 'Section Content' region: content parent_name: '' - weight: 2 + weight: 3 format_type: details format_settings: classes: section-content @@ -31,7 +32,7 @@ third_party_settings: label: 'Additional Resources' region: content parent_name: '' - weight: 3 + weight: 4 format_type: details format_settings: classes: '' @@ -71,6 +72,12 @@ content: size: 60 placeholder: '' third_party_settings: { } + field_section_style: + type: options_buttons + weight: 2 + region: content + settings: { } + third_party_settings: { } hidden: created: true status: true diff --git a/conf/drupal/config/core.entity_view_display.paragraph.org_section_long_form.default.yml b/conf/drupal/config/core.entity_view_display.paragraph.org_section_long_form.default.yml index 83d853a4bd..821020cd53 100644 --- a/conf/drupal/config/core.entity_view_display.paragraph.org_section_long_form.default.yml +++ b/conf/drupal/config/core.entity_view_display.paragraph.org_section_long_form.default.yml @@ -6,9 +6,11 @@ dependencies: - field.field.paragraph.org_section_long_form.field_hide_heading - field.field.paragraph.org_section_long_form.field_section_long_form_content - field.field.paragraph.org_section_long_form.field_section_long_form_heading + - field.field.paragraph.org_section_long_form.field_section_style - paragraphs.paragraphs_type.org_section_long_form module: - entity_reference_revisions + - options id: paragraph.org_section_long_form.default targetEntityType: paragraph bundle: org_section_long_form @@ -31,6 +33,13 @@ content: third_party_settings: { } weight: 0 region: content + field_section_style: + type: list_default + label: above + settings: { } + third_party_settings: { } + weight: 2 + region: content hidden: computed_org_page: true field_hide_heading: true diff --git a/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml b/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml index 58333a249f..e50371d02c 100644 --- a/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml +++ b/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml @@ -11,6 +11,7 @@ dependencies: - paragraphs.paragraphs_type.featured_item_mosaic - paragraphs.paragraphs_type.featured_message - paragraphs.paragraphs_type.featured_topics + - paragraphs.paragraphs_type.flexible_link_group - paragraphs.paragraphs_type.iframe - paragraphs.paragraphs_type.image - paragraphs.paragraphs_type.info_details_card_group @@ -69,6 +70,7 @@ settings: video: video what_would_you_like_to_do: what_would_you_like_to_do collection_search: collection_search + flexible_link_group: flexible_link_group negate: 0 target_bundles_drag_drop: 1up_stacked_band: @@ -125,6 +127,9 @@ settings: advisory_section: weight: 39 enabled: false + alert: + weight: 151 + enabled: false board_member: weight: 40 enabled: false @@ -161,6 +166,9 @@ settings: contact_info: weight: 48 enabled: false + contact_placeholder: + weight: 164 + enabled: false content_card_group: weight: 49 enabled: false @@ -215,6 +223,9 @@ settings: file_download_single: weight: 63 enabled: false + flexible_link_group: + weight: 183 + enabled: true footnotes: weight: 64 enabled: false @@ -263,9 +274,6 @@ settings: key_message_section: weight: 76 enabled: false - link_group: - weight: 77 - enabled: false link_group_accordion: weight: 90 enabled: false @@ -413,6 +421,12 @@ settings: section_with_heading: weight: 117 enabled: false + service_rich_text: + weight: 249 + enabled: false + service_section: + weight: 250 + enabled: false sitewide_alert_message: weight: 242 enabled: false @@ -440,6 +454,9 @@ settings: tableau_embed: weight: 20 enabled: true + time_callout: + weight: 260 + enabled: false video: weight: 21 enabled: true diff --git a/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_style.yml b/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_style.yml new file mode 100644 index 0000000000..7d5256977b --- /dev/null +++ b/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_style.yml @@ -0,0 +1,23 @@ +uuid: 17054d01-bdd8-4160-855d-f062c3f094e8 +langcode: en +status: true +dependencies: + config: + - field.storage.paragraph.field_section_style + - paragraphs.paragraphs_type.org_section_long_form + module: + - options +id: paragraph.org_section_long_form.field_section_style +field_name: field_section_style +entity_type: paragraph +bundle: org_section_long_form +label: 'Section style' +description: 'The "Simple" option uses a plain black header with content on a white background. If you really want to call attention to this section, you can use the "Enhanced" option which will use a blue header banner and gray shading for the section.' +required: true +translatable: true +default_value: + - + value: simple +default_value_callback: '' +settings: { } +field_type: list_string diff --git a/conf/drupal/config/views.view.change_collections.yml b/conf/drupal/config/views.view.change_collections.yml index e11383de5f..0c1220e116 100644 --- a/conf/drupal/config/views.view.change_collections.yml +++ b/conf/drupal/config/views.view.change_collections.yml @@ -103,13 +103,13 @@ display: form_step: true buttons: true action_title: Action + clear_on_exposed: false + force_selection_info: false selected_actions: 4: action_id: mass_views_change_collections preconfiguration: - add_confirmation: 1 - clear_on_exposed: false - force_selection_info: 0 + add_confirmation: true title: id: title table: node_field_revision diff --git a/conf/drupal/config/views.view.content_performance.yml b/conf/drupal/config/views.view.content_performance.yml index 897ab4e0a5..22c85473c9 100644 --- a/conf/drupal/config/views.view.content_performance.yml +++ b/conf/drupal/config/views.view.content_performance.yml @@ -2275,11 +2275,6 @@ display: options: row_class: '' default_row_class: true - override: 1 - sticky: 0 - caption: '' - summary: '' - description: '' columns: title: title nid: nid @@ -2291,147 +2286,152 @@ display: field_views_simple_math_field: field_views_simple_math_field operations: operations eject_rate: eject_rate + default: eject_rate info: title: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' nid: - sortable: 0 + sortable: false default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' type: - sortable: 0 + sortable: false default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' uid: - sortable: 0 + sortable: false default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' status: - sortable: 0 + sortable: false default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' changed: - sortable: 0 + sortable: false default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' pageviews: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' field_views_simple_math_field: - sortable: 0 + sortable: false default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' operations: align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' eject_rate: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' - default: eject_rate - empty_table: 0 + override: true + sticky: false + summary: '' + empty_table: false + caption: '' + description: '' group_aggregation: group_aggregation_results: '0' grouping_field_class: '' @@ -2440,7 +2440,7 @@ display: grouping_row_class: '' column_aggregation: totals_row_position: - 2: '2' + 2: 2 1: 0 3: 0 totals_per_page: '1' diff --git a/docroot/themes/custom/mass_theme/mass_theme.theme b/docroot/themes/custom/mass_theme/mass_theme.theme index dd53f6d5fa..b5af147256 100644 --- a/docroot/themes/custom/mass_theme/mass_theme.theme +++ b/docroot/themes/custom/mass_theme/mass_theme.theme @@ -7204,6 +7204,9 @@ function _mass_theme_preprocess_paragraph_sections(&$variables, $field) { * Groups different components together when necessary. */ function mass_theme_preprocess_paragraph__org_section_long_form(&$variables) { + + $container = $variables['paragraph']; + $variables['section_style'] = $container->field_section_style->value; $variables["org_components"] = _mass_theme_preprocess_paragraph_sections($variables, 'field_section_long_form_content'); } diff --git a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig index f7a35d47a5..6c80bc9c58 100644 --- a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig +++ b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig @@ -7,41 +7,70 @@ } %} {% endif %} -{% embed "@organisms/by-author/stacked-row-section.twig" with { - "stackedRowSection": heading, - "stackedRow": { - "borderless": true, - "modifier" : "no-sidebar" - }, - "externalSidebar": true -} %} - {% block stackedRowContentOverride %} - {% for org_component in org_components %} - {% if org_component.group == 'default' %} - {% embed "@organisms/by-author/rich-text.twig" %} - {% block rteElements %} - {% for c in org_component.items %} - {{ c|view }} - {% endfor %} - {% endblock %} - {% endembed %} - {% elseif org_component.group == 'self' %} - {% embed "@organisms/by-author/rich-text.twig" %} - {% block rteElements %} - {{ org_component.items|view }} - {% endblock %} - {% endembed %} - {% elseif org_component.group == 'contained' %} - {% embed "@organisms/by-author/rich-text.twig" with {'headerIndent' : 'om__contained-component'} %} - {% block rteElements %} - {{ org_component.items|view }} - {% endblock %} - {% endembed %} - {% else %} - {{ org_component[0]|view }} +{% set section_style_class = section_style == 'enhanced' ? 'service-section--enhanced' : 'service-section--simple' %} + +
+ {% embed "@organisms/by-author/stacked-row-section.twig" with { + "stackedRowSection": heading, + "stackedRow": { + "borderless": true, + "modifier" : "no-sidebar" + }, + "externalSidebar": true + } %} + {% block stackRowTitle %} + {% if heading %} + {% if section_style == 'enhanced' %} + {% include "@atoms/04-headings/colored-heading-from-left.twig" with { + "coloredHeadingFromLeft": { + "bgColor": "blue", + "title": (content.field_section_long_form_heading|field_value) + }} + %} + {% else %} +
+
+ {% set compHeading = { + "title": stackedRowSection.title, + "sub": "", + "color": "", + "id": stackedRowSection.id + } + %} + {% include "@atoms/04-headings/comp-heading.twig" %} +
+
+ {% endif %} {% endif %} - {% endfor %} - {% endblock %} -{% endembed %} + {% endblock %} + {% block stackedRowContentOverride %} + {% for org_component in org_components %} + {% if org_component.group == 'default' %} + {% embed "@organisms/by-author/rich-text.twig" %} + {% block rteElements %} + {% for c in org_component.items %} + {{ c|view }} + {% endfor %} + {% endblock %} + {% endembed %} + {% elseif org_component.group == 'self' %} + {% embed "@organisms/by-author/rich-text.twig" %} + {% block rteElements %} + {{ org_component.items|view }} + {% endblock %} + {% endembed %} + {% elseif org_component.group == 'contained' %} + {% embed "@organisms/by-author/rich-text.twig" with {'headerIndent' : 'om__contained-component'} %} + {% block rteElements %} + {{ org_component.items|view }} + {% endblock %} + {% endembed %} + {% else %} + {{ org_component[0]|view }} + {% endif %} + {% endfor %} + {% endblock %} + {% endembed %} -{{ content.field_section_long_form_addition }} + {{ content.field_section_long_form_addition }} +
From b5d4100a2adcc59acb6cc6e73e6f6a1edfb4caaa Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Tue, 1 Aug 2023 22:54:06 +0400 Subject: [PATCH 02/32] Draft --- .../custom/mass_fields/mass_fields.module | 152 +++++++++--------- test.php | 32 ++++ 2 files changed, 109 insertions(+), 75 deletions(-) create mode 100644 test.php diff --git a/docroot/modules/custom/mass_fields/mass_fields.module b/docroot/modules/custom/mass_fields/mass_fields.module index 0eb33eeedf..8af8ea8951 100644 --- a/docroot/modules/custom/mass_fields/mass_fields.module +++ b/docroot/modules/custom/mass_fields/mass_fields.module @@ -896,87 +896,89 @@ function _mass_fields_conditions_for_paragraphs(&$element, FormStateInterface $f $widget_state = WidgetBase::getWidgetState($element['#field_parents'], $paragraph_entity_reference_field_name, $form_state); /** @var \Drupal\paragraphs\Entity\Paragraph $paragraph */ $paragraph_instance = $widget_state['paragraphs'][$element['#delta']]['entity']; - $paragraph_type = $paragraph_instance->bundle(); - // Determine which paragraph type is being embedded. - switch ($paragraph_type) { - case 'collection_search': - $dependee_field_name = 'field_search_type'; - $selector = sprintf('select[name="%s[%d][subform][%s][%d][subform][%s]"]', - $element['#field_parents'][0], - $element['#field_parents'][1], - $paragraph_entity_reference_field_name, - $element['#delta'], - $dependee_field_name); - - if ($paragraph_entity_reference_field_name == 'field_sections') { - $selector = sprintf('select[name="%s[%d][subform][%s]"]', + if ($paragraph_instance) { + $paragraph_type = $paragraph_instance->bundle(); + // Determine which paragraph type is being embedded. + switch ($paragraph_type) { + case 'collection_search': + $dependee_field_name = 'field_search_type'; + $selector = sprintf('select[name="%s[%d][subform][%s][%d][subform][%s]"]', + $element['#field_parents'][0], + $element['#field_parents'][1], $paragraph_entity_reference_field_name, $element['#delta'], $dependee_field_name); - } - - // Dependent fields. - $element['subform']['field_collection']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'collection'], - ], - 'required' => [ - $selector => ['value' => 'collection'], - ], - ]; - // Dependent fields. - $element['subform']['field_search_site_url']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'external'], - ], - 'required' => [ - $selector => ['value' => 'external'], - ], - ]; - - // Dependent fields. - $element['subform']['field_search_query_param_name']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'external'], - ], - 'required' => [ - $selector => ['value' => 'external'], - ], - ]; - break; - - case 'key_message_section': - $dependee_field_name = 'field_background_type'; - $selector = sprintf('input[name="%s[%d][subform][%s]"]', $paragraph_entity_reference_field_name, $element['#delta'], $dependee_field_name); - - // Dependent fields. - $element['subform']['field_image']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'image'], - ], - 'required' => [ - $selector => ['value' => 'image'], - ], - ]; - - $element['subform']['field_section_background_color']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'color'], - ], - 'required' => [ - $selector => ['value' => 'color'], - ], - ]; - - $element['subform']['field_section_text_overlay_color']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'image'], - ], + if ($paragraph_entity_reference_field_name == 'field_sections') { + $selector = sprintf('select[name="%s[%d][subform][%s]"]', + $paragraph_entity_reference_field_name, + $element['#delta'], + $dependee_field_name); + } - ]; - break; + // Dependent fields. + $element['subform']['field_collection']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'collection'], + ], + 'required' => [ + $selector => ['value' => 'collection'], + ], + ]; + + // Dependent fields. + $element['subform']['field_search_site_url']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'external'], + ], + 'required' => [ + $selector => ['value' => 'external'], + ], + ]; + + // Dependent fields. + $element['subform']['field_search_query_param_name']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'external'], + ], + 'required' => [ + $selector => ['value' => 'external'], + ], + ]; + break; + + case 'key_message_section': + $dependee_field_name = 'field_background_type'; + $selector = sprintf('input[name="%s[%d][subform][%s]"]', $paragraph_entity_reference_field_name, $element['#delta'], $dependee_field_name); + + // Dependent fields. + $element['subform']['field_image']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'image'], + ], + 'required' => [ + $selector => ['value' => 'image'], + ], + ]; + + $element['subform']['field_section_background_color']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'color'], + ], + 'required' => [ + $selector => ['value' => 'color'], + ], + ]; + + $element['subform']['field_section_text_overlay_color']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'image'], + ], + + ]; + break; + } } } } diff --git a/test.php b/test.php new file mode 100644 index 0000000000..ea7729a4d2 --- /dev/null +++ b/test.php @@ -0,0 +1,32 @@ +condition('type','what_would_you_like_to_do')->execute(); + +$parapgrahs = \Drupal\paragraphs\Entity\Paragraph::loadMultiple($ids); + +foreach ($parapgrahs as $parapgrah) { + + if ($parapgrah->id() == '2643406') { + $parent_field_name = $parapgrah->parent_field_name->value; + if (!$parapgrah->get('field_wwyltd_top_s_links')->isEmpty()) { + $top_links = $parapgrah->get('field_wwyltd_top_s_links')->getValue(); + // dump($top_links); + } + if ($parent = $parapgrah->getParentEntity()) { + if ($parent instanceof \Drupal\paragraphs\Entity\Paragraph && $parent->bundle() == 'org_section_long_form') { + if ($parent->getParentEntity() instanceof \Drupal\node\Entity\Node) { + $items = $parent->get($parent_field_name)->getValue(); + foreach ($items as $index => $item) { + if ($item['target_id'] == $parapgrah->id() && $item['target_revision_id'] == $parapgrah->getRevisionId()) { + $paragraph_index = $index; + break; + } + } + + dump($parent->get($parent_field_name)->offsetGet($paragraph_index)->toArray()); + // offsetset to the same index with the new data and paragraph + } + } + } + } +} From d200e81e100224cc07b8af12d9ad92bc0c332383 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Wed, 2 Aug 2023 13:45:39 +0400 Subject: [PATCH 03/32] Draft --- test.php | 124 ++++++++++++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 114 insertions(+), 10 deletions(-) diff --git a/test.php b/test.php index ea7729a4d2..1b530df5ea 100644 --- a/test.php +++ b/test.php @@ -1,29 +1,133 @@ condition('type','what_would_you_like_to_do')->execute(); +use \Drupal\paragraphs\Entity\Paragraph; + +$_ENV['MASS_FLAGGING_BYPASS'] = TRUE; + +$ids = \Drupal::entityQuery('paragraph')->accessCheck(FALSE)->condition('type','what_would_you_like_to_do')->execute(); $parapgrahs = \Drupal\paragraphs\Entity\Paragraph::loadMultiple($ids); foreach ($parapgrahs as $parapgrah) { - if ($parapgrah->id() == '2643406') { + if ($parapgrah->id()) { $parent_field_name = $parapgrah->parent_field_name->value; - if (!$parapgrah->get('field_wwyltd_top_s_links')->isEmpty()) { - $top_links = $parapgrah->get('field_wwyltd_top_s_links')->getValue(); - // dump($top_links); - } + if ($parent = $parapgrah->getParentEntity()) { if ($parent instanceof \Drupal\paragraphs\Entity\Paragraph && $parent->bundle() == 'org_section_long_form') { if ($parent->getParentEntity() instanceof \Drupal\node\Entity\Node) { - $items = $parent->get($parent_field_name)->getValue(); + $node = $parent->getParentEntity(); + $node_field_name = $parent->parent_field_name->value; + + $items = $node->get($node_field_name)->getValue(); foreach ($items as $index => $item) { - if ($item['target_id'] == $parapgrah->id() && $item['target_revision_id'] == $parapgrah->getRevisionId()) { - $paragraph_index = $index; + if ($item['target_id'] == $parent->id() && $item['target_revision_id'] == $parent->getRevisionId()) { + $section_index = $index; break; } } - dump($parent->get($parent_field_name)->offsetGet($paragraph_index)->toArray()); + $flexible_link_groups = []; + if (!$parapgrah->get('field_wwyltd_top_s_links')->isEmpty()) { + $top_links = $parapgrah->get('field_wwyltd_top_s_links')->getValue(); + + $link_group_links = []; + foreach ($top_links as $link) { + // Create a new link_group_link paragraph. + $link_group_link = Paragraph::create([ + 'type' => 'link_group_link', + ]); + + $link_group_link->set('field_link_group_link', $link); + $link_group_link->save(); + $link_group_links[] = $link_group_link; + } + + + // Create a new flexible_link_group paragraph. + $flexible_link_group = Paragraph::create([ + 'type' => 'flexible_link_group', + ]); + + $flexible_link_group->set('field_featured', 1); + $flexible_link_group->set('field_display_type', 'buttons'); + // 2 = Buttons. + $flexible_link_group->set('field_link_group', $link_group_links); + $flexible_link_group->save(); + $flexible_link_groups[] = $flexible_link_group; + } + + if (!$parapgrah->get('field_wwyltd_more_services')->isEmpty()) { + $more_paragraphs = $parapgrah->get('field_wwyltd_more_services')->referencedEntities(); + + foreach ($more_paragraphs as $more_paragraph) { + if (!$more_paragraph->get('field_links_documents')->isEmpty()) { + $link_group_links = $more_paragraph->get('field_links_documents') + ->referencedEntities(); + + // Create a new flexible_link_group paragraph. + $flexible_link_group = Paragraph::create([ + 'type' => 'flexible_link_group', + ]); + + $flexible_link_group->set('field_featured', 0); + $flexible_link_group->set('field_display_type', 'links'); + $flexible_link_group->set('field_group_expanded', 1); + if (!$more_paragraph->get('field_section_title')->isEmpty()) { + $title = $more_paragraph->get('field_section_title')->value; + $flexible_link_group->set('field_flexible_link_group_title', $title); + } + $flexible_link_group->set('field_link_group', $link_group_links); + $flexible_link_group->save(); + $flexible_link_groups[] = $flexible_link_group; + } + } + } + + if ($flexible_link_groups) { + $new_org_section_long_form_paragraph = Paragraph::create([ + 'type' => 'org_section_long_form', + ]); + $new_org_section_long_form_paragraph->set('field_section_long_form_content', $flexible_link_groups); + if (!$parapgrah->get('field_wwyltd_heading')->isEmpty()) { + $heading = $parapgrah->get('field_wwyltd_heading')->value; + $new_org_section_long_form_paragraph->set('field_section_long_form_heading', $heading); + } + $new_org_section_long_form_paragraph->set('field_hide_heading', 0); + + // Save the new paragraph. + $new_org_section_long_form_paragraph->save(); + // Create a value array for the new section paragraph. + $new_org_section_long_form_paragraph_value = [ + 'target_id' => $new_org_section_long_form_paragraph->id(), + 'target_revision_id' => $new_org_section_long_form_paragraph->getRevisionId(), + ]; + if (isset($section_index)) { + $items[$section_index] = $new_org_section_long_form_paragraph_value; + } + else { + $items[] = $new_org_section_long_form_paragraph_value; + } + + $node->set('field_organization_sections', $items); + // Save the node. + // Save without updating the last modified date. This requires a core patch + // from the issue: https://www.drupal.org/project/drupal/issues/2329253. + $node->setSyncing(TRUE); + $node->save(); + $parapgrah->delete(); + dump($node->id()); + exit; + } +// $items = $node->get($parent_field_name)->getValue(); +// foreach ($items as $index => $item) { +// if ($item['target_id'] == $parapgrah->id() && $item['target_revision_id'] == $parapgrah->getRevisionId()) { +// $paragraph_index = $index; +// break; +// } +// } +// +// dump($parent->get($parent_field_name)->offsetGet($paragraph_index)->toArray()); // offsetset to the same index with the new data and paragraph } } From 31fe263e8dd1038d26efa7b72fb6c582495e2388 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Wed, 2 Aug 2023 15:09:51 +0400 Subject: [PATCH 04/32] Draft --- .../mass_content/mass_content.deploy.php | 196 ++++++++++++++++++ 1 file changed, 196 insertions(+) diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 87ca71e637..2f342d0407 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -897,3 +897,199 @@ function mass_content_deploy_related_content(&$sandbox) { } return "Processed {$sandbox['progress']} items."; } + +/** + * Set "Section style" default value for the org sections. + */ +function mass_content_deploy_org_section_style(&$sandbox) { + $_ENV['MASS_FLAGGING_BYPASS'] = TRUE; + + $query = \Drupal::entityQuery('paragraph')->accessCheck(FALSE); + $query->condition('type', 'org_section_long_form'); + + if (empty($sandbox)) { + // Get a list of all nodes of type event. + $sandbox['progress'] = 0; + $sandbox['current'] = 0; + $count = clone $query; + $sandbox['max'] = $count->count()->accessCheck(FALSE)->execute(); + } + + $batch_size = 50; + + $pids = $query->condition('id', $sandbox['current'], '>') + ->sort('id') + ->range(0, $batch_size) + ->execute(); + + $storage = \Drupal::entityTypeManager()->getStorage('paragraph'); + + $paragraphs = $storage->loadMultiple($pids); + + foreach ($paragraphs as $paragraph) { + $sandbox['current'] = $paragraph->id(); + $paragraph->set('field_section_style', 'simple'); + $paragraph->save(); + $sandbox['progress']++; + } + + $sandbox['#finished'] = empty($sandbox['max']) ? 1 : ($sandbox['progress'] / $sandbox['max']); + if ($sandbox['#finished'] >= 1) { + return t('Section style default value set for the org sections. Processed @total items.', ['@total' => $sandbox['progress']]); + } + return "Processed {$sandbox['progress']} items."; +} + +/** + * Migrate "What would you like to do" to be flexible links. + */ +function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { + $_ENV['MASS_FLAGGING_BYPASS'] = TRUE; + + $query = \Drupal::entityQuery('paragraph')->accessCheck(FALSE); + $query->condition('type', 'what_would_you_like_to_do'); + + if (empty($sandbox)) { + // Get a list of all nodes of type event. + $sandbox['progress'] = 0; + $sandbox['current'] = 0; + $count = clone $query; + $sandbox['max'] = $count->count()->accessCheck(FALSE)->execute(); + } + + $batch_size = 50; + + $pids = $query->condition('id', $sandbox['current'], '>') + ->sort('id') + ->range(0, $batch_size) + ->execute(); + + $storage = \Drupal::entityTypeManager()->getStorage('paragraph'); + + $paragraphs = $storage->loadMultiple($pids); + + foreach ($paragraphs as $paragraph) { + dump(gettype($paragraph)); + if ($paragraph) { + $parent_field_name = $paragraph->parent_field_name->value; + + if ($parent = $paragraph->getParentEntity()) { + if ($parent instanceof \Drupal\paragraphs\Entity\Paragraph && $parent->bundle() == 'org_section_long_form') { + if ($parent->getParentEntity() instanceof \Drupal\node\Entity\Node) { + $node = $parent->getParentEntity(); + $node_field_name = $parent->parent_field_name->value; + + $items = $node->get($node_field_name)->getValue(); + foreach ($items as $index => $item) { + if ($item['target_id'] == $parent->id() && $item['target_revision_id'] == $parent->getRevisionId()) { + $section_index = $index; + break; + } + } + + $flexible_link_groups = []; + if (!$paragraph->get('field_wwyltd_top_s_links')->isEmpty()) { + $top_links = $paragraph->get('field_wwyltd_top_s_links') + ->getValue(); + + $link_group_links = []; + foreach ($top_links as $link) { + // Create a new link_group_link paragraph. + $link_group_link = Paragraph::create([ + 'type' => 'link_group_link', + ]); + + $link_group_link->set('field_link_group_link', $link); + $link_group_link->save(); + $link_group_links[] = $link_group_link; + } + + + // Create a new flexible_link_group paragraph. + $flexible_link_group = Paragraph::create([ + 'type' => 'flexible_link_group', + ]); + + $flexible_link_group->set('field_featured', 1); + $flexible_link_group->set('field_display_type', 'buttons'); + // 2 = Buttons. + $flexible_link_group->set('field_link_group', $link_group_links); + $flexible_link_group->save(); + $flexible_link_groups[] = $flexible_link_group; + } + + if (!$paragraph->get('field_wwyltd_more_services')->isEmpty()) { + $more_paragraphs = $paragraph->get('field_wwyltd_more_services') + ->referencedEntities(); + + foreach ($more_paragraphs as $more_paragraph) { + if (!$more_paragraph->get('field_links_documents')->isEmpty()) { + $link_group_links = $more_paragraph->get('field_links_documents') + ->referencedEntities(); + + // Create a new flexible_link_group paragraph. + $flexible_link_group = Paragraph::create([ + 'type' => 'flexible_link_group', + ]); + + $flexible_link_group->set('field_featured', 0); + $flexible_link_group->set('field_display_type', 'links'); + $flexible_link_group->set('field_group_expanded', 1); + if (!$more_paragraph->get('field_section_title')->isEmpty()) { + $title = $more_paragraph->get('field_section_title')->value; + $flexible_link_group->set('field_flexible_link_group_title', $title); + } + $flexible_link_group->set('field_link_group', $link_group_links); + $flexible_link_group->save(); + $flexible_link_groups[] = $flexible_link_group; + } + } + } + + if ($flexible_link_groups) { + $new_org_section_long_form_paragraph = Paragraph::create([ + 'type' => 'org_section_long_form', + ]); + $new_org_section_long_form_paragraph->set('field_section_long_form_content', $flexible_link_groups); + if (!$paragraph->get('field_wwyltd_heading')->isEmpty()) { + $heading = $paragraph->get('field_wwyltd_heading')->value; + $new_org_section_long_form_paragraph->set('field_section_long_form_heading', $heading); + } + $new_org_section_long_form_paragraph->set('field_hide_heading', 0); + + // Save the new paragraph. + $new_org_section_long_form_paragraph->save(); + // Create a value array for the new section paragraph. + $new_org_section_long_form_paragraph_value = [ + 'target_id' => $new_org_section_long_form_paragraph->id(), + 'target_revision_id' => $new_org_section_long_form_paragraph->getRevisionId(), + ]; + if (isset($section_index)) { + $items[$section_index] = $new_org_section_long_form_paragraph_value; + } + else { + $items[] = $new_org_section_long_form_paragraph_value; + } + + $node->set('field_organization_sections', $items); + // Save the node. + // Save without updating the last modified date. This requires a core patch + // from the issue: https://www.drupal.org/project/drupal/issues/2329253. + $node->setSyncing(TRUE); + $node->save(); + $paragraph->delete(); + dump($node->id()); + } + } + } + } + } + $sandbox['progress']++; + } + + $sandbox['#finished'] = empty($sandbox['max']) ? 1 : ($sandbox['progress'] / $sandbox['max']); + if ($sandbox['#finished'] >= 1) { + return t('Migrate "What would you like to do" to flexible links. Processed @total items.', ['@total' => $sandbox['progress']]); + } + return "Processed {$sandbox['progress']} items."; +} From 96ae72de421b00748e947ef395f2e50cc8ef086c Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Wed, 2 Aug 2023 15:22:36 +0400 Subject: [PATCH 05/32] Draft --- .../mass_content/mass_content.deploy.php | 229 ++++++++++-------- 1 file changed, 130 insertions(+), 99 deletions(-) diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 2f342d0407..2027415230 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -966,120 +966,42 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { $storage = \Drupal::entityTypeManager()->getStorage('paragraph'); + // Turn off entity_hierarchy writes while processing the item. + \Drupal::state()->set('entity_hierarchy_disable_writes', TRUE); + $paragraphs = $storage->loadMultiple($pids); foreach ($paragraphs as $paragraph) { - dump(gettype($paragraph)); if ($paragraph) { $parent_field_name = $paragraph->parent_field_name->value; - if ($parent = $paragraph->getParentEntity()) { if ($parent instanceof \Drupal\paragraphs\Entity\Paragraph && $parent->bundle() == 'org_section_long_form') { if ($parent->getParentEntity() instanceof \Drupal\node\Entity\Node) { $node = $parent->getParentEntity(); - $node_field_name = $parent->parent_field_name->value; - - $items = $node->get($node_field_name)->getValue(); - foreach ($items as $index => $item) { - if ($item['target_id'] == $parent->id() && $item['target_revision_id'] == $parent->getRevisionId()) { - $section_index = $index; - break; - } + try { + mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragraph); } - - $flexible_link_groups = []; - if (!$paragraph->get('field_wwyltd_top_s_links')->isEmpty()) { - $top_links = $paragraph->get('field_wwyltd_top_s_links') - ->getValue(); - - $link_group_links = []; - foreach ($top_links as $link) { - // Create a new link_group_link paragraph. - $link_group_link = Paragraph::create([ - 'type' => 'link_group_link', - ]); - - $link_group_link->set('field_link_group_link', $link); - $link_group_link->save(); - $link_group_links[] = $link_group_link; - } - - - // Create a new flexible_link_group paragraph. - $flexible_link_group = Paragraph::create([ - 'type' => 'flexible_link_group', - ]); - - $flexible_link_group->set('field_featured', 1); - $flexible_link_group->set('field_display_type', 'buttons'); - // 2 = Buttons. - $flexible_link_group->set('field_link_group', $link_group_links); - $flexible_link_group->save(); - $flexible_link_groups[] = $flexible_link_group; + catch (\Exception $e) { + \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); } - - if (!$paragraph->get('field_wwyltd_more_services')->isEmpty()) { - $more_paragraphs = $paragraph->get('field_wwyltd_more_services') - ->referencedEntities(); - - foreach ($more_paragraphs as $more_paragraph) { - if (!$more_paragraph->get('field_links_documents')->isEmpty()) { - $link_group_links = $more_paragraph->get('field_links_documents') - ->referencedEntities(); - - // Create a new flexible_link_group paragraph. - $flexible_link_group = Paragraph::create([ - 'type' => 'flexible_link_group', - ]); - - $flexible_link_group->set('field_featured', 0); - $flexible_link_group->set('field_display_type', 'links'); - $flexible_link_group->set('field_group_expanded', 1); - if (!$more_paragraph->get('field_section_title')->isEmpty()) { - $title = $more_paragraph->get('field_section_title')->value; - $flexible_link_group->set('field_flexible_link_group_title', $title); + if (!$node->isLatestRevision()) { + $storage = \Drupal::entityTypeManager()->getStorage('node'); + $query = $storage->getQuery()->accessCheck(FALSE); + $query->condition('nid', $node->id()); + $query->latestRevision(); + $rids = $query->execute(); + foreach ($rids as $rid) { + $latest_revision = $storage->loadRevision($rid); + if (isset($latest_revision)) { + try { + mass_content_org_wwyltd_flexible_links_helper($latest_revision, $parent, $paragraph); + } + catch (\Exception $e) { + \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); } - $flexible_link_group->set('field_link_group', $link_group_links); - $flexible_link_group->save(); - $flexible_link_groups[] = $flexible_link_group; } } } - - if ($flexible_link_groups) { - $new_org_section_long_form_paragraph = Paragraph::create([ - 'type' => 'org_section_long_form', - ]); - $new_org_section_long_form_paragraph->set('field_section_long_form_content', $flexible_link_groups); - if (!$paragraph->get('field_wwyltd_heading')->isEmpty()) { - $heading = $paragraph->get('field_wwyltd_heading')->value; - $new_org_section_long_form_paragraph->set('field_section_long_form_heading', $heading); - } - $new_org_section_long_form_paragraph->set('field_hide_heading', 0); - - // Save the new paragraph. - $new_org_section_long_form_paragraph->save(); - // Create a value array for the new section paragraph. - $new_org_section_long_form_paragraph_value = [ - 'target_id' => $new_org_section_long_form_paragraph->id(), - 'target_revision_id' => $new_org_section_long_form_paragraph->getRevisionId(), - ]; - if (isset($section_index)) { - $items[$section_index] = $new_org_section_long_form_paragraph_value; - } - else { - $items[] = $new_org_section_long_form_paragraph_value; - } - - $node->set('field_organization_sections', $items); - // Save the node. - // Save without updating the last modified date. This requires a core patch - // from the issue: https://www.drupal.org/project/drupal/issues/2329253. - $node->setSyncing(TRUE); - $node->save(); - $paragraph->delete(); - dump($node->id()); - } } } } @@ -1089,7 +1011,116 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { $sandbox['#finished'] = empty($sandbox['max']) ? 1 : ($sandbox['progress'] / $sandbox['max']); if ($sandbox['#finished'] >= 1) { + \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); return t('Migrate "What would you like to do" to flexible links. Processed @total items.', ['@total' => $sandbox['progress']]); } return "Processed {$sandbox['progress']} items."; } + +/** + * Helper function to call during migration. + */ +function mass_content_org_wwyltd_flexible_links_helper ($node, $parent, $paragraph) { + $node_field_name = $parent->parent_field_name->value; + + $items = $node->get($node_field_name)->getValue(); + foreach ($items as $index => $item) { + if ($item['target_id'] == $parent->id() && $item['target_revision_id'] == $parent->getRevisionId()) { + $section_index = $index; + break; + } + } + + $flexible_link_groups = []; + if (!$paragraph->get('field_wwyltd_top_s_links')->isEmpty()) { + $top_links = $paragraph->get('field_wwyltd_top_s_links') + ->getValue(); + + $link_group_links = []; + foreach ($top_links as $link) { + // Create a new link_group_link paragraph. + $link_group_link = Paragraph::create([ + 'type' => 'link_group_link', + ]); + + $link_group_link->set('field_link_group_link', $link); + $link_group_link->save(); + $link_group_links[] = $link_group_link; + } + + + // Create a new flexible_link_group paragraph. + $flexible_link_group = Paragraph::create([ + 'type' => 'flexible_link_group', + ]); + + $flexible_link_group->set('field_featured', 1); + $flexible_link_group->set('field_display_type', 'buttons'); + // 2 = Buttons. + $flexible_link_group->set('field_link_group', $link_group_links); + $flexible_link_group->save(); + $flexible_link_groups[] = $flexible_link_group; + } + + if (!$paragraph->get('field_wwyltd_more_services')->isEmpty()) { + $more_paragraphs = $paragraph->get('field_wwyltd_more_services') + ->referencedEntities(); + + foreach ($more_paragraphs as $more_paragraph) { + if (!$more_paragraph->get('field_links_documents')->isEmpty()) { + $link_group_links = $more_paragraph->get('field_links_documents') + ->referencedEntities(); + + // Create a new flexible_link_group paragraph. + $flexible_link_group = Paragraph::create([ + 'type' => 'flexible_link_group', + ]); + + $flexible_link_group->set('field_featured', 0); + $flexible_link_group->set('field_display_type', 'links'); + $flexible_link_group->set('field_group_expanded', 1); + if (!$more_paragraph->get('field_section_title')->isEmpty()) { + $title = $more_paragraph->get('field_section_title')->value; + $flexible_link_group->set('field_flexible_link_group_title', $title); + } + $flexible_link_group->set('field_link_group', $link_group_links); + $flexible_link_group->save(); + $flexible_link_groups[] = $flexible_link_group; + } + } + } + + if ($flexible_link_groups) { + $new_org_section_long_form_paragraph = Paragraph::create([ + 'type' => 'org_section_long_form', + ]); + $new_org_section_long_form_paragraph->set('field_section_long_form_content', $flexible_link_groups); + if (!$paragraph->get('field_wwyltd_heading')->isEmpty()) { + $heading = $paragraph->get('field_wwyltd_heading')->value; + $new_org_section_long_form_paragraph->set('field_section_long_form_heading', $heading); + } + $new_org_section_long_form_paragraph->set('field_hide_heading', 0); + + // Save the new paragraph. + $new_org_section_long_form_paragraph->save(); + // Create a value array for the new section paragraph. + $new_org_section_long_form_paragraph_value = [ + 'target_id' => $new_org_section_long_form_paragraph->id(), + 'target_revision_id' => $new_org_section_long_form_paragraph->getRevisionId(), + ]; + if (isset($section_index)) { + $items[$section_index] = $new_org_section_long_form_paragraph_value; + } + else { + $items[] = $new_org_section_long_form_paragraph_value; + } + + $node->set('field_organization_sections', $items); + // Save the node. + // Save without updating the last modified date. This requires a core patch + // from the issue: https://www.drupal.org/project/drupal/issues/2329253. + $node->setSyncing(TRUE); + $node->save(); + $paragraph->delete(); + } +} From 4ed5998836ffb99524e1395b4a94fc0c72df4018 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Wed, 2 Aug 2023 15:23:40 +0400 Subject: [PATCH 06/32] Draft --- changelogs/DP-29020.yml | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 changelogs/DP-29020.yml diff --git a/changelogs/DP-29020.yml b/changelogs/DP-29020.yml new file mode 100644 index 0000000000..9ff84d0a87 --- /dev/null +++ b/changelogs/DP-29020.yml @@ -0,0 +1,41 @@ +# +# Write your changelog entry here. Every pull request must have a changelog yml file. +# +# Change types: +# ############################################################################# +# You can use one of the following types: +# - Added: For new features. +# - Changed: For changes to existing functionality. +# - Deprecated: For soon-to-be removed features. +# - Removed: For removed features. +# - Fixed: For any bug fixes. +# - Security: In case of vulnerabilities. +# +# Format +# ############################################################################# +# The format is crucial. Please follow the examples below. For reference, the requirements are: +# - All 3 parts are required and you must include "Type", "description" and "issue". +# - "Type" must be left aligned and followed by a colon. +# - "description" must be indented with 2 spaces followed by a colon +# - "issue" must be indented with 4 spaces followed by a colon. +# - "issue" is for the Jira ticket number only e.g. DP-1234 +# - No extra spaces, indents, or blank lines are allowed. +# +# Example: +# ############################################################################# +# Fixed: +# - description: Fixes scrolling on edit pages in Safari. +# issue: DP-13314 +# +# You may add more than 1 description & issue for each type using the following format: +# Changed: +# - description: Automating the release branch. +# issue: DP-10166 +# - description: Second change item that needs a description. +# issue: DP-19875 +# - description: Third change item that needs a description along with an issue. +# issue: DP-19843 +# +Changed: + - description: Convert org page paragraph "What would you like to do" to use service page component "Flexible link group". + issue: DP-29020 From 471f805268cd7219967eecf9c45c9bbf26a04215 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Wed, 2 Aug 2023 15:26:13 +0400 Subject: [PATCH 07/32] Draft --- ....org_section_long_form.field_section_long_form_content.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml b/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml index e50371d02c..cd72bdb98b 100644 --- a/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml +++ b/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml @@ -29,7 +29,6 @@ dependencies: - paragraphs.paragraphs_type.stat - paragraphs.paragraphs_type.tableau_embed - paragraphs.paragraphs_type.video - - paragraphs.paragraphs_type.what_would_you_like_to_do module: - entity_reference_revisions id: paragraph.org_section_long_form.field_section_long_form_content @@ -68,7 +67,6 @@ settings: stat: stat tableau_embed: tableau_embed video: video - what_would_you_like_to_do: what_would_you_like_to_do collection_search: collection_search flexible_link_group: flexible_link_group negate: 0 @@ -468,5 +466,5 @@ settings: enabled: false what_would_you_like_to_do: weight: 22 - enabled: true + enabled: false field_type: entity_reference_revisions From 7fa8ed3bd02f4bd162b65387eed099d26edb1dc8 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Wed, 2 Aug 2023 15:29:40 +0400 Subject: [PATCH 08/32] Draft --- docroot/modules/custom/mass_content/mass_content.deploy.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 2027415230..7560d7f1c8 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -1120,6 +1120,8 @@ function mass_content_org_wwyltd_flexible_links_helper ($node, $parent, $paragra // Save without updating the last modified date. This requires a core patch // from the issue: https://www.drupal.org/project/drupal/issues/2329253. $node->setSyncing(TRUE); + $node->revision_log = "Bulk automated change of ‘what would you like to do’ component to ‘flexible link group’"; + $node->setRevisionCreationTime(\Drupal::time()->getCurrentTime()); $node->save(); $paragraph->delete(); } From d95917b390f186e0e9be15f119b151e50e19d32c Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Wed, 2 Aug 2023 15:30:19 +0400 Subject: [PATCH 09/32] Draft --- docroot/modules/custom/mass_content/mass_content.deploy.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 7560d7f1c8..95b994aee2 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -1020,7 +1020,7 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { /** * Helper function to call during migration. */ -function mass_content_org_wwyltd_flexible_links_helper ($node, $parent, $paragraph) { +function mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragraph) { $node_field_name = $parent->parent_field_name->value; $items = $node->get($node_field_name)->getValue(); @@ -1048,7 +1048,6 @@ function mass_content_org_wwyltd_flexible_links_helper ($node, $parent, $paragra $link_group_links[] = $link_group_link; } - // Create a new flexible_link_group paragraph. $flexible_link_group = Paragraph::create([ 'type' => 'flexible_link_group', From b77765debc232e627a28e331250a04307fd0a846 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Thu, 3 Aug 2023 13:57:01 +0400 Subject: [PATCH 10/32] Final changes --- .../mass_content/mass_content.deploy.php | 37 ++++- test.php | 136 ------------------ 2 files changed, 34 insertions(+), 139 deletions(-) delete mode 100644 test.php diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 95b994aee2..07808c4e31 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -969,11 +969,12 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { // Turn off entity_hierarchy writes while processing the item. \Drupal::state()->set('entity_hierarchy_disable_writes', TRUE); - $paragraphs = $storage->loadMultiple($pids); + $memory_cache = \Drupal::service('entity.memory_cache'); + $paragraphs = $storage->loadMultiple($pids); foreach ($paragraphs as $paragraph) { + $sandbox['current'] = $paragraph->id(); if ($paragraph) { - $parent_field_name = $paragraph->parent_field_name->value; if ($parent = $paragraph->getParentEntity()) { if ($parent instanceof \Drupal\paragraphs\Entity\Paragraph && $parent->bundle() == 'org_section_long_form') { if ($parent->getParentEntity() instanceof \Drupal\node\Entity\Node) { @@ -1009,6 +1010,8 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { $sandbox['progress']++; } + $memory_cache->deleteAll(); + $sandbox['#finished'] = empty($sandbox['max']) ? 1 : ($sandbox['progress'] / $sandbox['max']); if ($sandbox['#finished'] >= 1) { \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); @@ -1022,6 +1025,18 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { */ function mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragraph) { $node_field_name = $parent->parent_field_name->value; + $parent_field_name = $paragraph->parent_field_name->value; + if ($parent = $paragraph->getParentEntity()) { + $content_items = $parent->get($parent_field_name)->getValue(); + if ($parent->get($parent_field_name)->count() > 1) { + foreach ($content_items as $i => $content_item) { + if ($content_item['target_id'] == $paragraph->id() && $content_item['target_revision_id'] == $paragraph->getRevisionId()) { + $content_index = $i; + break; + } + } + } + } $items = $node->get($node_field_name)->getValue(); foreach ($items as $index => $item) { @@ -1093,7 +1108,23 @@ function mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragrap $new_org_section_long_form_paragraph = Paragraph::create([ 'type' => 'org_section_long_form', ]); - $new_org_section_long_form_paragraph->set('field_section_long_form_content', $flexible_link_groups); + if (isset($content_index)) { + $result = []; + foreach ($content_items as $index => $content_item) { + if ($index == $content_index) { + foreach ($flexible_link_groups as $flexible_link_group) { + $result[] = $flexible_link_group; + } + } + else { + $result[] = $content_item; + } + } + $new_org_section_long_form_paragraph->set('field_section_long_form_content', $result); + } + else { + $new_org_section_long_form_paragraph->set('field_section_long_form_content', $flexible_link_groups); + } if (!$paragraph->get('field_wwyltd_heading')->isEmpty()) { $heading = $paragraph->get('field_wwyltd_heading')->value; $new_org_section_long_form_paragraph->set('field_section_long_form_heading', $heading); diff --git a/test.php b/test.php deleted file mode 100644 index 1b530df5ea..0000000000 --- a/test.php +++ /dev/null @@ -1,136 +0,0 @@ -accessCheck(FALSE)->condition('type','what_would_you_like_to_do')->execute(); - -$parapgrahs = \Drupal\paragraphs\Entity\Paragraph::loadMultiple($ids); - -foreach ($parapgrahs as $parapgrah) { - - if ($parapgrah->id()) { - $parent_field_name = $parapgrah->parent_field_name->value; - - if ($parent = $parapgrah->getParentEntity()) { - if ($parent instanceof \Drupal\paragraphs\Entity\Paragraph && $parent->bundle() == 'org_section_long_form') { - if ($parent->getParentEntity() instanceof \Drupal\node\Entity\Node) { - $node = $parent->getParentEntity(); - $node_field_name = $parent->parent_field_name->value; - - $items = $node->get($node_field_name)->getValue(); - foreach ($items as $index => $item) { - if ($item['target_id'] == $parent->id() && $item['target_revision_id'] == $parent->getRevisionId()) { - $section_index = $index; - break; - } - } - - $flexible_link_groups = []; - if (!$parapgrah->get('field_wwyltd_top_s_links')->isEmpty()) { - $top_links = $parapgrah->get('field_wwyltd_top_s_links')->getValue(); - - $link_group_links = []; - foreach ($top_links as $link) { - // Create a new link_group_link paragraph. - $link_group_link = Paragraph::create([ - 'type' => 'link_group_link', - ]); - - $link_group_link->set('field_link_group_link', $link); - $link_group_link->save(); - $link_group_links[] = $link_group_link; - } - - - // Create a new flexible_link_group paragraph. - $flexible_link_group = Paragraph::create([ - 'type' => 'flexible_link_group', - ]); - - $flexible_link_group->set('field_featured', 1); - $flexible_link_group->set('field_display_type', 'buttons'); - // 2 = Buttons. - $flexible_link_group->set('field_link_group', $link_group_links); - $flexible_link_group->save(); - $flexible_link_groups[] = $flexible_link_group; - } - - if (!$parapgrah->get('field_wwyltd_more_services')->isEmpty()) { - $more_paragraphs = $parapgrah->get('field_wwyltd_more_services')->referencedEntities(); - - foreach ($more_paragraphs as $more_paragraph) { - if (!$more_paragraph->get('field_links_documents')->isEmpty()) { - $link_group_links = $more_paragraph->get('field_links_documents') - ->referencedEntities(); - - // Create a new flexible_link_group paragraph. - $flexible_link_group = Paragraph::create([ - 'type' => 'flexible_link_group', - ]); - - $flexible_link_group->set('field_featured', 0); - $flexible_link_group->set('field_display_type', 'links'); - $flexible_link_group->set('field_group_expanded', 1); - if (!$more_paragraph->get('field_section_title')->isEmpty()) { - $title = $more_paragraph->get('field_section_title')->value; - $flexible_link_group->set('field_flexible_link_group_title', $title); - } - $flexible_link_group->set('field_link_group', $link_group_links); - $flexible_link_group->save(); - $flexible_link_groups[] = $flexible_link_group; - } - } - } - - if ($flexible_link_groups) { - $new_org_section_long_form_paragraph = Paragraph::create([ - 'type' => 'org_section_long_form', - ]); - $new_org_section_long_form_paragraph->set('field_section_long_form_content', $flexible_link_groups); - if (!$parapgrah->get('field_wwyltd_heading')->isEmpty()) { - $heading = $parapgrah->get('field_wwyltd_heading')->value; - $new_org_section_long_form_paragraph->set('field_section_long_form_heading', $heading); - } - $new_org_section_long_form_paragraph->set('field_hide_heading', 0); - - // Save the new paragraph. - $new_org_section_long_form_paragraph->save(); - // Create a value array for the new section paragraph. - $new_org_section_long_form_paragraph_value = [ - 'target_id' => $new_org_section_long_form_paragraph->id(), - 'target_revision_id' => $new_org_section_long_form_paragraph->getRevisionId(), - ]; - if (isset($section_index)) { - $items[$section_index] = $new_org_section_long_form_paragraph_value; - } - else { - $items[] = $new_org_section_long_form_paragraph_value; - } - - $node->set('field_organization_sections', $items); - // Save the node. - // Save without updating the last modified date. This requires a core patch - // from the issue: https://www.drupal.org/project/drupal/issues/2329253. - $node->setSyncing(TRUE); - $node->save(); - $parapgrah->delete(); - dump($node->id()); - exit; - } -// $items = $node->get($parent_field_name)->getValue(); -// foreach ($items as $index => $item) { -// if ($item['target_id'] == $parapgrah->id() && $item['target_revision_id'] == $parapgrah->getRevisionId()) { -// $paragraph_index = $index; -// break; -// } -// } -// -// dump($parent->get($parent_field_name)->offsetGet($paragraph_index)->toArray()); - // offsetset to the same index with the new data and paragraph - } - } - } - } -} From c00de3acc64a4daa1ef31eac37ca44748c650876 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Mon, 14 Aug 2023 13:24:43 +0400 Subject: [PATCH 11/32] Feedback fix --- .../mass_content/mass_content.deploy.php | 1 + .../themes/custom/mass_theme/mass_theme.theme | 32 +++++++++++++++++-- 2 files changed, 30 insertions(+), 3 deletions(-) diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 07808c4e31..29d541c86f 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -1129,6 +1129,7 @@ function mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragrap $heading = $paragraph->get('field_wwyltd_heading')->value; $new_org_section_long_form_paragraph->set('field_section_long_form_heading', $heading); } + $new_org_section_long_form_paragraph->set('field_section_style', 'enhanced'); $new_org_section_long_form_paragraph->set('field_hide_heading', 0); // Save the new paragraph. diff --git a/docroot/themes/custom/mass_theme/mass_theme.theme b/docroot/themes/custom/mass_theme/mass_theme.theme index abc37d9e56..4a45c17f06 100644 --- a/docroot/themes/custom/mass_theme/mass_theme.theme +++ b/docroot/themes/custom/mass_theme/mass_theme.theme @@ -7258,12 +7258,38 @@ function mass_theme_preprocess_paragraph__org_section_long_form(&$variables) { $variables['section_style'] = $container->field_section_style->value; $variables["org_components"] = _mass_theme_preprocess_paragraph_sections($variables, 'field_section_long_form_content'); + $links_group = []; + foreach ($variables['org_components'] as $key => &$org_component) { + /** @var Drupal\paragraphs\Entity\Paragraph */ + $org_component_paragraph = &$org_component[0]; + if ( + is_object($org_component_paragraph) && + $org_component_paragraph->getType() == 'flexible_link_group' && + $org_component_paragraph->field_display_type->value == 'links' + ) { + $links_group[$key] = $org_component; + } + else { + _mass_theme_join_contiguous_flexible_link_group_type_links($links_group, $variables, 'org'); + $links_group = []; + } + } + + _mass_theme_join_contiguous_flexible_link_group_type_links($links_group, $variables, 'org'); + + // Removing elements included previously. + foreach ($variables['org_components'] as $key => &$org_component) { + if ($org_component === FALSE) { + unset($variables['org_components'][$key]); + } + } } /** * Join contiguous flexible link groups, type links, into the same element. */ -function _mass_theme_join_contiguous_flexible_link_group_type_links(&$links_group, &$variables) { +function _mass_theme_join_contiguous_flexible_link_group_type_links(&$links_group, &$variables, $destination = 'service') { + $component_name = $destination . '_components'; if (count($links_group) < 2) { return; } @@ -7273,10 +7299,10 @@ function _mass_theme_join_contiguous_flexible_link_group_type_links(&$links_grou continue; } - $variables['service_components'][$first][0]->subsequent_links[] = $link_group[0]; + $variables[$component_name][$first][0]->subsequent_links[] = $link_group[0]; // Empty elements included previously. - $variables['service_components'][$key] = FALSE; + $variables[$component_name][$key] = FALSE; } $links_group = []; } From 314ecb485d756f1babe6619f6667b457cec4371e Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Mon, 14 Aug 2023 13:41:38 +0400 Subject: [PATCH 12/32] Feedback fix --- .../mass_theme/mass_theme.libraries.yml | 2 +- .../themes/custom/mass_theme/mass_theme.theme | 1 + .../css/{service-section.css => sections.css} | 21 +++++++++++++++---- ...--org-section-long-form--default.html.twig | 5 +++-- 4 files changed, 22 insertions(+), 7 deletions(-) rename docroot/themes/custom/mass_theme/overrides/css/{service-section.css => sections.css} (63%) diff --git a/docroot/themes/custom/mass_theme/mass_theme.libraries.yml b/docroot/themes/custom/mass_theme/mass_theme.libraries.yml index 4e9b318ef0..d057325f90 100644 --- a/docroot/themes/custom/mass_theme/mass_theme.libraries.yml +++ b/docroot/themes/custom/mass_theme/mass_theme.libraries.yml @@ -21,7 +21,7 @@ global-styling: overrides/css/contained.css: {} overrides/css/campaign_landing.css: {} overrides/css/flexible-link-group.css: {} - overrides/css/service-section.css: {} + overrides/css/sections.css: {} overrides/css/news-page.css: {} overrides/css/language-bar.css: {} js: diff --git a/docroot/themes/custom/mass_theme/mass_theme.theme b/docroot/themes/custom/mass_theme/mass_theme.theme index 4a45c17f06..98fc797936 100644 --- a/docroot/themes/custom/mass_theme/mass_theme.theme +++ b/docroot/themes/custom/mass_theme/mass_theme.theme @@ -7256,6 +7256,7 @@ function mass_theme_preprocess_paragraph__org_section_long_form(&$variables) { $container = $variables['paragraph']; $variables['section_style'] = $container->field_section_style->value; + $variables['hide_heading'] = $container->field_hide_heading->value; $variables["org_components"] = _mass_theme_preprocess_paragraph_sections($variables, 'field_section_long_form_content'); $links_group = []; diff --git a/docroot/themes/custom/mass_theme/overrides/css/service-section.css b/docroot/themes/custom/mass_theme/overrides/css/sections.css similarity index 63% rename from docroot/themes/custom/mass_theme/overrides/css/service-section.css rename to docroot/themes/custom/mass_theme/overrides/css/sections.css index 75fcaa868a..ce8dafe9f2 100644 --- a/docroot/themes/custom/mass_theme/overrides/css/service-section.css +++ b/docroot/themes/custom/mass_theme/overrides/css/sections.css @@ -1,12 +1,15 @@ +.org-section, .service-section { overflow: hidden; } +.org-section--enhanced, .service-section--enhanced { background-image: -o-linear-gradient(top, white 50px, #F2F2F2 51px); background: linear-gradient(180deg, white 50px, #F2F2F2 51px); } +.org-section--enhanced > section > header, .service-section--enhanced > section > header { margin-right: auto; margin-left: auto; @@ -15,22 +18,28 @@ padding-right: 40px; } +.org-section .ma__collapsible-header__title, .service-section .ma__collapsible-header__title { font-size: 2rem; } +.org-section .ma__callout-links-three-up h3, .service-section .ma__callout-links-three-up h3 { margin-bottom: 0; } +.org-section .ma__callout-links-three-up p, .service-section .ma__callout-links-three-up p { margin-top: 0.5rem; } +.org-section .ma__callout-links-three-up__container, .service-section .ma__callout-links-three-up__container { margin-top: 2rem; } +.org-section--hidden-title > section > header, +.org-section--hidden-title > section > .ma__stacked-row__container, .service-section--hidden-title > section > header, .service-section--hidden-title > section > .ma__stacked-row__container { position: absolute; @@ -43,32 +52,36 @@ border: 0; } +.org-section--enhanced.org-section--hidden-title, .service-section--enhanced.service-section--hidden-title { background: #F2F2F2; padding-top: 40px; } -.service-section -.ma__collapsible-content__body -.ma__collapsible-content__body-item { +.org-section .ma__collapsible-content__body .ma__collapsible-content__body-item, +.service-section .ma__collapsible-content__body .ma__collapsible-content__body-item { margin: 0.5rem 0; display: block; } +.org-section--enhanced + .org-section--simple .ma__stacked-row__section .ma__stacked-row__container:before, .service-section--enhanced + .service-section--simple .ma__stacked-row__section .ma__stacked-row__container:before { border-color: transparent; } +.org-section .ma__stacked-row__container:before, .service-section .ma__stacked-row__container:before { border-color: transparent !important; } +.org-section--enhanced + .org-section--enhanced.org-section--hidden-title, .service-section--enhanced + .service-section--enhanced.service-section--hidden-title { margin-top: 0 !important; padding-top: 0 !important; } +.org-section .ma__stacked-row__section .main-content, .service-section .ma__stacked-row__section .main-content { margin-bottom: 30px; -} \ No newline at end of file +} diff --git a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig index 6c80bc9c58..87e3a8140c 100644 --- a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig +++ b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig @@ -7,9 +7,10 @@ } %} {% endif %} -{% set section_style_class = section_style == 'enhanced' ? 'service-section--enhanced' : 'service-section--simple' %} +{% set section_style_class = section_style == 'enhanced' ? 'org-section--enhanced' : 'org-section--simple' %} +{% set hide_title_class = hide_heading ? 'org-section--hidden-title' : '' %} -
+
{% embed "@organisms/by-author/stacked-row-section.twig" with { "stackedRowSection": heading, "stackedRow": { From 24b55e8df3ddef0448e8dbd598182bc33b9a22bb Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Tue, 15 Aug 2023 13:03:20 +0400 Subject: [PATCH 13/32] Styling fixes --- docroot/themes/custom/mass_theme/overrides/css/sections.css | 5 ++++- .../paragraph--org-section-long-form--default.html.twig | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/docroot/themes/custom/mass_theme/overrides/css/sections.css b/docroot/themes/custom/mass_theme/overrides/css/sections.css index ce8dafe9f2..14807a2f56 100644 --- a/docroot/themes/custom/mass_theme/overrides/css/sections.css +++ b/docroot/themes/custom/mass_theme/overrides/css/sections.css @@ -81,7 +81,10 @@ } -.org-section .ma__stacked-row__section .main-content, +.org-section .ma__stacked-row__section .main-content { + margin-bottom: 0; +} + .service-section .ma__stacked-row__section .main-content { margin-bottom: 30px; } diff --git a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig index 87e3a8140c..18d676014c 100644 --- a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig +++ b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig @@ -24,7 +24,7 @@ {% if section_style == 'enhanced' %} {% include "@atoms/04-headings/colored-heading-from-left.twig" with { "coloredHeadingFromLeft": { - "bgColor": "blue", + "bgColor": "green", "title": (content.field_section_long_form_heading|field_value) }} %} From bd5ff220cdab4738aca9e7bc5d44a7da101e57aa Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Tue, 15 Aug 2023 14:38:15 +0400 Subject: [PATCH 14/32] Styling fixes --- .../themes/custom/mass_theme/overrides/css/sections.css | 7 +------ .../paragraph--org-section-long-form--default.html.twig | 4 ++-- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/docroot/themes/custom/mass_theme/overrides/css/sections.css b/docroot/themes/custom/mass_theme/overrides/css/sections.css index 14807a2f56..d66937cf05 100644 --- a/docroot/themes/custom/mass_theme/overrides/css/sections.css +++ b/docroot/themes/custom/mass_theme/overrides/css/sections.css @@ -1,4 +1,3 @@ -.org-section, .service-section { overflow: hidden; } @@ -80,11 +79,7 @@ padding-top: 0 !important; } - -.org-section .ma__stacked-row__section .main-content { - margin-bottom: 0; -} - +.org-section .ma__stacked-row__section .main-content, .service-section .ma__stacked-row__section .main-content { margin-bottom: 30px; } diff --git a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig index 18d676014c..58af4b672a 100644 --- a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig +++ b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig @@ -10,7 +10,7 @@ {% set section_style_class = section_style == 'enhanced' ? 'org-section--enhanced' : 'org-section--simple' %} {% set hide_title_class = hide_heading ? 'org-section--hidden-title' : '' %} -
+
{% embed "@organisms/by-author/stacked-row-section.twig" with { "stackedRowSection": heading, "stackedRow": { @@ -74,4 +74,4 @@ {% endembed %} {{ content.field_section_long_form_addition }} -
+ From 9f2fe75e22931735faf8d818698095cbee07ada6 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Tue, 15 Aug 2023 14:59:10 +0400 Subject: [PATCH 15/32] Styling fixes --- docroot/themes/custom/mass_theme/overrides/css/sections.css | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/docroot/themes/custom/mass_theme/overrides/css/sections.css b/docroot/themes/custom/mass_theme/overrides/css/sections.css index d66937cf05..86018af48f 100644 --- a/docroot/themes/custom/mass_theme/overrides/css/sections.css +++ b/docroot/themes/custom/mass_theme/overrides/css/sections.css @@ -79,7 +79,10 @@ padding-top: 0 !important; } -.org-section .ma__stacked-row__section .main-content, +.org-section.org-section--enhanced .ma__stacked-row__section .main-content { + padding-bottom: 30px; +} + .service-section .ma__stacked-row__section .main-content { margin-bottom: 30px; } From 848e582710e672fcf951f933937af4ee33f00fc8 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Tue, 15 Aug 2023 21:01:17 +0400 Subject: [PATCH 16/32] Orphan paragraph fix --- .../custom/mass_content/mass_content.deploy.php | 13 ++++++++----- docroot/themes/custom/mass_theme/mass_theme.theme | 4 +++- 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 29d541c86f..968810801a 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -9,6 +9,7 @@ use Drupal\Core\Datetime\DrupalDateTime; use Drupal\Core\Link; use Drupal\Core\Url; +use Drupal\mayflower\Helper; use Drupal\paragraphs\Entity\Paragraph; use Drupal\taxonomy\Entity\Term; @@ -928,8 +929,10 @@ function mass_content_deploy_org_section_style(&$sandbox) { foreach ($paragraphs as $paragraph) { $sandbox['current'] = $paragraph->id(); - $paragraph->set('field_section_style', 'simple'); - $paragraph->save(); + if (!Helper::isParagraphOrphan($paragraph)) { + $paragraph->set('field_section_style', 'simple'); + $paragraph->save(); + } $sandbox['progress']++; } @@ -974,10 +977,10 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { $paragraphs = $storage->loadMultiple($pids); foreach ($paragraphs as $paragraph) { $sandbox['current'] = $paragraph->id(); - if ($paragraph) { + if ($paragraph && !Helper::isParagraphOrphan($paragraph)) { if ($parent = $paragraph->getParentEntity()) { - if ($parent instanceof \Drupal\paragraphs\Entity\Paragraph && $parent->bundle() == 'org_section_long_form') { - if ($parent->getParentEntity() instanceof \Drupal\node\Entity\Node) { + if ($parent instanceof Paragraph && $parent->bundle() == 'org_section_long_form') { + if ($parent->getParentEntity() instanceof Node) { $node = $parent->getParentEntity(); try { mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragraph); diff --git a/docroot/themes/custom/mass_theme/mass_theme.theme b/docroot/themes/custom/mass_theme/mass_theme.theme index 98fc797936..bfcf02fd1b 100644 --- a/docroot/themes/custom/mass_theme/mass_theme.theme +++ b/docroot/themes/custom/mass_theme/mass_theme.theme @@ -7255,7 +7255,9 @@ function _mass_theme_preprocess_paragraph_sections(&$variables, $field) { function mass_theme_preprocess_paragraph__org_section_long_form(&$variables) { $container = $variables['paragraph']; - $variables['section_style'] = $container->field_section_style->value; + if (!$container->field_section_style->isEmpty()) { + $variables['section_style'] = $container->field_section_style->value; + } $variables['hide_heading'] = $container->field_hide_heading->value; $variables["org_components"] = _mass_theme_preprocess_paragraph_sections($variables, 'field_section_long_form_content'); From ec409c0c629e75fc8c29533c626c4321fe053640 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Tue, 15 Aug 2023 22:19:39 +0400 Subject: [PATCH 17/32] Orphan paragraph fix --- .../mass_content/mass_content.deploy.php | 52 ++++++++++--------- .../mass_theme/overrides/css/sections.css | 1 - 2 files changed, 27 insertions(+), 26 deletions(-) diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 968810801a..2e57f33814 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -10,6 +10,7 @@ use Drupal\Core\Link; use Drupal\Core\Url; use Drupal\mayflower\Helper; +use Drupal\node\Entity\Node; use Drupal\paragraphs\Entity\Paragraph; use Drupal\taxonomy\Entity\Term; @@ -977,31 +978,32 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { $paragraphs = $storage->loadMultiple($pids); foreach ($paragraphs as $paragraph) { $sandbox['current'] = $paragraph->id(); - if ($paragraph && !Helper::isParagraphOrphan($paragraph)) { - if ($parent = $paragraph->getParentEntity()) { - if ($parent instanceof Paragraph && $parent->bundle() == 'org_section_long_form') { - if ($parent->getParentEntity() instanceof Node) { - $node = $parent->getParentEntity(); - try { - mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragraph); - } - catch (\Exception $e) { - \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); - } - if (!$node->isLatestRevision()) { - $storage = \Drupal::entityTypeManager()->getStorage('node'); - $query = $storage->getQuery()->accessCheck(FALSE); - $query->condition('nid', $node->id()); - $query->latestRevision(); - $rids = $query->execute(); - foreach ($rids as $rid) { - $latest_revision = $storage->loadRevision($rid); - if (isset($latest_revision)) { - try { - mass_content_org_wwyltd_flexible_links_helper($latest_revision, $parent, $paragraph); - } - catch (\Exception $e) { - \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); + if ($paragraph instanceof Paragraph) { + if (!Helper::isParagraphOrphan($paragraph)) { + if ($parent = $paragraph->getParentEntity()) { + if ($parent instanceof Paragraph && $parent->bundle() == 'org_section_long_form') { + if ($parent->getParentEntity() instanceof Node) { + $node = $parent->getParentEntity(); + try { + mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragraph); + } catch (\Exception $e) { + \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); + } + if (!$node->isLatestRevision()) { + $storage = \Drupal::entityTypeManager()->getStorage('node'); + $query = $storage->getQuery()->accessCheck(FALSE); + $query->condition('nid', $node->id()); + $query->latestRevision(); + $rids = $query->execute(); + foreach ($rids as $rid) { + $latest_revision = $storage->loadRevision($rid); + if (isset($latest_revision)) { + try { + mass_content_org_wwyltd_flexible_links_helper($latest_revision, $parent, $paragraph); + } catch (\Exception $e) { + \Drupal::state() + ->set('entity_hierarchy_disable_writes', FALSE); + } } } } diff --git a/docroot/themes/custom/mass_theme/overrides/css/sections.css b/docroot/themes/custom/mass_theme/overrides/css/sections.css index 86018af48f..b52db0d1a8 100644 --- a/docroot/themes/custom/mass_theme/overrides/css/sections.css +++ b/docroot/themes/custom/mass_theme/overrides/css/sections.css @@ -17,7 +17,6 @@ padding-right: 40px; } -.org-section .ma__collapsible-header__title, .service-section .ma__collapsible-header__title { font-size: 2rem; } From eda28f71260094fee499b81c02d5d7177eb58755 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Tue, 15 Aug 2023 23:13:00 +0400 Subject: [PATCH 18/32] Deploy hook fix --- .../modules/custom/mass_content/mass_content.deploy.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 2e57f33814..71ab34916b 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -1097,7 +1097,13 @@ function mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragrap $flexible_link_group->set('field_featured', 0); $flexible_link_group->set('field_display_type', 'links'); - $flexible_link_group->set('field_group_expanded', 1); + $flexible_link_group->set('field_group_expanded', $more_paragraph->get('field_group_expanded')->value); + if (!$more_paragraph->get('field_group_expanded')->isEmpty()) { + $flexible_link_group->set('field_group_expanded', $more_paragraph->get('field_group_expanded')->value); + } + else { + $flexible_link_group->set('field_group_expanded', 1); + } if (!$more_paragraph->get('field_section_title')->isEmpty()) { $title = $more_paragraph->get('field_section_title')->value; $flexible_link_group->set('field_flexible_link_group_title', $title); From 70cbd5b9c4b23596dfbafa4cb4973bd78df5ade8 Mon Sep 17 00:00:00 2001 From: abaghdasaryan Date: Tue, 15 Aug 2023 23:15:02 +0400 Subject: [PATCH 19/32] Deploy hook fix --- docroot/modules/custom/mass_content/mass_content.deploy.php | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index 71ab34916b..c011cb2dbd 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -986,7 +986,8 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { $node = $parent->getParentEntity(); try { mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragraph); - } catch (\Exception $e) { + } + catch (\Exception $e) { \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); } if (!$node->isLatestRevision()) { @@ -1000,7 +1001,8 @@ function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { if (isset($latest_revision)) { try { mass_content_org_wwyltd_flexible_links_helper($latest_revision, $parent, $paragraph); - } catch (\Exception $e) { + } + catch (\Exception $e) { \Drupal::state() ->set('entity_hierarchy_disable_writes', FALSE); } From f50c7bbd8e21e2aff41636795a5af049b17da87b Mon Sep 17 00:00:00 2001 From: Moshe Weitzman Date: Fri, 1 Sep 2023 12:33:52 -0400 Subject: [PATCH 20/32] Avoid redirect to install.php when DB is down --- composer.json | 1 + composer.lock | 49 ++++++++++++++++++++++++++- conf/drupal/config/core.extension.yml | 1 + docroot/index.php | 3 +- 4 files changed, 52 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index 305cc376b3..252742bbe6 100644 --- a/composer.json +++ b/composer.json @@ -233,6 +233,7 @@ "drupal/pathologic": "^1", "drupal/prepopulate": "^2.0", "drupal/private_files_download_permission": "^3", + "drupal/prod_no_redirect": "dev-1.0.x", "drupal/purge": "^3", "drupal/purge_queues": "^2", "drupal/queue_unique": "^3", diff --git a/composer.lock b/composer.lock index 3e9e550002..144a73de24 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "df4d2f9c2d929837136d29e0c587f02c", + "content-hash": "d1f4a26ea4b89e1f3aab3ec12aa1ccc5", "packages": [ { "name": "akamai-open/edgegrid-auth", @@ -8507,6 +8507,52 @@ "source": "https://git.drupalcode.org/project/private_files_download_permission" } }, + { + "name": "drupal/prod_no_redirect", + "version": "dev-1.0.x", + "source": { + "type": "git", + "url": "https://git.drupalcode.org/project/prod_no_redirect.git", + "reference": "a50d574b2214cdc89e1b96ad38f4c26f5fbb65f1" + }, + "require": { + "drupal/core": "^9 || ^10" + }, + "type": "drupal-module", + "extra": { + "branch-alias": { + "dev-1.0.x": "1.0.x-dev" + }, + "drupal": { + "version": "1.0.x-dev", + "datestamp": "1693583408", + "security-coverage": { + "status": "not-covered", + "message": "Project has not opted into security advisory coverage!" + } + } + }, + "autoload": { + "classmap": [ + "lib" + ] + }, + "notification-url": "https://packages.drupal.org/8/downloads", + "license": [ + "GPL-2.0-or-later" + ], + "authors": [ + { + "name": "moshe weitzman", + "homepage": "https://www.drupal.org/user/23" + } + ], + "description": "Production must never redirect to install.php", + "homepage": "https://www.drupal.org/project/prod_no_redirect", + "support": { + "source": "https://git.drupalcode.org/project/prod_no_redirect" + } + }, { "name": "drupal/purge", "version": "3.4.0", @@ -23761,6 +23807,7 @@ "drupal/focal_point": 20, "drupal/openid_connect": 20, "drupal/openid_connect_windows_aad": 20, + "drupal/prod_no_redirect": 20, "drupal/require_on_publish": 20, "drupal/views_taxonomy_term_name_into_id": 15, "furf/jquery-ui-touch-punch": 20, diff --git a/conf/drupal/config/core.extension.yml b/conf/drupal/config/core.extension.yml index eff769fa1d..477597ace3 100644 --- a/conf/drupal/config/core.extension.yml +++ b/conf/drupal/config/core.extension.yml @@ -182,6 +182,7 @@ module: pathologic: 0 pfdp: 0 prepopulate: 0 + prod_no_redirect: 0 purge: 0 purge_drush: 0 purge_processor_cron: 0 diff --git a/docroot/index.php b/docroot/index.php index 750dc282dc..8dd1ccd99d 100644 --- a/docroot/index.php +++ b/docroot/index.php @@ -9,11 +9,12 @@ */ use Drupal\Core\DrupalKernel; +use Drupal\prod_no_redirect\ProdNoRedirectDrupalKernel; use Symfony\Component\HttpFoundation\Request; $autoloader = require_once 'autoload.php'; -$kernel = new DrupalKernel('prod', $autoloader); +$kernel = new ProdNoRedirectDrupalKernel('prod', $autoloader); $request = Request::createFromGlobals(); $response = $kernel->handle($request); From 768f5cfac5d4c7660c506114d3069c1ff34672d6 Mon Sep 17 00:00:00 2001 From: Moshe Weitzman Date: Fri, 1 Sep 2023 12:47:30 -0400 Subject: [PATCH 21/32] Add changelog --- changelogs/DP-29542.yml | 41 +++++++++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 changelogs/DP-29542.yml diff --git a/changelogs/DP-29542.yml b/changelogs/DP-29542.yml new file mode 100644 index 0000000000..93da16f1d7 --- /dev/null +++ b/changelogs/DP-29542.yml @@ -0,0 +1,41 @@ +# +# Write your changelog entry here. Every pull request must have a changelog yml file. +# +# Change types: +# ############################################################################# +# You can use one of the following types: +# - Added: For new features. +# - Changed: For changes to existing functionality. +# - Deprecated: For soon-to-be removed features. +# - Removed: For removed features. +# - Fixed: For any bug fixes. +# - Security: In case of vulnerabilities. +# +# Format +# ############################################################################# +# The format is crucial. Please follow the examples below. For reference, the requirements are: +# - All 3 parts are required and you must include "Type", "description" and "issue". +# - "Type" must be left aligned and followed by a colon. +# - "description" must be indented with 2 spaces followed by a colon +# - "issue" must be indented with 4 spaces followed by a colon. +# - "issue" is for the Jira ticket number only e.g. DP-1234 +# - No extra spaces, indents, or blank lines are allowed. +# +# Example: +# ############################################################################# +# Fixed: +# - description: Fixes scrolling on edit pages in Safari. +# issue: DP-13314 +# +# You may add more than 1 description & issue for each type using the following format: +# Changed: +# - description: Automating the release branch. +# issue: DP-10166 +# - description: Second change item that needs a description. +# issue: DP-19875 +# - description: Third change item that needs a description along with an issue. +# issue: DP-19843 +# +Added: + - description: Avoid redirect to install.php when DB is down + issue: From 57237147139b522d410e2cc2e439502e86333e6f Mon Sep 17 00:00:00 2001 From: joeg8612 Date: Wed, 6 Sep 2023 08:17:01 -0400 Subject: [PATCH 22/32] DP-29553 backstop removal of service details pages (#2179) * remove pages from backstop * changelog --- backstop/all.json | 2 -- backstop/post-release.json | 1 - changelogs/DP-29553.yml | 41 ++++++++++++++++++++++++++++++++++++++ 3 files changed, 41 insertions(+), 3 deletions(-) create mode 100644 changelogs/DP-29553.yml diff --git a/backstop/all.json b/backstop/all.json index b6ac910be1..b28b261506 100644 --- a/backstop/all.json +++ b/backstop/all.json @@ -55,8 +55,6 @@ {"label": "RegulationDraft", "url": "/regulations/900-CMR-3-qag-regulation-title-ultricies-tristique-nulla-aliquet-enim-tortor-at-auctor", "screens": ["desktop"]}, {"label": "RegulationEffectiveDate", "url": "/regulations/900-CMR-2-qag-regulation-title"}, {"label": "RulesOfCourt", "url": "/trial-court-rules/qag-rulesofcourt"}, - {"label": "ServiceDetails", "url": "/service-details/qag-servicedetails"}, - {"label": "ServiceDetailsResources", "url": "/service-details/qag-servicedetails/resources", "screens": ["desktop", "mobile"]}, {"label": "Service1", "url": "/qag-service1"}, {"label": "Service3", "url": "/qag-service3", "screens": ["desktop"]}, {"label": "Service4", "url": "/qag-service4", "screens": ["desktop"]}, diff --git a/backstop/post-release.json b/backstop/post-release.json index ea7ee7774f..50c38b92a4 100644 --- a/backstop/post-release.json +++ b/backstop/post-release.json @@ -14,7 +14,6 @@ {"label": "OrgQAGEOTSSGeneralOrg", "url": "/orgs/qag-executive-office-of-technology-services-and-security"}, {"label": "OrgElectedOfficial", "url": "/orgs/qag-test-elected-org-page"}, {"label": "RegulationEffectiveDate", "url": "/regulations/900-CMR-2-qag-regulation-title"}, - {"label": "ServiceDetails", "url": "/service-details/qag-servicedetails"}, {"label": "Service1", "url": "/qag-service1"}, {"label": "TopicPage1", "url": "/topics/qag-topicpage1"} diff --git a/changelogs/DP-29553.yml b/changelogs/DP-29553.yml new file mode 100644 index 0000000000..8f887c87af --- /dev/null +++ b/changelogs/DP-29553.yml @@ -0,0 +1,41 @@ +# +# Write your changelog entry here. Every pull request must have a changelog yml file. +# +# Change types: +# ############################################################################# +# You can use one of the following types: +# - Added: For new features. +# - Changed: For changes to existing functionality. +# - Deprecated: For soon-to-be removed features. +# - Removed: For removed features. +# - Fixed: For any bug fixes. +# - Security: In case of vulnerabilities. +# +# Format +# ############################################################################# +# The format is crucial. Please follow the examples below. For reference, the requirements are: +# - All 3 parts are required and you must include "Type", "description" and "issue". +# - "Type" must be left aligned and followed by a colon. +# - "description" must be indented with 2 spaces followed by a colon +# - "issue" must be indented with 4 spaces followed by a colon. +# - "issue" is for the Jira ticket number only e.g. DP-1234 +# - No extra spaces, indents, or blank lines are allowed. +# +# Example: +# ############################################################################# +# Fixed: +# - description: Fixes scrolling on edit pages in Safari. +# issue: DP-13314 +# +# You may add more than 1 description & issue for each type using the following format: +# Changed: +# - description: Automating the release branch. +# issue: DP-10166 +# - description: Second change item that needs a description. +# issue: DP-19875 +# - description: Third change item that needs a description along with an issue. +# issue: DP-19843 +# +Changed: + - description: Remove service details pages from visual regression testing in backstop. + issue: DP-29553 From af308d8ad012e29637f956bafd72e208d1dbf358 Mon Sep 17 00:00:00 2001 From: joeg8612 Date: Wed, 6 Sep 2023 08:19:23 -0400 Subject: [PATCH 23/32] DP-29559 role permissions analytics (#2180) * updated role permissions * changelog --- changelogs/DP-29559.yml | 41 +++++++++++ conf/drupal/config/user.role.author.yml | 2 + conf/drupal/config/user.role.editor.yml | 2 + conf/drupal/config/user.role.tester.yml | 91 +------------------------ 4 files changed, 47 insertions(+), 89 deletions(-) create mode 100644 changelogs/DP-29559.yml diff --git a/changelogs/DP-29559.yml b/changelogs/DP-29559.yml new file mode 100644 index 0000000000..e974a28186 --- /dev/null +++ b/changelogs/DP-29559.yml @@ -0,0 +1,41 @@ +# +# Write your changelog entry here. Every pull request must have a changelog yml file. +# +# Change types: +# ############################################################################# +# You can use one of the following types: +# - Added: For new features. +# - Changed: For changes to existing functionality. +# - Deprecated: For soon-to-be removed features. +# - Removed: For removed features. +# - Fixed: For any bug fixes. +# - Security: In case of vulnerabilities. +# +# Format +# ############################################################################# +# The format is crucial. Please follow the examples below. For reference, the requirements are: +# - All 3 parts are required and you must include "Type", "description" and "issue". +# - "Type" must be left aligned and followed by a colon. +# - "description" must be indented with 2 spaces followed by a colon +# - "issue" must be indented with 4 spaces followed by a colon. +# - "issue" is for the Jira ticket number only e.g. DP-1234 +# - No extra spaces, indents, or blank lines are allowed. +# +# Example: +# ############################################################################# +# Fixed: +# - description: Fixes scrolling on edit pages in Safari. +# issue: DP-13314 +# +# You may add more than 1 description & issue for each type using the following format: +# Changed: +# - description: Automating the release branch. +# issue: DP-10166 +# - description: Second change item that needs a description. +# issue: DP-19875 +# - description: Third change item that needs a description along with an issue. +# issue: DP-19843 +# +Changed: + - description: Role permissions changed to allow all authors and editors access to new analytics tab without tester role. Cleanup of tester role permissions. + issue: DP-29559 diff --git a/conf/drupal/config/user.role.author.yml b/conf/drupal/config/user.role.author.yml index 3c94dd2a4a..d61bac00dc 100644 --- a/conf/drupal/config/user.role.author.yml +++ b/conf/drupal/config/user.role.author.yml @@ -44,6 +44,7 @@ dependencies: - entity_usage - environment_indicator - mass_admin_toolbar + - mass_analytics - mass_validation - mass_views - mass_workbench_ui @@ -210,6 +211,7 @@ permissions: - 'view alert revisions' - 'view all revisions' - 'view all scheduled transitions' + - 'view analytics pages' - 'view any unpublished content' - 'view binder revisions' - 'view campaign_landing revisions' diff --git a/conf/drupal/config/user.role.editor.yml b/conf/drupal/config/user.role.editor.yml index 6f63e7217e..eedbb04f02 100644 --- a/conf/drupal/config/user.role.editor.yml +++ b/conf/drupal/config/user.role.editor.yml @@ -45,6 +45,7 @@ dependencies: - entity_usage - environment_indicator - mass_admin_toolbar + - mass_analytics - mass_content_api - mass_hierarchy - mass_validation @@ -319,6 +320,7 @@ permissions: - 'view alert revisions' - 'view all revisions' - 'view all scheduled transitions' + - 'view analytics pages' - 'view any unpublished content' - 'view binder revisions' - 'view campaign_landing revisions' diff --git a/conf/drupal/config/user.role.tester.yml b/conf/drupal/config/user.role.tester.yml index 3d02cf053c..5e5dc60d81 100644 --- a/conf/drupal/config/user.role.tester.yml +++ b/conf/drupal/config/user.role.tester.yml @@ -1,96 +1,9 @@ uuid: d4b98b38-5584-45a0-9cbd-89818d717589 langcode: en status: true -dependencies: - config: - - node.type.advisory - - node.type.curated_list - - node.type.decision - - node.type.decision_tree - - node.type.decision_tree_branch - - node.type.decision_tree_conclusion - - node.type.event - - node.type.form_page - - node.type.guide_page - - node.type.location_details - - node.type.news - - node.type.person - - node.type.regulation - module: - - mass_analytics - - mass_validation - - node - - route_iframes +dependencies: { } id: tester label: Tester weight: 0 is_admin: null -permissions: - - 'create advisory content' - - 'create curated_list content' - - 'create decision content' - - 'create decision_tree content' - - 'create decision_tree_branch content' - - 'create decision_tree_conclusion content' - - 'create event content' - - 'create form_page content' - - 'create guide_page content' - - 'create location_details content' - - 'create news content' - - 'create person content' - - 'create regulation content' - - 'edit any advisory content' - - 'edit any curated_list content' - - 'edit any decision content' - - 'edit any decision_tree content' - - 'edit any decision_tree_branch content' - - 'edit any decision_tree_conclusion content' - - 'edit any event content' - - 'edit any form_page content' - - 'edit any guide_page content' - - 'edit any location_details content' - - 'edit any news content' - - 'edit any person content' - - 'edit any regulation content' - - 'edit own advisory content' - - 'edit own curated_list content' - - 'edit own decision content' - - 'edit own decision_tree content' - - 'edit own decision_tree_branch content' - - 'edit own decision_tree_conclusion content' - - 'edit own event content' - - 'edit own form_page content' - - 'edit own guide_page content' - - 'edit own location_details content' - - 'edit own news content' - - 'edit own person content' - - 'edit own regulation content' - - 'revert advisory revisions' - - 'revert curated_list revisions' - - 'revert decision revisions' - - 'revert decision_tree revisions' - - 'revert decision_tree_branch revisions' - - 'revert decision_tree_conclusion revisions' - - 'revert event revisions' - - 'revert form_page revisions' - - 'revert guide_page revisions' - - 'revert location_details revisions' - - 'revert news revisions' - - 'revert person revisions' - - 'revert regulation revisions' - - 'set collection tags' - - 'view advisory revisions' - - 'view analytics pages' - - 'view curated_list revisions' - - 'view decision revisions' - - 'view decision_tree revisions' - - 'view decision_tree_branch revisions' - - 'view decision_tree_conclusion revisions' - - 'view event revisions' - - 'view form_page revisions' - - 'view guide_page revisions' - - 'view location_details revisions' - - 'view news revisions' - - 'view person revisions' - - 'view regulation revisions' - - 'view route iframe pages' +permissions: { } From a39510d86f76077bb4b657aedcfdd3f034be212e Mon Sep 17 00:00:00 2001 From: Thomas Fleming Date: Thu, 7 Sep 2023 10:09:54 -0400 Subject: [PATCH 24/32] Fixed phpcs issue --- .../src/Plugin/migrate/source/UpdateReferences.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/docroot/modules/custom/mass_migrate/src/Plugin/migrate/source/UpdateReferences.php b/docroot/modules/custom/mass_migrate/src/Plugin/migrate/source/UpdateReferences.php index e4a8c2c45c..7e6673ee47 100644 --- a/docroot/modules/custom/mass_migrate/src/Plugin/migrate/source/UpdateReferences.php +++ b/docroot/modules/custom/mass_migrate/src/Plugin/migrate/source/UpdateReferences.php @@ -129,8 +129,7 @@ public function prepareRow(Row $row) { } break; case EntityReferenceItem::class: - if ($item->get('target_id') - ->getString() == $ref['reference_value_old']) { + if ($item->get('target_id')->getString() == $ref['reference_value_old']) { $values[$field_name][$delta]['target_id'] = $ref['reference_value_new']; $changed = TRUE; } From ee0a4842141edcdd8a2d53666e625185bec21a0a Mon Sep 17 00:00:00 2001 From: Tom Fleming Date: Thu, 7 Sep 2023 12:24:54 -0400 Subject: [PATCH 25/32] DP-29536 - imagick install fix (#2182) * Force pecl install imagick to avoid error when already installed * Added changelog * ignore errors in pecl install * Comment out imagick install * Removed imagick installation --- .tugboat/config.yml | 5 ----- changelogs/DP-29536.yml | 41 +++++++++++++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+), 5 deletions(-) create mode 100644 changelogs/DP-29536.yml diff --git a/.tugboat/config.yml b/.tugboat/config.yml index 574df1bbaf..2135083842 100644 --- a/.tugboat/config.yml +++ b/.tugboat/config.yml @@ -51,11 +51,6 @@ services: # Install Node.js 16.x - curl -fsSL https://deb.nodesource.com/setup_16.x | bash - - apt-get install -y nodejs - # Install imagick - - apt-get install -y libmagickwand-dev - # Avoid prompts. https://stackoverflow.com/a/33647515 - - echo '' | pecl install imagick - - docker-php-ext-enable imagick # Install opcache - docker-php-ext-install opcache # Needed for image styles. diff --git a/changelogs/DP-29536.yml b/changelogs/DP-29536.yml new file mode 100644 index 0000000000..671212c4e1 --- /dev/null +++ b/changelogs/DP-29536.yml @@ -0,0 +1,41 @@ +# +# Write your changelog entry here. Every pull request must have a changelog yml file. +# +# Change types: +# ############################################################################# +# You can use one of the following types: +# - Added: For new features. +# - Changed: For changes to existing functionality. +# - Deprecated: For soon-to-be removed features. +# - Removed: For removed features. +# - Fixed: For any bug fixes. +# - Security: In case of vulnerabilities. +# +# Format +# ############################################################################# +# The format is crucial. Please follow the examples below. For reference, the requirements are: +# - All 3 parts are required and you must include "Type", "description" and "issue". +# - "Type" must be left aligned and followed by a colon. +# - "description" must be indented with 2 spaces followed by a colon +# - "issue" must be indented with 4 spaces followed by a colon. +# - "issue" is for the Jira ticket number only e.g. DP-1234 +# - No extra spaces, indents, or blank lines are allowed. +# +# Example: +# ############################################################################# +# Fixed: +# - description: Fixes scrolling on edit pages in Safari. +# issue: DP-13314 +# +# You may add more than 1 description & issue for each type using the following format: +# Changed: +# - description: Automating the release branch. +# issue: DP-10166 +# - description: Second change item that needs a description. +# issue: DP-19875 +# - description: Third change item that needs a description along with an issue. +# issue: DP-19843 +# +Fixed: + - description: Fixed Tugboat builds. + issue: DP-29536 From 76258c799ecd9387f31cd004255c282d63613f2a Mon Sep 17 00:00:00 2001 From: Moshe Weitzman Date: Mon, 11 Sep 2023 05:06:49 -0400 Subject: [PATCH 26/32] Replace Twitter logo with new 'X' logo and add Threads logo across Mass.gov (#2176) * Replace Twitter logo with new 'X' logo and add Threads logo across Mass.gov * Use new Mayflower PR * Add changelog * PHPCS * Mayflower update --------- Co-authored-by: joeg8612 Co-authored-by: abaghdasaryan Co-authored-by: Arthur Baghdasaryan <62405127+arthurbaghdas@users.noreply.github.com> --- changelogs/DP-29416.yml | 41 +++++++++++++++++++ composer.lock | 8 ++-- ...field.node.org_page.field_social_links.yml | 2 +- ...d.field.node.person.field_social_links.yml | 2 +- .../mass_content/src/Field/SocialLinks.php | 1 + .../custom/mass_utility/mass_utility.module | 2 +- .../mass_validation/mass_validation.module | 2 + .../mayflower/src/Prepare/Molecules.php | 1 + .../themes/custom/mass_theme/mass_theme.theme | 2 + .../includes/molecules-social-links.html.twig | 7 +++- 10 files changed, 60 insertions(+), 8 deletions(-) create mode 100644 changelogs/DP-29416.yml diff --git a/changelogs/DP-29416.yml b/changelogs/DP-29416.yml new file mode 100644 index 0000000000..e649f03a18 --- /dev/null +++ b/changelogs/DP-29416.yml @@ -0,0 +1,41 @@ +# +# Write your changelog entry here. Every pull request must have a changelog yml file. +# +# Change types: +# ############################################################################# +# You can use one of the following types: +# - Added: For new features. +# - Changed: For changes to existing functionality. +# - Deprecated: For soon-to-be removed features. +# - Removed: For removed features. +# - Fixed: For any bug fixes. +# - Security: In case of vulnerabilities. +# +# Format +# ############################################################################# +# The format is crucial. Please follow the examples below. For reference, the requirements are: +# - All 3 parts are required and you must include "Type", "description" and "issue". +# - "Type" must be left aligned and followed by a colon. +# - "description" must be indented with 2 spaces followed by a colon +# - "issue" must be indented with 4 spaces followed by a colon. +# - "issue" is for the Jira ticket number only e.g. DP-1234 +# - No extra spaces, indents, or blank lines are allowed. +# +# Example: +# ############################################################################# +# Fixed: +# - description: Fixes scrolling on edit pages in Safari. +# issue: DP-13314 +# +# You may add more than 1 description & issue for each type using the following format: +# Changed: +# - description: Automating the release branch. +# issue: DP-10166 +# - description: Second change item that needs a description. +# issue: DP-19875 +# - description: Third change item that needs a description along with an issue. +# issue: DP-19843 +# +Changed: + - description: Replace Twitter logo with new 'X' logo and add Threads logo + issue: DP-29416 diff --git a/composer.lock b/composer.lock index c19300e234..847c52bbfc 100644 --- a/composer.lock +++ b/composer.lock @@ -12806,12 +12806,12 @@ "source": { "type": "git", "url": "git@github.com:massgov/mayflower-artifacts.git", - "reference": "d4bffc2a73e1118d6dcef990ea421e9e54d5f83a" + "reference": "7118bf20f6781e71d6a3c9d0cbe95d0d335ff0c4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/massgov/mayflower-artifacts/zipball/d4bffc2a73e1118d6dcef990ea421e9e54d5f83a", - "reference": "d4bffc2a73e1118d6dcef990ea421e9e54d5f83a", + "url": "https://api.github.com/repos/massgov/mayflower-artifacts/zipball/7118bf20f6781e71d6a3c9d0cbe95d0d335ff0c4", + "reference": "7118bf20f6781e71d6a3c9d0cbe95d0d335ff0c4", "shasum": "" }, "require": { @@ -12829,7 +12829,7 @@ } ], "description": "This repository is the product of the built artifact from massgov/mayflower", - "time": "2023-08-17T19:38:28+00:00" + "time": "2023-09-11T08:45:31+00:00" }, { "name": "masterminds/html5", diff --git a/conf/drupal/config/field.field.node.org_page.field_social_links.yml b/conf/drupal/config/field.field.node.org_page.field_social_links.yml index 4bb258e68c..4ad739d43a 100644 --- a/conf/drupal/config/field.field.node.org_page.field_social_links.yml +++ b/conf/drupal/config/field.field.node.org_page.field_social_links.yml @@ -12,7 +12,7 @@ field_name: field_social_links entity_type: node bundle: org_page label: 'Social Links' -description: "Add links to your social media profiles here.\r\nIn the URL field, use complete links including \"https\" from one of the following domains: twitter.com, facebook.com, flickr.com, instagram.com, linkedin.com, medium.com, and youtube.com.\r\nFor the link text, enter your username, handle, or other text that helps the user know what profile they will find when they click this social media link. Social information will only appear on your Org page if you add a Social Media section under the \"Content\" tab." +description: "Add links to your social media profiles here.\r\nIn the URL field, use complete links including \"https\" from one of the following domains: twitter.com, x.com, facebook.com, threads.net, flickr.com, instagram.com, linkedin.com, medium.com, and youtube.com.\r\nFor the link text, enter your username, handle, or other text that helps the user know what profile they will find when they click this social media link. Social information will only appear on your Org page if you add a Social Media section under the \"Content\" tab." required: false translatable: false default_value: { } diff --git a/conf/drupal/config/field.field.node.person.field_social_links.yml b/conf/drupal/config/field.field.node.person.field_social_links.yml index 9600d35ad3..3e0040e288 100644 --- a/conf/drupal/config/field.field.node.person.field_social_links.yml +++ b/conf/drupal/config/field.field.node.person.field_social_links.yml @@ -12,7 +12,7 @@ field_name: field_social_links entity_type: node bundle: person label: 'Social Links' -description: "Add links to your social media profiles here.\r\nIn the URL field, use complete links including \"https\" from one of the following domains: twitter.com, facebook.com, flickr.com, instagram.com, linkedin.com, medium.com, and youtube.com.\r\nFor the link text, enter your username, handle, or other text that helps the user know what profile they will find when they click this social media link." +description: "Add links to your social media profiles here.\r\nIn the URL field, use complete links including \"https\" from one of the following domains: twitter.com, x.com, facebook.com, threads.net, flickr.com, instagram.com, linkedin.com, medium.com, and youtube.com.\r\nFor the link text, enter your username, handle, or other text that helps the user know what profile they will find when they click this social media link." required: false translatable: true default_value: { } diff --git a/docroot/modules/custom/mass_content/src/Field/SocialLinks.php b/docroot/modules/custom/mass_content/src/Field/SocialLinks.php index 851fd231ed..fec9dac935 100644 --- a/docroot/modules/custom/mass_content/src/Field/SocialLinks.php +++ b/docroot/modules/custom/mass_content/src/Field/SocialLinks.php @@ -17,6 +17,7 @@ public function computeValue() { $services = [ 'twitter', 'facebook', + 'threads', 'flickr', 'blog', 'linkedin', diff --git a/docroot/modules/custom/mass_utility/mass_utility.module b/docroot/modules/custom/mass_utility/mass_utility.module index ac057ee1ba..440dddb310 100644 --- a/docroot/modules/custom/mass_utility/mass_utility.module +++ b/docroot/modules/custom/mass_utility/mass_utility.module @@ -456,7 +456,7 @@ function mass_utility_field_widget_form_alter(&$element, FormStateInterface $for 'field_social_links', ]; if (in_array($field_name, $social_link_fields)) { - $element['uri']['#description'] = t('Enter a complete, valid URL from Facebook, Twitter, Instagram, LinkedIn, or Medium.', + $element['uri']['#description'] = t('Enter a complete, valid URL from Facebook, X (formerly Twitter), Threads, Instagram, LinkedIn, or Medium.', [ '%front' => '', '%add-node' => '/node/add', diff --git a/docroot/modules/custom/mass_validation/mass_validation.module b/docroot/modules/custom/mass_validation/mass_validation.module index 8a397b2a33..2bcd8759eb 100644 --- a/docroot/modules/custom/mass_validation/mass_validation.module +++ b/docroot/modules/custom/mass_validation/mass_validation.module @@ -65,8 +65,10 @@ function mass_validation_entity_bundle_field_info_alter(&$fields, EntityTypeInte $field_social_links->addConstraint('SocialLink', [ 'allowedValues' => [ 'twitter.com', + 'x.com', 'flickr.com', 'facebook.com', + 'threads.net', 'instagram.com', 'linkedin.com', 'youtube.com', diff --git a/docroot/modules/custom/mayflower/src/Prepare/Molecules.php b/docroot/modules/custom/mayflower/src/Prepare/Molecules.php index be0ff07017..1e6cd7665d 100644 --- a/docroot/modules/custom/mayflower/src/Prepare/Molecules.php +++ b/docroot/modules/custom/mayflower/src/Prepare/Molecules.php @@ -290,6 +290,7 @@ public static function prepareIconLinks($entity, array $options = []) { $services = [ 'twitter', 'facebook', + 'threads', 'flickr', 'blog', 'linkedin', diff --git a/docroot/themes/custom/mass_theme/mass_theme.theme b/docroot/themes/custom/mass_theme/mass_theme.theme index ddbcc26ed1..0254581653 100644 --- a/docroot/themes/custom/mass_theme/mass_theme.theme +++ b/docroot/themes/custom/mass_theme/mass_theme.theme @@ -4928,6 +4928,7 @@ function mass_theme_preprocess_field(&$variables, $hook) { $services = [ 'twitter', 'facebook', + 'threads', 'flickr', 'blog', 'linkedin', @@ -6854,6 +6855,7 @@ function mass_theme_preprocess_field__node__field_social_links(&$variables) { $services = [ 'twitter', 'facebook', + 'threads', 'flickr', 'blog', 'linkedin', diff --git a/docroot/themes/custom/mass_theme/templates/includes/molecules-social-links.html.twig b/docroot/themes/custom/mass_theme/templates/includes/molecules-social-links.html.twig index 678d8c555e..161bced3b8 100644 --- a/docroot/themes/custom/mass_theme/templates/includes/molecules-social-links.html.twig +++ b/docroot/themes/custom/mass_theme/templates/includes/molecules-social-links.html.twig @@ -11,6 +11,11 @@ {% include directory ~ "/templates/includes/atoms-svg.html.twig" with {'iconName':'facebook'} %} + - \ No newline at end of file + From a754aef294fe01049f72771de72733d1a346c853 Mon Sep 17 00:00:00 2001 From: Minghua Sun Date: Mon, 11 Sep 2023 05:51:04 -0400 Subject: [PATCH 27/32] dp 29600 fix suggested page item bug (#2183) * link to mf * add changelog * Mayflower update --------- Co-authored-by: abaghdasaryan --- changelogs/DP-29600.yml | 41 +++++++++++++++++++++++++++++++++++++++++ composer.lock | 8 ++++---- 2 files changed, 45 insertions(+), 4 deletions(-) create mode 100644 changelogs/DP-29600.yml diff --git a/changelogs/DP-29600.yml b/changelogs/DP-29600.yml new file mode 100644 index 0000000000..8b6bce59da --- /dev/null +++ b/changelogs/DP-29600.yml @@ -0,0 +1,41 @@ +# +# Write your changelog entry here. Every pull request must have a changelog yml file. +# +# Change types: +# ############################################################################# +# You can use one of the following types: +# - Added: For new features. +# - Changed: For changes to existing functionality. +# - Deprecated: For soon-to-be removed features. +# - Removed: For removed features. +# - Fixed: For any bug fixes. +# - Security: In case of vulnerabilities. +# +# Format +# ############################################################################# +# The format is crucial. Please follow the examples below. For reference, the requirements are: +# - All 3 parts are required and you must include "Type", "description" and "issue". +# - "Type" must be left aligned and followed by a colon. +# - "description" must be indented with 2 spaces followed by a colon +# - "issue" must be indented with 4 spaces followed by a colon. +# - "issue" is for the Jira ticket number only e.g. DP-1234 +# - No extra spaces, indents, or blank lines are allowed. +# +# Example: +# ############################################################################# +# Fixed: +# - description: Fixes scrolling on edit pages in Safari. +# issue: DP-13314 +# +# You may add more than 1 description & issue for each type using the following format: +# Changed: +# - description: Automating the release branch. +# issue: DP-10166 +# - description: Second change item that needs a description. +# issue: DP-19875 +# - description: Third change item that needs a description along with an issue. +# issue: DP-19843 +# +Fixed: + - description: Fixed suggested page item link covering the whole page. + issue: DP-29600 diff --git a/composer.lock b/composer.lock index 847c52bbfc..aa0f056189 100644 --- a/composer.lock +++ b/composer.lock @@ -12806,12 +12806,12 @@ "source": { "type": "git", "url": "git@github.com:massgov/mayflower-artifacts.git", - "reference": "7118bf20f6781e71d6a3c9d0cbe95d0d335ff0c4" + "reference": "c7dafa9b3a62772394ff883e92db4354e1771870" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/massgov/mayflower-artifacts/zipball/7118bf20f6781e71d6a3c9d0cbe95d0d335ff0c4", - "reference": "7118bf20f6781e71d6a3c9d0cbe95d0d335ff0c4", + "url": "https://api.github.com/repos/massgov/mayflower-artifacts/zipball/c7dafa9b3a62772394ff883e92db4354e1771870", + "reference": "c7dafa9b3a62772394ff883e92db4354e1771870", "shasum": "" }, "require": { @@ -12829,7 +12829,7 @@ } ], "description": "This repository is the product of the built artifact from massgov/mayflower", - "time": "2023-09-11T08:45:31+00:00" + "time": "2023-09-11T09:26:47+00:00" }, { "name": "masterminds/html5", From 022b9f8eee05fe0ecf11d24670b22f044a4d06f5 Mon Sep 17 00:00:00 2001 From: Robert Tyler Stephens Date: Mon, 11 Sep 2023 14:35:53 -0400 Subject: [PATCH 28/32] DP-28608: Replace superset data in views with bigquery (#2113) * DP-28608: Add views fields with bigquery data * DP-28608: Remove superset from /admin/content * DP-28608: Add nos_per_1000 and pageviews to admin/content page, trying to troubleshoot error * DP-28608: Change order * DP-28608: Fix period in nos_per_1000_cleaned. * DP-28608: Rewrite as link * DP-28608: Add nos per 1000 and pageviews to export on /admin/content * DP-28608: Replace /ma-dash/needs-review and /admin/ma-dash/my-content * DP-28608: Replace data on content performance ejects, remove superset on performance org feedback * DP-28608: Add BQ to content performance view, org feedback display * DP-28608: Replace on content performance view content performance display * DP-28608: Replace on content performance view feedback display * DP-28608: Replace on content performance view data export * DP-28608: Add changelog * DP-28608: WIP for pages with high negative feedback * DP-28608: Add bq to page with high negative feedback * DP-28608: Switch long title and high eject views * DP-28608: Switch parent reports * DP-28608: Switch breadcrumb depth * DP-28608: Switch on orphaned content report * DP-28608: Switch on advanced search * DP-28608: Switch on /ma-dash/reports/organizations * DP-28608: Switch on /admin/ma-dash/watched-content * DP-28608: Switch on changed parents * DP-28608: Switch on /admin/orphaned-service-details * DP-28608: Switch on /admin/content/scheduled-drafts * DP-28608: Switch on /admin/ma-dash/visitor-help-pages * DP-28608: Switch on forgotten feedback by organization view * DP-28608: Switch on forgotten mass dashboard content view * DP-28608: Switch on forgotten mass dashboard trash view * DP-28608: Modify default display for high neg feedback * DP-28608: Modify default display for high number of ejects * DP-28608: Modify default display for feedback by org * DP-28608: Modify default display for change collections view * DP-28608: Modify default display for content performance * DP-28608: Modify default display for my content view * DP-28608: Modify default display for content, orgs, and parent reports views * DP-28608: Replace nos_per_1000 with nos_per_1000_cleaned in remaning views * DP-28608: Re-export views to fix config diff issues --------- Co-authored-by: joeg8612 Co-authored-by: Moshe Weitzman --- changelogs/DP-28608.yml | 41 + .../config/views.view.advancedsearch.yml | 4 +- .../config/views.view.breadcrumb_depth.yml | 6 +- .../config/views.view.change_collections.yml | 86 +- .../config/views.view.change_parents.yml | 10 +- conf/drupal/config/views.view.content.yml | 370 +------- .../config/views.view.content_performance.yml | 884 ++---------------- .../config/views.view.content_reports.yml | 4 +- ...ews.view.content_reports_organizations.yml | 4 +- .../views.view.content_reports_titles.yml | 120 +-- .../views.view.feedback_by_organization.yml | 473 ++-------- .../views.view.mass_dashboard_content.yml | 38 +- ...views.view.mass_dashboard_needs_review.yml | 35 +- .../views.view.mass_dashboard_trash.yml | 39 +- conf/drupal/config/views.view.my_content.yml | 112 +-- .../views.view.orphaned_service_details.yml | 53 +- ...view.pages_with_high_negative_feedback.yml | 425 ++------- ....view.pages_with_high_number_of_ejects.yml | 466 ++------- .../config/views.view.parent_reports.yml | 16 +- .../views.view.report_orphaned_content.yml | 122 +-- ...views.view.scheduled_content_revisions.yml | 54 +- .../config/views.view.visitor_help_pages.yml | 4 +- .../config/views.view.watched_content.yml | 54 +- .../mass_bigquery/mass_bigquery.views.inc | 180 ++++ 24 files changed, 918 insertions(+), 2682 deletions(-) create mode 100644 changelogs/DP-28608.yml create mode 100644 docroot/modules/custom/mass_bigquery/mass_bigquery.views.inc diff --git a/changelogs/DP-28608.yml b/changelogs/DP-28608.yml new file mode 100644 index 0000000000..4956b2393f --- /dev/null +++ b/changelogs/DP-28608.yml @@ -0,0 +1,41 @@ +# +# Write your changelog entry here. Every pull request must have a changelog yml file. +# +# Change types: +# ############################################################################# +# You can use one of the following types: +# - Added: For new features. +# - Changed: For changes to existing functionality. +# - Deprecated: For soon-to-be removed features. +# - Removed: For removed features. +# - Fixed: For any bug fixes. +# - Security: In case of vulnerabilities. +# +# Format +# ############################################################################# +# The format is crucial. Please follow the examples below. For reference, the requirements are: +# - All 3 parts are required and you must include "Type", "description" and "issue". +# - "Type" must be left aligned and followed by a colon. +# - "description" must be indented with 2 spaces followed by a colon +# - "issue" must be indented with 4 spaces followed by a colon. +# - "issue" is for the Jira ticket number only e.g. DP-1234 +# - No extra spaces, indents, or blank lines are allowed. +# +# Example: +# ############################################################################# +# Fixed: +# - description: Fixes scrolling on edit pages in Safari. +# issue: DP-13314 +# +# You may add more than 1 description & issue for each type using the following format: +# Changed: +# - description: Automating the release branch. +# issue: DP-10166 +# - description: Second change item that needs a description. +# issue: DP-19875 +# - description: Third change item that needs a description along with an issue. +# issue: DP-19843 +# +Changed: + - description: Replace superset data in views with data from bigquery + issue: DP-28608 diff --git a/conf/drupal/config/views.view.advancedsearch.yml b/conf/drupal/config/views.view.advancedsearch.yml index fff0585861..a60ad4ca29 100644 --- a/conf/drupal/config/views.view.advancedsearch.yml +++ b/conf/drupal/config/views.view.advancedsearch.yml @@ -12,7 +12,7 @@ dependencies: module: - content_moderation - entity_hierarchy - - mass_superset + - mass_bigquery - mass_views - node - taxonomy @@ -813,7 +813,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group diff --git a/conf/drupal/config/views.view.breadcrumb_depth.yml b/conf/drupal/config/views.view.breadcrumb_depth.yml index 677284cb79..018e092948 100644 --- a/conf/drupal/config/views.view.breadcrumb_depth.yml +++ b/conf/drupal/config/views.view.breadcrumb_depth.yml @@ -28,7 +28,7 @@ dependencies: module: - csv_serialization - entity_hierarchy - - mass_superset + - mass_bigquery - mass_views - node - rest @@ -303,7 +303,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group @@ -1072,7 +1072,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group diff --git a/conf/drupal/config/views.view.change_collections.yml b/conf/drupal/config/views.view.change_collections.yml index cf3d7af80a..b2f6907069 100644 --- a/conf/drupal/config/views.view.change_collections.yml +++ b/conf/drupal/config/views.view.change_collections.yml @@ -24,7 +24,7 @@ dependencies: - workflows.workflow.editorial module: - content_moderation - - mass_superset + - mass_bigquery - mass_views - node - taxonomy @@ -1082,15 +1082,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -1098,16 +1098,16 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false - remember: true + remember: false multiple: false remember_roles: authenticated: authenticated @@ -1122,6 +1122,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' @@ -1137,67 +1140,6 @@ display: default_group: All default_group_multiple: { } group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date filter_groups: operator: AND groups: diff --git a/conf/drupal/config/views.view.change_parents.yml b/conf/drupal/config/views.view.change_parents.yml index 97faf588b6..b7843f1c64 100644 --- a/conf/drupal/config/views.view.change_parents.yml +++ b/conf/drupal/config/views.view.change_parents.yml @@ -7,7 +7,7 @@ dependencies: - taxonomy.vocabulary.label module: - content_moderation - - mass_superset + - mass_bigquery - node - taxonomy - user @@ -82,13 +82,13 @@ display: form_step: true buttons: true action_title: Action + clear_on_exposed: false + force_selection_info: false selected_actions: 2: action_id: mass_hierarchy_change_parent preconfiguration: - add_confirmation: 0 - clear_on_exposed: false - force_selection_info: 0 + add_confirmation: false title: id: title table: node_field_data @@ -417,7 +417,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group diff --git a/conf/drupal/config/views.view.content.yml b/conf/drupal/config/views.view.content.yml index 8858b8b79e..d33a900b78 100644 --- a/conf/drupal/config/views.view.content.yml +++ b/conf/drupal/config/views.view.content.yml @@ -57,7 +57,7 @@ dependencies: - content_moderation - csv_serialization - entity_hierarchy - - mass_superset + - mass_bigquery - mass_views - node - options @@ -679,15 +679,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -738,7 +738,7 @@ display: suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -844,55 +844,6 @@ display: empty_zero: false hide_alter_empty: true destination: false - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: vid - group_type: group - admin_label: '' - plugin_id: standard - label: 'Date Snoozed' - exclude: true - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true pager: type: mini options: @@ -1293,15 +1244,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -1309,14 +1260,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -1333,6 +1284,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' @@ -1348,67 +1302,6 @@ display: default_group: All default_group_multiple: { } group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date filter_groups: operator: AND groups: @@ -2076,15 +1969,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -2135,7 +2028,7 @@ display: suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -2416,55 +2309,6 @@ display: - node_promote_action - node_unpromote_action - pathauto_update_alias_node - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: standard - label: 'Date Snoozed' - exclude: true - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true field_reusable_label: id: field_reusable_label table: node__field_reusable_label @@ -3882,15 +3726,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -3898,14 +3742,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -3922,6 +3766,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' @@ -3937,67 +3784,6 @@ display: default_group: All default_group_multiple: { } group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date field_reusable_label_target_id: id: field_reusable_label_target_id table: node__field_reusable_label @@ -4779,15 +4565,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -4795,14 +4581,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: false multiple: false @@ -4819,6 +4605,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' @@ -4834,67 +4623,6 @@ display: default_group: All default_group_multiple: { } group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: vid - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 2: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date field_reusable_label_target_id: id: field_reusable_label_target_id table: node__field_reusable_label diff --git a/conf/drupal/config/views.view.content_performance.yml b/conf/drupal/config/views.view.content_performance.yml index 29de99da90..e51d127901 100644 --- a/conf/drupal/config/views.view.content_performance.yml +++ b/conf/drupal/config/views.view.content_performance.yml @@ -46,7 +46,7 @@ dependencies: module: - content_moderation - csv_serialization - - mass_superset + - mass_bigquery - mass_views - node - rest @@ -530,7 +530,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -585,116 +585,10 @@ display: format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: vid - group_type: group - admin_label: '' - plugin_id: standard - label: 'Date Snoozed' - exclude: true - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - score: - id: score - table: mass_superset_data - field: score - relationship: vid - group_type: group - admin_label: '' - plugin_id: numeric - label: Score - exclude: false - alter: - alter_text: false - text: '' - make_link: true - path: 'node/{{ nid }}/analytics' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: true - empty_zero: false - hide_alter_empty: true - set_precision: true - precision: 1 - decimal: . - separator: ',' - format_plural: false - format_plural_string: !!binary MQNAY291bnQ= - prefix: '' - suffix: '' - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' @@ -750,7 +644,7 @@ display: suffix: '' eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: vid group_type: group @@ -807,7 +701,7 @@ display: suffix: '' broken_links: id: broken_links - table: mass_superset_data + table: mass_bigquery_data field: broken_links relationship: vid group_type: group @@ -864,7 +758,7 @@ display: suffix: '' grade_level: id: grade_level - table: mass_superset_data + table: mass_bigquery_data field: grade_level relationship: vid group_type: group @@ -921,7 +815,7 @@ display: suffix: '' total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: vid group_type: group @@ -978,7 +872,7 @@ display: suffix: '' total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: vid group_type: group @@ -1035,7 +929,7 @@ display: suffix: '' total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: vid group_type: group @@ -1662,125 +1556,9 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score - relationship: vid - group_type: group - admin_label: '' - plugin_id: numeric - operator: '<=' - value: - min: '' - max: '' - value: '' - group: 1 - exposed: true - expose: - operator_id: score_op - label: 'Score is less than or equal to' - description: '' - use_operator: false - operator: score_op - operator_limit_selection: false - operator_list: { } - identifier: score - required: false - remember: true - multiple: false - remember_roles: - authenticated: authenticated - anonymous: '0' - author: '0' - editor: '0' - emergency_alert_publisher: '0' - executive_orders: '0' - redirect_creators: '0' - content_team: '0' - developer: '0' - administrator: '0' - tester: '0' - doc_deletion: '0' - min_placeholder: '' - max_placeholder: '' - placeholder: '' - is_grouped: false - group_info: - label: '' - description: '' - identifier: '' - optional: true - widget: select - multiple: false - remember: false - default_group: All - default_group_multiple: { } - group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -1839,10 +1617,10 @@ display: default_group: All default_group_multiple: { } group_items: { } - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' @@ -1855,17 +1633,14 @@ display: group: 1 exposed: true expose: - operator_id: nos_per_1000_op - label: 'Nos per 1000' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' - use_operator: true - operator: nos_per_1000_op - operator_limit_selection: true - operator_list: - '<=': '<=' - '>=': '>=' - between: between - identifier: nos_per_1000 + use_operator: false + operator: nos_per_1000_cleaned_op + operator_limit_selection: false + operator_list: { } + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -1902,7 +1677,7 @@ display: group_items: { } eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: nid group_type: group @@ -1963,7 +1738,7 @@ display: group_items: { } grade_level: id: grade_level - table: mass_superset_data + table: mass_bigquery_data field: grade_level relationship: nid group_type: group @@ -2024,7 +1799,7 @@ display: group_items: { } broken_links: id: broken_links - table: mass_superset_data + table: mass_bigquery_data field: broken_links relationship: nid group_type: group @@ -2085,7 +1860,7 @@ display: group_items: { } total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: nid group_type: group @@ -2146,7 +1921,7 @@ display: group_items: { } total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: group @@ -2207,7 +1982,7 @@ display: group_items: { } total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: nid group_type: group @@ -3073,21 +2848,21 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'No''s per K page views' exclude: false alter: alter_text: false text: '' - make_link: true - path: 'node/{{ nid }}/analytics' + make_link: false + path: '' absolute: false external: false replace_spaces: false @@ -3132,7 +2907,7 @@ display: suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -3413,55 +3188,6 @@ display: - node_promote_action - node_unpromote_action - pathauto_update_alias_node - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: standard - label: 'Date Snoozed' - exclude: true - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true filters: latest_revision: id: latest_revision @@ -4046,15 +3772,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -4062,14 +3788,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -4086,6 +3812,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' @@ -4101,67 +3830,6 @@ display: default_group: All default_group_multiple: { } group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date field_reusable_label_target_id: id: field_reusable_label_target_id table: node__field_reusable_label @@ -4729,7 +4397,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -4835,8 +4503,6 @@ display: hide_alter_empty: true fieldset_one: data_field: - eject_rate: eject_rate - node_bulk_form: 0 title: 0 nid: 0 type: 0 @@ -4844,9 +4510,10 @@ display: status: 0 changed: 0 pageviews: 0 - last_updated: 0 operations: 0 + eject_rate: 0 formula: '@eject_rate * 100' + mute_logs: false set_precision: 1 precision: '1' decimal: . @@ -4908,7 +4575,7 @@ display: destination: false eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: nid group_type: group @@ -5402,70 +5069,9 @@ display: hierarchy: false limit: true error_message: true - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -5526,7 +5132,7 @@ display: group_items: { } eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: nid group_type: group @@ -5712,7 +5318,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: sum @@ -5767,10 +5373,10 @@ display: format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: avg admin_label: '' @@ -5878,10 +5484,11 @@ display: pageviews: pageviews total_no: total_no field_organizations: 0 - nos_per_1000: 0 + nos_per_1000_cleaned: 0 title: 0 field_parent: 0 formula: '@total_no/@pageviews*1000' + mute_logs: false set_precision: 1 precision: '1' decimal: . @@ -6027,7 +5634,7 @@ display: field_api_classes: false total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: sum @@ -6449,70 +6056,9 @@ display: hierarchy: false limit: true error_message: true - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: sum @@ -6571,10 +6117,10 @@ display: default_group: All default_group_multiple: { } group_items: { } - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: avg admin_label: '' @@ -6587,17 +6133,17 @@ display: group: 1 exposed: true expose: - operator_id: nos_per_1000_op + operator_id: nos_per_1000_cleaned_op label: 'Avg No''s per 1000 Pageviews' description: '' use_operator: true - operator: nos_per_1000_op + operator: nos_per_1000_cleaned_op operator_limit_selection: true operator_list: '<=': '<=' '>=': '>=' between: between - identifier: nos_per_1000 + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -7139,125 +6685,9 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score - relationship: vid - group_type: group - admin_label: '' - plugin_id: numeric - operator: '<=' - value: - min: '' - max: '' - value: '' - group: 1 - exposed: true - expose: - operator_id: score_op - label: 'Score is less than or equal to' - description: '' - use_operator: false - operator: score_op - operator_limit_selection: false - operator_list: { } - identifier: score - required: false - remember: true - multiple: false - remember_roles: - authenticated: authenticated - anonymous: '0' - author: '0' - editor: '0' - emergency_alert_publisher: '0' - executive_orders: '0' - redirect_creators: '0' - content_team: '0' - developer: '0' - administrator: '0' - tester: '0' - doc_deletion: '0' - min_placeholder: '' - max_placeholder: '' - placeholder: '' - is_grouped: false - group_info: - label: '' - description: '' - identifier: '' - optional: true - widget: select - multiple: false - remember: false - default_group: All - default_group_multiple: { } - group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -7316,10 +6746,10 @@ display: default_group: All default_group_multiple: { } group_items: { } - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' @@ -7332,17 +6762,17 @@ display: group: 1 exposed: true expose: - operator_id: nos_per_1000_op + operator_id: nos_per_1000_cleaned_op label: 'Nos per 1000' description: '' use_operator: true - operator: nos_per_1000_op + operator: nos_per_1000_cleaned_op operator_limit_selection: true operator_list: '<=': '<=' '>=': '>=' between: between - identifier: nos_per_1000 + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -7379,7 +6809,7 @@ display: group_items: { } eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: nid group_type: group @@ -7440,7 +6870,7 @@ display: group_items: { } grade_level: id: grade_level - table: mass_superset_data + table: mass_bigquery_data field: grade_level relationship: nid group_type: group @@ -7501,7 +6931,7 @@ display: group_items: { } broken_links: id: broken_links - table: mass_superset_data + table: mass_bigquery_data field: broken_links relationship: nid group_type: group @@ -7997,7 +7427,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -8052,59 +7482,10 @@ display: format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: vid - group_type: group - admin_label: '' - plugin_id: standard - label: 'Date Snoozed' - exclude: true - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' @@ -8160,7 +7541,7 @@ display: suffix: '' total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: group @@ -8217,7 +7598,7 @@ display: suffix: '' total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: nid group_type: group @@ -8762,70 +8143,9 @@ display: hierarchy: false limit: true error_message: true - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -8884,10 +8204,10 @@ display: default_group: All default_group_multiple: { } group_items: { } - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' @@ -8900,17 +8220,17 @@ display: group: 1 exposed: true expose: - operator_id: nos_per_1000_op + operator_id: nos_per_1000_cleaned_op label: 'No''s per 1000 Pageviews' description: '' use_operator: true - operator: nos_per_1000_op + operator: nos_per_1000_cleaned_op operator_limit_selection: true operator_list: '<=': '<=' '>=': '>=' between: between - identifier: nos_per_1000 + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -8947,7 +8267,7 @@ display: group_items: { } total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: nid group_type: group @@ -8964,7 +8284,7 @@ display: operator_id: total_feedback_op label: 'Minimum # of Feedback responses' description: '' - use_operator: false + use_operator: true operator: total_feedback_op operator_limit_selection: false operator_list: { } @@ -9005,7 +8325,7 @@ display: group_items: { } total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: group @@ -9063,7 +8383,7 @@ display: group_items: { } total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: nid group_type: group diff --git a/conf/drupal/config/views.view.content_reports.yml b/conf/drupal/config/views.view.content_reports.yml index 39742f2bf7..5034f0be93 100644 --- a/conf/drupal/config/views.view.content_reports.yml +++ b/conf/drupal/config/views.view.content_reports.yml @@ -32,7 +32,7 @@ dependencies: - better_exposed_filters - content_moderation - csv_serialization - - mass_superset + - mass_bigquery - mass_views - node - rest @@ -498,7 +498,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group diff --git a/conf/drupal/config/views.view.content_reports_organizations.yml b/conf/drupal/config/views.view.content_reports_organizations.yml index a269aff46b..fe8cc094dc 100644 --- a/conf/drupal/config/views.view.content_reports_organizations.yml +++ b/conf/drupal/config/views.view.content_reports_organizations.yml @@ -36,7 +36,7 @@ dependencies: - content_moderation - csv_serialization - dynamic_entity_reference - - mass_superset + - mass_bigquery - mass_views - node - options @@ -504,7 +504,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group diff --git a/conf/drupal/config/views.view.content_reports_titles.yml b/conf/drupal/config/views.view.content_reports_titles.yml index 2a7435a2c9..aca5bdb80e 100644 --- a/conf/drupal/config/views.view.content_reports_titles.yml +++ b/conf/drupal/config/views.view.content_reports_titles.yml @@ -6,12 +6,13 @@ dependencies: - core.entity_view_mode.node.teaser - field.storage.node.field_short_title module: + - mass_bigquery - mass_formatters - - mass_superset - mass_views - node - user - views_autocomplete_filters + - views_porter_stemmer id: content_reports_titles label: 'Pages with long or short titles' module: views @@ -550,66 +551,9 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score - relationship: none - group_type: group - admin_label: '' - plugin_id: numeric - label: Score - exclude: false - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - set_precision: false - precision: 0 - decimal: . - separator: ',' - format_plural: false - format_plural_string: !!binary MQNAY291bnQ= - prefix: '' - suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group @@ -983,64 +927,6 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score - relationship: none - group_type: group - admin_label: '' - plugin_id: numeric - operator: '=' - value: - min: '' - max: '' - value: '' - group: 1 - exposed: true - expose: - operator_id: score_op - label: Score - description: '' - use_operator: false - operator: score_op - operator_limit_selection: false - operator_list: { } - identifier: score - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - anonymous: '0' - author: '0' - editor: '0' - emergency_alert_publisher: '0' - executive_orders: '0' - redirect_creators: '0' - content_team: '0' - developer: '0' - administrator: '0' - tester: '0' - doc_deletion: '0' - campaign_landing_page_publisher: '0' - d2d_redirect_manager: '0' - external_data_resource_manager: '0' - min_placeholder: '' - max_placeholder: '' - placeholder: '' - is_grouped: false - group_info: - label: '' - description: '' - identifier: '' - optional: true - widget: select - multiple: false - remember: false - default_group: All - default_group_multiple: { } - group_items: { } status: id: status table: node_field_data diff --git a/conf/drupal/config/views.view.feedback_by_organization.yml b/conf/drupal/config/views.view.feedback_by_organization.yml index 8c9f8a97d3..0d9487f47a 100644 --- a/conf/drupal/config/views.view.feedback_by_organization.yml +++ b/conf/drupal/config/views.view.feedback_by_organization.yml @@ -12,7 +12,7 @@ dependencies: - workflows.workflow.topic_page module: - content_moderation - - mass_superset + - mass_bigquery - mass_views - node - taxonomy @@ -491,121 +491,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - pageviews: - id: pageviews - table: mass_superset_data - field: pageviews + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - label: 'Page views (1 month)' - exclude: false - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - set_precision: false - precision: 0 - decimal: . - separator: ',' - format_plural: false - format_plural_string: !!binary MQNAY291bnQ= - prefix: '' - suffix: '' - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: vid - group_type: group - admin_label: '' - plugin_id: standard - label: 'Date Snoozed' - exclude: true - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - score: - id: score - table: mass_superset_data - field: score - relationship: vid - group_type: group - admin_label: '' - plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -654,21 +548,21 @@ display: format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + pageviews: + id: pageviews + table: mass_bigquery_data + field: pageviews relationship: vid group_type: group admin_label: '' plugin_id: numeric - label: 'Nos per 1000' + label: 'Page views (1 month)' exclude: false alter: alter_text: false text: '' - make_link: true - path: 'node/{{ nid }}/feedback' + make_link: false + path: '' absolute: false external: false replace_spaces: false @@ -703,8 +597,8 @@ display: hide_empty: false empty_zero: false hide_alter_empty: true - set_precision: true - precision: 1 + set_precision: false + precision: 0 decimal: . separator: ',' format_plural: false @@ -713,7 +607,7 @@ display: suffix: '' eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: vid group_type: group @@ -770,7 +664,7 @@ display: suffix: '' broken_links: id: broken_links - table: mass_superset_data + table: mass_bigquery_data field: broken_links relationship: vid group_type: group @@ -827,7 +721,7 @@ display: suffix: '' grade_level: id: grade_level - table: mass_superset_data + table: mass_bigquery_data field: grade_level relationship: vid group_type: group @@ -884,7 +778,7 @@ display: suffix: '' total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: vid group_type: group @@ -941,7 +835,7 @@ display: suffix: '' total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: vid group_type: group @@ -998,7 +892,7 @@ display: suffix: '' total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: vid group_type: group @@ -1625,125 +1519,9 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score - relationship: vid - group_type: group - admin_label: '' - plugin_id: numeric - operator: '<=' - value: - min: '' - max: '' - value: '' - group: 1 - exposed: true - expose: - operator_id: score_op - label: 'Score is less than or equal to' - description: '' - use_operator: false - operator: score_op - operator_limit_selection: false - operator_list: { } - identifier: score - required: false - remember: true - multiple: false - remember_roles: - authenticated: authenticated - anonymous: '0' - author: '0' - editor: '0' - emergency_alert_publisher: '0' - executive_orders: '0' - redirect_creators: '0' - content_team: '0' - developer: '0' - administrator: '0' - tester: '0' - doc_deletion: '0' - min_placeholder: '' - max_placeholder: '' - placeholder: '' - is_grouped: false - group_info: - label: '' - description: '' - identifier: '' - optional: true - widget: select - multiple: false - remember: false - default_group: All - default_group_multiple: { } - group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -1802,10 +1580,10 @@ display: default_group: All default_group_multiple: { } group_items: { } - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' @@ -1818,17 +1596,14 @@ display: group: 1 exposed: true expose: - operator_id: nos_per_1000_op - label: 'Nos per 1000' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' - use_operator: true - operator: nos_per_1000_op - operator_limit_selection: true - operator_list: - '<=': '<=' - '>=': '>=' - between: between - identifier: nos_per_1000 + use_operator: false + operator: nos_per_1000_cleaned_op + operator_limit_selection: false + operator_list: { } + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -1865,7 +1640,7 @@ display: group_items: { } eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: nid group_type: group @@ -1926,7 +1701,7 @@ display: group_items: { } grade_level: id: grade_level - table: mass_superset_data + table: mass_bigquery_data field: grade_level relationship: nid group_type: group @@ -1987,7 +1762,7 @@ display: group_items: { } broken_links: id: broken_links - table: mass_superset_data + table: mass_bigquery_data field: broken_links relationship: nid group_type: group @@ -2048,7 +1823,7 @@ display: group_items: { } total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: nid group_type: group @@ -2109,7 +1884,7 @@ display: group_items: { } total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: group @@ -2170,7 +1945,7 @@ display: group_items: { } total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: nid group_type: group @@ -2238,118 +2013,118 @@ display: options: row_class: '' default_row_class: true - override: 1 - sticky: 0 - caption: '' - summary: '' - description: '' columns: field_organizations: field_organizations pageviews: pageviews - nos_per_1000: nos_per_1000 + nos_per_1000_cleaned: nos_per_1000_cleaned field_views_simple_math_field: field_views_simple_math_field title: title field_parent: field_parent total_no: total_no + default: nos_per_1000_cleaned info: field_organizations: align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' pageviews: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' - nos_per_1000: - sortable: 1 + nos_per_1000_cleaned: + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' field_views_simple_math_field: - sortable: 0 + sortable: false default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' title: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' field_parent: - sortable: 0 + sortable: false default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' total_no: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' - default: nos_per_1000 - empty_table: 0 + override: true + sticky: false + summary: '' + empty_table: false + caption: '' + description: '' group_aggregation: group_aggregation_results: '0' grouping_field_class: '' @@ -2358,7 +2133,7 @@ display: grouping_row_class: '' column_aggregation: totals_row_position: - 2: '2' + 2: 2 1: 0 3: 0 totals_per_page: '1' @@ -2534,7 +2309,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: sum @@ -2589,11 +2364,11 @@ display: format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 - relationship: vid + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned + relationship: nid group_type: avg admin_label: '' plugin_id: numeric @@ -2635,7 +2410,7 @@ display: element_wrapper_class: '' element_default_classes: true empty: '' - hide_empty: false + hide_empty: true empty_zero: false hide_alter_empty: true set_precision: true @@ -2700,10 +2475,11 @@ display: pageviews: pageviews total_no: total_no field_organizations: 0 - nos_per_1000: 0 + nos_per_1000_cleaned: 0 title: 0 field_parent: 0 formula: '@total_no/@pageviews*1000' + mute_logs: false set_precision: 1 precision: '1' decimal: . @@ -2849,7 +2625,7 @@ display: field_api_classes: false total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: sum @@ -3271,70 +3047,9 @@ display: hierarchy: false limit: true error_message: true - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: sum @@ -3393,10 +3108,10 @@ display: default_group: All default_group_multiple: { } group_items: { } - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: avg admin_label: '' @@ -3409,17 +3124,17 @@ display: group: 1 exposed: true expose: - operator_id: nos_per_1000_op + operator_id: nos_per_1000_cleaned_op label: 'Avg No''s per 1000 Pageviews' description: '' use_operator: true - operator: nos_per_1000_op + operator: nos_per_1000_cleaned_op operator_limit_selection: true operator_list: '<=': '<=' '>=': '>=' between: between - identifier: nos_per_1000 + identifier: nos_per_1000_cleaned required: false remember: true multiple: false diff --git a/conf/drupal/config/views.view.mass_dashboard_content.yml b/conf/drupal/config/views.view.mass_dashboard_content.yml index f9ed4895d2..0bb39dcd0b 100644 --- a/conf/drupal/config/views.view.mass_dashboard_content.yml +++ b/conf/drupal/config/views.view.mass_dashboard_content.yml @@ -43,12 +43,13 @@ dependencies: - workflows.workflow.topic_page module: - content_moderation - - mass_superset + - mass_bigquery - mass_views - node - taxonomy - user - views_autocomplete_filters + - views_porter_stemmer id: mass_dashboard_content label: 'Mass Dashboard Content' module: views @@ -647,15 +648,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -693,7 +694,7 @@ display: element_wrapper_class: '' element_default_classes: true empty: '' - hide_empty: false + hide_empty: true empty_zero: false hide_alter_empty: true set_precision: true @@ -706,7 +707,7 @@ display: suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -1264,15 +1265,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -1280,14 +1281,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -1304,6 +1305,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' diff --git a/conf/drupal/config/views.view.mass_dashboard_needs_review.yml b/conf/drupal/config/views.view.mass_dashboard_needs_review.yml index d3ea49a87e..b64989c22c 100644 --- a/conf/drupal/config/views.view.mass_dashboard_needs_review.yml +++ b/conf/drupal/config/views.view.mass_dashboard_needs_review.yml @@ -42,7 +42,7 @@ dependencies: - workflows.workflow.editorial module: - content_moderation - - mass_superset + - mass_bigquery - mass_views - node - taxonomy @@ -661,15 +661,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -720,7 +720,7 @@ display: suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -1390,15 +1390,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -1406,14 +1406,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -1430,6 +1430,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' diff --git a/conf/drupal/config/views.view.mass_dashboard_trash.yml b/conf/drupal/config/views.view.mass_dashboard_trash.yml index 5e6bced5c5..b0c5f3fcbe 100644 --- a/conf/drupal/config/views.view.mass_dashboard_trash.yml +++ b/conf/drupal/config/views.view.mass_dashboard_trash.yml @@ -42,7 +42,7 @@ dependencies: - workflows.workflow.topic_page module: - content_moderation - - mass_superset + - mass_bigquery - mass_views - node - taxonomy @@ -588,15 +588,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -647,13 +647,13 @@ display: suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group admin_label: '' plugin_id: numeric - label: 'Page views (1 month)' + label: 'Page views' exclude: false alter: alter_text: false @@ -1245,15 +1245,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -1261,16 +1261,16 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false - remember: true + remember: false multiple: false remember_roles: authenticated: authenticated @@ -1285,6 +1285,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' diff --git a/conf/drupal/config/views.view.my_content.yml b/conf/drupal/config/views.view.my_content.yml index 4f79f4d08b..cb23c4b0e2 100644 --- a/conf/drupal/config/views.view.my_content.yml +++ b/conf/drupal/config/views.view.my_content.yml @@ -47,7 +47,7 @@ dependencies: module: - content_moderation - flag - - mass_superset + - mass_bigquery - mass_views - node - taxonomy @@ -653,15 +653,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -712,7 +712,7 @@ display: suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -1281,30 +1281,32 @@ display: default_group: All default_group_multiple: { } group_items: { } - node_org_filter: - id: node_org_filter - table: node_field_data - field: node_org_filter + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' - entity_type: node - plugin_id: mass_views_node_org_filter - operator: '=' - value: null + plugin_id: numeric + operator: '>=' + value: + min: '' + max: '' + value: '' group: 1 exposed: true expose: - operator_id: '' - label: 'Organization Filter' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: node_org_filter_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: node_org_filter + identifier: nos_per_1000_cleaned required: false - remember: false + remember: true multiple: false remember_roles: authenticated: authenticated @@ -1319,6 +1321,12 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' + min_placeholder: '' + max_placeholder: '' + placeholder: '' is_grouped: false group_info: label: '' @@ -1331,32 +1339,30 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + node_org_filter: + id: node_org_filter + table: node_field_data + field: node_org_filter relationship: vid group_type: group admin_label: '' - plugin_id: numeric - operator: '<=' - value: - min: '' - max: '' - value: '' + entity_type: node + plugin_id: mass_views_node_org_filter + operator: '=' + value: null group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: '' + label: 'Organization Filter' description: '' use_operator: false - operator: score_op + operator: node_org_filter_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: node_org_filter required: false - remember: true + remember: false multiple: false remember_roles: authenticated: authenticated @@ -1371,9 +1377,6 @@ display: administrator: '0' tester: '0' doc_deletion: '0' - min_placeholder: '' - max_placeholder: '' - placeholder: '' is_grouped: false group_info: label: '' @@ -2702,15 +2705,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -2761,7 +2764,7 @@ display: suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -3336,15 +3339,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -3352,14 +3355,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -3376,6 +3379,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' diff --git a/conf/drupal/config/views.view.orphaned_service_details.yml b/conf/drupal/config/views.view.orphaned_service_details.yml index 49b6d27288..ba4f4040a8 100644 --- a/conf/drupal/config/views.view.orphaned_service_details.yml +++ b/conf/drupal/config/views.view.orphaned_service_details.yml @@ -11,7 +11,7 @@ dependencies: - user.role.content_team - user.role.developer module: - - mass_superset + - mass_bigquery - node - taxonomy - user @@ -346,15 +346,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: none group_type: group admin_label: '' - plugin_id: standard - label: Score + plugin_id: numeric + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -395,22 +395,22 @@ display: hide_empty: true empty_zero: false hide_alter_empty: true - set_precision: 1 - precision: '1' + set_precision: true + precision: 1 decimal: . separator: ',' - format_plural: 0 + format_plural: false format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group admin_label: '' - plugin_id: standard + plugin_id: numeric label: 'Page views (1 month)' exclude: false alter: @@ -452,6 +452,14 @@ display: hide_empty: false empty_zero: false hide_alter_empty: true + set_precision: false + precision: 0 + decimal: . + separator: ',' + format_plural: false + format_plural_string: !!binary MQNAY291bnQ= + prefix: '' + suffix: '' created: id: created table: node_field_revision @@ -840,15 +848,15 @@ display: hierarchy: false limit: true error_message: true - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: none group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -856,14 +864,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: false multiple: false @@ -880,6 +888,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' diff --git a/conf/drupal/config/views.view.pages_with_high_negative_feedback.yml b/conf/drupal/config/views.view.pages_with_high_negative_feedback.yml index 187542d63c..7affd8aed8 100644 --- a/conf/drupal/config/views.view.pages_with_high_negative_feedback.yml +++ b/conf/drupal/config/views.view.pages_with_high_negative_feedback.yml @@ -10,7 +10,7 @@ dependencies: - workflows.workflow.topic_page module: - content_moderation - - mass_superset + - mass_bigquery - mass_views - node - taxonomy @@ -490,7 +490,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -545,64 +545,15 @@ display: format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: vid - group_type: group - admin_label: '' - plugin_id: standard - label: 'Date Snoozed' - exclude: true - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -651,66 +602,9 @@ display: format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 - relationship: vid - group_type: group - admin_label: '' - plugin_id: numeric - label: 'Nos per 1000' - exclude: false - alter: - alter_text: false - text: '' - make_link: true - path: 'node/{{ nid }}/feedback' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - set_precision: true - precision: 1 - decimal: . - separator: ',' - format_plural: false - format_plural_string: !!binary MQNAY291bnQ= - prefix: '' - suffix: '' eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: vid group_type: group @@ -767,7 +661,7 @@ display: suffix: '' broken_links: id: broken_links - table: mass_superset_data + table: mass_bigquery_data field: broken_links relationship: vid group_type: group @@ -824,7 +718,7 @@ display: suffix: '' grade_level: id: grade_level - table: mass_superset_data + table: mass_bigquery_data field: grade_level relationship: vid group_type: group @@ -881,7 +775,7 @@ display: suffix: '' total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: vid group_type: group @@ -938,7 +832,7 @@ display: suffix: '' total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: vid group_type: group @@ -995,7 +889,7 @@ display: suffix: '' total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: vid group_type: group @@ -1622,15 +1516,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -1638,14 +1532,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -1662,6 +1556,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' @@ -1677,70 +1574,9 @@ display: default_group: All default_group_multiple: { } group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -1799,70 +1635,9 @@ display: default_group: All default_group_multiple: { } group_items: { } - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 - relationship: nid - group_type: group - admin_label: '' - plugin_id: numeric - operator: '>=' - value: - min: '' - max: '' - value: '' - group: 1 - exposed: true - expose: - operator_id: nos_per_1000_op - label: 'Nos per 1000' - description: '' - use_operator: true - operator: nos_per_1000_op - operator_limit_selection: true - operator_list: - '<=': '<=' - '>=': '>=' - between: between - identifier: nos_per_1000 - required: false - remember: true - multiple: false - remember_roles: - authenticated: authenticated - anonymous: '0' - author: '0' - editor: '0' - emergency_alert_publisher: '0' - executive_orders: '0' - redirect_creators: '0' - content_team: '0' - developer: '0' - administrator: '0' - tester: '0' - doc_deletion: '0' - d2d_redirect_manager: '0' - data_administrator: '0' - collection_administrator: '0' - min_placeholder: '' - max_placeholder: '' - placeholder: '' - is_grouped: false - group_info: - label: '' - description: '' - identifier: '' - optional: true - widget: select - multiple: false - remember: false - default_group: All - default_group_multiple: { } - group_items: { } eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: nid group_type: group @@ -1923,7 +1698,7 @@ display: group_items: { } grade_level: id: grade_level - table: mass_superset_data + table: mass_bigquery_data field: grade_level relationship: nid group_type: group @@ -1984,7 +1759,7 @@ display: group_items: { } broken_links: id: broken_links - table: mass_superset_data + table: mass_bigquery_data field: broken_links relationship: nid group_type: group @@ -2045,7 +1820,7 @@ display: group_items: { } total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: nid group_type: group @@ -2106,7 +1881,7 @@ display: group_items: { } total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: group @@ -2167,7 +1942,7 @@ display: group_items: { } total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: nid group_type: group @@ -2235,11 +2010,6 @@ display: options: row_class: '' default_row_class: true - override: 1 - sticky: 0 - caption: '' - summary: '' - description: '' columns: title: title nid: nid @@ -2247,151 +2017,156 @@ display: status: status changed: changed pageviews: pageviews - nos_per_1000: nos_per_1000 + nos_per_1000_cleaned: nos_per_1000_cleaned total_no: total_no total_yes: total_yes operations: operations + default: nos_per_1000_cleaned info: title: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' nid: - sortable: 0 + sortable: false default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' type: - sortable: 1 + sortable: true default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' status: - sortable: 1 + sortable: true default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' changed: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' pageviews: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' - nos_per_1000: - sortable: 1 + nos_per_1000_cleaned: + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' total_no: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' total_yes: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' operations: align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' - default: nos_per_1000 - empty_table: 0 + override: true + sticky: false + summary: '' + empty_table: false + caption: '' + description: '' group_aggregation: group_aggregation_results: '0' grouping_field_class: '' @@ -2400,7 +2175,7 @@ display: grouping_row_class: '' column_aggregation: totals_row_position: - 2: '2' + 2: 2 1: 0 3: 0 totals_per_page: '1' @@ -2843,7 +2618,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -2898,10 +2673,10 @@ display: format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: vid group_type: group admin_label: '' @@ -2944,7 +2719,7 @@ display: element_wrapper_class: '' element_default_classes: true empty: '' - hide_empty: false + hide_empty: true empty_zero: false hide_alter_empty: true set_precision: true @@ -2957,7 +2732,7 @@ display: suffix: '' total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: group @@ -3014,7 +2789,7 @@ display: suffix: '' total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: nid group_type: group @@ -3561,7 +3336,7 @@ display: error_message: true pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -3620,10 +3395,10 @@ display: default_group: All default_group_multiple: { } group_items: { } - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' @@ -3636,17 +3411,17 @@ display: group: 1 exposed: true expose: - operator_id: nos_per_1000_op + operator_id: nos_per_1000_cleaned_op label: 'No’s per 1K page views' description: '' use_operator: true - operator: nos_per_1000_op + operator: nos_per_1000_cleaned_op operator_limit_selection: true operator_list: '<=': '<=' '>=': '>=' between: between - identifier: nos_per_1000 + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -3683,7 +3458,7 @@ display: group_items: { } total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: nid group_type: group @@ -3741,7 +3516,7 @@ display: group_items: { } total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: group @@ -3799,7 +3574,7 @@ display: group_items: { } total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: nid group_type: group diff --git a/conf/drupal/config/views.view.pages_with_high_number_of_ejects.yml b/conf/drupal/config/views.view.pages_with_high_number_of_ejects.yml index 9c0629911f..a7fedd79fd 100644 --- a/conf/drupal/config/views.view.pages_with_high_number_of_ejects.yml +++ b/conf/drupal/config/views.view.pages_with_high_number_of_ejects.yml @@ -10,7 +10,7 @@ dependencies: - workflows.workflow.topic_page module: - content_moderation - - mass_superset + - mass_bigquery - mass_views - node - taxonomy @@ -488,121 +488,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - pageviews: - id: pageviews - table: mass_superset_data - field: pageviews - relationship: vid - group_type: group - admin_label: '' - plugin_id: numeric - label: 'Page views (1 month)' - exclude: false - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - set_precision: false - precision: 0 - decimal: . - separator: ',' - format_plural: false - format_plural_string: !!binary MQNAY291bnQ= - prefix: '' - suffix: '' - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: vid - group_type: group - admin_label: '' - plugin_id: standard - label: 'Date Snoozed' - exclude: true - alter: - alter_text: false - text: '' - make_link: false - path: '' - absolute: false - external: false - replace_spaces: false - path_case: none - trim_whitespace: false - alt: '' - rel: '' - link_class: '' - prefix: '' - suffix: '' - target: '' - nl2br: false - max_length: 0 - word_boundary: true - ellipsis: true - more_link: false - more_link_text: '' - more_link_path: '' - strip_tags: false - trim: false - preserve_tags: '' - html: false - element_type: '' - element_class: '' - element_label_type: '' - element_label_class: '' - element_label_colon: true - element_wrapper_type: '' - element_wrapper_class: '' - element_default_classes: true - empty: '' - hide_empty: false - empty_zero: false - hide_alter_empty: true - score: - id: score - table: mass_superset_data - field: score - relationship: vid + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned + relationship: nid group_type: group admin_label: '' plugin_id: numeric - label: Score + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -651,21 +545,21 @@ display: format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 + pageviews: + id: pageviews + table: mass_bigquery_data + field: pageviews relationship: vid group_type: group admin_label: '' plugin_id: numeric - label: 'Nos per 1000' + label: 'Page views (1 month)' exclude: false alter: alter_text: false text: '' - make_link: true - path: 'node/{{ nid }}/feedback' + make_link: false + path: '' absolute: false external: false replace_spaces: false @@ -700,8 +594,8 @@ display: hide_empty: false empty_zero: false hide_alter_empty: true - set_precision: true - precision: 1 + set_precision: false + precision: 0 decimal: . separator: ',' format_plural: false @@ -710,7 +604,7 @@ display: suffix: '' eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: vid group_type: group @@ -767,7 +661,7 @@ display: suffix: '' broken_links: id: broken_links - table: mass_superset_data + table: mass_bigquery_data field: broken_links relationship: vid group_type: group @@ -824,7 +718,7 @@ display: suffix: '' grade_level: id: grade_level - table: mass_superset_data + table: mass_bigquery_data field: grade_level relationship: vid group_type: group @@ -881,7 +775,7 @@ display: suffix: '' total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: vid group_type: group @@ -938,7 +832,7 @@ display: suffix: '' total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: vid group_type: group @@ -995,7 +889,7 @@ display: suffix: '' total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: vid group_type: group @@ -1622,15 +1516,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score - relationship: vid + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned + relationship: nid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -1638,14 +1532,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: true multiple: false @@ -1662,6 +1556,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' @@ -1677,70 +1574,9 @@ display: default_group: All default_group_multiple: { } group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -1799,70 +1635,9 @@ display: default_group: All default_group_multiple: { } group_items: { } - nos_per_1000: - id: nos_per_1000 - table: mass_superset_data - field: nos_per_1000 - relationship: nid - group_type: group - admin_label: '' - plugin_id: numeric - operator: '>=' - value: - min: '' - max: '' - value: '' - group: 1 - exposed: true - expose: - operator_id: nos_per_1000_op - label: 'Nos per 1000' - description: '' - use_operator: true - operator: nos_per_1000_op - operator_limit_selection: true - operator_list: - '<=': '<=' - '>=': '>=' - between: between - identifier: nos_per_1000 - required: false - remember: true - multiple: false - remember_roles: - authenticated: authenticated - anonymous: '0' - author: '0' - editor: '0' - emergency_alert_publisher: '0' - executive_orders: '0' - redirect_creators: '0' - content_team: '0' - developer: '0' - administrator: '0' - tester: '0' - doc_deletion: '0' - d2d_redirect_manager: '0' - data_administrator: '0' - collection_administrator: '0' - min_placeholder: '' - max_placeholder: '' - placeholder: '' - is_grouped: false - group_info: - label: '' - description: '' - identifier: '' - optional: true - widget: select - multiple: false - remember: false - default_group: All - default_group_multiple: { } - group_items: { } eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: nid group_type: group @@ -1923,7 +1698,7 @@ display: group_items: { } grade_level: id: grade_level - table: mass_superset_data + table: mass_bigquery_data field: grade_level relationship: nid group_type: group @@ -1984,7 +1759,7 @@ display: group_items: { } broken_links: id: broken_links - table: mass_superset_data + table: mass_bigquery_data field: broken_links relationship: nid group_type: group @@ -2045,7 +1820,7 @@ display: group_items: { } total_feedback: id: total_feedback - table: mass_superset_data + table: mass_bigquery_data field: total_feedback relationship: nid group_type: group @@ -2106,7 +1881,7 @@ display: group_items: { } total_no: id: total_no - table: mass_superset_data + table: mass_bigquery_data field: total_no relationship: nid group_type: group @@ -2167,7 +1942,7 @@ display: group_items: { } total_yes: id: total_yes - table: mass_superset_data + table: mass_bigquery_data field: total_yes relationship: nid group_type: group @@ -2235,11 +2010,6 @@ display: options: row_class: '' default_row_class: true - override: 1 - sticky: 0 - caption: '' - summary: '' - description: '' columns: title: title nid: nid @@ -2250,133 +2020,138 @@ display: pageviews: pageviews eject_rate: eject_rate operations: operations + default: eject_rate info: title: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' nid: - sortable: 0 + sortable: false default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' type: - sortable: 1 + sortable: true default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' uid: - sortable: 0 + sortable: false default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' status: - sortable: 1 + sortable: true default_sort_order: asc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' changed: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' pageviews: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' eject_rate: - sortable: 1 + sortable: true default_sort_order: desc align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' operations: align: '' separator: '' - empty_column: 0 + empty_column: false responsive: '' - has_aggr: 0 + has_aggr: false aggr: views_aggregator_first: views_aggregator_first aggr_par: '' - has_aggr_column: 0 + has_aggr_column: false aggr_column: views_aggregator_sum aggr_par_column: '' - default: eject_rate - empty_table: 0 + override: true + sticky: false + summary: '' + empty_table: false + caption: '' + description: '' group_aggregation: group_aggregation_results: '0' grouping_field_class: '' @@ -2385,7 +2160,7 @@ display: grouping_row_class: '' column_aggregation: totals_row_position: - 2: '2' + 2: 2 1: 0 3: 0 totals_per_page: '1' @@ -2893,7 +2668,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -2950,7 +2725,7 @@ display: suffix: '' eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: nid group_type: group @@ -3000,7 +2775,7 @@ display: set_precision: true precision: 2 decimal: . - separator: '' + separator: ',' format_plural: false format_plural_string: !!binary MQNAY291bnQ= prefix: '' @@ -3495,70 +3270,9 @@ display: hierarchy: false limit: true error_message: true - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group @@ -3619,7 +3333,7 @@ display: group_items: { } eject_rate: id: eject_rate - table: mass_superset_data + table: mass_bigquery_data field: eject_rate relationship: nid group_type: group diff --git a/conf/drupal/config/views.view.parent_reports.yml b/conf/drupal/config/views.view.parent_reports.yml index 3e8e44a744..0a83c49bfe 100644 --- a/conf/drupal/config/views.view.parent_reports.yml +++ b/conf/drupal/config/views.view.parent_reports.yml @@ -35,7 +35,7 @@ dependencies: module: - csv_serialization - entity_hierarchy - - mass_superset + - mass_bigquery - mass_views - node - rest @@ -456,7 +456,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group @@ -1487,7 +1487,7 @@ display: hide_alter_empty: true pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group @@ -2321,7 +2321,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group @@ -3418,7 +3418,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group @@ -4589,7 +4589,7 @@ display: hide_alter_empty: true pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group @@ -5449,7 +5449,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group @@ -6519,7 +6519,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group diff --git a/conf/drupal/config/views.view.report_orphaned_content.yml b/conf/drupal/config/views.view.report_orphaned_content.yml index 3d2065ca77..17142fb42f 100644 --- a/conf/drupal/config/views.view.report_orphaned_content.yml +++ b/conf/drupal/config/views.view.report_orphaned_content.yml @@ -35,7 +35,7 @@ dependencies: - content_moderation - csv_serialization - entity_usage - - mass_superset + - mass_bigquery - mass_views - node - rest @@ -715,7 +715,7 @@ display: suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group @@ -1270,122 +1270,6 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score - relationship: vid - group_type: group - admin_label: '' - plugin_id: numeric - operator: '<=' - value: - min: '' - max: '' - value: '' - group: 1 - exposed: true - expose: - operator_id: score_op - label: 'Score is less than or equal to' - description: '' - use_operator: false - operator: score_op - operator_limit_selection: false - operator_list: { } - identifier: score - required: false - remember: true - multiple: false - remember_roles: - authenticated: authenticated - anonymous: '0' - author: '0' - editor: '0' - emergency_alert_publisher: '0' - executive_orders: '0' - redirect_creators: '0' - content_team: '0' - developer: '0' - administrator: '0' - tester: '0' - doc_deletion: '0' - min_placeholder: '' - max_placeholder: '' - placeholder: '' - is_grouped: false - group_info: - label: '' - description: '' - identifier: '' - optional: true - widget: select - multiple: false - remember: false - default_group: All - default_group_multiple: { } - group_items: { } - last_updated: - id: last_updated - table: snooze - field: last_updated - relationship: none - group_type: group - admin_label: '' - plugin_id: date - operator: '=' - value: - min: '' - max: '' - value: '' - type: date - group: 1 - exposed: true - expose: - operator_id: last_updated_op - label: Snoozed - description: null - use_operator: false - operator: last_updated_op - operator_limit_selection: false - operator_list: { } - identifier: last_updated - required: false - remember: false - multiple: false - remember_roles: - authenticated: authenticated - min_placeholder: null - max_placeholder: null - placeholder: null - is_grouped: true - group_info: - label: Snoozed - description: '' - identifier: last_updated - optional: true - widget: select - multiple: false - remember: true - default_group: All - default_group_multiple: { } - group_items: - 1: - title: 'Yes' - operator: '>=' - value: - min: '' - max: '' - value: '-2 weeks' - type: offset - 3: - title: 'No' - operator: empty - value: - min: '' - max: '' - value: '' - type: date filter_groups: operator: AND groups: @@ -3545,7 +3429,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: vid group_type: group diff --git a/conf/drupal/config/views.view.scheduled_content_revisions.yml b/conf/drupal/config/views.view.scheduled_content_revisions.yml index db84e8767c..1c65e5da59 100644 --- a/conf/drupal/config/views.view.scheduled_content_revisions.yml +++ b/conf/drupal/config/views.view.scheduled_content_revisions.yml @@ -6,11 +6,12 @@ dependencies: - taxonomy.vocabulary.label module: - content_moderation - - mass_superset + - mass_bigquery - node - taxonomy - user - views_autocomplete_filters + - views_porter_stemmer id: scheduled_content_revisions label: 'Scheduled Content Revisions' module: views @@ -543,15 +544,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' - plugin_id: standard - label: Score + plugin_id: numeric + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -592,22 +593,22 @@ display: hide_empty: true empty_zero: false hide_alter_empty: true - set_precision: 1 - precision: '1' + set_precision: true + precision: 1 decimal: . separator: ',' - format_plural: 0 + format_plural: false format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: nid group_type: group admin_label: '' - plugin_id: standard + plugin_id: numeric label: 'Page views (1 month)' exclude: false alter: @@ -649,6 +650,14 @@ display: hide_empty: false empty_zero: false hide_alter_empty: true + set_precision: false + precision: 0 + decimal: . + separator: ',' + format_plural: false + format_plural_string: !!binary MQNAY291bnQ= + prefix: '' + suffix: '' operations: id: operations table: node @@ -952,15 +961,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: nid group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -968,14 +977,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: false multiple: false @@ -992,6 +1001,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' diff --git a/conf/drupal/config/views.view.visitor_help_pages.yml b/conf/drupal/config/views.view.visitor_help_pages.yml index 6be2e55ffb..74a26d59b8 100644 --- a/conf/drupal/config/views.view.visitor_help_pages.yml +++ b/conf/drupal/config/views.view.visitor_help_pages.yml @@ -8,7 +8,7 @@ dependencies: - node.type.org_page module: - link - - mass_superset + - mass_bigquery - node - user id: visitor_help_pages @@ -160,7 +160,7 @@ display: field_api_classes: false pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group diff --git a/conf/drupal/config/views.view.watched_content.yml b/conf/drupal/config/views.view.watched_content.yml index f0fbce3494..d59d9d852b 100644 --- a/conf/drupal/config/views.view.watched_content.yml +++ b/conf/drupal/config/views.view.watched_content.yml @@ -11,11 +11,12 @@ dependencies: module: - content_moderation - flag - - mass_superset + - mass_bigquery - mass_views - node - user - views_autocomplete_filters + - views_porter_stemmer id: watched_content label: 'Watched Content' module: views @@ -382,15 +383,15 @@ display: multi_type: separator separator: ', ' field_api_classes: false - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: none group_type: group admin_label: '' - plugin_id: standard - label: Score + plugin_id: numeric + label: 'Nos per 1000' exclude: false alter: alter_text: false @@ -431,22 +432,22 @@ display: hide_empty: true empty_zero: false hide_alter_empty: true - set_precision: 1 - precision: '1' + set_precision: true + precision: 1 decimal: . separator: ',' - format_plural: 0 + format_plural: false format_plural_string: !!binary MQNAY291bnQ= prefix: '' suffix: '' pageviews: id: pageviews - table: mass_superset_data + table: mass_bigquery_data field: pageviews relationship: none group_type: group admin_label: '' - plugin_id: standard + plugin_id: numeric label: 'Page views (1 month)' exclude: false alter: @@ -488,6 +489,14 @@ display: hide_empty: false empty_zero: false hide_alter_empty: true + set_precision: false + precision: 0 + decimal: . + separator: ',' + format_plural: false + format_plural_string: !!binary MQNAY291bnQ= + prefix: '' + suffix: '' pager: type: mini options: @@ -759,15 +768,15 @@ display: default_group: All default_group_multiple: { } group_items: { } - score: - id: score - table: mass_superset_data - field: score + nos_per_1000_cleaned: + id: nos_per_1000_cleaned + table: mass_bigquery_data + field: nos_per_1000_cleaned relationship: none group_type: group admin_label: '' plugin_id: numeric - operator: '<=' + operator: '>=' value: min: '' max: '' @@ -775,14 +784,14 @@ display: group: 1 exposed: true expose: - operator_id: score_op - label: 'Score is less than or equal to' + operator_id: nos_per_1000_cleaned_op + label: 'Nos per 1000 is greater than or equal to' description: '' use_operator: false - operator: score_op + operator: nos_per_1000_cleaned_op operator_limit_selection: false operator_list: { } - identifier: score + identifier: nos_per_1000_cleaned required: false remember: false multiple: false @@ -799,6 +808,9 @@ display: administrator: '0' tester: '0' doc_deletion: '0' + d2d_redirect_manager: '0' + data_administrator: '0' + collection_administrator: '0' min_placeholder: '' max_placeholder: '' placeholder: '' diff --git a/docroot/modules/custom/mass_bigquery/mass_bigquery.views.inc b/docroot/modules/custom/mass_bigquery/mass_bigquery.views.inc new file mode 100644 index 0000000000..9f7f41f668 --- /dev/null +++ b/docroot/modules/custom/mass_bigquery/mass_bigquery.views.inc @@ -0,0 +1,180 @@ + [ + 'type' => 'LEFT', + 'left_field' => 'nid', + 'field' => 'nid', + ], + ]; + + $data['mass_bigquery_data']['nid'] = [ + 'title' => t('Node ID'), + 'help' => t('The nid of the node entity.'), + 'field' => [ + 'id' => 'standard', + ], + ]; + + $data['mass_bigquery_data']['pageviews'] = [ + 'title' => t('Page views'), + 'help' => t('The pageviews for the node entity.'), + 'field' => [ + 'id' => 'numeric', + ], + 'filter' => [ + 'title' => t('Page views'), + 'help' => t('Limit pages to those with a certain number of pageviews.'), + 'field' => 'pageviews', + 'id' => 'numeric', + ], + ]; + + $data['mass_bigquery_data']['nos_per_1000_cleaned'] = [ + 'title' => t('Nos per 1000 cleaned'), + 'help' => t('Nos per 1000 cleaned'), + 'field' => [ + 'id' => 'numeric', + 'float' => TRUE, + ], + 'filter' => [ + 'title' => t('Nos per 1000 cleaned'), + 'help' => t('Specify the range of values to show.'), + 'field' => 'nos_per_1000_cleaned', + 'id' => 'numeric', + ], + ]; + + $data['mass_bigquery_data']['last_updated'] = [ + 'title' => t('Last Updated'), + 'help' => t('The UNIX time stamp representing when the node was last updated.'), + 'field' => [ + 'id' => 'standard', + ], + ]; + + $data['mass_bigquery_data']['nos_per_1000'] = [ + 'title' => t('Nos per 1000'), + 'help' => t('The number of No responses per 1000.'), + 'field' => [ + 'id' => 'numeric', + 'float' => TRUE, + ], + 'filter' => [ + 'title' => t('Nos per 1000'), + 'help' => t('Limit pages to those with a certain number of Nos per 1000.'), + 'field' => 'nos_per_1000', + 'id' => 'numeric', + ], + ]; + + $data['mass_bigquery_data']['eject_rate'] = [ + 'title' => t('Eject Rate'), + 'help' => t('The eject rate.'), + 'field' => [ + 'id' => 'numeric', + 'float' => TRUE, + ], + 'filter' => [ + 'title' => t('Eject Rate'), + 'help' => t('Limit pages to those with a certain eject rate.'), + 'field' => 'eject_rate', + 'id' => 'numeric', + ], + ]; + + $data['mass_bigquery_data']['broken_links'] = [ + 'title' => t('Broken Links'), + 'help' => t('The number of broken links.'), + 'field' => [ + 'id' => 'numeric', + 'float' => FALSE, + ], + 'filter' => [ + 'title' => t('Broken Links'), + 'help' => t('Limit pages to those with a certain rate of broken links.'), + 'field' => 'broken_links', + 'id' => 'numeric', + ], + ]; + + $data['mass_bigquery_data']['grade_level'] = [ + 'title' => t('Reading Level'), + 'help' => t('The grade reading level.'), + 'field' => [ + 'id' => 'numeric', + 'float' => FALSE, + ], + 'filter' => [ + 'title' => t('Reading Level'), + 'help' => t('Limit pages to those with a certain reading level.'), + 'field' => 'grade_level', + 'id' => 'numeric', + ], + ]; + + $data['mass_bigquery_data']['total_no'] = [ + 'title' => t('Total No'), + 'help' => t('The total number of no responses by month.'), + 'field' => [ + 'id' => 'numeric', + 'float' => TRUE, + ], + 'filter' => [ + 'title' => t('Total No'), + 'help' => t('Limit pages to those with a certain number of no responses by month.'), + 'field' => 'total_no', + 'id' => 'numeric', + ], + ]; + + $data['mass_bigquery_data']['total_yes'] = [ + 'title' => t('Total Yes'), + 'help' => t('The total number of yes responses by month.'), + 'field' => [ + 'id' => 'numeric', + 'float' => TRUE, + ], + 'filter' => [ + 'title' => t('Total Yes'), + 'help' => t('Limit pages to those with a certain number of yes responses by month.'), + 'field' => 'total_yes', + 'id' => 'numeric', + ], + ]; + + $data['mass_bigquery_data']['total_feedback'] = [ + 'title' => t('Total Feedback'), + 'help' => t('The total feedback for month.'), + 'field' => [ + 'id' => 'numeric', + 'float' => TRUE, + ], + 'filter' => [ + 'title' => t('Total Feedback'), + 'help' => t('Limit pages to those with a certain number of feedback by month.'), + 'field' => 'total_feedback', + 'id' => 'numeric', + ], + ]; + + return $data; +} From d63739ea0e82a0f3ac1539751d4393a56a616f21 Mon Sep 17 00:00:00 2001 From: Robert Tyler Stephens Date: Mon, 11 Sep 2023 17:01:16 -0400 Subject: [PATCH 29/32] DP-29493: Fix default domain URLs from migration (#2174) * DP-29493: Fix default domain URLs from migration * DP-29493: Add changelog --- changelogs/DP-29493.yml | 41 + .../mass_migrate/src/fix_default_urls.php | 14611 ++++++++++++++++ 2 files changed, 14652 insertions(+) create mode 100644 changelogs/DP-29493.yml create mode 100644 docroot/modules/custom/mass_migrate/src/fix_default_urls.php diff --git a/changelogs/DP-29493.yml b/changelogs/DP-29493.yml new file mode 100644 index 0000000000..be127d5736 --- /dev/null +++ b/changelogs/DP-29493.yml @@ -0,0 +1,41 @@ +# +# Write your changelog entry here. Every pull request must have a changelog yml file. +# +# Change types: +# ############################################################################# +# You can use one of the following types: +# - Added: For new features. +# - Changed: For changes to existing functionality. +# - Deprecated: For soon-to-be removed features. +# - Removed: For removed features. +# - Fixed: For any bug fixes. +# - Security: In case of vulnerabilities. +# +# Format +# ############################################################################# +# The format is crucial. Please follow the examples below. For reference, the requirements are: +# - All 3 parts are required and you must include "Type", "description" and "issue". +# - "Type" must be left aligned and followed by a colon. +# - "description" must be indented with 2 spaces followed by a colon +# - "issue" must be indented with 4 spaces followed by a colon. +# - "issue" is for the Jira ticket number only e.g. DP-1234 +# - No extra spaces, indents, or blank lines are allowed. +# +# Example: +# ############################################################################# +# Fixed: +# - description: Fixes scrolling on edit pages in Safari. +# issue: DP-13314 +# +# You may add more than 1 description & issue for each type using the following format: +# Changed: +# - description: Automating the release branch. +# issue: DP-10166 +# - description: Second change item that needs a description. +# issue: DP-19875 +# - description: Third change item that needs a description along with an issue. +# issue: DP-19843 +# +Fixed: + - description: Fix default domain URLs from service detail migration + issue: DP-29493 diff --git a/docroot/modules/custom/mass_migrate/src/fix_default_urls.php b/docroot/modules/custom/mass_migrate/src/fix_default_urls.php new file mode 100644 index 0000000000..a09282993d --- /dev/null +++ b/docroot/modules/custom/mass_migrate/src/fix_default_urls.php @@ -0,0 +1,14611 @@ +get($field_name); + foreach ($field_items as $delta => $item) { + if (!isset($values[$field_name][$delta])) { + $values[$field_name][$delta] = $item->getValue(); + } + switch (get_class($item)) { + // This is a/the problem. + case DynamicLinkItem::class: + case FieldItemList::class: + // Only update the delta that was migrated + // (when there are multiple values). + // Each if() is a different type of DynamicLinkItem + $item_uri = $item->get('uri')->getString(); + if (strpos($item_uri, 'http://default/') === 0) { + $uri_new = get_new_uri($item_uri); + $values[$field_name][$delta]['uri'] = $uri_new; + $changed = TRUE; + } + break; + default: + } + } + if ($changed) { + var_dump('saving'); + $entity->$field_name = $values[$field_name]; + $entity->save(); + } + +} + +function update_paragraph_ref_links($sourceid) { + + $storage = \Drupal::entityTypeManager()->getStorage('paragraph'); + + // Query for paragraph items referencing service details node. + $query = \Drupal::database()->select('entity_usage', 'eu'); + $query->fields('eu', ['source_id', 'source_type']); + // Filter to paragraph entities that exist. + $query->innerJoin('paragraphs_item', 'pi', 'eu.source_id=pi.id'); + $query->condition('eu.source_type', 'paragraph'); + $query->condition('eu.target_type', 'node'); + + $query->groupBy('eu.source_id'); + $query->groupBy('eu.source_type'); + $query->addField('eu', 'field_name'); + $query->groupBy('eu.field_name'); + $query->condition('eu.target_id', $sourceid); + + $refs = $query->execute()->fetchAll(); + + foreach ($refs as $ref) { + $field_name = $ref->field_name; + $entity = $storage->load($ref->source_id); + /** @var \Drupal\Core\Entity\ContentEntityInterface $entity */ + if (!$entity = $storage->load($ref->source_id)) { + // Not a valid source anymore. Maybe it got deleted. + var_dump("Unable to load entity"); + continue; + } + update_links_in_entity_field($entity, $field_name); + } +} + +function get_new_uri($oldUri) { + // Since the node no longer exists. + $nodeAlias = parse_url($oldUri, PHP_URL_PATH); + if (!$nodeAlias) { + var_dump('No path found'); + return; + } + // Ex: /node/733946. + $internalPath = \Drupal::service('path_alias.manager')->getPathByAlias($nodeAlias); + return str_replace('/node/', 'entity:node/', $internalPath); +} + +$_ENV['MASS_FLAGGING_BYPASS'] = TRUE; + +// Update links based on references to the service details. +foreach ($sourceids as $sourceid) { + update_paragraph_ref_links($sourceid); +} +$tableColumns = [ + [ + 'table' => 'node__field_info_details_related', + 'column' => 'field_info_details_related_uri', + ], + [ + 'table' => 'node__field_event_links', + 'column' => 'field_event_links_uri', + ], + [ + 'table' => 'node__field_news_links', + 'column' => 'field_news_links_uri', + ], + [ + 'table' => 'node__field_regulation_link_org', + 'column' => 'field_regulation_link_org_uri', + ], + [ + 'table' => 'node__field_how_to_links_5', + 'column' => 'field_how_to_links_5_uri', + ], + [ + 'table' => 'node__field_decision_related', + 'column' => 'field_decision_related_uri', + ], + [ + 'table' => 'node__field_contact_more_info_link', + 'column' => 'field_contact_more_info_link_uri', + ], + [ + 'table' => 'node__field_event_participating_orgs', + 'column' => 'field_event_participating_orgs_uri', + ], +]; + + +foreach ($tableColumns as $tableColumn) { + $query = \Drupal::database()->select($tableColumn['table'], 'f'); + $query->fields('f', ['entity_id']); + $query->condition('f.' . $tableColumn['column'], 'http://default/%', 'LIKE'); + $nids = $query->execute()->fetchCol(); + $nodes = \Drupal::entityTypeManager()->getStorage('node')->loadMultiple($nids); + $field = str_replace('_uri', '', $tableColumn['column']); + foreach ($nodes as $node) { + update_links_in_entity_field($node, $field); + } +} + + +drupal_flush_all_caches(); From 7a1a139d32fe1cbabb93e23a0d6682f058a9761b Mon Sep 17 00:00:00 2001 From: Arthur Baghdasaryan <62405127+arthurbaghdas@users.noreply.github.com> Date: Tue, 12 Sep 2023 17:26:12 +0400 Subject: [PATCH 30/32] DP-29649: Correct spelling issue in address error (#2187) * DP-29649: Correct spelling issue in address error * DP-29649: Correct spelling issue in address error --- changelogs/DP-29649.yml | 3 +++ docroot/modules/custom/mass_map/src/MapLocationFetcher.php | 2 +- .../mass_theme/templates/views/views-view--locations.html.twig | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) create mode 100644 changelogs/DP-29649.yml diff --git a/changelogs/DP-29649.yml b/changelogs/DP-29649.yml new file mode 100644 index 0000000000..e349968bf3 --- /dev/null +++ b/changelogs/DP-29649.yml @@ -0,0 +1,3 @@ +Fixed: + - description: Correct spelling issue in address error. + issue: DP-29649 diff --git a/docroot/modules/custom/mass_map/src/MapLocationFetcher.php b/docroot/modules/custom/mass_map/src/MapLocationFetcher.php index 52827b8cce..cd307227af 100644 --- a/docroot/modules/custom/mass_map/src/MapLocationFetcher.php +++ b/docroot/modules/custom/mass_map/src/MapLocationFetcher.php @@ -42,7 +42,7 @@ public function getLocations(array $nids) { 'name' => 'filter-by-location', 'type' => 'text', 'placeholder' => 'City, town, or ZIP code', - 'errorMsg' => 'Please select an address in the suggesions. Hit ENTER or start typing to show suggesions.' + 'errorMsg' => 'Please select an address in the suggestions. Hit ENTER or start typing to show suggestions.' ], ], 'tags' => [ diff --git a/docroot/themes/custom/mass_theme/templates/views/views-view--locations.html.twig b/docroot/themes/custom/mass_theme/templates/views/views-view--locations.html.twig index 5281dbb8ed..3a11a6c400 100644 --- a/docroot/themes/custom/mass_theme/templates/views/views-view--locations.html.twig +++ b/docroot/themes/custom/mass_theme/templates/views/views-view--locations.html.twig @@ -81,7 +81,7 @@
-
Please select an address in the suggesions. Hit ENTER or start typing to show suggesions.
+
Please select an address in the suggestions. Hit ENTER or start typing to show suggestions.
From e8d2812fc6280d4d50dd1d03184bed3d5c2ae038 Mon Sep 17 00:00:00 2001 From: CircleCI Deployment Bot Date: Tue, 12 Sep 2023 17:06:20 +0000 Subject: [PATCH 31/32] changelog update and remove old changelog files --- CHANGELOG.md | 20 +++++++++++++++++++ changelogs/DP-28608.yml | 41 -------------------------------------- changelogs/DP-29020.yml | 41 -------------------------------------- changelogs/DP-29416.yml | 41 -------------------------------------- changelogs/DP-29493.yml | 41 -------------------------------------- changelogs/DP-29536.yml | 41 -------------------------------------- changelogs/DP-29542.yml | 41 -------------------------------------- changelogs/DP-29553.yml | 41 -------------------------------------- changelogs/DP-29559.yml | 41 -------------------------------------- changelogs/DP-29600.yml | 41 -------------------------------------- changelogs/DP-29649.yml | 3 --- scripts/changelog-body.txt | 24 ++++++++++------------ 12 files changed, 31 insertions(+), 385 deletions(-) delete mode 100644 changelogs/DP-28608.yml delete mode 100644 changelogs/DP-29020.yml delete mode 100644 changelogs/DP-29416.yml delete mode 100644 changelogs/DP-29493.yml delete mode 100644 changelogs/DP-29536.yml delete mode 100644 changelogs/DP-29542.yml delete mode 100644 changelogs/DP-29553.yml delete mode 100644 changelogs/DP-29559.yml delete mode 100644 changelogs/DP-29600.yml delete mode 100644 changelogs/DP-29649.yml diff --git a/CHANGELOG.md b/CHANGELOG.md index ea89c09bab..601ce33c9c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,25 @@ +## [0.373.0] - September 12, 2023 + +### Changed + - DP-28608: Replace superset data in views with data from bigquery + - DP-29020: Convert org page paragraph "What would you like to do" to use service page component "Flexible link group". + - DP-29416: Replace Twitter logo with new 'X' logo and add Threads logo + - DP-29553: Remove service details pages from visual regression testing in backstop. + - DP-29559: Role permissions changed to allow all authors and editors access to new analytics tab without tester role. Cleanup of tester role permissions. + +### Fixed + - DP-29493: Fix default domain URLs from service detail migration + - DP-29536: Fixed Tugboat builds. + - DP-29600: Fixed suggested page item link covering the whole page. + - DP-29649: Correct spelling issue in address error. + +### Added + - Avoid redirect to install.php when DB is down + + + ## [0.372.0] - September 5, 2023 ### Changed diff --git a/changelogs/DP-28608.yml b/changelogs/DP-28608.yml deleted file mode 100644 index 4956b2393f..0000000000 --- a/changelogs/DP-28608.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Changed: - - description: Replace superset data in views with data from bigquery - issue: DP-28608 diff --git a/changelogs/DP-29020.yml b/changelogs/DP-29020.yml deleted file mode 100644 index 9ff84d0a87..0000000000 --- a/changelogs/DP-29020.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Changed: - - description: Convert org page paragraph "What would you like to do" to use service page component "Flexible link group". - issue: DP-29020 diff --git a/changelogs/DP-29416.yml b/changelogs/DP-29416.yml deleted file mode 100644 index e649f03a18..0000000000 --- a/changelogs/DP-29416.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Changed: - - description: Replace Twitter logo with new 'X' logo and add Threads logo - issue: DP-29416 diff --git a/changelogs/DP-29493.yml b/changelogs/DP-29493.yml deleted file mode 100644 index be127d5736..0000000000 --- a/changelogs/DP-29493.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Fixed: - - description: Fix default domain URLs from service detail migration - issue: DP-29493 diff --git a/changelogs/DP-29536.yml b/changelogs/DP-29536.yml deleted file mode 100644 index 671212c4e1..0000000000 --- a/changelogs/DP-29536.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Fixed: - - description: Fixed Tugboat builds. - issue: DP-29536 diff --git a/changelogs/DP-29542.yml b/changelogs/DP-29542.yml deleted file mode 100644 index 93da16f1d7..0000000000 --- a/changelogs/DP-29542.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Added: - - description: Avoid redirect to install.php when DB is down - issue: diff --git a/changelogs/DP-29553.yml b/changelogs/DP-29553.yml deleted file mode 100644 index 8f887c87af..0000000000 --- a/changelogs/DP-29553.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Changed: - - description: Remove service details pages from visual regression testing in backstop. - issue: DP-29553 diff --git a/changelogs/DP-29559.yml b/changelogs/DP-29559.yml deleted file mode 100644 index e974a28186..0000000000 --- a/changelogs/DP-29559.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Changed: - - description: Role permissions changed to allow all authors and editors access to new analytics tab without tester role. Cleanup of tester role permissions. - issue: DP-29559 diff --git a/changelogs/DP-29600.yml b/changelogs/DP-29600.yml deleted file mode 100644 index 8b6bce59da..0000000000 --- a/changelogs/DP-29600.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Fixed: - - description: Fixed suggested page item link covering the whole page. - issue: DP-29600 diff --git a/changelogs/DP-29649.yml b/changelogs/DP-29649.yml deleted file mode 100644 index e349968bf3..0000000000 --- a/changelogs/DP-29649.yml +++ /dev/null @@ -1,3 +0,0 @@ -Fixed: - - description: Correct spelling issue in address error. - issue: DP-29649 diff --git a/scripts/changelog-body.txt b/scripts/changelog-body.txt index 7effa5b02f..b87aa53671 100644 --- a/scripts/changelog-body.txt +++ b/scripts/changelog-body.txt @@ -1,22 +1,20 @@ -## [0.372.0] - September 5, 2023 +## [0.373.0] - September 12, 2023 ### Changed - - DP-25149: Revert Akamai version which got moved up recently. Fixes test failures. - - DP-28733: Remove aria-labelledby from key actions, title attribute from its comp heading and correct the heading level. - - DP-288257: Consolidate two Drush commands into one - ma:heal-references-to-trash - - DP-28842: Drupal 10 compat - Update Entity Embed and LinkIt - - DP-29492: Config change to load Google Tag manager in all paths including author paths. - -### Removed - - DP-26154: Remove testing of service_details pages + - DP-28608: Replace superset data in views with data from bigquery + - DP-29020: Convert org page paragraph "What would you like to do" to use service page component "Flexible link group". + - DP-29416: Replace Twitter logo with new 'X' logo and add Threads logo + - DP-29553: Remove service details pages from visual regression testing in backstop. + - DP-29559: Role permissions changed to allow all authors and editors access to new analytics tab without tester role. Cleanup of tester role permissions. ### Fixed - - DP-28622: Export report of orphaned pages fixed. - - DP-29391: Fix flagging for migrated service details pages. + - DP-29493: Fix default domain URLs from service detail migration + - DP-29536: Fixed Tugboat builds. + - DP-29600: Fixed suggested page item link covering the whole page. + - DP-29649: Correct spelling issue in address error. ### Added - - DP-29259: Add metadata field mg_parent_org. - - DP-29392: Add drush ma:backup command for starting an on-demand DB backup. + - Avoid redirect to install.php when DB is down From 1238f6a0839ac941ebda25d6d2c4c6c477dcc11e Mon Sep 17 00:00:00 2001 From: Tom Fleming Date: Tue, 12 Sep 2023 14:29:20 -0400 Subject: [PATCH 32/32] Revert "feature/DP-29020_convert_wwyltd_to_flexible_links" --- changelogs/DP-29020.yml | 41 --- ...aragraph.org_section_long_form.default.yml | 11 +- ...aragraph.org_section_long_form.default.yml | 9 - ...g_form.field_section_long_form_content.yml | 27 +- ..._section_long_form.field_section_style.yml | 23 -- .../mass_content/mass_content.deploy.php | 273 ------------------ .../custom/mass_fields/mass_fields.module | 152 +++++----- .../migrate/source/UpdateReferences.php | 3 +- .../mass_theme/mass_theme.libraries.yml | 2 +- .../themes/custom/mass_theme/mass_theme.theme | 38 +-- .../css/{sections.css => service-section.css} | 21 +- ...--org-section-long-form--default.html.twig | 102 +++---- 12 files changed, 129 insertions(+), 573 deletions(-) delete mode 100644 changelogs/DP-29020.yml delete mode 100644 conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_style.yml rename docroot/themes/custom/mass_theme/overrides/css/{sections.css => service-section.css} (63%) diff --git a/changelogs/DP-29020.yml b/changelogs/DP-29020.yml deleted file mode 100644 index 9ff84d0a87..0000000000 --- a/changelogs/DP-29020.yml +++ /dev/null @@ -1,41 +0,0 @@ -# -# Write your changelog entry here. Every pull request must have a changelog yml file. -# -# Change types: -# ############################################################################# -# You can use one of the following types: -# - Added: For new features. -# - Changed: For changes to existing functionality. -# - Deprecated: For soon-to-be removed features. -# - Removed: For removed features. -# - Fixed: For any bug fixes. -# - Security: In case of vulnerabilities. -# -# Format -# ############################################################################# -# The format is crucial. Please follow the examples below. For reference, the requirements are: -# - All 3 parts are required and you must include "Type", "description" and "issue". -# - "Type" must be left aligned and followed by a colon. -# - "description" must be indented with 2 spaces followed by a colon -# - "issue" must be indented with 4 spaces followed by a colon. -# - "issue" is for the Jira ticket number only e.g. DP-1234 -# - No extra spaces, indents, or blank lines are allowed. -# -# Example: -# ############################################################################# -# Fixed: -# - description: Fixes scrolling on edit pages in Safari. -# issue: DP-13314 -# -# You may add more than 1 description & issue for each type using the following format: -# Changed: -# - description: Automating the release branch. -# issue: DP-10166 -# - description: Second change item that needs a description. -# issue: DP-19875 -# - description: Third change item that needs a description along with an issue. -# issue: DP-19843 -# -Changed: - - description: Convert org page paragraph "What would you like to do" to use service page component "Flexible link group". - issue: DP-29020 diff --git a/conf/drupal/config/core.entity_form_display.paragraph.org_section_long_form.default.yml b/conf/drupal/config/core.entity_form_display.paragraph.org_section_long_form.default.yml index 733fab7fb0..7973083e55 100644 --- a/conf/drupal/config/core.entity_form_display.paragraph.org_section_long_form.default.yml +++ b/conf/drupal/config/core.entity_form_display.paragraph.org_section_long_form.default.yml @@ -6,7 +6,6 @@ dependencies: - field.field.paragraph.org_section_long_form.field_hide_heading - field.field.paragraph.org_section_long_form.field_section_long_form_content - field.field.paragraph.org_section_long_form.field_section_long_form_heading - - field.field.paragraph.org_section_long_form.field_section_style - paragraphs.paragraphs_type.org_section_long_form module: - field_group @@ -19,7 +18,7 @@ third_party_settings: label: 'Section Content' region: content parent_name: '' - weight: 3 + weight: 2 format_type: details format_settings: classes: section-content @@ -32,7 +31,7 @@ third_party_settings: label: 'Additional Resources' region: content parent_name: '' - weight: 4 + weight: 3 format_type: details format_settings: classes: '' @@ -72,12 +71,6 @@ content: size: 60 placeholder: '' third_party_settings: { } - field_section_style: - type: options_buttons - weight: 2 - region: content - settings: { } - third_party_settings: { } hidden: created: true status: true diff --git a/conf/drupal/config/core.entity_view_display.paragraph.org_section_long_form.default.yml b/conf/drupal/config/core.entity_view_display.paragraph.org_section_long_form.default.yml index 821020cd53..83d853a4bd 100644 --- a/conf/drupal/config/core.entity_view_display.paragraph.org_section_long_form.default.yml +++ b/conf/drupal/config/core.entity_view_display.paragraph.org_section_long_form.default.yml @@ -6,11 +6,9 @@ dependencies: - field.field.paragraph.org_section_long_form.field_hide_heading - field.field.paragraph.org_section_long_form.field_section_long_form_content - field.field.paragraph.org_section_long_form.field_section_long_form_heading - - field.field.paragraph.org_section_long_form.field_section_style - paragraphs.paragraphs_type.org_section_long_form module: - entity_reference_revisions - - options id: paragraph.org_section_long_form.default targetEntityType: paragraph bundle: org_section_long_form @@ -33,13 +31,6 @@ content: third_party_settings: { } weight: 0 region: content - field_section_style: - type: list_default - label: above - settings: { } - third_party_settings: { } - weight: 2 - region: content hidden: computed_org_page: true field_hide_heading: true diff --git a/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml b/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml index cd72bdb98b..58333a249f 100644 --- a/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml +++ b/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_long_form_content.yml @@ -11,7 +11,6 @@ dependencies: - paragraphs.paragraphs_type.featured_item_mosaic - paragraphs.paragraphs_type.featured_message - paragraphs.paragraphs_type.featured_topics - - paragraphs.paragraphs_type.flexible_link_group - paragraphs.paragraphs_type.iframe - paragraphs.paragraphs_type.image - paragraphs.paragraphs_type.info_details_card_group @@ -29,6 +28,7 @@ dependencies: - paragraphs.paragraphs_type.stat - paragraphs.paragraphs_type.tableau_embed - paragraphs.paragraphs_type.video + - paragraphs.paragraphs_type.what_would_you_like_to_do module: - entity_reference_revisions id: paragraph.org_section_long_form.field_section_long_form_content @@ -67,8 +67,8 @@ settings: stat: stat tableau_embed: tableau_embed video: video + what_would_you_like_to_do: what_would_you_like_to_do collection_search: collection_search - flexible_link_group: flexible_link_group negate: 0 target_bundles_drag_drop: 1up_stacked_band: @@ -125,9 +125,6 @@ settings: advisory_section: weight: 39 enabled: false - alert: - weight: 151 - enabled: false board_member: weight: 40 enabled: false @@ -164,9 +161,6 @@ settings: contact_info: weight: 48 enabled: false - contact_placeholder: - weight: 164 - enabled: false content_card_group: weight: 49 enabled: false @@ -221,9 +215,6 @@ settings: file_download_single: weight: 63 enabled: false - flexible_link_group: - weight: 183 - enabled: true footnotes: weight: 64 enabled: false @@ -272,6 +263,9 @@ settings: key_message_section: weight: 76 enabled: false + link_group: + weight: 77 + enabled: false link_group_accordion: weight: 90 enabled: false @@ -419,12 +413,6 @@ settings: section_with_heading: weight: 117 enabled: false - service_rich_text: - weight: 249 - enabled: false - service_section: - weight: 250 - enabled: false sitewide_alert_message: weight: 242 enabled: false @@ -452,9 +440,6 @@ settings: tableau_embed: weight: 20 enabled: true - time_callout: - weight: 260 - enabled: false video: weight: 21 enabled: true @@ -466,5 +451,5 @@ settings: enabled: false what_would_you_like_to_do: weight: 22 - enabled: false + enabled: true field_type: entity_reference_revisions diff --git a/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_style.yml b/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_style.yml deleted file mode 100644 index 7d5256977b..0000000000 --- a/conf/drupal/config/field.field.paragraph.org_section_long_form.field_section_style.yml +++ /dev/null @@ -1,23 +0,0 @@ -uuid: 17054d01-bdd8-4160-855d-f062c3f094e8 -langcode: en -status: true -dependencies: - config: - - field.storage.paragraph.field_section_style - - paragraphs.paragraphs_type.org_section_long_form - module: - - options -id: paragraph.org_section_long_form.field_section_style -field_name: field_section_style -entity_type: paragraph -bundle: org_section_long_form -label: 'Section style' -description: 'The "Simple" option uses a plain black header with content on a white background. If you really want to call attention to this section, you can use the "Enhanced" option which will use a blue header banner and gray shading for the section.' -required: true -translatable: true -default_value: - - - value: simple -default_value_callback: '' -settings: { } -field_type: list_string diff --git a/docroot/modules/custom/mass_content/mass_content.deploy.php b/docroot/modules/custom/mass_content/mass_content.deploy.php index c011cb2dbd..87ca71e637 100644 --- a/docroot/modules/custom/mass_content/mass_content.deploy.php +++ b/docroot/modules/custom/mass_content/mass_content.deploy.php @@ -9,8 +9,6 @@ use Drupal\Core\Datetime\DrupalDateTime; use Drupal\Core\Link; use Drupal\Core\Url; -use Drupal\mayflower\Helper; -use Drupal\node\Entity\Node; use Drupal\paragraphs\Entity\Paragraph; use Drupal\taxonomy\Entity\Term; @@ -899,274 +897,3 @@ function mass_content_deploy_related_content(&$sandbox) { } return "Processed {$sandbox['progress']} items."; } - -/** - * Set "Section style" default value for the org sections. - */ -function mass_content_deploy_org_section_style(&$sandbox) { - $_ENV['MASS_FLAGGING_BYPASS'] = TRUE; - - $query = \Drupal::entityQuery('paragraph')->accessCheck(FALSE); - $query->condition('type', 'org_section_long_form'); - - if (empty($sandbox)) { - // Get a list of all nodes of type event. - $sandbox['progress'] = 0; - $sandbox['current'] = 0; - $count = clone $query; - $sandbox['max'] = $count->count()->accessCheck(FALSE)->execute(); - } - - $batch_size = 50; - - $pids = $query->condition('id', $sandbox['current'], '>') - ->sort('id') - ->range(0, $batch_size) - ->execute(); - - $storage = \Drupal::entityTypeManager()->getStorage('paragraph'); - - $paragraphs = $storage->loadMultiple($pids); - - foreach ($paragraphs as $paragraph) { - $sandbox['current'] = $paragraph->id(); - if (!Helper::isParagraphOrphan($paragraph)) { - $paragraph->set('field_section_style', 'simple'); - $paragraph->save(); - } - $sandbox['progress']++; - } - - $sandbox['#finished'] = empty($sandbox['max']) ? 1 : ($sandbox['progress'] / $sandbox['max']); - if ($sandbox['#finished'] >= 1) { - return t('Section style default value set for the org sections. Processed @total items.', ['@total' => $sandbox['progress']]); - } - return "Processed {$sandbox['progress']} items."; -} - -/** - * Migrate "What would you like to do" to be flexible links. - */ -function mass_content_deploy_org_wwyltd_flexible_links(&$sandbox) { - $_ENV['MASS_FLAGGING_BYPASS'] = TRUE; - - $query = \Drupal::entityQuery('paragraph')->accessCheck(FALSE); - $query->condition('type', 'what_would_you_like_to_do'); - - if (empty($sandbox)) { - // Get a list of all nodes of type event. - $sandbox['progress'] = 0; - $sandbox['current'] = 0; - $count = clone $query; - $sandbox['max'] = $count->count()->accessCheck(FALSE)->execute(); - } - - $batch_size = 50; - - $pids = $query->condition('id', $sandbox['current'], '>') - ->sort('id') - ->range(0, $batch_size) - ->execute(); - - $storage = \Drupal::entityTypeManager()->getStorage('paragraph'); - - // Turn off entity_hierarchy writes while processing the item. - \Drupal::state()->set('entity_hierarchy_disable_writes', TRUE); - - $memory_cache = \Drupal::service('entity.memory_cache'); - - $paragraphs = $storage->loadMultiple($pids); - foreach ($paragraphs as $paragraph) { - $sandbox['current'] = $paragraph->id(); - if ($paragraph instanceof Paragraph) { - if (!Helper::isParagraphOrphan($paragraph)) { - if ($parent = $paragraph->getParentEntity()) { - if ($parent instanceof Paragraph && $parent->bundle() == 'org_section_long_form') { - if ($parent->getParentEntity() instanceof Node) { - $node = $parent->getParentEntity(); - try { - mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragraph); - } - catch (\Exception $e) { - \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); - } - if (!$node->isLatestRevision()) { - $storage = \Drupal::entityTypeManager()->getStorage('node'); - $query = $storage->getQuery()->accessCheck(FALSE); - $query->condition('nid', $node->id()); - $query->latestRevision(); - $rids = $query->execute(); - foreach ($rids as $rid) { - $latest_revision = $storage->loadRevision($rid); - if (isset($latest_revision)) { - try { - mass_content_org_wwyltd_flexible_links_helper($latest_revision, $parent, $paragraph); - } - catch (\Exception $e) { - \Drupal::state() - ->set('entity_hierarchy_disable_writes', FALSE); - } - } - } - } - } - } - } - } - } - $sandbox['progress']++; - } - - $memory_cache->deleteAll(); - - $sandbox['#finished'] = empty($sandbox['max']) ? 1 : ($sandbox['progress'] / $sandbox['max']); - if ($sandbox['#finished'] >= 1) { - \Drupal::state()->set('entity_hierarchy_disable_writes', FALSE); - return t('Migrate "What would you like to do" to flexible links. Processed @total items.', ['@total' => $sandbox['progress']]); - } - return "Processed {$sandbox['progress']} items."; -} - -/** - * Helper function to call during migration. - */ -function mass_content_org_wwyltd_flexible_links_helper($node, $parent, $paragraph) { - $node_field_name = $parent->parent_field_name->value; - $parent_field_name = $paragraph->parent_field_name->value; - if ($parent = $paragraph->getParentEntity()) { - $content_items = $parent->get($parent_field_name)->getValue(); - if ($parent->get($parent_field_name)->count() > 1) { - foreach ($content_items as $i => $content_item) { - if ($content_item['target_id'] == $paragraph->id() && $content_item['target_revision_id'] == $paragraph->getRevisionId()) { - $content_index = $i; - break; - } - } - } - } - - $items = $node->get($node_field_name)->getValue(); - foreach ($items as $index => $item) { - if ($item['target_id'] == $parent->id() && $item['target_revision_id'] == $parent->getRevisionId()) { - $section_index = $index; - break; - } - } - - $flexible_link_groups = []; - if (!$paragraph->get('field_wwyltd_top_s_links')->isEmpty()) { - $top_links = $paragraph->get('field_wwyltd_top_s_links') - ->getValue(); - - $link_group_links = []; - foreach ($top_links as $link) { - // Create a new link_group_link paragraph. - $link_group_link = Paragraph::create([ - 'type' => 'link_group_link', - ]); - - $link_group_link->set('field_link_group_link', $link); - $link_group_link->save(); - $link_group_links[] = $link_group_link; - } - - // Create a new flexible_link_group paragraph. - $flexible_link_group = Paragraph::create([ - 'type' => 'flexible_link_group', - ]); - - $flexible_link_group->set('field_featured', 1); - $flexible_link_group->set('field_display_type', 'buttons'); - // 2 = Buttons. - $flexible_link_group->set('field_link_group', $link_group_links); - $flexible_link_group->save(); - $flexible_link_groups[] = $flexible_link_group; - } - - if (!$paragraph->get('field_wwyltd_more_services')->isEmpty()) { - $more_paragraphs = $paragraph->get('field_wwyltd_more_services') - ->referencedEntities(); - - foreach ($more_paragraphs as $more_paragraph) { - if (!$more_paragraph->get('field_links_documents')->isEmpty()) { - $link_group_links = $more_paragraph->get('field_links_documents') - ->referencedEntities(); - - // Create a new flexible_link_group paragraph. - $flexible_link_group = Paragraph::create([ - 'type' => 'flexible_link_group', - ]); - - $flexible_link_group->set('field_featured', 0); - $flexible_link_group->set('field_display_type', 'links'); - $flexible_link_group->set('field_group_expanded', $more_paragraph->get('field_group_expanded')->value); - if (!$more_paragraph->get('field_group_expanded')->isEmpty()) { - $flexible_link_group->set('field_group_expanded', $more_paragraph->get('field_group_expanded')->value); - } - else { - $flexible_link_group->set('field_group_expanded', 1); - } - if (!$more_paragraph->get('field_section_title')->isEmpty()) { - $title = $more_paragraph->get('field_section_title')->value; - $flexible_link_group->set('field_flexible_link_group_title', $title); - } - $flexible_link_group->set('field_link_group', $link_group_links); - $flexible_link_group->save(); - $flexible_link_groups[] = $flexible_link_group; - } - } - } - - if ($flexible_link_groups) { - $new_org_section_long_form_paragraph = Paragraph::create([ - 'type' => 'org_section_long_form', - ]); - if (isset($content_index)) { - $result = []; - foreach ($content_items as $index => $content_item) { - if ($index == $content_index) { - foreach ($flexible_link_groups as $flexible_link_group) { - $result[] = $flexible_link_group; - } - } - else { - $result[] = $content_item; - } - } - $new_org_section_long_form_paragraph->set('field_section_long_form_content', $result); - } - else { - $new_org_section_long_form_paragraph->set('field_section_long_form_content', $flexible_link_groups); - } - if (!$paragraph->get('field_wwyltd_heading')->isEmpty()) { - $heading = $paragraph->get('field_wwyltd_heading')->value; - $new_org_section_long_form_paragraph->set('field_section_long_form_heading', $heading); - } - $new_org_section_long_form_paragraph->set('field_section_style', 'enhanced'); - $new_org_section_long_form_paragraph->set('field_hide_heading', 0); - - // Save the new paragraph. - $new_org_section_long_form_paragraph->save(); - // Create a value array for the new section paragraph. - $new_org_section_long_form_paragraph_value = [ - 'target_id' => $new_org_section_long_form_paragraph->id(), - 'target_revision_id' => $new_org_section_long_form_paragraph->getRevisionId(), - ]; - if (isset($section_index)) { - $items[$section_index] = $new_org_section_long_form_paragraph_value; - } - else { - $items[] = $new_org_section_long_form_paragraph_value; - } - - $node->set('field_organization_sections', $items); - // Save the node. - // Save without updating the last modified date. This requires a core patch - // from the issue: https://www.drupal.org/project/drupal/issues/2329253. - $node->setSyncing(TRUE); - $node->revision_log = "Bulk automated change of ‘what would you like to do’ component to ‘flexible link group’"; - $node->setRevisionCreationTime(\Drupal::time()->getCurrentTime()); - $node->save(); - $paragraph->delete(); - } -} diff --git a/docroot/modules/custom/mass_fields/mass_fields.module b/docroot/modules/custom/mass_fields/mass_fields.module index 8af8ea8951..0eb33eeedf 100644 --- a/docroot/modules/custom/mass_fields/mass_fields.module +++ b/docroot/modules/custom/mass_fields/mass_fields.module @@ -896,89 +896,87 @@ function _mass_fields_conditions_for_paragraphs(&$element, FormStateInterface $f $widget_state = WidgetBase::getWidgetState($element['#field_parents'], $paragraph_entity_reference_field_name, $form_state); /** @var \Drupal\paragraphs\Entity\Paragraph $paragraph */ $paragraph_instance = $widget_state['paragraphs'][$element['#delta']]['entity']; - if ($paragraph_instance) { - $paragraph_type = $paragraph_instance->bundle(); - // Determine which paragraph type is being embedded. - switch ($paragraph_type) { - case 'collection_search': - $dependee_field_name = 'field_search_type'; - $selector = sprintf('select[name="%s[%d][subform][%s][%d][subform][%s]"]', - $element['#field_parents'][0], - $element['#field_parents'][1], + $paragraph_type = $paragraph_instance->bundle(); + // Determine which paragraph type is being embedded. + switch ($paragraph_type) { + case 'collection_search': + $dependee_field_name = 'field_search_type'; + $selector = sprintf('select[name="%s[%d][subform][%s][%d][subform][%s]"]', + $element['#field_parents'][0], + $element['#field_parents'][1], + $paragraph_entity_reference_field_name, + $element['#delta'], + $dependee_field_name); + + if ($paragraph_entity_reference_field_name == 'field_sections') { + $selector = sprintf('select[name="%s[%d][subform][%s]"]', $paragraph_entity_reference_field_name, $element['#delta'], $dependee_field_name); + } - if ($paragraph_entity_reference_field_name == 'field_sections') { - $selector = sprintf('select[name="%s[%d][subform][%s]"]', - $paragraph_entity_reference_field_name, - $element['#delta'], - $dependee_field_name); - } + // Dependent fields. + $element['subform']['field_collection']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'collection'], + ], + 'required' => [ + $selector => ['value' => 'collection'], + ], + ]; - // Dependent fields. - $element['subform']['field_collection']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'collection'], - ], - 'required' => [ - $selector => ['value' => 'collection'], - ], - ]; - - // Dependent fields. - $element['subform']['field_search_site_url']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'external'], - ], - 'required' => [ - $selector => ['value' => 'external'], - ], - ]; - - // Dependent fields. - $element['subform']['field_search_query_param_name']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'external'], - ], - 'required' => [ - $selector => ['value' => 'external'], - ], - ]; - break; - - case 'key_message_section': - $dependee_field_name = 'field_background_type'; - $selector = sprintf('input[name="%s[%d][subform][%s]"]', $paragraph_entity_reference_field_name, $element['#delta'], $dependee_field_name); - - // Dependent fields. - $element['subform']['field_image']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'image'], - ], - 'required' => [ - $selector => ['value' => 'image'], - ], - ]; - - $element['subform']['field_section_background_color']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'color'], - ], - 'required' => [ - $selector => ['value' => 'color'], - ], - ]; - - $element['subform']['field_section_text_overlay_color']['#states'] = [ - 'visible' => [ - $selector => ['value' => 'image'], - ], - - ]; - break; + // Dependent fields. + $element['subform']['field_search_site_url']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'external'], + ], + 'required' => [ + $selector => ['value' => 'external'], + ], + ]; + + // Dependent fields. + $element['subform']['field_search_query_param_name']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'external'], + ], + 'required' => [ + $selector => ['value' => 'external'], + ], + ]; + break; + + case 'key_message_section': + $dependee_field_name = 'field_background_type'; + $selector = sprintf('input[name="%s[%d][subform][%s]"]', $paragraph_entity_reference_field_name, $element['#delta'], $dependee_field_name); + + // Dependent fields. + $element['subform']['field_image']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'image'], + ], + 'required' => [ + $selector => ['value' => 'image'], + ], + ]; + + $element['subform']['field_section_background_color']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'color'], + ], + 'required' => [ + $selector => ['value' => 'color'], + ], + ]; + + $element['subform']['field_section_text_overlay_color']['#states'] = [ + 'visible' => [ + $selector => ['value' => 'image'], + ], + + ]; + break; - } } } } diff --git a/docroot/modules/custom/mass_migrate/src/Plugin/migrate/source/UpdateReferences.php b/docroot/modules/custom/mass_migrate/src/Plugin/migrate/source/UpdateReferences.php index 7e6673ee47..e4a8c2c45c 100644 --- a/docroot/modules/custom/mass_migrate/src/Plugin/migrate/source/UpdateReferences.php +++ b/docroot/modules/custom/mass_migrate/src/Plugin/migrate/source/UpdateReferences.php @@ -129,7 +129,8 @@ public function prepareRow(Row $row) { } break; case EntityReferenceItem::class: - if ($item->get('target_id')->getString() == $ref['reference_value_old']) { + if ($item->get('target_id') + ->getString() == $ref['reference_value_old']) { $values[$field_name][$delta]['target_id'] = $ref['reference_value_new']; $changed = TRUE; } diff --git a/docroot/themes/custom/mass_theme/mass_theme.libraries.yml b/docroot/themes/custom/mass_theme/mass_theme.libraries.yml index d057325f90..4e9b318ef0 100644 --- a/docroot/themes/custom/mass_theme/mass_theme.libraries.yml +++ b/docroot/themes/custom/mass_theme/mass_theme.libraries.yml @@ -21,7 +21,7 @@ global-styling: overrides/css/contained.css: {} overrides/css/campaign_landing.css: {} overrides/css/flexible-link-group.css: {} - overrides/css/sections.css: {} + overrides/css/service-section.css: {} overrides/css/news-page.css: {} overrides/css/language-bar.css: {} js: diff --git a/docroot/themes/custom/mass_theme/mass_theme.theme b/docroot/themes/custom/mass_theme/mass_theme.theme index 0254581653..700c1904be 100644 --- a/docroot/themes/custom/mass_theme/mass_theme.theme +++ b/docroot/themes/custom/mass_theme/mass_theme.theme @@ -7255,46 +7255,14 @@ function _mass_theme_preprocess_paragraph_sections(&$variables, $field) { * Groups different components together when necessary. */ function mass_theme_preprocess_paragraph__org_section_long_form(&$variables) { - - $container = $variables['paragraph']; - if (!$container->field_section_style->isEmpty()) { - $variables['section_style'] = $container->field_section_style->value; - } - $variables['hide_heading'] = $container->field_hide_heading->value; $variables["org_components"] = _mass_theme_preprocess_paragraph_sections($variables, 'field_section_long_form_content'); - $links_group = []; - foreach ($variables['org_components'] as $key => &$org_component) { - /** @var Drupal\paragraphs\Entity\Paragraph */ - $org_component_paragraph = &$org_component[0]; - if ( - is_object($org_component_paragraph) && - $org_component_paragraph->getType() == 'flexible_link_group' && - $org_component_paragraph->field_display_type->value == 'links' - ) { - $links_group[$key] = $org_component; - } - else { - _mass_theme_join_contiguous_flexible_link_group_type_links($links_group, $variables, 'org'); - $links_group = []; - } - } - - _mass_theme_join_contiguous_flexible_link_group_type_links($links_group, $variables, 'org'); - - // Removing elements included previously. - foreach ($variables['org_components'] as $key => &$org_component) { - if ($org_component === FALSE) { - unset($variables['org_components'][$key]); - } - } } /** * Join contiguous flexible link groups, type links, into the same element. */ -function _mass_theme_join_contiguous_flexible_link_group_type_links(&$links_group, &$variables, $destination = 'service') { - $component_name = $destination . '_components'; +function _mass_theme_join_contiguous_flexible_link_group_type_links(&$links_group, &$variables) { if (count($links_group) < 2) { return; } @@ -7304,10 +7272,10 @@ function _mass_theme_join_contiguous_flexible_link_group_type_links(&$links_grou continue; } - $variables[$component_name][$first][0]->subsequent_links[] = $link_group[0]; + $variables['service_components'][$first][0]->subsequent_links[] = $link_group[0]; // Empty elements included previously. - $variables[$component_name][$key] = FALSE; + $variables['service_components'][$key] = FALSE; } $links_group = []; } diff --git a/docroot/themes/custom/mass_theme/overrides/css/sections.css b/docroot/themes/custom/mass_theme/overrides/css/service-section.css similarity index 63% rename from docroot/themes/custom/mass_theme/overrides/css/sections.css rename to docroot/themes/custom/mass_theme/overrides/css/service-section.css index b52db0d1a8..75fcaa868a 100644 --- a/docroot/themes/custom/mass_theme/overrides/css/sections.css +++ b/docroot/themes/custom/mass_theme/overrides/css/service-section.css @@ -2,13 +2,11 @@ overflow: hidden; } -.org-section--enhanced, .service-section--enhanced { background-image: -o-linear-gradient(top, white 50px, #F2F2F2 51px); background: linear-gradient(180deg, white 50px, #F2F2F2 51px); } -.org-section--enhanced > section > header, .service-section--enhanced > section > header { margin-right: auto; margin-left: auto; @@ -21,23 +19,18 @@ font-size: 2rem; } -.org-section .ma__callout-links-three-up h3, .service-section .ma__callout-links-three-up h3 { margin-bottom: 0; } -.org-section .ma__callout-links-three-up p, .service-section .ma__callout-links-three-up p { margin-top: 0.5rem; } -.org-section .ma__callout-links-three-up__container, .service-section .ma__callout-links-three-up__container { margin-top: 2rem; } -.org-section--hidden-title > section > header, -.org-section--hidden-title > section > .ma__stacked-row__container, .service-section--hidden-title > section > header, .service-section--hidden-title > section > .ma__stacked-row__container { position: absolute; @@ -50,38 +43,32 @@ border: 0; } -.org-section--enhanced.org-section--hidden-title, .service-section--enhanced.service-section--hidden-title { background: #F2F2F2; padding-top: 40px; } -.org-section .ma__collapsible-content__body .ma__collapsible-content__body-item, -.service-section .ma__collapsible-content__body .ma__collapsible-content__body-item { +.service-section +.ma__collapsible-content__body +.ma__collapsible-content__body-item { margin: 0.5rem 0; display: block; } -.org-section--enhanced + .org-section--simple .ma__stacked-row__section .ma__stacked-row__container:before, .service-section--enhanced + .service-section--simple .ma__stacked-row__section .ma__stacked-row__container:before { border-color: transparent; } -.org-section .ma__stacked-row__container:before, .service-section .ma__stacked-row__container:before { border-color: transparent !important; } -.org-section--enhanced + .org-section--enhanced.org-section--hidden-title, .service-section--enhanced + .service-section--enhanced.service-section--hidden-title { margin-top: 0 !important; padding-top: 0 !important; } -.org-section.org-section--enhanced .ma__stacked-row__section .main-content { - padding-bottom: 30px; -} .service-section .ma__stacked-row__section .main-content { margin-bottom: 30px; -} +} \ No newline at end of file diff --git a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig index 58af4b672a..f7a35d47a5 100644 --- a/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig +++ b/docroot/themes/custom/mass_theme/templates/paragraphs/paragraph--org-section-long-form--default.html.twig @@ -7,71 +7,41 @@ } %} {% endif %} -{% set section_style_class = section_style == 'enhanced' ? 'org-section--enhanced' : 'org-section--simple' %} -{% set hide_title_class = hide_heading ? 'org-section--hidden-title' : '' %} - -
- {% embed "@organisms/by-author/stacked-row-section.twig" with { - "stackedRowSection": heading, - "stackedRow": { - "borderless": true, - "modifier" : "no-sidebar" - }, - "externalSidebar": true - } %} - {% block stackRowTitle %} - {% if heading %} - {% if section_style == 'enhanced' %} - {% include "@atoms/04-headings/colored-heading-from-left.twig" with { - "coloredHeadingFromLeft": { - "bgColor": "green", - "title": (content.field_section_long_form_heading|field_value) - }} - %} - {% else %} -
-
- {% set compHeading = { - "title": stackedRowSection.title, - "sub": "", - "color": "", - "id": stackedRowSection.id - } - %} - {% include "@atoms/04-headings/comp-heading.twig" %} -
-
- {% endif %} +{% embed "@organisms/by-author/stacked-row-section.twig" with { + "stackedRowSection": heading, + "stackedRow": { + "borderless": true, + "modifier" : "no-sidebar" + }, + "externalSidebar": true +} %} + {% block stackedRowContentOverride %} + {% for org_component in org_components %} + {% if org_component.group == 'default' %} + {% embed "@organisms/by-author/rich-text.twig" %} + {% block rteElements %} + {% for c in org_component.items %} + {{ c|view }} + {% endfor %} + {% endblock %} + {% endembed %} + {% elseif org_component.group == 'self' %} + {% embed "@organisms/by-author/rich-text.twig" %} + {% block rteElements %} + {{ org_component.items|view }} + {% endblock %} + {% endembed %} + {% elseif org_component.group == 'contained' %} + {% embed "@organisms/by-author/rich-text.twig" with {'headerIndent' : 'om__contained-component'} %} + {% block rteElements %} + {{ org_component.items|view }} + {% endblock %} + {% endembed %} + {% else %} + {{ org_component[0]|view }} {% endif %} - {% endblock %} - {% block stackedRowContentOverride %} - {% for org_component in org_components %} - {% if org_component.group == 'default' %} - {% embed "@organisms/by-author/rich-text.twig" %} - {% block rteElements %} - {% for c in org_component.items %} - {{ c|view }} - {% endfor %} - {% endblock %} - {% endembed %} - {% elseif org_component.group == 'self' %} - {% embed "@organisms/by-author/rich-text.twig" %} - {% block rteElements %} - {{ org_component.items|view }} - {% endblock %} - {% endembed %} - {% elseif org_component.group == 'contained' %} - {% embed "@organisms/by-author/rich-text.twig" with {'headerIndent' : 'om__contained-component'} %} - {% block rteElements %} - {{ org_component.items|view }} - {% endblock %} - {% endembed %} - {% else %} - {{ org_component[0]|view }} - {% endif %} - {% endfor %} - {% endblock %} - {% endembed %} + {% endfor %} + {% endblock %} +{% endembed %} - {{ content.field_section_long_form_addition }} -
+{{ content.field_section_long_form_addition }}