Automattic\WooCommerce\Admin\Features\Fulfillments

FulfillmentsTracker::track_fulfillment_deletion │ public static │ WC 10.7.0

Track when a fulfillment is successfully deleted.

Tracked from: OrderFulfillmentsRestController::delete_fulfillment(). Measures: How often merchants remove fulfillments and at what stage.

Метод класса: FulfillmentsTracker{}

Хуков нет.

Возвращает

void. Ничего (null).

Использование

$result = FulfillmentsTracker::track_fulfillment_deletion( $source, $fulfillment_id, $status_at_deletion, $notification_sent ): void;
$source(строка) (обязательный)
The source of the deletion ("fulfillments_modal" or "api").
$fulfillment_id(int) (обязательный)
The ID of the fulfillment being deleted.
$status_at_deletion(строка) (обязательный)
The status at the time of deletion ("draft" or "fulfilled").
$notification_sent(true|false) (обязательный)
Whether a deletion notification was requested.

Список изменений

С версии 10.7.0 Введена.

Код FulfillmentsTracker::track_fulfillment_deletion() WC 11.2.2

public static function track_fulfillment_deletion( string $source, int $fulfillment_id, string $status_at_deletion, bool $notification_sent ): void {
	WC_Tracks::record_event(
		'fulfillment_deleted',
		array(
			'source'             => $source,
			'fulfillment_id'     => $fulfillment_id,
			'status_at_deletion' => $status_at_deletion,
			'notification_sent'  => $notification_sent,
		)
	);
}