Action_Scheduler\WP_CLI

Action_Command::delete │ public │ WC 1.0

Delete existing scheduled action(s).

OPTIONS

<id>...
One or more IDs of actions to delete.
--- default: 0
---

EXAMPLES

# Delete the action with id 100
$ wp action-scheduler action delete 100
# Delete the actions with ids 100 and 200
$ wp action-scheduler action delete 100 200
# Delete the first five pending actions in 'action-scheduler' group
$ wp action-scheduler action delete $( wp action-scheduler action list --status=pending --group=action-scheduler --format=ids )

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

Хуков нет.

Возвращает

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

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

$Action_Command = new Action_Command();
$Action_Command->delete( $args, $assoc_args );
$args(массив) (обязательный)
Positional arguments.
$assoc_args(массив) (обязательный)
Keyed arguments.

Код Action_Command::delete() WC 11.2.2

public function delete( array $args, array $assoc_args ) {
	require_once __DIR__ . '/Action/Delete_Command.php';
	$command = new Action\Delete_Command( $args, $assoc_args );
	$command->execute();
}