Revert "Convert before and after dates to UTC (https://github.com/woocommerce/woocommerce-admin/pull/5819)" (https://github.com/woocommerce/woocommerce-admin/pull/5834)
This reverts commit c86563c3ac
.
This commit is contained in:
parent
16ef985c39
commit
bc6ba4f3ac
|
@ -692,8 +692,6 @@ class DataStore extends SqlQuery {
|
|||
$datetime_str = $query_args['before']->date( TimeInterval::$sql_datetime_format );
|
||||
} else {
|
||||
$datetime_str = $query_args['before']->format( TimeInterval::$sql_datetime_format );
|
||||
$datetime_str = TimeInterval::convert_local_datetime_to_gmt( $datetime_str )
|
||||
->format( TimeInterval::$sql_datetime_format );
|
||||
}
|
||||
if ( isset( $this->subquery ) ) {
|
||||
$this->subquery->add_sql_clause( 'where_time', "AND {$table_name}.date_created <= '$datetime_str'" );
|
||||
|
@ -707,8 +705,6 @@ class DataStore extends SqlQuery {
|
|||
$datetime_str = $query_args['after']->date( TimeInterval::$sql_datetime_format );
|
||||
} else {
|
||||
$datetime_str = $query_args['after']->format( TimeInterval::$sql_datetime_format );
|
||||
$datetime_str = TimeInterval::convert_local_datetime_to_gmt( $datetime_str )
|
||||
->format( TimeInterval::$sql_datetime_format );
|
||||
}
|
||||
if ( isset( $this->subquery ) ) {
|
||||
$this->subquery->add_sql_clause( 'where_time', "AND {$table_name}.date_created >= '$datetime_str'" );
|
||||
|
|
Loading…
Reference in New Issue