New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
反馈一个关以json生成列表的问题 #301
Comments
经过,我的不懈努力发现问题出现在
这里 因为你使用json 是转换成linkHasMap 而这边使用 泛型获取名称 肯定会报错,所以我在 TableParser类中的 sort 方法里做了一点修改
因为使用 json 一般情况下都是接口返回的数据,可以让后台给你返回的时候就是排列好的 ,希望对大家有帮助 |
在使用json 转表格时,使用表格的 smarTable.setSortColumn 排序功能 会报错,日志为:
E/AndroidRuntime: FATAL EXCEPTION: Thread-13
Process: com.example.shanxidemo, PID: 27579
com.bin.david.form.exception.TableException: NoSuchFieldException :Please check whether field name is correct!
at com.bin.david.form.core.TableParser$1.compare(TableParser.java:227)
at java.util.TimSort.countRunAndMakeAscending(TimSort.java:351)
at java.util.TimSort.sort(TimSort.java:216)
at java.util.Arrays.sort(Arrays.java:1523)
at java.util.Collections.sort(Collections.java:238)
at com.bin.david.form.core.TableParser.sort(TableParser.java:196)
at com.bin.david.form.core.TableParser.parse(TableParser.java:42)
at com.example.shanxidemo.phaseIi.view.SmartTable$1.run(SmartTable.java:238)
at java.lang.Thread.run(Thread.java:761)
The text was updated successfully, but these errors were encountered: