**在二级列表的布局里写,注意写在 return view 之前**
holder.tv_del.setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
List<GoosBean.DataBean.DatasBean> datasBeen = childList.get(groupPosition);
GoosBean.DataBean.DatasBean remove = datasBeen.remove(childPosition);
if (datasBeen.size() == 0) {
childList.remove(groupPosition);
groupList.remove(groupPosition);
}
EventBus.getDefault().post(compute());
notifyDataSetChanged();
}
});
android 简单二级购物车的删除方法
最新推荐文章于 2017-12-25 09:03:00 发布