Needs review
Project:
Views (for Drupal 7)
Version:
7.x-3.x-dev
Component:
Miscellaneous
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
8 Oct 2015 at 18:28 UTC
Updated:
26 May 2020 at 16:51 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
jojonaloha commentedThe attached patch moves the "Global: Result summary" tokens to
views_plugin_style, handling them with the rest of the tokens intokenize_value(). In order to remove duplicate code, I removed this fromviews_handler_area_result, which is almost unneeded now. In order to not break existing views though, I made it extendviews_handler_area_textsince that already calls the style pluginstokenize_value()method, and set the defaults forviews_handler_area_resultto turn on tokens, which are required now for the summary to work.Comment #3
nwom commentedI tested this against an older stable version and it worked amazingly. I added @total to the title without problems. Thank you very much!
Comment #4
mrsad commentedUpdated patch to latest 7.x-3.x-dev.
Comment #5
ocastle commentedPatch #4 works well for the title.
However changing the extended class to
views_handler_area_textcauses the 'Global: Result Summary' field to usetext_formatinstead oftextarea. This might cause HTML to be stripped from the output until the field format is updated.I don't think this is ideal when trying to support existing views. I've attached a new patch using the original code but just adjusting to run it though token replacement.
Comment #6
Alexey.Samsonov commentedAdapted for latest 3.x-dev
Comment #7
nwom commented#6 no longer applied to the latest dev or stable. Here is a re-roll against the newest dev.