in rettifica cerca per codice articolo se code128
This commit is contained in:
parent
46e438e0e9
commit
8134a64a43
@ -20,7 +20,7 @@ public class BarcodeRESTConsumer extends _BaseRESTConsumer {
|
|||||||
|
|
||||||
IBarcodeCustomization barcodeCustomization = ClassRouter.getInstance(ClassRouter.PATH.BARCODE_CUSTOMIZATION);
|
IBarcodeCustomization barcodeCustomization = ClassRouter.getInstance(ClassRouter.PATH.BARCODE_CUSTOMIZATION);
|
||||||
|
|
||||||
if(barcodeCustomization != null && barcodeCustomization.shouldForceToEan13(barcodeObj.getStringValue())){
|
if (barcodeCustomization != null && barcodeCustomization.shouldForceToEan13(barcodeObj.getStringValue())) {
|
||||||
Ean128Model ean128Model = new Ean128Model();
|
Ean128Model ean128Model = new Ean128Model();
|
||||||
ean128Model.Gtin = barcodeObj.getStringValue();
|
ean128Model.Gtin = barcodeObj.getStringValue();
|
||||||
onComplete.run(ean128Model);
|
onComplete.run(ean128Model);
|
||||||
@ -30,7 +30,7 @@ public class BarcodeRESTConsumer extends _BaseRESTConsumer {
|
|||||||
String ean128 = barcodeObj.getStringValue().replaceAll("" + ((char) 29), "|");
|
String ean128 = barcodeObj.getStringValue().replaceAll("" + ((char) 29), "|");
|
||||||
|
|
||||||
BarcodeRESTConsumerService barcodeRESTConsumerService = RESTBuilder.getService(BarcodeRESTConsumerService.class);
|
BarcodeRESTConsumerService barcodeRESTConsumerService = RESTBuilder.getService(BarcodeRESTConsumerService.class);
|
||||||
barcodeRESTConsumerService.decodeEan128(ean128).enqueue(new Callback<ServiceRESTResponse<Ean128Model>>() {
|
barcodeRESTConsumerService.decodeEan128(ean128).enqueue(new Callback<>() {
|
||||||
@Override
|
@Override
|
||||||
public void onResponse(Call<ServiceRESTResponse<Ean128Model>> call, Response<ServiceRESTResponse<Ean128Model>> response) {
|
public void onResponse(Call<ServiceRESTResponse<Ean128Model>> call, Response<ServiceRESTResponse<Ean128Model>> response) {
|
||||||
analyzeAnswer(response, "DecodeEan128", onComplete, onFailed);
|
analyzeAnswer(response, "DecodeEan128", onComplete, onFailed);
|
||||||
|
|||||||
@ -145,7 +145,9 @@ public class RettificaGiacenzeViewModel {
|
|||||||
//EAN 128 non completo o comunque mancano i riferimenti al prodotto
|
//EAN 128 non completo o comunque mancano i riferimenti al prodotto
|
||||||
onComplete.run();
|
onComplete.run();
|
||||||
}
|
}
|
||||||
}, this::sendError);
|
}, (e) -> {
|
||||||
|
this.searchArtInt(barcodeScanDTO.getStringValue(), onComplete);
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
private void loadArticolo(String barcodeProd, PickDataDTO pickData, Runnable onComplete) {
|
private void loadArticolo(String barcodeProd, PickDataDTO pickData, Runnable onComplete) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user