Author Topic: How can we add quarter header as in Q-YYYY format for a Pivot Grid?  (Read 1794 times)

EPM Solutions

  • Pro Ultimate
  • Full Member
  • *
  • Posts: 182
    • View Profile
Hello Team,

Our requirement is to add Quarter Display header like Q-YYYY : Q1-2017, Q2-2017, Q3-2017, Q1-2018,Q2-2018 etc. for a Pivot grid.

We tried to add it. But it is not working as required. We added an plnkr URL(below) and Screenshot-

Plnkr URL(Issue):
https://next.plnkr.co/edit/a3Uc5jIHbloGsQ7c?preview/

When we are using year as in reverse order (like YYYY-Q- 2017-Q1, 2017-Q2, 2018-Q1, 2018-Q2) then it is working fine (in Plnkr below).

Plnkr URL(year as reverse order):
https://next.plnkr.co/edit/L1XRX56cb2GuhpFK?preview

Please tell me that how can we implement quarter as Q-YYYY.

paramvir

  • Administrator
  • Hero Member
  • *****
  • Posts: 6310
    • View Profile
Re: How can we add quarter header as in Q-YYYY format for a Pivot Grid?
« Reply #1 on: October 01, 2019, 10:40:40 pm »
you can add format to the Quarter column

Code: [Select]
format: function(val){
     return val.split("-").reverse().join("-")
},

https://next.plnkr.co/edit/VSbCxgRepMsSDt2E