+--------------------------------------------------------------------+
| CiviCRM version 4.7 |
+--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2016 |
+ | Copyright CiviCRM LLC (c) 2004-2017 |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
}
CRM_Extension_System::singleton()->getCache()->flush();
CRM_Extension_System::singleton(TRUE);
- CRM_Extension_System::singleton()->getManager()->install(array($params['key']));
+ if (CRM_Utils_Array::value('install', $params, TRUE)) {
+ CRM_Extension_System::singleton()->getManager()->install(array($params['key']));
+ }
return civicrm_api3_create_success();
}
'type' => CRM_Utils_Type::T_STRING,
'description' => 'Optional as the system can determine the url automatically for public extensions',
);
+ $fields['install'] = array(
+ 'title' => 'Auto-install',
+ 'type' => CRM_Utils_Type::T_STRING,
+ 'description' => 'Automatically install the downloaded extension',
+ 'api.default' => TRUE,
+ );
}
/**