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

Getting field property under the drill-through view

Answered
Sergii Valko asked on May 20, 2020

Hello, during implementation of clickable cells functionality there is a need to get a value of field property(type='property'). But under drill-through view, it seems unreachable. The main goal is that in generated URL as value should be placed some property(e.g. userId) instead of member caption(e.g. userName), but at the same time a hyperlink caption should be user friendly(e.g. userName). At the pivot table, it works perfectly and was achieved through 'customizeCell()' function. How to do the same under drill-through view? In other words, how to derive property of field under drill-through view. Thank you in advance.

6 answers

Public
Illia Yatsyshyn Illia Yatsyshyn Flexmonster May 21, 2020

Hello,
 
Thank you for reaching out to us.
 
Our team would like to kindly explain that the field marked as a property is associated with an exact member of the hierarchy. Being opened in the drill-through, cells are not considered members; therefore, their Cell Data object does not contain information about properties.
 
Our recommendation is to pass URL separately from the main data set and apply formatting using custom logic. The name of the member can be used as an identifier. Please see an example demonstrating such an approach.
 
The object urlList is used as a storage for links. The customizeCell function uses the name of the scanned member in order to retrieve the matching URL from the object.
 
We sure hope it works for your case.
Do not hesitate to contact us in case additional questions occur.
 
Kind regards,
Illia

Public
Sergii Valko June 9, 2020

Thank you for the response. Unfortunately, cell's caption can be not unique(e.g. user full name - namesake). Now I understood why properties are not reachable under the drill-through view, but it seems 'recordId' ("type": "id") should be. Under compact view 'recordId' is always null and under drill-through view instead of the label id value is showing for some reason, but field 'recordId' is still null. Probably I've made some mistakes. Please have a look. Thank you in advance.

Public
Gennady Gandelman June 11, 2020

Hey Flexmonster Team,

Can you help us with this? We want our users to be able to navigate to a destination right from the drill-through. This is going to make a huge difference for their productivity as otherwise they will have to switch to flat layout and locate the record there. It may not sound like a lot but that's going to slow them down significantly.

Thank you

Public
Illia Yatsyshyn Illia Yatsyshyn Flexmonster June 11, 2020

Hello, Sergii,
 
Thank you for your feedback.
 
Our team would like to explain that there is no need to specify the hierarchy property in case the field's type is id. The structure used in the provided example is applicable only to the property data type.
 
After removing the hierarchy property, the recordId property will be available in the drill-through. The identifier itself can be retrieved using the following line of code: data.recordId. Please note that the value of such property will be an array in case the pivot form (compact or classic) is used and a single number if the drill-through or the flat form is opened.
 
The availability of such property allows choosing an appropriate link for every single member with a unique identifier.
We have modified an example you have provided so that every record has its unique identifier. The link is chosen for every record based on its id. For example, each odd id means the link will be opened in English, and each even one means the link will be opened in the official language of the country.
 
Please let us know if it works for your case.
We are looking forward to hearing from you.
 
Regards,
Illia

Public
Illia Yatsyshyn Illia Yatsyshyn Flexmonster June 11, 2020

Hello, Gennady,
 
In order to embed links to the drill-through view and give users the possibility to navigate through them, our team recommends checking out approaches discussed within the current thread.
 
Please let us know if any questions appear.
 
Regards,
Illia

Public
Gennady Gandelman June 11, 2020

Hi Illia,
 
Thank you for your response.
 
Best

Please login or Register to Submit Answer