Merge branch 'feature/RefactoringGestioneColli' into master-beta
All checks were successful
WMS - Android (New)/pipeline/head This commit looks good
All checks were successful
WMS - Android (New)/pipeline/head This commit looks good
This commit is contained in:
@@ -11,8 +11,8 @@ apply plugin: 'com.google.gms.google-services'
|
||||
|
||||
android {
|
||||
|
||||
def appVersionCode = 541
|
||||
def appVersionName = '1.48.01'
|
||||
def appVersionCode = 542
|
||||
def appVersionName = '1.48.02'
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
|
||||
@@ -1185,8 +1185,12 @@ public class SpedizioneActivity extends BaseActivity implements SpedizioneViewMo
|
||||
@Override
|
||||
public void onBatchLotSelectionRequest(List<PartitaCommessaDTO> availableBatchLotsCodJcoms, RunnableArgs<PartitaCommessaDTO> onComplete) {
|
||||
handler.post(() -> {
|
||||
this.onLoadingStarted();
|
||||
|
||||
DialogChooseBatchLotView.newInstance(availableBatchLotsCodJcoms, onComplete)
|
||||
.show(getSupportFragmentManager(), "tag");
|
||||
|
||||
this.onLoadingEnded();
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -1050,10 +1050,7 @@ public class SpedizioneViewModel {
|
||||
// }
|
||||
|
||||
if (availableBatchLotsAndCodJcoms.size() > 1) {
|
||||
this.sendOnLoadingStarted();
|
||||
|
||||
var selected = this.sendBatchLotSelectionRequest(availableBatchLotsAndCodJcoms);
|
||||
this.sendOnLoadingEnded();
|
||||
|
||||
if (selected != null) {
|
||||
MtbColr scannedMtbColr = pickingObjectDTO.getTempPickData().getSourceMtbColt().getMtbColr().stream()
|
||||
|
||||
@@ -564,14 +564,24 @@ public class DialogInputQuantityV2View extends BaseDialogFragment implements Dia
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onWarning(String text, RunnableArgs<Boolean> result) {
|
||||
public void onWarning(String text, Boolean showNegativeClick, RunnableArgs<Boolean> result) {
|
||||
handler.post(() -> {
|
||||
|
||||
DialogSimpleMessageView.makeWarningDialog(context, new SpannableString(Html.fromHtml(text)),
|
||||
null,
|
||||
() -> result.run(true),
|
||||
() -> result.run(false)
|
||||
).show();
|
||||
if (showNegativeClick) {
|
||||
DialogSimpleMessageView.makeWarningDialog(
|
||||
context,
|
||||
new SpannableString(Html.fromHtml(text)),
|
||||
null,
|
||||
() -> result.run(true),
|
||||
() -> result.run(false)
|
||||
).show();
|
||||
} else {
|
||||
DialogSimpleMessageView.makeWarningDialog(
|
||||
context,
|
||||
new SpannableString(Html.fromHtml(text)),
|
||||
null,
|
||||
() -> result.run(true)
|
||||
).show();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
@@ -215,6 +215,12 @@ public class DialogInputQuantityV2ViewModel {
|
||||
} else if (ean128Model.Sscc != null) {
|
||||
//Close current UDS and open another one with new SSCC
|
||||
if (enableSSCCRead) {
|
||||
|
||||
if (UtilityBigDecimal.lowerThan(totalNumCnfToBeTaken, totalNumCnfAvailable)){
|
||||
this.sendWarning(UtilityResources.getString(R.string.qta_to_be_taken_lower_then_qta_available), false);
|
||||
return;
|
||||
}
|
||||
|
||||
this.internalNextUlBarcode = barcodeScanDTO;
|
||||
this.sendOnULCloseRequested();
|
||||
}
|
||||
@@ -674,7 +680,7 @@ public class DialogInputQuantityV2ViewModel {
|
||||
final FutureTask<Object> ft = new FutureTask<>(() -> {
|
||||
}, new Object());
|
||||
AtomicBoolean returnResult = new AtomicBoolean();
|
||||
mListener.onWarning(text, result -> {
|
||||
mListener.onWarning(text, true, result -> {
|
||||
returnResult.set(result);
|
||||
ft.run();
|
||||
});
|
||||
@@ -745,12 +751,17 @@ public class DialogInputQuantityV2ViewModel {
|
||||
if (this.mListener != null) mListener.onULCloseRequested();
|
||||
}
|
||||
|
||||
private void sendWarning(String text, Boolean showNegativeClick) {
|
||||
if (this.mListener != null) mListener.onWarning(text, showNegativeClick, result -> {
|
||||
});
|
||||
}
|
||||
|
||||
public interface Listener extends ILoadingListener {
|
||||
void onDataChanged();
|
||||
|
||||
void onError(Exception ex);
|
||||
|
||||
void onWarning(String text, RunnableArgs<Boolean> result);
|
||||
void onWarning(String text, Boolean showNegativeClick, RunnableArgs<Boolean> result);
|
||||
|
||||
void onULCloseRequested();
|
||||
}
|
||||
|
||||
@@ -225,6 +225,7 @@
|
||||
<string name="check_box_preference_title">Check box</string>
|
||||
<string name="check_box_preference_summary">This is a regular preference</string>
|
||||
<string name="confirm_anomalie"><![CDATA[Sono state riscontrate <b>%d</b> anomalie. Continuare?]]></string>
|
||||
<string name="qta_to_be_taken_lower_then_qta_available"><![CDATA[La <b>quantità</b> da prelevare risulta inferiore alla <b>quantità</b> totale disponibile. <br> Chiudere manualmente la UL.]]></string>
|
||||
|
||||
<string name="alert_delete_UL">Stai per eliminare una UL. Confermi?</string>
|
||||
<string name="alert_delete_mtb_colr">Stai per eliminare una riga. Confermi?</string>
|
||||
|
||||
@@ -224,6 +224,7 @@
|
||||
<string name="check_box_preference_title">Check box</string>
|
||||
<string name="check_box_preference_summary">This is a regular preference</string>
|
||||
<string name="confirm_anomalie"><![CDATA[<b>%d</b> anomalies were found. To continue?]]></string>
|
||||
<string name="qta_to_be_taken_lower_then_qta_available"><![CDATA[The <b>quantity</b> to be withdrawn is less than the total <b>quantity</b> available. Close the UL manually.]]></string>
|
||||
|
||||
<string name="alert_delete_UL">Are you sure you want to delete this UL? Please confirm</string>
|
||||
<string name="alert_delete_mtb_colr">Are you sure to delete? Please confirm</string>
|
||||
|
||||
Reference in New Issue
Block a user