X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=api%2Fv3%2FLogging.php;h=7abc337574251b49d96568c1907506fc6136ca46;hb=060ea8f8e944292abc945b136c66cb7ccabd4fc1;hp=76c02053794e676716acb9061e0a76fb45e9ad22;hpb=d880d1db343ce51a575d446d2748e3e1e5468277;p=civicrm-core.git diff --git a/api/v3/Logging.php b/api/v3/Logging.php index 76c0205379..7abc337574 100644 --- a/api/v3/Logging.php +++ b/api/v3/Logging.php @@ -1,27 +1,11 @@ 'Logging Connection ID', 'type' => CRM_Utils_Type::T_STRING, 'api.required' => TRUE, - ); - $params['log_date'] = array( + ]; + $params['log_date'] = [ 'title' => 'Logging Timestamp', 'type' => CRM_Utils_Type::T_DATE + CRM_Utils_Type::T_TIME, - ); - $params['interval'] = array( + ]; + $params['interval'] = [ 'title' => ts('Interval (required if date is included)'), 'type' => CRM_Utils_Type::T_STRING, 'api.default' => '10 SECOND', 'description' => ts('Used when log_date is passed in'), - ); + ]; - $params['tables'] = array( + $params['tables'] = [ 'title' => ts('Tables to revert'), 'type' => CRM_Utils_Type::T_STRING, 'description' => ts('Tables to revert, if not set all contact-referring entities will be reverted'), - ); + ]; } /** @@ -88,7 +72,7 @@ function _civicrm_api3_logging_revert_spec(&$params) { * @param array $params * * @return array - * API Success Array + * API Success Array * @throws \API_Exception * @throws \Civi\API\Exception\UnauthorizedException */ @@ -109,24 +93,24 @@ function civicrm_api3_logging_get($params) { * @throws \Civi\API\Exception\UnauthorizedException */ function _civicrm_api3_logging_get_spec(&$params) { - $params['log_conn_id'] = array( + $params['log_conn_id'] = [ 'title' => 'Logging Connection ID', 'type' => CRM_Utils_Type::T_STRING, 'api.required' => TRUE, - ); - $params['log_date'] = array( + ]; + $params['log_date'] = [ 'title' => 'Logging Timestamp', 'type' => CRM_Utils_Type::T_DATE + CRM_Utils_Type::T_TIME, - ); - $params['interval'] = array( + ]; + $params['interval'] = [ 'title' => ts('Interval (required if date is included)'), 'type' => CRM_Utils_Type::T_STRING, 'api.default' => '10 SECOND', 'description' => ts('Used when log_date is passed in'), - ); - $params['tables'] = array( + ]; + $params['tables'] = [ 'title' => ts('Tables to query'), 'type' => CRM_Utils_Type::T_STRING, 'description' => ts('Tables to query, if not set all contact-referring entities will be queried'), - ); + ]; }