diff --git a/CRM/Upgrade/Incremental/General.php b/CRM/Upgrade/Incremental/General.php
index dca7b60d5d38..a2add6413185 100644
--- a/CRM/Upgrade/Incremental/General.php
+++ b/CRM/Upgrade/Incremental/General.php
@@ -126,6 +126,15 @@ public static function setPreUpgradeMessage(&$preUpgradeMessage, $currentVer, $l
// advanced feature in the hands of the sysadmin.
$preUpgradeMessage .= '
' . ts('This database uses InnoDB Full Text Search for optimized searching. The upgrade procedure has not been tested with this feature. You should disable (and later re-enable) the feature by navigating to "Administer => System Settings => Miscellaneous".');
}
+
+ $ftAclSetting = Civi::settings()->get('acl_financial_type');
+ $financialAclExtension = civicrm_api3('extension', 'get', array('key' => 'biz.jmaconsulting.financialaclreport'));
+ if ($ftAclSetting && (($financialAclExtension['count'] == 1 && $financialAclExtension['status'] != 'Installed') || $financialAclExtension['count'] !== 1)) {
+ $preUpgradeMessage .= '
' . ts('CiviCRM will in the future require the extension %1 for CiviCRM Reports to work correctly with the Financial Type ACLs. The extension can be downloaded here', array(
+ 1 => 'biz.jmaconsulting.financialaclreport',
+ 2 => 'https://github.com/JMAConsulting/biz.jmaconsulting.financialaclreport',
+ ));
+ }
}
/**
diff --git a/CRM/Utils/Check/Component/FinancialTypeAcls.php b/CRM/Utils/Check/Component/FinancialTypeAcls.php
new file mode 100644
index 000000000000..3785d49d7921
--- /dev/null
+++ b/CRM/Utils/Check/Component/FinancialTypeAcls.php
@@ -0,0 +1,55 @@
+get('acl_financial_type');
+ $financialAclExtension = civicrm_api3('extension', 'get', array('key' => 'biz.jmaconsulting.financialaclreport'));
+ if ($ftAclSetting && (($financialAclExtension['count'] == 1 && $financialAclExtension['status'] != 'Installed') || $financialAclExtension['count'] !== 1)) {
+ $messages[] = new CRM_Utils_Check_Message(
+ __FUNCTION__,
+ ts('CiviCRM will in the future require the extension %1 for CiviCRM Reports to work correctly with the Financial Type ACLs. The extension can be downloaded here', array(
+ 1 => 'biz.jmaconsulting.financialaclreport',
+ 2 => 'https://github.com/JMAConsulting/biz.jmaconsulting.financialaclreport',
+ )),
+ ts('Extension Missing'),
+ \Psr\Log\LogLevel::WARNING,
+ 'fa-server'
+ );
+ }
+
+ return $messages;
+ }
+
+}