[BUGFIX] Risolto problema di modifica/cancellazione riga in Accettazione
This commit is contained in:
parent
2e21982ea7
commit
38853e5514
@ -0,0 +1,28 @@
|
|||||||
|
package it.integry.integrywmsnative.core.utility;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
public class UtilityBigDecimal {
|
||||||
|
|
||||||
|
public static boolean greaterThan(BigDecimal input, BigDecimal toCompareWith) {
|
||||||
|
if(input == null) return false;
|
||||||
|
if(toCompareWith == null) return false;
|
||||||
|
|
||||||
|
return input.compareTo(toCompareWith) > 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static boolean equalsTo(BigDecimal input, BigDecimal toCompareWith) {
|
||||||
|
if(input == null) return false;
|
||||||
|
if(toCompareWith == null) return false;
|
||||||
|
|
||||||
|
return input.compareTo(toCompareWith) == 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static boolean lowerThan(BigDecimal input, BigDecimal toCompareWith) {
|
||||||
|
if(input == null) return false;
|
||||||
|
if(toCompareWith == null) return false;
|
||||||
|
|
||||||
|
return input.compareTo(toCompareWith) < 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -72,4 +72,10 @@ public class UtilityString {
|
|||||||
return Html.fromHtml(String.format(UtilityResources.getString(stringId),params));
|
return Html.fromHtml(String.format(UtilityResources.getString(stringId),params));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public static boolean equalsIgnoreCase(String val1, String val2) {
|
||||||
|
return (val1 == null && val2 == null) ||
|
||||||
|
(val1 != null && val1.equalsIgnoreCase(val2));
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,12 +2,15 @@ package it.integry.integrywmsnative.gest.accettazione_ordine_inevaso.viewmodel;
|
|||||||
|
|
||||||
import android.app.Dialog;
|
import android.app.Dialog;
|
||||||
import android.app.ProgressDialog;
|
import android.app.ProgressDialog;
|
||||||
|
|
||||||
import androidx.databinding.ObservableArrayList;
|
import androidx.databinding.ObservableArrayList;
|
||||||
import androidx.databinding.ObservableField;
|
import androidx.databinding.ObservableField;
|
||||||
import androidx.appcompat.app.AlertDialog;
|
import androidx.appcompat.app.AlertDialog;
|
||||||
import androidx.recyclerview.widget.LinearLayoutManager;
|
import androidx.recyclerview.widget.LinearLayoutManager;
|
||||||
|
|
||||||
import android.text.SpannableString;
|
import android.text.SpannableString;
|
||||||
|
|
||||||
|
import com.annimon.stream.Optional;
|
||||||
import com.annimon.stream.Stream;
|
import com.annimon.stream.Stream;
|
||||||
import com.tfb.fbtoast.FBToast;
|
import com.tfb.fbtoast.FBToast;
|
||||||
|
|
||||||
@ -36,6 +39,7 @@ import it.integry.integrywmsnative.core.model.secondary.GestioneEnum;
|
|||||||
import it.integry.integrywmsnative.core.report.ReportManager;
|
import it.integry.integrywmsnative.core.report.ReportManager;
|
||||||
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityBarcode;
|
import it.integry.integrywmsnative.core.utility.UtilityBarcode;
|
||||||
|
import it.integry.integrywmsnative.core.utility.UtilityBigDecimal;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityDate;
|
import it.integry.integrywmsnative.core.utility.UtilityDate;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityLogger;
|
import it.integry.integrywmsnative.core.utility.UtilityLogger;
|
||||||
@ -88,7 +92,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
this.init();
|
this.init();
|
||||||
}
|
}
|
||||||
|
|
||||||
private void init(){
|
private void init() {
|
||||||
|
|
||||||
currentOrderBy = AccettazioneOrdineInevasoOrderBy.Enum.fromInt(SettingsManager.i().userSession.defaultOrdinamentoPickingAccettazione);
|
currentOrderBy = AccettazioneOrdineInevasoOrderBy.Enum.fromInt(SettingsManager.i().userSession.defaultOrdinamentoPickingAccettazione);
|
||||||
|
|
||||||
@ -97,7 +101,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
mArticoliInColloBottomSheetViewModel.setOnItemEditedCallback(this::onRowEdited);
|
mArticoliInColloBottomSheetViewModel.setOnItemEditedCallback(this::onRowEdited);
|
||||||
|
|
||||||
groupedOrdini = new ArrayList<>();
|
groupedOrdini = new ArrayList<>();
|
||||||
for (OrdineAccettazioneDTO ordine : mOrders){
|
for (OrdineAccettazioneDTO ordine : mOrders) {
|
||||||
groupedOrdini.addAll(ordine.getOrdini());
|
groupedOrdini.addAll(ordine.getOrdini());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -115,9 +119,9 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
.distinctBy(x -> x)
|
.distinctBy(x -> x)
|
||||||
.toList();
|
.toList();
|
||||||
|
|
||||||
if(foundGestioni != null) {
|
if (foundGestioni != null) {
|
||||||
|
|
||||||
if(foundGestioni.size() == 1) {
|
if (foundGestioni.size() == 1) {
|
||||||
defaultGestioneOfUL = foundGestioni.get(0) == GestioneEnum.PRODUZIONE ? GestioneEnum.LAVORAZIONE : foundGestioni.get(0);
|
defaultGestioneOfUL = foundGestioni.get(0) == GestioneEnum.PRODUZIONE ? GestioneEnum.LAVORAZIONE : foundGestioni.get(0);
|
||||||
} else {
|
} else {
|
||||||
DialogSimpleMessageHelper.makeErrorDialog(mActivity, new SpannableString(mActivity.getString(R.string.error_multiple_gest)), null, () -> {
|
DialogSimpleMessageHelper.makeErrorDialog(mActivity, new SpannableString(mActivity.getString(R.string.error_multiple_gest)), null, () -> {
|
||||||
@ -134,7 +138,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private void initRecyclerView(List<List<OrdineAccettazioneDTO.Riga>> groupedRighe){
|
private void initRecyclerView(List<List<OrdineAccettazioneDTO.Riga>> groupedRighe) {
|
||||||
//RecyclerView setup
|
//RecyclerView setup
|
||||||
mActivity.bindings.accettazioneOrdineMainList.setHasFixedSize(true);
|
mActivity.bindings.accettazioneOrdineMainList.setHasFixedSize(true);
|
||||||
|
|
||||||
@ -152,8 +156,8 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
mActivity.bindings.accettazioneOrdineMainList.setAdapter(mAdapter);
|
mActivity.bindings.accettazioneOrdineMainList.setAdapter(mAdapter);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void refreshOrderBy(boolean forceHiddenCheck){
|
public void refreshOrderBy(boolean forceHiddenCheck) {
|
||||||
switch (currentOrderBy){
|
switch (currentOrderBy) {
|
||||||
case COD_ART_FOR:
|
case COD_ART_FOR:
|
||||||
groupedRighe = helper.getOrdiniRaggruppatiPerCodArtForn(groupedOrdini, forceHiddenCheck);
|
groupedRighe = helper.getOrdiniRaggruppatiPerCodArtForn(groupedOrdini, forceHiddenCheck);
|
||||||
break;
|
break;
|
||||||
@ -186,7 +190,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
}
|
}
|
||||||
|
|
||||||
public void removeListFilter() {
|
public void removeListFilter() {
|
||||||
for(int i = 0; i < groupedOrdini.size(); i++) {
|
for (int i = 0; i < groupedOrdini.size(); i++) {
|
||||||
groupedOrdini.get(i).setTempHidden(false);
|
groupedOrdini.get(i).setTempHidden(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -194,9 +198,9 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
mActivity.bindings.filteredArtsInListExpandableLayout.collapse(true);
|
mActivity.bindings.filteredArtsInListExpandableLayout.collapse(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
public void recoverUL(MtbColt recoveredMtbColt){
|
public void recoverUL(MtbColt recoveredMtbColt) {
|
||||||
|
|
||||||
for(int i = 0; i < recoveredMtbColt.getMtbColr().size(); i++){
|
for (int i = 0; i < recoveredMtbColt.getMtbColr().size(); i++) {
|
||||||
|
|
||||||
MtbColr currentMtbColr = recoveredMtbColt.getMtbColr().get(i);
|
MtbColr currentMtbColr = recoveredMtbColt.getMtbColr().get(i);
|
||||||
|
|
||||||
@ -215,7 +219,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
.toList();
|
.toList();
|
||||||
|
|
||||||
|
|
||||||
if(foundRows != null && foundRows.size() > 0){
|
if (foundRows != null && foundRows.size() > 0) {
|
||||||
OrdineAccettazioneDTO.Riga currentRow = foundRows.get(0);
|
OrdineAccettazioneDTO.Riga currentRow = foundRows.get(0);
|
||||||
|
|
||||||
currentRow.setHidden(false);
|
currentRow.setHidden(false);
|
||||||
@ -230,15 +234,13 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public RunnableArgs<BarcodeScanDTO> onScanSuccessfull = data -> {
|
public RunnableArgs<BarcodeScanDTO> onScanSuccessfull = data -> {
|
||||||
|
|
||||||
Dialog progressDialog = UtilityProgress.createDefaultProgressDialog(mActivity);
|
Dialog progressDialog = UtilityProgress.createDefaultProgressDialog(mActivity);
|
||||||
|
|
||||||
BarcodeManager.disable();
|
BarcodeManager.disable();
|
||||||
if(UtilityBarcode.isEtichettaAnonima(data)){
|
if (UtilityBarcode.isEtichettaAnonima(data)) {
|
||||||
if(!thereIsAnOpenedUL()) this.executeEtichettaAnonima(data, progressDialog);
|
if (!thereIsAnOpenedUL()) this.executeEtichettaAnonima(data, progressDialog);
|
||||||
else {
|
else {
|
||||||
DialogSimpleMessageHelper.makeErrorDialog(
|
DialogSimpleMessageHelper.makeErrorDialog(
|
||||||
mActivity,
|
mActivity,
|
||||||
@ -248,11 +250,11 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
BarcodeManager.enable();
|
BarcodeManager.enable();
|
||||||
progressDialog.dismiss();
|
progressDialog.dismiss();
|
||||||
})
|
})
|
||||||
.show();
|
.show();
|
||||||
}
|
}
|
||||||
} else if(UtilityBarcode.isEtichetta128(data)) {
|
} else if (UtilityBarcode.isEtichetta128(data)) {
|
||||||
this.executeEtichettaEan128(data, progressDialog);
|
this.executeEtichettaEan128(data, progressDialog);
|
||||||
} else if(UtilityBarcode.isEanPeso(data)){
|
} else if (UtilityBarcode.isEanPeso(data)) {
|
||||||
this.executeEtichettaEanPeso(data, progressDialog);
|
this.executeEtichettaEanPeso(data, progressDialog);
|
||||||
} else {
|
} else {
|
||||||
this.loadArticolo(data.getStringValue(), null, progressDialog);
|
this.loadArticolo(data.getStringValue(), null, progressDialog);
|
||||||
@ -264,8 +266,8 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
private void executeEtichettaAnonima(BarcodeScanDTO barcodeScanDTO, Dialog progressDialog) {
|
private void executeEtichettaAnonima(BarcodeScanDTO barcodeScanDTO, Dialog progressDialog) {
|
||||||
ColliMagazzinoRESTConsumer.getBySSCC(barcodeScanDTO.getStringValue(), false, false, mtbColt -> {
|
ColliMagazzinoRESTConsumer.getBySSCC(barcodeScanDTO.getStringValue(), false, false, mtbColt -> {
|
||||||
|
|
||||||
if(mtbColt == null) {
|
if (mtbColt == null) {
|
||||||
if(!UtilityBarcode.isEtichettaAnonimaOfCurrentYear(barcodeScanDTO.getStringValue())) {
|
if (!UtilityBarcode.isEtichettaAnonimaOfCurrentYear(barcodeScanDTO.getStringValue())) {
|
||||||
UtilityExceptions.defaultException(mActivity, new Exception("Per continuare scansiona un'etichetta dell'anno corrente"), progressDialog, false);
|
UtilityExceptions.defaultException(mActivity, new Exception("Per continuare scansiona un'etichetta dell'anno corrente"), progressDialog, false);
|
||||||
BarcodeManager.enable();
|
BarcodeManager.enable();
|
||||||
} else {
|
} else {
|
||||||
@ -292,12 +294,12 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
String barcodeProd = null;
|
String barcodeProd = null;
|
||||||
|
|
||||||
if(ean128Model.Sscc != null) barcodeProd = ean128Model.Sscc;
|
if (ean128Model.Sscc != null) barcodeProd = ean128Model.Sscc;
|
||||||
if(ean128Model.Gtin != null) barcodeProd = ean128Model.Gtin;
|
if (ean128Model.Gtin != null) barcodeProd = ean128Model.Gtin;
|
||||||
if(ean128Model.Content != null) barcodeProd = ean128Model.Content;
|
if (ean128Model.Content != null) barcodeProd = ean128Model.Content;
|
||||||
|
|
||||||
|
|
||||||
if(!UtilityString.isNullOrEmpty(barcodeProd)) {
|
if (!UtilityString.isNullOrEmpty(barcodeProd)) {
|
||||||
if (barcodeProd.startsWith("0") || barcodeProd.startsWith("9")) {
|
if (barcodeProd.startsWith("0") || barcodeProd.startsWith("9")) {
|
||||||
barcodeProd = barcodeProd.substring(1, barcodeProd.length());
|
barcodeProd = barcodeProd.substring(1, barcodeProd.length());
|
||||||
}
|
}
|
||||||
@ -307,7 +309,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
progressDialog.dismiss();
|
progressDialog.dismiss();
|
||||||
BarcodeManager.enable();
|
BarcodeManager.enable();
|
||||||
}
|
}
|
||||||
}, ex-> {
|
}, ex -> {
|
||||||
UtilityExceptions.defaultException(mActivity, ex, progressDialog);
|
UtilityExceptions.defaultException(mActivity, ex, progressDialog);
|
||||||
BarcodeManager.enable();
|
BarcodeManager.enable();
|
||||||
});
|
});
|
||||||
@ -326,20 +328,19 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private void loadArticolo(String barcodeProd, Ean128Model ean128Model, Dialog progressDialog) {
|
private void loadArticolo(String barcodeProd, Ean128Model ean128Model, Dialog progressDialog) {
|
||||||
if(barcodeProd.length() == 14) {
|
if (barcodeProd.length() == 14) {
|
||||||
// barcodeProd = UtilityBarcode.convertITF14toNeutral(barcodeProd);
|
// barcodeProd = UtilityBarcode.convertITF14toNeutral(barcodeProd);
|
||||||
barcodeProd = UtilityBarcode.convertITF14toEAN13(barcodeProd);
|
barcodeProd = UtilityBarcode.convertITF14toEAN13(barcodeProd);
|
||||||
}
|
}
|
||||||
|
|
||||||
ArticoloRESTConsumer.getByBarcodeProd(barcodeProd, mtbAartList -> {
|
ArticoloRESTConsumer.getByBarcodeProd(barcodeProd, mtbAartList -> {
|
||||||
|
|
||||||
if(mtbAartList != null && mtbAartList.size() > 0) {
|
if (mtbAartList != null && mtbAartList.size() > 0) {
|
||||||
|
|
||||||
if(!thereIsAnOpenedUL()){
|
if (!thereIsAnOpenedUL()) {
|
||||||
|
|
||||||
if(SettingsManager.iDB().isFlagCanAutoOpenNewULAccettazione()) {
|
if (SettingsManager.iDB().isFlagCanAutoOpenNewULAccettazione()) {
|
||||||
this.createNewUL(null, null, progressDialog, false, () -> {
|
this.createNewUL(null, null, progressDialog, false, () -> {
|
||||||
BarcodeManager.enable();
|
BarcodeManager.enable();
|
||||||
this.searchArtInList(mtbAartList.get(0), ean128Model);
|
this.searchArtInList(mtbAartList.get(0), ean128Model);
|
||||||
@ -379,16 +380,16 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
List<OrdineAccettazioneDTO.Riga> foundRowsList = Stream.of(groupedOrdini)
|
List<OrdineAccettazioneDTO.Riga> foundRowsList = Stream.of(groupedOrdini)
|
||||||
.filter(x -> x.getMtbAart().getCodMart().equalsIgnoreCase(mtbAart.getCodMart()) &&
|
.filter(x -> x.getMtbAart().getCodMart().equalsIgnoreCase(mtbAart.getCodMart()) &&
|
||||||
(x.isHidden() != null && !x.isHidden()) && (x.isTempHidden() != null && !x.isTempHidden()))
|
(x.isHidden() != null && !x.isHidden()) && (x.isTempHidden() != null && !x.isTempHidden()))
|
||||||
.toList();
|
.toList();
|
||||||
|
|
||||||
if(foundRowsList.size() == 0) {
|
if (foundRowsList.size() == 0) {
|
||||||
showNoArtFoundDialog();
|
showNoArtFoundDialog();
|
||||||
} else if(foundRowsList.size() == 1) {
|
} else if (foundRowsList.size() == 1) {
|
||||||
onOrdineRowDispatch(foundRowsList.get(0), ean128Model);
|
onOrdineRowDispatch(foundRowsList.get(0), ean128Model);
|
||||||
} else {
|
} else {
|
||||||
for(int i = 0; i < groupedOrdini.size(); i++) {
|
for (int i = 0; i < groupedOrdini.size(); i++) {
|
||||||
if(!foundRowsList.contains(groupedOrdini.get(i))) {
|
if (!foundRowsList.contains(groupedOrdini.get(i))) {
|
||||||
groupedOrdini.get(i).setTempHidden(true);
|
groupedOrdini.get(i).setTempHidden(true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -415,7 +416,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
AlertDialog dialog = new AlertDialog.Builder(mActivity)
|
AlertDialog dialog = new AlertDialog.Builder(mActivity)
|
||||||
.setTitle(mActivity.getText(R.string.action_orderBy))
|
.setTitle(mActivity.getText(R.string.action_orderBy))
|
||||||
.setSingleChoiceItems(AccettazioneOrdineInevasoOrderBy.descriptions, currentOrderBy.getVal(), (dialog12, which) -> {
|
.setSingleChoiceItems(AccettazioneOrdineInevasoOrderBy.descriptions, currentOrderBy.getVal(), (dialog12, which) -> {
|
||||||
currentOrderBy = AccettazioneOrdineInevasoOrderBy.Enum.fromInt(which);
|
currentOrderBy = AccettazioneOrdineInevasoOrderBy.Enum.fromInt(which);
|
||||||
SettingsManager.i().userSession.defaultOrdinamentoPickingAccettazione = which;
|
SettingsManager.i().userSession.defaultOrdinamentoPickingAccettazione = which;
|
||||||
})
|
})
|
||||||
@ -433,7 +434,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
mActivity.bindings.accettazioneOrdineInevasoFab.close(true);
|
mActivity.bindings.accettazioneOrdineInevasoFab.close(true);
|
||||||
|
|
||||||
if (progress == null){
|
if (progress == null) {
|
||||||
progress = UtilityProgress.createDefaultProgressDialog(mActivity);
|
progress = UtilityProgress.createDefaultProgressDialog(mActivity);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -448,7 +449,8 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
GestSetupRESTConsumer.getValue("PICKING", "SETUP", "DEFAULT_POSIZIONE_COLLI_ACCETTAZIONE", defaultPosAccettazioneDTO -> {
|
GestSetupRESTConsumer.getValue("PICKING", "SETUP", "DEFAULT_POSIZIONE_COLLI_ACCETTAZIONE", defaultPosAccettazioneDTO -> {
|
||||||
|
|
||||||
String defaultPosAccettazione = "";
|
String defaultPosAccettazione = "";
|
||||||
if(defaultPosAccettazioneDTO != null && !UtilityString.isNullOrEmpty(defaultPosAccettazioneDTO.value)) defaultPosAccettazione = defaultPosAccettazioneDTO.value;
|
if (defaultPosAccettazioneDTO != null && !UtilityString.isNullOrEmpty(defaultPosAccettazioneDTO.value))
|
||||||
|
defaultPosAccettazione = defaultPosAccettazioneDTO.value;
|
||||||
|
|
||||||
MtbColt mtbColt = new MtbColt();
|
MtbColt mtbColt = new MtbColt();
|
||||||
mtbColt
|
mtbColt
|
||||||
@ -458,11 +460,11 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
.setPosizione(defaultPosAccettazione)
|
.setPosizione(defaultPosAccettazione)
|
||||||
.setOperation(CommonModelConsts.OPERATION.INSERT_OR_UPDATE);
|
.setOperation(CommonModelConsts.OPERATION.INSERT_OR_UPDATE);
|
||||||
|
|
||||||
if(customNumCollo != null) {
|
if (customNumCollo != null) {
|
||||||
mtbColt.setNumCollo(customNumCollo);
|
mtbColt.setNumCollo(customNumCollo);
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!UtilityString.isNullOrEmpty(customSerCollo)) {
|
if (!UtilityString.isNullOrEmpty(customSerCollo)) {
|
||||||
mtbColt.setSerCollo(customSerCollo);
|
mtbColt.setSerCollo(customSerCollo);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -472,7 +474,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
.distinct()
|
.distinct()
|
||||||
.toList();
|
.toList();
|
||||||
|
|
||||||
if(codAnags != null && codAnags.size() == 1){
|
if (codAnags != null && codAnags.size() == 1) {
|
||||||
mtbColt.setCodAnag(codAnags.get(0));
|
mtbColt.setCodAnag(codAnags.get(0));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -482,7 +484,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
.distinct()
|
.distinct()
|
||||||
.toList();
|
.toList();
|
||||||
|
|
||||||
if(rifOrds != null && rifOrds.size() == 1){
|
if (rifOrds != null && rifOrds.size() == 1) {
|
||||||
mtbColt.setRifOrd(rifOrds.get(0));
|
mtbColt.setRifOrd(rifOrds.get(0));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -492,7 +494,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
.distinct()
|
.distinct()
|
||||||
.toList();
|
.toList();
|
||||||
|
|
||||||
if(numDataOrds != null && numDataOrds.size() == 1){
|
if (numDataOrds != null && numDataOrds.size() == 1) {
|
||||||
mtbColt.setNumOrd(mOrders.get(0).getNumero());
|
mtbColt.setNumOrd(mOrders.get(0).getNumero());
|
||||||
mtbColt.setDataOrd(mOrders.get(0).getData());
|
mtbColt.setDataOrd(mOrders.get(0).getData());
|
||||||
|
|
||||||
@ -519,9 +521,9 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
finalProgress.dismiss();
|
finalProgress.dismiss();
|
||||||
|
|
||||||
FBToast.successToast(mActivity,mActivity.getResources().getString(R.string.data_saved) ,FBToast.LENGTH_SHORT);
|
FBToast.successToast(mActivity, mActivity.getResources().getString(R.string.data_saved), FBToast.LENGTH_SHORT);
|
||||||
|
|
||||||
if(onComplete != null) onComplete.run();
|
if (onComplete != null) onComplete.run();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -545,7 +547,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
private void setULToCurrentContext(MtbColt mtbColt){
|
private void setULToCurrentContext(MtbColt mtbColt) {
|
||||||
isFabVisible.set(false);
|
isFabVisible.set(false);
|
||||||
mArticoliInColloBottomSheetViewModel.mtbColt.set(mtbColt);
|
mArticoliInColloBottomSheetViewModel.mtbColt.set(mtbColt);
|
||||||
}
|
}
|
||||||
@ -574,14 +576,14 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onColloClosed(Runnable onComplete, boolean shouldPrint) {
|
public void onColloClosed(Runnable onComplete, boolean shouldPrint) {
|
||||||
if(thereIsAnOpenedUL()) {
|
if (thereIsAnOpenedUL()) {
|
||||||
|
|
||||||
final Dialog progress = UtilityProgress.createDefaultProgressDialog(mActivity);
|
final Dialog progress = UtilityProgress.createDefaultProgressDialog(mActivity);
|
||||||
progress.show();
|
progress.show();
|
||||||
|
|
||||||
if(thereIsAnyRowInUL()) {
|
if (thereIsAnyRowInUL()) {
|
||||||
updateDataFine(progress, () -> {
|
updateDataFine(progress, () -> {
|
||||||
if(shouldPrint) printCollo(progress, onComplete);
|
if (shouldPrint) printCollo(progress, onComplete);
|
||||||
else {
|
else {
|
||||||
postCloseOperations(onComplete);
|
postCloseOperations(onComplete);
|
||||||
progress.dismiss();
|
progress.dismiss();
|
||||||
@ -592,7 +594,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
if(onComplete != null) onComplete.run();
|
if (onComplete != null) onComplete.run();
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
@ -621,7 +623,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
private void printCollo(Dialog progress, Runnable onComplete) {
|
private void printCollo(Dialog progress, Runnable onComplete) {
|
||||||
MtbColt currentMtbColt = mArticoliInColloBottomSheetViewModel.mtbColt.get();
|
MtbColt currentMtbColt = mArticoliInColloBottomSheetViewModel.mtbColt.get();
|
||||||
|
|
||||||
if(currentMtbColt.getDisablePrint()){
|
if (currentMtbColt.getDisablePrint()) {
|
||||||
postCloseOperations(onComplete);
|
postCloseOperations(onComplete);
|
||||||
progress.dismiss();
|
progress.dismiss();
|
||||||
return;
|
return;
|
||||||
@ -629,49 +631,49 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
PrinterRESTConsumer.getAvailablePrinters(SettingsManager.i().userSession.depo.getCodMdep(), PrinterRESTConsumer.Type.SECONDARIA, value -> {
|
PrinterRESTConsumer.getAvailablePrinters(SettingsManager.i().userSession.depo.getCodMdep(), PrinterRESTConsumer.Type.SECONDARIA, value -> {
|
||||||
|
|
||||||
if(value.size() > 0) {
|
if (value.size() > 0) {
|
||||||
try{
|
try {
|
||||||
|
|
||||||
|
|
||||||
ReportManager.getRightReportNameByGestione(GestioneEnum.ACQUISTO, reportName -> {
|
ReportManager.getRightReportNameByGestione(GestioneEnum.ACQUISTO, reportName -> {
|
||||||
|
|
||||||
PrinterRESTConsumer.printCollo(
|
PrinterRESTConsumer.printCollo(
|
||||||
value.get(0),
|
value.get(0),
|
||||||
currentMtbColt,
|
currentMtbColt,
|
||||||
1, reportName, () -> {
|
1, reportName, () -> {
|
||||||
|
|
||||||
postCloseOperations(onComplete);
|
postCloseOperations(onComplete);
|
||||||
progress.dismiss();
|
progress.dismiss();
|
||||||
|
|
||||||
}, ex -> {
|
}, ex -> {
|
||||||
|
|
||||||
progress.dismiss();
|
progress.dismiss();
|
||||||
String errorMessage = ex.getMessage();
|
String errorMessage = ex.getMessage();
|
||||||
DialogSimpleMessageHelper.makeErrorDialog(
|
DialogSimpleMessageHelper.makeErrorDialog(
|
||||||
mActivity,
|
mActivity,
|
||||||
new SpannableString(errorMessage),
|
new SpannableString(errorMessage),
|
||||||
null,
|
null,
|
||||||
null,
|
null,
|
||||||
R.string.button_ignore_print,
|
R.string.button_ignore_print,
|
||||||
() -> postCloseOperations(onComplete)).show();
|
() -> postCloseOperations(onComplete)).show();
|
||||||
});
|
});
|
||||||
|
|
||||||
}, ex -> UtilityExceptions.defaultException(mActivity, ex, progress)
|
}, ex -> UtilityExceptions.defaultException(mActivity, ex, progress)
|
||||||
);
|
);
|
||||||
} catch (Exception ex){
|
} catch (Exception ex) {
|
||||||
UtilityExceptions.defaultException(mActivity, ex, progress);
|
UtilityExceptions.defaultException(mActivity, ex, progress);
|
||||||
}
|
|
||||||
} else {
|
|
||||||
resetUL();
|
|
||||||
isFabVisible.set(true);
|
|
||||||
|
|
||||||
progress.dismiss();
|
|
||||||
String errorMessage = "Nessuna stampante configurata";
|
|
||||||
DialogSimpleMessageHelper.makeWarningDialog(mActivity, new SpannableString(errorMessage), null, null).show();
|
|
||||||
}
|
}
|
||||||
}, ex -> {
|
} else {
|
||||||
UtilityExceptions.defaultException(mActivity, ex, progress);
|
resetUL();
|
||||||
});
|
isFabVisible.set(true);
|
||||||
|
|
||||||
|
progress.dismiss();
|
||||||
|
String errorMessage = "Nessuna stampante configurata";
|
||||||
|
DialogSimpleMessageHelper.makeWarningDialog(mActivity, new SpannableString(errorMessage), null, null).show();
|
||||||
|
}
|
||||||
|
}, ex -> {
|
||||||
|
UtilityExceptions.defaultException(mActivity, ex, progress);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -683,7 +685,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
isFabVisible.set(true);
|
isFabVisible.set(true);
|
||||||
|
|
||||||
progress.dismiss();
|
progress.dismiss();
|
||||||
if(onComplete != null) onComplete.run();
|
if (onComplete != null) onComplete.run();
|
||||||
}, ex -> UtilityExceptions.defaultException(mActivity, ex, progress));
|
}, ex -> UtilityExceptions.defaultException(mActivity, ex, progress));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -699,7 +701,6 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private void postCloseOperations(Runnable onComplete) {
|
private void postCloseOperations(Runnable onComplete) {
|
||||||
|
|
||||||
MtbColt mtbColt = (MtbColt) getColloRef().clone();
|
MtbColt mtbColt = (MtbColt) getColloRef().clone();
|
||||||
@ -708,18 +709,18 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
isFabVisible.set(true);
|
isFabVisible.set(true);
|
||||||
|
|
||||||
if(mtbColt != null && mtbColt.getMtbColr() != null) {
|
if (mtbColt != null && mtbColt.getMtbColr() != null) {
|
||||||
for (int i = 0; i < mtbColt.getMtbColr().size(); i++) {
|
for (int i = 0; i < mtbColt.getMtbColr().size(); i++) {
|
||||||
|
|
||||||
MtbColr currentRow = mtbColt.getMtbColr().get(i);
|
MtbColr currentRow = mtbColt.getMtbColr().get(i);
|
||||||
|
|
||||||
if(currentRow.getRigaOrd() != null) {
|
if (currentRow.getRigaOrd() != null) {
|
||||||
|
|
||||||
for(int k = 0; k < this.groupedOrdini.size(); k++) {
|
for (int k = 0; k < this.groupedOrdini.size(); k++) {
|
||||||
|
|
||||||
OrdineAccettazioneDTO.Riga x = this.groupedOrdini.get(k);
|
OrdineAccettazioneDTO.Riga x = this.groupedOrdini.get(k);
|
||||||
|
|
||||||
if(x.getQtaDaEvadere().floatValue() > 0 &&
|
if (x.getQtaDaEvadere().floatValue() > 0 &&
|
||||||
x.getMtbAart().getCodMart().equalsIgnoreCase(currentRow.getCodMart()) &&
|
x.getMtbAart().getCodMart().equalsIgnoreCase(currentRow.getCodMart()) &&
|
||||||
x.getCodJcom().equalsIgnoreCase(currentRow.getCodJcom()) &&
|
x.getCodJcom().equalsIgnoreCase(currentRow.getCodJcom()) &&
|
||||||
x.getRigaOrd() == currentRow.getRigaOrd() &&
|
x.getRigaOrd() == currentRow.getRigaOrd() &&
|
||||||
@ -753,13 +754,13 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
removeListFilter();
|
removeListFilter();
|
||||||
refreshOrderBy(true);
|
refreshOrderBy(true);
|
||||||
|
|
||||||
if(onComplete != null) onComplete.run();
|
if (onComplete != null) onComplete.run();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onOrdineRowDispatch(final OrdineAccettazioneDTO.Riga item, Ean128Model ean128Model) {
|
public void onOrdineRowDispatch(final OrdineAccettazioneDTO.Riga item, Ean128Model ean128Model) {
|
||||||
if(getColloRef() != null){
|
if (getColloRef() != null) {
|
||||||
|
|
||||||
List<MtbColr> currentMtbColrs = getColloRef().getMtbColr();
|
List<MtbColr> currentMtbColrs = getColloRef().getMtbColr();
|
||||||
|
|
||||||
@ -777,14 +778,13 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
float qtaEvasa = item.qtaRiservate + qtaEvasaInMtbColr;
|
float qtaEvasa = item.qtaRiservate + qtaEvasaInMtbColr;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
BigDecimal qtaDaEvadere;
|
BigDecimal qtaDaEvadere;
|
||||||
|
|
||||||
BigDecimal totalQtaDaEvadere = item.getQtaOrd().subtract(new BigDecimal(qtaEvasa)).subtract(item.getQtaEvasa());
|
BigDecimal totalQtaDaEvadere = item.getQtaOrd().subtract(new BigDecimal(qtaEvasa)).subtract(item.getQtaEvasa());
|
||||||
|
|
||||||
BigDecimal qtaColliPedana = item.mtbAart.getColliPedana().multiply(item.mtbAart.getQtaCnf());
|
BigDecimal qtaColliPedana = item.mtbAart.getColliPedana().multiply(item.mtbAart.getQtaCnf());
|
||||||
|
|
||||||
if(qtaColliPedana.floatValue() > 0 && qtaColliPedana.compareTo(totalQtaDaEvadere) <= 0) {
|
if (qtaColliPedana.floatValue() > 0 && qtaColliPedana.compareTo(totalQtaDaEvadere) <= 0) {
|
||||||
qtaDaEvadere = qtaColliPedana;
|
qtaDaEvadere = qtaColliPedana;
|
||||||
} else {
|
} else {
|
||||||
qtaDaEvadere = totalQtaDaEvadere;
|
qtaDaEvadere = totalQtaDaEvadere;
|
||||||
@ -799,15 +799,15 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
.setQtaEvasa(new BigDecimal(qtaEvasa))
|
.setQtaEvasa(new BigDecimal(qtaEvasa))
|
||||||
.setCanPartitaMagBeChanged(true);
|
.setCanPartitaMagBeChanged(true);
|
||||||
|
|
||||||
if(ean128Model != null){
|
if (ean128Model != null) {
|
||||||
if(!UtilityString.isNullOrEmpty(ean128Model.BatchLot)) {
|
if (!UtilityString.isNullOrEmpty(ean128Model.BatchLot)) {
|
||||||
dto.setBatchLot(ean128Model.BatchLot);
|
dto.setBatchLot(ean128Model.BatchLot);
|
||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
if(!UtilityString.isNullOrEmpty(ean128Model.BestBefore)){
|
if (!UtilityString.isNullOrEmpty(ean128Model.BestBefore)) {
|
||||||
dto.setDataScad(UtilityDate.recognizeDate(ean128Model.BestBefore));
|
dto.setDataScad(UtilityDate.recognizeDate(ean128Model.BestBefore));
|
||||||
} else if(!UtilityString.isNullOrEmpty(ean128Model.Expiry)) {
|
} else if (!UtilityString.isNullOrEmpty(ean128Model.Expiry)) {
|
||||||
dto.setDataScad(UtilityDate.recognizeDate(ean128Model.Expiry));
|
dto.setDataScad(UtilityDate.recognizeDate(ean128Model.Expiry));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -816,13 +816,13 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
if(ean128Model.Count != null && ean128Model.Count > 0) {
|
if (ean128Model.Count != null && ean128Model.Count > 0) {
|
||||||
//if(!UtilityString.isNullOrEmpty(ean128Model.Sscc)) {
|
//if(!UtilityString.isNullOrEmpty(ean128Model.Sscc)) {
|
||||||
dto.setQtaTot(new BigDecimal(ean128Model.Count));
|
dto.setQtaTot(new BigDecimal(ean128Model.Count));
|
||||||
|
|
||||||
if(!item.getMtbAart().isFlagQtaCnfFissa()) {
|
if (!item.getMtbAart().isFlagQtaCnfFissa()) {
|
||||||
dto.setQtaCnf(new BigDecimal(ean128Model.Count));
|
dto.setQtaCnf(new BigDecimal(ean128Model.Count));
|
||||||
}
|
}
|
||||||
//} else {
|
//} else {
|
||||||
// dto.setQtaTot(new BigDecimal(ean128Model.Count));
|
// dto.setQtaTot(new BigDecimal(ean128Model.Count));
|
||||||
//}
|
//}
|
||||||
@ -832,7 +832,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
dto.setQtaTot(new BigDecimal(ean128Model.NetWeightKg));
|
dto.setQtaTot(new BigDecimal(ean128Model.NetWeightKg));
|
||||||
}
|
}
|
||||||
|
|
||||||
if(dto.getQtaTot() != null && dto.getQtaTot().floatValue() > 0 && dto.getNumCnf() != null && dto.getNumCnf() > 0) {
|
if (dto.getQtaTot() != null && dto.getQtaTot().floatValue() > 0 && dto.getNumCnf() != null && dto.getNumCnf() > 0) {
|
||||||
dto.setQtaCnf(dto.getQtaTot().divide(new BigDecimal(dto.getNumCnf())));
|
dto.setQtaCnf(dto.getQtaTot().divide(new BigDecimal(dto.getNumCnf())));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -841,11 +841,11 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
dto.setShouldAskDataScad(true);
|
dto.setShouldAskDataScad(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
DialogInputQuantity.makeBase(mActivity, dto, true, (quantityDTO, closeLU) -> onOrdineRowDispatched(item, quantityDTO, closeLU), null).show();
|
DialogInputQuantity.makeBase(mActivity, dto, true, (quantityDTO, closeLU) -> onOrdineRowDispatched(item, quantityDTO, closeLU), null).show();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private void onOrdineRowDispatched(OrdineAccettazioneDTO.Riga item, QuantityDTO quantityDTO, boolean closeLU){
|
private void onOrdineRowDispatched(OrdineAccettazioneDTO.Riga item, QuantityDTO quantityDTO, boolean closeLU) {
|
||||||
final Dialog progress = UtilityProgress.createDefaultProgressDialog(mActivity);
|
final Dialog progress = UtilityProgress.createDefaultProgressDialog(mActivity);
|
||||||
|
|
||||||
String gestioneRif = item.getGestioneOrdEnum() == GestioneEnum.PRODUZIONE ? "L" : item.getGestioneOrd();
|
String gestioneRif = item.getGestioneOrdEnum() == GestioneEnum.PRODUZIONE ? "L" : item.getGestioneOrd();
|
||||||
@ -863,7 +863,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
.setCodJcom(item.getCodJcom())
|
.setCodJcom(item.getCodJcom())
|
||||||
.setRigaOrd(item.getRigaOrd());
|
.setRigaOrd(item.getRigaOrd());
|
||||||
|
|
||||||
if(!item.getMtbAart().isFlagQtaCnfFissa()) {
|
if (!item.getMtbAart().isFlagQtaCnfFissa()) {
|
||||||
mtbColr.setQtaCnf(quantityDTO.qtaCnf.getBigDecimal());
|
mtbColr.setQtaCnf(quantityDTO.qtaCnf.getBigDecimal());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -896,7 +896,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
FBToast.successToast(mActivity, mActivity.getResources().getString(R.string.data_saved), FBToast.LENGTH_SHORT);
|
FBToast.successToast(mActivity, mActivity.getResources().getString(R.string.data_saved), FBToast.LENGTH_SHORT);
|
||||||
progress.dismiss();
|
progress.dismiss();
|
||||||
|
|
||||||
if(closeLU) onColloClosed(null, true);
|
if (closeLU) onColloClosed(null, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -908,7 +908,6 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private MtbColt getColloRef() {
|
private MtbColt getColloRef() {
|
||||||
return mArticoliInColloBottomSheetViewModel.mtbColt.get();
|
return mArticoliInColloBottomSheetViewModel.mtbColt.get();
|
||||||
}
|
}
|
||||||
@ -919,33 +918,37 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
private void onRowEdited(MtbColr oldValue, MtbColr newValue) {
|
private void onRowEdited(MtbColr oldValue, MtbColr newValue) {
|
||||||
|
|
||||||
if(getColloRef() != null) {
|
// if (getColloRef() != null) {
|
||||||
|
//
|
||||||
Dialog progress = UtilityProgress.createDefaultProgressDialog(mActivity);
|
// Dialog progress = UtilityProgress.createDefaultProgressDialog(mActivity);
|
||||||
|
//
|
||||||
MtbColr mtbColrToEditOfAccettazione = Stream.of(getColloRef().getMtbColr())
|
// Optional<MtbColr> optionalMtbColrToEditOfAccettazione = Stream.of(getColloRef().getMtbColr())
|
||||||
.filter(x -> x.getQtaCol().compareTo(oldValue.getQtaCol()) == 0 &&
|
// .filter(x -> UtilityBigDecimal.equalsTo(x.getQtaCol(), oldValue.getQtaCol()) &&
|
||||||
x.getCodMart().equalsIgnoreCase(oldValue.getCodMart()) &&
|
// UtilityString.equalsIgnoreCase(x.getCodMart(), oldValue.getCodMart()) &&
|
||||||
x.getPartitaMag().equalsIgnoreCase(oldValue.getPartitaMag()) &&
|
// UtilityString.equalsIgnoreCase(x.getPartitaMag(), oldValue.getPartitaMag()) &&
|
||||||
x.getCodJcom().equalsIgnoreCase(oldValue.getCodJcom()))
|
// UtilityString.equalsIgnoreCase(x.getCodJcom(), oldValue.getCodJcom()))
|
||||||
.findFirst()
|
// .findFirst();
|
||||||
.get();
|
//
|
||||||
|
// if(optionalMtbColrToEditOfAccettazione.isPresent()) {
|
||||||
mtbColrToEditOfAccettazione
|
// MtbColr mtbColrToEditOfAccettazione = optionalMtbColrToEditOfAccettazione.get();
|
||||||
.setQtaCol(newValue.getQtaCol());
|
//
|
||||||
|
// mtbColrToEditOfAccettazione
|
||||||
ColliMagazzinoRESTConsumer.updateRiga(mtbColrToEditOfAccettazione, () -> {
|
// .setQtaCol(newValue.getQtaCol());
|
||||||
progress.dismiss();
|
//
|
||||||
this.refreshOrderBy(false);
|
// ColliMagazzinoRESTConsumer.updateRiga(mtbColrToEditOfAccettazione, () -> {
|
||||||
}, ex -> {
|
// progress.dismiss();
|
||||||
UtilityExceptions.defaultException(mActivity, ex, progress);
|
// this.refreshOrderBy(false);
|
||||||
this.refreshOrderBy(false);
|
// }, ex -> {
|
||||||
});
|
// UtilityExceptions.defaultException(mActivity, ex, progress);
|
||||||
|
// this.refreshOrderBy(false);
|
||||||
} else {
|
// });
|
||||||
|
//
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// } else {
|
||||||
|
//
|
||||||
this.refreshOrderBy(false);
|
this.refreshOrderBy(false);
|
||||||
}
|
// }
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -975,7 +978,7 @@ public class AccettazioneOrdineAccettazioneInevasoViewModel implements IOnColloC
|
|||||||
|
|
||||||
// } else {
|
// } else {
|
||||||
|
|
||||||
this.refreshOrderBy(false);
|
this.refreshOrderBy(false);
|
||||||
// }
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user