Flex 4.5 Spark Datagrid 多列排序
有谁知道 Flex 4.5 Spark Datagrid 是否支持本机多列排序 - 就像 ADG 一样?
我正在查看 api 文档,但看不到任何内容...
谢谢
does anyboy know if Flex 4.5 Spark Datagrid suppoprts multi-column sort natively - just like the ADG does?
I'm looking at the api documentation and cannot see anything on this...
Thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(3)
Apache 的 4.10/4.11 版本具有所需的方法。我们已经在博客中介绍了这一点:http://blog.flexicious .com/post/Spark-DataGrid-Multi-Column-Sort.aspx
The 4.10/4.11 release from Apache has the methods needed. We've blogged about this here: http://blog.flexicious.com/post/Spark-DataGrid-Multi-Column-Sort.aspx
本来就不是没有。 Flex 的图表不断得到改进,但目前尚未添加。
最好的解决方案是在列标题上设置一个侦听器,然后自己对数据进行排序。这并不难,但能够保持排序的“状态”很重要。另外,它还可以让您更好地更改排序选项。
Not natively no. There's constant improvements being done on the charting for Flex, but this hasn't been added in just yet.
Your best solution would be to have a listener on the column headers and then sort the data yourself. It isn't that hard, but it's important to be able to keep 'state' on the sort. Plus, it'll give you better malleability to change the sorting options.
我使用 Spark DataGrid 的 sortCompareFunction 属性来定义一个包含多列排序逻辑的函数。就目前而言,它运行得很好。
I use the sortCompareFunction property of the spark DataGrid to define a function with the multi-column sorting logic in it. It works well enough, for the moment.