Bug #47054
IntegerConverter not found for properties annotated with @var int
Status: | Resolved | Start date: | 2013-04-08 | |
---|---|---|---|---|
Priority: | Should have | Due date: | ||
Assigned To: | Philipp Maier | % Done: | 100% |
|
Category: | Property | |||
Target version: | - | |||
PHP Version: | Complexity: | |||
Has patch: | No | Affected Flow version: | Git master |
Description
Attached you can find an working example package. The properties (and setter methods) in the DTO are annotated as 'int'.
On submitting the form, no suitable converter can be found. If the property is annotated with 'integer' it works as expected.
This should (imo) also work for 'int'.
The exact error message is:
#1297759968: Exception while property mapping for target type "TypeConverter\Test\Domain\Model\DTO\IntegerConverter", at property path "someProperty": No converter found which can be used to convert from "string" to "int".
Associated revisions
[BUGFIX] PropertyMapper now normalizes simple types
This fixes a bug where the property mapper was unable to find a
valid typeconverter for properties annotated with int or bool.
Change-Id: Ic9db9626613083bc8400ca3d96ca85475c7fb106
Fixes: #47054
Releases: master, 2.0, 1.1
[BUGFIX] PropertyMapper now normalizes simple types
This fixes a bug where the property mapper was unable to find a
valid typeconverter for properties annotated with int or bool.
Change-Id: Ic9db9626613083bc8400ca3d96ca85475c7fb106
Fixes: #47054
Releases: master, 2.0, 1.1
[BUGFIX] PropertyMapper now normalizes simple types
This fixes a bug where the property mapper was unable to find a
valid typeconverter for properties annotated with int or bool.
Change-Id: Ic9db9626613083bc8400ca3d96ca85475c7fb106
Fixes: #47054
Releases: master, 2.0, 1.1
History
#1 Updated by Philipp Maier over 2 years ago
- File TypeConverter.Test.zip added
Ofc I should attach said package now, should I? :)
#2 Updated by Adrian Föder over 2 years ago
- Category set to Property
- Assigned To set to Philipp Maier
Since you've said you'll give it a try to fix it,
the actual conversion happens here, \TYPO3\Flow\Property\PropertyMapper::convert
I don't know ATM if the targetType should be normalized then already, or if this will be done at a later stage. Maybe you'll come up with an answer to that.
Have also a look at \TYPO3\Flow\Utility\TypeHandling::normalizeType :)
#3 Updated by Philipp Maier over 2 years ago
This also happens with bool <> boolean.
And yup, I'm on it.
#4 Updated by Gerrit Code Review over 2 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 https://review.typo3.org/19769
#5 Updated by Gerrit Code Review over 2 years ago
Patch set 2 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/19769
#6 Updated by Gerrit Code Review over 2 years ago
Patch set 3 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/19769
#7 Updated by Gerrit Code Review over 2 years ago
Patch set 4 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/19769
#8 Updated by Gerrit Code Review over 2 years ago
Patch set 5 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/19769
#9 Updated by Gerrit Code Review over 2 years ago
Patch set 6 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/19769
#10 Updated by Gerrit Code Review over 2 years ago
Patch set 7 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/19769
#11 Updated by Gerrit Code Review over 2 years ago
Patch set 8 for branch master has been pushed to the review server.
It is available at https://review.typo3.org/19769
#12 Updated by Gerrit Code Review over 2 years ago
Patch set 1 for branch 2.0 has been pushed to the review server.
It is available at https://review.typo3.org/20358
#13 Updated by Gerrit Code Review over 2 years ago
Patch set 1 for branch FLOW3-1.1 has been pushed to the review server.
It is available at https://review.typo3.org/20359
#14 Updated by Philipp Maier over 2 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset f6d8d4fbc3a4cc5ce86c44089d146c37bc312fb7.