|
@@ -117,6 +117,7 @@ class GraphyActivity : BaseActivity(), ICaptureStatusListener, ICameraChangedCal
|
|
|
override val di: DI by closestDI()
|
|
|
|
|
|
private val mVm: AdmViewModel by viewModel()
|
|
|
+ private val equipClassList = ArrayList<String>()
|
|
|
|
|
|
//选择图片
|
|
|
private val REQUEST_CODE_PIC = 0X102
|
|
@@ -1113,6 +1114,8 @@ class GraphyActivity : BaseActivity(), ICaptureStatusListener, ICameraChangedCal
|
|
|
equipLocation.setText("")
|
|
|
drawLl.visibility = View.GONE
|
|
|
equipLl.visibility = View.VISIBLE
|
|
|
+ equipEdit.setText("")
|
|
|
+ equipRg.clearCheck()
|
|
|
|
|
|
}
|
|
|
|
|
@@ -1396,11 +1399,14 @@ class GraphyActivity : BaseActivity(), ICaptureStatusListener, ICameraChangedCal
|
|
|
for (model in list) {
|
|
|
val textview = TextView(this)
|
|
|
textview.apply {
|
|
|
- setText(model.type + "(${model.children.size})")
|
|
|
+ setText(model.typeName + "-" + model.type + "(${model.children.size})")
|
|
|
setSingleLine()
|
|
|
gravity = Gravity.CENTER
|
|
|
textSize = 12f
|
|
|
height = DensityUtils.dp2px(this@GraphyActivity, 30f)
|
|
|
+ if (equipClassList.contains(model.type)) {
|
|
|
+ model.isCheck = false
|
|
|
+ }
|
|
|
if (model.isCheck) {
|
|
|
background = resources.getDrawable(R.drawable.shape_filter_normal)
|
|
|
textColor = resources.getColor(R.color.grey_900)
|
|
@@ -1411,10 +1417,12 @@ class GraphyActivity : BaseActivity(), ICaptureStatusListener, ICameraChangedCal
|
|
|
setOnClickListener {
|
|
|
model.isCheck = !model.isCheck
|
|
|
if (model.isCheck) {
|
|
|
+ equipClassList.remove(model.type!!)
|
|
|
textview.background =
|
|
|
resources.getDrawable(R.drawable.shape_filter_normal)
|
|
|
textview.textColor = resources.getColor(R.color.grey_900)
|
|
|
} else {
|
|
|
+ equipClassList.add(model.type!!)
|
|
|
textview.background =
|
|
|
resources.getDrawable(R.drawable.shape_filter_selected)
|
|
|
textview.textColor = resources.getColor(R.color.white)
|