From 92e2ff906728980ef8511b15f261ca9cf36e1203 Mon Sep 17 00:00:00 2001 From: Seamus Lee Date: Fri, 18 Aug 2023 07:25:10 +1000 Subject: [PATCH] Follow up to ensure we are excluding quick config price sets as per the previous function --- CRM/Contribute/Form/ContributionPage/Amount.php | 2 +- CRM/Member/Form/MembershipBlock.php | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CRM/Contribute/Form/ContributionPage/Amount.php b/CRM/Contribute/Form/ContributionPage/Amount.php index 544856b4f0..910d57e1a9 100644 --- a/CRM/Contribute/Form/ContributionPage/Amount.php +++ b/CRM/Contribute/Form/ContributionPage/Amount.php @@ -382,7 +382,7 @@ class CRM_Contribute_Form_ContributionPage_Amount extends CRM_Contribute_Form_Co if ($priceSetId) { // don't allow price set w/ membership. if ($hasMembershipBlk) { - $errors['price_set_id'] = ts('You cannot enable both Membership Signup and a Contribution Price Set on the same online contribution page'); + $errors['price_set_id'] = ts('You cannot enable both Membership Signup and a Contribution Price Set on the same online contribution page.'); } } else { diff --git a/CRM/Member/Form/MembershipBlock.php b/CRM/Member/Form/MembershipBlock.php index 7834352d4f..9018e63bc4 100644 --- a/CRM/Member/Form/MembershipBlock.php +++ b/CRM/Member/Form/MembershipBlock.php @@ -248,6 +248,7 @@ class CRM_Member_Form_MembershipBlock extends CRM_Contribute_Form_ContributionPa ->addWhere('entity_table', '=', 'civicrm_contribution_page') ->addWhere('entity_id', '=', $contributionPageId) ->addWhere('price_set.extends:name', 'CONTAINS', 'CiviMember') + ->addWhere('price_set.is_quick_config', '=', 0) ->execute() ->first(); if (!$priceSetExtendsMembership) { -- 2.25.1