Commit bfe71a09 authored by jichao's avatar jichao

改表名

parent a5caa609
...@@ -26,7 +26,7 @@ public interface EnergyCountMRepository extends BaseMapper<EnergyCountM> { ...@@ -26,7 +26,7 @@ public interface EnergyCountMRepository extends BaseMapper<EnergyCountM> {
@Select("<script>select sum(WATER) as water,sum(WATER_MONEY) as waterMoney," + @Select("<script>select sum(WATER) as water,sum(WATER_MONEY) as waterMoney," +
"sum(ELEC) as elec,sum(ELEC_MONEY) as elecMoney," + "sum(ELEC) as elec,sum(ELEC_MONEY) as elecMoney," +
"sum(GAS) as gas,sum(GAS_MONEY) as gasMoney" + "sum(GAS) as gas,sum(GAS_MONEY) as gasMoney" +
" from ENERGY_COUNT_M e " + " from energy_count_m e " +
"where e.PRO_ID=#{proId} and `year`=#{year}" + "where e.PRO_ID=#{proId} and `year`=#{year}" +
"<if test=\"day != null\"> and `day`=${day} group by e.`day`</if>" + "<if test=\"day != null\"> and `day`=${day} group by e.`day`</if>" +
"<if test=\"mon != null\"> and mon=${mon} group by e.mon</if></script>") "<if test=\"mon != null\"> and mon=${mon} group by e.mon</if></script>")
...@@ -42,7 +42,7 @@ public interface EnergyCountMRepository extends BaseMapper<EnergyCountM> { ...@@ -42,7 +42,7 @@ public interface EnergyCountMRepository extends BaseMapper<EnergyCountM> {
"<if test=\"type == 1\">sum(e.WATER_MONEY)</if>" + "<if test=\"type == 1\">sum(e.WATER_MONEY)</if>" +
"<if test=\"type == 2\">sum(e.ELEC_MONEY)</if>" + "<if test=\"type == 2\">sum(e.ELEC_MONEY)</if>" +
"<if test=\"type == 3\">sum(e.GAS_MONEY)</if>" + "<if test=\"type == 3\">sum(e.GAS_MONEY)</if>" +
" as MONEY from ENERGY_COUNT_M e" + " as MONEY from energy_count_m e" +
" where e.PRO_ID=#{proId} and e.`YEAR`=#{year} and e.MON=${mon} and e.`DAY`=${day} group by e.`HOUR`+0 asc</script>") " where e.PRO_ID=#{proId} and e.`YEAR`=#{year} and e.MON=${mon} and e.`DAY`=${day} group by e.`HOUR`+0 asc</script>")
@ResultMap("resultMapVo") @ResultMap("resultMapVo")
List<EnergyCountMVo> countDailyPrice(EnergyCountMVo energyCountMVo); List<EnergyCountMVo> countDailyPrice(EnergyCountMVo energyCountMVo);
...@@ -82,7 +82,7 @@ public interface EnergyCountMRepository extends BaseMapper<EnergyCountM> { ...@@ -82,7 +82,7 @@ public interface EnergyCountMRepository extends BaseMapper<EnergyCountM> {
"<if test=\"type == 1\">sum(e.WATER_MONEY)</if>" + "<if test=\"type == 1\">sum(e.WATER_MONEY)</if>" +
"<if test=\"type == 2\">sum(e.ELEC_MONEY)</if>" + "<if test=\"type == 2\">sum(e.ELEC_MONEY)</if>" +
"<if test=\"type == 3\">sum(e.GAS_MONEY)</if>" + "<if test=\"type == 3\">sum(e.GAS_MONEY)</if>" +
" as MONEY from ENERGY_COUNT_M e where e.PRO_ID=#{proId} and e.`YEAR`=#{year} and e.MON=${mon}" + " as MONEY from energy_count_m e where e.PRO_ID=#{proId} and e.`YEAR`=#{year} and e.MON=${mon}" +
"<if test=\"hour != null\"> and e.HOUR &lt;= #{hour}</if>" + "<if test=\"hour != null\"> and e.HOUR &lt;= #{hour}</if>" +
" group by e.`DAY`+0 asc) a order by a.MONEY desc</script>") " group by e.`DAY`+0 asc) a order by a.MONEY desc</script>")
@ResultMap("resultMapVo") @ResultMap("resultMapVo")
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment