Packages Organization

Lib.AspNetCore.Mvc.JqGrid.Core - The core serialization and deserialization functionality. If you prefer to write your own JavaScript instead of using strongly typed helpers, but you still want some support on the server side for requests and responses, this is what you want.

The split was driven mostly by two use cases which have often been raised. One is separating the (view) models from the rest of the application (for example, independent assembly). The only package needed now in such cases is Lib.AspNetCore.Mvc.JqGrid.DataAnnotations which doesn't have any ties to ASP.NET Core. The second use case is not using the JavaScript generation part, just the support in response and request serialization. That functionality has been separated as well in order to minimize footprint for such scenario.

Usage Basics and Demos

The helper in the version for ASP.NET MVC was an independent class which needed to be initialized (typically in the view) and then could be used to generate the JavaScript and HTML (very similar to System.Web.Helpers.WebGrid). This has been changed, the JavaScript and HTML generation is exposed through IHtmlHelper extensions methods (JqGridTableHtml, JqGridPagerHtml, JqGridHtml, and JqGridJavaScript) which take JqGridOptions instances as parameters. This means that view code can be simplified to this (assuming all needed scripts and styles have been referenced):

The JqGridOptions instance can be created anywhere in the application, as it sits in Lib.AspNetCore.Mvc.JqGrid.Infrastructure there is even no reference to ASP.NET Core required. When it comes to the controller code, not much has changed. The Lib.AspNetCore.Mvc.JqGrid.Core provides classes like JqGridRequest, JqGridResponse or JqGridRecord with appropriate binders and converters which are automatically used.

There is a demo project available on GitHub which contains samples of key feature areas with and without helper usage.

Supported Features and a Roadmap

This first version doesn't support all the features which Lib.Web.Mvc did. I've chosen the MVP based on what has been the most common subject for discussions and questions in the past. This gives the following list of areas:

Formatters

Footer

Paging

Dynamic scrolling

Sorting

Single and advanced searching

Form and cell editing

Grouping

Tree grid

Subgrids

This is of course not the end. I will soon start setting a roadmap for subsequent releases. This is something that everybody can have their say on by creating or reacting to issues.

In general, I'm open to any form of feedback (tweets, emails, issues, high fives, donations). I will keep working on this project as long as it will have value for anybody and I'll try to answer any questions.