|
@@ -21,10 +21,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<result property="date" column="date" />
|
|
<result property="date" column="date" />
|
|
<result property="deductionGrowthValue" column="deduction_growth_value" />
|
|
<result property="deductionGrowthValue" column="deduction_growth_value" />
|
|
<result property="memberCondit" column="member_condit" />
|
|
<result property="memberCondit" column="member_condit" />
|
|
|
|
+ <result property="stationId" column="station_id" />
|
|
|
|
+ <result property="stationName" column="station_name" />
|
|
|
|
+ <result property="oilName" column="oil_name" />
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectCustomerGradeSettingVo">
|
|
<sql id="selectCustomerGradeSettingVo">
|
|
- select id, grade, discount_way, gasoil_discount_litre, dieseloil_discount_litre, grade_type, gasoil_consume, gasoil_growth_value, dieseloil_consume, dieseloil_growth_value, member_recharge, member_growth_value, growth_value, date, deduction_growth_value, member_condit from customer_grade_setting
|
|
|
|
|
|
+ select id, grade, discount_way, gasoil_discount_litre, dieseloil_discount_litre, grade_type, gasoil_consume, gasoil_growth_value, dieseloil_consume, dieseloil_growth_value, member_recharge, member_growth_value, growth_value, date, deduction_growth_value, member_condit, station_id, station_name, oil_name from customer_grade_setting
|
|
</sql>
|
|
</sql>
|
|
|
|
|
|
<select id="selectCustomerGradeSettingList" parameterType="CustomerGradeSetting" resultMap="CustomerGradeSettingResult">
|
|
<select id="selectCustomerGradeSettingList" parameterType="CustomerGradeSetting" resultMap="CustomerGradeSettingResult">
|
|
@@ -45,6 +48,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="date != null "> and date = #{date}</if>
|
|
<if test="date != null "> and date = #{date}</if>
|
|
<if test="deductionGrowthValue != null and deductionGrowthValue != ''"> and deduction_growth_value = #{deductionGrowthValue}</if>
|
|
<if test="deductionGrowthValue != null and deductionGrowthValue != ''"> and deduction_growth_value = #{deductionGrowthValue}</if>
|
|
<if test="memberCondit != null and memberCondit != ''"> and member_condit = #{memberCondit}</if>
|
|
<if test="memberCondit != null and memberCondit != ''"> and member_condit = #{memberCondit}</if>
|
|
|
|
+ <if test="stationId != null "> and station_id = #{stationId}</if>
|
|
|
|
+ <if test="stationName != null and stationName != ''"> and station_name like concat('%', #{stationName}, '%')</if>
|
|
|
|
+ <if test="oilName != null and oilName != ''"> and oil_name like concat('%', #{oilName}, '%')</if>
|
|
</where>
|
|
</where>
|
|
</select>
|
|
</select>
|
|
|
|
|
|
@@ -71,6 +77,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="date != null">date,</if>
|
|
<if test="date != null">date,</if>
|
|
<if test="deductionGrowthValue != null">deduction_growth_value,</if>
|
|
<if test="deductionGrowthValue != null">deduction_growth_value,</if>
|
|
<if test="memberCondit != null">member_condit,</if>
|
|
<if test="memberCondit != null">member_condit,</if>
|
|
|
|
+ <if test="stationId != null">station_id,</if>
|
|
|
|
+ <if test="stationName != null">station_name,</if>
|
|
|
|
+ <if test="oilName != null">oil_name,</if>
|
|
</trim>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="grade != null">#{grade},</if>
|
|
<if test="grade != null">#{grade},</if>
|
|
@@ -88,6 +97,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="date != null">#{date},</if>
|
|
<if test="date != null">#{date},</if>
|
|
<if test="deductionGrowthValue != null">#{deductionGrowthValue},</if>
|
|
<if test="deductionGrowthValue != null">#{deductionGrowthValue},</if>
|
|
<if test="memberCondit != null">#{memberCondit},</if>
|
|
<if test="memberCondit != null">#{memberCondit},</if>
|
|
|
|
+ <if test="stationId != null">#{stationId},</if>
|
|
|
|
+ <if test="stationName != null">#{stationName},</if>
|
|
|
|
+ <if test="oilName != null">#{oilName},</if>
|
|
</trim>
|
|
</trim>
|
|
</insert>
|
|
</insert>
|
|
|
|
|
|
@@ -109,6 +121,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
<if test="date != null">date = #{date},</if>
|
|
<if test="date != null">date = #{date},</if>
|
|
<if test="deductionGrowthValue != null">deduction_growth_value = #{deductionGrowthValue},</if>
|
|
<if test="deductionGrowthValue != null">deduction_growth_value = #{deductionGrowthValue},</if>
|
|
<if test="memberCondit != null">member_condit = #{memberCondit},</if>
|
|
<if test="memberCondit != null">member_condit = #{memberCondit},</if>
|
|
|
|
+ <if test="stationId != null">station_id = #{stationId},</if>
|
|
|
|
+ <if test="stationName != null">station_name = #{stationName},</if>
|
|
|
|
+ <if test="oilName != null">oil_name = #{oilName},</if>
|
|
</trim>
|
|
</trim>
|
|
where id = #{id}
|
|
where id = #{id}
|
|
</update>
|
|
</update>
|