Commit 982b2cdd authored by 麻笑宇's avatar 麻笑宇

特种设备bug修改

parent 11ce7833
......@@ -148,7 +148,7 @@
tzs_safety_problem_tracing
WHERE
governing_body_org_code LIKE concat ( #{orgCode}, '%' )
AND DATE_FORMAT ( problem_time, '%Y-%m' ) = #{time}
AND DATE_FORMAT ( problem_time, '%Y-%m-%d' ) >= #{time}
</select>
<select id="cylinderIssueMonthList" resultType="java.util.Map">
......
......@@ -318,13 +318,29 @@
</select>
<select id="useCountByOrgCode" resultType="java.lang.Long">
SELECT COUNT
( 1 )
SELECT SUM
( COUNT )
FROM
tzs_jg_use_registration T
WHERE
T.status = '已完成' and T.is_delete = 0
AND T.receive_company_org_code LIKE CONCAT ( #{orgCode}, '%' )
(
SELECT COUNT
( 1 )
FROM
tzs_jg_use_registration T
WHERE
T.status = '已完成'
AND T.is_delete = 0
AND T.receive_company_org_code LIKE CONCAT ( #{orgCode}, '%' ) UNION ALL
SELECT COUNT
( 1 )
FROM
tzs_jg_vehicle_information T,
privilege_company pc
WHERE
T.status = '已完成'
AND T.is_delete = 0
AND T.receive_company_code = pc.company_code
AND pc.org_code LIKE concat ( #{orgCode}, '%' )
)
</select>
<select id="over15yearsCount" resultType="java.lang.Long">
SELECT
......@@ -430,7 +446,8 @@
FROM
tzs_jg_installation_notice T
WHERE
install_start_date &gt;= #{time}
handle_date &gt;= #{time}
and notice_status != 6617
AND T.receive_company_org_code LIKE CONCAT ( #{orgCode}, '%' ) UNION ALL
SELECT
CONCAT ( T.city_name, T.county_name ) AS location,
......@@ -441,7 +458,8 @@
FROM
tzs_jg_maintain_notice T
WHERE
plan_date &gt;= #{time}
accept_date &gt;= #{time}
and notice_status != 6617
AND T.receive_company_org_code LIKE CONCAT ( #{orgCode}, '%' ) UNION ALL
SELECT
CONCAT ( T.city_name, T.county_name ) AS location,
......@@ -452,7 +470,8 @@
FROM
tzs_jg_reform_notice T
WHERE
plan_date &gt;= #{time}
accept_date &gt;= #{time}
and notice_status != 6617
AND T.receive_company_org_code LIKE CONCAT ( #{orgCode}, '%' ) UNION ALL
SELECT
CONCAT ( T.city_name, T.county_name ) AS location,
......@@ -463,7 +482,8 @@
FROM
tzs_jg_transfer_notice T
WHERE
plan_date &gt;= #{time}
handle_date &gt;= #{time}
and notice_status != 6617
AND T.receive_company_org_code LIKE CONCAT ( #{orgCode}, '%' )) A
ORDER BY A."constructionDate" DESC
</select>
......
......@@ -689,7 +689,7 @@ public class AQZSDPStatisticsServiceImpl {
if (orgCode == null) {
return new ArrayList<>(0);
}
String time = LocalDate.now().format(DateTimeFormatter.ofPattern("yyyy-MM"));
String time = LocalDate.now().minusDays(29).format(DateTimeFormatter.ofPattern("yyyy-MM-dd"));
return statisticsMapper.issueMonthList(orgCode, time);
}
......
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