22 lines
976 B
XML

<?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.xhpc.order.mapper.XhpcInternetUserMapper">
<select id="selectByOperatorIdEvcs" resultType="int">
select count(*)
from xhpc_internet_user
where operator_id_evcs = #{operatorIdEvcs}
and cooperation_start_time &lt;= now()
and cooperation_end_time &gt;= now()
</select>
<select id="getXhpcStationInternetBlacklist" resultType="int">
SELECT COUNT(*) FROM xhpc_station_internet_blacklist
where internet_user_id = (select internet_user_id from xhpc_internet_user where operator_id_evcs = #{operatorIdEvcs} and del_flag=0 limit 1)
and status =0 and charging_station_id =(select charging_station_id from xhpc_terminal where serial_number=#{connectorId} and del_flag=0 and status=0 limit 1)
</select>
</mapper>