- Issue created by @allexim
- Status changed to Fixed
over 1 year ago 8:54am 18 April 2023 - 🇬🇧United Kingdom joachim
> The hook implementation function signature should be computed_field_field__compute($entity_type_manager, $entity, $fields, $delta), and the desired value should be returned.
If you're looking at those docs, then you're using the 3.x version, not the 4.x. The 3.x version is not very actively supported.
'hook implementation' means that you need a custom module, yes.
- 🇷🇺Russia allexim
Thank you for your quick reply!
... about v4:
php82 /usr/local/bin/composer82 require 'drupal/computed_field:^4.0@alpha'
/admin/structure/types/manage/video/fields
- upon verbose error level enabled ($config['system.logging']['error_level'] = 'verbose';)
<em>Error message</em> Deprecated function: Creation of dynamic property Drupal\computed_field\Form\ComputedFieldForm::$pluginManager is deprecated in Drupal\computed_field\Form\ComputedFieldForm->configureEntityViewDisplay() (line 300 of modules/contrib/computed_field/src/Form/ComputedFieldForm.php). Drupal\computed_field\Form\ComputedFieldForm->configureEntityViewDisplay('computed_php') (Line: 250) Drupal\computed_field\Form\ComputedFieldForm->submitForm(Array, Object)
Drupal\computed_field\Form\ComputedFieldForm->configureEntityViewDisplay('computed_php') (Line: 250)
Drupal\computed_field\Form\ComputedFieldForm->submitForm(Array, Object)
call_user_func_array(Array, Array) (Line: 114)Computed value source:
(the only one option) Reverse entity reference
Entity reference field:
Entity ID on Comment entities/admin/structure/types/manage/video/display
- All, what i see, is just a possibility to switch format:
- rendered entity
- entity id
- label
As for me, i do not have deep programming skills.
My experience of D7 computed field doesn't allow to comprehend your module for the latest versions of Drupal - D{9,10}, it is really hard to figure out how to deal with. - 🇬🇧United Kingdom joachim
> Deprecated function: Creation of dynamic property Drupal\computed_field\Form\ComputedFieldForm::$pluginManager is deprecated in
Could you file a separate issue for that please?
> My experience of D7 computed field doesn't allow to comprehend your module for the latest versions of Drupal - D{9,10}, it is really hard to figure out how to deal with.
Have you read the README? That explains how to set up the module.
- 🇷🇺Russia allexim
Sure, i will open a new issue...
Yes, i've read them both:
https://git.drupalcode.org/project/computed_field/-/blob/4.0.x/README.md
https://git.drupalcode.org/project/computed_field/-/blob/3.x/README.mdWill try to read again more attentively.
Automatically closed - issue fixed for 2 weeks with no activity.