This commit is contained in:
zj
2026-01-30 17:16:28 +08:00
parent c07b4fb12a
commit 167fa21569
7 changed files with 52 additions and 21 deletions

View File

@@ -160,7 +160,7 @@ public class ToWmsServiceImpl implements IToWmsService {
//超大托盘不处理 直接返回 //超大托盘不处理 直接返回
if (size == 5) { if (size == 5) {
return new AjaxResult(5, "超大托盘!"); return new AjaxResult(5, "超大托盘或没有长宽高需手动维护");
} }
//托盘大小与电气返回不匹配 //托盘大小与电气返回不匹配
if (StrUtil.isNotBlank(requestEnter.getSize()) && !"1".equals(requestEnter.getType()) && size != Integer.parseInt(requestEnter.getSize())) { if (StrUtil.isNotBlank(requestEnter.getSize()) && !"1".equals(requestEnter.getType()) && size != Integer.parseInt(requestEnter.getSize())) {
@@ -304,7 +304,7 @@ public class ToWmsServiceImpl implements IToWmsService {
int size = Convert.toInt(basProduct.getSpare10()); int size = Convert.toInt(basProduct.getSpare10());
//超大托盘不处理 直接返回 //超大托盘不处理 直接返回
if (size == 5) { if (size == 5) {
return new AjaxResult(3, "超大托盘"); return new AjaxResult(3, "超大托盘或没有长宽高需手动维护");
} }
if(size == 1){ if(size == 1){
@@ -506,7 +506,7 @@ public class ToWmsServiceImpl implements IToWmsService {
//超大托盘不处理 直接返回 //超大托盘不处理 直接返回
if (size == 5) { if (size == 5) {
return new AjaxResult(3, "超大托盘"); return new AjaxResult(3, "超大托盘或没有长宽高需手动维护");
} }
//托盘大小与电气返回不匹配 //托盘大小与电气返回不匹配
if (StrUtil.isNotBlank(requestEnter.getSize()) && !"1".equals(requestEnter.getType()) && size != Integer.parseInt(requestEnter.getSize())) { if (StrUtil.isNotBlank(requestEnter.getSize()) && !"1".equals(requestEnter.getType()) && size != Integer.parseInt(requestEnter.getSize())) {

View File

@@ -51,4 +51,6 @@ public interface IProductionCallbackService {
public int deleteProductionCallbackByTrayCode(String trayCode); public int deleteProductionCallbackByTrayCode(String trayCode);
int updateProductionCallbackMsg(ProductionCallback productionCallback); int updateProductionCallbackMsg(ProductionCallback productionCallback);
ProductionCallback getByTrayCode(String trayCode);
} }

View File

@@ -89,4 +89,10 @@ public class ProductionCallbackServiceImpl implements IProductionCallbackService
return productionCallbackMapper.updateProductionCallbackMsg(productionCallback); return productionCallbackMapper.updateProductionCallbackMsg(productionCallback);
} }
@Override
public ProductionCallback getByTrayCode(String trayCode) {
return productionCallbackMapper.selectProductionCallbackByTrayCode(trayCode);
}
} }

View File

@@ -373,19 +373,26 @@ public class MydoJobServiceImpl implements IMydoJobService {
insertHistory(mydoJob.getJobId()); insertHistory(mydoJob.getJobId());
//报工数据插入 //报工数据插入
if("G1005".equals(mydoJob.getEntranceId())){ if("G1005".equals(mydoJob.getEntranceId())){
ProductionCallback productionCallback = new ProductionCallback(); ProductionCallback existCallback = productionCallbackService.getByTrayCode(mydoJob.getTrayCode());
productionCallback.setTrayCode(mydoJob.getTrayCode()); if(existCallback == null) {
productionCallback.setBillNo(mydoJob.getLineId()); ProductionCallback productionCallback = new ProductionCallback();
productionCallback.setProductId(mydoJobDetails.get(0).getProductId()); productionCallback.setTrayCode(mydoJob.getTrayCode());
if(basProduct != null) { productionCallback.setBillNo(mydoJob.getLineId());
productionCallback.setProductName(basProduct.getProductName()); productionCallback.setProductId(mydoJobDetails.get(0).getProductId());
if (basProduct != null) {
productionCallback.setProductName(basProduct.getProductName());
}
productionCallback.setSpec(mydoJobDetails.get(0).getSpec());
productionCallback.setUnit(basProduct.getUnit());
productionCallback.setStatus("0");
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
productionCallback.setCreateTime(sdf.format(new Date()));
productionCallbackService.insertProductionCallback(productionCallback);
}else {
// 已存在则跳过插入,执行后续操作
// 这里可以添加日志记录或其他逻辑
log.info("TrayCode {} 已存在于productionCallback表中,跳过插入", mydoJob.getTrayCode());
} }
productionCallback.setSpec(mydoJobDetails.get(0).getSpec());
productionCallback.setUnit(basProduct.getUnit());
productionCallback.setStatus("0");
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
productionCallback.setCreateTime(sdf.format(new Date()));
productionCallbackService.insertProductionCallback(productionCallback);
} }
//其他出入库单据回传 //其他出入库单据回传

View File

@@ -72,7 +72,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="productGuid != null and productGuid != ''"> and product_guid = #{productGuid}</if> <if test="productGuid != null and productGuid != ''"> and product_guid = #{productGuid}</if>
<if test="quantity != null "> and quantity = #{quantity}</if> <if test="quantity != null "> and quantity = #{quantity}</if>
<if test="jobId != null and jobId != ''"> and job_id = #{jobId}</if> <if test="jobId != null and jobId != ''"> and job_id = #{jobId}</if>
<if test="trayCode != null and trayCode != ''"> and tray_code = #{trayCode}</if> <if test="trayCode != null and trayCode != ''"> and tray_code like concat('%', #{trayCode}, '%')</if>
<if test="outQuantity != null and outQuantity != ''"> and out_quantity = #{outQuantity}</if> <if test="outQuantity != null and outQuantity != ''"> and out_quantity = #{outQuantity}</if>
<if test="stockinDetailId != null and stockinDetailId != ''"> and stockin_detail_id = #{stockinDetailId}</if> <if test="stockinDetailId != null and stockinDetailId != ''"> and stockin_detail_id = #{stockinDetailId}</if>
<if test="stockinId != null and stockinId != ''"> and stockin_id = #{stockinId}</if> <if test="stockinId != null and stockinId != ''"> and stockin_id = #{stockinId}</if>
@@ -80,15 +80,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="inClassId != null and inClassId != ''"> and in_class_id = #{inClassId}</if> <if test="inClassId != null and inClassId != ''"> and in_class_id = #{inClassId}</if>
<if test="warehouseId != null and warehouseId != ''"> and warehouse_id = #{warehouseId}</if> <if test="warehouseId != null and warehouseId != ''"> and warehouse_id = #{warehouseId}</if>
<if test="stackingId != null and stackingId != ''"> and stacking_id = #{stackingId}</if> <if test="stackingId != null and stackingId != ''"> and stacking_id = #{stackingId}</if>
<if test="spare1 != null and spare1 != ''"> and spare1 = #{spare1}</if> <if test="spare1 != null and spare1 != ''"> and spare1 like concat('%', #{spare1}, '%')</if>
<if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if> <if test="spare2 != null and spare2 != ''"> and spare2 = #{spare2}</if>
<if test="spare3 != null and spare3 != ''"> and spare3 = #{spare3}</if> <if test="spare3 != null and spare3 != ''"> and spare3 = #{spare3}</if>
<if test="spare4 != null and spare4 != ''"> and spare4 = #{spare4}</if> <if test="spare4 != null and spare4 != ''"> and spare4 = #{spare4}</if>
<if test="spare5 != null and spare5 != ''"> and spare5 = #{spare5}</if> <if test="spare5 != null and spare5 != ''"> and spare5 like concat('%', #{spare5}, '%')</if>
<if test="spare6 != null and spare6 != ''"> and spare6 like concat('%', #{spare6}, '%')</if> <if test="spare6 != null and spare6 != ''"> and spare6 like concat('%', #{spare6}, '%')</if>
<if test="productId != null and productId != ''"> and product_id = #{productId}</if> <if test="productId != null and productId != ''"> and product_id like concat('%', #{productId}, '%')</if>
<if test="productName != null and productName != ''"> and product_name like concat('%', #{productName}, '%')</if> <if test="productName != null and productName != ''"> and product_name like concat('%', #{productName}, '%')</if>
<if test="voltage != null and voltage != ''"> and voltage = #{voltage}</if> <if test="voltage != null and voltage != ''"> and voltage like concat('%', #{voltage}, '%')</if>
<if test="power != null and power != ''"> and power = #{power}</if> <if test="power != null and power != ''"> and power = #{power}</if>
<if test="phase != null and phase != ''"> and phase = #{phase}</if> <if test="phase != null and phase != ''"> and phase = #{phase}</if>
<if test="netWeight != null "> and net_weight = #{netWeight}</if> <if test="netWeight != null "> and net_weight = #{netWeight}</if>

View File

@@ -36,7 +36,7 @@ export default {
pageSizes: { pageSizes: {
type: Array, type: Array,
default() { default() {
return [10, 20, 30, 50] return [10, 20, 30, 50,100,200]
} }
}, },
// 移动端页码按钮的数量端默认值5 // 移动端页码按钮的数量端默认值5

View File

@@ -49,6 +49,22 @@
@keyup.enter.native="handleQuery" @keyup.enter.native="handleQuery"
/> />
</el-form-item> </el-form-item>
<el-form-item label="电压" prop="voltage"><!-- 货位id -->
<el-input
v-model="queryParams.voltage"
placeholder="请输入电压"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="颜色" prop="spare5"><!-- 货位id -->
<el-input
v-model="queryParams.spare5"
placeholder="请输入颜色"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="货位-排" prop="thePlatoon"><!-- 货位id --> <el-form-item label="货位-排" prop="thePlatoon"><!-- 货位id -->
<el-input <el-input
v-model="queryParams.thePlatoon" v-model="queryParams.thePlatoon"