File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1356,10 +1356,10 @@ protected function intToDate(int $value)
13561356 return $ value ;
13571357
13581358 case 'datetime ' :
1359- return date (' Y-m-d H:i:s ' , $ value );
1359+ return date ($ this -> db -> dateFormat [ ' datetime ' ] , $ value );
13601360
13611361 case 'date ' :
1362- return date (' Y-m-d ' , $ value );
1362+ return date ($ this -> db -> dateFormat [ ' date ' ] , $ value );
13631363
13641364 default :
13651365 throw ModelException::forNoDateFormat (static ::class);
@@ -1382,10 +1382,10 @@ protected function timeToDate(Time $value)
13821382 {
13831383 switch ($ this ->dateFormat ) {
13841384 case 'datetime ' :
1385- return $ value ->format (' Y-m-d H:i:s ' );
1385+ return $ value ->format ($ this -> db -> dateFormat [ ' datetime ' ] );
13861386
13871387 case 'date ' :
1388- return $ value ->format (' Y-m-d ' );
1388+ return $ value ->format ($ this -> db -> dateFormat [ ' date ' ] );
13891389
13901390 case 'int ' :
13911391 return $ value ->getTimestamp ();
You can’t perform that action at this time.
0 commit comments