package com.hai.dao; import com.hai.entity.HighCouponCode; import com.hai.model.GzSinopecModel; import org.apache.ibatis.annotations.*; import org.apache.ibatis.type.JdbcType; import java.util.List; import java.util.Map; /** * mapper扩展类 */ public interface HighCouponCodeMapperExt { @Insert({ "" }) void insertList(@Param(value = "list") List list); @Select("select * from high_coupon_code where child_order_id = (SELECT b.id child_order_id FROM high_order a,high_child_order b where a.mem_discount_id = #{discountUserRelId} and a.id = b.order_id and b.goods_type = 1 and b.child_orde_status in (2,3,4) GROUP BY a.mem_discount_id)") @Results({ @Result(column="id", property="id", jdbcType= JdbcType.BIGINT, id=true), @Result(column="coupon_id", property="couponId", jdbcType=JdbcType.BIGINT), @Result(column="merchant_id", property="merchantId", jdbcType=JdbcType.BIGINT), @Result(column="is_assign_agent", property="isAssignAgent", jdbcType=JdbcType.BIT), @Result(column="agent_id", property="agentId", jdbcType=JdbcType.BIGINT), @Result(column="store_id", property="storeId", jdbcType=JdbcType.BIGINT), @Result(column="store_name", property="storeName", jdbcType=JdbcType.VARCHAR), @Result(column="child_order_id", property="childOrderId", jdbcType=JdbcType.BIGINT), @Result(column="code_key", property="codeKey", jdbcType=JdbcType.VARCHAR), @Result(column="sales_code", property="salesCode", jdbcType=JdbcType.VARCHAR), @Result(column="sales_end_time", property="salesEndTime", jdbcType=JdbcType.TIMESTAMP), @Result(column="use_end_time", property="useEndTime", jdbcType=JdbcType.TIMESTAMP), @Result(column="create_time", property="createTime", jdbcType=JdbcType.TIMESTAMP), @Result(column="receive_time", property="receiveTime", jdbcType=JdbcType.TIMESTAMP), @Result(column="consume_time", property="consumeTime", jdbcType=JdbcType.TIMESTAMP), @Result(column="status", property="status", jdbcType=JdbcType.INTEGER), @Result(column="operator_id", property="operatorId", jdbcType=JdbcType.BIGINT), @Result(column="operator_name", property="operatorName", jdbcType=JdbcType.VARCHAR), @Result(column="ext_1", property="ext1", jdbcType=JdbcType.VARCHAR), @Result(column="ext_2", property="ext2", jdbcType=JdbcType.VARCHAR), @Result(column="ext_3", property="ext3", jdbcType=JdbcType.VARCHAR) }) HighCouponCode selectCouponCodeByUserDiscount(@Param("discountUserRelId") Long discountUserRelId); @Select({""}) List selectGzSinopecAssignList(@Param("param") Map param); }