Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/sorting/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Sorting 在Ext Js中单击datagrid列标题作为ASC和DESC时如何进行本地排序_Sorting_Extjs_Columnsorting_Columnheader - Fatal编程技术网

Sorting 在Ext Js中单击datagrid列标题作为ASC和DESC时如何进行本地排序

Sorting 在Ext Js中单击datagrid列标题作为ASC和DESC时如何进行本地排序,sorting,extjs,columnsorting,columnheader,Sorting,Extjs,Columnsorting,Columnheader,我在Ext Js中工作。当我单击列标题按字母顺序排序时,某些本地字符无法正常工作 例如: 艾玛·莎拉·汤姆·厄姆斯 Ş是本地字符 我尝试触发如下“headerclick”事件 listeners: { headerclick : function(grid,col,e){ this.store.setSorterFn(function (record1, record2) { var product

我在Ext Js中工作。当我单击列标题按字母顺序排序时,某些本地字符无法正常工作

例如:

艾玛·莎拉·汤姆·厄姆斯

Ş是本地字符

我尝试触发如下“headerclick”事件

 listeners: {
            headerclick : function(grid,col,e){
                this.store.setSorterFn(function (record1, record2) {
                    var productLine1 = record1.get(col.formName),
                        productLine2 = record2.get(col.formName);
                    return productLine1.localeCompare(productLine2);
                });
            }

但是当我单击列的标题时,我无法管理排序

您不需要处理标题单击您可以使用列的排序器配置处理自定义排序

参考资料:-

希望这对你有帮助