Creato servizio per caricare più stbGestSetup in un'unica richiesta
This commit is contained in:
parent
26cd14eb9d
commit
02d0ac04a9
BIN
.idea/caches/build_file_checksums.ser
generated
BIN
.idea/caches/build_file_checksums.ser
generated
Binary file not shown.
@ -106,9 +106,9 @@ dependencies {
|
||||
implementation 'androidx.cardview:cardview:1.0.0'
|
||||
implementation 'androidx.recyclerview:recyclerview:1.1.0-beta04'
|
||||
implementation 'androidx.preference:preference:1.1.0'
|
||||
implementation 'com.squareup.okhttp3:okhttp:4.1.0'
|
||||
implementation 'com.squareup.retrofit2:retrofit:2.6.1'
|
||||
implementation 'com.squareup.retrofit2:converter-gson:2.6.1'
|
||||
implementation 'com.squareup.okhttp3:okhttp:4.2.2'
|
||||
implementation 'com.squareup.retrofit2:retrofit:2.6.2'
|
||||
implementation 'com.squareup.retrofit2:converter-gson:2.6.2'
|
||||
implementation 'com.annimon:stream:1.2.1'
|
||||
implementation 'androidx.lifecycle:lifecycle-runtime:2.1.0'
|
||||
implementation 'androidx.lifecycle:lifecycle-extensions:2.1.0'
|
||||
|
||||
@ -125,7 +125,6 @@ public class MainActivity extends AppCompatActivity
|
||||
onNavigationItemSelected(mBinding.navView.getMenu().findItem(menuId));
|
||||
}
|
||||
|
||||
@SuppressWarnings("StatementWithEmptyBody")
|
||||
@Override
|
||||
public boolean onNavigationItemSelected(MenuItem item) {
|
||||
|
||||
|
||||
@ -69,7 +69,9 @@ public class ClassRouter {
|
||||
|
||||
return (T)clazz.newInstance();
|
||||
|
||||
} catch (Exception ex) {
|
||||
} catch (InstantiationException ex) {
|
||||
UtilityExceptions.defaultException(context, ex, true);
|
||||
} catch (IllegalAccessException ex) {
|
||||
UtilityExceptions.defaultException(context, ex, true);
|
||||
}
|
||||
|
||||
|
||||
@ -748,16 +748,4 @@ public class DtbDocr {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
|
||||
public String getStringKeyIdentifier() {
|
||||
String separator = "|";
|
||||
return
|
||||
this.getCodAnag() + separator +
|
||||
this.getCodDtip() + separator +
|
||||
this.getSerDoc() + separator +
|
||||
UtilityDate.formatDate(this.getDataDocD(), UtilityDate.COMMONS_DATE_FORMATS.YMD_SLASH) + separator +
|
||||
this.getNumDoc() + separator +
|
||||
this.getIdRiga();
|
||||
}
|
||||
}
|
||||
|
||||
@ -14,7 +14,7 @@ import it.integry.integrywmsnative.core.utility.UtilityExceptions;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityLogger;
|
||||
import it.integry.integrywmsnative.core.utility.UtilityString;
|
||||
|
||||
public class MtbColr extends EntityBase implements Parcelable {
|
||||
public class MtbColr extends EntityBase {
|
||||
|
||||
|
||||
private String gestione;
|
||||
@ -48,6 +48,12 @@ public class MtbColr extends EntityBase implements Parcelable {
|
||||
private String untMis;
|
||||
private Integer causale;
|
||||
private String utente;
|
||||
private String codAnagDoc;
|
||||
private String codDtipDoc;
|
||||
private String dataDoc;
|
||||
private String serDoc;
|
||||
private Integer numDoc;
|
||||
private Integer idRigaDoc;
|
||||
|
||||
private MtbAart mtbAart;
|
||||
|
||||
@ -64,179 +70,6 @@ public class MtbColr extends EntityBase implements Parcelable {
|
||||
public static final int VERSAMENTO = 2;
|
||||
}
|
||||
|
||||
protected MtbColr(Parcel in) {
|
||||
type = "mtb_colr";
|
||||
gestione = in.readString();
|
||||
serCollo = in.readString();
|
||||
if (in.readByte() == 0) {
|
||||
numCollo = null;
|
||||
} else {
|
||||
numCollo = in.readInt();
|
||||
}
|
||||
dataCollo = in.readString();
|
||||
if (in.readByte() == 0) {
|
||||
riga = null;
|
||||
} else {
|
||||
riga = in.readInt();
|
||||
}
|
||||
if (in.readByte() == 0) {
|
||||
rigaOrd = null;
|
||||
} else {
|
||||
rigaOrd = in.readInt();
|
||||
}
|
||||
codMart = in.readString();
|
||||
codBarre = in.readString();
|
||||
codCol = in.readString();
|
||||
codTagl = in.readString();
|
||||
partitaMag = in.readString();
|
||||
gestioneRif = in.readString();
|
||||
serColloRif = in.readString();
|
||||
note = in.readString();
|
||||
dataOrd = in.readString();
|
||||
dataColloRif = in.readString();
|
||||
if (in.readByte() == 0) {
|
||||
numOrd = null;
|
||||
} else {
|
||||
numOrd = in.readInt();
|
||||
}
|
||||
if (in.readByte() == 0) {
|
||||
numEtich = null;
|
||||
} else {
|
||||
numEtich = in.readInt();
|
||||
}
|
||||
if (in.readByte() == 0) {
|
||||
numColloRif = null;
|
||||
} else {
|
||||
numColloRif = in.readInt();
|
||||
}
|
||||
datetimeRow = in.readString();
|
||||
codJcom = in.readString();
|
||||
insPartitaMag = in.readString();
|
||||
mtbPartitaMag_descrizione = in.readString();
|
||||
dataScadPartita = in.readString();
|
||||
descrizione = in.readString();
|
||||
untMis = in.readString();
|
||||
|
||||
if (in.readByte() == 0) {
|
||||
qtaCnf = null;
|
||||
} else {
|
||||
qtaCnf = new BigDecimal(in.readFloat());
|
||||
}
|
||||
|
||||
if (in.readByte() == 0) {
|
||||
qtaCol = null;
|
||||
} else {
|
||||
qtaCol = new BigDecimal(in.readFloat());
|
||||
}
|
||||
|
||||
if (in.readByte() == 0) {
|
||||
numCnf = null;
|
||||
} else {
|
||||
numCnf = new BigDecimal(in.readFloat());
|
||||
}
|
||||
|
||||
mtbAart = in.readParcelable(MtbAart.class.getClassLoader());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void writeToParcel(Parcel dest, int flags) {
|
||||
dest.writeString(gestione);
|
||||
dest.writeString(serCollo);
|
||||
if (numCollo == null) {
|
||||
dest.writeByte((byte) 0);
|
||||
} else {
|
||||
dest.writeByte((byte) 1);
|
||||
dest.writeInt(numCollo);
|
||||
}
|
||||
dest.writeString(dataCollo);
|
||||
if (riga == null) {
|
||||
dest.writeByte((byte) 0);
|
||||
} else {
|
||||
dest.writeByte((byte) 1);
|
||||
dest.writeInt(riga);
|
||||
}
|
||||
if (rigaOrd == null) {
|
||||
dest.writeByte((byte) 0);
|
||||
} else {
|
||||
dest.writeByte((byte) 1);
|
||||
dest.writeInt(rigaOrd);
|
||||
}
|
||||
dest.writeString(codMart);
|
||||
dest.writeString(codBarre);
|
||||
dest.writeString(codCol);
|
||||
dest.writeString(codTagl);
|
||||
dest.writeString(partitaMag);
|
||||
dest.writeString(gestioneRif);
|
||||
dest.writeString(serColloRif);
|
||||
dest.writeString(note);
|
||||
dest.writeString(dataOrd);
|
||||
dest.writeString(dataColloRif);
|
||||
if (numOrd == null) {
|
||||
dest.writeByte((byte) 0);
|
||||
} else {
|
||||
dest.writeByte((byte) 1);
|
||||
dest.writeInt(numOrd);
|
||||
}
|
||||
if (numEtich == null) {
|
||||
dest.writeByte((byte) 0);
|
||||
} else {
|
||||
dest.writeByte((byte) 1);
|
||||
dest.writeInt(numEtich);
|
||||
}
|
||||
if (numColloRif == null) {
|
||||
dest.writeByte((byte) 0);
|
||||
} else {
|
||||
dest.writeByte((byte) 1);
|
||||
dest.writeInt(numColloRif);
|
||||
}
|
||||
dest.writeString(datetimeRow);
|
||||
dest.writeString(codJcom);
|
||||
dest.writeString(insPartitaMag);
|
||||
dest.writeString(mtbPartitaMag_descrizione);
|
||||
dest.writeString(dataScadPartita);
|
||||
dest.writeString(descrizione);
|
||||
dest.writeString(untMis);
|
||||
|
||||
if (qtaCnf == null) {
|
||||
dest.writeByte((byte) 0);
|
||||
} else {
|
||||
dest.writeByte((byte) 1);
|
||||
dest.writeFloat(qtaCnf.floatValue());
|
||||
}
|
||||
|
||||
if (qtaCol == null) {
|
||||
dest.writeByte((byte) 0);
|
||||
} else {
|
||||
dest.writeByte((byte) 1);
|
||||
dest.writeFloat(qtaCol.floatValue());
|
||||
}
|
||||
|
||||
if (numCnf == null) {
|
||||
dest.writeByte((byte) 0);
|
||||
} else {
|
||||
dest.writeByte((byte) 1);
|
||||
dest.writeFloat(numCnf.floatValue());
|
||||
}
|
||||
|
||||
dest.writeParcelable(mtbAart, flags);
|
||||
}
|
||||
|
||||
@Override
|
||||
public int describeContents() {
|
||||
return 0;
|
||||
}
|
||||
|
||||
public static final Creator<MtbColr> CREATOR = new Creator<MtbColr>() {
|
||||
@Override
|
||||
public MtbColr createFromParcel(Parcel in) {
|
||||
return new MtbColr(in);
|
||||
}
|
||||
|
||||
@Override
|
||||
public MtbColr[] newArray(int size) {
|
||||
return new MtbColr[size];
|
||||
}
|
||||
};
|
||||
|
||||
public String getGestione() {
|
||||
return gestione;
|
||||
@ -602,4 +435,58 @@ public class MtbColr extends EntityBase implements Parcelable {
|
||||
this.utente = utente;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodAnagDoc() {
|
||||
return codAnagDoc;
|
||||
}
|
||||
|
||||
public MtbColr setCodAnagDoc(String codAnagDoc) {
|
||||
this.codAnagDoc = codAnagDoc;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getCodDtipDoc() {
|
||||
return codDtipDoc;
|
||||
}
|
||||
|
||||
public MtbColr setCodDtipDoc(String codDtipDoc) {
|
||||
this.codDtipDoc = codDtipDoc;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDataDoc() {
|
||||
return dataDoc;
|
||||
}
|
||||
|
||||
public MtbColr setDataDoc(String dataDoc) {
|
||||
this.dataDoc = dataDoc;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getSerDoc() {
|
||||
return serDoc;
|
||||
}
|
||||
|
||||
public MtbColr setSerDoc(String serDoc) {
|
||||
this.serDoc = serDoc;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Integer getNumDoc() {
|
||||
return numDoc;
|
||||
}
|
||||
|
||||
public MtbColr setNumDoc(Integer numDoc) {
|
||||
this.numDoc = numDoc;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Integer getIdRigaDoc() {
|
||||
return idRigaDoc;
|
||||
}
|
||||
|
||||
public MtbColr setIdRigaDoc(Integer idRigaDoc) {
|
||||
this.idRigaDoc = idRigaDoc;
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
@ -10,6 +10,7 @@ public class MtbDepoPosizione {
|
||||
private String descrizione;
|
||||
private String flagMonoCollo;
|
||||
private String flagLineaProduzione;
|
||||
private Integer priorita;
|
||||
|
||||
|
||||
|
||||
@ -76,4 +77,13 @@ public class MtbDepoPosizione {
|
||||
public boolean isFlagLineaProduzione() {
|
||||
return "S".equalsIgnoreCase(flagLineaProduzione);
|
||||
}
|
||||
|
||||
public Integer getPriorita() {
|
||||
return priorita;
|
||||
}
|
||||
|
||||
public MtbDepoPosizione setPriorita(Integer priorita) {
|
||||
this.priorita = priorita;
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
@ -0,0 +1,131 @@
|
||||
package it.integry.integrywmsnative.core.model;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
public class StbGestSetup extends EntityBase{
|
||||
|
||||
private String gestName;
|
||||
private String section;
|
||||
private String keySection;
|
||||
private String value;
|
||||
private String description;
|
||||
private String flagSync;
|
||||
private String queryDefault;
|
||||
private String flagUserView;
|
||||
private Date dataModifica;
|
||||
private String modificatoDa;
|
||||
private String flagSetupDepo;
|
||||
private String flagSetupUserWeb;
|
||||
|
||||
public StbGestSetup() {
|
||||
type = "stb_gest_setup";
|
||||
}
|
||||
|
||||
public String getGestName() {
|
||||
return gestName;
|
||||
}
|
||||
|
||||
public StbGestSetup setGestName(String gestName) {
|
||||
this.gestName = gestName;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getSection() {
|
||||
return section;
|
||||
}
|
||||
|
||||
public StbGestSetup setSection(String section) {
|
||||
this.section = section;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getKeySection() {
|
||||
return keySection;
|
||||
}
|
||||
|
||||
public StbGestSetup setKeySection(String keySection) {
|
||||
this.keySection = keySection;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getValue() {
|
||||
return value;
|
||||
}
|
||||
|
||||
public StbGestSetup setValue(String value) {
|
||||
this.value = value;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getDescription() {
|
||||
return description;
|
||||
}
|
||||
|
||||
public StbGestSetup setDescription(String description) {
|
||||
this.description = description;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagSync() {
|
||||
return flagSync;
|
||||
}
|
||||
|
||||
public StbGestSetup setFlagSync(String flagSync) {
|
||||
this.flagSync = flagSync;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getQueryDefault() {
|
||||
return queryDefault;
|
||||
}
|
||||
|
||||
public StbGestSetup setQueryDefault(String queryDefault) {
|
||||
this.queryDefault = queryDefault;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagUserView() {
|
||||
return flagUserView;
|
||||
}
|
||||
|
||||
public StbGestSetup setFlagUserView(String flagUserView) {
|
||||
this.flagUserView = flagUserView;
|
||||
return this;
|
||||
}
|
||||
|
||||
public Date getDataModifica() {
|
||||
return dataModifica;
|
||||
}
|
||||
|
||||
public StbGestSetup setDataModifica(Date dataModifica) {
|
||||
this.dataModifica = dataModifica;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getModificatoDa() {
|
||||
return modificatoDa;
|
||||
}
|
||||
|
||||
public StbGestSetup setModificatoDa(String modificatoDa) {
|
||||
this.modificatoDa = modificatoDa;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagSetupDepo() {
|
||||
return flagSetupDepo;
|
||||
}
|
||||
|
||||
public StbGestSetup setFlagSetupDepo(String flagSetupDepo) {
|
||||
this.flagSetupDepo = flagSetupDepo;
|
||||
return this;
|
||||
}
|
||||
|
||||
public String getFlagSetupUserWeb() {
|
||||
return flagSetupUserWeb;
|
||||
}
|
||||
|
||||
public StbGestSetup setFlagSetupUserWeb(String flagSetupUserWeb) {
|
||||
this.flagSetupUserWeb = flagSetupUserWeb;
|
||||
return this;
|
||||
}
|
||||
}
|
||||
@ -2,6 +2,9 @@ package it.integry.integrywmsnative.core.rest.consumers;
|
||||
|
||||
import android.util.Log;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.core.model.StbGestSetup;
|
||||
import it.integry.integrywmsnative.core.rest.RESTBuilder;
|
||||
import it.integry.integrywmsnative.core.rest.model.GestSetupDTO;
|
||||
import it.integry.integrywmsnative.core.rest.model.ServiceRESTResponse;
|
||||
@ -68,4 +71,22 @@ public class GestSetupRESTConsumer extends _BaseRESTConsumer {
|
||||
}
|
||||
|
||||
|
||||
public static void getValues(List<StbGestSetup> stbGestSetupList, RunnableArgs<List<StbGestSetup>> onComplete, RunnableArgs<Exception> onFailed) {
|
||||
GestSetupRESTConsumerService service = RESTBuilder.getService(GestSetupRESTConsumerService.class);
|
||||
service.getGestSetupValues(stbGestSetupList).enqueue(new Callback<ServiceRESTResponse<List<StbGestSetup>>>() {
|
||||
@Override
|
||||
public void onResponse(Call<ServiceRESTResponse<List<StbGestSetup>>> call, Response<ServiceRESTResponse<List<StbGestSetup>>> response) {
|
||||
analyzeAnswer(response, "GestSetup", onComplete, onFailed);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onFailure(Call<ServiceRESTResponse<List<StbGestSetup>>> call, Throwable t) {
|
||||
Log.e("PrintCollo", t.toString());
|
||||
UtilityLogger.errorMe(new Exception(t));
|
||||
if(onFailed != null) onFailed.run(new Exception(t));
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@ -1,9 +1,14 @@
|
||||
package it.integry.integrywmsnative.core.rest.consumers;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.core.model.StbGestSetup;
|
||||
import it.integry.integrywmsnative.core.rest.model.GestSetupDTO;
|
||||
import it.integry.integrywmsnative.core.rest.model.ServiceRESTResponse;
|
||||
import retrofit2.Call;
|
||||
import retrofit2.http.Body;
|
||||
import retrofit2.http.GET;
|
||||
import retrofit2.http.POST;
|
||||
import retrofit2.http.Query;
|
||||
|
||||
public interface GestSetupRESTConsumerService {
|
||||
@ -21,4 +26,8 @@ public interface GestSetupRESTConsumerService {
|
||||
@Query("keySection") String keySection,
|
||||
@Query("codMdep") String codMdep);
|
||||
|
||||
@POST("gestSetupList")
|
||||
Call<ServiceRESTResponse<List<StbGestSetup>>> getGestSetupValues(
|
||||
@Body List<StbGestSetup> stbGestSetupList);
|
||||
|
||||
}
|
||||
|
||||
@ -1,13 +1,17 @@
|
||||
package it.integry.integrywmsnative.core.settings;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.Log;
|
||||
|
||||
import com.annimon.stream.Stream;
|
||||
import com.google.firebase.perf.metrics.Trace;
|
||||
|
||||
import java.net.SocketTimeoutException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import it.integry.integrywmsnative.R;
|
||||
import it.integry.integrywmsnative.core.model.StbGestSetup;
|
||||
import it.integry.integrywmsnative.core.rest.consumers.GestSetupRESTConsumer;
|
||||
import it.integry.integrywmsnative.core.rest.consumers.ISimpleOperationCallback;
|
||||
import it.integry.integrywmsnative.core.rest.consumers.PosizioniRESTConsumer;
|
||||
@ -171,70 +175,76 @@ public class SettingsManager {
|
||||
|
||||
|
||||
private static void loadGestSetupValues(Runnable onComplete, RunnableArgs<Exception> onFailed) {
|
||||
GestSetupRESTConsumer.getValue("PICKING", "SETUP", "DEFAULT_CAUSALE_RETTIFICA_GIACENZE", valueDefaultCausaleRettificaGiacenze -> {
|
||||
dbSettingsModelIstance.setDefaultCausaleRettificaGiacenze(valueDefaultCausaleRettificaGiacenze.value);
|
||||
|
||||
GestSetupRESTConsumer.getBooleanValue("PICKING", "SETUP", "ENABLE_CHECK_PARTITA_MAG_PICKING_V", valueEnableCheckPartitaMag -> {
|
||||
dbSettingsModelIstance.setEnableCheckPartitaMagCheckPickingV(valueEnableCheckPartitaMag);
|
||||
List<StbGestSetup> stbGestSetupList = new ArrayList<>();
|
||||
|
||||
GestSetupRESTConsumer.getBooleanValue("PICKING", "SETUP", "FLAG_MULTI_CLIENTE_ORD_VENDITA", valueFlagMultiClienteOrdVendita -> {
|
||||
dbSettingsModelIstance.setFlagMultiClienteOrdV(valueFlagMultiClienteOrdVendita);
|
||||
stbGestSetupList.add(new StbGestSetup()
|
||||
.setGestName("PICKING")
|
||||
.setSection("SETUP")
|
||||
.setKeySection("DEFAULT_CAUSALE_RETTIFICA_GIACENZE"));
|
||||
stbGestSetupList.add(new StbGestSetup()
|
||||
.setGestName("PICKING")
|
||||
.setSection("SETUP")
|
||||
.setKeySection("ENABLE_CHECK_PARTITA_MAG_PICKING_V"));
|
||||
stbGestSetupList.add(new StbGestSetup()
|
||||
.setGestName("PICKING")
|
||||
.setSection("SETUP")
|
||||
.setKeySection("FLAG_MULTI_CLIENTE_ORD_VENDITA"));
|
||||
stbGestSetupList.add(new StbGestSetup()
|
||||
.setGestName("PICKING")
|
||||
.setSection("SETUP")
|
||||
.setKeySection("COD_ANAG_DEFAULT"));
|
||||
stbGestSetupList.add(new StbGestSetup()
|
||||
.setGestName("PICKING")
|
||||
.setSection("SETUP")
|
||||
.setKeySection("DEFAULT_CRITERIO_DISTRIBUZIONE"));
|
||||
stbGestSetupList.add(new StbGestSetup()
|
||||
.setGestName("PICKING")
|
||||
.setSection("PICKING_LIBERO")
|
||||
.setKeySection("FLAG_ASK_CLIENTE"));
|
||||
stbGestSetupList.add(new StbGestSetup()
|
||||
.setGestName("PICKING")
|
||||
.setSection("SPEDIZIONE")
|
||||
.setKeySection("FLAG_CAN_ADD_EXTRA_ITEMS"));
|
||||
stbGestSetupList.add(new StbGestSetup()
|
||||
.setGestName("PICKING")
|
||||
.setSection("ACCETTAZIONE")
|
||||
.setKeySection("FLAG_AUTO_OPEN_NEW_UL"));
|
||||
stbGestSetupList.add(new StbGestSetup()
|
||||
.setGestName("PICKING")
|
||||
.setSection("SPEDIZIONE")
|
||||
.setKeySection("FLAG_CAN_ADD_EXTRA_QUANTITY"));
|
||||
|
||||
GestSetupRESTConsumer.getValue("PICKING", "SETUP", "COD_ANAG_DEFAULT", valueCodAnagDefault -> {
|
||||
dbSettingsModelIstance.setDefaultCodAnag(valueCodAnagDefault.value);
|
||||
|
||||
GestSetupRESTConsumer.getValue("PICKING", "SETUP", "DEFAULT_CRITERIO_DISTRIBUZIONE", valueDefaultCriterioDistribuzione -> {
|
||||
dbSettingsModelIstance.setDefaultCriterioDistribuzione(valueDefaultCriterioDistribuzione.value);
|
||||
GestSetupRESTConsumer.getValues(stbGestSetupList, list -> {
|
||||
dbSettingsModelIstance.setDefaultCausaleRettificaGiacenze(getValueFromList(list, "DEFAULT_CAUSALE_RETTIFICA_GIACENZE", String.class));
|
||||
dbSettingsModelIstance.setEnableCheckPartitaMagCheckPickingV(getValueFromList(list, "ENABLE_CHECK_PARTITA_MAG_PICKING_V", Boolean.class));
|
||||
dbSettingsModelIstance.setFlagMultiClienteOrdV(getValueFromList(list, "FLAG_MULTI_CLIENTE_ORD_VENDITA", Boolean.class));
|
||||
dbSettingsModelIstance.setDefaultCodAnag(getValueFromList(list, "COD_ANAG_DEFAULT", String.class));
|
||||
dbSettingsModelIstance.setDefaultCriterioDistribuzione(getValueFromList(list, "DEFAULT_CRITERIO_DISTRIBUZIONE", String.class));
|
||||
dbSettingsModelIstance.setFlagAskClienteInPickingLibero(getValueFromList(list, "FLAG_ASK_CLIENTE", Boolean.class));
|
||||
dbSettingsModelIstance.setFlagCanAddExtraItemSpedizione(getValueFromList(list, "FLAG_CAN_ADD_EXTRA_ITEMS", Boolean.class));
|
||||
dbSettingsModelIstance.setFlagCanAutoOpenNewULAccettazione(getValueFromList(list, "FLAG_AUTO_OPEN_NEW_UL", Boolean.class));
|
||||
dbSettingsModelIstance.setFlagCanAddExtraQuantitySpedizione(getValueFromList(list, "FLAG_CAN_ADD_EXTRA_QUANTITY", Boolean.class));
|
||||
|
||||
GestSetupRESTConsumer.getBooleanValue("PICKING", "PICKING_LIBERO", "FLAG_ASK_CLIENTE", valueAskClientePickingLibero -> {
|
||||
dbSettingsModelIstance.setFlagAskClienteInPickingLibero(valueAskClientePickingLibero);
|
||||
if(onComplete != null) onComplete.run();
|
||||
}, onFailed);
|
||||
|
||||
GestSetupRESTConsumer.getBooleanValue("PICKING", "SPEDIZIONE", "FLAG_CAN_ADD_EXTRA_ITEMS", valueCanAddExtraItemSpedizione -> {
|
||||
dbSettingsModelIstance.setFlagCanAddExtraItemSpedizione(valueCanAddExtraItemSpedizione);
|
||||
}
|
||||
|
||||
GestSetupRESTConsumer.getBooleanValue("PICKING", "ACCETTAZIONE", "FLAG_AUTO_OPEN_NEW_UL", valueCanAutoOpenNewUL -> {
|
||||
dbSettingsModelIstance.setFlagCanAutoOpenNewULAccettazione(valueCanAutoOpenNewUL);
|
||||
|
||||
GestSetupRESTConsumer.getBooleanValue("PICKING", "SPEDIZIONE", "FLAG_CAN_ADD_EXTRA_QUANTITY", valueCanAddExtraQuantitySpedizione -> {
|
||||
dbSettingsModelIstance.setFlagCanAddExtraQuantitySpedizione(valueCanAddExtraQuantitySpedizione);
|
||||
public static <T>T getValueFromList(List<StbGestSetup> stbGestSetupList, String keySectionName, Class<T> clazz) {
|
||||
|
||||
if(onComplete != null) onComplete.run();
|
||||
StbGestSetup value = Stream.of(stbGestSetupList)
|
||||
.filter(x -> x.getKeySection().equalsIgnoreCase(keySectionName))
|
||||
.findFirst().get();
|
||||
|
||||
}, ex -> {
|
||||
if(onFailed != null) onFailed.run(ex);
|
||||
});
|
||||
if(clazz == String.class) {
|
||||
return clazz.cast(value.getValue());
|
||||
} else if(clazz == Boolean.class) {
|
||||
return clazz.cast("S".equalsIgnoreCase(value.getValue()));
|
||||
} else return null;
|
||||
|
||||
}, ex -> {
|
||||
if(onFailed != null) onFailed.run(ex);
|
||||
});
|
||||
|
||||
}, ex -> {
|
||||
if(onFailed != null) onFailed.run(ex);
|
||||
});
|
||||
|
||||
}, ex -> {
|
||||
if(onFailed != null) onFailed.run(ex);
|
||||
});
|
||||
|
||||
}, ex -> {
|
||||
if(onFailed != null) onFailed.run(ex);
|
||||
});
|
||||
|
||||
}, ex -> {
|
||||
if(onFailed != null) onFailed.run(ex);
|
||||
});
|
||||
|
||||
}, ex -> {
|
||||
if(onFailed != null) onFailed.run(ex);
|
||||
});
|
||||
|
||||
}, ex -> {
|
||||
if(onFailed != null) onFailed.run(ex);
|
||||
});
|
||||
|
||||
}, ex -> {
|
||||
if(onFailed != null) onFailed.run(ex);
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -223,7 +223,6 @@ public class MainFragment extends Fragment implements ITitledFragment, IScrollab
|
||||
|
||||
for(MenuConfiguration.MenuGroup menuGroup : menuGroups) {
|
||||
|
||||
|
||||
FragmentMainMenuGroupLayoutBinding groupBinding = DataBindingUtil.inflate(mLayoutInflater, R.layout.fragment_main_menu_group_layout, null, false);
|
||||
|
||||
String title = this.getResources().getString(menuGroup.getGroupText());
|
||||
|
||||
@ -344,7 +344,13 @@ public class PickingResiActivity extends AppCompatActivity implements IOnColloC
|
||||
.setNumCnf(quantityDTO.numCnf.getBigDecimal())
|
||||
.setDescrizione(item.getDescrizioneEstesa())
|
||||
.setDatetimeRow(UtilityDate.getDateInstance())
|
||||
.setNote(item.getStringKeyIdentifier());
|
||||
|
||||
.setCodAnagDoc(item.getCodAnag())
|
||||
.setCodDtipDoc(item.getCodDtip())
|
||||
.setSerDoc(item.getSerDoc())
|
||||
.setNumDoc(item.getNumDoc())
|
||||
.setDataDoc(item.getDataDocS())
|
||||
.setIdRigaDoc(item.getIdRiga());
|
||||
|
||||
|
||||
|
||||
|
||||
@ -267,7 +267,7 @@
|
||||
color: #7c7d81;
|
||||
font-size: small;
|
||||
font-weight: bold;
|
||||
">Questa email è solo una notifica riguardo un errore che si è verificatosi in un progetto</span>
|
||||
">Questa email è solo una notifica riguardo un errore che si è verificato in un progetto</span>
|
||||
</center>
|
||||
|
||||
</td>
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user