groupName.add(“统计1”)
groupName.add(“统计2”)
return groupName
}
…
3.1 StatisticsAdapter.kt
3.1.1 RootNodeProvider.kt,点击item
override fun onClick(helper: BaseViewHolder, view: View, data: BaseNode, position: Int) {
getAdapter()!!.expandOrCollapse(position)
}
3.1.2 StatisticsNodeProvider.kt
override fun onClick(helper: BaseViewHolder, view: View, data: BaseNode, position: Int) {
val entity: StatisticsNode = data as Stati
sticsNode
if (“2” == entity.classity) {
v