In my Application Module i would like to configure the JsonIgnoreCondition. I did take a look at https://docs.abp.io/en/abp/latest/JSON I used AbpSystemTextJsonSerializerOptions, what did not work as expected.
I use this code in my Application Module:
I am not sure this is a bug or i am missing something ? I would expect after reading the documentation that the first way should work.
I had some trouble here to paste the code from above. all strings between the square brackets are deleted : this becomes: options.AddMaps(), (a bug here in the editor ?)
If you're creating a bug/problem report, please include followings:
We generated our base code with abp suite. It does generate in every entity repository a IQueryable<T> ApplyFilter Function. Asume that you have over 100.000 Entries for an entity.
a) We would like to have the ability to get only a few selected items (as List<Guid>) from the database. So similar to filterText we want to add a parameter filterIds to be able to get only these Ids as result.
Normally you would provide for every Entity like Car something like this:
public static class QueryableExtensions
{
public static IQueryable<Car> IncludeFilterIds(
this IQueryable<Car> queryable,
List<Guid> filterIds = null)
{
if (!filterIds.IsNullOrEmpty())
{
return queryable
.WhereIf(!filterIds.IsNullOrEmpty(), e => filterIds.Contains(e.Id));
}
return queryable;
}
}
I would like to have this ability for every entity, so i tried;
public static class QueryableExtensions
{
public static IQueryable<IEntity<Guid>> IncludeFilterIds(
this IQueryable<IEntity<Guid>> queryable,
List<Guid> filterIds = null)
{
if (!filterIds.IsNullOrEmpty())
{
return queryable
.WhereIf(!filterIds.IsNullOrEmpty(), e => filterIds.Contains(e.Id));
}
return queryable;
}
I did call it with:
var query = ApplyFilter((await GetQueryableAsync()), filterText, filterIds, name, description);
query = (IQueryable<Car>) query.IncludeFilterIds(filterIds);
But this wont work as expected.causing a casting exception. Of course i can us instead of "IEntity<Guid>" "dynamic" as type, but then i wont have the Id Field, and will need to get it per reflection.
What is here the best approach ? In your examples at https://docs.abp.io/en/abp/latest/Repositories you implement the IQueryable Logic at Application Level. Is this suggested instead of Entity Framework Level ?
b) I further would like to limit the properties in a generic way. Sometimes you need only one field like Id instead the whole table. ( so instead select * from db , i would use select id from db) For a known data type i could expand above solution with:
return queryable
.WhereIf(!filterIds.IsNullOrEmpty(), e => filterIds.Contains(e.Id));
.Select(p => new { p.Id });
But again if i want to do it an an generic way , i will first need to implement a parameter like List<string> proplist and then add it to the query without knowing the datatype. Do you got an idea howto achieve that ?
I think both functionaltities can be used everywhere..
Hope, you could help.,
Hi ABP Support,
1)
i find it hard to use your forum and find relevant posts.
You should at least provide a Link like the other above in the forum Howto search here.... It would be great if you could find a better way for use... like Github or whateveer forum..
2) I find it not suitable that there is no FeedBack Portal for the commcercial Part of ABP like here for Example : https://www.syncfusion.com/feedback I would like to post in such a forum especially Feature Requests for all your modules, for abp suite for example. You could see which feature Request gains the mosts Interest and we could follow better that requests. I did try posting such requests in the past in github, but it seems not to work good for me..
I wrote this here and opened a ticket because coudn't find better informations from you.. This is not customer oriented. I hope you are interested in our input as customer how to get things better here for us.
I am using a Syncfusion Component similar to the ABP FileManager for handling large Files Upload. We use it because it supports asynchron chunk uploads,what is necessary for us. large Files means files bigger than 30mb up to 50GB like Windows OS Isos or a virtual disk.
Our Project was created with ABP 4.3.2 and that upload parts runs without problems. I tested an an windows 10 machine with visual studio (without any antivirus /windows defender deactivated for repo folder)
I did prepare a working sample for you. Just contact me per Mail and i provide you the link.
With ABP 4.3.2 we get this:
With ABP 4.4.2 we get an error at the FileManagerController.cs (Line 173). Check this after you get the code.
So please check the reason for that issue.
Besides that technical problem, i would like to know:
I hope you answer all my questions. and we fix that problem soon.