feat: 国际出港组装分配
This commit is contained in:
@@ -0,0 +1,26 @@
|
||||
package com.lukouguoji.gjc.holder
|
||||
|
||||
import android.view.View
|
||||
import com.lukouguoji.gjc.databinding.ItemGjcAssembleAllocateBinding
|
||||
import com.lukouguoji.module_base.base.BaseViewHolder
|
||||
import com.lukouguoji.module_base.bean.GjcAssembleAllocate
|
||||
|
||||
/**
|
||||
* 国际出港组装分配列表ViewHolder
|
||||
*/
|
||||
class GjcAssembleAllocateViewHolder(view: View) :
|
||||
BaseViewHolder<GjcAssembleAllocate, ItemGjcAssembleAllocateBinding>(view) {
|
||||
|
||||
override fun onBind(item: Any?, position: Int) {
|
||||
val bean = getItemBean(item) ?: return
|
||||
binding.bean = bean
|
||||
binding.executePendingBindings()
|
||||
|
||||
// 选中图标点击事件
|
||||
binding.ivIcon.setOnClickListener {
|
||||
bean.checked.set(!bean.checked.get())
|
||||
// 通知adapter刷新item
|
||||
binding.executePendingBindings()
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user