pms出库单表添加记录号作为主键;添加任务状态赋值
This commit is contained in:
parent
f67563e0d2
commit
e2ac149376
|
|
@ -115,12 +115,14 @@ public class AppPmsController extends BaseController {
|
||||||
return error("出库单号重复。");
|
return error("出库单号重复。");
|
||||||
}
|
}
|
||||||
AppPmsOrderOut appPmsOrderOut = new AppPmsOrderOut();
|
AppPmsOrderOut appPmsOrderOut = new AppPmsOrderOut();
|
||||||
|
appPmsOrderOut.setRecordId(UUID.randomUUID().toString());
|
||||||
appPmsOrderOut.setListId(orderOutRequest.getListId());
|
appPmsOrderOut.setListId(orderOutRequest.getListId());
|
||||||
appPmsOrderOut.setOrderType(Long.valueOf(orderOutRequest.getOrderType()));
|
appPmsOrderOut.setOrderType(Long.valueOf(orderOutRequest.getOrderType()));
|
||||||
appPmsOrderOut.setCustomerId(orderOutRequest.getCustomerId());
|
appPmsOrderOut.setCustomerId(orderOutRequest.getCustomerId());
|
||||||
appPmsOrderOut.setGoodsId(orderOutRequest.getGoodsId());
|
appPmsOrderOut.setGoodsId(orderOutRequest.getGoodsId());
|
||||||
appPmsOrderOut.setGoodsNum(BigDecimal.valueOf(orderOutRequest.getGoodsNum()));
|
appPmsOrderOut.setGoodsNum(BigDecimal.valueOf(orderOutRequest.getGoodsNum()));
|
||||||
appPmsOrderOut.setGoodsDesc(orderOutRequest.getGoodsDesc());
|
appPmsOrderOut.setGoodsDesc(orderOutRequest.getGoodsDesc());
|
||||||
|
appPmsOrderOut.setOrderStatus(0);
|
||||||
appPmsOrderOut.setCreateTime(new Date());
|
appPmsOrderOut.setCreateTime(new Date());
|
||||||
appPmsOrderOut.setUpdateTime(new Date());
|
appPmsOrderOut.setUpdateTime(new Date());
|
||||||
insertRow += appPmsOrderOutService.insertAppPmsOrderOut(appPmsOrderOut);
|
insertRow += appPmsOrderOutService.insertAppPmsOrderOut(appPmsOrderOut);
|
||||||
|
|
|
||||||
|
|
@ -16,6 +16,16 @@ public class AppPmsOrderOut extends BaseEntity
|
||||||
{
|
{
|
||||||
private static final long serialVersionUID = 1L;
|
private static final long serialVersionUID = 1L;
|
||||||
|
|
||||||
|
private String recordId;
|
||||||
|
|
||||||
|
public String getRecordId() {
|
||||||
|
return recordId;
|
||||||
|
}
|
||||||
|
|
||||||
|
public void setRecordId(String recordId) {
|
||||||
|
this.recordId = recordId;
|
||||||
|
}
|
||||||
|
|
||||||
/** 出库单号 */
|
/** 出库单号 */
|
||||||
private String listId;
|
private String listId;
|
||||||
|
|
||||||
|
|
@ -48,7 +58,7 @@ public class AppPmsOrderOut extends BaseEntity
|
||||||
private String spare2;
|
private String spare2;
|
||||||
|
|
||||||
@Excel(name = "订单状态")
|
@Excel(name = "订单状态")
|
||||||
private String orderStatus;
|
private Integer orderStatus;
|
||||||
|
|
||||||
public void setListId(String listId)
|
public void setListId(String listId)
|
||||||
{
|
{
|
||||||
|
|
@ -123,11 +133,11 @@ public class AppPmsOrderOut extends BaseEntity
|
||||||
return spare2;
|
return spare2;
|
||||||
}
|
}
|
||||||
|
|
||||||
public String getOrderStatus() {
|
public Integer getOrderStatus() {
|
||||||
return orderStatus;
|
return orderStatus;
|
||||||
}
|
}
|
||||||
|
|
||||||
public void setOrderStatus(String orderStatus) {
|
public void setOrderStatus(Integer orderStatus) {
|
||||||
this.orderStatus = orderStatus;
|
this.orderStatus = orderStatus;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -15,10 +15,10 @@ public interface AppPmsOrderOutMapper
|
||||||
/**
|
/**
|
||||||
* 查询【请填写功能名称】
|
* 查询【请填写功能名称】
|
||||||
*
|
*
|
||||||
* @param listId 【请填写功能名称】主键
|
* @param recordId 【请填写功能名称】主键
|
||||||
* @return 【请填写功能名称】
|
* @return 【请填写功能名称】
|
||||||
*/
|
*/
|
||||||
public AppPmsOrderOut selectAppPmsOrderOutByListId(String listId);
|
public AppPmsOrderOut selectAppPmsOrderOutByListId(String recordId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 查询【请填写功能名称】列表
|
* 查询【请填写功能名称】列表
|
||||||
|
|
@ -47,16 +47,16 @@ public interface AppPmsOrderOutMapper
|
||||||
/**
|
/**
|
||||||
* 删除【请填写功能名称】
|
* 删除【请填写功能名称】
|
||||||
*
|
*
|
||||||
* @param listId 【请填写功能名称】主键
|
* @param recordId 【请填写功能名称】主键
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
public int deleteAppPmsOrderOutByListId(String listId);
|
public int deleteAppPmsOrderOutByListId(String recordId);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 批量删除【请填写功能名称】
|
* 批量删除【请填写功能名称】
|
||||||
*
|
*
|
||||||
* @param listIds 需要删除的数据主键集合
|
* @param recordIds 需要删除的数据主键集合
|
||||||
* @return 结果
|
* @return 结果
|
||||||
*/
|
*/
|
||||||
public int deleteAppPmsOrderOutByListIds(String[] listIds);
|
public int deleteAppPmsOrderOutByListIds(String[] recordIds);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@
|
||||||
<mapper namespace="com.ruoyi.app.mapper.AppPmsOrderOutMapper">
|
<mapper namespace="com.ruoyi.app.mapper.AppPmsOrderOutMapper">
|
||||||
|
|
||||||
<resultMap type="AppPmsOrderOut" id="AppPmsOrderOutResult">
|
<resultMap type="AppPmsOrderOut" id="AppPmsOrderOutResult">
|
||||||
|
<id property="recordId" column="record_id" />
|
||||||
<result property="listId" column="list_id" />
|
<result property="listId" column="list_id" />
|
||||||
<result property="orderType" column="order_type" />
|
<result property="orderType" column="order_type" />
|
||||||
<result property="customerId" column="customer_id" />
|
<result property="customerId" column="customer_id" />
|
||||||
|
|
@ -16,7 +17,7 @@
|
||||||
</resultMap>
|
</resultMap>
|
||||||
|
|
||||||
<sql id="selectAppPmsOrderOutVo">
|
<sql id="selectAppPmsOrderOutVo">
|
||||||
select list_id, order_type, customer_id, goods_id, goods_num, goods_desc, spare1, spare2 from app_pms_order_out
|
select record_id, list_id, order_type, customer_id, goods_id, goods_num, goods_desc, spare1, spare2 from app_pms_order_out
|
||||||
</sql>
|
</sql>
|
||||||
|
|
||||||
<select id="selectAppPmsOrderOutList" parameterType="AppPmsOrderOut" resultMap="AppPmsOrderOutResult">
|
<select id="selectAppPmsOrderOutList" parameterType="AppPmsOrderOut" resultMap="AppPmsOrderOutResult">
|
||||||
|
|
@ -34,12 +35,13 @@
|
||||||
|
|
||||||
<select id="selectAppPmsOrderOutByListId" parameterType="String" resultMap="AppPmsOrderOutResult">
|
<select id="selectAppPmsOrderOutByListId" parameterType="String" resultMap="AppPmsOrderOutResult">
|
||||||
<include refid="selectAppPmsOrderOutVo"/>
|
<include refid="selectAppPmsOrderOutVo"/>
|
||||||
where list_id = #{listId}
|
where record_id = #{recordId}
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
<insert id="insertAppPmsOrderOut" parameterType="AppPmsOrderOut">
|
<insert id="insertAppPmsOrderOut" parameterType="AppPmsOrderOut">
|
||||||
insert into app_pms_order_out
|
insert into app_pms_order_out
|
||||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="recordId != null">record_id,</if>
|
||||||
<if test="listId != null">list_id,</if>
|
<if test="listId != null">list_id,</if>
|
||||||
<if test="orderType != null">order_type,</if>
|
<if test="orderType != null">order_type,</if>
|
||||||
<if test="customerId != null and customerId != ''">customer_id,</if>
|
<if test="customerId != null and customerId != ''">customer_id,</if>
|
||||||
|
|
@ -51,6 +53,7 @@
|
||||||
<if test="orderStatus != null">order_status,</if>
|
<if test="orderStatus != null">order_status,</if>
|
||||||
</trim>
|
</trim>
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
|
<if test="recordId != null">#{recordId},</if>
|
||||||
<if test="listId != null">#{listId},</if>
|
<if test="listId != null">#{listId},</if>
|
||||||
<if test="orderType != null">#{orderType},</if>
|
<if test="orderType != null">#{orderType},</if>
|
||||||
<if test="customerId != null and customerId != ''">#{customerId},</if>
|
<if test="customerId != null and customerId != ''">#{customerId},</if>
|
||||||
|
|
@ -66,6 +69,7 @@
|
||||||
<update id="updateAppPmsOrderOut" parameterType="AppPmsOrderOut">
|
<update id="updateAppPmsOrderOut" parameterType="AppPmsOrderOut">
|
||||||
update app_pms_order_out
|
update app_pms_order_out
|
||||||
<trim prefix="SET" suffixOverrides=",">
|
<trim prefix="SET" suffixOverrides=",">
|
||||||
|
<if test="listId != null">list_id = #{listId},</if>
|
||||||
<if test="orderType != null">order_type = #{orderType},</if>
|
<if test="orderType != null">order_type = #{orderType},</if>
|
||||||
<if test="customerId != null and customerId != ''">customer_id = #{customerId},</if>
|
<if test="customerId != null and customerId != ''">customer_id = #{customerId},</if>
|
||||||
<if test="goodsId != null and goodsId != ''">goods_id = #{goodsId},</if>
|
<if test="goodsId != null and goodsId != ''">goods_id = #{goodsId},</if>
|
||||||
|
|
@ -74,17 +78,17 @@
|
||||||
<if test="spare1 != null and spare1 != ''">spare1 = #{spare1},</if>
|
<if test="spare1 != null and spare1 != ''">spare1 = #{spare1},</if>
|
||||||
<if test="spare2 != null">spare2 = #{spare2},</if>
|
<if test="spare2 != null">spare2 = #{spare2},</if>
|
||||||
</trim>
|
</trim>
|
||||||
where list_id = #{listId}
|
where record_id = #{recordId}
|
||||||
</update>
|
</update>
|
||||||
|
|
||||||
<delete id="deleteAppPmsOrderOutByListId" parameterType="String">
|
<delete id="deleteAppPmsOrderOutByListId" parameterType="String">
|
||||||
delete from app_pms_order_out where list_id = #{listId}
|
delete from app_pms_order_out where record_id = #{recordId}
|
||||||
</delete>
|
</delete>
|
||||||
|
|
||||||
<delete id="deleteAppPmsOrderOutByListIds" parameterType="String">
|
<delete id="deleteAppPmsOrderOutByListIds" parameterType="String">
|
||||||
delete from app_pms_order_out where list_id in
|
delete from app_pms_order_out where record_id in
|
||||||
<foreach item="listId" collection="array" open="(" separator="," close=")">
|
<foreach item="record_id" collection="array" open="(" separator="," close=")">
|
||||||
#{listId}
|
#{recordId}
|
||||||
</foreach>
|
</foreach>
|
||||||
</delete>
|
</delete>
|
||||||
</mapper>
|
</mapper>
|
||||||
Loading…
Reference in New Issue
Block a user