浏览代码

励磁出入库和错误日志

LiangtongHe 2 周之前
父节点
当前提交
c8c7874dfd

+ 104 - 0
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/controller/ErrorInformationController.java

@@ -0,0 +1,104 @@
+package com.zkqy.amichi.controller;
+
+import java.util.List;
+import javax.servlet.http.HttpServletResponse;
+import org.springframework.security.access.prepost.PreAuthorize;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.web.bind.annotation.GetMapping;
+import org.springframework.web.bind.annotation.PostMapping;
+import org.springframework.web.bind.annotation.PutMapping;
+import org.springframework.web.bind.annotation.DeleteMapping;
+import org.springframework.web.bind.annotation.PathVariable;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
+import com.zkqy.common.annotation.Log;
+import com.zkqy.common.core.controller.BaseController;
+import com.zkqy.common.core.domain.AjaxResult;
+import com.zkqy.common.enums.BusinessType;
+import com.zkqy.amichi.domain.ErrorInformation;
+import com.zkqy.amichi.service.IErrorInformationService;
+import com.zkqy.common.utils.poi.ExcelUtil;
+import com.zkqy.common.core.page.TableDataInfo;
+
+/**
+ * 手持机错误日志Controller
+ * 
+ * @author ruoyi
+ * @date 2025-07-15
+ */
+@RestController
+@RequestMapping("/errorInformation/errorInformation")
+public class ErrorInformationController extends BaseController
+{
+    @Autowired
+    private IErrorInformationService errorInformationService;
+
+    /**
+     * 查询手持机错误日志列表
+     */
+    @PreAuthorize("@ss.hasPermi('errorInformation:errorInformation:list')")
+    @GetMapping("/list")
+    public TableDataInfo list(ErrorInformation errorInformation)
+    {
+        startPage();
+        List<ErrorInformation> list = errorInformationService.selectErrorInformationList(errorInformation);
+        return getDataTable(list);
+    }
+
+    /**
+     * 导出手持机错误日志列表
+     */
+    @PreAuthorize("@ss.hasPermi('errorInformation:errorInformation:export')")
+    @Log(title = "手持机错误日志", businessType = BusinessType.EXPORT)
+    @PostMapping("/export")
+    public void export(HttpServletResponse response, ErrorInformation errorInformation)
+    {
+        List<ErrorInformation> list = errorInformationService.selectErrorInformationList(errorInformation);
+        ExcelUtil<ErrorInformation> util = new ExcelUtil<ErrorInformation>(ErrorInformation.class);
+        util.exportExcel(response, list, "手持机错误日志数据");
+    }
+
+    /**
+     * 获取手持机错误日志详细信息
+     */
+    @PreAuthorize("@ss.hasPermi('errorInformation:errorInformation:query')")
+    @GetMapping(value = "/{id}")
+    public AjaxResult getInfo(@PathVariable("id") Long id)
+    {
+        return success(errorInformationService.selectErrorInformationById(id));
+    }
+
+    /**
+     * 新增手持机错误日志
+     */
+    @PreAuthorize("@ss.hasPermi('errorInformation:errorInformation:add')")
+    @Log(title = "手持机错误日志", businessType = BusinessType.INSERT)
+    @PostMapping
+    public AjaxResult add(@RequestBody ErrorInformation errorInformation)
+    {
+        return toAjax(errorInformationService.insertErrorInformation(errorInformation));
+    }
+
+    /**
+     * 修改手持机错误日志
+     */
+    @PreAuthorize("@ss.hasPermi('errorInformation:errorInformation:edit')")
+    @Log(title = "手持机错误日志", businessType = BusinessType.UPDATE)
+    @PutMapping
+    public AjaxResult edit(@RequestBody ErrorInformation errorInformation)
+    {
+        return toAjax(errorInformationService.updateErrorInformation(errorInformation));
+    }
+
+    /**
+     * 删除手持机错误日志
+     */
+    @PreAuthorize("@ss.hasPermi('errorInformation:errorInformation:remove')")
+    @Log(title = "手持机错误日志", businessType = BusinessType.DELETE)
+	@DeleteMapping("/{ids}")
+    public AjaxResult remove(@PathVariable Long[] ids)
+    {
+        return toAjax(errorInformationService.deleteErrorInformationByIds(ids));
+    }
+}

+ 10 - 0
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/controller/MaterialsInventoryController.java

@@ -83,6 +83,15 @@ public class MaterialsInventoryController extends BaseController
         return toAjax(materialsInventoryService.insertMaterialsInventory(materialsInventory));
     }
 
+    /**
+     * 出库
+     */
+    @PutMapping("/inventoryout")
+    public AjaxResult inventoryout(@RequestBody MaterialsInventory materialsInventory)
+    {
+        return toAjax(materialsInventoryService.updateMaterialsInventoryout(materialsInventory));
+    }
+
     /**
      * 修改半成品库存
      */
@@ -94,6 +103,7 @@ public class MaterialsInventoryController extends BaseController
         return toAjax(materialsInventoryService.updateMaterialsInventory(materialsInventory));
     }
 
+
     /**
      * 删除半成品库存
      */

+ 264 - 0
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/domain/ErrorInformation.java

@@ -0,0 +1,264 @@
+package com.zkqy.amichi.domain;
+
+import java.util.Date;
+import com.fasterxml.jackson.annotation.JsonFormat;
+import org.apache.commons.lang3.builder.ToStringBuilder;
+import org.apache.commons.lang3.builder.ToStringStyle;
+import com.zkqy.common.annotation.Excel;
+import com.zkqy.common.core.domain.BaseEntity;
+
+/**
+ * 手持机错误日志对象 error_information
+ * 
+ * @author ruoyi
+ * @date 2025-07-15
+ */
+public class ErrorInformation extends BaseEntity
+{
+    private static final long serialVersionUID = 1L;
+
+    /** 主键 */
+    private Long id;
+
+    /** 设备编号 */
+    @Excel(name = "设备编号")
+    private String deviceNumber;
+
+    /** 设备名称 */
+    @Excel(name = "设备名称")
+    private String deviceName;
+
+    /** 扫描时间 */
+    @JsonFormat(pattern = "yyyy-MM-dd")
+    @Excel(name = "扫描时间", width = 30, dateFormat = "yyyy-MM-dd")
+    private Date scanningTime;
+
+    /** 扫描内容 */
+    @Excel(name = "扫描内容")
+    private String contentInformation;
+
+    /** 原生编号 */
+    @Excel(name = "原生编号")
+    private String nativeNumbering;
+
+    /** 扫描人 */
+    @Excel(name = "扫描人")
+    private String personnelName;
+
+    /** 工序编号 */
+    @Excel(name = "工序编号")
+    private String process;
+
+    /** 工序名称 */
+    @Excel(name = "工序名称")
+    private String processName;
+
+    /** 订单号 */
+    @Excel(name = "订单号")
+    private String orderNumber;
+
+    /** 生产订单号 */
+    @Excel(name = "生产订单号")
+    private String productionOrderNumber;
+
+    /** 工位id */
+    @Excel(name = "工位id")
+    private String stationId;
+
+    /** 工位名称 */
+    @Excel(name = "工位名称")
+    private String stationName;
+
+    /** 1:成功 2:失败 */
+    @Excel(name = "1:成功 2:失败")
+    private String executionMark;
+
+    /** 执行信息 */
+    @Excel(name = "执行信息")
+    private String executionMessage;
+
+    /** 完成数量 */
+    @Excel(name = "完成数量")
+    private String overNumber;
+
+    /** 产品id */
+    @Excel(name = "产品id")
+    private Long cpId;
+
+    public void setId(Long id) 
+    {
+        this.id = id;
+    }
+
+    public Long getId() 
+    {
+        return id;
+    }
+    public void setDeviceNumber(String deviceNumber) 
+    {
+        this.deviceNumber = deviceNumber;
+    }
+
+    public String getDeviceNumber() 
+    {
+        return deviceNumber;
+    }
+    public void setDeviceName(String deviceName) 
+    {
+        this.deviceName = deviceName;
+    }
+
+    public String getDeviceName() 
+    {
+        return deviceName;
+    }
+    public void setScanningTime(Date scanningTime) 
+    {
+        this.scanningTime = scanningTime;
+    }
+
+    public Date getScanningTime() 
+    {
+        return scanningTime;
+    }
+    public void setContentInformation(String contentInformation) 
+    {
+        this.contentInformation = contentInformation;
+    }
+
+    public String getContentInformation() 
+    {
+        return contentInformation;
+    }
+    public void setNativeNumbering(String nativeNumbering) 
+    {
+        this.nativeNumbering = nativeNumbering;
+    }
+
+    public String getNativeNumbering() 
+    {
+        return nativeNumbering;
+    }
+    public void setPersonnelName(String personnelName) 
+    {
+        this.personnelName = personnelName;
+    }
+
+    public String getPersonnelName() 
+    {
+        return personnelName;
+    }
+    public void setProcess(String process) 
+    {
+        this.process = process;
+    }
+
+    public String getProcess() 
+    {
+        return process;
+    }
+    public void setProcessName(String processName) 
+    {
+        this.processName = processName;
+    }
+
+    public String getProcessName() 
+    {
+        return processName;
+    }
+    public void setOrderNumber(String orderNumber) 
+    {
+        this.orderNumber = orderNumber;
+    }
+
+    public String getOrderNumber() 
+    {
+        return orderNumber;
+    }
+    public void setProductionOrderNumber(String productionOrderNumber) 
+    {
+        this.productionOrderNumber = productionOrderNumber;
+    }
+
+    public String getProductionOrderNumber() 
+    {
+        return productionOrderNumber;
+    }
+    public void setStationId(String stationId) 
+    {
+        this.stationId = stationId;
+    }
+
+    public String getStationId() 
+    {
+        return stationId;
+    }
+    public void setStationName(String stationName) 
+    {
+        this.stationName = stationName;
+    }
+
+    public String getStationName() 
+    {
+        return stationName;
+    }
+    public void setExecutionMark(String executionMark) 
+    {
+        this.executionMark = executionMark;
+    }
+
+    public String getExecutionMark() 
+    {
+        return executionMark;
+    }
+    public void setExecutionMessage(String executionMessage) 
+    {
+        this.executionMessage = executionMessage;
+    }
+
+    public String getExecutionMessage() 
+    {
+        return executionMessage;
+    }
+    public void setOverNumber(String overNumber) 
+    {
+        this.overNumber = overNumber;
+    }
+
+    public String getOverNumber() 
+    {
+        return overNumber;
+    }
+    public void setCpId(Long cpId) 
+    {
+        this.cpId = cpId;
+    }
+
+    public Long getCpId() 
+    {
+        return cpId;
+    }
+
+    @Override
+    public String toString() {
+        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
+            .append("id", getId())
+            .append("deviceNumber", getDeviceNumber())
+            .append("deviceName", getDeviceName())
+            .append("scanningTime", getScanningTime())
+            .append("contentInformation", getContentInformation())
+            .append("nativeNumbering", getNativeNumbering())
+            .append("personnelName", getPersonnelName())
+            .append("process", getProcess())
+            .append("processName", getProcessName())
+            .append("orderNumber", getOrderNumber())
+            .append("productionOrderNumber", getProductionOrderNumber())
+            .append("stationId", getStationId())
+            .append("stationName", getStationName())
+            .append("executionMark", getExecutionMark())
+            .append("executionMessage", getExecutionMessage())
+            .append("overNumber", getOverNumber())
+            .append("cpId", getCpId())
+            .toString();
+    }
+}

+ 61 - 0
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/mapper/ErrorInformationMapper.java

@@ -0,0 +1,61 @@
+package com.zkqy.amichi.mapper;
+
+import java.util.List;
+import com.zkqy.amichi.domain.ErrorInformation;
+
+/**
+ * 手持机错误日志Mapper接口
+ * 
+ * @author ruoyi
+ * @date 2025-07-15
+ */
+public interface ErrorInformationMapper 
+{
+    /**
+     * 查询手持机错误日志
+     * 
+     * @param id 手持机错误日志主键
+     * @return 手持机错误日志
+     */
+    public ErrorInformation selectErrorInformationById(Long id);
+
+    /**
+     * 查询手持机错误日志列表
+     * 
+     * @param errorInformation 手持机错误日志
+     * @return 手持机错误日志集合
+     */
+    public List<ErrorInformation> selectErrorInformationList(ErrorInformation errorInformation);
+
+    /**
+     * 新增手持机错误日志
+     * 
+     * @param errorInformation 手持机错误日志
+     * @return 结果
+     */
+    public int insertErrorInformation(ErrorInformation errorInformation);
+
+    /**
+     * 修改手持机错误日志
+     * 
+     * @param errorInformation 手持机错误日志
+     * @return 结果
+     */
+    public int updateErrorInformation(ErrorInformation errorInformation);
+
+    /**
+     * 删除手持机错误日志
+     * 
+     * @param id 手持机错误日志主键
+     * @return 结果
+     */
+    public int deleteErrorInformationById(Long id);
+
+    /**
+     * 批量删除手持机错误日志
+     * 
+     * @param ids 需要删除的数据主键集合
+     * @return 结果
+     */
+    public int deleteErrorInformationByIds(Long[] ids);
+}

+ 61 - 0
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/service/IErrorInformationService.java

@@ -0,0 +1,61 @@
+package com.zkqy.amichi.service;
+
+import java.util.List;
+import com.zkqy.amichi.domain.ErrorInformation;
+
+/**
+ * 手持机错误日志Service接口
+ * 
+ * @author ruoyi
+ * @date 2025-07-15
+ */
+public interface IErrorInformationService 
+{
+    /**
+     * 查询手持机错误日志
+     * 
+     * @param id 手持机错误日志主键
+     * @return 手持机错误日志
+     */
+    public ErrorInformation selectErrorInformationById(Long id);
+
+    /**
+     * 查询手持机错误日志列表
+     * 
+     * @param errorInformation 手持机错误日志
+     * @return 手持机错误日志集合
+     */
+    public List<ErrorInformation> selectErrorInformationList(ErrorInformation errorInformation);
+
+    /**
+     * 新增手持机错误日志
+     * 
+     * @param errorInformation 手持机错误日志
+     * @return 结果
+     */
+    public int insertErrorInformation(ErrorInformation errorInformation);
+
+    /**
+     * 修改手持机错误日志
+     * 
+     * @param errorInformation 手持机错误日志
+     * @return 结果
+     */
+    public int updateErrorInformation(ErrorInformation errorInformation);
+
+    /**
+     * 批量删除手持机错误日志
+     * 
+     * @param ids 需要删除的手持机错误日志主键集合
+     * @return 结果
+     */
+    public int deleteErrorInformationByIds(Long[] ids);
+
+    /**
+     * 删除手持机错误日志信息
+     * 
+     * @param id 手持机错误日志主键
+     * @return 结果
+     */
+    public int deleteErrorInformationById(Long id);
+}

+ 8 - 0
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/service/IMaterialsInventoryService.java

@@ -43,6 +43,14 @@ public interface IMaterialsInventoryService
      */
     public int updateMaterialsInventory(MaterialsInventory materialsInventory);
 
+    /**
+     * 出库
+     *
+     * @param materialsInventory 半成品库存
+     * @return 结果
+     */
+    public int updateMaterialsInventoryout(MaterialsInventory materialsInventory);
+
     /**
      * 批量删除半成品库存
      * 

+ 93 - 0
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/service/impl/ErrorInformationServiceImpl.java

@@ -0,0 +1,93 @@
+package com.zkqy.amichi.service.impl;
+
+import java.util.List;
+import org.springframework.beans.factory.annotation.Autowired;
+import org.springframework.stereotype.Service;
+import com.zkqy.amichi.mapper.ErrorInformationMapper;
+import com.zkqy.amichi.domain.ErrorInformation;
+import com.zkqy.amichi.service.IErrorInformationService;
+
+/**
+ * 手持机错误日志Service业务层处理
+ * 
+ * @author ruoyi
+ * @date 2025-07-15
+ */
+@Service
+public class ErrorInformationServiceImpl implements IErrorInformationService 
+{
+    @Autowired
+    private ErrorInformationMapper errorInformationMapper;
+
+    /**
+     * 查询手持机错误日志
+     * 
+     * @param id 手持机错误日志主键
+     * @return 手持机错误日志
+     */
+    @Override
+    public ErrorInformation selectErrorInformationById(Long id)
+    {
+        return errorInformationMapper.selectErrorInformationById(id);
+    }
+
+    /**
+     * 查询手持机错误日志列表
+     * 
+     * @param errorInformation 手持机错误日志
+     * @return 手持机错误日志
+     */
+    @Override
+    public List<ErrorInformation> selectErrorInformationList(ErrorInformation errorInformation)
+    {
+        return errorInformationMapper.selectErrorInformationList(errorInformation);
+    }
+
+    /**
+     * 新增手持机错误日志
+     * 
+     * @param errorInformation 手持机错误日志
+     * @return 结果
+     */
+    @Override
+    public int insertErrorInformation(ErrorInformation errorInformation)
+    {
+        return errorInformationMapper.insertErrorInformation(errorInformation);
+    }
+
+    /**
+     * 修改手持机错误日志
+     * 
+     * @param errorInformation 手持机错误日志
+     * @return 结果
+     */
+    @Override
+    public int updateErrorInformation(ErrorInformation errorInformation)
+    {
+        return errorInformationMapper.updateErrorInformation(errorInformation);
+    }
+
+    /**
+     * 批量删除手持机错误日志
+     * 
+     * @param ids 需要删除的手持机错误日志主键
+     * @return 结果
+     */
+    @Override
+    public int deleteErrorInformationByIds(Long[] ids)
+    {
+        return errorInformationMapper.deleteErrorInformationByIds(ids);
+    }
+
+    /**
+     * 删除手持机错误日志信息
+     * 
+     * @param id 手持机错误日志主键
+     * @return 结果
+     */
+    @Override
+    public int deleteErrorInformationById(Long id)
+    {
+        return errorInformationMapper.deleteErrorInformationById(id);
+    }
+}

+ 44 - 0
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/service/impl/MaterialsInventoryServiceImpl.java

@@ -1,8 +1,12 @@
 package com.zkqy.amichi.service.impl;
 
+import java.util.Date;
 import java.util.List;
 
+import com.zkqy.amichi.domain.StockOutRecord;
+import com.zkqy.amichi.mapper.StockOutRecordMapper;
 import com.zkqy.common.utils.DateUtils;
+import com.zkqy.common.utils.SecurityUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import com.zkqy.amichi.mapper.MaterialsInventoryMapper;
@@ -21,6 +25,8 @@ public class MaterialsInventoryServiceImpl implements IMaterialsInventoryService
     @Autowired
     private MaterialsInventoryMapper materialsInventoryMapper;
 
+    @Autowired
+    private StockOutRecordMapper stockOutRecordMapper;
     /**
      * 查询半成品库存
      *
@@ -71,6 +77,44 @@ public class MaterialsInventoryServiceImpl implements IMaterialsInventoryService
         return materialsInventoryMapper.updateMaterialsInventory(materialsInventory);
     }
 
+    /**
+     * 出库
+     *
+     * @param materialsInventory 半成品库存
+     * @return 结果
+     */
+    @Override
+    public int updateMaterialsInventoryout(MaterialsInventory materialsInventory)
+    {
+        //查询当前库存
+        MaterialsInventory materialsInventorylod = materialsInventoryMapper.selectMaterialsInventoryById(materialsInventory.getId());
+        //判断库存是否大于出库的库存
+        if(materialsInventorylod.getStockQuantity() > materialsInventory.getStockQuantity()){
+            //添加出库日志
+            StockOutRecord stockOutRecord=new StockOutRecord();
+            stockOutRecord.setMaterialCode(materialsInventory.getMaterialCode()); //物料编码
+            stockOutRecord.setMaterialName(materialsInventory.getMaterialName()); //物料名称
+            stockOutRecord.setModel(materialsInventory.getModel());//型号
+            stockOutRecord.setSpecification(materialsInventory.getSpecification());//规格
+            stockOutRecord.setOutQuantity(materialsInventory.getStockQuantity());//出库数量
+            stockOutRecord.setCreateTime(new Date());//创建时间
+            stockOutRecord.setInventoryId(materialsInventory.getId());
+            stockOutRecord.setCreateBy(SecurityUtils.getUsername());//操作人
+            stockOutRecord.setOperator(SecurityUtils.getUsername());//操作人
+            stockOutRecord.setCreateById(SecurityUtils.getUserId());//操作人id
+            stockOutRecord.setInboundType("手动出库");
+            stockOutRecord.setRkdbh("");
+            stockOutRecordMapper.insertStockOutRecord(stockOutRecord);
+            //计算库存,出库
+            materialsInventory.setStockQuantity(materialsInventorylod.getStockQuantity()-materialsInventory.getStockQuantity());//扣库存
+            materialsInventory.setUpdateTime(DateUtils.getNowDate());
+            return materialsInventoryMapper.updateMaterialsInventory(materialsInventory);
+        }else{
+            return 0;
+        }
+    }
+
+
     /**
      * 批量删除半成品库存
      *

+ 1 - 1
zkqy-fujian-amichi/src/main/java/com/zkqy/amichi/service/impl/StockInOrderServiceImpl.java

@@ -231,7 +231,7 @@ public class StockInOrderServiceImpl implements IStockInOrderService
         StockInOrder stockInOrderCopy=new StockInOrder();
         BeanUtils.copyProperties(stockInOrder,stockInOrderCopy);
         int i = stockInOrderMapper.insertStockInOrder(stockInOrderCopy);//添加入库单信息
-//操作入库单明细信息
+        //操作入库单明细信息
         List<StockInOrderDetail> stockInOrderDetailList = stockInOrder.getOrderDetailList();
         stockInOrderDetailList.forEach(item->{
 

+ 131 - 0
zkqy-fujian-amichi/src/main/resources/mapper/ErrorInformationMapper.xml

@@ -0,0 +1,131 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!DOCTYPE mapper
+PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<mapper namespace="com.zkqy.amichi.mapper.ErrorInformationMapper">
+    
+    <resultMap type="com.zkqy.amichi.domain.ErrorInformation" id="ErrorInformationResult">
+        <result property="id"    column="id"    />
+        <result property="deviceNumber"    column="device_number"    />
+        <result property="deviceName"    column="device_name"    />
+        <result property="scanningTime"    column="scanning_time"    />
+        <result property="contentInformation"    column="content_information"    />
+        <result property="nativeNumbering"    column="native_numbering"    />
+        <result property="personnelName"    column="personnel_name"    />
+        <result property="process"    column="process"    />
+        <result property="processName"    column="process_name"    />
+        <result property="orderNumber"    column="order_number"    />
+        <result property="productionOrderNumber"    column="production_order_number"    />
+        <result property="stationId"    column="station_id"    />
+        <result property="stationName"    column="station_name"    />
+        <result property="executionMark"    column="execution_mark"    />
+        <result property="executionMessage"    column="execution_message"    />
+        <result property="overNumber"    column="over_number"    />
+        <result property="cpId"    column="cp_id"    />
+    </resultMap>
+
+    <sql id="selectErrorInformationVo">
+        select id, device_number, device_name, scanning_time, content_information, native_numbering, personnel_name, process, process_name, order_number, production_order_number, station_id, station_name, execution_mark, execution_message, over_number, cp_id from fjqydb.error_information
+    </sql>
+
+    <select id="selectErrorInformationList" parameterType="com.zkqy.amichi.domain.ErrorInformation" resultMap="ErrorInformationResult">
+        <include refid="selectErrorInformationVo"/>
+        <where>  
+            <if test="deviceNumber != null  and deviceNumber != ''"> and device_number = #{deviceNumber}</if>
+            <if test="deviceName != null  and deviceName != ''"> and device_name like concat('%', #{deviceName}, '%')</if>
+            <if test="scanningTime != null "> and scanning_time = #{scanningTime}</if>
+            <if test="contentInformation != null  and contentInformation != ''"> and content_information = #{contentInformation}</if>
+            <if test="nativeNumbering != null  and nativeNumbering != ''"> and native_numbering = #{nativeNumbering}</if>
+            <if test="personnelName != null  and personnelName != ''"> and personnel_name like concat('%', #{personnelName}, '%')</if>
+            <if test="process != null  and process != ''"> and process = #{process}</if>
+            <if test="processName != null  and processName != ''"> and process_name like concat('%', #{processName}, '%')</if>
+            <if test="orderNumber != null  and orderNumber != ''"> and order_number = #{orderNumber}</if>
+            <if test="productionOrderNumber != null  and productionOrderNumber != ''"> and production_order_number = #{productionOrderNumber}</if>
+            <if test="stationId != null  and stationId != ''"> and station_id = #{stationId}</if>
+            <if test="stationName != null  and stationName != ''"> and station_name like concat('%', #{stationName}, '%')</if>
+            <if test="executionMark != null  and executionMark != ''"> and execution_mark = #{executionMark}</if>
+            <if test="executionMessage != null  and executionMessage != ''"> and execution_message = #{executionMessage}</if>
+            <if test="overNumber != null  and overNumber != ''"> and over_number = #{overNumber}</if>
+            <if test="cpId != null "> and cp_id = #{cpId}</if>
+        </where>
+    </select>
+    
+    <select id="selectErrorInformationById" parameterType="Long" resultMap="ErrorInformationResult">
+        <include refid="selectErrorInformationVo"/>
+        where id = #{id}
+    </select>
+
+    <insert id="insertErrorInformation" parameterType="com.zkqy.amichi.domain.ErrorInformation" useGeneratedKeys="true" keyProperty="id">
+        insert into fjqydb.error_information
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+            <if test="deviceNumber != null">device_number,</if>
+            <if test="deviceName != null">device_name,</if>
+            <if test="scanningTime != null">scanning_time,</if>
+            <if test="contentInformation != null">content_information,</if>
+            <if test="nativeNumbering != null">native_numbering,</if>
+            <if test="personnelName != null">personnel_name,</if>
+            <if test="process != null">process,</if>
+            <if test="processName != null">process_name,</if>
+            <if test="orderNumber != null">order_number,</if>
+            <if test="productionOrderNumber != null">production_order_number,</if>
+            <if test="stationId != null">station_id,</if>
+            <if test="stationName != null">station_name,</if>
+            <if test="executionMark != null">execution_mark,</if>
+            <if test="executionMessage != null">execution_message,</if>
+            <if test="overNumber != null">over_number,</if>
+            <if test="cpId != null">cp_id,</if>
+         </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+            <if test="deviceNumber != null">#{deviceNumber},</if>
+            <if test="deviceName != null">#{deviceName},</if>
+            <if test="scanningTime != null">#{scanningTime},</if>
+            <if test="contentInformation != null">#{contentInformation},</if>
+            <if test="nativeNumbering != null">#{nativeNumbering},</if>
+            <if test="personnelName != null">#{personnelName},</if>
+            <if test="process != null">#{process},</if>
+            <if test="processName != null">#{processName},</if>
+            <if test="orderNumber != null">#{orderNumber},</if>
+            <if test="productionOrderNumber != null">#{productionOrderNumber},</if>
+            <if test="stationId != null">#{stationId},</if>
+            <if test="stationName != null">#{stationName},</if>
+            <if test="executionMark != null">#{executionMark},</if>
+            <if test="executionMessage != null">#{executionMessage},</if>
+            <if test="overNumber != null">#{overNumber},</if>
+            <if test="cpId != null">#{cpId},</if>
+         </trim>
+    </insert>
+
+    <update id="updateErrorInformation" parameterType="com.zkqy.amichi.domain.ErrorInformation">
+        update fjqydb.error_information
+        <trim prefix="SET" suffixOverrides=",">
+            <if test="deviceNumber != null">device_number = #{deviceNumber},</if>
+            <if test="deviceName != null">device_name = #{deviceName},</if>
+            <if test="scanningTime != null">scanning_time = #{scanningTime},</if>
+            <if test="contentInformation != null">content_information = #{contentInformation},</if>
+            <if test="nativeNumbering != null">native_numbering = #{nativeNumbering},</if>
+            <if test="personnelName != null">personnel_name = #{personnelName},</if>
+            <if test="process != null">process = #{process},</if>
+            <if test="processName != null">process_name = #{processName},</if>
+            <if test="orderNumber != null">order_number = #{orderNumber},</if>
+            <if test="productionOrderNumber != null">production_order_number = #{productionOrderNumber},</if>
+            <if test="stationId != null">station_id = #{stationId},</if>
+            <if test="stationName != null">station_name = #{stationName},</if>
+            <if test="executionMark != null">execution_mark = #{executionMark},</if>
+            <if test="executionMessage != null">execution_message = #{executionMessage},</if>
+            <if test="overNumber != null">over_number = #{overNumber},</if>
+            <if test="cpId != null">cp_id = #{cpId},</if>
+        </trim>
+        where id = #{id}
+    </update>
+
+    <delete id="deleteErrorInformationById" parameterType="Long">
+        delete from fjqydb.error_information where id = #{id}
+    </delete>
+
+    <delete id="deleteErrorInformationByIds" parameterType="String">
+        delete from fjqydb.error_information where id in
+        <foreach item="id" collection="array" open="(" separator="," close=")">
+            #{id}
+        </foreach>
+    </delete>
+</mapper>

+ 9 - 0
zkqy-ui/src/api/amichi/indoor/inventory.js

@@ -35,6 +35,15 @@ export function updateInventory(data) {
   })
 }
 
+// 出库
+export function inventoryout(data) {
+  return request({
+    url: '/indoor/inventory/inventoryout',
+    method: 'put',
+    data: data
+  })
+}
+
 // 删除半成品库存
 export function delInventory(id) {
   return request({

+ 8 - 0
zkqy-ui/src/api/amichi/indoor/order.js

@@ -34,6 +34,14 @@ export function stockInOrderAndOrderDetail(data) {
   })
 }
 
+export function stockInOrderAndOrderDetailLc(data) {
+  return request({
+    url: '/indoor/order/stockInOrderAndOrderDetail',
+    method: 'post',
+    data: data
+  })
+}
+
 // 修改半成品入库单主
 export function updateOrder(data) {
   return request({

+ 44 - 0
zkqy-ui/src/api/errorInformation/errorInformation.js

@@ -0,0 +1,44 @@
+import request from '@/utils/request'
+
+// 查询手持机错误日志列表
+export function listErrorInformation(query) {
+  return request({
+    url: '/errorInformation/errorInformation/list',
+    method: 'get',
+    params: query
+  })
+}
+
+// 查询手持机错误日志详细
+export function getErrorInformation(id) {
+  return request({
+    url: '/errorInformation/errorInformation/' + id,
+    method: 'get'
+  })
+}
+
+// 新增手持机错误日志
+export function addErrorInformation(data) {
+  return request({
+    url: '/errorInformation/errorInformation',
+    method: 'post',
+    data: data
+  })
+}
+
+// 修改手持机错误日志
+export function updateErrorInformation(data) {
+  return request({
+    url: '/errorInformation/errorInformation',
+    method: 'put',
+    data: data
+  })
+}
+
+// 删除手持机错误日志
+export function delErrorInformation(id) {
+  return request({
+    url: '/errorInformation/errorInformation/' + id,
+    method: 'delete'
+  })
+}

+ 464 - 0
zkqy-ui/src/views/amichi/errorInformation/index.vue

@@ -0,0 +1,464 @@
+<template>
+  <div class="app-container">
+    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
+      <el-form-item label="设备编号" prop="deviceNumber">
+        <el-input
+          v-model="queryParams.deviceNumber"
+          placeholder="请输入设备编号"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="设备名称" prop="deviceName">
+        <el-input
+          v-model="queryParams.deviceName"
+          placeholder="请输入设备名称"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="扫描时间" prop="scanningTime">
+        <el-date-picker clearable
+          v-model="queryParams.scanningTime"
+          type="date"
+          value-format="yyyy-MM-dd"
+          placeholder="请选择扫描时间">
+        </el-date-picker>
+      </el-form-item>
+      <el-form-item label="扫描内容" prop="contentInformation">
+        <el-input
+          v-model="queryParams.contentInformation"
+          placeholder="请输入扫描内容"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="原生编号" prop="nativeNumbering">
+        <el-input
+          v-model="queryParams.nativeNumbering"
+          placeholder="请输入原生编号"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="扫描人" prop="personnelName">
+        <el-input
+          v-model="queryParams.personnelName"
+          placeholder="请输入扫描人"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="工序编号" prop="process">
+        <el-input
+          v-model="queryParams.process"
+          placeholder="请输入工序编号"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="工序名称" prop="processName">
+        <el-input
+          v-model="queryParams.processName"
+          placeholder="请输入工序名称"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="订单号" prop="orderNumber">
+        <el-input
+          v-model="queryParams.orderNumber"
+          placeholder="请输入订单号"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="生产订单号" prop="productionOrderNumber">
+        <el-input
+          v-model="queryParams.productionOrderNumber"
+          placeholder="请输入生产订单号"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="工位id" prop="stationId">
+        <el-input
+          v-model="queryParams.stationId"
+          placeholder="请输入工位id"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="工位名称" prop="stationName">
+        <el-input
+          v-model="queryParams.stationName"
+          placeholder="请输入工位名称"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="1:成功 2:失败" prop="executionMark">
+        <el-input
+          v-model="queryParams.executionMark"
+          placeholder="请输入1:成功 2:失败"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="执行信息" prop="executionMessage">
+        <el-input
+          v-model="queryParams.executionMessage"
+          placeholder="请输入执行信息"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="完成数量" prop="overNumber">
+        <el-input
+          v-model="queryParams.overNumber"
+          placeholder="请输入完成数量"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item label="产品id" prop="cpId">
+        <el-input
+          v-model="queryParams.cpId"
+          placeholder="请输入产品id"
+          clearable
+          @keyup.enter.native="handleQuery"
+        />
+      </el-form-item>
+      <el-form-item>
+        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
+        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
+      </el-form-item>
+    </el-form>
+
+    <el-row :gutter="10" class="mb8">
+      <el-col :span="1.5">
+        <el-button
+          type="primary"
+          plain
+          icon="el-icon-plus"
+          size="mini"
+          @click="handleAdd"
+          v-hasPermi="['errorInformation:errorInformation:add']"
+        >新增</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="success"
+          plain
+          icon="el-icon-edit"
+          size="mini"
+          :disabled="single"
+          @click="handleUpdate"
+          v-hasPermi="['errorInformation:errorInformation:edit']"
+        >修改</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="danger"
+          plain
+          icon="el-icon-delete"
+          size="mini"
+          :disabled="multiple"
+          @click="handleDelete"
+          v-hasPermi="['errorInformation:errorInformation:remove']"
+        >删除</el-button>
+      </el-col>
+      <el-col :span="1.5">
+        <el-button
+          type="warning"
+          plain
+          icon="el-icon-download"
+          size="mini"
+          @click="handleExport"
+          v-hasPermi="['errorInformation:errorInformation:export']"
+        >导出</el-button>
+      </el-col>
+      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
+    </el-row>
+
+    <el-table v-loading="loading" :data="errorInformationList" @selection-change="handleSelectionChange">
+      <el-table-column type="selection" width="55" align="center" />
+      <el-table-column label="主键" align="center" prop="id" />
+      <el-table-column label="设备编号" align="center" prop="deviceNumber" />
+      <el-table-column label="设备名称" align="center" prop="deviceName" />
+      <el-table-column label="扫描时间" align="center" prop="scanningTime" width="180">
+        <template slot-scope="scope">
+          <span>{{ parseTime(scope.row.scanningTime, '{y}-{m}-{d}') }}</span>
+        </template>
+      </el-table-column>
+      <el-table-column label="扫描内容" align="center" prop="contentInformation" />
+      <el-table-column label="原生编号" align="center" prop="nativeNumbering" />
+      <el-table-column label="扫描人" align="center" prop="personnelName" />
+      <el-table-column label="工序编号" align="center" prop="process" />
+      <el-table-column label="工序名称" align="center" prop="processName" />
+      <el-table-column label="订单号" align="center" prop="orderNumber" />
+      <el-table-column label="生产订单号" align="center" prop="productionOrderNumber" />
+      <el-table-column label="工位id" align="center" prop="stationId" />
+      <el-table-column label="工位名称" align="center" prop="stationName" />
+      <el-table-column label="1:成功 2:失败" align="center" prop="executionMark" />
+      <el-table-column label="执行信息" align="center" prop="executionMessage" />
+      <el-table-column label="完成数量" align="center" prop="overNumber" />
+      <el-table-column label="产品id" align="center" prop="cpId" />
+      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
+        <template slot-scope="scope">
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-edit"
+            @click="handleUpdate(scope.row)"
+            v-hasPermi="['errorInformation:errorInformation:edit']"
+          >修改</el-button>
+          <el-button
+            size="mini"
+            type="text"
+            icon="el-icon-delete"
+            @click="handleDelete(scope.row)"
+            v-hasPermi="['errorInformation:errorInformation:remove']"
+          >删除</el-button>
+        </template>
+      </el-table-column>
+    </el-table>
+    
+    <pagination
+      v-show="total>0"
+      :total="total"
+      :page.sync="queryParams.pageNum"
+      :limit.sync="queryParams.pageSize"
+      @pagination="getList"
+    />
+
+    <!-- 添加或修改手持机错误日志对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="设备编号" prop="deviceNumber">
+          <el-input v-model="form.deviceNumber" placeholder="请输入设备编号" />
+        </el-form-item>
+        <el-form-item label="设备名称" prop="deviceName">
+          <el-input v-model="form.deviceName" placeholder="请输入设备名称" />
+        </el-form-item>
+        <el-form-item label="扫描时间" prop="scanningTime">
+          <el-date-picker clearable
+            v-model="form.scanningTime"
+            type="date"
+            value-format="yyyy-MM-dd"
+            placeholder="请选择扫描时间">
+          </el-date-picker>
+        </el-form-item>
+        <el-form-item label="扫描内容" prop="contentInformation">
+          <el-input v-model="form.contentInformation" placeholder="请输入扫描内容" />
+        </el-form-item>
+        <el-form-item label="原生编号" prop="nativeNumbering">
+          <el-input v-model="form.nativeNumbering" placeholder="请输入原生编号" />
+        </el-form-item>
+        <el-form-item label="扫描人" prop="personnelName">
+          <el-input v-model="form.personnelName" placeholder="请输入扫描人" />
+        </el-form-item>
+        <el-form-item label="工序编号" prop="process">
+          <el-input v-model="form.process" placeholder="请输入工序编号" />
+        </el-form-item>
+        <el-form-item label="工序名称" prop="processName">
+          <el-input v-model="form.processName" placeholder="请输入工序名称" />
+        </el-form-item>
+        <el-form-item label="订单号" prop="orderNumber">
+          <el-input v-model="form.orderNumber" placeholder="请输入订单号" />
+        </el-form-item>
+        <el-form-item label="生产订单号" prop="productionOrderNumber">
+          <el-input v-model="form.productionOrderNumber" placeholder="请输入生产订单号" />
+        </el-form-item>
+        <el-form-item label="工位id" prop="stationId">
+          <el-input v-model="form.stationId" placeholder="请输入工位id" />
+        </el-form-item>
+        <el-form-item label="工位名称" prop="stationName">
+          <el-input v-model="form.stationName" placeholder="请输入工位名称" />
+        </el-form-item>
+        <el-form-item label="1:成功 2:失败" prop="executionMark">
+          <el-input v-model="form.executionMark" placeholder="请输入1:成功 2:失败" />
+        </el-form-item>
+        <el-form-item label="执行信息" prop="executionMessage">
+          <el-input v-model="form.executionMessage" placeholder="请输入执行信息" />
+        </el-form-item>
+        <el-form-item label="完成数量" prop="overNumber">
+          <el-input v-model="form.overNumber" placeholder="请输入完成数量" />
+        </el-form-item>
+        <el-form-item label="产品id" prop="cpId">
+          <el-input v-model="form.cpId" placeholder="请输入产品id" />
+        </el-form-item>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitForm">确 定</el-button>
+        <el-button @click="cancel">取 消</el-button>
+      </div>
+    </el-dialog>
+  </div>
+</template>
+
+<script>
+import { listErrorInformation, getErrorInformation, delErrorInformation, addErrorInformation, updateErrorInformation } from "@/api/errorInformation/errorInformation";
+
+export default {
+  name: "ErrorInformation",
+  data() {
+    return {
+      // 遮罩层
+      loading: true,
+      // 选中数组
+      ids: [],
+      // 非单个禁用
+      single: true,
+      // 非多个禁用
+      multiple: true,
+      // 显示搜索条件
+      showSearch: true,
+      // 总条数
+      total: 0,
+      // 手持机错误日志表格数据
+      errorInformationList: [],
+      // 弹出层标题
+      title: "",
+      // 是否显示弹出层
+      open: false,
+      // 查询参数
+      queryParams: {
+        pageNum: 1,
+        pageSize: 10,
+        deviceNumber: null,
+        deviceName: null,
+        scanningTime: null,
+        contentInformation: null,
+        nativeNumbering: null,
+        personnelName: null,
+        process: null,
+        processName: null,
+        orderNumber: null,
+        productionOrderNumber: null,
+        stationId: null,
+        stationName: null,
+        executionMark: null,
+        executionMessage: null,
+        overNumber: null,
+        cpId: null
+      },
+      // 表单参数
+      form: {},
+      // 表单校验
+      rules: {
+      }
+    };
+  },
+  created() {
+    this.getList();
+  },
+  methods: {
+    /** 查询手持机错误日志列表 */
+    getList() {
+      this.loading = true;
+      listErrorInformation(this.queryParams).then(response => {
+        this.errorInformationList = response.rows;
+        this.total = response.total;
+        this.loading = false;
+      });
+    },
+    // 取消按钮
+    cancel() {
+      this.open = false;
+      this.reset();
+    },
+    // 表单重置
+    reset() {
+      this.form = {
+        id: null,
+        deviceNumber: null,
+        deviceName: null,
+        scanningTime: null,
+        contentInformation: null,
+        nativeNumbering: null,
+        personnelName: null,
+        process: null,
+        processName: null,
+        orderNumber: null,
+        productionOrderNumber: null,
+        stationId: null,
+        stationName: null,
+        executionMark: null,
+        executionMessage: null,
+        overNumber: null,
+        cpId: null
+      };
+      this.resetForm("form");
+    },
+    /** 搜索按钮操作 */
+    handleQuery() {
+      this.queryParams.pageNum = 1;
+      this.getList();
+    },
+    /** 重置按钮操作 */
+    resetQuery() {
+      this.resetForm("queryForm");
+      this.handleQuery();
+    },
+    // 多选框选中数据
+    handleSelectionChange(selection) {
+      this.ids = selection.map(item => item.id)
+      this.single = selection.length!==1
+      this.multiple = !selection.length
+    },
+    /** 新增按钮操作 */
+    handleAdd() {
+      this.reset();
+      this.open = true;
+      this.title = "添加手持机错误日志";
+    },
+    /** 修改按钮操作 */
+    handleUpdate(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getErrorInformation(id).then(response => {
+        this.form = response.data;
+        this.open = true;
+        this.title = "修改手持机错误日志";
+      });
+    },
+    /** 提交按钮 */
+    submitForm() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            updateErrorInformation(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            addErrorInformation(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.open = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 删除按钮操作 */
+    handleDelete(row) {
+      const ids = row.id || this.ids;
+      this.$modal.confirm('是否确认删除手持机错误日志编号为"' + ids + '"的数据项?').then(function() {
+        return delErrorInformation(ids);
+      }).then(() => {
+        this.getList();
+        this.$modal.msgSuccess("删除成功");
+      }).catch(() => {});
+    },
+    /** 导出按钮操作 */
+    handleExport() {
+      this.download('errorInformation/errorInformation/export', {
+        ...this.queryParams
+      }, `errorInformation_${new Date().getTime()}.xlsx`)
+    }
+  }
+};
+</script>

+ 489 - 57
zkqy-ui/src/views/amichi/planTask/indoor/inventory/index.vue

@@ -57,38 +57,48 @@
     </el-form>
 
     <el-row :gutter="10" class="mb8">
+<!--      <el-col :span="1.5">-->
+<!--        <el-button-->
+<!--          type="primary"-->
+<!--          plain-->
+<!--          icon="el-icon-plus"-->
+<!--          size="mini"-->
+<!--          @click="handleAdd"-->
+<!--          v-hasPermi="['indoor:inventory:add']"-->
+<!--        >新增</el-button>-->
+<!--      </el-col>-->
       <el-col :span="1.5">
         <el-button
           type="primary"
           plain
           icon="el-icon-plus"
           size="mini"
-          @click="handleAdd"
-          v-hasPermi="['indoor:inventory:add']"
-        >新增</el-button>
-      </el-col>
-      <el-col :span="1.5">
-        <el-button
-          type="success"
-          plain
-          icon="el-icon-edit"
-          size="mini"
-          :disabled="single"
-          @click="handleUpdate"
-          v-hasPermi="['indoor:inventory:edit']"
-        >修改</el-button>
-      </el-col>
-      <el-col :span="1.5">
-        <el-button
-          type="danger"
-          plain
-          icon="el-icon-delete"
-          size="mini"
-          :disabled="multiple"
-          @click="handleDelete"
-          v-hasPermi="['indoor:inventory:remove']"
-        >删除</el-button>
+          @click="handleAddLc"
+          v-hasPermi="['indoor:order:add']"
+        >励磁入库</el-button>
       </el-col>
+<!--      <el-col :span="1.5">-->
+<!--        <el-button-->
+<!--          type="success"-->
+<!--          plain-->
+<!--          icon="el-icon-edit"-->
+<!--          size="mini"-->
+<!--          :disabled="single"-->
+<!--          @click="handleUpdatess"-->
+<!--          v-hasPermi="['indoor:inventory:edit']"-->
+<!--        >修改</el-button>-->
+<!--      </el-col>-->
+<!--      <el-col :span="1.5">-->
+<!--        <el-button-->
+<!--          type="danger"-->
+<!--          plain-->
+<!--          icon="el-icon-delete"-->
+<!--          size="mini"-->
+<!--          :disabled="multiple"-->
+<!--          @click="handleDelete"-->
+<!--          v-hasPermi="['indoor:inventory:remove']"-->
+<!--        >删除</el-button>-->
+<!--      </el-col>-->
       <el-col :span="1.5">
         <el-button
           type="warning"
@@ -104,15 +114,15 @@
 
     <el-table v-loading="loading" :data="inventoryList" style="margin-top: 20px" @selection-change="handleSelectionChange">
       <el-table-column type="selection" width="55" align="center" />
-      <el-table-column label="主键ID" align="center" prop="id" />
+<!--      <el-table-column label="主键ID" align="center" prop="id" />-->
       <el-table-column label="物料编码" align="center" prop="materialCode" />
       <el-table-column label="物料名称" align="center" prop="materialName" />
       <el-table-column label="型号" align="center" prop="model" />
       <el-table-column label="规格" align="center" prop="specification" />
       <el-table-column label="库存数量" align="center" prop="stockQuantity" />
       <el-table-column label="备注" align="center" prop="remark" />
-      <el-table-column label="操作人" align="center" prop="createBy" />
-      <el-table-column label="修改人" align="center" prop="updateBy" />
+<!--      <el-table-column label="操作人" align="center" prop="createBy" />-->
+<!--      <el-table-column label="修改人" align="center" prop="updateBy" />-->
       <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
         <template slot-scope="scope">
           <el-dropdown @command="(command)=>{handleCommand(command, scope.row)}">
@@ -121,7 +131,8 @@
             </el-button>
             <el-dropdown-menu slot="dropdown">
               <el-dropdown-item  icon="el-icon-edit"  command="handleUpdate">修改</el-dropdown-item>
-              <el-dropdown-item  icon="el-icon-delete" command="handleDelete">删除</el-dropdown-item>
+              <el-dropdown-item  icon="el-icon-edit"  command="handleAddLcout">出库</el-dropdown-item>
+<!--              <el-dropdown-item  icon="el-icon-delete" command="handleDelete">删除</el-dropdown-item>-->
             </el-dropdown-menu>
           </el-dropdown>
         </template>
@@ -135,21 +146,173 @@
       :limit.sync="queryParams.pageSize"
       @pagination="getList"
     />
+    <!-- 添加或修改半成品入库单主对话框 -->
+    <el-dialog
+      :title="title"
+      :visible.sync="openLc"
+      width="1200px"
+      append-to-body
+      :close-on-click-modal="false"
+      class="custom-dialog">
+      <el-form ref="form" :model="form" :rules="rules" label-width="100px" size="small">
+        <!-- 主表信息 -->
+        <el-card class="box-card" shadow="never" v-show="false">
+          <div slot="header" class="card-header">
+            <div class="header-left">
+              <i class="el-icon-document"></i>
+              <span>基本信息</span>
+            </div>
+          </div>
+          <el-row :gutter="24">
+            <el-col :span="8">
+              <el-form-item label="入库单号" prop="orderNo">
+                <el-input v-model="form.orderNo" :disabled="true" class="custom-input" />
+              </el-form-item>
+            </el-col>
+            <el-col :span="8">
+              <el-form-item label="入库时间" prop="createTime">
+                <el-date-picker
+                  v-model="form.createTime"
+                  type="datetime"
+                  :disabled="true"
+                  value-format="yyyy-MM-dd HH:mm:ss"
+                  placeholder="选择入库时间"
+                  class="custom-date-picker">
+                </el-date-picker>
+              </el-form-item>
+            </el-col>
+            <el-col :span="8">
+              <el-form-item label="创建人" prop="createBy">
+                <el-input v-model="form.createBy" :disabled="true" class="custom-input" />
+              </el-form-item>
+            </el-col>
+          </el-row>
+          <el-row>
+            <el-col :span="24">
+              <el-form-item label="备注" prop="remark">
+                <el-input
+                  v-model="form.remark"
+                  type="textarea"
+                  :rows="2"
+                  placeholder="请输入备注信息"
+                  class="custom-textarea" />
+              </el-form-item>
+            </el-col>
+          </el-row>
+        </el-card>
 
-    <!-- 添加或修改半成品库存对话框 -->
-    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+        <!-- 明细信息 -->
+        <el-card class="box-card detail-card" shadow="never">
+          <div slot="header" class="card-header">
+            <div class="header-left">
+              <i class="el-icon-tickets"></i>
+              <span>明细信息</span>
+            </div>
+            <div class="header-right">
+              <el-button
+                type="primary"
+                icon="el-icon-plus"
+                size="mini"
+                plain
+                @click="handleAddDetail">添加明细</el-button>
+            </div>
+          </div>
+          <el-table :data="form.detailList" border class="detail-table" size="small" :header-cell-style="{background:'#F5F7FA',color:'#606266'}">
+            <el-table-column type="index" label="序号" width="55" align="center" />
+            <el-table-column label="物料类型" prop="excitationType" min-width="120">
+              <template slot-scope="scope">
+                <el-select
+                  v-model="scope.row.excitationType"
+                  placeholder="请选择类型"
+                  @change="(val) => handleExcitationTypeChange(val, scope.$index)"
+                  class="custom-select">
+                  <el-option label="励磁定子" value="励磁定子"></el-option>
+                  <el-option label="励磁转子" value="励磁转子"></el-option>
+                </el-select>
+              </template>
+            </el-table-column>
+            <el-table-column label="物料编码" prop="materialCode" min-width="180">
+              <template slot-scope="scope">
+                <el-select
+                  v-model="scope.row.materialCode"
+                  placeholder="请选择物料"
+                  filterable
+                  remote
+                  reserve-keyword
+                  :remote-method="handleMaterialSearch"
+                  :loading="materialLoading"
+                  @change="(val) => handleMaterialChange(val, scope.$index)"
+                  value-key="id"
+                  class="custom-select">
+                  <el-option
+                    v-for="item in materialOptions"
+                    :key="item.code"
+                    :label="item.code + ' - ' + item.model"
+                    :value="item.code">
+                    <div>
+                      <span style="float: left">{{ item.code }}</span>
+                      <span style="float: right; color: #8492a6; font-size: 13px">{{ item.model }}</span>
+                    </div>
+                  </el-option>
+                </el-select>
+              </template>
+            </el-table-column>
+            <el-table-column label="物料名称" prop="materialName" min-width="120">
+              <template slot-scope="scope">
+                <el-input v-model="scope.row.materialName" readonly class="custom-input" />
+              </template>
+            </el-table-column>
+            <el-table-column label="型号" prop="model" min-width="120">
+              <template slot-scope="scope">
+                <el-input v-model="scope.row.model" readonly class="custom-input" />
+              </template>
+            </el-table-column>
+            <el-table-column label="规格" prop="specification" min-width="120">
+              <template slot-scope="scope">
+                <el-input v-model="scope.row.specification" readonly class="custom-input" />
+              </template>
+            </el-table-column>
+            <el-table-column label="数量" prop="inQuantity" width="150">
+              <template slot-scope="scope">
+                <el-input-number
+                  v-model="scope.row.inQuantity"
+                  :min="1"
+                  controls-position="right"
+                  class="custom-number-input" />
+              </template>
+            </el-table-column>
+            <el-table-column label="操作" align="center" width="80" fixed="right">
+              <template slot-scope="scope">
+                <el-button
+                  type="text"
+                  icon="el-icon-delete"
+                  @click="handleDeleteDetail(scope.$index)"
+                  class="delete-btn">删除</el-button>
+              </template>
+            </el-table-column>
+          </el-table>
+        </el-card>
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button @click="cancelLc" size="small">取 消</el-button>
+        <el-button type="primary" @click="submitFormLc" size="small">确 定</el-button>
+      </div>
+    </el-dialog>
+
+    <!-- 出库话框 -->
+    <el-dialog :title="title" :visible.sync="openLcout" width="500px" append-to-body>
       <el-form ref="form" :model="form" :rules="rules" label-width="80px">
         <el-form-item label="物料编码" prop="materialCode">
-          <el-input v-model="form.materialCode" placeholder="请输入物料编码" />
+          <el-input v-model="form.materialCode" placeholder="请输入物料编码" disabled/>
         </el-form-item>
         <el-form-item label="物料名称" prop="materialName">
-          <el-input v-model="form.materialName" placeholder="请输入物料名称" />
+          <el-input v-model="form.materialName" placeholder="请输入物料名称" disabled/>
         </el-form-item>
         <el-form-item label="型号" prop="model">
-          <el-input v-model="form.model" placeholder="请输入型号" />
+          <el-input v-model="form.model" placeholder="请输入型号" disabled/>
         </el-form-item>
         <el-form-item label="规格" prop="specification">
-          <el-input v-model="form.specification" placeholder="请输入规格" />
+          <el-input v-model="form.specification" placeholder="请输入规格" disabled/>
         </el-form-item>
         <el-form-item label="库存数量" prop="stockQuantity">
           <el-input v-model="form.stockQuantity" placeholder="请输入库存数量" />
@@ -157,12 +320,46 @@
         <el-form-item label="备注" prop="remark">
           <el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
         </el-form-item>
-        <el-form-item label="操作人" prop="createById"   v-if="title=='添加半成品库存'">
-          <el-input v-model="form.createBy" placeholder="请输入创建人" />
+        <!--        <el-form-item label="操作人" prop="createById"   v-if="title=='添加半成品库存'">-->
+        <!--          <el-input v-model="form.createBy" placeholder="请输入创建人" />-->
+        <!--        </el-form-item>-->
+        <!--        <el-form-item label="修改人" prop="updateById" v-if="title=='修改半成品库存'">-->
+        <!--          <el-input v-model="form.updateById" placeholder="请输入修改人" />-->
+        <!--        </el-form-item>-->
+      </el-form>
+      <div slot="footer" class="dialog-footer">
+        <el-button type="primary" @click="submitFormout">确 定</el-button>
+        <el-button @click="cancelLcout">取 消</el-button>
+      </div>
+    </el-dialog>
+
+    <!-- 添加或修改半成品库存对话框 -->
+    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
+      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
+        <el-form-item label="物料编码" prop="materialCode">
+          <el-input v-model="form.materialCode" placeholder="请输入物料编码" disabled/>
         </el-form-item>
-        <el-form-item label="修改人" prop="updateById" v-if="title=='修改半成品库存'">
-          <el-input v-model="form.updateById" placeholder="请输入修改人" />
+        <el-form-item label="物料名称" prop="materialName">
+          <el-input v-model="form.materialName" placeholder="请输入物料名称" disabled/>
         </el-form-item>
+        <el-form-item label="型号" prop="model">
+          <el-input v-model="form.model" placeholder="请输入型号" disabled/>
+        </el-form-item>
+        <el-form-item label="规格" prop="specification">
+          <el-input v-model="form.specification" placeholder="请输入规格" disabled/>
+        </el-form-item>
+        <el-form-item label="库存数量" prop="stockQuantity">
+          <el-input v-model="form.stockQuantity" placeholder="请输入库存数量" />
+        </el-form-item>
+        <el-form-item label="备注" prop="remark">
+          <el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
+        </el-form-item>
+<!--        <el-form-item label="操作人" prop="createById"   v-if="title=='添加半成品库存'">-->
+<!--          <el-input v-model="form.createBy" placeholder="请输入创建人" />-->
+<!--        </el-form-item>-->
+<!--        <el-form-item label="修改人" prop="updateById" v-if="title=='修改半成品库存'">-->
+<!--          <el-input v-model="form.updateById" placeholder="请输入修改人" />-->
+<!--        </el-form-item>-->
       </el-form>
       <div slot="footer" class="dialog-footer">
         <el-button type="primary" @click="submitForm">确 定</el-button>
@@ -173,8 +370,16 @@
 </template>
 
 <script>
-import { listInventory, getInventory, delInventory, addInventory, updateInventory } from "@/api/amichi/indoor/inventory";
-
+import {
+  listInventory,
+  getInventory,
+  delInventory,
+  addInventory,
+  updateInventory,
+  inventoryout
+} from "@/api/amichi/indoor/inventory";
+import { listIndoorMaterial } from "@/api/amichi/indoor/material";
+import {stockInOrderAndOrderDetailLc} from "@/api/amichi/indoor/order";
 export default {
   name: "Inventory",
   data() {
@@ -197,6 +402,10 @@ export default {
       title: "",
       // 是否显示弹出层
       open: false,
+      // 出库弹窗
+      openLcout:false,
+      // 入库弹窗
+      openLc:false,
       // 查询参数
       queryParams: {
         pageNum: 1,
@@ -209,16 +418,38 @@ export default {
         createById: null,
         updateById: null,
       },
+      // 物料选项列表
+      materialOptions: [],
+      // 物料加载状态
+      materialLoading: false,
+      // 半成品入库单主表格数据
+      orderList: [],
+      // 查看明细开关
+      detailOpen: false,
+      // 明细表单
+      detailForm: {
+        orderNo: '',
+        createTime: '',
+        createBy: '',
+        remark: '',
+        detailList: []
+      },
       // 表单参数
-      form: {},
+      form: {
+        id: null,
+        orderNo: null,
+        remark: null,
+        createBy: null,
+        createById: null,
+        createTime: null,
+        updateBy: null,
+        updateById: null,
+        updateTime: null,
+        detailList: []
+      },
       // 表单校验
       rules: {
-        materialCode: [
-          { required: true, message: "物料编码不能为空", trigger: "blur" }
-        ],
-        materialName: [
-          { required: true, message: "物料名称不能为空", trigger: "blur" }
-        ],
+
         createBy: [
           { required: true, message: "不能为空", trigger: "blur" }
         ],
@@ -252,23 +483,31 @@ export default {
       this.open = false;
       this.reset();
     },
+    // 新的新增励磁取消按钮
+    cancelLc() {
+      this.openLc = false;
+      this.reset();
+    },
+    // 新的出库励磁取消按钮
+    cancelLcout() {
+      this.openLcout = false;
+      this.reset();
+    },
+
 
     // 表单重置
     reset() {
       this.form = {
         id: null,
-        materialCode: null,
-        materialName: null,
-        model: null,
-        specification: null,
-        stockQuantity: null,
+        orderNo: null,
         remark: null,
         createBy: null,
         createById: null,
         createTime: null,
         updateBy: null,
         updateById: null,
-        updateTime: null
+        updateTime: null,
+        detailList: []
       };
       this.resetForm("form");
     },
@@ -286,7 +525,10 @@ export default {
     handleCommand(command, row) {
       switch (command) {
         case "handleUpdate":
-          this.handleUpdate(row)
+          this.handleUpdatess(row)
+          break;
+        case "handleAddLcout":
+          this.handleAddLcout(row)
           break;
         case "handleDelete":
           this.handleDelete(row)
@@ -307,14 +549,202 @@ export default {
       this.open = true;
       this.title = "添加半成品库存";
     },
+
+    /** 新的励磁添加-新增按钮操作 */
+    handleAddLc() {
+      this.reset();
+      this.openLc = true;
+      this.title = "新增入库单";
+      // 生成入库单号 FORMAT: RK + 年月日时分秒
+      const now = new Date();
+      const year = now.getFullYear();
+      const month = String(now.getMonth() + 1).padStart(2, '0');
+      const day = String(now.getDate()).padStart(2, '0');
+      const hours = String(now.getHours()).padStart(2, '0');
+      const minutes = String(now.getMinutes()).padStart(2, '0');
+      const seconds = String(now.getSeconds()).padStart(2, '0');
+      this.form.orderNo = `RK${year}${month}${day}${hours}${minutes}${seconds}`;
+      this.form.createTime = now.toISOString().slice(0, 19).replace('T', ' ');
+      this.form.createBy = this.$store.getters.name; // 获取当前登录用户
+    },
+    /** 新的励磁添加-添加明细行 */
+    handleAddDetail() {
+      this.form.detailList.push({
+        materialCode: undefined,
+        excitationType: undefined,
+        materialName: '',
+        model: '',
+        specification: '',
+        inQuantity: 1
+      });
+    },
+    // 删除明细行
+    handleDeleteDetail(index) {
+      this.form.detailList.splice(index, 1);
+    },
+    /** 新的励磁添加-励磁类型改变事件 */
+    handleExcitationTypeChange(val, index) {
+      // 清空当前行的物料信息
+      this.form.detailList[index].materialCode = undefined;
+      this.form.detailList[index].materialName = '';
+      this.form.detailList[index].model = '';
+      this.form.detailList[index].specification = '';
+      // 重新获取对应类型的物料列表
+      this.getMaterialList('', val);
+    },
+
+    /** 新的励磁添加-获取物料列表 */
+    getMaterialList(query = '', excitationType = '') {
+      // 如果没有选择励磁类型且不是搜索操作,则不获取数据
+      if (!excitationType && !query) {
+        this.materialOptions = [];
+        return;
+      }
+
+      this.materialLoading = true;
+      listIndoorMaterial({
+        isEnablePaging: false,
+        materialName: query,
+        materialType: excitationType // 添加物料类型参数
+      }).then(response => {
+        console.log('物料数据:', response);
+
+        this.materialOptions = (response.data || response.rows || []).map(item => ({
+          id: item.id,
+          code: item.materialCode || item.code,
+          name: item.materialName || item.name,
+          model: item.model || item.specification,
+          specification: item.specification
+        }));
+
+        console.log('转换后的物料选项:', this.materialOptions);
+
+        this.materialLoading = false;
+      }).catch(() => {
+        this.materialLoading = false;
+      });
+    },
+    /** 新的励磁添加-物料选择改变事件 */
+    handleMaterialSearch(query) {
+      // 获取当前正在编辑的行的励磁类型
+      const currentExcitationType = this.form.detailList.find(item => !item.materialCode)?.excitationType;
+      if (query !== '') {
+        this.getMaterialList(query, currentExcitationType);
+      }
+    },
+    /** 新的励磁添加-物料选择改变事件 */
+    handleMaterialChange(materialCode, index) {
+      const selectedMaterial = this.materialOptions.find(item => item.code === materialCode);
+      if (selectedMaterial) {
+        // 确保更新materialId
+        this.form.detailList[index].materialCode = materialCode;
+        this.form.detailList[index].materialName = selectedMaterial.name;
+        this.form.detailList[index].model = selectedMaterial.model;
+        this.form.detailList[index].specification = selectedMaterial.specification;
+      } else {
+        this.form.detailList[index].materialCode = undefined;
+        this.form.detailList[index].materialName = '';
+        this.form.detailList[index].model = '';
+        this.form.detailList[index].specification = '';
+      }
+    },
+    /** 新的励磁添加-提交按钮 */
+    submitFormLc() {
+      console.log("-----------------",this.form.detailList)
+      this.$refs["form"].validate(async valid => {
+        console.log("-----------------")
+        if (valid) {
+          if (this.form.detailList.length === 0) {
+            this.$modal.msgError("请至少添加一条明细记录");
+            return;
+          }
+
+          // 检查明细数据
+          for (let i = 0; i < this.form.detailList.length; i++) {
+            const detail = this.form.detailList[i];
+            if (!detail.excitationType) {
+              this.$modal.msgError(`第${i + 1}行物料类型不能为空`);
+              return;
+            }
+            if (!detail.materialCode) {  // 修改验证字段
+              this.$modal.msgError(`第${i + 1}行物料信息不能为空`);
+              return;
+            }
+          }
+
+          if (this.form.id != null) {
+            updateOrder(this.form).then(response => {
+              this.$modal.msgSuccess("修改成功");
+              this.open = false;
+              this.getList();
+            });
+          } else {
+            // 构造提交数据
+            console.log("---------------------------------0000",this.form.detailList)
+            const submitData = {
+              orderNo: this.form.orderNo,
+              remark: this.form.remark,
+              createBy: this.form.createBy,
+              createTime: this.form.createTime,
+              orderDetailList: this.form.detailList.map(item => ({
+                materialCode: item.materialCode,
+                excitationType: item.excitationType,
+                materialName: item.materialName,
+                model: item.model,
+                specification: item.specification,
+                inQuantity: item.inQuantity
+              }))
+            };
+            console.log("-------+++++++++----------",submitData)
+            stockInOrderAndOrderDetailLc(submitData).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.openLc = false;
+              this.getList();
+            });
+          }
+        }
+      });
+    },
+    /** 出库 */
+    handleAddLcout(row) {
+      this.reset();
+      const id = row.id || this.ids
+      getInventory(id).then(response => {
+        this.form = response.data;
+        this.openLcout = true;
+        this.title = "出库";
+      });
+    },
     /** 修改按钮操作 */
-    handleUpdate(row) {
+    handleUpdatess(row) {
       this.reset();
       const id = row.id || this.ids
       getInventory(id).then(response => {
         this.form = response.data;
         this.open = true;
-        this.title = "修改半成品库存";
+        this.title = "修改";
+      });
+    },
+    /** 出库 */
+    submitFormout() {
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          if (this.form.id != null) {
+            inventoryout(this.form).then(response => {
+              this.$modal.msgSuccess("出库成功");
+              this.openLcout = false;
+              this.reset();
+              this.getList();
+            });
+          } else {
+            addInventory(this.form).then(response => {
+              this.$modal.msgSuccess("新增成功");
+              this.openLcout = false;
+              this.reset();
+              this.getList();
+            });
+          }
+        }
       });
     },
     /** 提交按钮 */
@@ -325,12 +755,14 @@ export default {
             updateInventory(this.form).then(response => {
               this.$modal.msgSuccess("修改成功");
               this.open = false;
+              this.reset();
               this.getList();
             });
           } else {
             addInventory(this.form).then(response => {
               this.$modal.msgSuccess("新增成功");
               this.open = false;
+              this.reset();
               this.getList();
             });
           }

+ 29 - 28
zkqy-ui/src/views/amichi/planTask/indoor/record/indexC.vue

@@ -42,32 +42,32 @@
         />
       </el-form-item>
 
-      <el-form-item label="单据号" prop="djh">
-        <el-input
-          v-model="queryParams.djh"
-          placeholder="请输入单据号"
-          clearable
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>
-      <el-form-item label="单据序号" prop="djIndex">
-        <el-input
-          v-model="queryParams.djIndex"
-          placeholder="请输入单据序号"
-          clearable
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>
+<!--      <el-form-item label="单据号" prop="djh">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.djh"-->
+<!--          placeholder="请输入单据号"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
+<!--      <el-form-item label="单据序号" prop="djIndex">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.djIndex"-->
+<!--          placeholder="请输入单据序号"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
 
 
-      <el-form-item label="操作人" prop="createBy">
-        <el-input
-          v-model="queryParams.createBy"
-          placeholder="请输入操作人ID"
-          clearable
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>
+<!--      <el-form-item label="操作人" prop="createBy">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.createBy"-->
+<!--          placeholder="请输入操作人ID"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
       <el-form-item>
         <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
         <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
@@ -119,8 +119,8 @@
       </el-col>
       <el-row >
       <el-radio-group v-model="queryParams.inboundType" style="margin-bottom: 30px;float: right"  @change="getList" >
-        <el-radio-button label="扫码出库">扫码出库</el-radio-button>
-        <el-radio-button label="手动出库">手动出库</el-radio-button>
+<!--        <el-radio-button label="扫码出库">扫码出库</el-radio-button>-->
+<!--        <el-radio-button label="手动出库">手动出库</el-radio-button>-->
       </el-radio-group>
       </el-row>
       <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
@@ -130,7 +130,7 @@
       <el-table-column type="selection" width="55" align="center" />
       <!--<el-table-column label="主键ID" align="center" prop="id" />-->
       <!--<el-table-column label="关联库存ID" align="center" prop="inventoryId" />-->
-      <el-table-column label="出库单编号" align="center" prop="rkdbh" v-if="queryParams.inboundType == '手动出库'" />
+<!--      <el-table-column label="出库单编号" align="center" prop="rkdbh" v-if="queryParams.inboundType == '手动出库'" />-->
       <el-table-column label="物料编码" align="center" prop="materialCode" />
       <el-table-column label="物料名称" align="center" prop="materialName" />
       <el-table-column label="型号" align="center" prop="model" />
@@ -142,6 +142,7 @@
       <el-table-column label="单据序号" align="center" prop="djIndex" v-if="queryParams.inboundType == '扫码出库'" />
       <el-table-column label="一托盘数量" align="center" prop="ytps" v-if="queryParams.inboundType == '扫码出库'" />
       <el-table-column label="一共几个托盘" align="center" prop="tps" v-if="queryParams.inboundType == '扫码出库'" />
+      <el-table-column label="出库时间" align="center" prop="createTime" />
       <el-table-column label="备注" align="center" prop="remark" />
       <el-table-column label="创建人" align="center" prop="createBy" />
       <!--<el-table-column label="操作人ID" align="center" prop="updateBy" />-->
@@ -252,7 +253,7 @@ export default {
         tps: null,
         createById: null,
         updateById: null,
-        inboundType:"扫码出库"
+        inboundType:"手动出库"
       },
       // 表单参数
       form: {},

+ 34 - 33
zkqy-ui/src/views/amichi/planTask/indoor/record/indexR.vue

@@ -35,38 +35,38 @@
         />
       </el-form-item>
 
-      <el-form-item label="操作人" prop="operator">
-        <el-input
-          v-model="queryParams.operator"
-          placeholder="请输入操作人"
-          clearable
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>
-      <el-form-item label="单据号" prop="djh">
-        <el-input
-          v-model="queryParams.djh"
-          placeholder="请输入单据号"
-          clearable
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>
-      <el-form-item label="单据序号" prop="djIndex">
-        <el-input
-          v-model="queryParams.djIndex"
-          placeholder="请输入单据序号"
-          clearable
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>
-      <el-form-item label="操作人" prop="createBy">
-        <el-input
-          v-model="queryParams.createBy"
-          placeholder="请输入操作人ID"
-          clearable
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>
+<!--      <el-form-item label="操作人" prop="operator">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.operator"-->
+<!--          placeholder="请输入操作人"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
+<!--      <el-form-item label="单据号" prop="djh">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.djh"-->
+<!--          placeholder="请输入单据号"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
+<!--      <el-form-item label="单据序号" prop="djIndex">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.djIndex"-->
+<!--          placeholder="请输入单据序号"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
+<!--      <el-form-item label="操作人" prop="createBy">-->
+<!--        <el-input-->
+<!--          v-model="queryParams.createBy"-->
+<!--          placeholder="请输入操作人ID"-->
+<!--          clearable-->
+<!--          @keyup.enter.native="handleQuery"-->
+<!--        />-->
+<!--      </el-form-item>-->
 
       <el-form-item>
         <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
@@ -129,7 +129,7 @@
     <el-table v-loading="loading" :data="recordList" style="margin-top: 20px" @selection-change="handleSelectionChange">
       <el-table-column type="selection" width="55" align="center" />
       <!--<el-table-column label="主键ID" align="center" prop="id" />-->
-      <el-table-column label="入库单编号" align="center" prop="rkdbh" v-if="queryParams.inboundType == '手动入库'" />
+<!--      <el-table-column label="入库单编号" align="center" prop="rkdbh" v-if="queryParams.inboundType == '手动入库'" />-->
       <el-table-column label="物料编码" align="center" prop="materialCode" />
       <el-table-column label="物料名称" align="center" prop="materialName" />
       <el-table-column label="型号" align="center" prop="model" />
@@ -142,6 +142,7 @@
       <el-table-column label="一托盘数量" align="center" prop="ytps" v-if="queryParams.inboundType == '扫码入库'" />
       <el-table-column label="一共几个托盘" align="center" prop="tps" v-if="queryParams.inboundType == '扫码入库'" />
       <el-table-column label="入库类型" align="center" prop="inboundType" />
+      <el-table-column label="入库时间" align="center" prop="createTime" />
       <el-table-column label="备注" align="center" prop="remark" />
       <el-table-column label="创建人" align="center" prop="createBy" />
       <!--<el-table-column label="修改人" align="center" prop="updateBy" />-->