File names:
.../core/modules/datetime/lib/Drupal/datetime/Plugin/field/formatter/DatetimeDefaultFormatter.php
.../core/modules/datetime/lib/Drupal/datetime/Plugin/field/formatter/DatetimePlainFormatter.php

Class names:
DateTimeDefaultFormatter
DateTimePlainFormatter

This differences causes fatal error when you try to replace the class in hook_field_formatter_info()

Files: 
CommentFileSizeAuthor
#5 drupal-2073669.patch862 bytesSweetchuck
PASSED: [[SimpleTest]]: [MySQL] 58,862 pass(es).
[ View ]
#3 drupal-2073669.patch15.61 KBSweetchuck
PASSED: [[SimpleTest]]: [MySQL] 59,005 pass(es).
[ View ]
#1 drupal-2073669.patch14.23 KBSweetchuck
PASSED: [[SimpleTest]]: [MySQL] 58,508 pass(es).
[ View ]

Comments

Sweetchuck’s picture

Status:Active» Needs review
StatusFileSize
new14.23 KB
PASSED: [[SimpleTest]]: [MySQL] 58,508 pass(es).
[ View ]

The patch only renames the mentioned files.

CaptainWonky’s picture

Status:Needs review» Needs work

Patch doesn't apply anymore.

Reading the patch, it seems DatetimePlainFormatter doesn't get removed.

I'd reroll myself but it seems my git has problems realising that lower case is different from upper case. It's a Windows thing I think!

Sweetchuck’s picture

Status:Needs work» Needs review
StatusFileSize
new15.61 KB
PASSED: [[SimpleTest]]: [MySQL] 59,005 pass(es).
[ View ]
Berdir’s picture

Status:Needs review» Needs work

See https://drupal.org/documentation/git/configure on how to create a patch that moves files instead of removing and adding them again.

You can also try to just specify -M50 as an option to git diff.

Sweetchuck’s picture

StatusFileSize
new862 bytes
PASSED: [[SimpleTest]]: [MySQL] 58,862 pass(es).
[ View ]

OK. Thank you for the idea.

Sweetchuck’s picture

Status:Needs work» Needs review
vijaycs85’s picture

Issue summary:View changes
Status:Needs review» Reviewed & tested by the community
Issue tags:+Novice, +rename

Thanks, Same problem for widgets solved at #2090313: DateTime widget's filenames don't match its class names. :)

alexpott’s picture

Status:Reviewed & tested by the community» Needs work
Issue tags:+Needs reroll

drupal-2073669_1.patch no longer applies.

error: core/modules/datetime/lib/Drupal/datetime/Plugin/field/formatter/DatetimeDefaultFormatter.php: No such file or directory
error: core/modules/datetime/lib/Drupal/datetime/Plugin/field/formatter/DatetimePlainFormatter.php: No such file or directory
vijaycs85’s picture

This change has been committed as part of #2156283: Fix case of Datetime widgets and formatters. Would be great, if we can give some commit credit to 'Sweetchuck'

vijaycs85’s picture

Status:Needs work» Closed (duplicate)