WooCommerce Code Reference

FulfillmentsController
in package

Class FulfillmentsController

Base controller for fulfillments management.

Table of Contents

$provides  : array<string|int, string>
Provides the list of classes that this controller provides.
initialize_fulfillments()  : mixed
Initialize the fulfillments controller.
register()  : void
Initialize the controller.
register_data_stores()  : array<string|int, mixed>
Register the fulfillments data store via the woocommerce_data_stores filter.
bulk_delete_order_fulfillment_status_meta()  : void
Bulk delete fulfillment status meta for specific order IDs, or all orders if no order ID specified.
delete_hpos_order_fulfillment_meta()  : void
Delete fulfillment status meta from HPOS meta table.
delete_legacy_order_fulfillment_meta()  : mixed
Delete fulfillment status meta from legacy postmeta table.
maybe_create_db_tables()  : void
Create the database tables if they do not exist.
register_custom_shipping_providers_taxonomy()  : void
Register the custom shipping providers taxonomy.

Properties

$provides

Provides the list of classes that this controller provides.

private array<string|int, string> $provides = array(AutomatticWooCommerceAdminFeaturesFulfillmentsFulfillmentsManager::class, AutomatticWooCommerceAdminFeaturesFulfillmentsFulfillmentsRenderer::class, AutomatticWooCommerceAdminFeaturesFulfillmentsFulfillmentsSettings::class, AutomatticWooCommerceAdminFeaturesFulfillmentsOrderFulfillmentsRestController::class)

Methods

register_data_stores()

Register the fulfillments data store via the woocommerce_data_stores filter.

public register_data_stores(array<string|int, mixed> $data_stores) : array<string|int, mixed>

This allows extensions to replace the data store with a custom implementation by filtering 'woocommerce_data_stores' or 'woocommerce_order-fulfillment_data_store'.

Parameters
$data_stores : array<string|int, mixed>

Data stores.

Return values
array<string|int, mixed>

bulk_delete_order_fulfillment_status_meta()

Bulk delete fulfillment status meta for specific order IDs, or all orders if no order ID specified.

private bulk_delete_order_fulfillment_status_meta([array<string|int, int> $order_ids = array() ]) : void

This method deletes the fulfillment status meta for the specified order IDs from both the legacy postmeta table and the HPOS meta table.

Parameters
$order_ids : array<string|int, int> = array()

Array of order IDs to delete fulfillment status meta for.

Return values
void

delete_hpos_order_fulfillment_meta()

Delete fulfillment status meta from HPOS meta table.

private delete_hpos_order_fulfillment_meta([array<string|int, int> $order_ids = array() ]) : void
Parameters
$order_ids : array<string|int, int> = array()

Array of order IDs to delete fulfillment status meta for.

Return values
void

delete_legacy_order_fulfillment_meta()

Delete fulfillment status meta from legacy postmeta table.

private delete_legacy_order_fulfillment_meta([array<string|int, int> $order_ids = array() ]) : mixed
Parameters
$order_ids : array<string|int, int> = array()

Array of order IDs to delete fulfillment status meta for.

Return values
mixed