From: David Reedy Jr Date: Tue, 29 Dec 2015 14:03:43 +0000 (-0600) Subject: CRM-17686 fix disabling of extension on upgrade X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=13599400c54c9cbad29ec695eb2ed6fc52646d35;p=civicrm-core.git CRM-17686 fix disabling of extension on upgrade --- diff --git a/CRM/Upgrade/Incremental/php/FourSeven.php b/CRM/Upgrade/Incremental/php/FourSeven.php index 2fd013a061..d2628f6620 100644 --- a/CRM/Upgrade/Incremental/php/FourSeven.php +++ b/CRM/Upgrade/Incremental/php/FourSeven.php @@ -140,6 +140,7 @@ class CRM_Upgrade_Incremental_php_FourSeven extends CRM_Upgrade_Incremental_Base * @param string $rev */ public function upgrade_4_7_beta5($rev) { + $this->addTask(ts('Upgrade DB to %1: SQL', array(1 => $rev)), 'runSql', $rev); $this->addTask('Disable flexible jobs extension', 'disableFlexibleJobsExtension'); } @@ -380,7 +381,7 @@ FROM `civicrm_dashboard_contact` WHERE 1 GROUP BY contact_id"; * @return bool */ public function disableFlexibleJobsExtension(CRM_Queue_TaskContext $ctx) { - CRM_Core_DAO::setFieldValue('CRM_Core_DAO_Job', 'Flexible Jobs', 'is_active', 0, 'name'); + civicrm_api3('Extension', 'disable', array('key' => 'com.klangsoft.flexiblejobs')); return TRUE; }