Add 'enclose' and 'isempty' keys to text supplier
A couple of simple ideas to add value to the text supplier in the Reporting Supplier API
* An 'enclose X' key would automatically enclose the text -- IF any is found -- in one of the enclosing characters, namely (), {}, <>, [], etc. The X value would just be the left member of the pair. Unlike other keys (e.g. trim), this would actually augment the text.
* A related key would be 'isempty' which would return a boolean, eliminating the need to use 'text:size > number:equal 0'. One could also add 'iswhite' which would detect if the entire text element was whitespace.
* An 'enclose X' key would automatically enclose the text -- IF any is found -- in one of the enclosing characters, namely (), {}, <>, [], etc. The X value would just be the left member of the pair. Unlike other keys (e.g. trim), this would actually augment the text.
* A related key would be 'isempty' which would return a boolean, eliminating the need to use 'text:size > number:equal 0'. One could also add 'iswhite' which would detect if the entire text element was whitespace.
1
person likes this idea
I like this idea!
Tell me when this idea gets some attention.
The more people who like this idea, the more it gets noticed.
The more people who like this idea, the more it gets noticed.
The company implemented this idea.
-
Inappropriate?They sound like reasonable ideas. Could you please add a feature request and I'll schedule it to get looked at for the next release.
-
Inappropriate?Does anybody have an example of the is empty text supplier? I'd like to use it to see if no value exists for a scaffolding field in a report table.
-
Inappropriate?Hi there,
The feature will be coming in the next release of Reporting. You would use it something like this:
{report-table}
{local-reporter:page:children}
{boolean-filter:data:is empty|value=false}
{local-reporter}
{report-column:title=Page}{report-info:page:title|link=true}
{report-table}
However, if the value is actually 'null', you may get unpredictable results, since the 'is empty' key will not actually get called unless the string exists.
Loading Profile...



EMPLOYEE