Hello,
After my last support ticket, I have implemented a custom data server solution for my project based on your example from here:
https://www.flexmonster.com/doc/pivot-table-with-dot-net-core-server/
https://www.flexmonster.com/doc/introduction-to-custom-data-source-api/
https://github.com/flexmonster/api-data-source
Till now everything worked fine, although I had to adjust some parts of your code in order to pass necessary data needed for my custom data source to work properly (but nothing out of ordinary). Recently I encountered an issue when trying to filter the data inside the columns, it fails and does not really throw any significant exceptions during code execution, but only while parsing the data for 'select' http request (my guess based on what I have found). The only meaningful error message I could get is from scanning the network traffic and here's what I got:
At first I thought it might have been related to some kind of data value parsing, but after trying to filter out plain 'string' values I also got errors like these:
Error converting value \"Account 100\" to type 'OCT.Flexmonster.Models.ValueObject'. Path 'query.filter[0].exclude[1].member', line 1, position 426."
The filtering I'm taking about is simply executed by the UI (I've included some screenshots in the attachments).
To help you out narrowing down and debugging my problem, I've included every parts of the code that could be relevant to you (see the attachments for 'code.zip). Here I included my custom data source / server implementation on the net backend side as well as angular component with everything set up (some parts may be missing, but you should be able to get the whole context of my use case).
Any help will be appreciated.
Best regards,
Hello, Gerd,
Thank you for reaching out to us.
Our team is currently working on your question. We will get back to you soon.
Kind regards,
Nadia
Hello, Gerd,
Thank you for giving us some time and providing the detailed information.
We have looked through the files provided in the net_custom_data_serverfolder
from your ZIP. We don't see the ValuesJsonConverter.cs
file in the JsonConverters
directory. It is responsible for converting the ValueObject
object to JSON depending on its type. Without it, the server could not parse requests with filters and hierarchies.
As far as the described error mentions converting types, we suppose that it is caused by the absence of ValuesJsonConverter.cs
. Do you use it in your project?
Looking forward to hearing from you.
Kind regards,
Nadia
Hello Nadia,
Yes you are right, it was in fact a missing ValuesJsonConverter.cs, although I had to adjust your implementation to fit our current json handler (from System.Text.Json to Newtonsoft.Json). Thanks for the help and fast response.
Best regards
Hello, Gerd,
Thank you for your feedback.
We are happy to hear that it works for you.
As always, feel free to contact us if other questions arise.
Kind regards,
Nadia