Migliorato servizio di importColliDaProduzione
This commit is contained in:
parent
a27db0ab68
commit
2b467f56d7
@ -20,12 +20,10 @@ import androidx.recyclerview.widget.LinearLayoutManager;
|
|||||||
|
|
||||||
import com.annimon.stream.ComparatorCompat;
|
import com.annimon.stream.ComparatorCompat;
|
||||||
import com.annimon.stream.Stream;
|
import com.annimon.stream.Stream;
|
||||||
import com.google.gson.reflect.TypeToken;
|
|
||||||
import com.harrysoft.androidbluetoothserial.BluetoothManager;
|
import com.harrysoft.androidbluetoothserial.BluetoothManager;
|
||||||
import com.harrysoft.androidbluetoothserial.BluetoothSerialDevice;
|
import com.harrysoft.androidbluetoothserial.BluetoothSerialDevice;
|
||||||
|
|
||||||
import java.math.BigDecimal;
|
import java.math.BigDecimal;
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import javax.inject.Inject;
|
import javax.inject.Inject;
|
||||||
@ -38,12 +36,10 @@ import it.integry.integrywmsnative.core.exception.BluetoothConnectionException;
|
|||||||
import it.integry.integrywmsnative.core.expansion.AtomicBigDecimal;
|
import it.integry.integrywmsnative.core.expansion.AtomicBigDecimal;
|
||||||
import it.integry.integrywmsnative.core.expansion.BaseFragment;
|
import it.integry.integrywmsnative.core.expansion.BaseFragment;
|
||||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||||
import it.integry.integrywmsnative.core.model.DtbOrdSteps;
|
|
||||||
import it.integry.integrywmsnative.core.model.MtbColr;
|
import it.integry.integrywmsnative.core.model.MtbColr;
|
||||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.ArticoloRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.ArticoloRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.SystemRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.SystemRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityDB;
|
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityString;
|
import it.integry.integrywmsnative.core.utility.UtilityString;
|
||||||
import it.integry.integrywmsnative.databinding.FragmentProdRientroMerceOrderDetailBinding;
|
import it.integry.integrywmsnative.databinding.FragmentProdRientroMerceOrderDetailBinding;
|
||||||
import it.integry.integrywmsnative.gest.prod_versamento_materiale.dto.OrdineLavorazioneDTO;
|
import it.integry.integrywmsnative.gest.prod_versamento_materiale.dto.OrdineLavorazioneDTO;
|
||||||
@ -201,7 +197,7 @@ public class ProdRientroMerceOrderDetailFragment extends BaseFragment implements
|
|||||||
private void refreshOrder() {
|
private void refreshOrder() {
|
||||||
OrdineLavorazioneDTO currentOrd = currentOrder.getValue();
|
OrdineLavorazioneDTO currentOrd = currentOrder.getValue();
|
||||||
|
|
||||||
if(currentOrd != null) {
|
if (currentOrd != null) {
|
||||||
isOrderColli.set(currentOrd.getQtaCnf().compareTo(BigDecimal.ONE) == 0);
|
isOrderColli.set(currentOrd.getQtaCnf().compareTo(BigDecimal.ONE) == 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -277,26 +273,8 @@ public class ProdRientroMerceOrderDetailFragment extends BaseFragment implements
|
|||||||
this.onError(new Exception("Nessun ordine rilevato!"));
|
this.onError(new Exception("Nessun ordine rilevato!"));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
String codProd = currentOrder.getCodProd();
|
|
||||||
mArticoloRESTConsumer.getByCodMart(codProd, mtbAart -> {
|
|
||||||
|
|
||||||
String sql = "SELECT TOP 1 * " +
|
|
||||||
"FROM ( " +
|
|
||||||
" SELECT MAX(id_step) OVER ( PARTITION BY gestione, num_ord, data_ord) as last_step, " +
|
|
||||||
" * " +
|
|
||||||
" FROM dtb_ord_steps " +
|
|
||||||
" WHERE cod_jfas IS NOT NULL " +
|
|
||||||
" AND gestione = " + UtilityDB.valueToString(currentOrder.getGestione()) +
|
|
||||||
" AND num_ord = " + UtilityDB.valueToString(currentOrder.getNumOrd()) +
|
|
||||||
" AND data_ord = " + UtilityDB.valueToString(currentOrder.getDataOrdD()) +
|
|
||||||
" ) tmp " +
|
|
||||||
"WHERE data_iniz IS NOT NULL " +
|
|
||||||
" AND (data_fine IS NULL OR last_step = id_step) " +
|
|
||||||
"ORDER BY id_step DESC";
|
|
||||||
|
|
||||||
mSystemRESTConsumer.<List<DtbOrdSteps>>processSql(sql, new TypeToken<ArrayList<DtbOrdSteps>>() {
|
|
||||||
}.getType(), dtbOrdStep -> {
|
|
||||||
|
|
||||||
|
mViewModel.retrieveOrderData((mtbAart, codJfas) -> {
|
||||||
this.onLoadingEnded();
|
this.onLoadingEnded();
|
||||||
|
|
||||||
String codTcol = currentOrder.getCodTcolUl();
|
String codTcol = currentOrder.getCodTcolUl();
|
||||||
@ -317,30 +295,50 @@ public class ProdRientroMerceOrderDetailFragment extends BaseFragment implements
|
|||||||
.setDataScad(currentOrder.getDataScadD())
|
.setDataScad(currentOrder.getDataScadD())
|
||||||
.setCodJfasParent(currentOrder.getCodJfas())
|
.setCodJfasParent(currentOrder.getCodJfas())
|
||||||
.setCodTcol(codTcol)
|
.setCodTcol(codTcol)
|
||||||
.setSuggestedCodJfas(dtbOrdStep != null && dtbOrdStep.size() > 0 ? dtbOrdStep.get(0).getCodJfas() : null);
|
.setSuggestedCodJfas(codJfas);
|
||||||
|
|
||||||
|
|
||||||
DialogInputLUProdView
|
DialogInputLUProdView
|
||||||
.newInstance(mConnectedBluetoothDevice != null ? mConnectedBluetoothDevice.toSimpleDeviceInterface() : null, dialogInputLUProdDTO, resultDTO -> {
|
.newInstance(mConnectedBluetoothDevice != null ? mConnectedBluetoothDevice.toSimpleDeviceInterface() : null, dialogInputLUProdDTO, resultDTO -> {
|
||||||
ProdRientroMerceOrderDetailPickedQuantityDTO pickedQuantityDTO = new ProdRientroMerceOrderDetailPickedQuantityDTO()
|
ProdRientroMerceOrderDetailPickedQuantityDTO pickedQuantityDTO = new ProdRientroMerceOrderDetailPickedQuantityDTO()
|
||||||
.setNumCnf(resultDTO.getNumCnf())
|
.setNumCnf(resultDTO.getNumCnf())
|
||||||
|
.setQtaCnf(resultDTO.getPesoCollo())
|
||||||
|
.setQtaCol(resultDTO.getPesoNetto())
|
||||||
.setPesoCollo(resultDTO.getPesoCollo())
|
.setPesoCollo(resultDTO.getPesoCollo())
|
||||||
.setPesoNetto(resultDTO.getPesoNetto())
|
.setPesoNetto(resultDTO.getPesoNetto())
|
||||||
.setTaraPed(resultDTO.getTaraPed())
|
.setTaraPed(resultDTO.getTaraPed())
|
||||||
.setTaraCol(resultDTO.getTaraCol())
|
.setTaraCol(resultDTO.getTaraCol())
|
||||||
.setPesoLordo(resultDTO.getPesoLordo())
|
.setPesoLordo(resultDTO.getPesoLordo())
|
||||||
.setMtbTCol(resultDTO.getMtbTCol())
|
.setMtbTCol(resultDTO.getMtbTCol())
|
||||||
.setJtbFasi(resultDTO.getJtbFasi());
|
.setCodJfas(resultDTO.getJtbFasi() != null ? resultDTO.getJtbFasi().getCodJfas() : codJfas);
|
||||||
|
|
||||||
this.mViewModel.createLU(pickedQuantityDTO);
|
this.mViewModel.createLU(pickedQuantityDTO);
|
||||||
}, () -> {
|
}, this::onLoadingEnded)
|
||||||
this.onLoadingEnded();
|
|
||||||
})
|
|
||||||
.show(requireActivity().getSupportFragmentManager(), "tag");
|
.show(requireActivity().getSupportFragmentManager(), "tag");
|
||||||
|
|
||||||
}, this::onError);
|
});
|
||||||
|
}
|
||||||
|
|
||||||
}, this::onError);
|
public void addSingleUnitButtonClick() {
|
||||||
|
this.onLoadingStarted();
|
||||||
|
|
||||||
|
OrdineLavorazioneDTO currentOrder = this.currentOrder.getValue();
|
||||||
|
if (currentOrder == null) {
|
||||||
|
this.onError(new Exception("Nessun ordine rilevato!"));
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
mViewModel.retrieveOrderData((mtbAart, codJfas) -> {
|
||||||
|
ProdRientroMerceOrderDetailPickedQuantityDTO pickedQuantityDTO = new ProdRientroMerceOrderDetailPickedQuantityDTO()
|
||||||
|
.setNumCnf(BigDecimal.ONE)
|
||||||
|
.setQtaCnf(currentOrder.getQtaCnf())
|
||||||
|
.setQtaCol(currentOrder.getQtaCnf())
|
||||||
|
.setCodJfas(codJfas);
|
||||||
|
|
||||||
|
|
||||||
|
this.mViewModel.createLU(pickedQuantityDTO);
|
||||||
|
|
||||||
|
this.onLoadingEnded();
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
public ProdRientroMerceOrderDetailFragment setOnMtbColtClicked(RunnableArgs<MtbColt> onMtbColtClicked) {
|
public ProdRientroMerceOrderDetailFragment setOnMtbColtClicked(RunnableArgs<MtbColt> onMtbColtClicked) {
|
||||||
@ -409,7 +407,7 @@ public class ProdRientroMerceOrderDetailFragment extends BaseFragment implements
|
|||||||
|
|
||||||
public Drawable getUntMisIcon() {
|
public Drawable getUntMisIcon() {
|
||||||
if (currentOrder.getValue() != null) {
|
if (currentOrder.getValue() != null) {
|
||||||
if(currentOrder.getValue().getUntOrd().equalsIgnoreCase("KG"))
|
if (currentOrder.getValue().getUntOrd().equalsIgnoreCase("KG"))
|
||||||
return ContextCompat.getDrawable(requireActivity(), R.drawable.ic_weight_kg);
|
return ContextCompat.getDrawable(requireActivity(), R.drawable.ic_weight_kg);
|
||||||
else
|
else
|
||||||
return ContextCompat.getDrawable(requireActivity(), R.drawable.ic_puzzle);
|
return ContextCompat.getDrawable(requireActivity(), R.drawable.ic_puzzle);
|
||||||
|
|||||||
@ -2,6 +2,7 @@ package it.integry.integrywmsnative.gest.prod_rientro_merce.order_detail;
|
|||||||
|
|
||||||
import dagger.Module;
|
import dagger.Module;
|
||||||
import dagger.Provides;
|
import dagger.Provides;
|
||||||
|
import it.integry.integrywmsnative.core.rest.consumers.ArticoloRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.ColliMagazzinoRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.ColliMagazzinoRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.PrinterRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.PrinterRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.SystemRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.SystemRESTConsumer;
|
||||||
@ -19,8 +20,10 @@ public class ProdRientroMerceOrderDetailModule {
|
|||||||
ProdRientroMerceOrderDetailViewModel provideProdRientroMerceOrderDetailViewModel(
|
ProdRientroMerceOrderDetailViewModel provideProdRientroMerceOrderDetailViewModel(
|
||||||
ProdRientroMerceOrderDetailRESTConsumer prodRientroMerceOrderDetailRESTConsumer,
|
ProdRientroMerceOrderDetailRESTConsumer prodRientroMerceOrderDetailRESTConsumer,
|
||||||
ColliMagazzinoRESTConsumer colliMagazzinoRESTConsumer,
|
ColliMagazzinoRESTConsumer colliMagazzinoRESTConsumer,
|
||||||
PrinterRESTConsumer printerRESTConsumer) {
|
PrinterRESTConsumer printerRESTConsumer,
|
||||||
return new ProdRientroMerceOrderDetailViewModel(prodRientroMerceOrderDetailRESTConsumer, colliMagazzinoRESTConsumer, printerRESTConsumer);
|
ArticoloRESTConsumer articoloRESTConsumer,
|
||||||
|
SystemRESTConsumer systemRESTConsumer) {
|
||||||
|
return new ProdRientroMerceOrderDetailViewModel(prodRientroMerceOrderDetailRESTConsumer, colliMagazzinoRESTConsumer, printerRESTConsumer, articoloRESTConsumer, systemRESTConsumer);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -8,14 +8,16 @@ import it.integry.integrywmsnative.core.model.MtbTCol;
|
|||||||
public class ProdRientroMerceOrderDetailPickedQuantityDTO {
|
public class ProdRientroMerceOrderDetailPickedQuantityDTO {
|
||||||
|
|
||||||
private BigDecimal numCnf;
|
private BigDecimal numCnf;
|
||||||
|
private BigDecimal qtaCnf;
|
||||||
|
private BigDecimal qtaCol;
|
||||||
private BigDecimal pesoCollo;
|
private BigDecimal pesoCollo;
|
||||||
private BigDecimal pesoNetto;
|
private BigDecimal pesoNetto;
|
||||||
private BigDecimal taraPed;
|
private BigDecimal taraPed;
|
||||||
private BigDecimal taraCol;
|
private BigDecimal taraCol;
|
||||||
private BigDecimal pesoLordo;
|
private BigDecimal pesoLordo;
|
||||||
|
private String codJfas;
|
||||||
|
|
||||||
private MtbTCol mtbTCol;
|
private MtbTCol mtbTCol;
|
||||||
private JtbFasi jtbFasi;
|
|
||||||
|
|
||||||
public BigDecimal getNumCnf() {
|
public BigDecimal getNumCnf() {
|
||||||
return numCnf;
|
return numCnf;
|
||||||
@ -26,6 +28,24 @@ public class ProdRientroMerceOrderDetailPickedQuantityDTO {
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public BigDecimal getQtaCnf() {
|
||||||
|
return qtaCnf;
|
||||||
|
}
|
||||||
|
|
||||||
|
public ProdRientroMerceOrderDetailPickedQuantityDTO setQtaCnf(BigDecimal qtaCnf) {
|
||||||
|
this.qtaCnf = qtaCnf;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public BigDecimal getQtaCol() {
|
||||||
|
return qtaCol;
|
||||||
|
}
|
||||||
|
|
||||||
|
public ProdRientroMerceOrderDetailPickedQuantityDTO setQtaCol(BigDecimal qtaCol) {
|
||||||
|
this.qtaCol = qtaCol;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public BigDecimal getPesoCollo() {
|
public BigDecimal getPesoCollo() {
|
||||||
return pesoCollo;
|
return pesoCollo;
|
||||||
}
|
}
|
||||||
@ -71,6 +91,15 @@ public class ProdRientroMerceOrderDetailPickedQuantityDTO {
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getCodJfas() {
|
||||||
|
return codJfas;
|
||||||
|
}
|
||||||
|
|
||||||
|
public ProdRientroMerceOrderDetailPickedQuantityDTO setCodJfas(String codJfas) {
|
||||||
|
this.codJfas = codJfas;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
public MtbTCol getMtbTCol() {
|
public MtbTCol getMtbTCol() {
|
||||||
return mtbTCol;
|
return mtbTCol;
|
||||||
}
|
}
|
||||||
@ -79,13 +108,4 @@ public class ProdRientroMerceOrderDetailPickedQuantityDTO {
|
|||||||
this.mtbTCol = mtbTCol;
|
this.mtbTCol = mtbTCol;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public JtbFasi getJtbFasi() {
|
|
||||||
return jtbFasi;
|
|
||||||
}
|
|
||||||
|
|
||||||
public ProdRientroMerceOrderDetailPickedQuantityDTO setJtbFasi(JtbFasi jtbFasi) {
|
|
||||||
this.jtbFasi = jtbFasi;
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -2,22 +2,30 @@ package it.integry.integrywmsnative.gest.prod_rientro_merce.order_detail;
|
|||||||
|
|
||||||
import androidx.lifecycle.MutableLiveData;
|
import androidx.lifecycle.MutableLiveData;
|
||||||
|
|
||||||
import com.annimon.stream.Optional;
|
import com.google.gson.reflect.TypeToken;
|
||||||
import com.annimon.stream.Stream;
|
|
||||||
|
|
||||||
import java.time.LocalDate;
|
import java.time.LocalDate;
|
||||||
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
import java.util.Objects;
|
||||||
|
import java.util.Optional;
|
||||||
|
|
||||||
import javax.inject.Inject;
|
import javax.inject.Inject;
|
||||||
|
|
||||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||||
|
import it.integry.integrywmsnative.core.expansion.RunnableArgss;
|
||||||
import it.integry.integrywmsnative.core.interfaces.viewmodel_listeners.ILoadingListener;
|
import it.integry.integrywmsnative.core.interfaces.viewmodel_listeners.ILoadingListener;
|
||||||
|
import it.integry.integrywmsnative.core.model.DtbOrdSteps;
|
||||||
|
import it.integry.integrywmsnative.core.model.MtbAart;
|
||||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||||
import it.integry.integrywmsnative.core.report.ReportType;
|
import it.integry.integrywmsnative.core.report.ReportType;
|
||||||
|
import it.integry.integrywmsnative.core.rest.consumers.ArticoloRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.ColliMagazzinoRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.ColliMagazzinoRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.PrinterRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.PrinterRESTConsumer;
|
||||||
|
import it.integry.integrywmsnative.core.rest.consumers.SystemRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
||||||
|
import it.integry.integrywmsnative.core.utility.UtilityDB;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityDate;
|
import it.integry.integrywmsnative.core.utility.UtilityDate;
|
||||||
import it.integry.integrywmsnative.gest.prod_rientro_merce.order_detail.rest.ProdRientroMerceOrderDetailRESTConsumer;
|
import it.integry.integrywmsnative.gest.prod_rientro_merce.order_detail.rest.ProdRientroMerceOrderDetailRESTConsumer;
|
||||||
import it.integry.integrywmsnative.gest.prod_rientro_merce.order_detail.rest.dto.ImportColliDaProduzioneRequestDTO;
|
import it.integry.integrywmsnative.gest.prod_rientro_merce.order_detail.rest.dto.ImportColliDaProduzioneRequestDTO;
|
||||||
@ -29,19 +37,25 @@ public class ProdRientroMerceOrderDetailViewModel {
|
|||||||
public final MutableLiveData<List<MtbColt>> mtbColtsOfOrder = new MutableLiveData<>();
|
public final MutableLiveData<List<MtbColt>> mtbColtsOfOrder = new MutableLiveData<>();
|
||||||
private OrdineLavorazioneDTO currentOrder;
|
private OrdineLavorazioneDTO currentOrder;
|
||||||
|
|
||||||
private final ProdRientroMerceOrderDetailRESTConsumer mProdRientroMerceOrderDetailRESTConsumer;
|
private final ProdRientroMerceOrderDetailRESTConsumer prodRientroMerceOrderDetailRESTConsumer;
|
||||||
private final ColliMagazzinoRESTConsumer mColliMagazzinoRESTConsumer;
|
private final ColliMagazzinoRESTConsumer colliMagazzinoRESTConsumer;
|
||||||
private final PrinterRESTConsumer mPrinterRESTConsumer;
|
private final PrinterRESTConsumer printerRESTConsumer;
|
||||||
|
private final ArticoloRESTConsumer articoloRESTConsumer;
|
||||||
|
private final SystemRESTConsumer systemRESTConsumer;
|
||||||
|
|
||||||
private Listener mListener;
|
private Listener mListener;
|
||||||
|
|
||||||
@Inject
|
@Inject
|
||||||
public ProdRientroMerceOrderDetailViewModel(ProdRientroMerceOrderDetailRESTConsumer prodRientroMerceOrderDetailRESTConsumer,
|
public ProdRientroMerceOrderDetailViewModel(ProdRientroMerceOrderDetailRESTConsumer prodRientroMerceOrderDetailRESTConsumer,
|
||||||
ColliMagazzinoRESTConsumer colliMagazzinoRESTConsumer,
|
ColliMagazzinoRESTConsumer colliMagazzinoRESTConsumer,
|
||||||
PrinterRESTConsumer printerRESTConsumer) {
|
PrinterRESTConsumer printerRESTConsumer,
|
||||||
this.mProdRientroMerceOrderDetailRESTConsumer = prodRientroMerceOrderDetailRESTConsumer;
|
ArticoloRESTConsumer articoloRESTConsumer,
|
||||||
this.mColliMagazzinoRESTConsumer = colliMagazzinoRESTConsumer;
|
SystemRESTConsumer systemRESTConsumer) {
|
||||||
this.mPrinterRESTConsumer = printerRESTConsumer;
|
this.prodRientroMerceOrderDetailRESTConsumer = prodRientroMerceOrderDetailRESTConsumer;
|
||||||
|
this.colliMagazzinoRESTConsumer = colliMagazzinoRESTConsumer;
|
||||||
|
this.printerRESTConsumer = printerRESTConsumer;
|
||||||
|
this.articoloRESTConsumer = articoloRESTConsumer;
|
||||||
|
this.systemRESTConsumer = systemRESTConsumer;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setOrder(OrdineLavorazioneDTO order) {
|
public void setOrder(OrdineLavorazioneDTO order) {
|
||||||
@ -54,7 +68,7 @@ public class ProdRientroMerceOrderDetailViewModel {
|
|||||||
this.sendOnLoadingStarted();
|
this.sendOnLoadingStarted();
|
||||||
this.mtbColtsOfOrder.postValue(null);
|
this.mtbColtsOfOrder.postValue(null);
|
||||||
|
|
||||||
this.mProdRientroMerceOrderDetailRESTConsumer.getMtbColtsOfOrder(currentOrder, mtbColts -> {
|
this.prodRientroMerceOrderDetailRESTConsumer.getMtbColtsOfOrder(currentOrder, mtbColts -> {
|
||||||
for (MtbColt mtbColt : mtbColts) {
|
for (MtbColt mtbColt : mtbColts) {
|
||||||
mtbColt.getMtbColr().get(0)
|
mtbColt.getMtbColr().get(0)
|
||||||
.setDescrizione(currentOrder.getDescrizioneProd())
|
.setDescrizione(currentOrder.getDescrizioneProd())
|
||||||
@ -66,6 +80,34 @@ public class ProdRientroMerceOrderDetailViewModel {
|
|||||||
}, this::sendError);
|
}, this::sendError);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void retrieveOrderData(RunnableArgss<MtbAart, String> onComplete) {
|
||||||
|
String codProd = currentOrder.getCodProd();
|
||||||
|
articoloRESTConsumer.getByCodMart(codProd, mtbAart -> {
|
||||||
|
|
||||||
|
String sql = "SELECT TOP 1 * " +
|
||||||
|
"FROM ( " +
|
||||||
|
" SELECT MAX(id_step) OVER ( PARTITION BY gestione, num_ord, data_ord) as last_step, " +
|
||||||
|
" * " +
|
||||||
|
" FROM dtb_ord_steps " +
|
||||||
|
" WHERE cod_jfas IS NOT NULL " +
|
||||||
|
" AND gestione = " + UtilityDB.valueToString(currentOrder.getGestione()) +
|
||||||
|
" AND num_ord = " + UtilityDB.valueToString(currentOrder.getNumOrd()) +
|
||||||
|
" AND data_ord = " + UtilityDB.valueToString(currentOrder.getDataOrdD()) +
|
||||||
|
" ) tmp " +
|
||||||
|
"WHERE (data_iniz IS NOT NULL" +
|
||||||
|
" AND (data_fine IS NULL OR last_step = id_step))" +
|
||||||
|
" OR id_step = 0" +
|
||||||
|
"ORDER BY id_step DESC";
|
||||||
|
|
||||||
|
systemRESTConsumer.<List<DtbOrdSteps>>processSql(sql, new TypeToken<ArrayList<DtbOrdSteps>>() {
|
||||||
|
}.getType(), dtbOrdStep -> {
|
||||||
|
|
||||||
|
onComplete.run(mtbAart, dtbOrdStep != null && !dtbOrdStep.isEmpty() ? dtbOrdStep.get(0).getCodJfas() : null);
|
||||||
|
|
||||||
|
}, this::sendError);
|
||||||
|
}, this::sendError);
|
||||||
|
}
|
||||||
|
|
||||||
public void createLU(ProdRientroMerceOrderDetailPickedQuantityDTO pickedQuantityDTO) {
|
public void createLU(ProdRientroMerceOrderDetailPickedQuantityDTO pickedQuantityDTO) {
|
||||||
|
|
||||||
this.sendOnLoadingStarted();
|
this.sendOnLoadingStarted();
|
||||||
@ -73,11 +115,10 @@ public class ProdRientroMerceOrderDetailViewModel {
|
|||||||
ImportColliDaProduzioneRequestDTO importColliDaProduzioneRequestDTO =
|
ImportColliDaProduzioneRequestDTO importColliDaProduzioneRequestDTO =
|
||||||
new ImportColliDaProduzioneRequestDTO()
|
new ImportColliDaProduzioneRequestDTO()
|
||||||
.setColliBancale(pickedQuantityDTO.getNumCnf().intValue())
|
.setColliBancale(pickedQuantityDTO.getNumCnf().intValue())
|
||||||
.setQtaCnf(pickedQuantityDTO.getPesoCollo())
|
.setQtaCnf(pickedQuantityDTO.getQtaCnf())
|
||||||
.setQtaCol(pickedQuantityDTO.getPesoNetto())
|
.setQtaCol(pickedQuantityDTO.getQtaCol())
|
||||||
.setCodJcom(currentOrder.getCodJcom())
|
.setCodJcom(currentOrder.getCodJcom())
|
||||||
// .setCodJfas("OFF")
|
.setCodJfas(pickedQuantityDTO.getCodJfas())
|
||||||
.setCodJfas(pickedQuantityDTO.getJtbFasi() != null ? pickedQuantityDTO.getJtbFasi().getCodJfas() : null)
|
|
||||||
.setCodMart(currentOrder.getCodProd())
|
.setCodMart(currentOrder.getCodProd())
|
||||||
.setCodTcol(pickedQuantityDTO.getMtbTCol() != null ? pickedQuantityDTO.getMtbTCol().getCodTcol() : null)
|
.setCodTcol(pickedQuantityDTO.getMtbTCol() != null ? pickedQuantityDTO.getMtbTCol().getCodTcol() : null)
|
||||||
.setDataCollo(LocalDate.now())
|
.setDataCollo(LocalDate.now())
|
||||||
@ -87,9 +128,12 @@ public class ProdRientroMerceOrderDetailViewModel {
|
|||||||
.setPartitaMag(currentOrder.getPartitaMag())
|
.setPartitaMag(currentOrder.getPartitaMag())
|
||||||
.setFornitore(currentOrder.getRagSocAnag())
|
.setFornitore(currentOrder.getRagSocAnag())
|
||||||
.setPesoLordo(pickedQuantityDTO.getPesoLordo())
|
.setPesoLordo(pickedQuantityDTO.getPesoLordo())
|
||||||
.setPesoNetto(pickedQuantityDTO.getPesoNetto());
|
.setPesoNetto(pickedQuantityDTO.getPesoNetto())
|
||||||
|
.setAutoGeneraVendita(false);
|
||||||
|
|
||||||
|
this.prodRientroMerceOrderDetailRESTConsumer.importColliDaProduzione(importColliDaProduzioneRequestDTO, mtbColtSaved -> {
|
||||||
|
|
||||||
|
|
||||||
this.mProdRientroMerceOrderDetailRESTConsumer.importColloDaProduzione(importColliDaProduzioneRequestDTO, mtbColtSaved -> {
|
|
||||||
synchronized (this.mtbColtsOfOrder) {
|
synchronized (this.mtbColtsOfOrder) {
|
||||||
this.mListener.onDataSaved(mtbColtSaved);
|
this.mListener.onDataSaved(mtbColtSaved);
|
||||||
}
|
}
|
||||||
@ -98,13 +142,13 @@ public class ProdRientroMerceOrderDetailViewModel {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void deleteLU(MtbColt mtbColt) {
|
|
||||||
new Thread(this::sendOnLoadingStarted).start();
|
|
||||||
|
|
||||||
new Thread(() -> {
|
public void deleteLU(MtbColt mtbColt) {
|
||||||
this.mProdRientroMerceOrderDetailRESTConsumer.deleteColloDaProduzione(mtbColt, () -> {
|
this.sendOnLoadingStarted();
|
||||||
|
|
||||||
|
this.prodRientroMerceOrderDetailRESTConsumer.deleteColloDaProduzione(mtbColt, () -> {
|
||||||
synchronized (this.mtbColtsOfOrder) {
|
synchronized (this.mtbColtsOfOrder) {
|
||||||
Optional<MtbColt> mtbColtToRemove = Stream.of(this.mtbColtsOfOrder.getValue())
|
Optional<MtbColt> mtbColtToRemove = Objects.requireNonNull(this.mtbColtsOfOrder.getValue()).stream()
|
||||||
.filter(x -> x.getNumCollo().equals(mtbColt.getNumCollo()) &&
|
.filter(x -> x.getNumCollo().equals(mtbColt.getNumCollo()) &&
|
||||||
x.getSerCollo().equalsIgnoreCase(mtbColt.getSerCollo()) &&
|
x.getSerCollo().equalsIgnoreCase(mtbColt.getSerCollo()) &&
|
||||||
x.getDataColloD().compareTo(mtbColt.getDataColloD()) == 0 &&
|
x.getDataColloD().compareTo(mtbColt.getDataColloD()) == 0 &&
|
||||||
@ -120,7 +164,6 @@ public class ProdRientroMerceOrderDetailViewModel {
|
|||||||
|
|
||||||
this.sendOnLoadingEnded();
|
this.sendOnLoadingEnded();
|
||||||
}, this::sendError);
|
}, this::sendError);
|
||||||
}).start();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setListener(Listener listener) {
|
public void setListener(Listener listener) {
|
||||||
@ -152,7 +195,7 @@ public class ProdRientroMerceOrderDetailViewModel {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void loadShipmentUlFromProductionUL(MtbColt productionUL, RunnableArgs<MtbColt> onLoad, RunnableArgs<Exception> onError) {
|
private void loadShipmentUlFromProductionUL(MtbColt productionUL, RunnableArgs<MtbColt> onLoad, RunnableArgs<Exception> onError) {
|
||||||
this.mColliMagazzinoRESTConsumer.loadShipmentUlFromProductionUL(productionUL, onLoad, onError);
|
this.colliMagazzinoRESTConsumer.loadShipmentUlFromProductionUL(productionUL, onLoad, onError);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void startPrint(MtbColt mtbColt, ReportType reportType, String codAnag) {
|
private void startPrint(MtbColt mtbColt, ReportType reportType, String codAnag) {
|
||||||
@ -161,7 +204,7 @@ public class ProdRientroMerceOrderDetailViewModel {
|
|||||||
params.put("ser_collo", mtbColt.getSerCollo());
|
params.put("ser_collo", mtbColt.getSerCollo());
|
||||||
params.put("num_collo", mtbColt.getNumCollo());
|
params.put("num_collo", mtbColt.getNumCollo());
|
||||||
params.put("data_collo", UtilityDate.formatDate(mtbColt.getDataColloD(), UtilityDate.COMMONS_DATE_FORMATS.YMD_DASH));
|
params.put("data_collo", UtilityDate.formatDate(mtbColt.getDataColloD(), UtilityDate.COMMONS_DATE_FORMATS.YMD_DASH));
|
||||||
this.mPrinterRESTConsumer.printReportType(
|
this.printerRESTConsumer.printReportType(
|
||||||
reportType,
|
reportType,
|
||||||
SettingsManager.i().getUserSession().getDepo().getCodMdep(),
|
SettingsManager.i().getUserSession().getDepo().getCodMdep(),
|
||||||
codAnag,
|
codAnag,
|
||||||
|
|||||||
@ -8,6 +8,7 @@ import com.orhanobut.logger.Logger;
|
|||||||
|
|
||||||
import java.lang.reflect.Type;
|
import java.lang.reflect.Type;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
import java.util.Collections;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@ -108,13 +109,14 @@ public class ProdRientroMerceOrderDetailRESTConsumer extends _BaseRESTConsumer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public void importColloDaProduzione(ImportColliDaProduzioneRequestDTO importColliDaProduzioneRequestDTO, RunnableArgs<MtbColt> onComplete, RunnableArgs<Exception> onFailed) {
|
public void importColliDaProduzione(ImportColliDaProduzioneRequestDTO importColliDaProduzioneRequestDTO, RunnableArgs<MtbColt> onComplete, RunnableArgs<Exception> onFailed) {
|
||||||
|
|
||||||
ProdRientroMerceOrderDetailRESTConsumerService service = RESTBuilder.getService(ProdRientroMerceOrderDetailRESTConsumerService.class);
|
ProdRientroMerceOrderDetailRESTConsumerService service = RESTBuilder.getService(ProdRientroMerceOrderDetailRESTConsumerService.class);
|
||||||
service.importColloDaProduzione(importColliDaProduzioneRequestDTO).enqueue(new Callback<ServiceRESTResponse<List<MtbColt>>>() {
|
service.importColliDaProduzione(Collections.singletonList(importColliDaProduzioneRequestDTO))
|
||||||
|
.enqueue(new Callback<>() {
|
||||||
@Override
|
@Override
|
||||||
public void onResponse(Call<ServiceRESTResponse<List<MtbColt>>> call, Response<ServiceRESTResponse<List<MtbColt>>> response) {
|
public void onResponse(Call<ServiceRESTResponse<MtbColt>> call, Response<ServiceRESTResponse<MtbColt>> response) {
|
||||||
analyzeAnswer(response, "importColliDaProduzione", mtbColt -> {
|
analyzeAnswerList(response, "importColliDaProduzione", mtbColt -> {
|
||||||
onComplete.run(mtbColt.get(0));
|
onComplete.run(mtbColt.get(0));
|
||||||
}, ex -> {
|
}, ex -> {
|
||||||
if (onFailed != null) onFailed.run(ex);
|
if (onFailed != null) onFailed.run(ex);
|
||||||
@ -122,7 +124,7 @@ public class ProdRientroMerceOrderDetailRESTConsumer extends _BaseRESTConsumer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onFailure(Call<ServiceRESTResponse<List<MtbColt>>> call, Throwable t) {
|
public void onFailure(Call<ServiceRESTResponse<MtbColt>> call, Throwable t) {
|
||||||
Logger.e(t, "importColliDaProduzione");
|
Logger.e(t, "importColliDaProduzione");
|
||||||
onFailed.run(new Exception(t));
|
onFailed.run(new Exception(t));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -13,10 +13,7 @@ public interface ProdRientroMerceOrderDetailRESTConsumerService {
|
|||||||
|
|
||||||
|
|
||||||
@POST("importColliDaProduzioneJson")
|
@POST("importColliDaProduzioneJson")
|
||||||
Call<ServiceRESTResponse<List<MtbColt>>> importColliDaProduzione(@Body List<ImportColliDaProduzioneRequestDTO> importColliDaProduzioneRequestDTO);
|
Call<ServiceRESTResponse<MtbColt>> importColliDaProduzione(@Body List<ImportColliDaProduzioneRequestDTO> importColliDaProduzioneRequestDTO);
|
||||||
|
|
||||||
@POST("importColloDaProduzioneJson")
|
|
||||||
Call<ServiceRESTResponse<List<MtbColt>>> importColloDaProduzione(@Body ImportColliDaProduzioneRequestDTO importColloDaProduzioneRequestDTO);
|
|
||||||
|
|
||||||
@POST("cancellaColloDaProduzione")
|
@POST("cancellaColloDaProduzione")
|
||||||
Call<ServiceRESTResponse<Object>> deleteColloDaProduzione(@Body MtbColt mtbColtToDelete);
|
Call<ServiceRESTResponse<Object>> deleteColloDaProduzione(@Body MtbColt mtbColtToDelete);
|
||||||
|
|||||||
@ -27,6 +27,8 @@ public class ImportColliDaProduzioneRequestDTO {
|
|||||||
private Integer numRisorse;
|
private Integer numRisorse;
|
||||||
private String annotazioni;
|
private String annotazioni;
|
||||||
|
|
||||||
|
private boolean autoGeneraVendita;
|
||||||
|
|
||||||
public String getCodMart() {
|
public String getCodMart() {
|
||||||
return codMart;
|
return codMart;
|
||||||
}
|
}
|
||||||
@ -188,4 +190,13 @@ public class ImportColliDaProduzioneRequestDTO {
|
|||||||
this.annotazioni = annotazioni;
|
this.annotazioni = annotazioni;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean isAutoGeneraVendita() {
|
||||||
|
return autoGeneraVendita;
|
||||||
|
}
|
||||||
|
|
||||||
|
public ImportColliDaProduzioneRequestDTO setAutoGeneraVendita(boolean autoGeneraVendita) {
|
||||||
|
this.autoGeneraVendita = autoGeneraVendita;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -32,7 +32,7 @@ public class ProdRientroMerceOrderListAdapter extends SectionedRecyclerViewAdapt
|
|||||||
private View mEmptyView;
|
private View mEmptyView;
|
||||||
|
|
||||||
private RunnableArgs<String> mOnGroupItemClicked;
|
private RunnableArgs<String> mOnGroupItemClicked;
|
||||||
private RunnableArgs<ProdRientroMerceOrderListModel> mOnItemChecked;
|
private RunnableArgs<ProdRientroMerceOrderListModel> mOnItemClicked;
|
||||||
|
|
||||||
static class SubheaderHolder extends RecyclerView.ViewHolder {
|
static class SubheaderHolder extends RecyclerView.ViewHolder {
|
||||||
|
|
||||||
@ -75,8 +75,8 @@ public class ProdRientroMerceOrderListAdapter extends SectionedRecyclerViewAdapt
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
public ProdRientroMerceOrderListAdapter setOnItemChecked(RunnableArgs<ProdRientroMerceOrderListModel> onItemChecked) {
|
public ProdRientroMerceOrderListAdapter setOnItemClicked(RunnableArgs<ProdRientroMerceOrderListModel> onItemChecked) {
|
||||||
this.mOnItemChecked = onItemChecked;
|
this.mOnItemClicked = onItemChecked;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -174,7 +174,7 @@ public class ProdRientroMerceOrderListAdapter extends SectionedRecyclerViewAdapt
|
|||||||
holder.mBinding.executePendingBindings();
|
holder.mBinding.executePendingBindings();
|
||||||
|
|
||||||
holder.mBinding.getRoot().setOnClickListener(v -> {
|
holder.mBinding.getRoot().setOnClickListener(v -> {
|
||||||
if (this.mOnItemChecked != null) this.mOnItemChecked.run(listModel);
|
if (this.mOnItemClicked != null) this.mOnItemClicked.run(listModel);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -84,7 +84,7 @@ public class ProdRientroMerceOrderListFragment extends Fragment {
|
|||||||
|
|
||||||
ProdRientroMerceOrderListAdapter prodRientroMerceOrderListAdapter = new ProdRientroMerceOrderListAdapter(getActivity(), mOrdiniApertiMutableData)
|
ProdRientroMerceOrderListAdapter prodRientroMerceOrderListAdapter = new ProdRientroMerceOrderListAdapter(getActivity(), mOrdiniApertiMutableData)
|
||||||
.setEmptyView(this.mBindings.emptyView)
|
.setEmptyView(this.mBindings.emptyView)
|
||||||
.setOnItemChecked(x -> {
|
.setOnItemClicked(x -> {
|
||||||
if (mOnItemSelectedRunnable != null)
|
if (mOnItemSelectedRunnable != null)
|
||||||
mOnItemSelectedRunnable.run(x.getOriginalModel());
|
mOnItemSelectedRunnable.run(x.getOriginalModel());
|
||||||
});
|
});
|
||||||
|
|||||||
@ -248,7 +248,8 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:gravity="end"
|
android:gravity="end"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal"
|
||||||
|
android:visibility="@{view.currentOrder.getDataConsCommessaD() == null ? View.GONE : View.VISIBLE}">
|
||||||
|
|
||||||
<androidx.appcompat.widget.LinearLayoutCompat
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
@ -440,7 +441,8 @@
|
|||||||
<androidx.appcompat.widget.LinearLayoutCompat
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal"
|
||||||
|
android:visibility="@{view.isOrderColli ? View.GONE : View.VISIBLE}">
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
android:layout_width="24dp"
|
android:layout_width="24dp"
|
||||||
@ -456,8 +458,7 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:gravity="start"
|
android:gravity="start"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical">
|
||||||
android:visibility="@{view.isOrderColli ? View.GONE : View.VISIBLE}">
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
@ -1150,7 +1151,7 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/add_lu"
|
android:text="@string/add_lu"
|
||||||
app:icon="@drawable/ic_add_24dp"
|
app:icon="@drawable/ic_add_24dp"
|
||||||
app:singleClick="@{() -> viewModel.addUL()}" />
|
app:singleClick="@{() -> view.addULButtonClick()}" />
|
||||||
|
|
||||||
<com.google.android.material.button.MaterialButton
|
<com.google.android.material.button.MaterialButton
|
||||||
style="@style/Button.PrimaryOutline"
|
style="@style/Button.PrimaryOutline"
|
||||||
@ -1158,7 +1159,7 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/add_unit"
|
android:text="@string/add_unit"
|
||||||
app:icon="@drawable/ic_add_24dp"
|
app:icon="@drawable/ic_add_24dp"
|
||||||
app:singleClick="@{() -> viewModel.addUnitButtonClick()}" />
|
app:singleClick="@{() -> view.addSingleUnitButtonClick()}" />
|
||||||
|
|
||||||
|
|
||||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
|
|||||||
@ -243,7 +243,8 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
android:gravity="end"
|
android:gravity="end"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal"
|
||||||
|
android:visibility="@{view.currentOrder.getDataConsCommessaD() == null ? View.GONE : View.VISIBLE}">
|
||||||
|
|
||||||
<androidx.appcompat.widget.LinearLayoutCompat
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
@ -435,7 +436,8 @@
|
|||||||
<androidx.appcompat.widget.LinearLayoutCompat
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:orientation="horizontal">
|
android:orientation="horizontal"
|
||||||
|
android:visibility="@{view.isOrderColli ? View.GONE : View.VISIBLE}">
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageView
|
<androidx.appcompat.widget.AppCompatImageView
|
||||||
android:layout_width="24dp"
|
android:layout_width="24dp"
|
||||||
@ -451,8 +453,7 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
android:gravity="start"
|
android:gravity="start"
|
||||||
android:orientation="vertical"
|
android:orientation="vertical">
|
||||||
android:visibility="@{view.isOrderColli ? View.GONE : View.VISIBLE}">
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
@ -731,7 +732,7 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/add_lu"
|
android:text="@string/add_lu"
|
||||||
app:icon="@drawable/ic_add_24dp"
|
app:icon="@drawable/ic_add_24dp"
|
||||||
app:singleClick="@{() -> viewModel.addUL()}" />
|
app:singleClick="@{() -> view.addULButtonClick()}" />
|
||||||
|
|
||||||
<com.google.android.material.button.MaterialButton
|
<com.google.android.material.button.MaterialButton
|
||||||
style="@style/Button.PrimaryOutline"
|
style="@style/Button.PrimaryOutline"
|
||||||
@ -739,7 +740,7 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="@string/add_unit"
|
android:text="@string/add_unit"
|
||||||
app:icon="@drawable/ic_add_24dp"
|
app:icon="@drawable/ic_add_24dp"
|
||||||
app:singleClick="@{() -> viewModel.addUnitButtonClick()}" />
|
app:singleClick="@{() -> view.addSingleUnitButtonClick()}" />
|
||||||
|
|
||||||
|
|
||||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
|
|||||||
@ -334,7 +334,7 @@
|
|||||||
<string name="general">Generale</string>
|
<string name="general">Generale</string>
|
||||||
<string name="purchase">Acquisti</string>
|
<string name="purchase">Acquisti</string>
|
||||||
<string name="checkout">Vendita</string>
|
<string name="checkout">Vendita</string>
|
||||||
<string name="manufacture">Lav. terzi / Trasf. interni</string>
|
<string name="manufacture">Produzione</string>
|
||||||
<string name="production">Produzione</string>
|
<string name="production">Produzione</string>
|
||||||
<string name="production_line">Linea di produzione</string>
|
<string name="production_line">Linea di produzione</string>
|
||||||
<string name="select_batch_lot">Seleziona un lotto</string>
|
<string name="select_batch_lot">Seleziona un lotto</string>
|
||||||
|
|||||||
@ -338,7 +338,7 @@
|
|||||||
<string name="general">General</string>
|
<string name="general">General</string>
|
||||||
<string name="purchase">Purchase</string>
|
<string name="purchase">Purchase</string>
|
||||||
<string name="checkout">Check out</string>
|
<string name="checkout">Check out</string>
|
||||||
<string name="manufacture">Manufacture / Internal movement</string>
|
<string name="manufacture">Manufacture</string>
|
||||||
<string name="production">Production</string>
|
<string name="production">Production</string>
|
||||||
<string name="production_line">Production line</string>
|
<string name="production_line">Production line</string>
|
||||||
<string name="select_batch_lot">Select a batch lot</string>
|
<string name="select_batch_lot">Select a batch lot</string>
|
||||||
|
|||||||
@ -3,7 +3,7 @@
|
|||||||
buildscript {
|
buildscript {
|
||||||
ext {
|
ext {
|
||||||
kotlin_version = '1.9.20'
|
kotlin_version = '1.9.20'
|
||||||
agp_version = '8.4.0'
|
agp_version = '8.7.2'
|
||||||
}
|
}
|
||||||
|
|
||||||
repositories {
|
repositories {
|
||||||
|
|||||||
2
gradle/wrapper/gradle-wrapper.properties
vendored
2
gradle/wrapper/gradle-wrapper.properties
vendored
@ -1,6 +1,6 @@
|
|||||||
#Mon Feb 13 15:14:43 CET 2023
|
#Mon Feb 13 15:14:43 CET 2023
|
||||||
distributionBase=GRADLE_USER_HOME
|
distributionBase=GRADLE_USER_HOME
|
||||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip
|
distributionUrl=https\://services.gradle.org/distributions/gradle-8.9-bin.zip
|
||||||
distributionPath=wrapper/dists
|
distributionPath=wrapper/dists
|
||||||
zipStorePath=wrapper/dists
|
zipStorePath=wrapper/dists
|
||||||
zipStoreBase=GRADLE_USER_HOME
|
zipStoreBase=GRADLE_USER_HOME
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user