Closed quazardous closed 5 years ago
Can you please elaborate a little bit more what you would like to do.
Bonus points if you create a PR with the feature you need 💯
I want to be able to apply a function on the field raw value before it is passed to the normal flow.
for translate
$listMapper ->add('type', 'trans', [], 'catalogue' => 'messages']);
without preprocess the translate file for types would be like
```php
# root level
type1: Type 1
type2: Type 2
...
with some preprocess
$listMapper ->add('type', 'trans', ['preprocess' => function ($value) { return 'purchase.type_' . $value; }], 'catalogue' => 'messages']);
the translate file for types would be like
```php
# root level
purchase
type_type1: Type 1
type_type2: Type 2
...
This is not a big feature, but it can be handy too when you need to beautify raw value and overriding a template is little too much.
If I have some time I will try to do a PR
This bundle is deprecated. Please create a new feature request at the https://github.com/sonata-project/form-extensions project
Feature Request
Could be very handy to have a quick way to preprocess the value before display in the list.
What I do now to tweak
What could be cool