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.
Just wanted to enable taxonomy filter with hierarchy and got the error:
An AJAX HTTP error occurred.
HTTP Result Code: 200
Debugging information follows.
Path: /d8/admin/structure/views/ajax/config-item/frontpage/page_1/filter/tid
StatusText: OK
ResponseText: Fatal error: Class 'Drupal\taxonomy\Plugin\views\filter\stdClass' not found in /home/www/drupal/core/modules/taxonomy/lib/Drupal/taxonomy/Plugin/views/filter/TaxonomyIndexTid.php on line 146
Comment | File | Size | Author |
---|---|---|---|
#9 | vdc-1823204-PASS.patch | 8.36 KB | dawehner |
#9 | vdc-1823204-FAIL.patch | 7.63 KB | dawehner |
#4 | 1823204-4.patch | 748 bytes | damiankloip |
#2 | quickfix-1823204-2.patch | 1.03 KB | Chi |
#1 | quickfix-1823204-0.patch | 739 bytes | Chi |
Comments
Comment #1
Chi CreditAttribution: Chi commentedIn namespaced code stdClass can't be used directly.
See: #1614186: Coding standards for using "native" PHP classes like stdClass in namespaced code
Comment #2
Chi CreditAttribution: Chi commentedAlso wondering why do we need to use stdClass here. It's not documented in Form API.
Comment #3
dawehnerThe point here is to leverage the hierachy, ... that's what the stdclass was used for.
Comment #4
damiankloip CreditAttribution: damiankloip commentedYeah, I guess really we want the fix to just be this.
Comment #6
dawehnerPerfect, now just someone has to step up and write tests. Good luck :)
Comment #7
dawehnerPerfect, now just someone has to step up and write tests. Good luck :)
Comment #8
dawehner#4: 1823204-4.patch queued for re-testing.
Comment #9
dawehnerHere are some tests for the UI.
Comment #11
dawehnerBack to needs review.
Comment #12
Chi CreditAttribution: Chi commentedIt works for me.
Comment #13
alexpottCommitted a16c164 and pushed to 8.x. Thanks!