Friday 8th March, 2019

Editor 1.9.0 release notes

Previous iterations of the Editor 1.x series have seen major new features such as multi-row editing and server-side libraries for .NET Core and NodeJS added. 1.9 takes a slightly different tack focusing primarily on addressing known issues and rounding off the API. That said the main reason for moving to 1.9 releases is the new time picker for the datetime input. The new time picker provides the ability to very quickly select a time, rather than needing to use multiple clicks and scrolling through select lists.

A new example is also available which shows CSV importing into Editor. This will be broken down in detail in a blog post soon.

Please see the release notes for full details.

Downloads

Downloads of specific versions of Editor are only available to license holders. Please see the download page for information about the current release version.

Release notes

New

  • Javascript
    • The ajax option of upload can now be used as a function, allowing complete control of the upload process on the client-side.
    • The DateTime picker's onChange callback will now execute in the scope of the date time instance and pass two arguments: 1. The selected value (as a string) and 2. The Date() object for the selected date / time. Note this is only useful if you are using the DateTime object outside of Editor.
    • Ability to disable show and hide animation via a dependent() return object
    • undependent() method to remove any event listeners added by the dependent() method
    • datetime time picker rewritten to be much easier and quicker to use. The previous version used select elements giving a narrow area where the user would need to click to open and then click to select a value (including possibly scrolling). The new UI uses more screen space, but allows single click selection of times.
  • PHP
    • Validation for Mjoin instances as an array holder (not just on a per field basis). This allows validation of the number of items selected / uploaded. New - PHP: Validate::mjoinMinCount and Validate::mjoinMaxCount validation methods which can be used with the new Mjoin group validation
    • Editor->validator() can be used multiple times to apply multiple different validation methods, rather than just one per instance.
  • .NET
    • Validation for mjoin instances as an array holder (not just on a per field basis). This allows validation of the number of items selected / uploaded.
    • Editor.Validator() can be used multiple times to apply multiple different validation methods, rather than just one per instance.
  • NodeJS
    • Editor.validator() can be used multiple times to apply multiple different validation methods, rather than just one per instance.
    • Introduce support for a schema() method on the Editor class to allow Editor to easily use schemas other than the default path.
    • Validation for mjoin instances as an array holder (not just on a per field basis). This allows validation of the number of items selected / uploaded.
  • Examples
    • CSV import example
    • readTable() example for the server-side which demonstrates the ability to read from a VIEW and update to the base table.

Updates

  • Javascript
    • Using mode() to move out of create mode into edit or remove will now throw an error.
    • Throw an error with a specific message (rather than a generic JS error) stating that a field of a given name does not exist if the server returns error information about a field that the client-side doesn't know about.
  • PHP
    • Validate::minLen and Validate::maxLen are now multi-byte aware, bringing them into line with the validators for .NET and NodeJS
  • NodeJS
    • TypeScript types for the request object structure (IDtRequest) and response object structure (IDtResponse) are now exposed at the top level - e.g. import {IDtRequest} from 'datatables.net-editor-server';.

Fixes

  • Javascript
    • Bootstrap 4 styling for buttons had conflicting classes applied, resulting in rendering errors
    • envelope display controller wouldn't work correctly when table had a DataTables API instance passed in
    • Potential compatibility issue with WebPack and CommonJS loaders in general. The built in display plugins would attempt to use jQuery from a global rather than the passed in version and throw an error if not found.
    • If using mode() to create a new row when inline editing an existing one, the existing row would still show an editing input box after submission
    • add() when used to add multiple new fields after a specified existing field would always just add the new fields at the end of the field list, rather than the specified target.
    • It wasn't possible before to use multiple DataTables / Editors that both referenced the same files table for upload. It now is.
    • If using server-side processing, with KeyTable and inline editing and drawType set to none, navigating to the final row on the last page would be impossible if you edited the final row on the second last page and navigated away using the arrow keys.
    • It was possible to navigate to one month before a minDate in the datetime picker
    • jQuery UI date picker (used with date when jQuery UI DatePicker is loaded - note that datetime is recommended over date) will no longer show the button for the calender icon (which was missing from the distribution).
    • Performance for getting a field value from the DOM when multi-row editing was poor due to repeatedly requesting the value from the DOM rather than just holding a local cache.
    • Editor would remove rows that had been edited when server-side processing was enabled. There was no visible effect to the end user as the table would immediately redraw, but it could potentially cause confusion with the API (counting rows) and cause unnecessary work.
    • Ensure that canReturnSubmit is defined on a plug-in before using it.
  • PHP
    • Error when passing in arguments to Query->get() as an array
    • File information for multiple fields from the same table would result in only one field getting the file information
    • Oracle support improved. Now part of our unit tests. Sorting with server-side processing is not yet fully functional
    • Oracle with server-side processing now sorts correctly over the full data set
    • PHP 7.3 deprecates defined with a case insenstive option.
    • Reset all date fields to 0 by default for dateFormatToSql
    • Server-side processing with ordering disabled would cause a PHP error
    • Support for Oracle with Mjoin linked tables
  • .NET
    • Fix: Upload error when neither a string nor function action was specified
  • NodeJS
    • Typing for the Editor.field() method was not correct. The function performed correctly, but the TypeScript overload was not correct. Update - NodeJS: Update TypeScript to 3.1.6
    • Oracle support for the demo. Now use the official oracledb driver and set the db pool options to use date information as ISO8601
  • Docs
    • table option had a typo in the example
  • Examples
    • Demo SQL for SQL Server could cause an error on systems configured for something other than ymd (ydm for example!).
    • Update Mjoin example to demonstrate the new Mjoin grouping validation