Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Please forgive my poor English, I just want to report this bug.
if you follow this, you can find this bug.
1) Add a new field for comment . eg:sex
http://localhost/drupal8/admin/structure/types/manage/page/comment/fields
2) Create a new conent, and add a comment.
3) Create a new views with comment type,and add the sex field (Comment: sex (sex))
4) you can find the field can't show the value.
This bug only appear in the comment types and custom Entity type
Comment | File | Size | Author |
---|---|---|---|
#8 | drupal-1977464-8.patch | 575 bytes | dawehner |
#6 | drupal-1977464-6.patch | 1.19 KB | dawehner |
#2 | drupal-1977464-2.patch | 1.41 KB | dawehner |
bug_step04.jpg | 9.17 KB | zhiqiang.qiu | |
bug_step03.jpg | 13.85 KB | zhiqiang.qiu |
Comments
Comment #1
swentel CreditAttribution: swentel commentedThanks for the report, tagging.
Comment #2
dawehnerI have no idea whether this is a proper fix, but basically field_view_field doesn't work with NG entities at the moment.
Comment #3
dawehner.
Comment #4
swentel CreditAttribution: swentel commentedIs this related to #1974474: Make sure within field_attach_*() that we are working with a BC entity ?
Comment #5
dawehnerThis is certainly related but afaik views does not call field_attach_view. So maybe the other issue should also do this trick on field_view_field as well? Alternative you could just use the approach in the other issue here.
Comment #6
dawehnerLet's directly convert the entity at the top.
Comment #7
tstoecklerIt seems the two hunks are redundant?!
Comment #8
dawehnerGood catch!
Comment #9
swentel CreditAttribution: swentel commentedThis is merged in #1980632: Viewing a node with a List field results in fatal error
Comment #9.0
swentel CreditAttribution: swentel commentedmodify the content