大气质量监测模块修改

This commit is contained in:
2023-02-27 11:59:15 +08:00
parent d27dad982b
commit 41ad8eebc3
15 changed files with 422 additions and 14 deletions

View File

@ -37,6 +37,7 @@
<resultMap id="change_rate_ratio" type="com.ruoyi.system.domain_yada.entity.PmChangeRateRatioEntity">
<result property="id" column="id"/>
<result property="year" column="year"/>
<result property="region" column="region"/>
<result property="regionEn" column="region_en"/>
<result property="level" column="level"/>
@ -53,6 +54,26 @@
<result property="value" column="value"/>
</resultMap>
<resultMap id="province_average"
type="com.ruoyi.system.domain_yada.entity.PmYearAverageProvinceConcentrationEntity">
<result property="id" column="id"/>
<result property="year" column="year"/>
<result property="country" column="country"/>
<result property="province" column="province"/>
<result property="provinceEn" column="province_en"/>
<result property="value" column="value"/>
</resultMap>
<resultMap id="province_change_rate"
type="com.ruoyi.system.domain_yada.entity.PmProvinceChangeRateEntity">
<result property="id" column="id"/>
<result property="year" column="year"/>
<result property="country" column="country"/>
<result property="province" column="province"/>
<result property="provinceEn" column="province_en"/>
<result property="rate" column="rate"/>
</resultMap>
<select id="findByRegion" resultMap="year_average">
select id, year, region, region_en, value
from pm_year_average_concentration
@ -78,9 +99,10 @@
</select>
<select id="changeRateRatio" resultMap="change_rate_ratio">
select id, region, region_en, level, value
select id, year, region, region_en, level, value
from pm_change_rate_ratio
where region = #{region}
where year = #{year}
and region = #{region}
</select>
<select id="monthAverage" resultMap="month_average">
@ -89,4 +111,18 @@
where year = #{year}
and region = #{region}
</select>
<select id="provinceAverage" resultMap="province_average">
select id, year, country, province, province_en, cast (value as decimal (10, 2)) as value
from pm_year_province_average_concentration
where year = #{year}
and country = #{country}
</select>
<select id="provinceChangeRate" resultMap="province_change_rate">
select id, year, country, province, province_en, cast (rate as decimal (10, 2)) as rate
from pm_province_change_rate
where year = #{year}
and country = #{country}
</select>
</mapper>