@ -625,7 +626,7 @@ public interface HighOrderMapperExt {
@Select({"<script>"+
" SELECT"+
" (select mer.merchant_name from high_merchant mer where EXISTS (select 1 from high_coupon cou where cou.id = a.goods_id and mer.id = cou.merchant_id)) merchantName,"+
" case a.goods_type when 1 then '卡券' when 2 then '金币充值' when 3 then '加油缴费' when 4 then 'KFC' when 5 then '电影票' when 6 then '话费充值' when 7 then '优惠券包' end goodsType, "+
" case a.goods_type when 1 then '卡券' when 2 then '金币充值' when 3 then '加油缴费' when 4 then 'KFC' when 5 then '电影票' when 6 then '话费充值' when 7 then '优惠券包' when 8 then '汇联通充值' end goodsType, "+
" a.goods_name goodsName, "+
" a.goods_type goodsTypeId,"+
" case a.giveaway_type when 1 then '赠送' when 0 then '购买' end giveawayType,"+
@ -675,4 +676,84 @@ public interface HighOrderMapperExt {
" (select mer.merchant_name from high_merchant mer where EXISTS (select 1 from high_coupon cou where cou.id = a.goods_id and mer.id = cou.merchant_id)) merchantName,"+
" case a.goods_type when 1 then '卡券' when 2 then '金币充值' when 3 then '加油缴费' when 4 then 'KFC' when 5 then '电影票' when 6 then '话费充值' when 7 then '优惠券包' when 8 then '汇联通充值' end goodsType, "+
" a.goods_name goodsName, "+
" a.goods_type goodsTypeId,"+
" case a.giveaway_type when 1 then '赠送' when 0 then '购买' end giveawayType,"+
" b.order_no orderNo,"+
" b.mem_name memName,"+
" b.mem_phone memPhone,"+
" case b.pay_model when 1 then '金币' when 2 then '第三方' end payModel, "+
" case b.pay_type when 1 then '支付宝' when 2 then '微信' when 3 then '金币' when 4 then '工会卡' when 5 then '银联' end payType,"+
" b.pay_serial_no paySerialNo,"+
" case a.giveaway_type when 0 then b.total_price when 1 then 0 end totalPrice,"+
" b.mem_discount_name memDiscountName,"+
" b.deduction_price deductionPrice,"+
" case a.giveaway_type when 0 then case when b.pay_gold is null then 0 else pay_gold end when 1 then 0 end payGold,"+
" case a.giveaway_type when 0 then b.pay_price when 1 then 0 end payPrice,"+
" case a.giveaway_type when 0 then case when b.pay_gold is not null then convert(b.pay_gold / 100,decimal(10,2)) else b.pay_real_price end when 1 then 0 end payRealPrice,"+
" case b.order_status when 1 then '待支付' when 2 then '已支付' when 3 then '已完成' when 4 then '已退款' when 5 then '已取消' when 6 then '退款中' when 7 then '退款失败' end orderStatus, "+
" b.order_status orderStatusId,"+
" b.create_time createTime,"+
" b.pay_time payTime,"+
" b.cancel_time cancelTime,"+
" b.refund_time refundTime,"+
" b.refund_content refundContent,"+
" b.refusal_refund_content refusalRefundContent"+
" FROM"+
" high_child_order a,"+
" high_order b"+
" WHERE"+
" a.order_id = b.id"+
" and a.giveaway_type = 0"+
" and b.Identification_code = #{map.identificationCode}"+
" and b.pay_type in (1,2,3,5)"+
" and b.order_status in (2,3)"+
" <if test='map.orderNo != null'> and b.order_no = #{map.orderNo} </if>"+
" <if test='map.paySerialNo != null'> and b.pay_serial_no = #{map.paySerialNo} </if>"+
" <if test='map.payModel != null'> and b.pay_model = #{map.payModel} </if>"+
" <if test='map.memDiscountName != null'> and a.goods_name = #{map.memDiscountName} </if>"+
" <if test='map.memPhone != null'> and b.mem_phone = #{map.memPhone} </if>"+