ActionScheduler_Store::get_scheduled_date_string()
Get the time MySQL formated date/time string for an action's (next) scheduled date.
Метод класса: ActionScheduler_Store{}
Хуков нет.
Возвращает
Строку
.
Использование
// protected - в коде основоного (родительского) или дочернего класса $result = $this->get_scheduled_date_string( $action, $scheduled_date );
- $action(ActionScheduler_Action) (обязательный)
- -
- $scheduled_date(DateTime)
- (optional)
По умолчанию: NULL
Код ActionScheduler_Store::get_scheduled_date_string() ActionScheduler Store::get scheduled date string WC 7.7.0
protected function get_scheduled_date_string( ActionScheduler_Action $action, DateTime $scheduled_date = NULL ) { $next = null === $scheduled_date ? $action->get_schedule()->get_date() : $scheduled_date; if ( ! $next ) { $next = date_create(); } $next->setTimezone( new DateTimeZone( 'UTC' ) ); return $next->format( 'Y-m-d H:i:s' ); }