Commit f35cd88c authored by litengwei's avatar litengwei

脚本大小写修复

parent 1896f845
......@@ -227,27 +227,27 @@
</sql>
</changeSet>
<changeSet author="tb" id="tb-20211009-11">
<preConditions onFail="MARK_RAN">
<columnExists tableName="p_latent_danger" columnName="check_input_id"/>
</preConditions>
<comment>p_latent_danger CHANGE COLUMN check_input_id to biz_id '创建隐患的业务数据主键id'</comment>
<sql>
ALTER TABLE p_latent_danger CHANGE COLUMN `check_input_id` `biz_id` bigint(20) DEFAULT NULL COMMENT '创建隐患的业务数据主键id';
</sql>
</changeSet>
<!-- <changeSet author="tb" id="tb-20211009-11">-->
<!-- <preConditions onFail="MARK_RAN">-->
<!-- <columnExists tableName="p_latent_danger" columnName="check_input_id"/>-->
<!-- </preConditions>-->
<!-- <comment>p_latent_danger CHANGE COLUMN check_input_id to biz_id '创建隐患的业务数据主键id'</comment>-->
<!-- <sql>-->
<!-- ALTER TABLE p_latent_danger CHANGE COLUMN `check_input_id` `biz_id` bigint(20) DEFAULT NULL COMMENT '创建隐患的业务数据主键id';-->
<!-- </sql>-->
<!-- </changeSet>-->
<changeSet author="tb" id="tb-20211009-12">
<preConditions onFail="MARK_RAN">
<not>
<columnExists tableName="p_latent_danger" columnName="biz_info"/>
</not>
</preConditions>
<comment>p_latent_danger add COLUMN biz_info '业务信息'</comment>
<sql>
ALTER TABLE p_latent_danger add COLUMN `biz_info` varchar(500) DEFAULT NULL COMMENT '业务信息';
</sql>
</changeSet>
<!-- <changeSet author="tb" id="tb-20211009-12">-->
<!-- <preConditions onFail="MARK_RAN">-->
<!-- <not>-->
<!-- <columnExists tableName="p_latent_danger" columnName="biz_info"/>-->
<!-- </not>-->
<!-- </preConditions>-->
<!-- <comment>p_latent_danger add COLUMN biz_info '业务信息'</comment>-->
<!-- <sql>-->
<!-- ALTER TABLE p_latent_danger add COLUMN `biz_info` varchar(500) DEFAULT NULL COMMENT '业务信息';-->
<!-- </sql>-->
<!-- </changeSet>-->
<changeSet author="tb" id="tb-20211009-13">
<preConditions onFail="MARK_RAN">
......
......@@ -835,8 +835,8 @@
SELECT
count( 1 )
FROM
P_PLAN_TASK ppt
RIGHT JOIN P_PLAN_TASK_DETAIL pptd ON ppt.ID = pptd.TASK_NO
p_plan_task ppt
RIGHT JOIN p_plan_task_detail pptd ON ppt.ID = pptd.TASK_NO
WHERE
ppt.org_code LIKE CONCAT( #{orgCode}, '%' ) and t_date.checkDate BETWEEN DATE_FORMAT( ppt.BEGIN_TIME, '%Y-%m-%d' )
AND DATE_FORMAT( ppt.END_TIME, '%Y-%m-%d' )
......@@ -845,7 +845,7 @@
SELECT
count( 1 )
FROM
P_CHECK pc
p_check pc
WHERE
pc.org_code LIKE CONCAT( #{orgCode}, '%' ) and
DATE_FORMAT( pc.CHECK_TIME, '%Y-%m-%d' ) = t_date.checkDate
......@@ -855,7 +855,7 @@
SELECT
count( 1 )
FROM
P_CHECK pc
p_check pc
WHERE
pc.org_code LIKE CONCAT( #{orgCode}, '%' ) and
DATE_FORMAT( pc.CHECK_TIME, '%Y-%m-%d' ) = t_date.checkDate
......@@ -894,15 +894,15 @@
<select id="getCountMonthChkNew" resultType="java.util.HashMap">
SELECT
T_DATE.checkDate
t_date.checkDate
, (
SELECT count(1) FROM P_PLAN_TASK ppt RIGHT JOIN P_PLAN_TASK_DETAIL pptd ON ppt.ID = pptd.TASK_NO WHERE t_date.checkDate BETWEEN DATE_FORMAT(ppt .BEGIN_TIME, '%Y-%m-%d') AND DATE_FORMAT(ppt .END_TIME , '%Y-%m-%d')
SELECT count(1) FROM p_plan_task ppt RIGHT JOIN p_plan_task_detail pptd ON ppt.ID = pptd.TASK_NO WHERE t_date.checkDate BETWEEN DATE_FORMAT(ppt .BEGIN_TIME, '%Y-%m-%d') AND DATE_FORMAT(ppt .END_TIME , '%Y-%m-%d')
) AS proNum
, (
SELECT
count(1)
FROM
P_CHECK pc
p_check pc
WHERE
DATE_FORMAT(pc.CHECK_TIME, '%Y-%m-%d') = t_date.checkDate
AND pc.IS_OK = 3
......@@ -911,10 +911,10 @@
SELECT
count(1)
FROM
P_CHECK pc
p_check pc
WHERE
DATE_FORMAT(pc.CHECK_TIME, '%Y-%m-%d') = t_date.checkDate
AND pc.IS_OK != 3
AND pc.is_ok != 3
) AS actualNum
FROM
(
......
......@@ -523,12 +523,12 @@
<!-- 巡检执行情况统计分页用 -->
<select id="countChkExListData" resultType="long">
select
count(A.ID) total_num
count(a.id) total_num
from
p_plan_task a,
p_plan b
<!-- s_user c -->
WHERE <!-- A.USER_ID = C.ID AND --> A.PLAN_ID = B.ID
WHERE <!-- A.USER_ID = C.ID AND --> a.plan_id = b.id
<if test="checkDate!=null"> and date_format(a.begin_time, '%Y%m%d') <![CDATA[<=]]> #{checkDate} and date_format(a.end_time, '%Y%m%d') >= #{checkDate}</if>
<if test="orgCode != null and orgCode !=''" >
And (a.org_code LIKE CONCAT( #{orgCode}, '-%' ) or a.org_code= #{orgCode} )
......@@ -538,12 +538,12 @@
<!-- 巡检执行情况统计分页用 -->
<select id="countChkExListDataNew" resultType="long">
select
count(A.ID) total_num
count(a.id) total_num
from
p_plan_task a,
p_plan b
<!-- s_user c -->
WHERE <!-- A.USER_ID = C.ID AND --> A.PLAN_ID = B.ID
WHERE <!-- A.USER_ID = C.ID AND --> a.plan_id = b.id
<if test="checkDate!=null"> and date_format(a.begin_time, '%Y%m%d') <![CDATA[<=]]> #{checkDate} and date_format(a.end_time, '%Y%m%d') >= #{checkDate}</if>
<if test="orgCode != null and orgCode !=''" >
And a.org_code LIKE CONCAT( #{orgCode}, '%' )
......@@ -568,7 +568,7 @@
p_plan_task a,
p_plan b
<!-- s_user c -->
WHERE <!-- A.USER_ID = C.ID AND --> A.PLAN_ID = B.ID
WHERE <!-- A.USER_ID = C.ID AND --> a.plan_id = b.id
<if test="checkDate!=null"> and date_format(a.begin_time, '%Y%m%d') <![CDATA[<=]]> #{checkDate} and date_format(a.end_time, '%Y%m%d') >= #{checkDate}</if>
<if test="orgCode != null and orgCode !=''" >
And (a.org_code LIKE CONCAT( #{orgCode}, '-%' ) or a.org_code= #{orgCode} )
......@@ -606,7 +606,7 @@
from
p_plan_task a,
p_plan b
WHERE A.PLAN_ID = B.ID
WHERE a.plan_id = b.id
<if test="checkDate!=null"> and date_format(a.begin_time, '%Y%m%d') <![CDATA[<=]]> #{checkDate} and date_format(a.end_time, '%Y%m%d') >= #{checkDate}</if>
<if test="orgCode != null and orgCode !=''" >
And a.org_code LIKE CONCAT( #{orgCode}, '%' )
......
......@@ -483,7 +483,7 @@
<if test="orgCode!=null">
and (org_code LIKE CONCAT( #{orgCode}, '-%' ) or org_code= #{orgCode} )
</if>
) VP
) vp
) tt group by tt.RealTimeStatus,tt.status order by status
</select>
<!-- 巡检点统计 -->
......@@ -505,7 +505,7 @@
and (org_code LIKE CONCAT( #{orgCode}, '-%' ) or org_code= #{orgCode} )
</if>
</where>
) VP
) vp
) tt group by tt.RealTimeStatus,tt.status order by status
</select>
......@@ -530,7 +530,7 @@
<if test="orgCode!=null">
and biz_org_code LIKE CONCAT( #{orgCode}, '%' )
</if>
) VP
) vp
) tt group by tt.RealTimeStatus,tt.status order by status
</select>
......@@ -613,7 +613,7 @@
'合格'
END AS STATUS,
DATE_FORMAT(
P.check_Time,
p.check_time,
'%Y-%m-%d %H:%i:%s'
) checkTime,
p.error errorMsg
......@@ -676,12 +676,12 @@
'合格'
END AS STATUS,
DATE_FORMAT(
P.check_Time,
p.check_time,
'%Y-%m-%d %H:%i:%s'
) checkTime,
p.error errorMsg
FROM p_point p
LEFT JOIN p_Catalog_Tree ct ON ct.ID = p.Catalog_ID
LEFT JOIN p_catalog_tree ct ON ct.ID = p.Catalog_ID
<!-- LEFT JOIN s_department sd ON sd.id = p.charge_dept_id
LEFT JOIN s_user su ON su.id = p.charge_person_id -->
where p.is_delete = 0
......@@ -730,7 +730,7 @@
'合格'
END AS STATUS
FROM p_point p
LEFT JOIN p_Catalog_Tree ct ON ct.ID = p.Catalog_ID
LEFT JOIN p_catalog_tree ct ON ct.ID = p.Catalog_ID
<!-- LEFT JOIN s_department sd ON sd.id = p.charge_dept_id
LEFT JOIN s_user su ON su.id = p.charge_person_id -->
<trim prefix="WHERE" prefixOverrides="AND ">
......
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