Coming from #1046898: [release blocker] use node.title (resp users.name) in Views argument summaries
(References project, i.e D7 noderef / userref)
The patch over there uses the 'title table' and 'title field' argument properties to display node titles (resp user names) instead of raw nids (resp uids) in argument summaries.
However, the only way I could get the 'title table' ('node' or 'user') correctly in the query (i.e joined as a separate copy from the field data 'referenced nid' column), was by patching views_handler_argument.inc.
Without the patch, the 'title field' ('title' or 'name') is fetched from the base table, which at best is incorrect (for a noderef argument in a View listing nodes, gives the title of the base node instead of the referenced node) and at worst breaks the query (for a userref argument in a View listing nodes, node.name doesn't exist)
Comment | File | Size | Author |
---|---|---|---|
#1 | views_argument_title_table-1059646-1.patch | 649 bytes | yched |
Comments
Comment #1
yched CreditAttribution: yched commentedPatch attached.
I'm definitely not sure whether this is the correct fix or not, feedback welcome !
Comment #2
klonossubscribing...
Comment #3
dawehnerAssign to earl.
This might could be commited to 6.x, too.
Comment #4
klonos...tagging as such then.
Comment #5
merlinofchaos CreditAttribution: merlinofchaos commentedCommitted to both 6.x-3.x and 7.x-3.x
Comment #6
klonosThanx Earl, one less patch to keep track of ;)