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

修复后台订单bug

上级 03eff256
......@@ -114,4 +114,7 @@ public interface TbCfOrderDao extends BaseDao<TbCfOrderEntity> {
int queryTotal2();
TbCfOrderEntity queryOrderById(String orderId);
}
......@@ -29,6 +29,7 @@ public interface TbCfOrderListDao extends BaseDao<TbCfOrderListEntity> {
int queryOrderDeliveryTotal(String orderId);
List<DeliveryOrderVo> queryOrderDeliveryList(String orderId);
List<DeliveryOrderVo> queryOrderDeliveryWebList(String orderId);
OrderBasicVo queryorderBasic(String orderId);
......
......@@ -142,6 +142,16 @@ public class TbCfOrderEntity implements Serializable {
*/
private String remarkInfo;
private Integer orderSource;
public Integer getOrderSource() {
return orderSource;
}
public void setOrderSource(Integer orderSource) {
this.orderSource = orderSource;
}
public String getRemarkInfo() {
return remarkInfo;
}
......
......@@ -31,6 +31,16 @@ public class TbCfOrderListEntity implements Serializable {
private String deliveryFlag;
private BigDecimal itemsPrice;
private Integer orderSource;
public Integer getOrderSource() {
return orderSource;
}
public void setOrderSource(Integer orderSource) {
this.orderSource = orderSource;
}
public BigDecimal getItemsPrice() {
return itemsPrice;
}
......
......@@ -30,6 +30,8 @@ public class TbCfOrderListServiceImpl implements TbCfOrderListService {
@Autowired
private TbCfOrderDao tbCfOrderDao;
private final String PC_WEB_ORDER="2";
@Override
public List<TbCfOrderListEntity> queryOrderList(Map<String, Object> map) {
return tbCfOrderListDao.queryOrderList(map);
......@@ -42,6 +44,10 @@ public class TbCfOrderListServiceImpl implements TbCfOrderListService {
@Override
public List<DeliveryOrderVo> queryOrderDeliveryList(String orderId) {
TbCfOrderEntity order = tbCfOrderDao.queryOrderById(orderId);
if(PC_WEB_ORDER.equals(order.getOrderSource().toString())){
return tbCfOrderListDao.queryOrderDeliveryWebList(orderId);
}
return tbCfOrderListDao.queryOrderDeliveryList(orderId);
}
......
......@@ -15,6 +15,7 @@
<result property="orderStatus" column="order_status"/>
<result property="userId" column="user_id"/>
<result property="userName" column="user_name"/>
<result property="orderSource" column="order_source"/>
<result property="deliveryAddressId" column="delivery_address_id"/>
<result property="deliveryAddress" column="delivery_address"/>
<result property="deliveryName" column="delivery_name"/>
......@@ -47,6 +48,7 @@
o.deal_time,
i.close_time closeTime,
i.order_status,
o.order_source,
o.user_id,
o.user_name,
o.delivery_address_id,
......@@ -71,6 +73,11 @@
left join tb_cf_item_order_r i on i.order_id=o.order_id
WHERE 1=1 and i.enable_flag=1 and i.order_item_id = #{orderId}
</select>
<select id="queryOrderById" resultType="com.platform.entity.TbCfOrderEntity">
select * from tb_cf_order where order_id=#{orderId}
</select>
<select id="getOrderByDate" resultType="com.platform.vo.StatisticalVo">
SELECT
<choose>
......@@ -578,4 +585,4 @@
<select id="queryPayCount" resultType="int">
select count(order_id) from tb_cf_order where pay_status=#{payStatus}
</select>
</mapper>
\ No newline at end of file
</mapper>
......@@ -10,6 +10,7 @@
<result property="orderTime" column="order_time"/>
<result property="realityPay" column="reality_pay"/>
<result property="itemsPrice" column="items_price"/>
<result property="orderSource" column="order_source"/>
<result property="deliveryAddress" column="delivery_address"/>
<result property="deliveryName" column="delivery_name"/>
<result property="deliveryPhone" column="delivery_phone"/>
......@@ -143,6 +144,15 @@
LEFT JOIN tb_cf_coupon c on c.coupon_id =o.coupon_id
where r.order_id=#{orderId}
</select>
<select id="queryOrderDeliveryWebList" resultType="com.platform.vo.DeliveryOrderVo">
select *,s.discount_price itemPrice,s.item_name itemTitle,i.sku_desc itemSku,i.sku_img itemImg, r.item_num itemNum from tb_cf_item_order_r r
left join tb_cf_order o on o.order_id=r.order_id
left join tb_cf_item_skus i on r.item_id=i.id
left join tb_cf_station_item s on s.item_id=i.item_id
where r.order_id=#{orderId}
</select>
<!--查询代购订单列表总记录数-->
<select id="queryOrderDeliveryTotal" resultType="int">
select count( *)
......@@ -226,4 +236,4 @@
</set>
where order_id=#{orderId}
</update>
</mapper>
\ No newline at end of file
</mapper>
......@@ -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 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论