Browse Source

[A端][修复]:更改ordermapper中的字段名,试用新结构

release_toaliyun_real
hupeng 7 years ago
parent
commit
d21f10d0ef
2 changed files with 38 additions and 38 deletions
  1. +37
    -37
      mallinkService/src/main/resources/mapper/WxCouponOrderMapper.xml
  2. +1
    -1
      mallinkService/src/main/resources/mapper/WxOrderMapper.xml

+ 37
- 37
mallinkService/src/main/resources/mapper/WxCouponOrderMapper.xml View File

@@ -150,49 +150,14 @@
co.id,co.tenant_id,co.coupon_id,co.c_user_id,co.b_user_id,co.order_id,co.expired_time,co.coupon_order_status,co.create_date,co.update_date,co.coupon_price
</sql>

<select id="findListOfOrderedByDateForBUser" parameterType="map" resultMap="BVoResultMap">
select <include refid="allBUserOrderedCouponOrderColumns" />
from wx_coupon_order co,wx_order o,wx_coupon c,wx_c_user cu
where o.id = co.order_id
and o.merchant_id = #{merchantId}
and co.coupon_id = c.id
and cu.id = co.c_user_id
<if test="startDate != null">
AND co.create_date &gt; #{startDate,jdbcType=TIMESTAMP}
</if>
<if test="endDate != null">
AND co.create_date &lt; #{endDate,jdbcType=TIMESTAMP}
</if>
order by co.create_date desc

</select>

<select id="findListOfVerifiedByDateForBUser" parameterType="map" resultMap="BVoResultMap">
select <include refid="allBUserVerifiedCouponOrderColumns" />
from wx_coupon_order co,wx_order o,wx_coupon c,wx_c_user cu,wx_merchant_b_user bu
where o.id = co.order_id
and o.merchant_id = #{merchantId}
and co.coupon_id = c.id
and cu.id = co.c_user_id
and bu.id = co.b_user_id
<if test="startDate != null">
AND co.update_date &gt; #{startDate,jdbcType=TIMESTAMP}
</if>
<if test="endDate != null">
AND co.update_date &lt; #{endDate,jdbcType=TIMESTAMP}
</if>
AND co.coupon_order_status = '1'
order by co.update_date desc
</select>

<select id="findListOfAdmin" parameterType="com.iformall.domain.vo.WxCouponOrderBVo" resultMap="BVoResultMap">
select <include refid="allAdminCouponOrderColumns" />
from wx_coupon_order co
inner JOIN wx_order o on o.id = co.order_id
inner JOIN wx_coupon c on co.coupon_id = c.id
inner JOIN wx_c_user cu on cu.id = co.c_user_id
left JOIN wx_merchant m on o.merchant_id = m.id
left join wx_merchant_b_user bu on co.b_user_id = bu.id
left JOIN wx_merchant_b_user bu on co.b_user_id = bu.id
left JOIN wx_merchant m on bu.merchant_id = m.id
where 1 = 1
<if test=" null != id ">
and co.id = #{id}
@@ -222,6 +187,41 @@

</select>

<select id="findListOfOrderedByDateForBUser" parameterType="map" resultMap="BVoResultMap">
select <include refid="allBUserOrderedCouponOrderColumns" />
from wx_coupon_order co,wx_order o,wx_coupon c,wx_c_user cu
where o.id = co.order_id
and o.merchant_id = #{merchantId}
and co.coupon_id = c.id
and cu.id = co.c_user_id
<if test="startDate != null">
AND co.create_date &gt; #{startDate,jdbcType=TIMESTAMP}
</if>
<if test="endDate != null">
AND co.create_date &lt; #{endDate,jdbcType=TIMESTAMP}
</if>
order by co.create_date desc

</select>

<select id="findListOfVerifiedByDateForBUser" parameterType="map" resultMap="BVoResultMap">
select <include refid="allBUserVerifiedCouponOrderColumns" />
from wx_coupon_order co,wx_order o,wx_coupon c,wx_c_user cu,wx_merchant_b_user bu
where o.id = co.order_id
and o.merchant_id = #{merchantId}
and co.coupon_id = c.id
and cu.id = co.c_user_id
and bu.id = co.b_user_id
<if test="startDate != null">
AND co.update_date &gt; #{startDate,jdbcType=TIMESTAMP}
</if>
<if test="endDate != null">
AND co.update_date &lt; #{endDate,jdbcType=TIMESTAMP}
</if>
AND co.coupon_order_status = '1'
order by co.update_date desc
</select>

<select id="findListOfOrderedByDate" parameterType="map" resultMap="BaseResultMap">
select <include refid="allCouponOrderColumns" />
from wx_coupon_order co,wx_order o


+ 1
- 1
mallinkService/src/main/resources/mapper/WxOrderMapper.xml View File

@@ -183,7 +183,7 @@

<collection property="merchantVoList"
ofType="com.iformall.domain.vo.WxMerchantVo"
column="coupon_id"
column="product_id"
select="com.iformall.mapper.WxOrderMapper.findMerchantList" >
</collection>
</resultMap>


Loading…
Cancel
Save