|
|
|
@ -34,11 +34,10 @@
|
|
|
|
|
* } );
|
|
|
|
|
*/
|
|
|
|
|
|
|
|
|
|
jQuery.fn.DataTable.ext.type.search.string = function ( data ) {
|
|
|
|
|
return ! data ?
|
|
|
|
|
'' :
|
|
|
|
|
typeof data === 'string' ?
|
|
|
|
|
data
|
|
|
|
|
(function(){
|
|
|
|
|
|
|
|
|
|
function removeAccents ( data ) {
|
|
|
|
|
return data
|
|
|
|
|
.replace( /έ/g, 'ε' )
|
|
|
|
|
.replace( /[ύϋΰ]/g, 'υ' )
|
|
|
|
|
.replace( /ό/g, 'ο' )
|
|
|
|
@ -61,6 +60,25 @@ jQuery.fn.DataTable.ext.type.search.string = function ( data ) {
|
|
|
|
|
.replace( /ã/g, 'a' )
|
|
|
|
|
.replace( /õ/g, 'o' )
|
|
|
|
|
.replace( /ç/g, 'c' )
|
|
|
|
|
.replace( /ì/g, 'i' ) :
|
|
|
|
|
.replace( /ì/g, 'i' );
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
var searchType = jQuery.fn.DataTable.ext.type.search;
|
|
|
|
|
|
|
|
|
|
searchType.string = function ( data ) {
|
|
|
|
|
return ! data ?
|
|
|
|
|
'' :
|
|
|
|
|
typeof data === 'string' ?
|
|
|
|
|
removeAccents( data ) :
|
|
|
|
|
data;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
searchType.html = function ( data ) {
|
|
|
|
|
return ! data ?
|
|
|
|
|
'' :
|
|
|
|
|
typeof data === 'string' ?
|
|
|
|
|
removeAccents( data.replace( /<.*?>/g, '' ) ) :
|
|
|
|
|
data;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
}());
|