Releases: Namoshek/DataTables.NetStandard
Releases · Namoshek/DataTables.NetStandard
Introduction of Enhanced DataTables, Added Security when Serializing View Models and Drawing Fixes
Full list of changes v0.3.0...v0.4.0
.
It is recommended to have a look at the updated documentation. It explains all the new features and changes in detail.
Additions
- A new parameter
SearchPredicate
has been added toDataTablesColumn
:- Will be used for both, global and column search if no
GlobalSearchPredicate
orColumnSearchPredicate
is given - The priority for the search predicate is now:
GlobalSearchPredicate
/ColumnSearchPredicate
>SearchPredicate
> default predicate based on thePrivatePropertyName
- Will be used for both, global and column search if no
- Adds a new package called
DataTables.NetStandard.Enhanced
with some additional features that extend on the base package:- Individual column search based on the yadcf library
- For now,
TextInputFilter
andSelectFilter
are available out of the box
Changes
- The render process of our DataTables has been adjusted
- The
DataTablesSerializationContractResolver
will now ensure only properties of our view model are serialized and sent to the client if they are listed in theColumns()
definitions of our table (this avoids unwanted data exposure)
Fixes
- The
draw
parameter of DataTables requests is now handled properly and returned back to the user
IDataTable Deprecation, Configuration Fixes and Enhanced DataTables Preview
Additions
- A preview of an enhanced DataTables.NetStandard package is now part of the source but not available over NuGet just yet. It lacks most of the desired functionality but provides a way of generating scripts based of custom
DataTable<TEntity, TEntityViewModel>
implementations for the vedmack/yadcf DataTables column filter library. This allows for easy filter setup in C# code.
Fixes
- The ajax configuration option of the
DataTablesConfiguration
object has been fixed. In order to usePOST
as request method, an object is required instead of a flat hirarchy. The change should not affect existing code but may fix some issues withPOST
request types. [974985a] - The
ParameterReplacerVisitor
had an issue with expressions that contain nested expressions due to their parameters and has been fixed to only replace parameters in the root expression. [de953ef]- What has always been working:
(e, s) => e.Foo.Contains(s)
- What didn't work before the fix:
(e, s) => e.Foos.Any(f => f.Bar.Contains(s))
(i.e. also has-many relations can be searched now)
- What has always been working:
Changes
- The
IDataTable<TEntity, TEntityViewModel>
has been removed as it did not fulfill any purpose. As the package itself does not consumeDataTables
by the user but simply renders them, having an additional interface over an abstract class is unnecessary. To update, simply remove the interface from yourDataTable
implementations.
New Template Mapping Helper Library
In order to clean up the base library, the IViewRenderService
and its implementation the ViewRenderService
were moved to their own new library called DataTables.NetStandard.TemplateMapper
. The README has been updated accordingly.
A new Library is born!
I'm very happy to announce that I finally released my first actual open-source project here on GitHub!
All feedback regarding the new package is highly appreciated. For details regarding usage, please have a look at the README.