<?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.nova.sankuai.infra.mapper.CostConfigMapper">
|
|
<select id="pageCostConfigList" resultType="com.nova.sankuai.domain.vo.CostConfigVo">
|
SELECT
|
id as id,
|
channel_id as channelId,
|
channel_name as channelName,
|
channel_code as channelCode,
|
default_flag as defaultFlag,
|
relation_city as relationCity,
|
relation_city_id as relationCityId,
|
If(default_flag=1,'默认配置',relation_city_name) as relationCityName,
|
uv_price as uvPrice,
|
register_price as registerPrice,
|
finished_price as finishedPrice
|
from cost_config
|
<where>
|
is_delete = 0
|
<if test="pageDto.channelCode!=null">
|
and channel_code = #{pageDto.channelCode}
|
</if>
|
<if test="pageDto.relationCityId!=null and pageDto.relationCityId!=''">
|
and relation_city_id = #{pageDto.relationCityId}
|
</if>
|
</where>
|
order by channel_id
|
</select>
|
|
<update id="deleteCostConfig">
|
update cost_config set is_delete = 1 where id = #{id}
|
</update>
|
|
</mapper>
|