Commit 32afc535 authored by 耿迪迪's avatar 耿迪迪

二道门车辆进出类型修改 gengdidi

parent 5b10239d
...@@ -12,11 +12,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -12,11 +12,15 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<resultMap id="statisticsImportVehicleResult" type="HashMap"> <resultMap id="statisticsImportVehicleResult" type="HashMap">
<result property="plateNumber" column="plateNumber" jdbcType="VARCHAR" /> <result property="plateNumber" column="plateNumber" jdbcType="VARCHAR" />
<result property="inParkTime" column="InParkTime" jdbcType="DATE"/> <result property="inParkTime" column="InParkTime" jdbcType="DATE"/>
<result property="cName" column="cName" jdbcType="VARCHAR"/>
<result property="inParkControlImageName" column="InParkControlImageName" jdbcType="VARCHAR"/>
</resultMap> </resultMap>
<resultMap id="statisticsExportVehicleResult" type="HashMap"> <resultMap id="statisticsExportVehicleResult" type="HashMap">
<result property="plateNumber" column="plateNumber" jdbcType="VARCHAR" /> <result property="plateNumber" column="plateNumber" jdbcType="VARCHAR" />
<result property="outParkTime" column="OutParkTime" jdbcType="DATE"/> <result property="outParkTime" column="OutParkTime" jdbcType="DATE"/>
<result property="cName" column="cName" jdbcType="VARCHAR"/>
<result property="inParkControlImageName" column="InParkControlImageName" jdbcType="VARCHAR"/>
</resultMap> </resultMap>
<select id="statisticsVehicleByActionType" resultMap="statisticsVehicleByActionTypeResult"> <select id="statisticsVehicleByActionType" resultMap="statisticsVehicleByActionTypeResult">
...@@ -39,8 +43,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -39,8 +43,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<select id="statisticsStayInVehicles" resultMap="statisticsImportVehicleResult"> <select id="statisticsStayInVehicles" resultMap="statisticsImportVehicleResult">
SELECT SELECT
plateNumber, stay.plateNumber,
InParkTime stay.InParkTime,
type.cName
FROM( FROM(
SELECT SELECT
plateNumber, plateNumber,
...@@ -50,27 +55,31 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" ...@@ -50,27 +55,31 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
Sys_Park_OutParkRecords Sys_Park_OutParkRecords
GROUP BY plateNumber GROUP BY plateNumber
)stay )stay
LEFT JOIN Sys_Park_OutParkRecords records ON stay.InParkTime = records.InParkTime AND stay.plateNumber = records.plateNumber
LEFT JOIN V_Park_PlateType type ON records.plateType = type.id
WHERE ISNULL(DATEDIFF(S, '1970-01-01 00:00:00', stay.InParkTime),0) - ISNULL(DATEDIFF(S, '1970-01-01 00:00:00', stay.OutParkTime),0) >0 WHERE ISNULL(DATEDIFF(S, '1970-01-01 00:00:00', stay.InParkTime),0) - ISNULL(DATEDIFF(S, '1970-01-01 00:00:00', stay.OutParkTime),0) >0
</select> </select>
<select id="lastImportData" resultMap="statisticsImportVehicleResult"> <select id="lastImportData" resultMap="statisticsImportVehicleResult">
SELECT SELECT
TOP 1 plateNumber,InParkTime TOP 1 records.plateNumber,records.InParkTime,type.cName,records.InParkControlImageName
FROM FROM
Sys_Park_OutParkRecords Sys_Park_OutParkRecords records
LEFT JOIN V_Park_PlateType type ON records.plateType = type.id
WHERE WHERE
InParkTime IS NOT NULL records.InParkTime IS NOT NULL
ORDER BY InParkTime DESC ORDER BY records.InParkTime DESC
</select> </select>
<select id="lastExportData" resultMap="statisticsExportVehicleResult"> <select id="lastExportData" resultMap="statisticsExportVehicleResult">
SELECT SELECT
TOP 1 plateNumber,OutParkTime TOP 1 records.plateNumber,records.OutParkTime,type.cName,records.InParkControlImageName
FROM FROM
Sys_Park_OutParkRecords Sys_Park_OutParkRecords records
LEFT JOIN V_Park_PlateType type ON records.plateType = type.id
WHERE WHERE
OutParkTime IS NOT NULL records.OutParkTime IS NOT NULL
ORDER BY OutParkTime DESC ORDER BY records.OutParkTime DESC
</select> </select>
</mapper> </mapper>
\ No newline at end of file
...@@ -112,7 +112,7 @@ ...@@ -112,7 +112,7 @@
<div class="ent-div"></div> <div class="ent-div"></div>
<div class="ent-b-in"> <div class="ent-b-in">
<img src="../../assets/img/car.png" alt=""> <img src="../../assets/img/car.png" alt="">
<div>车辆类型:<span></span> </div> <div>车辆类型:<span></span>{{lastImportCarData ? lastImportCarData.cName : "-"}}</div>
<div>车辆号牌:<span>{{lastImportCarData?lastImportCarData.plateNumber:"-"}}</span> </div> <div>车辆号牌:<span>{{lastImportCarData?lastImportCarData.plateNumber:"-"}}</span> </div>
<div>入场时间:<span>{{lastImportCarData?changeDateFormat(lastImportCarData.inParkTime):"-"}}</span> </div> <div>入场时间:<span>{{lastImportCarData?changeDateFormat(lastImportCarData.inParkTime):"-"}}</span> </div>
</div> </div>
...@@ -125,7 +125,7 @@ ...@@ -125,7 +125,7 @@
<div class="ent-div"></div> <div class="ent-div"></div>
<div class="ent-b-in"> <div class="ent-b-in">
<img src="../../assets/img/car.png" alt=""> <img src="../../assets/img/car.png" alt="">
<div>车辆类型:<span></span> </div> <div>车辆类型:<span></span>{{lastExportCarData ? lastExportCarData.cName : "-"}}</div>
<div>车辆号牌:<span>{{lastExportCarData?lastExportCarData.plateNumber:"-"}}</span> </div> <div>车辆号牌:<span>{{lastExportCarData?lastExportCarData.plateNumber:"-"}}</span> </div>
<div>入场时间:<span>{{lastExportCarData?changeDateFormat(lastExportCarData.outParkTime):"-"}}</span> </div> <div>入场时间:<span>{{lastExportCarData?changeDateFormat(lastExportCarData.outParkTime):"-"}}</span> </div>
</div> </div>
...@@ -145,7 +145,7 @@ ...@@ -145,7 +145,7 @@
width="170"> width="170">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="name" prop="cName"
label="类型"> label="类型">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
......
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