Implementazioni varie
This commit is contained in:
parent
90dbe35bd0
commit
70b43c4f09
4
.idea/assetWizardSettings.xml
generated
4
.idea/assetWizardSettings.xml
generated
@ -23,7 +23,7 @@
|
||||
<PersistentState>
|
||||
<option name="values">
|
||||
<map>
|
||||
<entry key="url" value="jar:file:/C:/Program%20Files/Android/Android%20Studio/plugins/android/lib/android.jar!/images/material_design_icons/action/ic_print_black_24dp.xml" />
|
||||
<entry key="url" value="jar:file:/C:/Program%20Files/Android/Android%20Studio/plugins/android/lib/android.jar!/images/material_design_icons/action/ic_delete_black_24dp.xml" />
|
||||
</map>
|
||||
</option>
|
||||
</PersistentState>
|
||||
@ -33,7 +33,7 @@
|
||||
</option>
|
||||
<option name="values">
|
||||
<map>
|
||||
<entry key="outputName" value="ic_print_black_24dp" />
|
||||
<entry key="outputName" value="ic_delete_24dp" />
|
||||
<entry key="sourceFile" value="C:\Users\GiuseppeS" />
|
||||
</map>
|
||||
</option>
|
||||
|
||||
@ -186,6 +186,690 @@ public class MtbAart implements Parcelable{
|
||||
return 0;
|
||||
}
|
||||
|
||||
public String getCodMart() {
|
||||
return codMart;
|
||||
}
|
||||
|
||||
public MtbAart setCodMart(String codMart) {
|
||||
this.codMart = codMart;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDescrizione() {
|
||||
return descrizione;
|
||||
}
|
||||
|
||||
public MtbAart setDescrizione(String descrizione) {
|
||||
this.descrizione = descrizione;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getUntMis() {
|
||||
return untMis;
|
||||
}
|
||||
|
||||
public MtbAart setUntMis(String untMis) {
|
||||
this.untMis = untMis;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getBarCode() {
|
||||
return barCode;
|
||||
}
|
||||
|
||||
public MtbAart setBarCode(String barCode) {
|
||||
this.barCode = barCode;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getPesoKg() {
|
||||
return pesoKg;
|
||||
}
|
||||
|
||||
public MtbAart setPesoKg(BigDecimal pesoKg) {
|
||||
this.pesoKg = pesoKg;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getQtaCnf() {
|
||||
return qtaCnf;
|
||||
}
|
||||
|
||||
public MtbAart setQtaCnf(BigDecimal qtaCnf) {
|
||||
this.qtaCnf = qtaCnf;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodAliq() {
|
||||
return codAliq;
|
||||
}
|
||||
|
||||
public MtbAart setCodAliq(String codAliq) {
|
||||
this.codAliq = codAliq;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodScoArt() {
|
||||
return codScoArt;
|
||||
}
|
||||
|
||||
public MtbAart setCodScoArt(String codScoArt) {
|
||||
this.codScoArt = codScoArt;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodTcolUi() {
|
||||
return codTcolUi;
|
||||
}
|
||||
|
||||
public MtbAart setCodTcolUi(String codTcolUi) {
|
||||
this.codTcolUi = codTcolUi;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodTcolUl() {
|
||||
return codTcolUl;
|
||||
}
|
||||
|
||||
public MtbAart setCodTcolUl(String codTcolUl) {
|
||||
this.codTcolUl = codTcolUl;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getArticoloComposto() {
|
||||
return articoloComposto;
|
||||
}
|
||||
|
||||
public MtbAart setArticoloComposto(String articoloComposto) {
|
||||
this.articoloComposto = articoloComposto;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getEsposizioneComp() {
|
||||
return esposizioneComp;
|
||||
}
|
||||
|
||||
public MtbAart setEsposizioneComp(String esposizioneComp) {
|
||||
this.esposizioneComp = esposizioneComp;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDescrizioneEstesa() {
|
||||
return descrizioneEstesa;
|
||||
}
|
||||
|
||||
public MtbAart setDescrizioneEstesa(String descrizioneEstesa) {
|
||||
this.descrizioneEstesa = descrizioneEstesa;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodUltForn() {
|
||||
return codUltForn;
|
||||
}
|
||||
|
||||
public MtbAart setCodUltForn(String codUltForn) {
|
||||
this.codUltForn = codUltForn;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDataUltCar() {
|
||||
return dataUltCar;
|
||||
}
|
||||
|
||||
public MtbAart setDataUltCar(String dataUltCar) {
|
||||
this.dataUltCar = dataUltCar;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getValUltCar() {
|
||||
return valUltCar;
|
||||
}
|
||||
|
||||
public MtbAart setValUltCar(BigDecimal valUltCar) {
|
||||
this.valUltCar = valUltCar;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodUltClie() {
|
||||
return codUltClie;
|
||||
}
|
||||
|
||||
public MtbAart setCodUltClie(String codUltClie) {
|
||||
this.codUltClie = codUltClie;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDataUltScar() {
|
||||
return dataUltScar;
|
||||
}
|
||||
|
||||
public MtbAart setDataUltScar(String dataUltScar) {
|
||||
this.dataUltScar = dataUltScar;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getValUltScar() {
|
||||
return valUltScar;
|
||||
}
|
||||
|
||||
public MtbAart setValUltScar(BigDecimal valUltScar) {
|
||||
this.valUltScar = valUltScar;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getTipoCodice() {
|
||||
return tipoCodice;
|
||||
}
|
||||
|
||||
public MtbAart setTipoCodice(String tipoCodice) {
|
||||
this.tipoCodice = tipoCodice;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getNote() {
|
||||
return note;
|
||||
}
|
||||
|
||||
public MtbAart setNote(String note) {
|
||||
this.note = note;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getPosizione() {
|
||||
return posizione;
|
||||
}
|
||||
|
||||
public MtbAart setPosizione(String posizione) {
|
||||
this.posizione = posizione;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getColliPedana() {
|
||||
return colliPedana;
|
||||
}
|
||||
|
||||
public MtbAart setColliPedana(BigDecimal colliPedana) {
|
||||
this.colliPedana = colliPedana;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getUntMis2() {
|
||||
return untMis2;
|
||||
}
|
||||
|
||||
public MtbAart setUntMis2(String untMis2) {
|
||||
this.untMis2 = untMis2;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getRapConv2() {
|
||||
return rapConv2;
|
||||
}
|
||||
|
||||
public MtbAart setRapConv2(BigDecimal rapConv2) {
|
||||
this.rapConv2 = rapConv2;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagInclListino() {
|
||||
return flagInclListino;
|
||||
}
|
||||
|
||||
public MtbAart setFlagInclListino(String flagInclListino) {
|
||||
this.flagInclListino = flagInclListino;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getUntMis3() {
|
||||
return untMis3;
|
||||
}
|
||||
|
||||
public MtbAart setUntMis3(String untMis3) {
|
||||
this.untMis3 = untMis3;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getRapConv3() {
|
||||
return rapConv3;
|
||||
}
|
||||
|
||||
public MtbAart setRapConv3(BigDecimal rapConv3) {
|
||||
this.rapConv3 = rapConv3;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodMartStat() {
|
||||
return codMartStat;
|
||||
}
|
||||
|
||||
public MtbAart setCodMartStat(String codMartStat) {
|
||||
this.codMartStat = codMartStat;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodMcon() {
|
||||
return codMcon;
|
||||
}
|
||||
|
||||
public MtbAart setCodMcon(String codMcon) {
|
||||
this.codMcon = codMcon;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodMgrp() {
|
||||
return codMgrp;
|
||||
}
|
||||
|
||||
public MtbAart setCodMgrp(String codMgrp) {
|
||||
this.codMgrp = codMgrp;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodMsfa() {
|
||||
return codMsfa;
|
||||
}
|
||||
|
||||
public MtbAart setCodMsfa(String codMsfa) {
|
||||
this.codMsfa = codMsfa;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodMsgr() {
|
||||
return codMsgr;
|
||||
}
|
||||
|
||||
public MtbAart setCodMsgr(String codMsgr) {
|
||||
this.codMsgr = codMsgr;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodMstp() {
|
||||
return codMstp;
|
||||
}
|
||||
|
||||
public MtbAart setCodMstp(String codMstp) {
|
||||
this.codMstp = codMstp;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodMtip() {
|
||||
return codMtip;
|
||||
}
|
||||
|
||||
public MtbAart setCodMtip(String codMtip) {
|
||||
this.codMtip = codMtip;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDescrizioneStat() {
|
||||
return descrizioneStat;
|
||||
}
|
||||
|
||||
public MtbAart setDescrizioneStat(String descrizioneStat) {
|
||||
this.descrizioneStat = descrizioneStat;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagStato() {
|
||||
return flagStato;
|
||||
}
|
||||
|
||||
public MtbAart setFlagStato(String flagStato) {
|
||||
this.flagStato = flagStato;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getCambioDiviCar() {
|
||||
return cambioDiviCar;
|
||||
}
|
||||
|
||||
public MtbAart setCambioDiviCar(BigDecimal cambioDiviCar) {
|
||||
this.cambioDiviCar = cambioDiviCar;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getCambioDiviScar() {
|
||||
return cambioDiviScar;
|
||||
}
|
||||
|
||||
public MtbAart setCambioDiviScar(BigDecimal cambioDiviScar) {
|
||||
this.cambioDiviScar = cambioDiviScar;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Integer getGgScadPartita() {
|
||||
return ggScadPartita;
|
||||
}
|
||||
|
||||
public MtbAart setGgScadPartita(Integer ggScadPartita) {
|
||||
this.ggScadPartita = ggScadPartita;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getVolumeMc() {
|
||||
return volumeMc;
|
||||
}
|
||||
|
||||
public MtbAart setVolumeMc(BigDecimal volumeMc) {
|
||||
this.volumeMc = volumeMc;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagEsponiPrz() {
|
||||
return flagEsponiPrz;
|
||||
}
|
||||
|
||||
public MtbAart setFlagEsponiPrz(String flagEsponiPrz) {
|
||||
this.flagEsponiPrz = flagEsponiPrz;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDataUltVar() {
|
||||
return dataUltVar;
|
||||
}
|
||||
|
||||
public MtbAart setDataUltVar(String dataUltVar) {
|
||||
this.dataUltVar = dataUltVar;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getPercSfrido() {
|
||||
return percSfrido;
|
||||
}
|
||||
|
||||
public MtbAart setPercSfrido(BigDecimal percSfrido) {
|
||||
this.percSfrido = percSfrido;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodBarreImb() {
|
||||
return codBarreImb;
|
||||
}
|
||||
|
||||
public MtbAart setCodBarreImb(String codBarreImb) {
|
||||
this.codBarreImb = codBarreImb;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagCalcPrz() {
|
||||
return flagCalcPrz;
|
||||
}
|
||||
|
||||
public MtbAart setFlagCalcPrz(String flagCalcPrz) {
|
||||
this.flagCalcPrz = flagCalcPrz;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getEsposizioneCompAcq() {
|
||||
return esposizioneCompAcq;
|
||||
}
|
||||
|
||||
public MtbAart setEsposizioneCompAcq(String esposizioneCompAcq) {
|
||||
this.esposizioneCompAcq = esposizioneCompAcq;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagCalcPrzAcq() {
|
||||
return flagCalcPrzAcq;
|
||||
}
|
||||
|
||||
public MtbAart setFlagCalcPrzAcq(String flagCalcPrzAcq) {
|
||||
this.flagCalcPrzAcq = flagCalcPrzAcq;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDiacod() {
|
||||
return diacod;
|
||||
}
|
||||
|
||||
public MtbAart setDiacod(String diacod) {
|
||||
this.diacod = diacod;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getPlu() {
|
||||
return plu;
|
||||
}
|
||||
|
||||
public MtbAart setPlu(String plu) {
|
||||
this.plu = plu;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getPartIvaProd() {
|
||||
return partIvaProd;
|
||||
}
|
||||
|
||||
public MtbAart setPartIvaProd(String partIvaProd) {
|
||||
this.partIvaProd = partIvaProd;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getRagSocProd() {
|
||||
return ragSocProd;
|
||||
}
|
||||
|
||||
public MtbAart setRagSocProd(String ragSocProd) {
|
||||
this.ragSocProd = ragSocProd;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagRapConvVariabile() {
|
||||
return flagRapConvVariabile;
|
||||
}
|
||||
|
||||
public MtbAart setFlagRapConvVariabile(String flagRapConvVariabile) {
|
||||
this.flagRapConvVariabile = flagRapConvVariabile;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagMovArtMag() {
|
||||
return flagMovArtMag;
|
||||
}
|
||||
|
||||
public MtbAart setFlagMovArtMag(String flagMovArtMag) {
|
||||
this.flagMovArtMag = flagMovArtMag;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagTracciabilita() {
|
||||
return flagTracciabilita;
|
||||
}
|
||||
|
||||
public MtbAart setFlagTracciabilita(String flagTracciabilita) {
|
||||
this.flagTracciabilita = flagTracciabilita;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getTaraKg() {
|
||||
return taraKg;
|
||||
}
|
||||
|
||||
public MtbAart setTaraKg(BigDecimal taraKg) {
|
||||
this.taraKg = taraKg;
|
||||
return this;
|
||||
}
|
||||
|
||||
public BigDecimal getColliStrato() {
|
||||
return colliStrato;
|
||||
}
|
||||
|
||||
public MtbAart setColliStrato(BigDecimal colliStrato) {
|
||||
this.colliStrato = colliStrato;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagQtaCnfFissa() {
|
||||
return flagQtaCnfFissa;
|
||||
}
|
||||
|
||||
public MtbAart setFlagQtaCnfFissa(String flagQtaCnfFissa) {
|
||||
this.flagQtaCnfFissa = flagQtaCnfFissa;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagColliPedanaFisso() {
|
||||
return flagColliPedanaFisso;
|
||||
}
|
||||
|
||||
public MtbAart setFlagColliPedanaFisso(String flagColliPedanaFisso) {
|
||||
this.flagColliPedanaFisso = flagColliPedanaFisso;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodCconCosti() {
|
||||
return codCconCosti;
|
||||
}
|
||||
|
||||
public MtbAart setCodCconCosti(String codCconCosti) {
|
||||
this.codCconCosti = codCconCosti;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodCconRicavi() {
|
||||
return codCconRicavi;
|
||||
}
|
||||
|
||||
public MtbAart setCodCconRicavi(String codCconRicavi) {
|
||||
this.codCconRicavi = codCconRicavi;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodDgrpArt() {
|
||||
return codDgrpArt;
|
||||
}
|
||||
|
||||
public MtbAart setCodDgrpArt(String codDgrpArt) {
|
||||
this.codDgrpArt = codDgrpArt;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodDiviCar() {
|
||||
return codDiviCar;
|
||||
}
|
||||
|
||||
public MtbAart setCodDiviCar(String codDiviCar) {
|
||||
this.codDiviCar = codDiviCar;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodDiviScar() {
|
||||
return codDiviScar;
|
||||
}
|
||||
|
||||
public MtbAart setCodDiviScar(String codDiviScar) {
|
||||
this.codDiviScar = codDiviScar;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodEcrCat() {
|
||||
return codEcrCat;
|
||||
}
|
||||
|
||||
public MtbAart setCodEcrCat(String codEcrCat) {
|
||||
this.codEcrCat = codEcrCat;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodEcrMcat() {
|
||||
return codEcrMcat;
|
||||
}
|
||||
|
||||
public MtbAart setCodEcrMcat(String codEcrMcat) {
|
||||
this.codEcrMcat = codEcrMcat;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodEcrRep() {
|
||||
return codEcrRep;
|
||||
}
|
||||
|
||||
public MtbAart setCodEcrRep(String codEcrRep) {
|
||||
this.codEcrRep = codEcrRep;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodEcrStipo() {
|
||||
return codEcrStipo;
|
||||
}
|
||||
|
||||
public MtbAart setCodEcrStipo(String codEcrStipo) {
|
||||
this.codEcrStipo = codEcrStipo;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodEcrTipo() {
|
||||
return codEcrTipo;
|
||||
}
|
||||
|
||||
public MtbAart setCodEcrTipo(String codEcrTipo) {
|
||||
this.codEcrTipo = codEcrTipo;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodGrpBolla() {
|
||||
return codGrpBolla;
|
||||
}
|
||||
|
||||
public MtbAart setCodGrpBolla(String codGrpBolla) {
|
||||
this.codGrpBolla = codGrpBolla;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getIngredienti() {
|
||||
return ingredienti;
|
||||
}
|
||||
|
||||
public MtbAart setIngredienti(String ingredienti) {
|
||||
this.ingredienti = ingredienti;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getIdArtEqui() {
|
||||
return idArtEqui;
|
||||
}
|
||||
|
||||
public MtbAart setIdArtEqui(String idArtEqui) {
|
||||
this.idArtEqui = idArtEqui;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDescrCassa() {
|
||||
return descrCassa;
|
||||
}
|
||||
|
||||
public MtbAart setDescrCassa(String descrCassa) {
|
||||
this.descrCassa = descrCassa;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodNcIntracee() {
|
||||
return codNcIntracee;
|
||||
}
|
||||
|
||||
public MtbAart setCodNcIntracee(String codNcIntracee) {
|
||||
this.codNcIntracee = codNcIntracee;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getMarchio() {
|
||||
return marchio;
|
||||
}
|
||||
|
||||
public MtbAart setMarchio(String marchio) {
|
||||
this.marchio = marchio;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Integer getSezione() {
|
||||
return sezione;
|
||||
}
|
||||
|
||||
public MtbAart setSezione(Integer sezione) {
|
||||
this.sezione = sezione;
|
||||
return this;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeToParcel(Parcel dest, int flags) {
|
||||
dest.writeString(codMart);
|
||||
@ -274,6 +958,10 @@ public class MtbAart implements Parcelable{
|
||||
dest.writeByte((byte) (0x01));
|
||||
dest.writeInt(sezione);
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@SuppressWarnings("unused")
|
||||
|
||||
@ -8,6 +8,8 @@ import java.text.ParseException;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
|
||||
import it.integry.integrywmsnative.core.utility.UtilityLogger;
|
||||
|
||||
public class MtbColr extends EntityBase implements Parcelable {
|
||||
|
||||
|
||||
@ -334,9 +336,14 @@ public class MtbColr extends EntityBase implements Parcelable {
|
||||
return dataOrd;
|
||||
}
|
||||
|
||||
public Date getDataOrdD() throws ParseException {
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("dd/MM/yyyy HH:mm:ss");
|
||||
return sdf.parse(getDataOrdS());
|
||||
public Date getDataOrdD() {
|
||||
try{
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("dd/MM/yyyy HH:mm:ss");
|
||||
return sdf.parse(getDataOrdS());
|
||||
} catch (ParseException pex){
|
||||
UtilityLogger.errorMe(pex);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
public MtbColr setDataOrd(String dataOrd) {
|
||||
|
||||
@ -2,6 +2,8 @@ package it.integry.integrywmsnative.core.utility;
|
||||
|
||||
import android.util.Log;
|
||||
|
||||
import com.orhanobut.logger.Logger;
|
||||
|
||||
import java.io.PrintStream;
|
||||
import java.io.PrintWriter;
|
||||
import java.io.StringWriter;
|
||||
@ -28,11 +30,11 @@ public class UtilityLogger {
|
||||
|
||||
}
|
||||
|
||||
Log.d("WMS LOGGER", caller + ": " + message);
|
||||
Logger.d(message);
|
||||
}
|
||||
|
||||
public static void errorMe(Exception ex) {
|
||||
ex.printStackTrace(); //Default log
|
||||
//ex.printStackTrace(); //Default log
|
||||
|
||||
String message = UtilityResources.readRawTextFile(R.raw.error_mail);
|
||||
|
||||
|
||||
@ -268,7 +268,7 @@ public class MainAccettazioneFragment extends Fragment implements ICheckBoxCallb
|
||||
+ "<br /><br />" +
|
||||
"<b>" + artsCounter + "</b> " + getActivity().getResources().getQuantityString(R.plurals.available_articles, artsCounter.get())),
|
||||
null,
|
||||
(dialogInterface, i) -> {
|
||||
() -> {
|
||||
|
||||
Intent myIntent = new Intent(getActivity(), AccettazioneOrdineInevasoActivity.class);
|
||||
myIntent.putExtra("key", (ArrayList<OrdineAccettazioneDTO>) ordini); //Optional parameters
|
||||
|
||||
@ -142,6 +142,90 @@ public class OrdineAccettazioneDTO implements Parcelable {
|
||||
}
|
||||
|
||||
|
||||
public Riga setQtaOrd(Float qtaOrd) {
|
||||
this.qtaOrd = qtaOrd;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setQtaRiservate(BigDecimal qtaRiservate) {
|
||||
this.qtaRiservate = qtaRiservate.floatValue();
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setQtaEvasa(Float qtaEvasa) {
|
||||
this.qtaEvasa = qtaEvasa;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setRigaOrd(int rigaOrd) {
|
||||
this.rigaOrd = rigaOrd;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setCodJcom(String codJcom) {
|
||||
this.codJcom = codJcom;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setRagSocCom(String ragSocCom) {
|
||||
this.ragSocCom = ragSocCom;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setDescrizioneCommessa(String descrizioneCommessa) {
|
||||
this.descrizioneCommessa = descrizioneCommessa;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setMtbAart(MtbAart mtbAart) {
|
||||
this.mtbAart = mtbAart;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setHidden(boolean hidden) {
|
||||
this.hidden = hidden;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setPartitaMag(String partitaMag) {
|
||||
this.partitaMag = partitaMag;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setCodArtFor(String codArtFor) {
|
||||
this.codArtFor = codArtFor;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setDescrizioneEstesa(String descrizioneEstesa) {
|
||||
this.descrizioneEstesa = descrizioneEstesa;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setCodAlis(String codAlis) {
|
||||
this.codAlis = codAlis;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setNumOrd(int numOrd) {
|
||||
this.numOrd = numOrd;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setDataOrd(String dataOrd) {
|
||||
this.dataOrd = dataOrd;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setGestioneOrd(String gestioneOrd) {
|
||||
this.gestioneOrd = gestioneOrd;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga setDataCons(String dataCons) {
|
||||
this.dataCons = dataCons;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Riga(){}
|
||||
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package it.integry.integrywmsnative.gest.accettazione_ordine_inevaso;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.databinding.DataBindingUtil;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.os.Bundle;
|
||||
@ -10,10 +11,13 @@ import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.R;
|
||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityLogger;
|
||||
import it.integry.integrywmsnative.databinding.ActivityAccettazioneOrdineInevasoBinding;
|
||||
import it.integry.integrywmsnative.databinding.FragmentArticoliInColloBottomSheetBinding;
|
||||
import it.integry.integrywmsnative.gest.accettazione.dto.OrdineAccettazioneDTO;
|
||||
import it.integry.integrywmsnative.gest.accettazione_ordine_inevaso.viewmodel.AccettazioneOnOrdineInevasoViewModel;
|
||||
import it.integry.integrywmsnative.gest.lista_bancali.ListaBancaliActivity;
|
||||
import it.integry.integrywmsnative.view.bottomsheet.viewmodel.ArticoliInColloBottomSheetViewModel;
|
||||
|
||||
public class AccettazioneOrdineInevasoActivity extends AppCompatActivity {
|
||||
@ -22,6 +26,7 @@ public class AccettazioneOrdineInevasoActivity extends AppCompatActivity {
|
||||
private AccettazioneOnOrdineInevasoViewModel mAccettazioneOrdineInevasoViewModel;
|
||||
private ArticoliInColloBottomSheetViewModel mArticoliInColloBottomSheetViewModel;
|
||||
|
||||
private static final int PICK_UL_REQUEST = 1; // The request code
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
@ -91,4 +96,28 @@ public class AccettazioneOrdineInevasoActivity extends AppCompatActivity {
|
||||
|
||||
|
||||
|
||||
public void startListaBancaliRegistratiActivity(ArrayList<MtbColt> mtbColts){
|
||||
Intent myIntent = new Intent(this, ListaBancaliActivity.class);
|
||||
myIntent.putExtra("key", mtbColts); //Optional parameters
|
||||
myIntent.putExtra(ListaBancaliActivity.Key.CanRecoverUL, true);
|
||||
this.startActivityForResult(myIntent, PICK_UL_REQUEST);
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
|
||||
// Check which request we're responding to
|
||||
if (requestCode == PICK_UL_REQUEST) {
|
||||
// Make sure the request was successful
|
||||
if (resultCode == RESULT_OK) {
|
||||
|
||||
MtbColt recoveredMtbColt = data.getParcelableExtra("key");
|
||||
|
||||
mAccettazioneOrdineInevasoViewModel.recoverUL(recoveredMtbColt);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -110,8 +110,7 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
try {
|
||||
helper.updateListModel(AccettazioneOrdineInevasoOrderBy.Enum.COD_ART_FOR, groupedRighe, null);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
DialogSimpleMessageHelper.makeErrorDialog(mActivity, new SpannableString(e.toString()), null, null).show();
|
||||
UtilityExceptions.defaultException(mActivity, e);
|
||||
}
|
||||
|
||||
mAdapter.setOnOrdineRowDispatchCallback(this);
|
||||
@ -140,13 +139,14 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
|
||||
helper.updateListModel(currentOrderBy, groupedRighe, mtbColrs);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
Toast.makeText(mActivity, e.getMessage(), Toast.LENGTH_LONG).show();
|
||||
|
||||
UtilityLogger.errorMe(e);
|
||||
UtilityExceptions.defaultException(mActivity, e);
|
||||
}
|
||||
}
|
||||
|
||||
public void recoverUL(MtbColt recoveredMtbColt){
|
||||
setULToCurrentContext(recoveredMtbColt);
|
||||
}
|
||||
|
||||
|
||||
public void showOrderDialog() {
|
||||
|
||||
@ -232,10 +232,9 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
@Override
|
||||
public void onSuccess(MtbColt value) {
|
||||
|
||||
isFabVisible.set(false);
|
||||
value.setMtbColr(new ObservableArrayList<>());
|
||||
|
||||
mArticoliInColloBottomSheetViewModel.mtbColt.set(value);
|
||||
setULToCurrentContext(value);
|
||||
|
||||
progress.dismiss();
|
||||
|
||||
@ -270,6 +269,11 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
}
|
||||
|
||||
|
||||
private void setULToCurrentContext(MtbColt mtbColt){
|
||||
isFabVisible.set(false);
|
||||
mArticoliInColloBottomSheetViewModel.mtbColt.set(mtbColt);
|
||||
}
|
||||
|
||||
//Al click di "Mostra UL già create"
|
||||
public void showCreatedUL() {
|
||||
|
||||
@ -284,13 +288,9 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
|
||||
progress.dismiss();
|
||||
|
||||
Intent myIntent = new Intent(mActivity, ListaBancaliActivity.class);
|
||||
myIntent.putExtra("key", (ArrayList<MtbColt>) mtbColts); //Optional parameters
|
||||
mActivity.startActivity(myIntent);
|
||||
mActivity.startListaBancaliRegistratiActivity((ArrayList<MtbColt>) mtbColts);
|
||||
|
||||
}, ex -> {
|
||||
UtilityExceptions.defaultException(mActivity, ex, progress);
|
||||
});
|
||||
}, ex -> UtilityExceptions.defaultException(mActivity, ex, progress));
|
||||
} catch (Exception ex) {
|
||||
UtilityExceptions.defaultException(mActivity, ex, progress);
|
||||
}
|
||||
@ -327,12 +327,21 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
mArticoliInColloBottomSheetViewModel.mtbColt.get(),
|
||||
1, "EtichettaBancale", () ->{
|
||||
|
||||
mArticoliInColloBottomSheetViewModel.mtbColt.set(null);
|
||||
|
||||
isFabVisible.set(true);
|
||||
postCloseOperations();
|
||||
progress.dismiss();
|
||||
|
||||
}, ex -> UtilityExceptions.defaultException(mActivity, ex, progress));
|
||||
}, ex -> {
|
||||
|
||||
progress.dismiss();
|
||||
String errorMessage = ex.getMessage();
|
||||
DialogSimpleMessageHelper.makeErrorDialog(
|
||||
mActivity,
|
||||
new SpannableString(errorMessage),
|
||||
null,
|
||||
null,
|
||||
R.string.button_ignore_print,
|
||||
() -> postCloseOperations()).show();
|
||||
});
|
||||
|
||||
|
||||
} else {
|
||||
@ -348,13 +357,7 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
|
||||
@Override
|
||||
public void onFailed(Exception ex) {
|
||||
progress.dismiss();
|
||||
String errorMessage = CommonRESTException.tryRecognizeThenGetMessage(ex);
|
||||
|
||||
if(errorMessage == null) errorMessage = ex.getMessage();
|
||||
DialogSimpleMessageHelper.makeErrorDialog(mActivity, new SpannableString(errorMessage), null, null).show();
|
||||
|
||||
UtilityLogger.errorMe(ex);
|
||||
UtilityExceptions.defaultException(mActivity, ex, progress);
|
||||
}
|
||||
});
|
||||
|
||||
@ -396,6 +399,44 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
mArticoliInColloBottomSheetViewModel.mtbColt.get().getMtbColr().size() > 0;
|
||||
}
|
||||
|
||||
|
||||
|
||||
private void postCloseOperations() {
|
||||
// for(int i = 0; i < groupedOrdini.size(); i++){
|
||||
// if(groupedOrdini.get(i).getQtaDaEvadere().floatValue() <= 0){
|
||||
// this.groupedOrdini.remove(i);
|
||||
// i--;
|
||||
// }
|
||||
// }
|
||||
|
||||
MtbColt mtbColtToDelete = mArticoliInColloBottomSheetViewModel.mtbColt.get();
|
||||
|
||||
mArticoliInColloBottomSheetViewModel.mtbColt.set(null);
|
||||
isFabVisible.set(true);
|
||||
|
||||
if(mtbColtToDelete != null && mtbColtToDelete.getMtbColr() != null) {
|
||||
for (int i = 0; i < mtbColtToDelete.getMtbColr().size(); i++) {
|
||||
|
||||
MtbColr currentRow = mtbColtToDelete.getMtbColr().get(i);
|
||||
|
||||
Stream.of(this.groupedOrdini)
|
||||
.filter(x ->
|
||||
x.getQtaDaEvadere().floatValue() > 0 &&
|
||||
x.getMtbAart().getCodMart().equalsIgnoreCase(currentRow.getCodMart()) &&
|
||||
x.getCodJcom().equalsIgnoreCase(currentRow.getCodJcom()) &&
|
||||
x.getRigaOrd() == currentRow.getRigaOrd() &&
|
||||
x.getDataOrd().equals(currentRow.getDataOrdD()) &&
|
||||
x.getNumOrd() == currentRow.getNumOrd()
|
||||
)
|
||||
.forEach(x -> x.setQtaRiservate(x.getQtaRiservate().add(currentRow.getQtaCol())));
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
refreshOrderBy();
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onOrdineRowDispatch(final OrdineAccettazioneDTO.Riga item) {
|
||||
if(mArticoliInColloBottomSheetViewModel.mtbColt.get() != null){
|
||||
@ -417,8 +458,6 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
float qtaEvasa = item.qtaRiservate + qtaEvasaInMtbColr;
|
||||
|
||||
DialogInputQuantity.makeBase(mActivity, item, qtaEvasa, value -> onOrdineRowDispatched(item, value)).show();
|
||||
|
||||
// Toast.makeText(mActivity, item.descrizioneEstesa, Toast.LENGTH_LONG).show();
|
||||
}
|
||||
}
|
||||
|
||||
@ -448,6 +487,9 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
ColliMagazzinoRESTConsumer.saveCollo(cloneMtbColt, new ISimpleOperationCallback<MtbColt>() {
|
||||
@Override
|
||||
public void onSuccess(MtbColt value) {
|
||||
|
||||
mtbColr.setUntMis(item.getMtbAart().untMis);
|
||||
|
||||
mArticoliInColloBottomSheetViewModel.mtbColt.get().getMtbColr().add(mtbColr);
|
||||
refreshOrderBy();
|
||||
|
||||
@ -464,15 +506,8 @@ public class AccettazioneOnOrdineInevasoViewModel implements IOnColloClosedCallb
|
||||
|
||||
@Override
|
||||
public void onFailed(Exception ex) {
|
||||
progress.dismiss();
|
||||
String errorMessage = CommonRESTException.tryRecognizeThenGetMessage(ex);
|
||||
|
||||
if(errorMessage == null) errorMessage = ex.getMessage();
|
||||
DialogSimpleMessageHelper.makeErrorDialog(mActivity, new SpannableString(errorMessage), null, null).show();
|
||||
UtilityExceptions.defaultException(mActivity, ex, progress);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package it.integry.integrywmsnative.gest.contenuto_bancale;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.databinding.DataBindingUtil;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.os.Bundle;
|
||||
@ -9,20 +10,27 @@ import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.databinding.ActivityContenutoBancaleBinding;
|
||||
import it.integry.integrywmsnative.gest.contenuto_bancale.viewmodel.ContenutoBancaleViewModel;
|
||||
|
||||
import static it.integry.integrywmsnative.gest.contenuto_bancale.ContenutoBancaleActivity.Key.CanRecoverUL;
|
||||
|
||||
public class ContenutoBancaleActivity extends AppCompatActivity {
|
||||
|
||||
public ActivityContenutoBancaleBinding bindings;
|
||||
|
||||
private ContenutoBancaleViewModel mViewModel;
|
||||
|
||||
public static class Key {
|
||||
public static final String CanRecoverUL = "canRecoverUL";
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
|
||||
bindings = DataBindingUtil.setContentView(this, R.layout.activity_contenuto_bancale);
|
||||
|
||||
boolean canRecoverUL = getIntent().getBooleanExtra(CanRecoverUL, false);
|
||||
MtbColt mtbColt = getIntent().getParcelableExtra("key");
|
||||
mViewModel = new ContenutoBancaleViewModel(this, mtbColt);
|
||||
mViewModel = new ContenutoBancaleViewModel(this, mtbColt, canRecoverUL);
|
||||
|
||||
bindings.waterfallToolbar.setNestedScrollView(bindings.scrollView);
|
||||
|
||||
@ -38,4 +46,6 @@ public class ContenutoBancaleActivity extends AppCompatActivity {
|
||||
onBackPressed();
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -2,6 +2,7 @@ package it.integry.integrywmsnative.gest.contenuto_bancale.viewmodel;
|
||||
|
||||
import android.app.AlertDialog;
|
||||
import android.app.ProgressDialog;
|
||||
import android.content.Intent;
|
||||
import android.content.res.Resources;
|
||||
import android.databinding.ObservableField;
|
||||
import android.support.v4.content.ContextCompat;
|
||||
@ -16,6 +17,7 @@ import it.integry.integrywmsnative.core.REST.consumers.DepositoRESTConsumer;
|
||||
import it.integry.integrywmsnative.core.REST.consumers.ISimpleOperationCallback;
|
||||
import it.integry.integrywmsnative.core.REST.consumers.PrinterRESTConsumer;
|
||||
import it.integry.integrywmsnative.core.di.BindableString;
|
||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||
import it.integry.integrywmsnative.core.interfaces.IRecyclerItemClicked;
|
||||
import it.integry.integrywmsnative.core.model.MtbColr;
|
||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
@ -26,6 +28,8 @@ import it.integry.integrywmsnative.gest.contenuto_bancale.ContenutoBancaleActivi
|
||||
import it.integry.integrywmsnative.gest.contenuto_bancale.core.ContenutoBancaleListAdapter;
|
||||
import it.integry.integrywmsnative.view.dialogs.DialogSimpleMessageHelper;
|
||||
|
||||
import static android.app.Activity.RESULT_OK;
|
||||
|
||||
public class ContenutoBancaleViewModel implements IRecyclerItemClicked<MtbColr> {
|
||||
|
||||
private ContenutoBancaleActivity mContext;
|
||||
@ -34,13 +38,15 @@ public class ContenutoBancaleViewModel implements IRecyclerItemClicked<MtbColr>
|
||||
public BindableString descrizioneDepo = new BindableString();
|
||||
|
||||
public ObservableField<Boolean> isFabVisible = new ObservableField<>();
|
||||
public ObservableField<Boolean> isRecoverFabMenuVisible = new ObservableField<>();
|
||||
|
||||
private ContenutoBancaleListAdapter mAdapter;
|
||||
|
||||
public ContenutoBancaleViewModel(ContenutoBancaleActivity context, MtbColt mtbColt){
|
||||
public ContenutoBancaleViewModel(ContenutoBancaleActivity context, MtbColt mtbColt, boolean canRecoverUL){
|
||||
mContext = context;
|
||||
this.mtbColt = new ObservableField<>(mtbColt);
|
||||
this.isFabVisible.set(true);
|
||||
this.isRecoverFabMenuVisible.set(canRecoverUL);
|
||||
|
||||
mContext.bindings.setViewModel(this);
|
||||
|
||||
@ -77,13 +83,16 @@ public class ContenutoBancaleViewModel implements IRecyclerItemClicked<MtbColr>
|
||||
|
||||
@Override
|
||||
public void onItemClick(MtbColr item, int position) {
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public void recoverUL(){
|
||||
Intent data = new Intent();
|
||||
data.putExtra("key", mtbColt.get());
|
||||
|
||||
mContext.setResult(RESULT_OK, data);
|
||||
mContext.finish();
|
||||
}
|
||||
|
||||
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package it.integry.integrywmsnative.gest.lista_bancali;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.databinding.DataBindingUtil;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.os.Bundle;
|
||||
@ -9,24 +10,39 @@ import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.R;
|
||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityLogger;
|
||||
import it.integry.integrywmsnative.databinding.ActivityListaBancaliBinding;
|
||||
import it.integry.integrywmsnative.gest.contenuto_bancale.ContenutoBancaleActivity;
|
||||
import it.integry.integrywmsnative.gest.lista_bancali.viewmodel.ListaBancaliViewModel;
|
||||
|
||||
import static it.integry.integrywmsnative.gest.lista_bancali.ListaBancaliActivity.Key.CanRecoverUL;
|
||||
|
||||
public class ListaBancaliActivity extends AppCompatActivity {
|
||||
|
||||
public static class Key {
|
||||
public static final String CanRecoverUL = "canRecoverUL";
|
||||
}
|
||||
|
||||
public ActivityListaBancaliBinding bindings;
|
||||
|
||||
private ListaBancaliViewModel mViewModel;
|
||||
|
||||
private boolean mCanRecoverUl;
|
||||
|
||||
private static final int PICK_UL_REQUEST = 1; // The request code
|
||||
|
||||
|
||||
@Override
|
||||
protected void onCreate(Bundle savedInstanceState) {
|
||||
super.onCreate(savedInstanceState);
|
||||
bindings = DataBindingUtil.setContentView(this, R.layout.activity_lista_bancali);
|
||||
|
||||
|
||||
mCanRecoverUl = getIntent().getBooleanExtra(CanRecoverUL, false);
|
||||
List<MtbColt> mtbColts = (ArrayList<MtbColt>)getIntent().getSerializableExtra("key");
|
||||
mViewModel = new ListaBancaliViewModel(this, mtbColts);
|
||||
|
||||
|
||||
setSupportActionBar(this.bindings.toolbar);
|
||||
getSupportActionBar().setDisplayHomeAsUpEnabled(true);
|
||||
|
||||
@ -38,4 +54,29 @@ public class ListaBancaliActivity extends AppCompatActivity {
|
||||
onBackPressed();
|
||||
return true;
|
||||
}
|
||||
|
||||
public void startContenutoBancaleActivity(MtbColt item){
|
||||
Intent myIntent = new Intent(this, ContenutoBancaleActivity.class);
|
||||
myIntent.putExtra("key", item); //Optional parameters
|
||||
myIntent.putExtra(ContenutoBancaleActivity.Key.CanRecoverUL, mCanRecoverUl);
|
||||
startActivityForResult(myIntent, PICK_UL_REQUEST);
|
||||
}
|
||||
|
||||
|
||||
|
||||
@Override
|
||||
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
|
||||
// Check which request we're responding to
|
||||
if (requestCode == PICK_UL_REQUEST) {
|
||||
// Make sure the request was successful
|
||||
if (resultCode == RESULT_OK) {
|
||||
|
||||
// MtbColt recoveredMtbColt = data.getParcelableExtra("key");
|
||||
|
||||
|
||||
this.setResult(RESULT_OK, data);
|
||||
this.finish();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@ -28,10 +28,13 @@ import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityDB;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityDate;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityLogger;
|
||||
import it.integry.integrywmsnative.gest.contenuto_bancale.ContenutoBancaleActivity;
|
||||
import it.integry.integrywmsnative.gest.lista_bancali.ListaBancaliActivity;
|
||||
import it.integry.integrywmsnative.gest.lista_bancali.core.MainListListaColliAdapter;
|
||||
|
||||
import static android.app.Activity.RESULT_OK;
|
||||
|
||||
public class ListaBancaliViewModel implements IRecyclerItemClicked<MtbColt> {
|
||||
|
||||
private ListaBancaliActivity mContext;
|
||||
@ -91,9 +94,8 @@ public class ListaBancaliViewModel implements IRecyclerItemClicked<MtbColt> {
|
||||
|
||||
progress.dismiss();
|
||||
|
||||
Intent myIntent = new Intent(mContext, ContenutoBancaleActivity.class);
|
||||
myIntent.putExtra("key", item); //Optional parameters
|
||||
mContext.startActivity(myIntent);
|
||||
mContext.startContenutoBancaleActivity(item);
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
@ -109,4 +111,5 @@ public class ListaBancaliViewModel implements IRecyclerItemClicked<MtbColt> {
|
||||
UtilityExceptions.defaultException(mContext, e, progress);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -203,7 +203,7 @@ public class LoginViewModel {
|
||||
title,
|
||||
message,
|
||||
null,
|
||||
(dialogInterface, i) -> showProfileDBSelectionDialog(host, port, availableProfiles)).show());
|
||||
() -> showProfileDBSelectionDialog(host, port, availableProfiles)).show());
|
||||
}
|
||||
|
||||
private void showProfileDBSelectionDialog(final String host, final int port, final List<String> availableProfiles){
|
||||
|
||||
@ -74,15 +74,10 @@ public class ArticoliInColloBottomSheetHelper extends BottomSheetBehavior.Bottom
|
||||
}
|
||||
|
||||
public void initCollo(MtbColt mtbColt){
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("dd MMM yyyy");
|
||||
|
||||
mBinding.articoliInColloTitle.setText(String.format(mActivity.getText(R.string.articoli_in_collo_sheet_title).toString(), mtbColt.getNumCollo()));
|
||||
try {
|
||||
mBinding.articoliInColloDetailsDate.setText(sdf.format(mtbColt.getDataColloD()));
|
||||
} catch (ParseException e) {
|
||||
e.printStackTrace();
|
||||
DialogSimpleMessageHelper.makeErrorDialog(mActivity, new SpannableString(e.toString()), null, null).show();
|
||||
}
|
||||
mBinding.articoliInColloDetailsDate.setText(mtbColt.getDataColloHumanLong());
|
||||
|
||||
|
||||
mBinding.articoliInColloDetailsPosizione.setText(mtbColt.getPosizione() != null ? mtbColt.getPosizione() : "N/A");
|
||||
// bindings.articoliInColloDetailsPreparatoDa.setText(mtbColt.getPreparatoDa() != null ? mtbColt.getPreparatoDa() : "N/A");
|
||||
|
||||
@ -6,18 +6,24 @@ import android.databinding.Observable;
|
||||
import android.databinding.ObservableField;
|
||||
import android.databinding.ObservableList;
|
||||
import android.databinding.ViewDataBinding;
|
||||
import android.support.annotation.NonNull;
|
||||
import android.support.design.widget.BottomSheetBehavior;
|
||||
import android.support.v7.app.AppCompatActivity;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.view.ViewGroup;
|
||||
import android.widget.BaseAdapter;
|
||||
|
||||
import com.linearlistview.LinearListView;
|
||||
|
||||
import java.lang.ref.WeakReference;
|
||||
|
||||
import it.integry.integrywmsnative.BR;
|
||||
import it.integry.integrywmsnative.R;
|
||||
import it.integry.integrywmsnative.core.expansion.RunnableArgs;
|
||||
import it.integry.integrywmsnative.core.model.MtbColr;
|
||||
import it.integry.integrywmsnative.core.model.MtbColt;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityNumber;
|
||||
import it.integry.integrywmsnative.databinding.FragmentArticoliInColloBottomSheetBinding;
|
||||
import it.integry.integrywmsnative.view.bottomsheet.ArticoliInColloBottomSheetHelper;
|
||||
import it.integry.integrywmsnative.view.bottomsheet.interfaces.IOnColloClosedCallback;
|
||||
@ -33,8 +39,14 @@ public class ArticoliInColloBottomSheetViewModel {
|
||||
private IOnColloClosedCallback onCloseColloCallback;
|
||||
|
||||
|
||||
public ArticoliInColloBottomSheetViewModel(AppCompatActivity context, final FragmentArticoliInColloBottomSheetBinding mBindings){
|
||||
private FragmentArticoliInColloBottomSheetBinding mBindings;
|
||||
|
||||
private BottomSheetBehavior mBottomSheetBehavior;
|
||||
|
||||
|
||||
public ArticoliInColloBottomSheetViewModel(AppCompatActivity context, final FragmentArticoliInColloBottomSheetBinding bindings){
|
||||
mContext = context;
|
||||
mBindings = bindings;
|
||||
mArticoliInColloBottomSheetHelper = new ArticoliInColloBottomSheetHelper(context, mBindings);
|
||||
|
||||
mBindings.setViewModel(this);
|
||||
@ -44,20 +56,44 @@ public class ArticoliInColloBottomSheetViewModel {
|
||||
public void onPropertyChanged(Observable sender, int propertyId) {
|
||||
mBindings.linearListview.setAdapter(new ArticoliInColloBottomSheetMtbColrAdapter());
|
||||
|
||||
mBindings.linearListview.setOnItemClickListener((parent, view, position, id) -> {
|
||||
mBottomSheetBehavior.setState(BottomSheetBehavior.STATE_EXPANDED);
|
||||
|
||||
onItemClicked.run(position);
|
||||
});
|
||||
|
||||
if(mtbColt.get() != null) {
|
||||
mArticoliInColloBottomSheetHelper.updateRigheNumber(mtbColt.get().getMtbColr().size());
|
||||
mArticoliInColloBottomSheetHelper.initCollo(mtbColt.get());
|
||||
|
||||
mtbColt.get().getMtbColr().addOnListChangedCallback(new SimpleListChangedCallback(new IOnSimpleListChangedCallback() {
|
||||
@Override
|
||||
public void onChange() {
|
||||
mArticoliInColloBottomSheetHelper.updateRigheNumber(mtbColt.get().getMtbColr().size());
|
||||
}
|
||||
mtbColt.get().getMtbColr().addOnListChangedCallback(new SimpleListChangedCallback(() -> {
|
||||
mArticoliInColloBottomSheetHelper.updateRigheNumber(mtbColt.get().getMtbColr().size());
|
||||
}));
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
initBottomSheetActions();
|
||||
}
|
||||
|
||||
private void initBottomSheetActions() {
|
||||
mBindings.bg.setOnClickListener(v -> mBottomSheetBehavior.setState(BottomSheetBehavior.STATE_COLLAPSED));
|
||||
|
||||
mBottomSheetBehavior = BottomSheetBehavior.from(mBindings.bottomSheetActions);
|
||||
|
||||
mBottomSheetBehavior.setBottomSheetCallback(new BottomSheetBehavior.BottomSheetCallback() {
|
||||
@Override
|
||||
public void onStateChanged(@NonNull View bottomSheet, int newState) {
|
||||
if (newState == BottomSheetBehavior.STATE_COLLAPSED)
|
||||
mBindings.bg.setVisibility(View.GONE);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onSlide(@NonNull View bottomSheet, float slideOffset) {
|
||||
mBindings.bg.setVisibility(View.VISIBLE);
|
||||
mBindings.bg.setAlpha(slideOffset);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
public void setOnCloseColloCallbackListener(final IOnColloClosedCallback onCloseColloCallback){
|
||||
@ -81,6 +117,20 @@ public class ArticoliInColloBottomSheetViewModel {
|
||||
mArticoliInColloBottomSheetHelper.collapse();
|
||||
}
|
||||
|
||||
|
||||
private RunnableArgs<Integer> onItemClicked = (position) -> {
|
||||
|
||||
MtbColr clickedItem = mtbColt.get().getMtbColr().get(position);
|
||||
|
||||
mBindings.bottomSheetActionsTitle.setText(clickedItem.getDescrizione());
|
||||
mBindings.bottomSheetActionsSubtitle.setText(clickedItem.getCodMart());
|
||||
|
||||
mBindings.bottomSheetActionsQuantity.setText(UtilityNumber.decimalToString(clickedItem.getQtaCol()) + " " + clickedItem.getUntMis());
|
||||
|
||||
|
||||
};
|
||||
|
||||
|
||||
public class ArticoliInColloBottomSheetMtbColrAdapter extends BaseAdapter {
|
||||
|
||||
|
||||
@ -174,6 +224,6 @@ public class ArticoliInColloBottomSheetViewModel {
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -2,27 +2,21 @@ package it.integry.integrywmsnative.view.dialogs;
|
||||
|
||||
import android.app.AlertDialog;
|
||||
import android.content.Context;
|
||||
import android.content.DialogInterface;
|
||||
import android.content.res.ColorStateList;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.support.constraint.ConstraintLayout;
|
||||
import android.support.annotation.StringRes;
|
||||
import android.support.v4.content.ContextCompat;
|
||||
import android.support.v7.widget.AppCompatImageView;
|
||||
import android.support.v7.widget.AppCompatTextView;
|
||||
import android.text.Html;
|
||||
import android.text.Spanned;
|
||||
import android.view.LayoutInflater;
|
||||
import android.view.View;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.LinearLayout;
|
||||
import android.widget.RelativeLayout;
|
||||
import android.widget.TextView;
|
||||
|
||||
import java.util.HashMap;
|
||||
|
||||
import de.hdodenhof.circleimageview.CircleImageView;
|
||||
import it.integry.integrywmsnative.R;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityDimension;
|
||||
|
||||
/**
|
||||
* Created by GiuseppeS on 22/03/2018.
|
||||
@ -52,7 +46,7 @@ public class DialogSimpleMessageHelper {
|
||||
}
|
||||
}
|
||||
|
||||
private static AlertDialog makeBase(TYPE type, Context mContext, String titleText, Spanned messageText, HashMap<String, String> hashmapContent, DialogInterface.OnClickListener onPositiveClick, DialogInterface.OnClickListener onNegativeClick){
|
||||
private static AlertDialog makeBase(TYPE type, Context mContext, String titleText, Spanned messageText, HashMap<String, String> hashmapContent, Runnable onPositiveClick, Runnable onNegativeClick, @StringRes int rNeutralButtonString, Runnable onNeutralClick){
|
||||
LayoutInflater inflater = (LayoutInflater) mContext.getSystemService( Context.LAYOUT_INFLATER_SERVICE );
|
||||
|
||||
int colorBackgroundTitle = -1;
|
||||
@ -115,10 +109,15 @@ public class DialogSimpleMessageHelper {
|
||||
.setCustomTitle(titleView)
|
||||
.setView(contentView)
|
||||
// .setMessage(messageText)
|
||||
.setPositiveButton(mContext.getText(R.string.ok), onPositiveClick);
|
||||
.setPositiveButton(mContext.getText(R.string.ok), (dialog, which) -> {
|
||||
if(onPositiveClick != null) onPositiveClick.run();
|
||||
});
|
||||
|
||||
if(onNeutralClick != null){
|
||||
alertDialog.setNeutralButton(rNeutralButtonString, (dialog, which) -> onNeutralClick.run());
|
||||
}
|
||||
if(onNegativeClick != null){
|
||||
alertDialog.setNegativeButton(mContext.getText(R.string.abort), onNegativeClick);
|
||||
alertDialog.setNegativeButton(mContext.getText(R.string.abort), (dialog, which) -> onNegativeClick.run());
|
||||
}
|
||||
|
||||
AlertDialog alert = alertDialog.create();
|
||||
@ -128,39 +127,39 @@ public class DialogSimpleMessageHelper {
|
||||
}
|
||||
|
||||
|
||||
public static AlertDialog makeInfoDialog(Context mContext, String titleText, Spanned messageText, HashMap<String, String> hashmapContent, DialogInterface.OnClickListener onPositiveClick){
|
||||
public static AlertDialog makeInfoDialog(Context mContext, String titleText, Spanned messageText, HashMap<String, String> hashmapContent, Runnable onPositiveClick){
|
||||
return makeBase(TYPE.INFO,
|
||||
mContext,
|
||||
titleText,
|
||||
messageText,
|
||||
hashmapContent,
|
||||
onPositiveClick,
|
||||
null);
|
||||
null, -1, null);
|
||||
}
|
||||
|
||||
|
||||
public static AlertDialog makeSuccessDialog(Context mContext, String titleText, Spanned messageText, HashMap<String, String> hashmapContent, DialogInterface.OnClickListener onPositiveClick){
|
||||
public static AlertDialog makeSuccessDialog(Context mContext, String titleText, Spanned messageText, HashMap<String, String> hashmapContent, Runnable onPositiveClick){
|
||||
return makeBase(TYPE.SUCCESS,
|
||||
mContext,
|
||||
titleText,
|
||||
messageText,
|
||||
hashmapContent,
|
||||
onPositiveClick,
|
||||
null);
|
||||
null, -1, null);
|
||||
}
|
||||
|
||||
|
||||
public static AlertDialog makeWarningDialog(Context mContext, Spanned messageText, HashMap<String, String> hashmapContent, DialogInterface.OnClickListener onPositiveClick){
|
||||
public static AlertDialog makeWarningDialog(Context mContext, Spanned messageText, HashMap<String, String> hashmapContent, Runnable onPositiveClick){
|
||||
return makeBase(TYPE.WARNING,
|
||||
mContext,
|
||||
mContext.getText(R.string.warning).toString(),
|
||||
messageText,
|
||||
hashmapContent,
|
||||
onPositiveClick,
|
||||
null);
|
||||
null, -1, null);
|
||||
}
|
||||
|
||||
public static AlertDialog makeErrorDialog(Context mContext, Spanned messageText, HashMap<String, String> hashmapContent, DialogInterface.OnClickListener onPositiveClick){
|
||||
public static AlertDialog makeErrorDialog(Context mContext, Spanned messageText, HashMap<String, String> hashmapContent, Runnable onPositiveClick){
|
||||
|
||||
return makeBase(TYPE.ERROR,
|
||||
mContext,
|
||||
@ -168,7 +167,18 @@ public class DialogSimpleMessageHelper {
|
||||
messageText,
|
||||
hashmapContent,
|
||||
onPositiveClick,
|
||||
null);
|
||||
null, -1, null);
|
||||
}
|
||||
|
||||
public static AlertDialog makeErrorDialog(Context mContext, Spanned messageText, HashMap<String, String> hashmapContent, Runnable onPositiveClick, @StringRes int rNeutralButtonString, Runnable onNeutralClick){
|
||||
|
||||
return makeBase(TYPE.ERROR,
|
||||
mContext,
|
||||
mContext.getText(R.string.error).toString(),
|
||||
messageText,
|
||||
hashmapContent,
|
||||
onPositiveClick,
|
||||
null, rNeutralButtonString, onNeutralClick);
|
||||
|
||||
}
|
||||
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 517 KiB |
9
app/src/main/res/drawable/ic_delete_24dp.xml
Normal file
9
app/src/main/res/drawable/ic_delete_24dp.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24.0"
|
||||
android:viewportHeight="24.0">
|
||||
<path
|
||||
android:fillColor="#FF000000"
|
||||
android:pathData="M6,19c0,1.1 0.9,2 2,2h8c1.1,0 2,-0.9 2,-2V7H6v12zM19,4h-3.5l-1,-1h-5l-1,1H5v2h14V4z"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/ic_edit_24dp.xml
Normal file
9
app/src/main/res/drawable/ic_edit_24dp.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24.0"
|
||||
android:viewportHeight="24.0">
|
||||
<path
|
||||
android:fillColor="#FF000000"
|
||||
android:pathData="M3,17.25V21h3.75L17.81,9.94l-3.75,-3.75L3,17.25zM20.71,7.04c0.39,-0.39 0.39,-1.02 0,-1.41l-2.34,-2.34c-0.39,-0.39 -1.02,-0.39 -1.41,0l-1.83,1.83 3.75,3.75 1.83,-1.83z"/>
|
||||
</vector>
|
||||
9
app/src/main/res/drawable/ic_recover_ul_24dp.xml
Normal file
9
app/src/main/res/drawable/ic_recover_ul_24dp.xml
Normal file
@ -0,0 +1,9 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="24dp"
|
||||
android:height="24dp"
|
||||
android:viewportWidth="24.0"
|
||||
android:viewportHeight="24.0">
|
||||
<path
|
||||
android:fillColor="@color/colorPrimary"
|
||||
android:pathData="M7,8L7,5l-7,7 7,7v-3l-4,-4 4,-4zM13,9L13,5l-7,7 7,7v-4.1c5,0 8.5,1.6 11,5.1 -1,-5 -4,-10 -11,-11z"/>
|
||||
</vector>
|
||||
@ -92,7 +92,8 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="4dp"
|
||||
style="@android:style/TextAppearance.Medium"
|
||||
android:textSize="16sp"
|
||||
android:textColor="@android:color/black"
|
||||
android:text="DESCRIZIONE"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
@ -227,12 +227,14 @@
|
||||
android:id="@+id/accettazione_ordine_inevaso_fab_item1"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:src="@drawable/ic_box"
|
||||
android:src="@drawable/ic_recover_ul_24dp"
|
||||
android:visibility="@{viewModel.isRecoverFabMenuVisible ? View.VISIBLE : View.GONE}"
|
||||
app:fab_colorNormal="@color/white"
|
||||
app:fab_colorPressed="@color/white_pressed"
|
||||
app:fab_colorRipple="#66FFFFFF"
|
||||
app:onClick="@{() -> viewModel.recoverUL()}"
|
||||
fab:fab_label="@string/action_recover_ul" />
|
||||
fab:fab_label="@string/action_recover_ul"
|
||||
android:scaleX="-1" />
|
||||
|
||||
<com.github.clans.fab.FloatingActionButton
|
||||
android:id="@+id/accettazione_ordine_inevaso_fab_item2"
|
||||
|
||||
@ -1,5 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<layout>
|
||||
<layout xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
|
||||
<data>
|
||||
<variable
|
||||
@ -10,8 +12,6 @@
|
||||
</data>
|
||||
|
||||
<android.support.design.widget.CoordinatorLayout
|
||||
xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/bottom_sheet1"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
@ -40,12 +40,13 @@
|
||||
android:background="@android:color/white">
|
||||
|
||||
|
||||
<android.support.v7.widget.AppCompatButton
|
||||
<android.support.v7.widget.AppCompatTextView
|
||||
android:id="@+id/articoli_in_collo_sheet_button"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:drawableStart="@drawable/ic_box"
|
||||
android:text="REFERENCES"
|
||||
tools:text="2 REFERENCES"
|
||||
android:textStyle="bold"
|
||||
android:drawablePadding="12dp"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:paddingTop="8dp"
|
||||
@ -53,7 +54,7 @@
|
||||
android:paddingLeft="16dp"
|
||||
android:paddingRight="16dp"
|
||||
android:elevation="0dp"
|
||||
android:theme="@style/white_button"
|
||||
android:textAllCaps="true"
|
||||
android:textSize="16sp"/>
|
||||
|
||||
<Button
|
||||
@ -103,10 +104,10 @@
|
||||
<android.support.v7.widget.CardView
|
||||
app:cardBackgroundColor="@android:color/white"
|
||||
app:cardCornerRadius="4dp"
|
||||
android:layout_marginLeft="10dp"
|
||||
android:layout_marginRight="10dp"
|
||||
android:layout_marginBottom="10dp"
|
||||
android:layout_marginTop="36dp"
|
||||
android:layout_marginLeft="8dp"
|
||||
android:layout_marginRight="8dp"
|
||||
android:layout_marginBottom="8dp"
|
||||
android:layout_marginTop="8dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
@ -245,7 +246,7 @@
|
||||
<android.support.v7.widget.CardView
|
||||
app:cardBackgroundColor="@android:color/white"
|
||||
app:cardCornerRadius="4dp"
|
||||
android:layout_margin="10dp"
|
||||
android:layout_margin="8dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
@ -276,6 +277,8 @@
|
||||
android:orientation="vertical"
|
||||
android:gravity="center"
|
||||
android:padding="16dp"
|
||||
android:layout_marginTop="16dp"
|
||||
android:layout_marginBottom="16dp"
|
||||
android:visibility="@{viewModel.mtbColt == null || viewModel.mtbColt.mtbColr.size() == 0 ? View.VISIBLE : View.GONE}">
|
||||
|
||||
<android.support.v7.widget.AppCompatImageView
|
||||
@ -301,7 +304,7 @@
|
||||
android:layout_height="wrap_content"
|
||||
android:clickable="true"
|
||||
android:orientation="vertical"
|
||||
app:dividerThickness="0dp" />
|
||||
app:dividerThickness="0.5dp" />
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
@ -366,5 +369,138 @@
|
||||
</RelativeLayout>
|
||||
|
||||
|
||||
<View
|
||||
android:visibility="gone"
|
||||
android:id="@+id/bg"
|
||||
android:background="#99000000"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"/>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/bottom_sheet_actions"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="#fff"
|
||||
android:orientation="vertical"
|
||||
android:padding="16dp"
|
||||
app:behavior_hideable="true"
|
||||
app:behavior_peekHeight="0dp"
|
||||
app:layout_behavior="android.support.design.widget.BottomSheetBehavior">
|
||||
|
||||
<android.support.constraint.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
android:layout_gravity="center_vertical">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
android:layout_marginBottom="8dp"
|
||||
app:layout_constraintEnd_toStartOf="@id/bottom_sheet_actions_quantity"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
|
||||
<android.support.v7.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_title"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
tools:text="Descrizione articolo"
|
||||
android:textColor="#444"
|
||||
android:textSize="18dp"
|
||||
android:maxLines="1"
|
||||
android:ellipsize="end"
|
||||
android:paddingRight="8dp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
<android.support.v7.widget.AppCompatTextView
|
||||
android:id="@+id/bottom_sheet_actions_subtitle"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
tools:text="ABF52IL"
|
||||
android:textSize="14dp"
|
||||
android:textStyle="bold" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/bottom_sheet_actions_quantity"
|
||||
android:layout_width="wrap_content"
|
||||
android:gravity="right"
|
||||
android:layout_height="wrap_content"
|
||||
android:textStyle="bold"
|
||||
android:textSize="15dp"
|
||||
tools:text="250 PZ"
|
||||
app:layout_constraintEnd_toEndOf="parent"/>
|
||||
</android.support.constraint.ConstraintLayout>
|
||||
|
||||
<android.support.constraint.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
|
||||
<android.support.constraint.Guideline
|
||||
android:id="@+id/guideline_action"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintGuide_percent="0.50" />
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toStartOf="@id/guideline_action"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
android:gravity="center">
|
||||
|
||||
<android.support.v7.widget.AppCompatImageButton
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="16dp"
|
||||
android:background="@android:color/white"
|
||||
android:scaleX="1.5"
|
||||
android:scaleY="1.5"
|
||||
android:src="@drawable/ic_edit_24dp"
|
||||
android:tint="@color/green_600" />
|
||||
|
||||
<android.support.v7.widget.AppCompatTextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Modifica"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="@id/guideline_action"
|
||||
android:gravity="center">
|
||||
|
||||
<android.support.v7.widget.AppCompatImageButton
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:padding="16dp"
|
||||
android:background="@android:color/white"
|
||||
android:scaleX="1.5"
|
||||
android:scaleY="1.5"
|
||||
android:src="@drawable/ic_delete_24dp"
|
||||
android:tint="@color/red_600" />
|
||||
|
||||
<android.support.v7.widget.AppCompatTextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="Cancella"/>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</android.support.constraint.ConstraintLayout>
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</android.support.design.widget.CoordinatorLayout>
|
||||
</layout>
|
||||
@ -6,71 +6,87 @@
|
||||
<data>
|
||||
<import type="android.view.View" />
|
||||
<import type="it.integry.integrywmsnative.core.utility.UtilityString" />
|
||||
<import type="it.integry.integrywmsnative.core.utility.UtilityNumber" />
|
||||
<variable
|
||||
name="mtbColr"
|
||||
type="it.integry.integrywmsnative.core.model.MtbColr"/>
|
||||
</data>
|
||||
|
||||
<LinearLayout
|
||||
android:orientation="vertical"
|
||||
<android.support.constraint.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingTop="3dp"
|
||||
android:paddingBottom="3dp"
|
||||
android:paddingStart="10dp"
|
||||
android:paddingEnd="10dp">
|
||||
android:padding="8dp">
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/linearLayout"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{`Cod: ` + mtbColr.codMart}"
|
||||
tools:text="Cod: 028650"/>
|
||||
android:orientation="vertical"
|
||||
app:layout_constraintEnd_toStartOf="@+id/qta_box"
|
||||
app:layout_constraintStart_toStartOf="parent">
|
||||
|
||||
|
||||
<android.support.constraint.ConstraintLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
<android.support.v7.widget.AppCompatTextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{mtbColr.codMart}"
|
||||
android:textColor="@color/colorPrimary"
|
||||
android:textSize="14sp"
|
||||
android:textStyle="bold"
|
||||
tools:text="COD MART" />
|
||||
|
||||
|
||||
<TextView
|
||||
style="@android:style/TextAppearance.Medium"
|
||||
android:layout_width="0dp"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentLeft="true"
|
||||
android:layout_toLeftOf="@id/posizione_collo"
|
||||
android:ellipsize="end"
|
||||
android:maxLines="1"
|
||||
android:text="@{mtbColr.descrizione}"
|
||||
android:text="@{mtbColr.getDescrizione()}"
|
||||
android:textColor="@android:color/black"
|
||||
android:layout_marginEnd="6dp"
|
||||
app:layout_constraintEnd_toStartOf="@+id/qta_textbox"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
tools:text="11719 - BESCIAMELLA CHEF 200ML FLASH CICCIO RICCIO" />
|
||||
android:textSize="16sp"
|
||||
tools:text="Descrizione lunga articolo" />
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/qta_textbox"
|
||||
android:layout_width="0dp"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="@{`Lotto: ` + mtbColr.getPartitaMag()}"
|
||||
android:textSize="14sp"
|
||||
android:visibility="@{UtilityString.isNullOrEmpty(mtbColr.getPartitaMag()) ? View.INVISIBLE : View.VISIBLE}"
|
||||
tools:text="Lotto: ABCDE" />
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/qta_box"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingStart="12dp"
|
||||
android:paddingEnd="12dp"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent">
|
||||
|
||||
<android.support.v7.widget.AppCompatTextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:background="@drawable/badge1_round_corner"
|
||||
android:backgroundTint="@color/green_600"
|
||||
android:paddingBottom="2dp"
|
||||
android:gravity="center"
|
||||
android:paddingLeft="6dp"
|
||||
android:paddingRight="6dp"
|
||||
android:paddingTop="2dp"
|
||||
android:text="@{`Qtà: ` + mtbColr.qtaCol}"
|
||||
android:paddingRight="6dp"
|
||||
android:paddingBottom="2dp"
|
||||
android:text="@{UtilityNumber.decimalToString(mtbColr.getQtaCol()) + `\n` + mtbColr.getUntMis()}"
|
||||
android:textSize="16sp"
|
||||
android:textColor="@android:color/white"
|
||||
android:textStyle="bold"
|
||||
tools:text="Qtà: 100"
|
||||
app:layout_constraintEnd_toEndOf="parent" />
|
||||
tools:text="280.45\nCONF" />
|
||||
|
||||
</android.support.constraint.ConstraintLayout>
|
||||
</RelativeLayout>
|
||||
|
||||
<TextView
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
android:layout_weight="1"
|
||||
android:text="@{`Lotto: ` + mtbColr.partitaMag + (mtbColr.getDataScadPartitaS() != null ? `(` + mtbColr.getDataScadPartitaS() + `)` : ``)}"
|
||||
tools:text="Lotto: 030716"
|
||||
android:visibility="@{UtilityString.isNullOrEmpty(mtbColr.partitaMag) ? View.GONE : View.VISIBLE}"/>
|
||||
|
||||
</LinearLayout>
|
||||
</android.support.constraint.ConstraintLayout>
|
||||
</layout>
|
||||
@ -100,5 +100,7 @@
|
||||
<string name="activity_lista_bancali_title">Lista UL</string>
|
||||
<string name="activity_contenuto_bancale_title">Contenuto UL</string>
|
||||
|
||||
<string name="button_ignore_print">Salta stampa</string>
|
||||
|
||||
|
||||
</resources>
|
||||
@ -109,4 +109,6 @@
|
||||
<string name="activity_lista_bancali_title">LU List</string>
|
||||
<string name="activity_contenuto_bancale_title">LU Content</string>
|
||||
|
||||
<string name="button_ignore_print">Skip print</string>
|
||||
|
||||
</resources>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user