DataStore
1 month ago
Providers
3 months ago
Fulfillment.php
1 month ago
FulfillmentException.php
3 months ago
FulfillmentOrderNotes.php
3 months ago
FulfillmentUtils.php
2 months ago
FulfillmentsController.php
3 months ago
FulfillmentsManager.php
2 months ago
FulfillmentsRenderer.php
1 month ago
FulfillmentsSettings.php
3 months ago
FulfillmentsTracker.php
3 months ago
OrderFulfillmentsRestController.php
1 month ago
ShippingProviders.php
3 months ago
FulfillmentException.php
26 lines
| 1 | <?php declare( strict_types = 1 ); |
| 2 | |
| 3 | namespace Automattic\WooCommerce\Admin\Features\Fulfillments; |
| 4 | |
| 5 | use Automattic\WooCommerce\Internal\Admin\Settings\Exceptions\ApiException; |
| 6 | |
| 7 | /** |
| 8 | * FulfillmentException class. |
| 9 | * This exception is thrown when there is an issue with fulfillment operations, |
| 10 | * such as creating, updating, or deleting fulfillments. |
| 11 | */ |
| 12 | class FulfillmentException extends ApiException { |
| 13 | /** |
| 14 | * Setup exception. |
| 15 | * |
| 16 | * @param string $message User-friendly translated error message, e.g. 'Fulfillment creation failed'. |
| 17 | * @param int $http_status_code Optional. Proper HTTP status code to respond with. |
| 18 | * Defaults to 400 (Bad request). |
| 19 | * @param array $additional_data Optional. Extra data (key value pairs) to expose in the error response. |
| 20 | * Defaults to empty array. |
| 21 | */ |
| 22 | public function __construct( string $message, int $http_status_code = 400, array $additional_data = array() ) { |
| 23 | parent::__construct( 'woocommerce_fulfillment_error', $message, $http_status_code, $additional_data ); |
| 24 | } |
| 25 | } |
| 26 |