Aggiunta quantità omaggio in spedizione
aggiunto alert partite in scadenza in spediione
This commit is contained in:
parent
020c99e700
commit
bf56c8e4c7
@ -17,6 +17,7 @@ import it.integry.integrywmsnative.core.rest.consumers.BarcodeRESTConsumer;
|
|||||||
import it.integry.integrywmsnative.core.rest.consumers.ColliMagazzinoRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.ColliMagazzinoRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.CommessaRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.CommessaRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.DepositoRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.DepositoRESTConsumer;
|
||||||
|
import it.integry.integrywmsnative.core.rest.consumers.DocumentiRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.EntityRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.EntityRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.GestSetupRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.GestSetupRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.GiacenzaRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.GiacenzaRESTConsumer;
|
||||||
@ -207,4 +208,10 @@ public class MainApplicationModule {
|
|||||||
return new ProductionLinesRESTConsumer();
|
return new ProductionLinesRESTConsumer();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Provides
|
||||||
|
@Singleton
|
||||||
|
DocumentiRESTConsumer provideDocumentiRESTConsumer() {
|
||||||
|
return new DocumentiRESTConsumer();
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@ -0,0 +1,93 @@
|
|||||||
|
package it.integry.integrywmsnative.core.model.dto;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
public class StatoArticoloDTO {
|
||||||
|
private String codMart;
|
||||||
|
|
||||||
|
private String partitaMag;
|
||||||
|
|
||||||
|
private Date dataScad;
|
||||||
|
|
||||||
|
private Integer ggScadPartita;
|
||||||
|
|
||||||
|
private Integer ggMax;
|
||||||
|
|
||||||
|
private Integer ggScadEffettivi;
|
||||||
|
|
||||||
|
private Integer ggUtili;
|
||||||
|
|
||||||
|
private Integer statoArt;
|
||||||
|
|
||||||
|
public String getCodMart() {
|
||||||
|
return codMart;
|
||||||
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO setCodMart(String codMart) {
|
||||||
|
this.codMart = codMart;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getPartitaMag() {
|
||||||
|
return partitaMag;
|
||||||
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO setPartitaMag(String partitaMag) {
|
||||||
|
this.partitaMag = partitaMag;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getDataScad() {
|
||||||
|
return dataScad;
|
||||||
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO setDataScad(Date dataScad) {
|
||||||
|
this.dataScad = dataScad;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getGgScadPartita() {
|
||||||
|
return ggScadPartita;
|
||||||
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO setGgScadPartita(Integer ggScadPartita) {
|
||||||
|
this.ggScadPartita = ggScadPartita;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getGgMax() {
|
||||||
|
return ggMax;
|
||||||
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO setGgMax(Integer ggMax) {
|
||||||
|
this.ggMax = ggMax;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getGgScadEffettivi() {
|
||||||
|
return ggScadEffettivi;
|
||||||
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO setGgScadEffettivi(Integer ggScadEffettivi) {
|
||||||
|
this.ggScadEffettivi = ggScadEffettivi;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getGgUtili() {
|
||||||
|
return ggUtili;
|
||||||
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO setGgUtili(Integer ggUtili) {
|
||||||
|
this.ggUtili = ggUtili;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getStatoArt() {
|
||||||
|
return statoArt;
|
||||||
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO setStatoArt(Integer statoArt) {
|
||||||
|
this.statoArt = statoArt;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,26 @@
|
|||||||
|
package it.integry.integrywmsnative.core.model.secondary;
|
||||||
|
|
||||||
|
public enum StatoPartitaMag {
|
||||||
|
|
||||||
|
IN_SCADENZA("1"),
|
||||||
|
SCADUTO("2"),
|
||||||
|
NON_IN_SCADENZA("3");
|
||||||
|
|
||||||
|
private final String text;
|
||||||
|
|
||||||
|
StatoPartitaMag(String text) {
|
||||||
|
this.text = text;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getText() {
|
||||||
|
return this.text;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static StatoPartitaMag fromString(String text) {
|
||||||
|
for (StatoPartitaMag b : StatoPartitaMag.values()) {
|
||||||
|
if (b.text.equalsIgnoreCase(text)) return b;
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@ -14,6 +14,7 @@ import javax.inject.Singleton;
|
|||||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||||
import it.integry.integrywmsnative.core.model.MtbAart;
|
import it.integry.integrywmsnative.core.model.MtbAart;
|
||||||
import it.integry.integrywmsnative.core.model.MtbGrup;
|
import it.integry.integrywmsnative.core.model.MtbGrup;
|
||||||
|
import it.integry.integrywmsnative.core.model.dto.StatoArticoloDTO;
|
||||||
import it.integry.integrywmsnative.core.rest.RESTBuilder;
|
import it.integry.integrywmsnative.core.rest.RESTBuilder;
|
||||||
import it.integry.integrywmsnative.core.rest.model.ServiceRESTResponse;
|
import it.integry.integrywmsnative.core.rest.model.ServiceRESTResponse;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityQuery;
|
import it.integry.integrywmsnative.core.utility.UtilityQuery;
|
||||||
@ -32,7 +33,7 @@ public class ArticoloRESTConsumer extends _BaseRESTConsumer {
|
|||||||
|
|
||||||
public void getByBarcodeProd(String barcodeProd, RunnableArgs<List<MtbAart>> onComplete, RunnableArgs<Exception> onFailed) {
|
public void getByBarcodeProd(String barcodeProd, RunnableArgs<List<MtbAart>> onComplete, RunnableArgs<Exception> onFailed) {
|
||||||
ArticoloRESTConsumerService articoloRESTConsumerService = RESTBuilder.getService(ArticoloRESTConsumerService.class);
|
ArticoloRESTConsumerService articoloRESTConsumerService = RESTBuilder.getService(ArticoloRESTConsumerService.class);
|
||||||
articoloRESTConsumerService.getByBarcodeProd(barcodeProd).enqueue(new Callback<ServiceRESTResponse<MtbAart>>() {
|
articoloRESTConsumerService.getByBarcodeProd(barcodeProd).enqueue(new Callback<>() {
|
||||||
@Override
|
@Override
|
||||||
public void onResponse(Call<ServiceRESTResponse<MtbAart>> call, Response<ServiceRESTResponse<MtbAart>> response) {
|
public void onResponse(Call<ServiceRESTResponse<MtbAart>> call, Response<ServiceRESTResponse<MtbAart>> response) {
|
||||||
analyzeAnswer(response, "getByBarcodeProd", (m) -> {
|
analyzeAnswer(response, "getByBarcodeProd", (m) -> {
|
||||||
@ -61,7 +62,7 @@ public class ArticoloRESTConsumer extends _BaseRESTConsumer {
|
|||||||
|
|
||||||
|
|
||||||
ArticoloRESTConsumerService articoloRESTConsumer = RESTBuilder.getService(ArticoloRESTConsumerService.class);
|
ArticoloRESTConsumerService articoloRESTConsumer = RESTBuilder.getService(ArticoloRESTConsumerService.class);
|
||||||
articoloRESTConsumer.getByCodMart(joinedCods).enqueue(new Callback<ServiceRESTResponse<MtbAart>>() {
|
articoloRESTConsumer.getByCodMart(joinedCods).enqueue(new Callback<>() {
|
||||||
@Override
|
@Override
|
||||||
public void onResponse(Call<ServiceRESTResponse<MtbAart>> call, Response<ServiceRESTResponse<MtbAart>> response) {
|
public void onResponse(Call<ServiceRESTResponse<MtbAart>> call, Response<ServiceRESTResponse<MtbAart>> response) {
|
||||||
analyzeAnswer(response, "getByCodMart", (m) -> {
|
analyzeAnswer(response, "getByCodMart", (m) -> {
|
||||||
@ -77,11 +78,28 @@ public class ArticoloRESTConsumer extends _BaseRESTConsumer {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public void getStatoPartita(String codMart, String partitaMag, RunnableArgs<List<StatoArticoloDTO>> onComplete, RunnableArgs<Exception> onFailed) {
|
||||||
|
|
||||||
|
ArticoloRESTConsumerService articoloRESTConsumer = RESTBuilder.getService(ArticoloRESTConsumerService.class);
|
||||||
|
articoloRESTConsumer.getStatoPartita(codMart, partitaMag).enqueue(new Callback<>() {
|
||||||
|
@Override
|
||||||
|
public void onResponse(Call<ServiceRESTResponse<List<StatoArticoloDTO>>> call, Response<ServiceRESTResponse<List<StatoArticoloDTO>>> response) {
|
||||||
|
analyzeAnswer(response, "getStatoPartita", onComplete, onFailed);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onFailure(Call<ServiceRESTResponse<List<StatoArticoloDTO>>> call, Throwable t) {
|
||||||
|
onFailed.run(new Exception(t));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public void getByCodMart(String codMartToFind, RunnableArgs<MtbAart> onComplete, RunnableArgs<Exception> onFailed) {
|
public void getByCodMart(String codMartToFind, RunnableArgs<MtbAart> onComplete, RunnableArgs<Exception> onFailed) {
|
||||||
|
|
||||||
ArticoloRESTConsumerService articoloRESTConsumer = RESTBuilder.getService(ArticoloRESTConsumerService.class);
|
ArticoloRESTConsumerService articoloRESTConsumer = RESTBuilder.getService(ArticoloRESTConsumerService.class);
|
||||||
articoloRESTConsumer.getByCodMart(codMartToFind).enqueue(new Callback<ServiceRESTResponse<MtbAart>>() {
|
articoloRESTConsumer.getByCodMart(codMartToFind).enqueue(new Callback<>() {
|
||||||
@Override
|
@Override
|
||||||
public void onResponse(Call<ServiceRESTResponse<MtbAart>> call, Response<ServiceRESTResponse<MtbAart>> response) {
|
public void onResponse(Call<ServiceRESTResponse<MtbAart>> call, Response<ServiceRESTResponse<MtbAart>> response) {
|
||||||
analyzeAnswer(response, "getByCodMart", (m) -> {
|
analyzeAnswer(response, "getByCodMart", (m) -> {
|
||||||
|
|||||||
@ -1,7 +1,10 @@
|
|||||||
package it.integry.integrywmsnative.core.rest.consumers;
|
package it.integry.integrywmsnative.core.rest.consumers;
|
||||||
|
|
||||||
import it.integry.integrywmsnative.core.rest.model.ServiceRESTResponse;
|
import java.util.List;
|
||||||
|
|
||||||
import it.integry.integrywmsnative.core.model.MtbAart;
|
import it.integry.integrywmsnative.core.model.MtbAart;
|
||||||
|
import it.integry.integrywmsnative.core.model.dto.StatoArticoloDTO;
|
||||||
|
import it.integry.integrywmsnative.core.rest.model.ServiceRESTResponse;
|
||||||
import retrofit2.Call;
|
import retrofit2.Call;
|
||||||
import retrofit2.http.GET;
|
import retrofit2.http.GET;
|
||||||
import retrofit2.http.POST;
|
import retrofit2.http.POST;
|
||||||
@ -16,4 +19,7 @@ public interface ArticoloRESTConsumerService {
|
|||||||
@GET("SM2getArticoloByCodMart")
|
@GET("SM2getArticoloByCodMart")
|
||||||
Call<ServiceRESTResponse<MtbAart>> getByCodMart(@Query("codMart") String barcodeProd);
|
Call<ServiceRESTResponse<MtbAart>> getByCodMart(@Query("codMart") String barcodeProd);
|
||||||
|
|
||||||
|
@GET("getProductLotStatus")
|
||||||
|
Call<ServiceRESTResponse<List<StatoArticoloDTO>>> getStatoPartita(@Query("codMart") String codMart, @Query("partitaMag") String partitaMag);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -0,0 +1,51 @@
|
|||||||
|
package it.integry.integrywmsnative.core.rest.consumers;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import javax.inject.Singleton;
|
||||||
|
|
||||||
|
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||||
|
import it.integry.integrywmsnative.core.model.DtbDoct;
|
||||||
|
import it.integry.integrywmsnative.core.rest.RESTBuilder;
|
||||||
|
import it.integry.integrywmsnative.core.rest.model.LoadColliDTO;
|
||||||
|
import it.integry.integrywmsnative.core.rest.model.ServiceRESTResponse;
|
||||||
|
import retrofit2.Call;
|
||||||
|
import retrofit2.Callback;
|
||||||
|
import retrofit2.Response;
|
||||||
|
|
||||||
|
@Singleton
|
||||||
|
public class DocumentiRESTConsumer extends _BaseRESTConsumer {
|
||||||
|
|
||||||
|
|
||||||
|
public void createDocsFromColli(List<LoadColliDTO> listColli, RunnableArgs<List<DtbDoct>> onComplete, RunnableArgs<Exception> onFailed) {
|
||||||
|
DocumentiRESTConsumerService documentiRESTConsumerService = RESTBuilder.getService(DocumentiRESTConsumerService.class);
|
||||||
|
documentiRESTConsumerService.createDocsFromColli(listColli).enqueue(new Callback<>() {
|
||||||
|
@Override
|
||||||
|
public void onResponse(Call<ServiceRESTResponse<List<DtbDoct>>> call, Response<ServiceRESTResponse<List<DtbDoct>>> response) {
|
||||||
|
analyzeAnswer(response, "createDocsFromColli", onComplete, onFailed);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onFailure(Call<ServiceRESTResponse<List<DtbDoct>>> call, Throwable t) {
|
||||||
|
onFailed.run(new Exception(t));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
public void createDocFromColli(LoadColliDTO loadColliDTO, RunnableArgs<DtbDoct> onComplete, RunnableArgs<Exception> onFailed) {
|
||||||
|
DocumentiRESTConsumerService documentiRESTConsumerService = RESTBuilder.getService(DocumentiRESTConsumerService.class);
|
||||||
|
documentiRESTConsumerService.createDocFromColli(loadColliDTO).enqueue(new Callback<>() {
|
||||||
|
@Override
|
||||||
|
public void onResponse(Call<ServiceRESTResponse<DtbDoct>> call, Response<ServiceRESTResponse<DtbDoct>> response) {
|
||||||
|
analyzeAnswer(response, "createDocFromColli", onComplete, onFailed);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onFailure(Call<ServiceRESTResponse<DtbDoct>> call, Throwable t) {
|
||||||
|
onFailed.run(new Exception(t));
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,20 @@
|
|||||||
|
package it.integry.integrywmsnative.core.rest.consumers;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import it.integry.integrywmsnative.core.model.DtbDoct;
|
||||||
|
import it.integry.integrywmsnative.core.rest.model.LoadColliDTO;
|
||||||
|
import it.integry.integrywmsnative.core.rest.model.ServiceRESTResponse;
|
||||||
|
import retrofit2.Call;
|
||||||
|
import retrofit2.http.Body;
|
||||||
|
import retrofit2.http.POST;
|
||||||
|
|
||||||
|
public interface DocumentiRESTConsumerService {
|
||||||
|
|
||||||
|
@POST("getDatiColliForDocs")
|
||||||
|
Call<ServiceRESTResponse<List<DtbDoct>>> createDocsFromColli(@Body List<LoadColliDTO> listColli);
|
||||||
|
|
||||||
|
@POST("createDocFromColli")
|
||||||
|
Call<ServiceRESTResponse<DtbDoct>> createDocFromColli(@Body LoadColliDTO listColli);
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,182 @@
|
|||||||
|
package it.integry.integrywmsnative.core.rest.model;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||||
|
|
||||||
|
public class LoadColliDTO {
|
||||||
|
|
||||||
|
private String gestione;
|
||||||
|
private String codDtip;
|
||||||
|
private String codAnag;
|
||||||
|
private String codVdes;
|
||||||
|
private Date dataDoc;
|
||||||
|
private String serDoc;
|
||||||
|
private Integer numDoc;
|
||||||
|
private String codMdep;
|
||||||
|
private String calcPrz;
|
||||||
|
private boolean datiOrd;
|
||||||
|
private Date dataOrd;
|
||||||
|
private Integer numOrd;
|
||||||
|
private String flagEvasoForzato;
|
||||||
|
private Date dataVers;
|
||||||
|
private String note;
|
||||||
|
private boolean saveDoc = true;
|
||||||
|
|
||||||
|
private List<MtbColt> colli = new ArrayList<>();
|
||||||
|
|
||||||
|
public String getGestione() {
|
||||||
|
return gestione;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setGestione(String gestione) {
|
||||||
|
this.gestione = gestione;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCodDtip() {
|
||||||
|
return codDtip;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setCodDtip(String codDtip) {
|
||||||
|
this.codDtip = codDtip;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCodAnag() {
|
||||||
|
return codAnag;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setCodAnag(String codAnag) {
|
||||||
|
this.codAnag = codAnag;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCodVdes() {
|
||||||
|
return codVdes;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setCodVdes(String codVdes) {
|
||||||
|
this.codVdes = codVdes;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getDataDoc() {
|
||||||
|
return dataDoc;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setDataDoc(Date dataDoc) {
|
||||||
|
this.dataDoc = dataDoc;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSerDoc() {
|
||||||
|
return serDoc;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setSerDoc(String serDoc) {
|
||||||
|
this.serDoc = serDoc;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getNumDoc() {
|
||||||
|
return numDoc;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setNumDoc(Integer numDoc) {
|
||||||
|
this.numDoc = numDoc;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCodMdep() {
|
||||||
|
return codMdep;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setCodMdep(String codMdep) {
|
||||||
|
this.codMdep = codMdep;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getCalcPrz() {
|
||||||
|
return calcPrz;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setCalcPrz(String calcPrz) {
|
||||||
|
this.calcPrz = calcPrz;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isDatiOrd() {
|
||||||
|
return datiOrd;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setDatiOrd(boolean datiOrd) {
|
||||||
|
this.datiOrd = datiOrd;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getDataOrd() {
|
||||||
|
return dataOrd;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setDataOrd(Date dataOrd) {
|
||||||
|
this.dataOrd = dataOrd;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Integer getNumOrd() {
|
||||||
|
return numOrd;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setNumOrd(Integer numOrd) {
|
||||||
|
this.numOrd = numOrd;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getFlagEvasoForzato() {
|
||||||
|
return flagEvasoForzato;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setFlagEvasoForzato(String flagEvasoForzato) {
|
||||||
|
this.flagEvasoForzato = flagEvasoForzato;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public Date getDataVers() {
|
||||||
|
return dataVers;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setDataVers(Date dataVers) {
|
||||||
|
this.dataVers = dataVers;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getNote() {
|
||||||
|
return note;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setNote(String note) {
|
||||||
|
this.note = note;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isSaveDoc() {
|
||||||
|
return saveDoc;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setSaveDoc(boolean saveDoc) {
|
||||||
|
this.saveDoc = saveDoc;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public List<MtbColt> getColli() {
|
||||||
|
return colli;
|
||||||
|
}
|
||||||
|
|
||||||
|
public LoadColliDTO setColli(List<MtbColt> colli) {
|
||||||
|
this.colli = colli;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -45,6 +45,8 @@ public class OrdineUscitaInevasoDTO extends OrdineInevasoDTO {
|
|||||||
private String nomeAgente;
|
private String nomeAgente;
|
||||||
private String codJfas;
|
private String codJfas;
|
||||||
private List<AvailableClassMerc> availableClassMerc;
|
private List<AvailableClassMerc> availableClassMerc;
|
||||||
|
private boolean ordTrasf;
|
||||||
|
|
||||||
|
|
||||||
public Integer getIdViaggio() {
|
public Integer getIdViaggio() {
|
||||||
return idViaggio;
|
return idViaggio;
|
||||||
@ -56,7 +58,6 @@ public class OrdineUscitaInevasoDTO extends OrdineInevasoDTO {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
public String getListino() {
|
public String getListino() {
|
||||||
return listino;
|
return listino;
|
||||||
}
|
}
|
||||||
@ -371,6 +372,14 @@ public class OrdineUscitaInevasoDTO extends OrdineInevasoDTO {
|
|||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean isOrdTrasf() {
|
||||||
|
return ordTrasf;
|
||||||
|
}
|
||||||
|
|
||||||
|
public OrdineUscitaInevasoDTO setOrdTrasf(boolean ordTrasf) {
|
||||||
|
this.ordTrasf = ordTrasf;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean equals(Object o) {
|
public boolean equals(Object o) {
|
||||||
|
|||||||
@ -27,6 +27,7 @@ public class SitArtOrdDTO {
|
|||||||
private String codMsfa;
|
private String codMsfa;
|
||||||
private String descrizioneMsfa;
|
private String descrizioneMsfa;
|
||||||
private String untord;
|
private String untord;
|
||||||
|
private BigDecimal qtaOmg;
|
||||||
|
|
||||||
private final HashMap<String, Object> extraInfo = new HashMap<>();
|
private final HashMap<String, Object> extraInfo = new HashMap<>();
|
||||||
|
|
||||||
@ -222,4 +223,13 @@ public class SitArtOrdDTO {
|
|||||||
this.untord = untord;
|
this.untord = untord;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public BigDecimal getQtaOmg() {
|
||||||
|
return qtaOmg;
|
||||||
|
}
|
||||||
|
|
||||||
|
public SitArtOrdDTO setQtaOmg(BigDecimal qtaOmg) {
|
||||||
|
this.qtaOmg = qtaOmg;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -50,6 +50,8 @@ public class DBSettingsModel {
|
|||||||
private boolean flagPickLiberoAllowEmptyDest = false;
|
private boolean flagPickLiberoAllowEmptyDest = false;
|
||||||
private boolean flagAskInfoAggiuntiveSpedizione = false;
|
private boolean flagAskInfoAggiuntiveSpedizione = false;
|
||||||
private String filterFornitoreProd;
|
private String filterFornitoreProd;
|
||||||
|
private String codDtipOrdTrasfV;
|
||||||
|
private boolean notifyLotStatus = false;
|
||||||
|
|
||||||
public boolean isFlagSpedizioneEnableFakeGiacenza() {
|
public boolean isFlagSpedizioneEnableFakeGiacenza() {
|
||||||
return flagSpedizioneEnableFakeGiacenza;
|
return flagSpedizioneEnableFakeGiacenza;
|
||||||
@ -384,4 +386,22 @@ public class DBSettingsModel {
|
|||||||
this.filterFornitoreProd = filterFornitoreProd;
|
this.filterFornitoreProd = filterFornitoreProd;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getCodDtipOrdTrasfV() {
|
||||||
|
return codDtipOrdTrasfV;
|
||||||
|
}
|
||||||
|
|
||||||
|
public DBSettingsModel setCodDtipOrdTrasfV(String codDtipOrdTrasfV) {
|
||||||
|
this.codDtipOrdTrasfV = codDtipOrdTrasfV;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isNotifyLotStatus() {
|
||||||
|
return notifyLotStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public DBSettingsModel setNotifyLotStatus(boolean notifyLotStatus) {
|
||||||
|
this.notifyLotStatus = notifyLotStatus;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -326,6 +326,14 @@ public class SettingsManager {
|
|||||||
.setGestName("PICKING")
|
.setGestName("PICKING")
|
||||||
.setSection("SPEDIZIONE")
|
.setSection("SPEDIZIONE")
|
||||||
.setKeySection("FLAG_ASK_INFO_AGGIUNTIVE"));
|
.setKeySection("FLAG_ASK_INFO_AGGIUNTIVE"));
|
||||||
|
stbGestSetupList.add(new StbGestSetup()
|
||||||
|
.setGestName("PICKING")
|
||||||
|
.setSection("SPEDIZIONE")
|
||||||
|
.setKeySection("COD_DTIP_ORD_TRASF"));
|
||||||
|
stbGestSetupList.add(new StbGestSetup()
|
||||||
|
.setGestName("PICKING")
|
||||||
|
.setSection("SPEDIZIONE")
|
||||||
|
.setKeySection("FLAG_NOTIFICA_STATO_PARTITA"));
|
||||||
String codMdep = SettingsManager.i().getUserSession().getDepo().getCodMdep();
|
String codMdep = SettingsManager.i().getUserSession().getDepo().getCodMdep();
|
||||||
|
|
||||||
GestSetupRESTConsumer.getValues(codMdep, stbGestSetupList, list -> {
|
GestSetupRESTConsumer.getValues(codMdep, stbGestSetupList, list -> {
|
||||||
@ -357,6 +365,8 @@ public class SettingsManager {
|
|||||||
dbSettingsModelIstance.setFlagPrintEtichetteOnOrderClose(getValueFromList(list, "SPEDIZIONE", "FLAG_PRINT_ETICHETTE_ON_CLOSE", Boolean.class));
|
dbSettingsModelIstance.setFlagPrintEtichetteOnOrderClose(getValueFromList(list, "SPEDIZIONE", "FLAG_PRINT_ETICHETTE_ON_CLOSE", Boolean.class));
|
||||||
dbSettingsModelIstance.setFlagAskInfoAggiuntiveSpedizione(getValueFromList(list, "SPEDIZIONE", "FLAG_ASK_INFO_AGGIUNTIVE", Boolean.class));
|
dbSettingsModelIstance.setFlagAskInfoAggiuntiveSpedizione(getValueFromList(list, "SPEDIZIONE", "FLAG_ASK_INFO_AGGIUNTIVE", Boolean.class));
|
||||||
dbSettingsModelIstance.setFilterFornitoreProd(getValueFromList(list, "PRODUZIONE", "FILTER_FORNTIORE_PROD", String.class));
|
dbSettingsModelIstance.setFilterFornitoreProd(getValueFromList(list, "PRODUZIONE", "FILTER_FORNTIORE_PROD", String.class));
|
||||||
|
dbSettingsModelIstance.setCodDtipOrdTrasfV(getValueFromList(list, "SPEDIZIONE", "COD_DTIP_ORD_TRASF", String.class));
|
||||||
|
dbSettingsModelIstance.setNotifyLotStatus(getValueFromList(list, "SPEDIZIONE", "FLAG_NOTIFICA_STATO_PARTITA", Boolean.class));
|
||||||
|
|
||||||
String notePerdita = getValueFromList(list, "DOC_INTERNI", "NOTE_PERDITA", String.class);
|
String notePerdita = getValueFromList(list, "DOC_INTERNI", "NOTE_PERDITA", String.class);
|
||||||
if (notePerdita != null)
|
if (notePerdita != null)
|
||||||
|
|||||||
@ -72,6 +72,7 @@ import it.integry.integrywmsnative.view.dialogs.ask_position_of_lu.DialogAskPosi
|
|||||||
import it.integry.integrywmsnative.view.dialogs.ask_should_print.DialogAskShouldPrint;
|
import it.integry.integrywmsnative.view.dialogs.ask_should_print.DialogAskShouldPrint;
|
||||||
import it.integry.integrywmsnative.view.dialogs.base.DialogSimpleInputHelper;
|
import it.integry.integrywmsnative.view.dialogs.base.DialogSimpleInputHelper;
|
||||||
import it.integry.integrywmsnative.view.dialogs.base.DialogSimpleMessageView;
|
import it.integry.integrywmsnative.view.dialogs.base.DialogSimpleMessageView;
|
||||||
|
import it.integry.integrywmsnative.view.dialogs.choose_art_from_lista_arts.DialogChooseArtFromListaArts;
|
||||||
import it.integry.integrywmsnative.view.dialogs.choose_batch_lot.DialogChooseBatchLotView;
|
import it.integry.integrywmsnative.view.dialogs.choose_batch_lot.DialogChooseBatchLotView;
|
||||||
import it.integry.integrywmsnative.view.dialogs.info_aggiuntive_lu.InfoAggiuntiveLUDialog;
|
import it.integry.integrywmsnative.view.dialogs.info_aggiuntive_lu.InfoAggiuntiveLUDialog;
|
||||||
import it.integry.integrywmsnative.view.dialogs.input_peso_lu.DialogInputPeso;
|
import it.integry.integrywmsnative.view.dialogs.input_peso_lu.DialogInputPeso;
|
||||||
@ -196,7 +197,10 @@ public class SpedizioneActivity extends BaseActivity implements SpedizioneViewMo
|
|||||||
this.initBarcodeReader();
|
this.initBarcodeReader();
|
||||||
this.initRecyclerView();
|
this.initRecyclerView();
|
||||||
|
|
||||||
closeOrderButtonEnabled.set(SettingsManager.iDB().isFlagPrintEtichetteOnOrderClose() || SettingsManager.iDB().isFlagPrintPackingListOnOrderClose());
|
closeOrderButtonEnabled.set(SettingsManager.iDB().isFlagPrintEtichetteOnOrderClose()
|
||||||
|
|| SettingsManager.iDB().isFlagPrintPackingListOnOrderClose()
|
||||||
|
|| (this.isOrdTrasf() && !UtilityString.isNullOrEmpty(SettingsManager.iDB().getCodDtipOrdTrasfV()))
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
String codMdep = SettingsManager.i().getUserSession().getDepo().getCodMdep();
|
String codMdep = SettingsManager.i().getUserSession().getDepo().getCodMdep();
|
||||||
@ -220,6 +224,16 @@ public class SpedizioneActivity extends BaseActivity implements SpedizioneViewMo
|
|||||||
useQtaOrd);
|
useQtaOrd);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private boolean isOrdTrasf() {
|
||||||
|
|
||||||
|
return mTestateOrdini != null && !mTestateOrdini.isEmpty() && Stream.of(mTestateOrdini)
|
||||||
|
.map(OrdineUscitaInevasoDTO::isOrdTrasf)
|
||||||
|
.withoutNulls()
|
||||||
|
.distinctBy(x -> x)
|
||||||
|
.findFirst()
|
||||||
|
.get();
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean onSupportNavigateUp() {
|
public boolean onSupportNavigateUp() {
|
||||||
onBackPressed();
|
onBackPressed();
|
||||||
@ -342,6 +356,11 @@ public class SpedizioneActivity extends BaseActivity implements SpedizioneViewMo
|
|||||||
spedizioneListModel.setUntMis(x.getMtbAart().getUntMis());
|
spedizioneListModel.setUntMis(x.getMtbAart().getUntMis());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
BigDecimal qtaOmg = x.getSitArtOrdDTO().getQtaOmg();
|
||||||
|
if (qtaOmg != null && qtaOmg.compareTo(BigDecimal.ZERO) > 0) {
|
||||||
|
spedizioneListModel.setFreeQuantity(String.format(getString(R.string.ord_ven_qta_omaggio), qtaOmg.stripTrailingZeros().toPlainString(), spedizioneListModel.getUntMis()));
|
||||||
|
}
|
||||||
|
|
||||||
spedizioneListModel.setOriginalModel(x);
|
spedizioneListModel.setOriginalModel(x);
|
||||||
spedizioneListModels.add(spedizioneListModel);
|
spedizioneListModels.add(spedizioneListModel);
|
||||||
} else {
|
} else {
|
||||||
@ -772,25 +791,26 @@ public class SpedizioneActivity extends BaseActivity implements SpedizioneViewMo
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onItemDispatched(PickingObjectDTO pickingObjectDTO,
|
public void onFullItemDispatched(PickingObjectDTO pickingObjectDTO,
|
||||||
MtbAart mtbAart,
|
MtbAart mtbAart,
|
||||||
BigDecimal initialNumCnf,
|
BigDecimal initialNumCnf,
|
||||||
BigDecimal initialQtaCnf,
|
BigDecimal initialQtaCnf,
|
||||||
BigDecimal initialQtaTot,
|
BigDecimal initialQtaTot,
|
||||||
BigDecimal totalQtaOrd,
|
BigDecimal totalQtaOrd,
|
||||||
BigDecimal totalNumCnfOrd,
|
BigDecimal totalNumCnfOrd,
|
||||||
BigDecimal qtaCnfOrd,
|
BigDecimal qtaCnfOrd,
|
||||||
BigDecimal totalQtaToBeTaken,
|
BigDecimal totalQtaToBeTaken,
|
||||||
BigDecimal totalNumCnfToBeTaken,
|
BigDecimal totalNumCnfToBeTaken,
|
||||||
BigDecimal qtaCnfToBeTaken,
|
BigDecimal qtaCnfToBeTaken,
|
||||||
BigDecimal totalQtaAvailable,
|
BigDecimal totalQtaAvailable,
|
||||||
BigDecimal totalNumCnfAvailable,
|
BigDecimal totalNumCnfAvailable,
|
||||||
BigDecimal qtaCnfAvailable,
|
BigDecimal qtaCnfAvailable,
|
||||||
String partitaMag,
|
String partitaMag,
|
||||||
Date dataScad,
|
Date dataScad,
|
||||||
boolean canOverflowOrderQuantity,
|
boolean canOverflowOrderQuantity,
|
||||||
boolean canPartitaMagBeChanged,
|
boolean canPartitaMagBeChanged,
|
||||||
RunnableArgss<PickedQuantityDTO, Boolean> onComplete) {
|
RunnableArgss<PickedQuantityDTO, Boolean> onComplete) {
|
||||||
|
|
||||||
DialogInputQuantityV2DTO dialogInputQuantityV2DTO = new DialogInputQuantityV2DTO()
|
DialogInputQuantityV2DTO dialogInputQuantityV2DTO = new DialogInputQuantityV2DTO()
|
||||||
.setMtbAart(mtbAart)
|
.setMtbAart(mtbAart)
|
||||||
.setInitialNumCnf(initialNumCnf)
|
.setInitialNumCnf(initialNumCnf)
|
||||||
@ -809,7 +829,9 @@ public class SpedizioneActivity extends BaseActivity implements SpedizioneViewMo
|
|||||||
.setDataScad(dataScad)
|
.setDataScad(dataScad)
|
||||||
.setCanOverflowOrderQuantity(canOverflowOrderQuantity)
|
.setCanOverflowOrderQuantity(canOverflowOrderQuantity)
|
||||||
.setCanLUBeClosed(true)
|
.setCanLUBeClosed(true)
|
||||||
.setCanPartitaMagBeChanged(canPartitaMagBeChanged);
|
.setCanPartitaMagBeChanged(canPartitaMagBeChanged)
|
||||||
|
.setStatoPartitaMag(pickingObjectDTO.getStatoArticoloDTO())
|
||||||
|
.setNotifyProductLotStatus(SettingsManager.iDB().isNotifyLotStatus());
|
||||||
|
|
||||||
if (!mDialogInputQuantityV2View.isVisible())
|
if (!mDialogInputQuantityV2View.isVisible())
|
||||||
mDialogInputQuantityV2View
|
mDialogInputQuantityV2View
|
||||||
@ -899,6 +921,18 @@ public class SpedizioneActivity extends BaseActivity implements SpedizioneViewMo
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onCreateDocsRequest() {
|
||||||
|
DialogYesNo.make(this, "Chiusura ordine", "Vuoi creare i documenti per gli ordini selezionati?", result -> {
|
||||||
|
this.mViewmodel.onCreateDocsAnswered(result);
|
||||||
|
}).show();
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void onChooseArtRequest(List<MtbAart> artsList, RunnableArgs<MtbAart> onComplete) {
|
||||||
|
DialogChooseArtFromListaArts.make(this, artsList, onComplete).show();
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onOrderClosed() {
|
public void onOrderClosed() {
|
||||||
this.onLoadingEnded();
|
this.onLoadingEnded();
|
||||||
|
|||||||
@ -6,6 +6,7 @@ import it.integry.integrywmsnative.core.data_recover.ColliDataRecoverService;
|
|||||||
import it.integry.integrywmsnative.core.rest.consumers.ArticoloRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.ArticoloRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.BarcodeRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.BarcodeRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.ColliMagazzinoRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.ColliMagazzinoRESTConsumer;
|
||||||
|
import it.integry.integrywmsnative.core.rest.consumers.DocumentiRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.OrdiniRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.OrdiniRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.PosizioniRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.PosizioniRESTConsumer;
|
||||||
import it.integry.integrywmsnative.core.rest.consumers.PrinterRESTConsumer;
|
import it.integry.integrywmsnative.core.rest.consumers.PrinterRESTConsumer;
|
||||||
@ -20,8 +21,8 @@ public class SpedizioneModule {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Provides
|
@Provides
|
||||||
SpedizioneViewModel providesSpedizioneViewModel(ArticoloRESTConsumer articoloRESTConsumer, ColliDataRecoverService colliDataRecoverService, OrdiniRESTConsumer ordiniRESTConsumer, ColliMagazzinoRESTConsumer colliMagazzinoRESTConsumer, PrinterRESTConsumer printerRESTConsumer, BarcodeRESTConsumer barcodeRESTConsumer, PosizioniRESTConsumer posizioniRESTConsumer) {
|
SpedizioneViewModel providesSpedizioneViewModel(ArticoloRESTConsumer articoloRESTConsumer, ColliDataRecoverService colliDataRecoverService, OrdiniRESTConsumer ordiniRESTConsumer, ColliMagazzinoRESTConsumer colliMagazzinoRESTConsumer, PrinterRESTConsumer printerRESTConsumer, BarcodeRESTConsumer barcodeRESTConsumer, PosizioniRESTConsumer posizioniRESTConsumer, DocumentiRESTConsumer documentiRESTConsumer) {
|
||||||
return new SpedizioneViewModel(articoloRESTConsumer, barcodeRESTConsumer, colliDataRecoverService, ordiniRESTConsumer, colliMagazzinoRESTConsumer, printerRESTConsumer, posizioniRESTConsumer);
|
return new SpedizioneViewModel(articoloRESTConsumer, barcodeRESTConsumer, colliDataRecoverService, ordiniRESTConsumer, colliMagazzinoRESTConsumer, printerRESTConsumer, posizioniRESTConsumer, documentiRESTConsumer);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@ -9,6 +9,7 @@ import it.integry.integrywmsnative.core.model.MtbAart;
|
|||||||
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.model.dto.PickDataDTO;
|
import it.integry.integrywmsnative.core.model.dto.PickDataDTO;
|
||||||
|
import it.integry.integrywmsnative.core.model.dto.StatoArticoloDTO;
|
||||||
import it.integry.integrywmsnative.core.rest.model.SitArtOrdDTO;
|
import it.integry.integrywmsnative.core.rest.model.SitArtOrdDTO;
|
||||||
|
|
||||||
public class PickingObjectDTO implements Cloneable {
|
public class PickingObjectDTO implements Cloneable {
|
||||||
@ -18,6 +19,7 @@ public class PickingObjectDTO implements Cloneable {
|
|||||||
private List<MtbColt> mtbColts;
|
private List<MtbColt> mtbColts;
|
||||||
|
|
||||||
private PickDataDTO tempPickData;
|
private PickDataDTO tempPickData;
|
||||||
|
private StatoArticoloDTO statoArticoloDTO;
|
||||||
private MtbColt refMtbColt;
|
private MtbColt refMtbColt;
|
||||||
private List<MtbColr> withdrawMtbColrs = new ArrayList<>();
|
private List<MtbColr> withdrawMtbColrs = new ArrayList<>();
|
||||||
|
|
||||||
@ -100,4 +102,13 @@ public class PickingObjectDTO implements Cloneable {
|
|||||||
this.withdrawMtbColrs = withdrawMtbColrs;
|
this.withdrawMtbColrs = withdrawMtbColrs;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO getStatoArticoloDTO() {
|
||||||
|
return statoArticoloDTO;
|
||||||
|
}
|
||||||
|
|
||||||
|
public PickingObjectDTO setStatoArticoloDTO(StatoArticoloDTO statoArticoloDTO) {
|
||||||
|
this.statoArticoloDTO = statoArticoloDTO;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -143,6 +143,13 @@ public class SpedizioneListAdapter extends SectionedRecyclerViewAdapter<Spedizio
|
|||||||
holder.mBinding.subdescrizione2.setText(UtilityString.isNullOrEmpty(pickingObjectDTO.getSubDescrizione2()) ? null : Html.fromHtml(pickingObjectDTO.getSubDescrizione2()));
|
holder.mBinding.subdescrizione2.setText(UtilityString.isNullOrEmpty(pickingObjectDTO.getSubDescrizione2()) ? null : Html.fromHtml(pickingObjectDTO.getSubDescrizione2()));
|
||||||
holder.mBinding.subdescrizione2.setVisibility(UtilityString.isNullOrEmpty(pickingObjectDTO.getSubDescrizione2()) ? View.GONE : View.VISIBLE);
|
holder.mBinding.subdescrizione2.setVisibility(UtilityString.isNullOrEmpty(pickingObjectDTO.getSubDescrizione2()) ? View.GONE : View.VISIBLE);
|
||||||
|
|
||||||
|
if (!UtilityString.isNullOrEmpty(pickingObjectDTO.getFreeQuantity())) {
|
||||||
|
holder.mBinding.freeQty.setText(Html.fromHtml(pickingObjectDTO.getFreeQuantity()));
|
||||||
|
holder.mBinding.freeQty.setVisibility(View.VISIBLE);
|
||||||
|
} else {
|
||||||
|
holder.mBinding.freeQty.setVisibility(View.GONE);
|
||||||
|
}
|
||||||
|
|
||||||
holder.mBinding.qtaEvasa.setText(UtilityNumber.decimalToString(pickingObjectDTO.getQtaEvasa()));
|
holder.mBinding.qtaEvasa.setText(UtilityNumber.decimalToString(pickingObjectDTO.getQtaEvasa()));
|
||||||
holder.mBinding.qtaTot.setText(UtilityNumber.decimalToString(pickingObjectDTO.getQtaTot()));
|
holder.mBinding.qtaTot.setText(UtilityNumber.decimalToString(pickingObjectDTO.getQtaTot()));
|
||||||
|
|
||||||
|
|||||||
@ -22,6 +22,7 @@ public class SpedizioneListModel implements Cloneable {
|
|||||||
private BigDecimal qtaEvasa;
|
private BigDecimal qtaEvasa;
|
||||||
private BigDecimal qtaTot;
|
private BigDecimal qtaTot;
|
||||||
private String untMis;
|
private String untMis;
|
||||||
|
private String freeQuantity;
|
||||||
|
|
||||||
private boolean active;
|
private boolean active;
|
||||||
|
|
||||||
@ -164,4 +165,13 @@ public class SpedizioneListModel implements Cloneable {
|
|||||||
this.mSourceMtbColr = sourceMtbColr;
|
this.mSourceMtbColr = sourceMtbColr;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String getFreeQuantity() {
|
||||||
|
return freeQuantity;
|
||||||
|
}
|
||||||
|
|
||||||
|
public SpedizioneListModel setFreeQuantity(String freeQuantity) {
|
||||||
|
this.freeQuantity = freeQuantity;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -5,6 +5,7 @@ import java.util.Date;
|
|||||||
|
|
||||||
import it.integry.integrywmsnative.core.expansion.RunnableArgsWithReturn;
|
import it.integry.integrywmsnative.core.expansion.RunnableArgsWithReturn;
|
||||||
import it.integry.integrywmsnative.core.model.MtbAart;
|
import it.integry.integrywmsnative.core.model.MtbAart;
|
||||||
|
import it.integry.integrywmsnative.core.model.dto.StatoArticoloDTO;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityBigDecimal;
|
import it.integry.integrywmsnative.core.utility.UtilityBigDecimal;
|
||||||
|
|
||||||
public class DialogInputQuantityV2DTO {
|
public class DialogInputQuantityV2DTO {
|
||||||
@ -40,6 +41,9 @@ public class DialogInputQuantityV2DTO {
|
|||||||
private boolean isFocusOnStart = true;
|
private boolean isFocusOnStart = true;
|
||||||
private boolean canLUBeClosed;
|
private boolean canLUBeClosed;
|
||||||
private boolean saveOnImeDone = false;
|
private boolean saveOnImeDone = false;
|
||||||
|
private boolean notifyProductLotStatus = false;
|
||||||
|
|
||||||
|
private StatoArticoloDTO statoPartitaMag;
|
||||||
|
|
||||||
private String partitaMag;
|
private String partitaMag;
|
||||||
private String note;
|
private String note;
|
||||||
@ -317,4 +321,22 @@ public class DialogInputQuantityV2DTO {
|
|||||||
this.saveOnImeDone = saveOnImeDone;
|
this.saveOnImeDone = saveOnImeDone;
|
||||||
return this;
|
return this;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public StatoArticoloDTO getStatoPartitaMag() {
|
||||||
|
return statoPartitaMag;
|
||||||
|
}
|
||||||
|
|
||||||
|
public DialogInputQuantityV2DTO setStatoPartitaMag(StatoArticoloDTO statoPartitaMag) {
|
||||||
|
this.statoPartitaMag = statoPartitaMag;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
|
||||||
|
public boolean isNotifyProductLotStatus() {
|
||||||
|
return notifyProductLotStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public DialogInputQuantityV2DTO setNotifyProductLotStatus(boolean notifyProductLotStatus) {
|
||||||
|
this.notifyProductLotStatus = notifyProductLotStatus;
|
||||||
|
return this;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -40,6 +40,7 @@ import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
|||||||
import it.integry.integrywmsnative.core.expansion.RunnableArgss;
|
import it.integry.integrywmsnative.core.expansion.RunnableArgss;
|
||||||
import it.integry.integrywmsnative.core.model.MtbAart;
|
import it.integry.integrywmsnative.core.model.MtbAart;
|
||||||
import it.integry.integrywmsnative.core.model.MtbUntMis;
|
import it.integry.integrywmsnative.core.model.MtbUntMis;
|
||||||
|
import it.integry.integrywmsnative.core.model.secondary.StatoPartitaMag;
|
||||||
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
import it.integry.integrywmsnative.core.settings.SettingsManager;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||||
import it.integry.integrywmsnative.core.utility.UtilityFocus;
|
import it.integry.integrywmsnative.core.utility.UtilityFocus;
|
||||||
@ -81,6 +82,7 @@ public class DialogInputQuantityV2View extends BaseDialogFragment implements Dia
|
|||||||
public ObservableField<Boolean> enabledChangePartitaMag = new ObservableField<>(true);
|
public ObservableField<Boolean> enabledChangePartitaMag = new ObservableField<>(true);
|
||||||
public ObservableField<Boolean> enabledNotes = new ObservableField<>(false);
|
public ObservableField<Boolean> enabledNotes = new ObservableField<>(false);
|
||||||
public ObservableField<Boolean> enabledLUCloseButton = new ObservableField<>(true);
|
public ObservableField<Boolean> enabledLUCloseButton = new ObservableField<>(true);
|
||||||
|
public ObservableField<Boolean> showProductLotStatus = new ObservableField<>(false);
|
||||||
|
|
||||||
private final Handler mHandler = new Handler();
|
private final Handler mHandler = new Handler();
|
||||||
|
|
||||||
@ -163,6 +165,10 @@ public class DialogInputQuantityV2View extends BaseDialogFragment implements Dia
|
|||||||
mBindings.setView(this);
|
mBindings.setView(this);
|
||||||
mBindings.setViewmodel(this.mViewModel);
|
mBindings.setViewmodel(this.mViewModel);
|
||||||
|
|
||||||
|
if (mDialogInputQuantityV2DTO.isNotifyProductLotStatus() && mDialogInputQuantityV2DTO.getStatoPartitaMag() != null) {
|
||||||
|
this.initProductLotStatusNotification();
|
||||||
|
}
|
||||||
|
|
||||||
MtbUntMis mtbUntMis = mDialogInputQuantityV2DTO.getMtbAart().getMtbUntMis() != null && mDialogInputQuantityV2DTO.getMtbAart().getMtbUntMis().size() > 0 ? mDialogInputQuantityV2DTO.getMtbAart().getMtbUntMis().get(0) : null;
|
MtbUntMis mtbUntMis = mDialogInputQuantityV2DTO.getMtbAart().getMtbUntMis() != null && mDialogInputQuantityV2DTO.getMtbAart().getMtbUntMis().size() > 0 ? mDialogInputQuantityV2DTO.getMtbAart().getMtbUntMis().get(0) : null;
|
||||||
if (!(mtbUntMis != null && mtbUntMis.isFlagDig())) {
|
if (!(mtbUntMis != null && mtbUntMis.isFlagDig())) {
|
||||||
mBindings.inputQtaTotText.setInputType(InputType.TYPE_CLASS_NUMBER | InputType.TYPE_NUMBER_FLAG_DECIMAL);
|
mBindings.inputQtaTotText.setInputType(InputType.TYPE_CLASS_NUMBER | InputType.TYPE_NUMBER_FLAG_DECIMAL);
|
||||||
@ -194,6 +200,28 @@ public class DialogInputQuantityV2View extends BaseDialogFragment implements Dia
|
|||||||
return mBindings.getRoot();
|
return mBindings.getRoot();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private void initProductLotStatusNotification() {
|
||||||
|
StatoPartitaMag statoPartitaMag = StatoPartitaMag.fromString(this.mDialogInputQuantityV2DTO.getStatoPartitaMag().getStatoArt().toString());
|
||||||
|
if (statoPartitaMag == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
this.mBindings.inputDataScadLayout.setEndIconMode(TextInputLayout.END_ICON_CUSTOM);
|
||||||
|
switch (statoPartitaMag) {
|
||||||
|
case SCADUTO:
|
||||||
|
this.mBindings.inputDataScadLayout.setEndIconDrawable(R.drawable.ic_baseline_warning_24);
|
||||||
|
this.mBindings.inputDataScadLayout.setEndIconTintList(ColorStateList.valueOf(ContextCompat.getColor(requireContext(), R.color.warn_color)));
|
||||||
|
break;
|
||||||
|
case IN_SCADENZA:
|
||||||
|
this.mBindings.inputDataScadLayout.setEndIconDrawable(R.drawable.ic_baseline_warning_24);
|
||||||
|
this.mBindings.inputDataScadLayout.setEndIconTintList(ColorStateList.valueOf(ContextCompat.getColor(requireContext(), R.color.error_color)));
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
this.mBindings.inputDataScadLayout.setEndIconDrawable(R.drawable.ic_check_white_24dp);
|
||||||
|
this.mBindings.inputDataScadLayout.setEndIconTintList(ColorStateList.valueOf(ContextCompat.getColor(requireContext(), R.color.success_color)));
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void onDestroyView() {
|
public void onDestroyView() {
|
||||||
super.onDestroyView();
|
super.onDestroyView();
|
||||||
@ -426,6 +454,7 @@ public class DialogInputQuantityV2View extends BaseDialogFragment implements Dia
|
|||||||
this.enabledChangePartitaMag.set(this.mDialogInputQuantityV2DTO.isCanPartitaMagBeChanged());
|
this.enabledChangePartitaMag.set(this.mDialogInputQuantityV2DTO.isCanPartitaMagBeChanged());
|
||||||
this.mViewModel.shouldAskDataScad = this.mDialogInputQuantityV2DTO.isDataScadMandatory();
|
this.mViewModel.shouldAskDataScad = this.mDialogInputQuantityV2DTO.isDataScadMandatory();
|
||||||
this.enabledNotes.set(this.mDialogInputQuantityV2DTO.isNotesAllowed());
|
this.enabledNotes.set(this.mDialogInputQuantityV2DTO.isNotesAllowed());
|
||||||
|
this.showProductLotStatus.set(SettingsManager.iDB().isNotifyLotStatus());
|
||||||
this.enabledLUCloseButton.set(this.mDialogInputQuantityV2DTO.isCanLUBeClosed());
|
this.enabledLUCloseButton.set(this.mDialogInputQuantityV2DTO.isCanLUBeClosed());
|
||||||
this.currentTaraArticolo.set(this.mViewModel.getMtbAart().getTaraKg());
|
this.currentTaraArticolo.set(this.mViewModel.getMtbAart().getTaraKg());
|
||||||
|
|
||||||
|
|||||||
5
app/src/main/res/drawable/ic_baseline_warning_24.xml
Normal file
5
app/src/main/res/drawable/ic_baseline_warning_24.xml
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
<vector android:height="24dp" android:tint="#000000"
|
||||||
|
android:viewportHeight="24" android:viewportWidth="24"
|
||||||
|
android:width="24dp" xmlns:android="http://schemas.android.com/apk/res/android">
|
||||||
|
<path android:fillColor="@android:color/white" android:pathData="M1,21h22L12,2 1,21zM13,18h-2v-2h2v2zM13,14h-2v-4h2v4z"/>
|
||||||
|
</vector>
|
||||||
@ -32,7 +32,7 @@
|
|||||||
android:paddingLeft="6dp"
|
android:paddingLeft="6dp"
|
||||||
android:paddingRight="6dp"
|
android:paddingRight="6dp"
|
||||||
android:textStyle="bold"
|
android:textStyle="bold"
|
||||||
style="@style/AppTheme.NewMaterial.Text.Small"/>
|
style="@style/AppTheme.NewMaterial.Text.Small" />
|
||||||
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.LinearLayoutCompat
|
<androidx.appcompat.widget.LinearLayoutCompat
|
||||||
@ -57,7 +57,7 @@
|
|||||||
android:textStyle="bold"
|
android:textStyle="bold"
|
||||||
android:textColor="@color/green_700"
|
android:textColor="@color/green_700"
|
||||||
style="@style/AppTheme.NewMaterial.Text.Medium"
|
style="@style/AppTheme.NewMaterial.Text.Medium"
|
||||||
tools:text="QTA"/>
|
tools:text="QTA" />
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
@ -65,7 +65,7 @@
|
|||||||
android:textStyle="bold"
|
android:textStyle="bold"
|
||||||
android:textColor="@android:color/black"
|
android:textColor="@android:color/black"
|
||||||
style="@android:style/TextAppearance.Medium"
|
style="@android:style/TextAppearance.Medium"
|
||||||
android:text=" / "/>
|
android:text=" / " />
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/qta_tot"
|
android:id="@+id/qta_tot"
|
||||||
@ -74,7 +74,7 @@
|
|||||||
android:textStyle="bold"
|
android:textStyle="bold"
|
||||||
android:textColor="@android:color/black"
|
android:textColor="@android:color/black"
|
||||||
style="@style/AppTheme.NewMaterial.Text.Medium"
|
style="@style/AppTheme.NewMaterial.Text.Medium"
|
||||||
tools:text="QTA"/>
|
tools:text="QTA" />
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
android:id="@+id/unt_mis"
|
android:id="@+id/unt_mis"
|
||||||
@ -86,7 +86,7 @@
|
|||||||
android:textAllCaps="true"
|
android:textAllCaps="true"
|
||||||
android:layout_gravity="center_vertical"
|
android:layout_gravity="center_vertical"
|
||||||
style="@style/AppTheme.NewMaterial.Text.Small"
|
style="@style/AppTheme.NewMaterial.Text.Small"
|
||||||
tools:text="cnf"/>
|
tools:text="cnf" />
|
||||||
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatImageButton
|
<androidx.appcompat.widget.AppCompatImageButton
|
||||||
@ -98,7 +98,7 @@
|
|||||||
android:scaleType="fitCenter"
|
android:scaleType="fitCenter"
|
||||||
android:background="@drawable/ic_info_78dp"
|
android:background="@drawable/ic_info_78dp"
|
||||||
android:backgroundTint="@color/colorPrimary"
|
android:backgroundTint="@color/colorPrimary"
|
||||||
android:visibility="gone"/>
|
android:visibility="gone" />
|
||||||
|
|
||||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
|
|
||||||
@ -112,7 +112,7 @@
|
|||||||
android:textSize="16sp"
|
android:textSize="16sp"
|
||||||
android:textColor="@android:color/black"
|
android:textColor="@android:color/black"
|
||||||
style="@style/AppTheme.NewMaterial.Text.Small"
|
style="@style/AppTheme.NewMaterial.Text.Small"
|
||||||
tools:text="DESCRIZIONE"/>
|
tools:text="DESCRIZIONE" />
|
||||||
|
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
@ -131,8 +131,7 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textSize="14sp"
|
android:textSize="14sp"
|
||||||
style="@style/AppTheme.NewMaterial.Text.Small"
|
style="@style/AppTheme.NewMaterial.Text.Small"
|
||||||
tools:text="SUB DESCRIZIONE"/>
|
tools:text="SUB DESCRIZIONE" />
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<androidx.appcompat.widget.AppCompatTextView
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
@ -141,7 +140,15 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:textSize="14sp"
|
android:textSize="14sp"
|
||||||
style="@style/AppTheme.NewMaterial.Text.Small"
|
style="@style/AppTheme.NewMaterial.Text.Small"
|
||||||
tools:text="SUB DESCRIZIONE"/>
|
tools:text="SUB DESCRIZIONE" />
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
|
android:id="@+id/free_qty"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:textSize="14sp"
|
||||||
|
style="@style/AppTheme.NewMaterial.Text.Small"
|
||||||
|
tools:text="QTA OMAGGIO 15 CNF" />
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
@ -160,12 +167,11 @@
|
|||||||
android:layout_marginStart="8dp"
|
android:layout_marginStart="8dp"
|
||||||
android:textStyle="bold"
|
android:textStyle="bold"
|
||||||
android:layout_alignParentEnd="true"
|
android:layout_alignParentEnd="true"
|
||||||
style="@style/AppTheme.NewMaterial.Text.Small"/>
|
style="@style/AppTheme.NewMaterial.Text.Small" />
|
||||||
|
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</androidx.appcompat.widget.LinearLayoutCompat>
|
</androidx.appcompat.widget.LinearLayoutCompat>
|
||||||
|
|
||||||
<View
|
<View
|
||||||
|
|||||||
@ -421,4 +421,5 @@
|
|||||||
<string name="action_create_doc">Crea documento</string>
|
<string name="action_create_doc">Crea documento</string>
|
||||||
<string name="no_arts_found">Nessun articolo compatibile trovato</string>
|
<string name="no_arts_found">Nessun articolo compatibile trovato</string>
|
||||||
<string name="empty_lu">UL vuota</string>
|
<string name="empty_lu">UL vuota</string>
|
||||||
|
<string name="ord_ven_qta_omaggio"><![CDATA[Qta omaggio: <b>%s %s</b>]]></string>
|
||||||
</resources>
|
</resources>
|
||||||
@ -427,4 +427,5 @@
|
|||||||
<string name="action_create_doc">Create document</string>
|
<string name="action_create_doc">Create document</string>
|
||||||
<string name="no_arts_found">No product found</string>
|
<string name="no_arts_found">No product found</string>
|
||||||
<string name="empty_lu">Empty LU</string>
|
<string name="empty_lu">Empty LU</string>
|
||||||
|
<string name="ord_ven_qta_omaggio"><![CDATA[Free qty: <b>%s %s</b>]]></string>
|
||||||
</resources>
|
</resources>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user