feat onChecking refs #7371
This commit is contained in:
parent
4640cffc30
commit
4d1f22f529
|
@ -129,6 +129,7 @@ class CollectionFragment(
|
||||||
private var recylerViewState: Parcelable? = null
|
private var recylerViewState: Parcelable? = null
|
||||||
private var isScanned: Boolean? = null
|
private var isScanned: Boolean? = null
|
||||||
private var canChangeState = true
|
private var canChangeState = true
|
||||||
|
private var allTicketsChecked = false
|
||||||
|
|
||||||
private lateinit var myGroupList: List<SaleVO>
|
private lateinit var myGroupList: List<SaleVO>
|
||||||
|
|
||||||
|
@ -2060,13 +2061,19 @@ class CollectionFragment(
|
||||||
getString(R.string.Coleccióncompleta).toast(this.context, Toast.LENGTH_SHORT)
|
getString(R.string.Coleccióncompleta).toast(this.context, Toast.LENGTH_SHORT)
|
||||||
saleAdapter!!.notifyDataSetChanged()
|
saleAdapter!!.notifyDataSetChanged()
|
||||||
|
|
||||||
// Se quita de la app
|
|
||||||
/* if (!goBack)
|
|
||||||
ticketCollection_setUsedShelves()
|
|
||||||
goBack = false*/
|
|
||||||
|
|
||||||
if (canChangeState) changeTicketState()
|
if (canChangeState) changeTicketState()
|
||||||
|
}else{
|
||||||
|
if (allTicketsChecked){
|
||||||
|
|
||||||
|
sales.forEach{
|
||||||
|
if (it.isControlled == "0"){
|
||||||
|
viewModel.ticketStateTodaySetState(
|
||||||
|
ticketFk = it.ticketFk.toInt(), state = "ON_CHECKING"
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
allTicketsChecked = false
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2216,6 +2223,7 @@ class CollectionFragment(
|
||||||
ticketFk = it.toInt(), state = "CHECKED"
|
ticketFk = it.toInt(), state = "CHECKED"
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
allTicketsChecked = true
|
||||||
} else if (type == SACADOR) {
|
} else if (type == SACADOR) {
|
||||||
tickets.forEach {
|
tickets.forEach {
|
||||||
viewModel.ticketStateTodaySetState(
|
viewModel.ticketStateTodaySetState(
|
||||||
|
|
Loading…
Reference in New Issue