Dear visitor, despite the COVID-19 outbreak, our team continues operating at full speed.

Also, here is the form where you can apply for a special discount and we will contact you with possible options. Stay safe and continue achieving your business goals.

Fill the form
Get Free Trial
Get Free Trial

Prevent drill through on doubleclick in some cells

Answered
William Silveira asked on December 19, 2019

Hello Guys, 
We have permissions and some users cant open drill through on some cells.
I had use the code below for contextMenu

function customizeFlexmonsterContextMenu(items, data, viewType) {
if (data.type == "value")
{
if (inArray('S', data.recordId))
{
items.shift();
}
}
return items;
}

So… for use the same thing on celldoubleclick method but doesnt work, still open the drill.

flexmonster.on('celldoubleclick', function (cell) {
if (cell.type == "value")
{
if (inArray('S', cell.recordId))
{
console.log("S");
return false;
}
}
return true;
});

5 answers

Public
Illia Yatsyshyn Illia Yatsyshyn Flexmonster December 19, 2019

Hello, William,
 
Thank you for reaching out to us.
 
We would like to kindly inform you that for now, there is no possibility to disable the drill-through view for specific measures.
 
The drill-through feature can be enabled or disabled for all cells at a time using the drillThrough property of an options object. Setting the named property to false allows disabling the feature both through the context menu and a double click.
 
More information about the options object and its properties: Options Object.
 
Please contact us in case of additional questions.
 
Regards,
Illia

Public
William Silveira December 19, 2019

I saw many people asking for this, theres no way to put something like “status” thats cell is clickable or not?

Public
Illia Yatsyshyn Illia Yatsyshyn Flexmonster December 19, 2019

Hello, William,
 
Thank you for your feedback.
 
The current version of Flexmonster does not provide such functionality.
 
For now, we would like to kindly recommend using an approach described in the following thread: https://www.flexmonster.com/question/drillthrough-for-specific-cells/.
 
Please contact us in case any additional questions arise.
 
Regards,
Illia

Public
William Silveira December 20, 2019

It works for me. Hehehehe

flexmonster.on('celldoubleclick', function (cell) {
if (cell.type == "value")
{
if (inArray('S', cell.recordId))
{
$("#fm-drillthrough-view").hide();
$(".fm-ui-modal-overlay").hide();
return false;
}
else
{
$("#fm-drillthrough-view").show();
return true;
}
}
});
Public
Illia Yatsyshyn Illia Yatsyshyn Flexmonster December 23, 2019

Hello, William,
 
We are happy to hear that a workaround for your case has been found.
 
You are welcome to contact us in case additional questions occur.
 
Best regards,
Illia

Please login or Register to Submit Answer