工业级运维app手机api
xufenglei
2017-11-16 43c0f7bd6b605b2c71f58e43055144004e7d42e7
src/main/resources/mapper/HistoryEntityMapper.xml
@@ -231,10 +231,10 @@
      FROM
         history
      WHERE
         mac = #{mac}
      AND mac_key = #{macKey}
      AND time > #{start}
      AND time < #{end}
         mac = #{mac,jdbcType=VARCHAR}
      AND mac_key = #{macKey,jdbcType=VARCHAR}
      AND time > #{start,jdbcType=TIMESTAMP}
      AND time < #{end,jdbcType=TIMESTAMP}
  </select>
   <select id="getAverageByAll" resultType="map">
@@ -266,7 +266,7 @@
      <if test="macKey != null and macKey != 'all'">
         AND   h.mac_key = #{macKey}
         GROUP BY e.id
         ORDER BY avg
         ORDER BY avg desc
      </if>   
      <if test="macKey == 'all'">
         GROUP BY h.mac_key
@@ -287,10 +287,6 @@
         </foreach>
      </if>
      GROUP BY state
   </select>
   <select id="getMacLogByLast" resultType="string">
      SELECT mac_log FROM logger ORDER BY time DESC LIMIT 1
   </select>
   <select id="getSensorsAverageByEquipment" resultType="map">