From 95f9ea7eb339c36cade6c67d0385c49ec2d81477 Mon Sep 17 00:00:00 2001 From: 935090232@qq.com <ak473600000> Date: Wed, 14 Apr 2021 19:39:45 +0800 Subject: [PATCH] Merge branch 'score_shop' into api_score_meger --- zq-erp/src/main/resources/mybatis/mapper/xcxShop/ShopOrderV2Dao.xml | 25 +++++++++++++++++++++++++ 1 files changed, 25 insertions(+), 0 deletions(-) diff --git a/zq-erp/src/main/resources/mybatis/mapper/xcxShop/ShopOrderV2Dao.xml b/zq-erp/src/main/resources/mybatis/mapper/xcxShop/ShopOrderV2Dao.xml new file mode 100644 index 0000000..a282ab6 --- /dev/null +++ b/zq-erp/src/main/resources/mybatis/mapper/xcxShop/ShopOrderV2Dao.xml @@ -0,0 +1,25 @@ +<?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.matrix.system.shopXcx.dao.ShopOrderV2Dao"> + + <select id="selectReceivedOrderCount" resultType="java.lang.Integer"> + select count(*) from shop_order where user_id = #{userId} and order_status in (4,5) + </select> + + <select id="countOrderAmount" resultType="java.lang.Double"> + select IFNULL(sum(IFNULL( order_money, 0 )),0) from shop_order where user_id = #{userId} and order_status in (4,5) + </select> + + <select id="countBuyZdcp" resultType="java.lang.Integer"> + select count(*) from shop_order a + left join shop_order_details b on a.id=b.order_id + where a.user_id=#{userId} + and order_status in (4,5) + and find_in_set(b.p_id,#{productIds}) + </select> + + + +</mapper> \ No newline at end of file -- Gitblit v1.9.1