src/Command/MigrateCommand.php
protected function _parseTimestamp($timestamp)
    {
        if (is_null($timestamp))
            return AbstractQuery::getCurrentTimestamp();

        if (!AbstractQuery::isValidTimestamp($timestamp)) {
            if ($sTime = strtotime($timestamp)) {
                $timestamp = date('YmdHis', $sTime);
            } else {
                throw oxNew(
                    ConsoleException::class,
                    'Invalid timestamp format, use YYYYMMDDhhmmss format'
                );
            }
        }

        return $timestamp;
    }
protected function _parseTimestamp($timestamp)
    {
        if (is_null($timestamp))
            return AbstractQuery::getCurrentTimestamp();

        if (!AbstractQuery::isValidTimestamp($timestamp)) {
            if ($sTime = strtotime($timestamp)) {
                $timestamp = date('YmdHis', $sTime);
            } else {
                throw oxNew(
                    ConsoleException::class,
                    'Invalid timestamp format, use YYYYMMDDhhmmss format'
                );
            }
        }

        return $timestamp;
    }
protected function _parseTimestamp ( $ timestamp ) { if ( is_null ( $ timestamp ) ) return AbstractQuery :: getCurrentTimestamp ( ) ; if ( ! AbstractQuery :: isValidTimestamp ( $ timestamp ) ) { if ( $ sTime = strtotime ( $ timestamp ) ) { $ timestamp = date ( 'YmdHis' , $ sTime ) ; } else { throw oxNew ( ConsoleException :: class , 'Invalid timestamp format, use YYYYMMDDhhmmss format' ) ; } } return $ timestamp ; }
Parse timestamp from user input

@param string|null $timestamp

@return string
Parse timestamp from user input