| | |
| | | import cn.flightfeather.thirdapp.activity.ProblemDetailActivity |
| | | import cn.flightfeather.thirdapp.adapter.ProblemListAdapter |
| | | import cn.flightfeather.thirdapp.adapter.RecyclerItemClickListener |
| | | import cn.flightfeather.thirdapp.bean.Inspection |
| | | import cn.flightfeather.thirdapp.bean.Scense |
| | | import cn.flightfeather.thirdapp.bean.Subtask |
| | | import cn.flightfeather.thirdapp.bean.entity.Inspection |
| | | import cn.flightfeather.thirdapp.bean.entity.Scense |
| | | import cn.flightfeather.thirdapp.bean.entity.Subtask |
| | | import cn.flightfeather.thirdapp.model.event.ProblemEvent |
| | | import cn.flightfeather.thirdapp.module.base.BaseActivity |
| | | import kotlinx.android.synthetic.main.dialog_problem_list.* |
| | |
| | | adapter = ProblemListAdapter(this@BaseProblemListActivity, viewModel.problemList.value, viewHolderType) |
| | | addOnItemTouchListener(RecyclerItemClickListener(this@BaseProblemListActivity, this, object : RecyclerItemClickListener.OnItemClickListener { |
| | | override fun onItemClick(view: View?, position: Int) { |
| | | val size = viewModel.problemList.value?.size ?: 0 |
| | | if (position >= size) { |
| | | return |
| | | } |
| | | val intent = Intent(this@BaseProblemListActivity, ProblemDetailActivity::class.java) |
| | | intent.putExtra("problemlistVo", viewModel.problemList.value?.get(position)) |
| | | intent.putExtra("subTaskSelected", subTaskSelected) |