Merge remote-tracking branch 'origin/feature/NoScanning' into feature/NoScanning
This commit is contained in:
commit
b6ab5205f7
|
|
@ -0,0 +1,31 @@
|
|||
package com.nflg.wms.admin.pojo.request;
|
||||
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
@Data
|
||||
public class NoScanningItemDataRequest {
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
@NotNull
|
||||
private BigDecimal num;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNo;
|
||||
|
||||
/**
|
||||
* 序列号
|
||||
*/
|
||||
private String serialNo;
|
||||
|
||||
/**
|
||||
* 库位
|
||||
*/
|
||||
private String binNo;
|
||||
}
|
||||
|
|
@ -1,31 +1,33 @@
|
|||
package com.nflg.wms.admin.pojo.request;
|
||||
|
||||
import jakarta.validation.Valid;
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotEmpty;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
@Data
|
||||
public class NoScanningItemRequest {
|
||||
|
||||
/**
|
||||
* 数量
|
||||
* 订单项ID
|
||||
*/
|
||||
@NotNull
|
||||
private BigDecimal num;
|
||||
private Long orderItemId;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
* 物料编号
|
||||
*/
|
||||
private String batchNo;
|
||||
@NotBlank
|
||||
private String materialNo;
|
||||
|
||||
/**
|
||||
* 序列号
|
||||
* 明细列表
|
||||
*/
|
||||
private String serialNo;
|
||||
|
||||
/**
|
||||
* 库位
|
||||
*/
|
||||
private String binNo;
|
||||
@Valid
|
||||
@NotEmpty
|
||||
private List<NoScanningItemDataRequest> datas;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -12,20 +12,17 @@ import java.util.List;
|
|||
public class NoScanningRequest {
|
||||
|
||||
/**
|
||||
* 订单项ID
|
||||
* 订单id
|
||||
*/
|
||||
@NotNull
|
||||
private Long orderItemId;
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 物料编号
|
||||
* 库存地点编号
|
||||
*/
|
||||
@NotBlank
|
||||
private String materialNo;
|
||||
private String warehouseNo;
|
||||
|
||||
/**
|
||||
* 明细列表
|
||||
*/
|
||||
@Valid
|
||||
@NotEmpty
|
||||
private List<NoScanningItemRequest> items;
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ public class NoScanningBaseControllerService {
|
|||
* @param materialNo 物料编号
|
||||
* @return 是否生成过二维码
|
||||
*/
|
||||
protected boolean existsQrCode(String materialNo) {
|
||||
public boolean existsQrCode(String materialNo) {
|
||||
return qrCodeMasterService.lambdaQuery()
|
||||
.eq(WmsQrCodeMaster::getMaterialCode, materialNo)
|
||||
.exists();
|
||||
|
|
@ -37,7 +37,7 @@ public class NoScanningBaseControllerService {
|
|||
* @param warehouseNo 仓库编号
|
||||
* @return 数量是否一致
|
||||
*/
|
||||
protected boolean quantityConsistencyCheck(String materialNo, String factoryNo, String warehouseNo) {
|
||||
public boolean quantityConsistencyCheck(String materialNo, String factoryNo, String warehouseNo) {
|
||||
BigDecimal quantityQr = qrCodeMasterService.lambdaQuery()
|
||||
.select(WmsQrCodeMaster::getQuantity)
|
||||
.eq(WmsQrCodeMaster::getMaterialCode, materialNo)
|
||||
|
|
@ -66,7 +66,7 @@ public class NoScanningBaseControllerService {
|
|||
* @param factoryNo 工厂编号
|
||||
* @param warehouseNo 仓库编号
|
||||
*/
|
||||
protected void qrCodeCreateTask(String materialNo,String factoryNo, String warehouseNo){
|
||||
public void qrCodeCreateTask(String materialNo,String factoryNo, String warehouseNo){
|
||||
if (!quantityConsistencyCheck(materialNo, factoryNo, warehouseNo)) {
|
||||
//TODO 给仓库负责人创建补码的待办任务
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue