X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=api%2Fv3%2FDashboard.php;h=77f6d30bd6141e0d46e3c67f2b858f32f1101fa3;hb=a60c0bc84a8db9a4123f53879109576524393ff9;hp=95a7327fd38255bdcb404b6589199800cab794cf;hpb=4f87ec96e8ba594ad1705a8806999bd0bc976bb0;p=civicrm-core.git diff --git a/api/v3/Dashboard.php b/api/v3/Dashboard.php index 95a7327fd3..77f6d30bd6 100644 --- a/api/v3/Dashboard.php +++ b/api/v3/Dashboard.php @@ -3,7 +3,7 @@ +--------------------------------------------------------------------+ | CiviCRM version 4.7 | +--------------------------------------------------------------------+ - | Copyright CiviCRM LLC (c) 2004-2015 | + | Copyright CiviCRM LLC (c) 2004-2016 | +--------------------------------------------------------------------+ | This file is a part of CiviCRM. | | | @@ -61,6 +61,7 @@ function civicrm_api3_dashboard_create($params) { * array of parameters determined by getfields. */ function _civicrm_api3_dashboard_create_spec(&$params) { + $params['is_active']['api.default'] = 1; unset($params['version']); } @@ -92,6 +93,6 @@ function civicrm_api3_dashboard_delete($params) { return civicrm_api3_create_success(1, $params, 'Dashboard', 'delete'); } else { - return civicrm_api3_create_error('Could not delete dashlet'); + throw new API_Exception('Could not delete dashlet'); } }