feat: refs #7956 getSimilar
This commit is contained in:
parent
91f3da78cf
commit
d077225e9e
|
@ -68,9 +68,16 @@ class ItemCardViewModel(var context: Context) : BaseViewModel(context) {
|
|||
warehouseFk: Int,
|
||||
shipped: String,
|
||||
isShowedByType: Boolean,
|
||||
daysInforward: Int = 0,
|
||||
) {
|
||||
salix.getItemSimilar(
|
||||
params = arrayListOf(itemFk, warehouseFk, shipped, isShowedByType).formatWithQuotes()
|
||||
params = arrayListOf(
|
||||
itemFk,
|
||||
warehouseFk,
|
||||
shipped,
|
||||
isShowedByType,
|
||||
daysInforward
|
||||
).formatWithQuotes()
|
||||
).enqueue(object : SalixCallback<List<ItemProposal>>(context) {
|
||||
override fun onSuccess(response: Response<List<ItemProposal>>) {
|
||||
_itemProposalList.value = response.body()?.let {
|
||||
|
@ -196,7 +203,7 @@ class ItemCardViewModel(var context: Context) : BaseViewModel(context) {
|
|||
}
|
||||
|
||||
fun getAddress() {
|
||||
salix.getAddress("""{"where":{"type":"internal"}, "include": [ { "relation": "address", "scope": { "fields": { "nickname": true } } } ] }""")
|
||||
salix.getAddress("""{"where":{"type": { "neq": "external"}}, "include": [ { "relation": "address", "scope": { "fields": { "nickname": true } } } ] }""")
|
||||
.enqueue(object : SalixCallback<List<AddressLoses>>(context) {
|
||||
override fun onSuccess(response: Response<List<AddressLoses>>) {
|
||||
_addressLosesList.value = response.body()?.let { AddressLosesList(it) }
|
||||
|
|
Loading…
Reference in New Issue