mppt模块
This commit is contained in:
@ -201,6 +201,31 @@
|
||||
group by type,station_id,day
|
||||
</where>
|
||||
</select>
|
||||
<select id="getElec" resultType="com.ho.business.vo.resp.profit.DayProfitType">
|
||||
select
|
||||
station_id,day,type,sum(digital) as digital
|
||||
from elec_meter_value
|
||||
<where>
|
||||
digital > 0
|
||||
<if test="type != null">
|
||||
and type = #{type}
|
||||
</if>
|
||||
<if test="groupId != null">
|
||||
and group_id = #{groupId}
|
||||
</if>
|
||||
<if test="beginTime != null and beginTime != '' and endTime != null and endTime != ''">
|
||||
and day BETWEEN #{beginTime}
|
||||
AND #{endTime}
|
||||
</if>
|
||||
<if test="stationIds != null and stationIds.size() != 0">
|
||||
and station_id in
|
||||
<foreach collection="stationIds" item="item" open="(" close=")" separator=",">
|
||||
#{item}
|
||||
</foreach>
|
||||
</if>
|
||||
</where>
|
||||
group by station_id, day,type;
|
||||
</select>
|
||||
|
||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
|
||||
delete
|
||||
|
||||
Reference in New Issue
Block a user