You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
<?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.epmet.dao.CustomerParameterDao">
|
|
|
|
|
|
|
|
<!-- 更新客户配置信息 -->
|
|
|
|
<update id="updateParamInfo">
|
|
|
|
<foreach collection="formDTOS" item="f" separator=";">
|
|
|
|
UPDATE customer_parameter
|
|
|
|
SET PARAMETER_VALUE = #{f.subtractParameterValue}
|
|
|
|
<where>
|
|
|
|
DEL_FLAG = 0
|
|
|
|
AND CUSTOMER_ID = #{f.customerId}
|
|
|
|
AND PARAMETER_KEY = #{f.parameterKey}
|
|
|
|
</where>
|
|
|
|
</foreach>
|
|
|
|
</update>
|
|
|
|
|
|
|
|
<!-- 查询客户的配置信息 -->
|
|
|
|
<select id="selectParamInfo" resultType="com.epmet.dto.result.CrmParameterResultDTO">
|
|
|
|
SELECT
|
|
|
|
CUSTOMER_ID,
|
|
|
|
PARAMETER_KEY,
|
|
|
|
PARAMETER_VALUE,
|
|
|
|
(CASE WHEN PARAMETER_SWITCH = 'on' THEN TRUE ELSE FALSE END) AS switchStatus
|
|
|
|
FROM customer_parameter
|
|
|
|
WHERE DEL_FLAG = 0
|
|
|
|
AND
|
|
|
|
<foreach collection="formDTOS" item="formDTO" separator=" OR ">
|
|
|
|
CUSTOMER_ID = #{formDTO.customerId}
|
|
|
|
AND PARAMETER_KEY = #{formDTO.parameterKey}
|
|
|
|
</foreach>
|
|
|
|
</select>
|
|
|
|
|
|
|
|
<!-- 查询FootBar显示模式(产品配置+客户定制化通用) -->
|
|
|
|
<select id="selectAppFootBarPattern" parameterType="map" resultType="com.epmet.entity.CustomerParameterEntity">
|
|
|
|
select
|
|
|
|
cp.*
|
|
|
|
from customer_parameter cp
|
|
|
|
where cp.DEL_FLAG='0'
|
|
|
|
and cp.CUSTOMER_ID=#{customerId}
|
|
|
|
and cp.PARAMETER_KEY=#{parameterKey}
|
|
|
|
</select>
|
|
|
|
</mapper>
|