Need a special offer?Find out if your project fits.
+

Why slice filter not work with componentFolder node_modules?

Answered
pvaritta asked on November 28, 2018

My question is why the report slice is not work as this link -->  http://jsfiddle.net/flexmonster/a2mguf82/    when I ues componetFolder="node_modules/flexmonster/" (I copy flexmonster folder from the trail version then paste to node_muldes folder).
         I have try to use filter:{} but I show as default that I'm not expect. If I use componentFolder="https://cdn.flexmonster.com/", it works correctly. What am I doing wrong?

Thank you.

5 answers

Public
Tanya Gryshko Tanya Gryshko Flexmonster November 28, 2018

Hello, Varitta,
Thank you for writing to us.
We have tested and weren't able to reproduce the issue on our side. The report slice seems to be working as expected regardless of the componentFolder value. We kindly ask to provide more details and to share your config file.
You mentioned using filter:{} which resulted in showing the default (all members are shown). We would like to inform you that such behavior is normal. The filter object specifies which filter is applied. Setting it to {} means no filters are applied.
Please let me know in case of additional questions.
Regards,
Tanya

Public
pvaritta November 28, 2018

Here's my config code: 
 Is anything wrong?

slice: {
rows: [
{
uniqueName: 'Event Type',
filter: {
members: ['type'],
},
sort: 'desc',
},
{
uniqueName: 'Currency',
filter: {
members: ['currency'],
},
sort: 'desc',
},
],
columns: [
{
uniqueName: 'Box',
filter: {
members: ['box'],
},
},
],
measures: [{ uniqueName: 'total' }],
},
};
Public
Tanya Gryshko Tanya Gryshko Flexmonster November 28, 2018

Varitta,
Thanks for a quick update.
Each hierarchy’s member needs to contain the unique name of this hierarchy. For example, you have a hierarchy with uniqueName: "Event Type" and it has two members: "type1" and "type2". If you want to show only "type1", it can be done the following way:

{
uniqueName: "Event Type",
filter: {
members: ["event type.[type1]"],
},
sort: "desc",
}

Please pay attention to how "type1" is specified in this example.
Hope it helps.
Regards,
Tanya

Public
pvaritta November 30, 2018

Hi, 
The screenshot below is my config file of package.json which is in flexmonster folder. Do I need change anything else? For license I put the license that I get from the email.
 
Regards,
Varitta.
 

Attachments:
package.PNG

Public
Tanya Gryshko Tanya Gryshko Flexmonster November 30, 2018

Hello, Varitta,
Thank you for your reply.
Please note that the main configs are set in the place where Flexmonster() API call is used to add the component. The license that you've got from the email also has to be specified as a licenseKey parameter inside Flexmonster() API call. Please refer to our Quick start guide to see the examples.
In case you have further questions, please let me know.
Regards,
Tanya

Please login or Register to Submit Answer