Finish v1.16.31(213)
This commit is contained in:
commit
88b1c56360
@ -6,8 +6,8 @@ apply plugin: 'com.google.gms.google-services'
|
|||||||
|
|
||||||
android {
|
android {
|
||||||
|
|
||||||
def appVersionCode = 212
|
def appVersionCode = 213
|
||||||
def appVersionName = '1.16.30'
|
def appVersionName = '1.16.31'
|
||||||
|
|
||||||
signingConfigs {
|
signingConfigs {
|
||||||
release {
|
release {
|
||||||
|
|||||||
@ -11,7 +11,6 @@ import org.jetbrains.annotations.NotNull;
|
|||||||
|
|
||||||
import java.lang.reflect.Type;
|
import java.lang.reflect.Type;
|
||||||
import java.math.BigDecimal;
|
import java.math.BigDecimal;
|
||||||
import java.text.SimpleDateFormat;
|
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
@ -485,40 +484,31 @@ public class ColliMagazzinoRESTConsumer extends _BaseRESTConsumer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public static void getByTestataStatic(MtbColt testata, boolean onlyResiduo, boolean throwExcIfNull, RunnableArgs<MtbColt> onComplete, RunnableArgs<Exception> onFailed) {
|
public static void getByTestataStatic(MtbColt testata, boolean onlyResiduo, boolean throwExcIfNull, RunnableArgs<MtbColt> onComplete, RunnableArgs<Exception> onFailed) {
|
||||||
String ssccString = null;
|
testata.setMtbColr(new ObservableArrayList<>());
|
||||||
|
|
||||||
if (testata.getSerCollo().equalsIgnoreCase(CommonConst.Config.DEFAULT_ANONYMOUS_UL_SERIE)) {
|
|
||||||
ssccString = "U";
|
|
||||||
|
|
||||||
SimpleDateFormat sdf = new SimpleDateFormat("yy");
|
ColliMagazzinoRESTConsumerService colliMagazzinoRESTConsumerService = RESTBuilder.getService(ColliMagazzinoRESTConsumerService.class);
|
||||||
ssccString += sdf.format(testata.getDataColloD());
|
colliMagazzinoRESTConsumerService.getColloInGiac(onlyResiduo, throwExcIfNull, testata).enqueue(new Callback<ServiceRESTResponse<MtbColt>>() {
|
||||||
|
@Override
|
||||||
|
public void onResponse(Call<ServiceRESTResponse<MtbColt>> call, Response<ServiceRESTResponse<MtbColt>> response) {
|
||||||
|
analyzeAnswer(response, "getColloInGiac", mtbColt -> {
|
||||||
|
|
||||||
ssccString += String.format("%07d", testata.getNumCollo());
|
if (mtbColt != null && mtbColt.getMtbColr() != null && mtbColt.getMtbColr().size() > 0) {
|
||||||
} else {
|
List<MtbColt> mtbColtList = new ArrayList<>();
|
||||||
ssccString = "";
|
mtbColtList.add(mtbColt);
|
||||||
|
fillMtbAartsOfMtbColtsStatic(mtbColtList, mtbColts -> onComplete.run(mtbColts.get(0)), onFailed);
|
||||||
|
} else {
|
||||||
|
onComplete.run(mtbColt);
|
||||||
|
}
|
||||||
|
|
||||||
switch (testata.getGestioneEnum()) {
|
}, onFailed);
|
||||||
case ACQUISTO:
|
|
||||||
ssccString += "1";
|
|
||||||
break;
|
|
||||||
|
|
||||||
case LAVORAZIONE:
|
|
||||||
ssccString += "2";
|
|
||||||
break;
|
|
||||||
|
|
||||||
case VENDITA:
|
|
||||||
ssccString += "3";
|
|
||||||
break;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
SimpleDateFormat sdf = new SimpleDateFormat("yy");
|
@Override
|
||||||
ssccString += sdf.format(testata.getDataColloD());
|
public void onFailure(Call<ServiceRESTResponse<MtbColt>> call, Throwable t) {
|
||||||
|
onFailed.run(new Exception(t));
|
||||||
ssccString += String.format("%05d", testata.getNumCollo());
|
}
|
||||||
ssccString += "0";
|
});
|
||||||
}
|
|
||||||
|
|
||||||
getBySSCCStatic(ssccString, onlyResiduo, throwExcIfNull, onComplete, onFailed);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@ -24,6 +24,9 @@ public interface ColliMagazzinoRESTConsumerService {
|
|||||||
@POST("getColloByBarcode")
|
@POST("getColloByBarcode")
|
||||||
Call<ServiceRESTResponse<MtbColt>> getColloByBarcode(@Query("codBarreCollo") String sscc, @Query("onlyResiduo") boolean onlyResiduo, @Query("throwExcIfNull") boolean throwExcIfNull);
|
Call<ServiceRESTResponse<MtbColt>> getColloByBarcode(@Query("codBarreCollo") String sscc, @Query("onlyResiduo") boolean onlyResiduo, @Query("throwExcIfNull") boolean throwExcIfNull);
|
||||||
|
|
||||||
|
@POST("getColloInGiac")
|
||||||
|
Call<ServiceRESTResponse<MtbColt>> getColloInGiac(@Query("onlyResiduo") boolean onlyResiduo, @Query("throwExcIfNull") boolean throwExcIfNull, @Body MtbColt mtbColt);
|
||||||
|
|
||||||
@GET("getColliInBasket")
|
@GET("getColliInBasket")
|
||||||
Call<ServiceRESTResponse<List<MtbColt>>> getColliInBasket(@Query("codMdep") String codMdep);
|
Call<ServiceRESTResponse<List<MtbColt>>> getColliInBasket(@Query("codMdep") String codMdep);
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user