Verified Commit 2c8a999b authored by Dave Long's avatar Dave Long
Browse files

Issue #3218087 by nlisgo, Gribnif, Lendude, smustgrave: Views...

Issue #3218087 by nlisgo, Gribnif, Lendude, smustgrave: Views MysqlDateSql::getDateFormat() should translate PHP's 'o' format to MySQL's '%x'

(cherry picked from commit ef8f7aa8)
parent 515304ab
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -27,6 +27,7 @@ class MysqlDateSql implements DateSqlInterface {
  protected static $replace = [
    'Y' => '%Y',
    'y' => '%y',
    'o' => '%x',
    'M' => '%b',
    'm' => '%m',
    'n' => '%c',
+1 −1
Original line number Diff line number Diff line
@@ -65,7 +65,7 @@ public function providerTestGetDateFormat() {
    return [
      ['foo.field', 'Y-y-M-m', '%Y-%y-%b-%m'],
      ['bar.field', 'n-F D d l', '%c-%M %a %d %W'],
      ['baz.bar_field', 'j/W/H-h i s A', '%e/%v/%H-%h %i %s %p'],
      ['baz.bar_field', 'o j/W/H-h i s A', '%x %e/%v/%H-%h %i %s %p'],
    ];
  }