{hero}

searchPanes.i18n.emptyPanes

Since: SearchPanes 1.0.0

Add internationalisation to the message shown when no panes are displayed.
Please note - this property requires the SearchPanes extension for DataTables.

Description

SearchPanes will display a message in the div that is meant to hold the panes if there are none to display. If a custom message has been declared then this will be shown in the place of the default message. If the value of searchPanes.i18n.emptyPanes is set to null then the div will not be shown.

This option will default to the value given by language.searchPanes.emptyPanes, which should generally be preferred over this option as the language strings can be loaded by Ajax and shared for the whole table, but if needed, this option is available to override that on a per instance basis.

Type

string

Description:

By setting the searchPanes.i18n.emptyPanes option to a message, if there are no panes to be displayed then this message will be displayed in their place.

Default

  • Value: No searchPanes

The default value for the searchPanes.i18n.emptyPanes parameter is "No SearchPanes". This is so that it is easier for devs to realise when there are no SearchPanes to be shown rather than mistaking the lack of a div for an error.

Examples

Alter Empty Pane Message:

new DataTable('#myTable', {
	layout: {
		top1: {
			searchPanes: {
				i18n: {
					emptyPanes: 'There are no panes to display. :/'
				}
			}
		}
	}
});

Hide the div that is meant to contain the SearchPanes:

new DataTable('#myTable', {
	layout: {
		top1: {
			searchPanes: {
				i18n: {
					emptyPanes: null
				}
			}
		}
	}
});