File tree Expand file tree Collapse file tree 6 files changed +9
-7
lines changed
app/code/Magento/SalesGraphQl/Model
dev/tests/api-functional/testsuite/Magento/GraphQl/Sales
lib/internal/Magento/Framework/Stdlib Expand file tree Collapse file tree 6 files changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -49,7 +49,7 @@ public function format(OrderInterface $orderModel): array
49
49
'increment_id ' => $ orderModel ->getIncrementId (),
50
50
'number ' => $ orderModel ->getIncrementId (),
51
51
'order_date ' => $ this ->timezone ->date ($ orderModel ->getCreatedAt ())
52
- ->format (DateTime::DATETIME_PHP_FORMAT ),
52
+ ->format (DateTime::DATETIME_SLASH_PHP_FORMAT ),
53
53
'order_number ' => $ orderModel ->getIncrementId (),
54
54
'status ' => $ orderModel ->getStatusLabel (),
55
55
'email ' => $ orderModel ->getCustomerEmail (),
Original file line number Diff line number Diff line change @@ -53,7 +53,7 @@ public function resolve(
53
53
$ comments [] = [
54
54
'message ' => $ comment ->getComment (),
55
55
'timestamp ' => $ this ->timezone ->date ($ comment ->getCreatedAt ())
56
- ->format (DateTime::DATETIME_PHP_FORMAT )
56
+ ->format (DateTime::DATETIME_SLASH_PHP_FORMAT )
57
57
];
58
58
}
59
59
}
Original file line number Diff line number Diff line change @@ -74,7 +74,7 @@ private function getInvoiceComments(InvoiceInterface $invoice): array
74
74
if ($ comment ->getIsVisibleOnFront ()) {
75
75
$ comments [] = [
76
76
'timestamp ' => $ this ->timezone ->date ($ comment ->getCreatedAt ())
77
- ->format (DateTime::DATETIME_PHP_FORMAT ),
77
+ ->format (DateTime::DATETIME_SLASH_PHP_FORMAT ),
78
78
'message ' => $ comment ->getComment ()
79
79
];
80
80
}
Original file line number Diff line number Diff line change @@ -75,7 +75,7 @@ private function getShipmentComments(ShipmentInterface $shipment): array
75
75
if ($ comment ->getIsVisibleOnFront ()) {
76
76
$ comments [] = [
77
77
'timestamp ' => $ this ->timezone ->date ($ comment ->getCreatedAt ())
78
- ->format (DateTime::DATETIME_PHP_FORMAT ),
78
+ ->format (DateTime::DATETIME_SLASH_PHP_FORMAT ),
79
79
'message ' => $ comment ->getComment ()
80
80
];
81
81
}
Original file line number Diff line number Diff line change @@ -509,7 +509,7 @@ public function testGetCustomerDescendingSortedOrders()
509
509
for ($ i = 1 ; $ i <= 3 ; $ i ++) {
510
510
$ orderNumber = $ this ->fixtures ->get ('or ' . $ i )->getIncrementId ();
511
511
$ orderCreatedAt = $ this ->timezone ->date ($ this ->fixtures ->get ('or ' . $ i )->getCreatedAt ())
512
- ->format (DateTime::DATETIME_PHP_FORMAT );
512
+ ->format (DateTime::DATETIME_SLASH_PHP_FORMAT );
513
513
$ orderNumberCreatedAtExpected [$ orderNumber ] = $ orderCreatedAt ;
514
514
}
515
515
Original file line number Diff line number Diff line change 1
1
<?php
2
2
/**
3
- * Copyright © Magento, Inc. All rights reserved.
4
- * See COPYING.txt for license details .
3
+ * Copyright 2011 Adobe
4
+ * All Rights Reserved .
5
5
*/
6
6
namespace Magento \Framework \Stdlib ;
7
7
@@ -25,6 +25,8 @@ class DateTime
25
25
26
26
public const DATE_PHP_FORMAT = 'Y-m-d ' ;
27
27
28
+ public const DATETIME_SLASH_PHP_FORMAT = 'd/m/Y H:i:s ' ;
29
+
28
30
/**#@-*/
29
31
30
32
/**
You can’t perform that action at this time.
0 commit comments