入库部分和接口
This commit is contained in:
@@ -41,4 +41,8 @@ public class DeliveryNoticeItemVo {
|
|||||||
private String quantity;
|
private String quantity;
|
||||||
/** 备注 */
|
/** 备注 */
|
||||||
private String remark;
|
private String remark;
|
||||||
|
|
||||||
|
private String area;
|
||||||
|
|
||||||
|
private String location;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,7 +12,9 @@ import com.ruoyi.in.erp.domain.TransferBillCallback;
|
|||||||
import com.ruoyi.in.erp.service.ITransferBillCallbackService;
|
import com.ruoyi.in.erp.service.ITransferBillCallbackService;
|
||||||
import com.ruoyi.in.stockin.domain.InStockin;
|
import com.ruoyi.in.stockin.domain.InStockin;
|
||||||
import com.ruoyi.in.stockin.service.IInStockinService;
|
import com.ruoyi.in.stockin.service.IInStockinService;
|
||||||
|
import com.ruoyi.in.stockinback.domain.InStockinBack;
|
||||||
import com.ruoyi.in.stockinback.service.IInStockinBackService;
|
import com.ruoyi.in.stockinback.service.IInStockinBackService;
|
||||||
|
import com.ruoyi.in.stockindeatilback.domain.InStockinDetailBack;
|
||||||
import com.ruoyi.in.stockindeatilback.service.IInStockinDetailBackService;
|
import com.ruoyi.in.stockindeatilback.service.IInStockinDetailBackService;
|
||||||
import com.ruoyi.in.stockindetail.domain.InStockinDetail;
|
import com.ruoyi.in.stockindetail.domain.InStockinDetail;
|
||||||
import com.ruoyi.in.stockindetail.service.IInStockinDetailService;
|
import com.ruoyi.in.stockindetail.service.IInStockinDetailService;
|
||||||
@@ -300,11 +302,8 @@ public class ToErpServiceImpl implements IToErpService {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void callbackInDeliveryNotice() {
|
public void callbackInDeliveryNotice() {
|
||||||
InStockin inStockin = null;
|
|
||||||
|
|
||||||
// inStockin = inStockinService.selectInStockinByStockinId(billNo);
|
InStockinBack inStockin = inStockinBackService.selectTopInStockin();
|
||||||
|
|
||||||
String billNo="";
|
|
||||||
DeliveryNoticeVo deliveryNoticeVo = new DeliveryNoticeVo();
|
DeliveryNoticeVo deliveryNoticeVo = new DeliveryNoticeVo();
|
||||||
deliveryNoticeVo.setBillNo(inStockin.getStockinId());
|
deliveryNoticeVo.setBillNo(inStockin.getStockinId());
|
||||||
deliveryNoticeVo.setNoteBillNo(inStockin.getStockinId());
|
deliveryNoticeVo.setNoteBillNo(inStockin.getStockinId());
|
||||||
@@ -321,13 +320,13 @@ public class ToErpServiceImpl implements IToErpService {
|
|||||||
deliveryNoticeVo.setApproveMan(inStockin.getSpare4());
|
deliveryNoticeVo.setApproveMan(inStockin.getSpare4());
|
||||||
deliveryNoticeVo.setRemark(inStockin.getSpare5());
|
deliveryNoticeVo.setRemark(inStockin.getSpare5());
|
||||||
|
|
||||||
InStockinDetail inStockinDetailParam = new InStockinDetail();
|
InStockinDetailBack inStockinDetailParam = new InStockinDetailBack();
|
||||||
inStockinDetailParam.setStockinId(billNo);
|
inStockinDetailParam.setStockinId(inStockin.getStockinId());
|
||||||
List<InStockinDetail> inStockinDetails = inStockinDetailService.selectInStockinDetailList(inStockinDetailParam);
|
List<InStockinDetailBack> inStockinDetails = inStockinDetailBackService.selectInStockinDetailBackList(inStockinDetailParam);
|
||||||
|
|
||||||
List<DeliveryNoticeItemVo> detailList = new ArrayList<>();
|
List<DeliveryNoticeItemVo> detailList = new ArrayList<>();
|
||||||
if (inStockinDetails != null && !inStockinDetails.isEmpty()) {
|
if (inStockinDetails != null && !inStockinDetails.isEmpty()) {
|
||||||
for (InStockinDetail detail : inStockinDetails) {
|
for (InStockinDetailBack detail : inStockinDetails) {
|
||||||
DeliveryNoticeItemVo item = new DeliveryNoticeItemVo();
|
DeliveryNoticeItemVo item = new DeliveryNoticeItemVo();
|
||||||
item.setLineNo(detail.getStockinDetailId());
|
item.setLineNo(detail.getStockinDetailId());
|
||||||
item.setNotelineNo(detail.getStockinDetailId());
|
item.setNotelineNo(detail.getStockinDetailId());
|
||||||
@@ -342,11 +341,15 @@ public class ToErpServiceImpl implements IToErpService {
|
|||||||
item.setUpperMaterial(detail.getSpare2());
|
item.setUpperMaterial(detail.getSpare2());
|
||||||
item.setTopMaterial(detail.getSpare3());
|
item.setTopMaterial(detail.getSpare3());
|
||||||
item.setRemark(detail.getRemark());
|
item.setRemark(detail.getRemark());
|
||||||
|
item.setArea(detail.getSpare9());
|
||||||
|
item.setLocation(detail.getSpare8());
|
||||||
detailList.add(item);
|
detailList.add(item);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
deliveryNoticeVo.setDetailList(detailList);
|
deliveryNoticeVo.setDetailList(detailList);
|
||||||
|
|
||||||
|
//todo 发送给erp 成功失败改状态
|
||||||
|
|
||||||
// return AjaxResult.success(deliveryNoticeVo);
|
// return AjaxResult.success(deliveryNoticeVo);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -17,6 +17,7 @@ import com.ruoyi.in.stockin.service.IInStockinService;
|
|||||||
import com.ruoyi.in.stockinback.domain.InStockinBack;
|
import com.ruoyi.in.stockinback.domain.InStockinBack;
|
||||||
import com.ruoyi.in.stockinback.mapper.InStockinBackMapper;
|
import com.ruoyi.in.stockinback.mapper.InStockinBackMapper;
|
||||||
import com.ruoyi.in.stockinback.service.IInStockinBackService;
|
import com.ruoyi.in.stockinback.service.IInStockinBackService;
|
||||||
|
import com.ruoyi.in.stockindeatilback.domain.InStockinDetailBack;
|
||||||
import com.ruoyi.in.stockindeatilback.mapper.InStockinDetailBackMapper;
|
import com.ruoyi.in.stockindeatilback.mapper.InStockinDetailBackMapper;
|
||||||
import com.ruoyi.in.stockindeatilback.service.IInStockinDetailBackService;
|
import com.ruoyi.in.stockindeatilback.service.IInStockinDetailBackService;
|
||||||
import com.ruoyi.in.stockindetail.domain.InStockinDetail;
|
import com.ruoyi.in.stockindetail.domain.InStockinDetail;
|
||||||
@@ -209,9 +210,20 @@ public class InStockinServiceImpl implements IInStockinService
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void insertInStockinBack(InStockin inStockin){
|
private void insertInStockinBack(InStockin inStockin){
|
||||||
|
InStockin inStockin1 = selectInStockinByStockinGuid(inStockin.getStockinGuid());
|
||||||
inStockinBackMapper.insertInStockinBackById(inStockin);
|
InStockinBack inStockinBack = new InStockinBack();
|
||||||
inStockinDetailBackMapper.insertInStockinDetailBackById(inStockin);
|
BeanUtil.copyProperties(inStockin1,inStockinBack);
|
||||||
|
inStockinBack.setSendStatus("0");
|
||||||
|
inStockinBackMapper.insertInStockinBack(inStockinBack);
|
||||||
|
InStockinDetail inStockinDetail = new InStockinDetail();
|
||||||
|
inStockinDetail.setStockinId(inStockin1.getStockinId());
|
||||||
|
List<InStockinDetail> inStockinDetails = iInStockinDetailService.selectInStockinDetailList(inStockinDetail);
|
||||||
|
for(InStockinDetail inStockinDetail1:inStockinDetails){
|
||||||
|
InStockinDetailBack inStockinDetailBack = new InStockinDetailBack();
|
||||||
|
BeanUtil.copyProperties(inStockinDetail1,inStockinDetailBack);
|
||||||
|
inStockinDetailBack.setSendStatus("0");
|
||||||
|
inStockinDetailBackMapper.insertInStockinDetailBack(inStockinDetailBack);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -90,7 +90,37 @@ public class InStockinBack extends BaseEntity
|
|||||||
@Excel(name = "供应商编码546")
|
@Excel(name = "供应商编码546")
|
||||||
private String supplierNo;
|
private String supplierNo;
|
||||||
|
|
||||||
public void setStockinGuid(String stockinGuid)
|
private String sendStatus;
|
||||||
|
|
||||||
|
private String sendTime;
|
||||||
|
|
||||||
|
private String msg;
|
||||||
|
|
||||||
|
public String getSendStatus() {
|
||||||
|
return sendStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSendStatus(String sendStatus) {
|
||||||
|
this.sendStatus = sendStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSendTime() {
|
||||||
|
return sendTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSendTime(String sendTime) {
|
||||||
|
this.sendTime = sendTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getMsg() {
|
||||||
|
return msg;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMsg(String msg) {
|
||||||
|
this.msg = msg;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setStockinGuid(String stockinGuid)
|
||||||
{
|
{
|
||||||
this.stockinGuid = stockinGuid;
|
this.stockinGuid = stockinGuid;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -62,4 +62,7 @@ public interface InStockinBackMapper
|
|||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
public int deleteInStockinBackByStockinGuids(String[] stockinGuids);
|
public int deleteInStockinBackByStockinGuids(String[] stockinGuids);
|
||||||
|
|
||||||
|
|
||||||
|
public InStockinBack selectTopInStockin();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -58,4 +58,6 @@ public interface IInStockinBackService
|
|||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
public int deleteInStockinBackByStockinGuid(String stockinGuid);
|
public int deleteInStockinBackByStockinGuid(String stockinGuid);
|
||||||
|
|
||||||
|
public InStockinBack selectTopInStockin();
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -90,4 +90,9 @@ public class InStockinBackServiceImpl implements IInStockinBackService
|
|||||||
{
|
{
|
||||||
return inStockinBackMapper.deleteInStockinBackByStockinGuid(stockinGuid);
|
return inStockinBackMapper.deleteInStockinBackByStockinGuid(stockinGuid);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public InStockinBack selectTopInStockin() {
|
||||||
|
return inStockinBackMapper.selectTopInStockin();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -146,7 +146,37 @@ public class InStockinDetailBack extends BaseEntity
|
|||||||
@Excel(name = "物料名称546")
|
@Excel(name = "物料名称546")
|
||||||
private String productName;
|
private String productName;
|
||||||
|
|
||||||
public void setStockinDetailId(String stockinDetailId)
|
private String sendStatus;
|
||||||
|
|
||||||
|
private String sendTime;
|
||||||
|
|
||||||
|
private String msg;
|
||||||
|
|
||||||
|
public String getSendStatus() {
|
||||||
|
return sendStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSendStatus(String sendStatus) {
|
||||||
|
this.sendStatus = sendStatus;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getSendTime() {
|
||||||
|
return sendTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setSendTime(String sendTime) {
|
||||||
|
this.sendTime = sendTime;
|
||||||
|
}
|
||||||
|
|
||||||
|
public String getMsg() {
|
||||||
|
return msg;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setMsg(String msg) {
|
||||||
|
this.msg = msg;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setStockinDetailId(String stockinDetailId)
|
||||||
{
|
{
|
||||||
this.stockinDetailId = stockinDetailId;
|
this.stockinDetailId = stockinDetailId;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -24,10 +24,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<result property="customerNo" column="customer_no" />
|
<result property="customerNo" column="customer_no" />
|
||||||
<result property="classNo" column="class_no" />
|
<result property="classNo" column="class_no" />
|
||||||
<result property="supplierNo" column="supplier_no" />
|
<result property="supplierNo" column="supplier_no" />
|
||||||
|
<result property="sendStatus" column="send_status"/>
|
||||||
|
<result property="sendTime" column="send_time"/>
|
||||||
|
<result property="msg" column="msg"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectInStockinBackVo">
|
<sql id="selectInStockinBackVo">
|
||||||
select stockin_guid, stockin_id, in_type, create_date, create_man_id, status, warehouse_id, spare5, spare4, spare3, finish_date, spare2, spare1, erp_bill, stock_source, department_no, customer_no, class_no, supplier_no from in_stockin_back
|
select stockin_guid, stockin_id, in_type, create_date, create_man_id, status, warehouse_id,
|
||||||
|
spare5, spare4, spare3, finish_date, spare2, spare1, erp_bill, stock_source, department_no,
|
||||||
|
customer_no, class_no, supplier_no,send_status,send_time,msg from in_stockin_back
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectInStockinBackList" parameterType="InStockinBack" resultMap="InStockinBackResult">
|
<select id="selectInStockinBackList" parameterType="InStockinBack" resultMap="InStockinBackResult">
|
||||||
@@ -51,6 +56,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="customerNo != null and customerNo != ''"> and customer_no = #{customerNo}</if>
|
<if test="customerNo != null and customerNo != ''"> and customer_no = #{customerNo}</if>
|
||||||
<if test="classNo != null and classNo != ''"> and class_no = #{classNo}</if>
|
<if test="classNo != null and classNo != ''"> and class_no = #{classNo}</if>
|
||||||
<if test="supplierNo != null and supplierNo != ''"> and supplier_no = #{supplierNo}</if>
|
<if test="supplierNo != null and supplierNo != ''"> and supplier_no = #{supplierNo}</if>
|
||||||
|
<if test="sendStatus != null and sendStatus != ''"> and send_status = #{sendStatus}</if>
|
||||||
|
<if test="sendTime != null and sendTime != ''"> and send_time = #{sendTime}</if>
|
||||||
|
<if test="msg != null and msg != ''"> and msg = #{msg}</if>
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
@@ -81,6 +89,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="customerNo != null">customer_no,</if>
|
<if test="customerNo != null">customer_no,</if>
|
||||||
<if test="classNo != null">class_no,</if>
|
<if test="classNo != null">class_no,</if>
|
||||||
<if test="supplierNo != null">supplier_no,</if>
|
<if test="supplierNo != null">supplier_no,</if>
|
||||||
|
<if test="sendStatus != null">send_status,</if>
|
||||||
|
<if test="sendTime != null">send_time,</if>
|
||||||
|
<if test="msg != null">msg,</if>
|
||||||
</trim>
|
</trim>
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
<if test="stockinGuid != null">#{stockinGuid},</if>
|
<if test="stockinGuid != null">#{stockinGuid},</if>
|
||||||
@@ -102,6 +113,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="customerNo != null">#{customerNo},</if>
|
<if test="customerNo != null">#{customerNo},</if>
|
||||||
<if test="classNo != null">#{classNo},</if>
|
<if test="classNo != null">#{classNo},</if>
|
||||||
<if test="supplierNo != null">#{supplierNo},</if>
|
<if test="supplierNo != null">#{supplierNo},</if>
|
||||||
|
<if test="sendStatus != null">#{sendStatus},</if>
|
||||||
|
<if test="sendTime != null">#{sendTime},</if>
|
||||||
|
<if test="msg != null">#{msg},</if>
|
||||||
</trim>
|
</trim>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@@ -131,6 +145,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="customerNo != null">customer_no = #{customerNo},</if>
|
<if test="customerNo != null">customer_no = #{customerNo},</if>
|
||||||
<if test="classNo != null">class_no = #{classNo},</if>
|
<if test="classNo != null">class_no = #{classNo},</if>
|
||||||
<if test="supplierNo != null">supplier_no = #{supplierNo},</if>
|
<if test="supplierNo != null">supplier_no = #{supplierNo},</if>
|
||||||
|
<if test="sendStatus != null">send_status = #{sendStatus},</if>
|
||||||
|
<if test="senTime != null">send_time = #{senTime},</if>
|
||||||
|
<if test="msg != null">msg = #{msg},</if>
|
||||||
</trim>
|
</trim>
|
||||||
where stockin_guid = #{stockinGuid}
|
where stockin_guid = #{stockinGuid}
|
||||||
</update>
|
</update>
|
||||||
@@ -145,4 +162,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
#{stockinGuid}
|
#{stockinGuid}
|
||||||
</foreach>
|
</foreach>
|
||||||
</delete>
|
</delete>
|
||||||
|
|
||||||
|
<select id="selectTopInStockin" resultMap="InStockinBackResult">
|
||||||
|
select top(1) *
|
||||||
|
from in_stockin_back where status= 0
|
||||||
|
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
@@ -39,10 +39,16 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<result property="spare8" column="spare8" />
|
<result property="spare8" column="spare8" />
|
||||||
<result property="spare9" column="spare9" />
|
<result property="spare9" column="spare9" />
|
||||||
<result property="productName" column="product_name" />
|
<result property="productName" column="product_name" />
|
||||||
|
<result property="sendStatus" column="send_status"/>
|
||||||
|
<result property="sendTime" column="send_time"/>
|
||||||
|
<result property="msg" column="msg"/>
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectInStockinDetailBackVo">
|
<sql id="selectInStockinDetailBackVo">
|
||||||
select stockin_detail_id, stockin_guid, stockin_id, lot_no, product_guid, product_id, quantity, quantity_x, quantity_j, price, cargo_no, remark, assign_num, assign_num_x, assign_num_j, print_date, stock_status, supplier_id, customer_id, unit, spec, spare1, spare2, spare3, spare4, spare5, spare6, scan_num, scan_num_x, scan_num_j, spare7, spare8, spare9, product_name from in_stockin_detail_back
|
select stockin_detail_id, stockin_guid, stockin_id, lot_no, product_guid, product_id, quantity,
|
||||||
|
quantity_x, quantity_j, price, cargo_no, remark, assign_num, assign_num_x, assign_num_j,
|
||||||
|
print_date, stock_status, supplier_id, customer_id, unit, spec, spare1, spare2, spare3,
|
||||||
|
spare4, spare5, spare6, scan_num, scan_num_x, scan_num_j, spare7, spare8, spare9, product_name,send_status,send_time,msg from in_stockin_detail_back
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectInStockinDetailBackList" parameterType="InStockinDetailBack" resultMap="InStockinDetailBackResult">
|
<select id="selectInStockinDetailBackList" parameterType="InStockinDetailBack" resultMap="InStockinDetailBackResult">
|
||||||
@@ -80,6 +86,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="spare8 != null and spare8 != ''"> and spare8 = #{spare8}</if>
|
<if test="spare8 != null and spare8 != ''"> and spare8 = #{spare8}</if>
|
||||||
<if test="spare9 != null and spare9 != ''"> and spare9 = #{spare9}</if>
|
<if test="spare9 != null and spare9 != ''"> and spare9 = #{spare9}</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="sendStatus != null and sendStatus != ''"> and send_status = #{sendStatus}</if>
|
||||||
|
<if test="sendTime != null and sendTime != ''"> and send_time = #{sendTime}</if>
|
||||||
|
<if test="msg != null and msg != ''"> and msg = #{msg}</if>
|
||||||
</where>
|
</where>
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
@@ -125,6 +134,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="spare8 != null">spare8,</if>
|
<if test="spare8 != null">spare8,</if>
|
||||||
<if test="spare9 != null">spare9,</if>
|
<if test="spare9 != null">spare9,</if>
|
||||||
<if test="productName != null">product_name,</if>
|
<if test="productName != null">product_name,</if>
|
||||||
|
<if test="sendStatus != null">send_status,</if>
|
||||||
|
<if test="sendTime != null">send_time,</if>
|
||||||
|
<if test="msg != null">msg,</if>
|
||||||
</trim>
|
</trim>
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
<if test="stockinDetailId != null">#{stockinDetailId},</if>
|
<if test="stockinDetailId != null">#{stockinDetailId},</if>
|
||||||
@@ -161,6 +173,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="spare8 != null">#{spare8},</if>
|
<if test="spare8 != null">#{spare8},</if>
|
||||||
<if test="spare9 != null">#{spare9},</if>
|
<if test="spare9 != null">#{spare9},</if>
|
||||||
<if test="productName != null">#{productName},</if>
|
<if test="productName != null">#{productName},</if>
|
||||||
|
<if test="sendStatus != null">#{sendStatus},</if>
|
||||||
|
<if test="sendTime != null">#{sendTime},</if>
|
||||||
|
<if test="msg != null">#{msg},</if>
|
||||||
</trim>
|
</trim>
|
||||||
</insert>
|
</insert>
|
||||||
|
|
||||||
@@ -206,6 +221,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|||||||
<if test="spare8 != null">spare8 = #{spare8},</if>
|
<if test="spare8 != null">spare8 = #{spare8},</if>
|
||||||
<if test="spare9 != null">spare9 = #{spare9},</if>
|
<if test="spare9 != null">spare9 = #{spare9},</if>
|
||||||
<if test="productName != null">product_name = #{productName},</if>
|
<if test="productName != null">product_name = #{productName},</if>
|
||||||
|
<if test="sendStatus != null">send_status = #{sendStatus},</if>
|
||||||
|
<if test="senTime != null">send_time = #{senTime},</if>
|
||||||
|
<if test="msg != null">msg = #{msg},</if>
|
||||||
</trim>
|
</trim>
|
||||||
where stockin_detail_id = #{stockinDetailId}
|
where stockin_detail_id = #{stockinDetailId}
|
||||||
</update>
|
</update>
|
||||||
|
|||||||
@@ -19,9 +19,9 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-col>
|
</el-col>
|
||||||
<el-col :span="4">
|
<el-col :span="4">
|
||||||
<el-form-item label="供应商" prop="supplierId">
|
<el-form-item label="供应商" prop="classNo">
|
||||||
<el-input
|
<el-input
|
||||||
v-model="form.supplierName"
|
v-model="form.classNo"
|
||||||
placeholder="请选择供应商"
|
placeholder="请选择供应商"
|
||||||
@click.native="openSupplierSelector"
|
@click.native="openSupplierSelector"
|
||||||
readonly
|
readonly
|
||||||
@@ -73,11 +73,40 @@
|
|||||||
<!-- <el-table-column label="主键" align="center" prop="productGuid" />-->
|
<!-- <el-table-column label="主键" align="center" prop="productGuid" />-->
|
||||||
<el-table-column fixed label="存货编码" align="left" prop="productId" />
|
<el-table-column fixed label="存货编码" align="left" prop="productId" />
|
||||||
<el-table-column fixed label="存货名称" align="left" prop="productName" />
|
<el-table-column fixed label="存货名称" align="left" prop="productName" />
|
||||||
<el-table-column fixed label="单位" align="left" prop="unit" />
|
|
||||||
<el-table-column fixed label="规格型号" align="left" prop="spec" />
|
<el-table-column fixed label="规格型号" align="left" prop="spec" />
|
||||||
<el-table-column fixed label="层级关系" align="left" prop="spare1" />
|
<el-table-column fixed label="单位" align="left" >
|
||||||
<el-table-column fixed label="上层物料" align="left" prop="spare2" />
|
<template slot-scope="scope">
|
||||||
<el-table-column fixed label="顶层物料" align="left" prop="spare3" />
|
<el-input
|
||||||
|
v-model="scope.row.unit"
|
||||||
|
controls-position="right"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column fixed label="规格型号" align="left" prop="spec" />
|
||||||
|
<el-table-column fixed label="层级关系" align="left" >
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-input
|
||||||
|
v-model="scope.row.spare1"
|
||||||
|
controls-position="right"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column fixed label="上层物料" align="left" >
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-input
|
||||||
|
v-model="scope.row.spare2"
|
||||||
|
controls-position="right"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="顶层物料" align="left" >
|
||||||
|
<template slot-scope="scope">
|
||||||
|
<el-input
|
||||||
|
v-model="scope.row.spare3"
|
||||||
|
controls-position="right"
|
||||||
|
/>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column label="数量" width="120" align="left">
|
<el-table-column label="数量" width="120" align="left">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-input-number
|
<el-input-number
|
||||||
@@ -92,7 +121,7 @@
|
|||||||
<el-input
|
<el-input
|
||||||
v-model="scope.row.lotNo"
|
v-model="scope.row.lotNo"
|
||||||
controls-position="right"
|
controls-position="right"
|
||||||
required="required"/>
|
/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<!-- <el-table-column label="单位" width="120" align="right">-->
|
<!-- <el-table-column label="单位" width="120" align="right">-->
|
||||||
@@ -554,24 +583,24 @@ export default {
|
|||||||
const newProducts = this.selectedProducts.map(item => ({
|
const newProducts = this.selectedProducts.map(item => ({
|
||||||
productGuid: item.productGuid,
|
productGuid: item.productGuid,
|
||||||
productId: item.productId,
|
productId: item.productId,
|
||||||
parentId: item.parentId,
|
// parentId: item.parentId,
|
||||||
price: item.price,
|
// price: item.price,
|
||||||
cargoNo: item.cargoNo,
|
// cargoNo: item.cargoNo,
|
||||||
unit: "",
|
// unit: "",
|
||||||
spec: item.spec,
|
spec: item.spec,
|
||||||
remark: item.remark,
|
// remark: item.remark,
|
||||||
productName: item.productName,
|
productName: item.productName,
|
||||||
quantity: 1,
|
// quantity: 1,
|
||||||
spare1: item.spare1,
|
// spare1: item.spare1,
|
||||||
spare2: item.spare2,
|
// spare2: item.spare2,
|
||||||
spare3: item.spare3,
|
// spare3: item.spare3,
|
||||||
spare4: item.spare4,
|
// spare4: item.spare4,
|
||||||
spare5: item.spare5,
|
// spare5: item.spare5,
|
||||||
spare6: item.spare6,
|
// spare6: item.spare6,
|
||||||
spare7: item.spare7,
|
// spare7: item.spare7,
|
||||||
spare8: item.spare8,
|
// spare8: item.spare8,
|
||||||
spare9:"",
|
// spare9:"",
|
||||||
lotNo:"",
|
// lotNo:"",
|
||||||
|
|
||||||
}));
|
}));
|
||||||
this.productList.push(...newProducts);
|
this.productList.push(...newProducts);
|
||||||
@@ -618,59 +647,60 @@ export default {
|
|||||||
for (let i = 0; i < this.productList.length; i++) {
|
for (let i = 0; i < this.productList.length; i++) {
|
||||||
const item = this.productList[i];
|
const item = this.productList[i];
|
||||||
if (!item.spare1) {
|
if (!item.spare1) {
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的型号未填写`);
|
this.$modal.msgError(`品号 ${item.productId} 的层级关系未填写`);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (!item.spare2) {
|
if (!item.spare2) {
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的净重未填写`);
|
this.$modal.msgError(`品号 ${item.productId} 的上层物料未填写`);
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.spare3) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的颜色未填写`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.spare4) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的序列号未填写`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.spare5) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的电压未填写`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.spare6) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的功率未填写`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.spare7) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的相位未填写`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.spare8) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的毛重未填写`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.quantity) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的数量未填写`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.lotNo) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的批次号未填写`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.unit) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的机型未填写`);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (!item.spare9) {
|
|
||||||
this.$modal.msgError(`品号 ${item.productId} 的分销未填写`);
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
// if (!item.spare3) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的颜色未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// if (!item.spare4) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的序列号未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// if (!item.spare5) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的电压未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// if (!item.spare6) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的功率未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// if (!item.spare7) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的相位未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// if (!item.spare8) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的毛重未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// if (!item.quantity) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的数量未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// if (!item.lotNo) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的批次号未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// if (!item.unit) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的机型未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
|
// if (!item.spare9) {
|
||||||
|
// this.$modal.msgError(`品号 ${item.productId} 的分销未填写`);
|
||||||
|
// return;
|
||||||
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
// 构建请求数据
|
// 构建请求数据
|
||||||
const data = {
|
const data = {
|
||||||
warehouseId: "01",
|
warehouseId: "01",
|
||||||
supplierId: this.form.supplierId,
|
supplierId: this.form.supplierId,
|
||||||
|
classNo:this.classNo,
|
||||||
remark: this.form.remark,
|
remark: this.form.remark,
|
||||||
inType:this.form.inType,
|
inType:this.form.inType,
|
||||||
erpBill:this.form.erpBill,
|
erpBill:this.form.erpBill,
|
||||||
@@ -686,12 +716,12 @@ export default {
|
|||||||
spare1: item.spare1,
|
spare1: item.spare1,
|
||||||
spare2: item.spare2,
|
spare2: item.spare2,
|
||||||
spare3: item.spare3,
|
spare3: item.spare3,
|
||||||
spare4: item.spare4,
|
// spare4: item.spare4,
|
||||||
spare5: item.spare5,
|
// spare5: item.spare5,
|
||||||
spare6: item.spare6,
|
// spare6: item.spare6,
|
||||||
spare7: item.spare7,
|
// spare7: item.spare7,
|
||||||
spare8: item.spare8,
|
// spare8: item.spare8,
|
||||||
spare9: item.spare9,
|
// spare9: item.spare9,
|
||||||
unit:item.unit,
|
unit:item.unit,
|
||||||
productName: item.productName
|
productName: item.productName
|
||||||
}))
|
}))
|
||||||
|
|||||||
@@ -267,7 +267,7 @@ import VueQr from 'vue-qr'
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "StockIn",
|
name: "StockIn",
|
||||||
dicts: ['bill_resource', 'in_bill_status', 'in_bill_type', 'bill_resource'],
|
dicts: ['bill_resource', 'in_bill_status', 'in_bill_type'],
|
||||||
components: {
|
components: {
|
||||||
vueEasyPrint,
|
vueEasyPrint,
|
||||||
VueQr
|
VueQr
|
||||||
|
|||||||
Reference in New Issue
Block a user