mobilebroken/nflg-mobilebroken-repository/src/main/resources/mapper/TBaseAreaMapper.xml

31 lines
1.2 KiB
XML
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<?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.nflg.mobilebroken.repository.mapper.TBaseAreaMapper">
<sql id="whr">
<if test="query.areaCodeOrName=null and query.areaCodeOrName!=''">
and (area_code =#{query.areaCodeOrName} or area_name = #{query.areaCodeOrName} )
</if>
<if test="query.areaState!=null and query.areaState!=''">
and area_state=#{query.areaState}
</if>
</sql>
<select id="getList" resultType="com.nflg.mobilebroken.common.pojo.vo.TBaseAreaVO">
select * from t_base_area where parent_area_row_id=0 <include refid="whr" />
</select>
<update id="delByIds">
update t_base_area set area_state=0 , data_modify_time=now(), data_modify_user_no=#{userNo},
data_modify_user_name=#{userName} where id in
<foreach collection="ids" item="=item" open="(" close=")" separator=",">
#{item}
</foreach>
</update>
<select id="getCount" resultType="java.lang.Integer">
select count(1) from t_base_area
</select>
</mapper>