rimossa progress che si blocca in conferma filtri spedizione
This commit is contained in:
parent
f1b4ce469e
commit
85c4768e51
@ -697,34 +697,34 @@ public class OrdiniUscitaElencoFragment extends BaseFragment implements ITitledF
|
|||||||
};
|
};
|
||||||
|
|
||||||
private void refreshList(List<OrdiniUscitaElencoDTO> filteredList) {
|
private void refreshList(List<OrdiniUscitaElencoDTO> filteredList) {
|
||||||
this.onLoadingStarted();
|
|
||||||
|
|
||||||
//new Thread(() -> {
|
// new Thread(() -> {
|
||||||
|
|
||||||
requireActivity().runOnUiThread(() -> {
|
// requireActivity().runOnUiThread(() -> {
|
||||||
List<OrdiniUscitaElencoDTO> tmpList;
|
// this.onLoadingStarted();
|
||||||
|
List<OrdiniUscitaElencoDTO> tmpList;
|
||||||
|
|
||||||
if (filteredList != null) {
|
if (filteredList != null) {
|
||||||
tmpList = filteredList;
|
tmpList = filteredList;
|
||||||
} else if (mAppliedFilterViewModel != null) {
|
} else if (mAppliedFilterViewModel != null) {
|
||||||
mAppliedFilterViewModel.applyAllTests();
|
mAppliedFilterViewModel.applyAllTests();
|
||||||
tmpList = mAppliedFilterViewModel.getMutableFilteredOrderList().getValue();
|
tmpList = mAppliedFilterViewModel.getMutableFilteredOrderList().getValue();
|
||||||
} else {
|
} else {
|
||||||
tmpList = mViewModel.getOrderList().getValue();
|
tmpList = mViewModel.getOrderList().getValue();
|
||||||
}
|
}
|
||||||
|
|
||||||
var list = convertDataModelToListModel(tmpList);
|
var list = convertDataModelToListModel(tmpList);
|
||||||
|
|
||||||
this.mOrdiniInevasiMutableData.clear();
|
this.mOrdiniInevasiMutableData.clear();
|
||||||
this.mOrdiniInevasiMutableData.addAll(list);
|
this.mOrdiniInevasiMutableData.addAll(list);
|
||||||
|
|
||||||
fabVisible.set(Stream.of(mOrdiniInevasiMutableData)
|
fabVisible.set(Stream.of(mOrdiniInevasiMutableData)
|
||||||
.anyMatch(y -> y.getSelectedObservable().get()));
|
.anyMatch(y -> y.getSelectedObservable().get()));
|
||||||
|
|
||||||
this.onLoadingEnded();
|
// this.onLoadingEnded();
|
||||||
});
|
// });
|
||||||
|
|
||||||
//}).start();
|
// }).start();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -104,7 +104,7 @@ public class OrdiniUscitaElencoViewModel {
|
|||||||
.distinct()
|
.distinct()
|
||||||
.toList();
|
.toList();
|
||||||
|
|
||||||
if (foundGestioni != null && foundGestioni.size() > 1) {
|
if (foundGestioni.size() > 1) {
|
||||||
this.sendError(new InvalidLUMultiGestioneException());
|
this.sendError(new InvalidLUMultiGestioneException());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -116,7 +116,7 @@ public class OrdiniUscitaElencoViewModel {
|
|||||||
.distinct()
|
.distinct()
|
||||||
.toList();
|
.toList();
|
||||||
|
|
||||||
if (foundCodMdep != null && foundCodMdep.size() > 1) {
|
if (foundCodMdep.size() > 1) {
|
||||||
this.sendError(new InvalidLUMultiCodMdepException());
|
this.sendError(new InvalidLUMultiCodMdepException());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@ -130,7 +130,7 @@ public class OrdiniUscitaElencoViewModel {
|
|||||||
|
|
||||||
this.mOrdiniRESTConsumer.retrieveListaArticoliFromOrdiniUscita(mCurrentCodMdep, selectedOrdersBase, sitArts -> {
|
this.mOrdiniRESTConsumer.retrieveListaArticoliFromOrdiniUscita(mCurrentCodMdep, selectedOrdersBase, sitArts -> {
|
||||||
|
|
||||||
if(mtbGrupToFilter != null && !mtbGrupToFilter.isEmpty()) {
|
if (mtbGrupToFilter != null && !mtbGrupToFilter.isEmpty()) {
|
||||||
sitArts = Stream.of(sitArts)
|
sitArts = Stream.of(sitArts)
|
||||||
.filter(x -> Stream.of(mtbGrupToFilter).map(MtbGrup::getCodMgrp).anyMatch(y -> y.equalsIgnoreCase(x.getCodMgrp())))
|
.filter(x -> Stream.of(mtbGrupToFilter).map(MtbGrup::getCodMgrp).anyMatch(y -> y.equalsIgnoreCase(x.getCodMgrp())))
|
||||||
.toList();
|
.toList();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user