includes/api/class-wc-rest-order-refunds-controller.php 1 location
|
@@ 510-522 (lines=13) @@
|
| 507 |
|
* |
| 508 |
|
* @return array |
| 509 |
|
*/ |
| 510 |
|
public function get_collection_params() { |
| 511 |
|
$params = parent::get_collection_params(); |
| 512 |
|
|
| 513 |
|
$params['dp'] = array( |
| 514 |
|
'default' => 2, |
| 515 |
|
'description' => __( 'Number of decimal points to use in each resource.', 'woocommerce' ), |
| 516 |
|
'type' => 'integer', |
| 517 |
|
'sanitize_callback' => 'absint', |
| 518 |
|
'validate_callback' => 'rest_validate_request_arg', |
| 519 |
|
); |
| 520 |
|
|
| 521 |
|
return $params; |
| 522 |
|
} |
| 523 |
|
} |
| 524 |
|
|
includes/api/class-wc-rest-coupons-controller.php 1 location
|
@@ 503-514 (lines=12) @@
|
| 500 |
|
* |
| 501 |
|
* @return array |
| 502 |
|
*/ |
| 503 |
|
public function get_collection_params() { |
| 504 |
|
$params = parent::get_collection_params(); |
| 505 |
|
$params['code'] = array( |
| 506 |
|
'description' => __( 'Limit result set to resources with a specific code.', 'woocommerce' ), |
| 507 |
|
'type' => 'string', |
| 508 |
|
'sanitize_callback' => 'sanitize_text_field', |
| 509 |
|
'validate_callback' => 'rest_validate_request_arg', |
| 510 |
|
); |
| 511 |
|
return $params; |
| 512 |
|
} |
| 513 |
|
} |
| 514 |
|
|