Get Free Trial

Date formatting into drill through

Sergii Valko asked on July 5, 2019

Hello! I have a simple requirement to have one date format anywhere, but I also need to use collapse feature and filter in the context of date. So I’ve selected data type for date – ‘year/month/day’ and it work perfect with exception detailed view. There the date is in some pattern like ‘yyyy/mmmm/dd’, but i need to ‘MM/dd/yyyy’. Please have a look(

1 answer

Vera Didenko Vera Didenko Flexmonster July 8, 2019

Hello, Sergii,
Thank you for your question.
Our team suggests using customizeCell to achieve the desired output of date values in the drill-through pop-up window, for example:
1) Specify the customizeCell property:

customizeCell: customizeDrillThrough

2) Provide implementation:

function customizeDrillThrough(cell, data){

   if (data.isDrillThrough && data.type != "header" && data.hierarchy && data.hierarchy.uniqueName == "date") {
    var partsOfDate = data.label.split("/");
    var day = partsOfDate.pop();
    var month = partsOfDate.pop();
    cell.text = partsOfDate.join("/");  


Here is a JSFiddle example for illustration.
Also, we would like to point out that the datePattern parameter is used for defining the format for only date string date fields (type: "date string" in JSON, ds+ prefix in CSV).
This is why the date values don’t get affected by the datePattern parameter.
For more information about the datePattern parameter please see
You are welcome to contact us in case any questions arise.
Best Regards,

Please login or Register to Submit Answer