In Drupal 7, with Panels, you could configure Views arguments to come from Pane context. For example, you could say that a Views argument gets it's value from a field on the Node context:
Drupal 8, it's possible to configure Views arguments to come from Block context, but only contexts that take entities, and the entity id is always passed into the argument - you can't configure the value to come from a field on the entity, for example.
I propose adding a similar configuration to Panopoly 2.x, which allows you to configure the argument value to come from any context type (including plain strings), and allow using tokens to extract sub-values from entities:
Comment | File | Size | Author |
---|---|---|---|
#2 | panopoly_magic-views-block-context-3353820-2.patch | 13.74 KB | dsnopek |
Comments
Comment #2
dsnopekPatch to implement is attached!
It works in my testing. The main thing I don't like about it is having to duplicate so much code from
ViewsBlock::build()
but I don't think there's any way around that.Comment #3
dsnopekEarly reports indicate that this is working! I'm going to be bold and merge :-)