change - 重复补打条码校验逻辑

master
yinq 7 months ago
parent a5809e2707
commit 4a71b5aa4f

@ -205,10 +205,10 @@ public class PdaApiController {
@PostMapping("/rebarCode")
public AjaxResult rebarCode(String barCode) {
String result = service.rebarCode(barCode);
if (StringUtils.isEmpty(result)){
return error("条码信息输入错误!");
if (StringUtils.isNotEmpty(result)){
return error(result);
}
return success(result);
return success( "请到条码打印机旁进行补打条码!");
}
/**

@ -63,17 +63,19 @@ public class PdaServiceImpl implements IPdaBindingService {
*/
@Override
public String rebarCode(String barCode) {
String result = null;
if (StringUtils.isEmpty(barCode)){
return null;
return "条码信息输入错误!";
}
List<HashMap<String, String>> barcodeList = mapper.selectPrintBarcode(barCode);
if (barcodeList.size() > 0){
if (StringUtils.isNotEmpty(barcodeList.get(0).get("IS_PRINT")) &&
barcodeList.get(0).get("IS_PRINT").equals("0")){
return "请勿重复补打条码!";
}
// 维护条码补打记录表
mapper.printSupplementBarcode(barcodeList.get(0));
result = "请到条码打印机旁进行补打条码!";
}
return result;
return null;
}
/**

@ -66,12 +66,12 @@
PB.MATERIAL_CODE,
PB.MATERIAL_NAME,
PB.MATERIAL_BARCODE,
PB.PRINT_TIME,
PB.PRINT_BARTYPE,
OI.PRINT_NAME
NVL(MIN(PS.IS_PRINT), 1) IS_PRINT
FROM BASE_ORDERINFO OI
JOIN C##AUCMA_SCADA.PRINT_BARCODE PB ON PB.ORDER_CODE = OI.ORDER_CODE
LEFT JOIN C##AUCMA_SCADA.PRINT_SUPPLEMENTBARCODE PS ON PS.MATERIAL_BARCODE = PB.MATERIAL_BARCODE
WHERE PB.MATERIAL_BARCODE = #{boxCode}
GROUP BY PB.ORDER_CODE, PB.MATERIAL_CODE, PB.MATERIAL_NAME, PB.MATERIAL_BARCODE
</select>
<update id="unbindBarCode">

Loading…
Cancel
Save