Feature #36333

Using Locale parser in Float TypeConverter

Added by Adrian Föder over 9 years ago. Updated about 9 years ago.

Status:
Resolved
Priority:
Should have
Assignee:
Category:
Property
Start date:
2012-04-19
Due date:
% Done:

100%

Estimated time:
PHP Version:
Has patch:
Yes
Complexity:

Description

since the Validator has it, it would be nice and useful to let the Property Mapper use the Locale parser to differentiate between various given decimal and thousands separators


Files

0001-FEATURE-FloatConverter-uses-Locale-parser.patch (9.76 KB) 0001-FEATURE-FloatConverter-uses-Locale-parser.patch Fix error on missing configuration and add unit tests Alexander Berl, 2012-04-28 22:10

Related issues

Related to TYPO3.Flow - Bug #35173: PropertyMapping: FloatConverter - map from float to float is not workingClosedNils Seinschedt2012-03-23

Actions
#1

Updated by Gerrit Code Review over 9 years ago

  • Status changed from New to Under Review

Patch set 1 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10634

#2

Updated by Alexander Berl over 9 years ago

I'd suggest using $this->localizationService->getConfiguration()->getCurrentLocale() instead of $this->localizationService->getConfiguration()->getDefaultLocale(), because it falls back to default locale but allows for overriding the locale via code (for example by parsing Accept-Language headers, or from session).

Other than that +1

#3

Updated by Gerrit Code Review over 9 years ago

Patch set 2 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10634

#4

Updated by Adrian Föder over 9 years ago

  • Has patch changed from No to Yes

thanks Alexander for the catch, could you review it again please and comment/vote directly on Gerrit? Thanks a lot!

#5

Updated by Alexander Berl over 9 years ago

I'm not sure how to push a change to this changeset and found no one on the IRC channel to give me some hints, so I'm just adding a patch diff.

This fixes the failing test when no configuration is given with the convertFrom call, adds conversion from float => float which resolves #35173 and adds some more unit tests for the new functionality.

#6

Updated by Gerrit Code Review over 9 years ago

Patch set 3 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10634

#7

Updated by Karsten Dambekalns over 9 years ago

  • Target version changed from 1.1 to 1.1 RC1
#8

Updated by Karsten Dambekalns over 9 years ago

  • Target version changed from 1.1 RC1 to 2.0 beta 1
#9

Updated by Gerrit Code Review over 9 years ago

Patch set 4 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10634

#10

Updated by Gerrit Code Review over 9 years ago

Patch set 5 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10634

#11

Updated by Gerrit Code Review over 9 years ago

Patch set 6 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10634

#12

Updated by Gerrit Code Review about 9 years ago

Patch set 7 for branch master has been pushed to the review server.
It is available at http://review.typo3.org/10634

#13

Updated by Adrian Föder about 9 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

Also available in: Atom PDF