# Enhancement request: localize filer captions for report definitions

**URL:** <https://forums.pega.com/t/enhancement-request-localize-filer-captions-for-report-definitions/3136>\
**Category:** User Experience\
**Tags:** 8-3, consumer-services, reporting, user-experience, system-architect\
**Created:** [August 23, 2022, 12:26pm UTC](https://forums.pega.com/t/enhancement-request-localize-filer-captions-for-report-definitions/3136 "2022-08-23T12:26:26Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![BasRulesMatter](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/basrulesmatter/32/23021_2.png) [@BasRulesMatter](https://forums.pega.com/u/BasRulesMatter)\
**Post date:** [August 23, 2022, 12:26pm UTC](https://forums.pega.com/t/enhancement-request-localize-filer-captions-for-report-definitions/3136/1 "2022-08-23T12:26:26Z")

</div>

In report definitions, we can add a caption to a filter. However, the caption is currently not localized in all places where we expect it to:

 ![Filter caption design time configuration.png](https://pega1.discourse-cdn.com/pega/original/2X/9/9f4389658cb82747649c23ac6b4f1d1cc533ac36.png)

If we edit the filter, the filter caption is showing the property value and not the localized value:

 ![Applied filter.png](https://pega1.discourse-cdn.com/pega/original/2X/a/a753632817bda9f996009cb7f7f36fca88f92b76.png)

To us, it would be better if this was translated

---

<div class="post-metadata">

**Author:** ![m.caldag](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/m.caldag/32/2328_2.png) [@m.caldag](https://forums.pega.com/u/m.caldag)\
**Post date:** [August 24, 2022, 3:06pm UTC](https://forums.pega.com/t/enhancement-request-localize-filer-captions-for-report-definitions/3136/2 "2022-08-24T15:06:07Z")

</div>

Dear @BasG0629,

I’ve analyzed your problem statement and generated a solution. Kindly try it and let me know the result whether it works or not.

First of all, I predicted your scenario that you created a _Period_ field value rule under _Code-Pega-List_ class for the _pyCaption_ field with the _To_ value of _Periode_ and execute the particular report definition rule either from the Case Manager Dashboard specifically Reports navigation rule item or directly from Designer Studio in order to test it.

Field value you created reflected to “Filter by: ” header part of the rendered UI. Because, this part is under Code-Pega-List class context and the value is set by tools.getLocalizedTextForString function getting from pyCaption field’s value. You may check _RRFilters\_Logic_ control rule in case you are willing to dive into more details.

When end user clicks the link of the filter, pop up which allows end user to edit filter details rendered on the UI and it is under different class context so that your field value is not reflected on there. Kindly follow the steps below in order to provide a solution.

**1.** Save as your field value rule to _Embed-ReportFilter_ class for the _pyFilterUICaption_ field.

**2.** We are going to apply a slight change on rule whose availability is configured as final and connected with Pega-Reporting ruleset. In case pega platform is not allowing you to save as this rule to your ruleset by applying some validation, kindly private edit _CheckAvailability_ activity rule and comment out first step and if another validation thrown after saving CheckAvailability activity rule, un check “Allow invocation from browser” and save it. After lifting those blockers now it is time for saving as CL: _Embed-ReportFilter_ ID: _pzEditSingleFilter_ section rule to your ruleset.

**3.** After you take the pzEditSingleFilter section rule in your ruleset and checkout, click gear icon of Filter Caption text input then click Change link in order to change control by clicking Custom → Other and choose GetLocalizedValue control eventually submit and check in the rule.

 ![Filter Caption.png](https://pega1.discourse-cdn.com/pega/original/2X/2/2b66abe80cbb246157795e03fb009b1cdfbcca53.png)

![image.gif](https://pega1.discourse-cdn.com/pega/original/2X/3/30cb5d44e276505b1d4c053c8b25525da228db30.gif)​

1. Test your changes.

---

<div class="post-metadata">

**Author:** ![BasRulesMatter](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/basrulesmatter/32/23021_2.png) [@BasRulesMatter](https://forums.pega.com/u/BasRulesMatter)\
**Post date:** [August 29, 2022, 5:31am UTC](https://forums.pega.com/t/enhancement-request-localize-filer-captions-for-report-definitions/3136/3 "2022-08-29T05:31:12Z")

</div>

@m.caldag Hi caldag,

I had a pyCaption in @baseclass for Period, but let’s give this solution a go! Thanks for the extensive analysis, it would be great if this worked so we can prevent creating not dynamic field values.

Kind regards,  
Bas

---

<div class="post-metadata">

**Author:** ![m.caldag](https://yyz2.discourse-cdn.com/pega/user_avatar/forums.pega.com/m.caldag/32/2328_2.png) [@m.caldag](https://forums.pega.com/u/m.caldag)\
**Post date:** [August 29, 2022, 12:59pm UTC](https://forums.pega.com/t/enhancement-request-localize-filer-captions-for-report-definitions/3136/4 "2022-08-29T12:59:07Z")

</div>

Hi @BasG0629, you are welcome.

“_I had a pyCaption in @baseclass for Period_”

\*-\*Okay that’s fine as well. Field value you created reflected to “Filter by: ” because Code-Pega-List class’ inheritance ( **@baseClass** -Code-Pega-List). Field value rule is going to be picked from @baseClass. We can also have this field value directly under pxObjClass of page’s extended (top level) classes to be able to increase the range and reusability just like you did it by applying FV under @baseClass.

-Similarly, if you save as your field value for _pyFilterUICaption_ under @_baseClass_, field value will reflect to edit filter pop up’s Filter Caption field part as well because of the Embed-ReportFilter class’ inheritance ( **@baseClass** -Embed-…)

I decided to keep _pyFilterUICaption_ field’s value directly under Embed-ReportFilter class because I only wanted to reflect my field value to page context whose pxObjClass value is Embed-ReportFilter only to not affect other parts. We can keep it under @baseclass to affect everywhere in case value always constant like Periode.

Regards.

Mert.
