refs #6460 fix:calls
This commit is contained in:
parent
3b8f06a3ba
commit
67b9460fbd
|
@ -13,8 +13,8 @@ android {
|
||||||
applicationId "es.verdnatura"
|
applicationId "es.verdnatura"
|
||||||
minSdkVersion 24 //21
|
minSdkVersion 24 //21
|
||||||
targetSdkVersion 33
|
targetSdkVersion 33
|
||||||
versionCode 242
|
versionCode 245
|
||||||
versionName = "23.48Beta"
|
versionName = "23.46"
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -92,24 +92,23 @@ class BuscarItemFragment(
|
||||||
true,
|
true,
|
||||||
it.list[0].errorMessage
|
it.list[0].errorMessage
|
||||||
)
|
)
|
||||||
}
|
}else{
|
||||||
} else {
|
adapter = LocationAdapter(it.list, pasillerosItemClickListener!!)
|
||||||
|
binding.locationRecyclerview.adapter = adapter
|
||||||
|
binding.locationRecyclerview.layoutManager =
|
||||||
|
LinearLayoutManager(
|
||||||
|
requireContext(),
|
||||||
|
LinearLayoutManager.VERTICAL,
|
||||||
|
false
|
||||||
|
)
|
||||||
|
|
||||||
adapter = LocationAdapter(it.list, pasillerosItemClickListener!!)
|
var totalVisible = 0
|
||||||
binding.locationRecyclerview.adapter = adapter
|
it.list.forEach {
|
||||||
binding.locationRecyclerview.layoutManager =
|
totalVisible += it.visible
|
||||||
LinearLayoutManager(
|
}
|
||||||
requireContext(),
|
binding.mainToolbar.toolbarTitle.text =
|
||||||
LinearLayoutManager.VERTICAL,
|
getString(R.string.item) + itemFk + " " + getString(R.string.visibleTotal) + totalVisible
|
||||||
false
|
|
||||||
)
|
|
||||||
|
|
||||||
var totalVisible = 0
|
|
||||||
it.list.forEach {
|
|
||||||
totalVisible += it.visible
|
|
||||||
}
|
}
|
||||||
binding.mainToolbar.toolbarTitle.text =
|
|
||||||
getString(R.string.item) + itemFk + " " + getString(R.string.visibleTotal) + totalVisible
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
|
@ -12,7 +12,6 @@ import es.verdnatura.presentation.base.BaseViewModel
|
||||||
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
import es.verdnatura.presentation.base.getMessageFromAllResponse
|
||||||
import es.verdnatura.presentation.base.nameofFunction
|
import es.verdnatura.presentation.base.nameofFunction
|
||||||
import es.verdnatura.presentation.common.Event
|
import es.verdnatura.presentation.common.Event
|
||||||
import es.verdnatura.presentation.common.ItemShelvingSaleSalix
|
|
||||||
import es.verdnatura.presentation.common.ResponseItemVO
|
import es.verdnatura.presentation.common.ResponseItemVO
|
||||||
import es.verdnatura.presentation.view.feature.collection.ItemVO
|
import es.verdnatura.presentation.view.feature.collection.ItemVO
|
||||||
import es.verdnatura.presentation.view.feature.collection.SalesModifiedList
|
import es.verdnatura.presentation.view.feature.collection.SalesModifiedList
|
||||||
|
@ -88,9 +87,14 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
val responseItemShelvingSale: LiveData<ResponseItemVO>
|
val responseItemShelvingSale: LiveData<ResponseItemVO>
|
||||||
get() = _responseItemShelvingSale
|
get() = _responseItemShelvingSale
|
||||||
|
|
||||||
|
|
||||||
|
private val _responseItemShelvingSaleUnPicked by lazy { MutableLiveData<ResponseItemVO>() }
|
||||||
|
val responseItemShelvingSaleUnPicked: LiveData<ResponseItemVO>
|
||||||
|
get() = _responseItemShelvingSaleUnPicked
|
||||||
|
|
||||||
private val _responseCollectionAddItem by lazy { MutableLiveData<ResponseItemVO>() }
|
private val _responseCollectionAddItem by lazy { MutableLiveData<ResponseItemVO>() }
|
||||||
val responseCollectionAddItem: LiveData<ResponseItemVO>
|
val responseCollectionAddItem: LiveData<ResponseItemVO>
|
||||||
get() = responseCollectionAddItem
|
get() = _responseCollectionAddItem
|
||||||
|
|
||||||
private val _responseConfirmReservedUpdate by lazy { MutableLiveData<ResponseItemVO>() }
|
private val _responseConfirmReservedUpdate by lazy { MutableLiveData<ResponseItemVO>() }
|
||||||
val responseConfirmReservedUpdate: LiveData<ResponseItemVO>
|
val responseConfirmReservedUpdate: LiveData<ResponseItemVO>
|
||||||
|
@ -372,13 +376,14 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
fun confirmItemShelvingReserved(
|
fun itemShelvingSaleSetQuantity(
|
||||||
itemShelvingSaleFk: Int,
|
itemShelvingSaleFk: Int,
|
||||||
quantity: Int,
|
quantity: Int,
|
||||||
isItemShelvingSaleEmpty: Boolean?
|
isItemShelvingSaleEmpty: Boolean?
|
||||||
) {
|
) {
|
||||||
salix.itemShelvingsConfirmRerserved(
|
salix.itemShelvingSaleSetquantitySalix(params = arrayListOf(itemShelvingSaleFk,quantity,isItemShelvingSaleEmpty)
|
||||||
params = ItemShelvingSaleSalix(itemShelvingSaleFk, quantity, isItemShelvingSaleEmpty)
|
//salix.itemShelvingSaleSetQuantity(
|
||||||
|
// params = ItemShelvingSaleSalix(itemShelvingSaleFk, quantity, isItemShelvingSaleEmpty)
|
||||||
).enqueue(object : SilexCallback<Any>(context) {
|
).enqueue(object : SilexCallback<Any>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseConfirmReservedItemShelvingSale.value = ResponseItemVO(
|
_responseConfirmReservedItemShelvingSale.value = ResponseItemVO(
|
||||||
|
@ -562,14 +567,14 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
)
|
)
|
||||||
).enqueue(object : SalixCallback<Unit>(context) {
|
).enqueue(object : SalixCallback<Unit>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseItemShelvingSale.value = ResponseItemVO(
|
_responseItemShelvingSaleUnPicked.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Unit>) {
|
override fun onSuccess(response: Response<Unit>) {
|
||||||
_responseItemShelvingSale.value = ResponseItemVO(isError = false)
|
_responseItemShelvingSaleUnPicked.value = ResponseItemVO(isError = false)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -583,14 +588,14 @@ class CollectionViewModel(val context: Context) : BaseViewModel(context) {
|
||||||
)
|
)
|
||||||
).enqueue(object : SalixCallback<Unit>(context) {
|
).enqueue(object : SalixCallback<Unit>(context) {
|
||||||
override fun onError(t: Throwable) {
|
override fun onError(t: Throwable) {
|
||||||
_responseItemShelvingSale.value = ResponseItemVO(
|
_responseSaleGroup.value = ResponseItemVO(
|
||||||
isError = true,
|
isError = true,
|
||||||
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
errorMessage = getMessageFromAllResponse(nameofFunction(this), t.message!!)
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onSuccess(response: Response<Unit>) {
|
override fun onSuccess(response: Response<Unit>) {
|
||||||
_responseItemShelvingSale.value = ResponseItemVO(isError = false)
|
_responseSaleGroup.value = ResponseItemVO(isError = false)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
|
@ -133,8 +133,7 @@ class ExpeditionPalletDetailFragment(
|
||||||
requireContext()
|
requireContext()
|
||||||
)
|
)
|
||||||
viewModel.expeditionPalletPrintSet(
|
viewModel.expeditionPalletPrintSet(
|
||||||
itemPallet!!.Pallet,
|
itemPallet!!.Pallet
|
||||||
getDataInt(SECTORFK)
|
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
ma.messageWithSound(
|
ma.messageWithSound(
|
||||||
|
|
|
@ -90,10 +90,9 @@ class ExpeditionPalletDetailViewModel(var context: Context) : BaseViewModel(cont
|
||||||
}
|
}
|
||||||
|
|
||||||
fun expeditionPalletPrintSet(
|
fun expeditionPalletPrintSet(
|
||||||
vPalletFk: Int,
|
vPalletFk: Int
|
||||||
vSectorFk: Int
|
|
||||||
) {
|
) {
|
||||||
salix.expeditionPalletPrintLabel(arrayListOf(vPalletFk, vSectorFk))
|
salix.expeditionPalletPrintLabel(arrayListOf(vPalletFk))
|
||||||
.enqueue(object : SilexCallback<Any>(context) {
|
.enqueue(object : SilexCallback<Any>(context) {
|
||||||
override fun onSuccess(response: Response<Any>) {
|
override fun onSuccess(response: Response<Any>) {
|
||||||
_responsePrintPallet.value =
|
_responsePrintPallet.value =
|
||||||
|
|
Loading…
Reference in New Issue