Skip to main content

This content has been archived and is no longer being updated. Links may not function; however, this content may be relevant to outdated versions of the product.

Support Article

Specified format is not working in Summary View

SA-23734

Summary



User's requirement is to display property in specified format(Date-Calendar) in Summary view, but it is always taking default GMT format instead of the specified format.

Error Messages

Not Applicable.

Steps to Reproduce



1. Create a Summary view.
2. Specify the format as "date-calendar" for a date-time property.
3. Run the report and observe the datetime property format.


Root Cause



A defect in Pegasystems’ code or rules.

if(thisRef().hasValidValue()) condition is not returning true for any value or property type(date/time/datetime), due to which it always goes to else block with statement as [else saveValueSet("result", thisValue());], returning the value as it is.
 

Resolution



Perform the following local-change: 

Create a new format and set the desired format for datetime value and Property type is set to blank.

​Example:


{JAVA}
if (thisValue().length() > 0 )  // removed check for thisRef().hasValidValue()
{         
         saveValueSet("result",
              PRDateFormat.format(tools.getParamValue("localeEntered"), "GMT",
                 "MMM dd, yyyy HH:MM:ss a", PRDateFormat.parseAsDateTime("","",null,thisValue()))); 
         
}
else saveValueSet("result", thisValue());
{/JAVA}
{when $mode-show}
    {$save(result)}
{else}
<SPAN nowrap>
    {include Messages}
    <input type=text value="{$save(result)}" id="{$this-Definition(pyPropertyName)}{% tools.getParamValue("pega_RLindex") %}" >
</SPAN>
{end}

Published May 30, 2016 - Updated October 8, 2020

Was this useful?

0% found this useful

Have a question? Get answers now.

Visit the Collaboration Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega Community has detected you are using a browser which may prevent you from experiencing the site as intended. To improve your experience, please update your browser.

Close Deprecation Notice
Contact us