From a022ae9804d0c2f402711b6b5202319d853919cf Mon Sep 17 00:00:00 2001
From: cjl <909710561@qq.com>
Date: Fri, 09 Aug 2024 13:38:47 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/dev' into cjl

---
 screen-job/src/main/resources/mapper/HistorySecondCruiserMapper.xml |   33 +++++++++++++++++++++++++++++++++
 1 files changed, 33 insertions(+), 0 deletions(-)

diff --git a/screen-job/src/main/resources/mapper/HistorySecondCruiserMapper.xml b/screen-job/src/main/resources/mapper/HistorySecondCruiserMapper.xml
new file mode 100644
index 0000000..851ed0d
--- /dev/null
+++ b/screen-job/src/main/resources/mapper/HistorySecondCruiserMapper.xml
@@ -0,0 +1,33 @@
+<?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.moral.api.mapper.HistorySecondCruiserMapper">
+
+    <!-- ������������������������ -->
+    <resultMap id="BaseResultMap" type="com.moral.api.entity.HistorySecondCruiser">
+        <result column="mac" property="mac"/>
+        <result column="time" property="time"/>
+        <result column="value" property="value"/>
+        <result column="organization_id" property="organizationId"/>
+        <result column="batch" property="batch"/>
+    </resultMap>
+
+
+    <select id="getDusts" resultType="java.util.Map">
+        SELECT
+            value ->>'$.flylat' as flyLat,value ->>'$.flylon' as flyLon,value ->>'$.dustld' as dustld,
+            `time`
+        FROM `history_second_cruiser`
+        WHERE mac = #{mac}
+          AND `time` <![CDATA[>=]]> #{startTime}
+          AND `time` <![CDATA[<]]> #{endTime}
+    </select>
+
+    <select id="getResult" resultType="com.moral.api.entity.HistorySecondCruiser">
+        SELECT
+            distinct mac,organization_id
+        FROM `history_second_cruiser`
+        WHERE
+           `time` <![CDATA[>=]]> #{startTime}
+          AND `time` <![CDATA[<=]]> #{endTime}
+    </select>
+</mapper>
\ No newline at end of file

--
Gitblit v1.8.0