jqGrid is a popular jQuery Plugin for displaying and editing data in tabular form. It has some other more sophisticated features, like subgrids, TreeGrids, grouping and so on.
jqGrid was developed originally by Tony Tomov and it was available under MIT/GPL-licenses till the version 4.7.0 published Dec 8, 2014 (see here). Short time after that the license agreement was changed (see here) and new 4.7.1 version was published.
The code from the GitHib repository is the fork of jqGrid 4.7.0 - the latest version available under MIT/GPL-licenses. It will be provided under MIT/GPL-licenses.
Below you can find short description of new features and the bug fixes implemented in free jqGrid 4.14.0 (compared with version 4.13.6). The version is developed by Oleg Kiriljuk, alias Oleg on the stackoverflow and OlegK on trirand forum.
Read Wiki for more detailed information about the features of free-jqGrid. The preliminary version of the documentation can be found here.
Free jqGrid can be used for free. We still ask to contribute the development by donating via PayPal, if one have the possibility for it. One can donate by clicking on the following button or by sending money via PayPal to [email protected] with the comment "free jqGrid". Bank transfer based on the invoice from OK soft GmbH is another option of donating. Just send the email with the information about the amount of donation and you will get the corresponding invoice with the full information about our bank account and our VAT number.
One can install the package with respect of npm by using "npm install free-jqgrid", with respect of bower by using "bower install free-jqgrid" or from NuGet by using "Install-Package free-jqGrid".
The package is published on WebJars too and it's deployed to Maven Central.
Free jqGrid is is available from jsDelivr CDN and cdnjs. Thus one can use it directly from Internet by including for example the URLs like
<link rel="stylesheet" href="https://cdn.jsdelivr.net/free-jqgrid/4.14.0/css/ui.jqgrid.min.css">
<script src="https://cdn.jsdelivr.net/free-jqgrid/4.14.0/js/jquery.jqgrid.min.js"></script>or
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/free-jqgrid/4.14.0/css/ui.jqgrid.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/free-jqgrid/4.14.0/jquery.jqgrid.min.js"></script>The locale file is optional. One can, but one don't need to include grid.locale-en.min.js, because the same information is already included in the jquery.jqgrid.min.js (or jquery.jqgrid.src.js).
If somebody want to test the latest version of free jqGrid, one can load it directly from GitHib using RawGit service:
<link rel="stylesheet" href="https://rawgit.com/free-jqgrid/jqGrid/master/css/ui.jqgrid.css">
<script src="https://rawgit.com/free-jqgrid/jqGrid/master/js/jquery.jqgrid.src.js"></script>All other language files and plugins are available from CDN too. See the wiki article for more details about the usage of free jqGrid from CDNs and RawGit.
Remark: the above URLs will be available after publishing the release of the version of 4.14.0.
- New Boolean property
createColumnIndex: trueincolModelorgenerateValue: trueofsearchoptionsoreditoptionscan be used in combination withstype: "select"oredittype: "select". The idea of the new feature come from the old answer. jqGrid can "look through" all values in the column and fill the list of unique value, sort the values and to generate the array of the resulting strings (see the new methodgetUniqueValueFromColumnIndex). Additionally, jqGrid can generatevalueproperty ofsearchoptions/editoptions, which can be used bystype: "select". The simplest usage of the new feature consist in adding ofstype: "select", searchoptions: { generateValue: true, noFilterText: "Any" }properties to any column. The demo https://jsfiddle.net/OlegKi/yvbt6w54/ shows the usage of the new feature. It generates the options of<select>dynamically (the column "tax"). Other columns ("name" and "ship_via") uses jQuery UI Autocomplete and select2 with dynamically generated options. getRowData,getCell,getColandgetDataFieldOfCellmethods work now with cells/rows, which could be in editing mode (inline editing or cell editing). It solves the old problem. I hope that the new changes allow to simplify the usage of jqGrid.- Add first support of Bootstrap v4 (tested with 4.0.0-alpha.6). The option
guiStyle: "bootstrap4"can be used now instead ofguiStyle: "bootstrap"to use jqGrid with Bootstrap v4. Of cause, one have to replace the CSS of Bootstrap 3 to the CSS of Bootstrap 4. - The folder
tsof free jqGrid incudesfree-jqgrid.d.tsfile with TypeScript type declaration of jqGrid methods, optons and events. The file is created manually. The information could contain some typing errors. Nevertheless. it provides many information, which could be helpful. Some text editors, like free Visual Studio Code, available for Widows, Linux and macOS, can use the type information for IntelliSense. IntelliSense can essental speep up writing of the code and it can be used as context sesitive documentation of free jqGrid options, methods and events. - Free jqGrid supports now editing of rowids in inline editing mode. If one have, for exmple, the column
id(or with the name, which corresponds tha value ofjsonReader.id) or some other column, which haskey: trueproperty, and the column is editable, then the value of rowid should be the same as the value from the cells of the column. Free jqGrid detect now the changes in the column in inline editing mode and changes the rowid after saving the modifications. The new methodchangeRowidcan be used to apply the chanhes of rowid manually. Additionally, jqGrid sends in the case of changing of rowid the value of rowid before the modification as"idOld"property. The name of the property can be changed usingidoldproperty ofprmNames. For example,prmNames: { idold: "orgId"}options renames"idOld"property to"orgId". - New
saveRowValidationcallback is added to inline editing for the final validation of all decoded data. The problem is that the classic validation viaeditrulesallows to validate a value in the cell, but it dosen't allow to validate relation between the columns. The newsaveRowValidationcallback will be called after all individual fields are processed. Theoptionsparameter of the callback containssavedRow,newDataand some other properties, which can be helpful to make the final validation of the changes. See the answer and the comment to the commit for more details. - New
sortIconNamecallback as the property incolModelor as the option of jqGrid simplifies building of custom sorting icons. The demo https://jsfiddle.net/OlegKi/ffgg9wdu/ provides an example of the the usage of thesortIconNamecallback.
- Move
*.cssand*.min.jsfiles of plugins in subfolderscssandmin. The changes simplifie the usage of jqGrid with SystemJS. One could need to adjust the paths in existing projects. - The module names used in free jqGrid are now the following: "free-jqgrid", "free-jqgrid-plugins", "jquery", "jquery-ui". One should uses paths mapping to map the module identifier to the real path. The demo is an example of the usage SystemJS for loading free jqGrid 4.14.0 modules together with jQuery UI 1.11.4 modules. Another demo uses jQuery UI 1.12.1 modules instead. Probably more typical is loading the whole jQuery UI as one file from CDN like in the next demo. The same works of cause with RequireJS. See the corresponding demo.
- Add support of
customUnaryOperationsoption to specify the names ofcustomUnaryOperationsoperation which required no data (like"nu"and"nn"). See comment to the commit and the answer for more details. - Small Bug fixes in
jqPivotto allow non-string values be used in aggregators - New
sortIconNameproperty of colModel or as grid option to simplify building of custom sorting icons - Bug fix the problem with setting attributes on
<select>, which be built viadataUrl - Add
saveRowValidationcallback to inline editing to final validation of all decoded data. The usage ofsaveRowValidationcan be changed before publishing of new version. The later changes will allow to return error message, which jqGrid will display to the user. - Add first support of Bootstrap v4. The option
guiStyle: "bootstrap4"can be used now instead ofguiStyle: "bootstrap"to use jqGrid with Bootstrap v4 (tested with 4.0.0-alpha.6) instead of Bootstrap 3.x. - Allow to use callback function as the value of the property
labelof the optionyDimensionof the methodjqPivot - Fixing in cell editing: the
namepropertyof theeditablecallback is changed tocmNameto have the same names in all editing modes - DefinitelyTyped file
free-jqgrid.d.tswith the type definitions for TypeScript - Bug fixes in the form Delete: remove unneeded
style='white-space:pre;'inline style, makereloadAfterSubmit: trueworking with local grid. The fix is required inloadonce: truescenario if one usesformDeleting: { reloadGridOptions: { fromServer: true } } - Bug fix in processing custom buttons in
info_dialog - Bug fixes of CSS for
nav-buttonwith the text - Use CSS classes
ui-jqgrid-pg-left,ui-jqgrid-pg-center,ui-jqgrid-pg-rightto style the pager parts - Bug fix in testing for empty
ExpandColumnoption - Add parameters to
addfunc,editfunc,viewfunc,delfunclike it exist already forsearchfunc - Bug fix of
footerDatametod in case of usage with"get"parameter - Extend the option of
onShowHideColwith the options ofshowHideColmethod - Small changes in
saveRowandeditRow:rowidandoptionsparameters are added tosuccessfunclike is was already before for the eventjqGridInlineSuccessSaveRow. - Move some part of subgrid initializing from the base module into the subgrid module
- Add new method
changeRowid, which simplifys changing of rowid in the grid - Add
afterChangeRowidcallback andjqGridAfterChangeRowidevent - Modify
saveRowto use newchangeRowidmethod - Add
defaultValue: falseto default checkboxformatoptions - Add new
useDefaultValuesOnGrouping: trueoption ofgroupingView - Use
formatoptions.defaultValueduring grouping if formatter is specified. One can change the behavior to old behavior by usaginguseDefaultValuesOnGrouping: falseingroupingViewoption. - Move testing for the existence of
$.fn.sortablefrom base module intosortableColumnsmethod ofgrid.jqueryui.jsto better separate modules - Remove some unused code from
$.jgrid.from - Improvements in the old code of
addChildNode - Bug fix of the options of afterChange callback of Searching Dialog, removing some unused parameters and some other minor fixes
- Add new
idold: "idOld"property inprmNames, which will be used in inline editing on id changing and remoteediturl - Send additional parameter
idOldto the server in case of id changes - Set
thisin theafterClearcallback - Bug fix in usage of
skipSortByXoption of the method jqPivot - Add initial support of boolean
searchoptions.generateValueproperty ofstype: "select" - Add new
inFilterSeparatorparameter, which will be used in multiple select and in "in" operation - Filling of
indexByColumnDataparameter after column templates are expanded - Add new
resetWidthOrgproperty ofautoResizingproperty ofcolModel - Filling of
indexByColumnDataparameter after column templates are expanded - Add id and item properties in the editable callback
- Some changes in at the begining of the files: AMD/Node/CommonJS module loading
- Small fix: use empty object (
{}) asEventin case ifsetSelectionwas called withundefinedEvent. See the commit for more details. - Fix the visibility in View/Edit forms if formoptions with rowpos,colpos used and some columns are hidden
- Move css and min.js files of plugins in subfolders css and min. The changes simplifie the usage of jqGrid in SystemJS
- Remove some old unused properties of
groupingView - Add new
isCellEditingmethod and changegetRowData,getCell,getColandgetDataFieldOfCellto work with editable cells/rows - Amall bug fix: remove the second (duplicate) triggering of
jqGridAfterEditCellevent - Initialize
lastSelectedDataarray as copy of data ifloadonce: truebe used withoutforceClientSorting: true - Remove the second (duplicate) triggering of
jqGridAfterEditCellevent - Small fix in processing of options of the old
excelExportmethod. - Apply
autowidth:trueafter call ofautoResizeAllColumnsifautoresizeOnLoad:trueoption is used. The changes work espesially good with newresetWidthOrg: trueproperty ofautoResizingoption. See the issue for more details. - Migrate from google-closure-compiler 20170124 to uglify 2.1.0 because or bugs in minification of module header by closure compiler. See the commit for more detailes.
- Add new method
getUniqueValueFromColumnIndexto simplify usage ofcreateColumnIndex:truewith jQuery UI Autocomplete - Bug fix in
addRowDatain case of usageidPrefixwith local data - Bug fix processing of
stype:"custom"in searching dialog and the filter toolbar - Add
sorttype:"boolean"as the workaround of problems with filtering by Booleanfalsevalue - Add
"Y"and"N"to possible default values offormatter:"checkbox"
Other old readmes contain the list of the features and bug fixed implemented in previous versions of free jqGrid:
- README4.13.6.md contains the readme of free jqGrid 4.13.6.
- README4.13.5.md contains the readme of free jqGrid 4.13.5.
- README4.13.4.md contains the readme of free jqGrid 4.13.4.
- README4.13.3.md contains the readme of free jqGrid 4.13.3.
- README4.13.2.md contains the readme of free jqGrid 4.13.2.
- README4.13.1.md contains the readme of free jqGrid 4.13.1.
- README4.13.0.md contains the readme of free jqGrid 4.13.0.
- README4.12.1.md contains the readme of free jqGrid 4.12.1.
- README4.12.0.md contains the readme of free jqGrid 4.12.0.
- README4.11.1.md contains the readme of free jqGrid 4.11.1.
- README4.11.0.md contains the readme of free jqGrid 4.11.0.
- README4.10.0.md contains the readme of free jqGrid 4.10.0.
- README492.md contains the readme of free jqGrid 4.9.2.
- README491.md contains the readme of free jqGrid 4.9.1.
- README49.md contains the readme of free jqGrid 4.9.0.
- README48.md contains the readme of free jqGrid 4.8.0.
Many thanks to all, who sent bug reports and suggestions to improve free jqGrid!