提交 05869e56 authored 作者: 吴德鹏's avatar 吴德鹏

增加代购商品的物流状态

上级 ffe92945
......@@ -9,7 +9,7 @@ import java.util.Date;
* 表名 tb_cf_platform_order
*
* @author lipengjun
* @date 2019-09-20 11:03:37
* @date 2020-06-05 11:22:12
*/
public class TbCfPlatformOrderEntity implements Serializable {
private static final long serialVersionUID = 1L;
......@@ -26,6 +26,10 @@ public class TbCfPlatformOrderEntity implements Serializable {
* 第三方订单id
*/
private String pOrderId;
/**
* 商品ID
*/
private String itemId;
/**
* 第三方平台名
*/
......@@ -41,16 +45,11 @@ public class TbCfPlatformOrderEntity implements Serializable {
/**
* 代购人
*/
private String agentName;
private String userName;
/**
* 代购人id
*/
private String agentId;
/**
* 商品品名
*/
private String descripitionName;
private String userId;
/**
* 创建时间
*/
......@@ -58,26 +57,19 @@ public class TbCfPlatformOrderEntity implements Serializable {
/**
* 实际付款
*/
private BigDecimal realPay;
private BigDecimal realityPay;
/**
* 第三方快递单号
*/
private String pExpressNumber;
/**
* 设置:商品品名
* 商品品名id
*/
public String setDescripitionName() {
return descripitionName;
}
private String descripitionId;
/**
* 获取:商品品名
* 物流状态 10:无 20:有
*/
public String getDescripitionName() {
this.descripitionName = descripitionName;
return descripitionName;
}
private Integer logisticsStatus;
/**
* 设置:对应id
......@@ -118,6 +110,19 @@ public class TbCfPlatformOrderEntity implements Serializable {
public String getPOrderId() {
return pOrderId;
}
/**
* 设置:商品ID
*/
public void setItemId(String itemId) {
this.itemId = itemId;
}
/**
* 获取:商品ID
*/
public String getItemId() {
return itemId;
}
/**
* 设置:第三方平台名
*/
......@@ -160,28 +165,28 @@ public class TbCfPlatformOrderEntity implements Serializable {
/**
* 设置:代购人
*/
public void setAgentName(String agentName) {
this.agentName = agentName;
public void setUserName(String userName) {
this.userName = userName;
}
/**
* 获取:代购人
*/
public String getAgentName() {
return agentName;
public String getUserName() {
return userName;
}
/**
* 设置:代购人id
*/
public void setAgentId(String agentId) {
this.agentId = agentId;
public void setUserId(String userId) {
this.userId = userId;
}
/**
* 获取:代购人id
*/
public String getAgentId() {
return agentId;
public String getUserId() {
return userId;
}
/**
* 设置:创建时间
......@@ -199,15 +204,15 @@ public class TbCfPlatformOrderEntity implements Serializable {
/**
* 设置:实际付款
*/
public void setRealPay(BigDecimal realPay) {
this.realPay = realPay;
public void setRealityPay(BigDecimal realityPay) {
this.realityPay = realityPay;
}
/**
* 获取:实际付款
*/
public BigDecimal getRealPay() {
return realPay;
public BigDecimal getRealityPay() {
return realityPay;
}
/**
* 设置:第三方快递单号
......@@ -222,5 +227,30 @@ public class TbCfPlatformOrderEntity implements Serializable {
public String getPExpressNumber() {
return pExpressNumber;
}
/**
* 设置:商品品名id
*/
public void setDescripitionId(String descripitionId) {
this.descripitionId = descripitionId;
}
/**
* 获取:商品品名id
*/
public String getDescripitionId() {
return descripitionId;
}
/**
* 设置:物流状态 10:无 20:有
*/
public void setLogisticsStatus(Integer logisticsStatus) {
this.logisticsStatus = logisticsStatus;
}
/**
* 获取:物流状态 10:无 20:有
*/
public Integer getLogisticsStatus() {
return logisticsStatus;
}
}
......@@ -98,6 +98,7 @@ public class TbCfOrderServiceImpl implements TbCfOrderService {
tbCfPlatformOrder.setUserName(sysUserDao.queryById(userId));
res = tbCfPlatformOrderDao.updates(tbCfPlatformOrder);
} else {
tbCfPlatformOrder.setLogisticsStatus(10);
tbCfPlatformOrder.setRelativeId(tbCfPlatformOrder.getOrdersId());
tbCfPlatformOrder.setOrderId(tbCfItemOrderRDao.getOrderId(tbCfPlatformOrder.getOrdersId()));
tbCfPlatformOrder.setCreateTime(new Date());
......
......@@ -52,6 +52,19 @@ public class PlatformOrderVo implements Serializable{
*/
private String pExpressNumber;
/**
* 物流状态 10:无 20:有
*/
private Integer logisticsStatus;
public Integer getLogisticsStatus() {
return logisticsStatus;
}
public void setLogisticsStatus(Integer logisticsStatus) {
this.logisticsStatus = logisticsStatus;
}
private String userId;
private String userName;
......
......@@ -5,20 +5,19 @@
<resultMap type="com.platform.vo.PlatformOrderVo" id="tbCfPlatformOrderMap">
<result property="relativeId" column="relative_id"/>
<result property="ordersId" column="ordersId"/>
<result property="orderId" column="order_id"/>
<result property="pOrderId" column="p_order_id"/>
<result property="itemId" column="item_id"/>
<result property="platformName" column="platform_name"/>
<result property="platformCode" column="platform_code"/>
<result property="pDeliveryAddress" column="p_delivery_address"/>
<result property="descripitionId" column="descripition_id"/>
<result property="templateId" column="template_id"/>
<result property="templateTitle" column="template_title"/>
<result property="userName" column="user_name"/>
<result property="userId" column="user_id"/>
<result property="createTime" column="create_time"/>
<result property="realityPay" column="reality_pay"/>
<result property="pExpressNumber" column="p_express_number"/>
<result property="descripitionId" column="descripition_id"/>
<result property="logisticsStatus" column="logistics_status"/>
</resultMap>
<select id="queryObject" resultType="com.platform.vo.PlatformOrderVo">
......@@ -73,7 +72,7 @@
</if>
</select>-->
<!--
<!--
<select id="queryTotal" resultType="int">
select count(*) from tb_cf_platform_order
WHERE 1=1
......@@ -81,7 +80,7 @@
AND name LIKE concat('%',#{name},'%')
</if>
</select>
-->
-->
<insert id="save" parameterType="com.platform.vo.PlatformOrderVo">
insert into tb_cf_platform_order(
......@@ -96,7 +95,8 @@
`create_time`,
`reality_pay`,
`p_express_number`,
`descripition_id`)
`descripition_id`,
`logistics_status`)
values(
#{relativeId},
#{orderId},
......@@ -109,39 +109,44 @@
#{createTime},
#{realityPay},
#{pExpressNumber},
#{descripitionId})
#{descripitionId},
#{logisticsStatus})
</insert>
<!--<update id="update" parameterType="com.platform.vo.PlatformOrderVo">
<update id="update" parameterType="com.platform.entity.TbCfItemOrderREntity">
update tb_cf_platform_order
<set>
<if test="orderId != null">`order_id` = #{orderId}, </if>
<if test="pOrderId != null">`p_order_id` = #{pOrderId}, </if>
<if test="platformName != null">`platform_name` = #{platformName}, </if>
<if test="platformCode != null">`platform_code` = #{platformCode}, </if>
<if test="pDeliveryAddress != null">`p_delivery_address` = #{pDeliveryAddress}, </if>
<if test="userName != null">`user_name` = #{userName}, </if>
<if test="userId != null">`user_id` = #{userId}, </if>
<if test="createTime != null">`create_time` = #{createTime}, </if>
<if test="realityPay != null">`reality_pay` = #{realityPay}, </if>
<if test="pExpressNumber != null">`p_express_number` = #{pExpressNumber}</if>
<if test="orderId != null">`order_id` = #{orderId},</if>
<if test="pOrderId != null">`p_order_id` = #{pOrderId},</if>
<if test="itemId != null">`item_id` = #{itemId},</if>
<if test="platformName != null">`platform_name` = #{platformName},</if>
<if test="platformCode != null">`platform_code` = #{platformCode},</if>
<if test="pDeliveryAddress != null">`p_delivery_address` = #{pDeliveryAddress},</if>
<if test="userName != null">`user_name` = #{userName},</if>
<if test="userId != null">`user_id` = #{userId},</if>
<if test="createTime != null">`create_time` = #{createTime},</if>
<if test="realityPay != null">`reality_pay` = #{realityPay},</if>
<if test="pExpressNumber != null">`p_express_number` = #{pExpressNumber},</if>
<if test="descripitionId != null">`descripition_id` = #{descripitionId},</if>
<if test="logisticsStatus != null">`logistics_status` = #{logisticsStatus}</if>
</set>
where relative_id = #{relativeId}
</update>-->
<update id="updates" parameterType="com.platform.vo.PlatformOrderVo" >
</update>
<update id="updates" parameterType="com.platform.vo.PlatformOrderVo">
update tb_cf_platform_order p left join tb_cf_express_template e on e.template_id=p.descripition_id
left join tb_cf_item_order_r i on i.order_id=p.order_id
<set>
<if test="orderId != null">p.order_id = #{orderId}, </if>
<if test="pOrderId != null">p.p_order_id = #{pOrderId}, </if>
<if test="platformName != null">p.platform_name = #{platformName}, </if>
<if test="platformCode != null">p.platform_code = #{platformCode}, </if>
<if test="pDeliveryAddress != null">p.p_delivery_address = #{pDeliveryAddress}, </if>
<if test="createTime != null">p.create_time = #{createTime}, </if>
<if test="realityPay != null">p.reality_pay = #{realityPay}, </if>
<if test="orderId != null">p.order_id = #{orderId},</if>
<if test="pOrderId != null">p.p_order_id = #{pOrderId},</if>
<if test="platformName != null">p.platform_name = #{platformName},</if>
<if test="platformCode != null">p.platform_code = #{platformCode},</if>
<if test="pDeliveryAddress != null">p.p_delivery_address = #{pDeliveryAddress},</if>
<if test="createTime != null">p.create_time = #{createTime},</if>
<if test="realityPay != null">p.reality_pay = #{realityPay},</if>
<if test="pExpressNumber != null">p.p_express_number = #{pExpressNumber},</if>
<if test="descripitionId != null">p.descripition_id = #{descripitionId}</if>
<if test="descripitionId != null">p.descripition_id = #{descripitionId},</if>
<if test="logisticsStatus != null">`logistics_status` = #{logisticsStatus}</if>
</set>
where p.relative_id = #{relativeId}
</update>
......
......@@ -2,13 +2,13 @@
#jdbc.username=root
#jdbc.password=root
#jdbc.url=jdbc:mysql://47.106.242.175:3306/chinafrica?allowMultiQueries=true&useSSL=false&useUnicode=true&characterEncoding=UTF-8
#jdbc.username=root
#jdbc.password=diaoyun666
jdbc.url=jdbc:mysql://47.106.242.175:3306/chinafrica?allowMultiQueries=true&useSSL=false&useUnicode=true&characterEncoding=UTF-8
jdbc.username=root
jdbc.password=diaoyun666
jdbc.url: jdbc:mysql://159.138.48.71:3306/chinafrica?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&autoReconnect=true&failOverReadOnly=false&zeroDateTimeBehavior=convertToNull&useSSL=false
jdbc.username: root
jdbc.password: Diaoyunnuli.8
#jdbc.url: jdbc:mysql://159.138.48.71:3306/chinafrica?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&autoReconnect=true&failOverReadOnly=false&zeroDateTimeBehavior=convertToNull&useSSL=false
#jdbc.username: root
#jdbc.password: Diaoyunnuli.8
jdbc.initialSize=5
jdbc.maxActive=30
......
......@@ -2,13 +2,13 @@
#jdbc.username=root
#jdbc.password=root
#jdbc.url=jdbc:mysql://47.106.242.175:3306/chinafrica?allowMultiQueries=true&useSSL=false&useUnicode=true&characterEncoding=UTF-8
#jdbc.username=root
#jdbc.password=diaoyun666
jdbc.url=jdbc:mysql://47.106.242.175:3306/chinafrica?allowMultiQueries=true&useSSL=false&useUnicode=true&characterEncoding=UTF-8
jdbc.username=root
jdbc.password=diaoyun666
jdbc.url: jdbc:mysql://159.138.48.71:3306/chinafrica?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&autoReconnect=true&failOverReadOnly=false&zeroDateTimeBehavior=convertToNull&useSSL=false
jdbc.username: root
jdbc.password: Diaoyunnuli.8
#jdbc.url: jdbc:mysql://159.138.48.71:3306/chinafrica?useUnicode=true&characterEncoding=UTF-8&rewriteBatchedStatements=true&autoReconnect=true&failOverReadOnly=false&zeroDateTimeBehavior=convertToNull&useSSL=false
#jdbc.username: root
#jdbc.password: Diaoyunnuli.8
jdbc.initialSize=5
jdbc.maxActive=30
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论