Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
hg-smart
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
platform
hg-smart
Commits
f2ab9ba4
Commit
f2ab9ba4
authored
May 25, 2024
by
liuyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
2024-05-24 1.设备点检预警预警逻辑调整
2.设备保养逻辑调整
parent
bee2e13e
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
30 additions
and
31 deletions
+30
-31
HGSB006.xml
src/main/java/com/baosight/hggp/hg/sb/sql/HGSB006.xml
+3
-4
HGSB007.xml
src/main/java/com/baosight/hggp/hg/sb/sql/HGSB007.xml
+27
-27
No files found.
src/main/java/com/baosight/hggp/hg/sb/sql/HGSB006.xml
View file @
f2ab9ba4
...
...
@@ -171,7 +171,7 @@
join ${hggpSchema}.HGSB002 B on A.PARENT_ID = B.ID AND B.DELETE_FLAG = '0'
where 1 = 1
and PLAN_END_DATE
<
DATE_FORMAT(CURDATE(), '%Y%m%d')
AND TASK_STATUS = '0' AND B.PLAN_TYPE = '1'
AND
B.PLAN_STATUS = '1' and B.
TASK_STATUS = '0' AND B.PLAN_TYPE = '1'
<include
refid=
"authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
B.COMPANY_CODE = #companyCode#
...
...
@@ -214,9 +214,8 @@
<include
refid=
"column002"
/>
from ${hggpSchema}.HGSB002A A
join ${hggpSchema}.HGSB002 B on A.PARENT_ID = B.ID AND B.DELETE_FLAG = '0'
where 1 = 1
and PLAN_END_DATE
<
DATE_FORMAT(CURDATE(), '%Y%m%d')
AND TASK_STATUS = '0' AND B.PLAN_TYPE = '1'
where 1 = 1 and PLAN_END_DATE
<
DATE_FORMAT(CURDATE(), '%Y%m%d')
AND B.PLAN_STATUS = '1' AND TASK_STATUS = '0' AND B.PLAN_TYPE = '1'
<include
refid=
"authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
B.COMPANY_CODE = #companyCode#
...
...
src/main/java/com/baosight/hggp/hg/sb/sql/HGSB007.xml
View file @
f2ab9ba4
...
...
@@ -177,8 +177,8 @@
from ${hggpSchema}.HGSB002A A
join ${hggpSchema}.HGSB002 B on A.PARENT_ID = B.ID AND B.DELETE_FLAG = '0'
where 1 = 1
and
PLAN_END_DATE
<
DATE_FORMAT(CURDATE(), '%Y%m%d')
AND TASK_STATUS = '0' AND B.PLAN_TYPE = '2'
AND
PLAN_END_DATE
<
DATE_FORMAT(CURDATE(), '%Y%m%d')
AND
B.PLAN_STATUS = '1' AND
TASK_STATUS = '0' AND B.PLAN_TYPE = '2'
<include
refid=
"authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
B.COMPANY_CODE = #companyCode#
...
...
@@ -202,7 +202,7 @@
$orderBy$
</isNotEmpty>
<isEmpty
property=
"orderBy"
>
A.PLAN_
START_DATE desc, A.PLAN_END_DAT
E desc
A.PLAN_
END_DATE desc, A.PLAN_START_DATE desc, A.PLAN_COD
E desc
</isEmpty>
</dynamic>
</select>
...
...
@@ -211,30 +211,30 @@
SELECT
COUNT(*)
FROM (
SELECT
<include
refid=
"column001"
/>
FROM ${hggpSchema}.HGSB005A A
JOIN ${hggpSchema}.HGSB005 B ON A.PARENT_ID = B.ID AND B.DELETE_FLAG = '0' WHERE 1=1
<include
refid=
"authCondition"
/>
<include
refid=
"condition"
/>
UNION ALL
SELECT
<include
refid=
"column002"
/>
from ${hggpSchema}.HGSB002A A
join ${hggpSchema}.HGSB002 B on A.PARENT_ID = B.ID AND B.DELETE_FLAG = '0'
where 1 = 1
and PLAN_END_DATE
<
DATE_FORMAT(CURDATE(), '%Y%m%d')
AND TASK_STATUS = '0' AND B.PLAN_TYPE = '2'
<include
refid=
"authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
B.COMPANY_CODE = #companyCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyName"
>
B.COMPANY_NAME LIKE CONCAT('%', #companyName#, '%')
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"deviceName"
>
A.DEVICE_NAME LIKE CONCAT('%', #deviceName#, '%')
</isNotEmpty>
SELECT
<include
refid=
"column001"
/>
FROM ${hggpSchema}.HGSB005A A
JOIN ${hggpSchema}.HGSB005 B ON A.PARENT_ID = B.ID AND B.DELETE_FLAG = '0' WHERE 1=1
<include
refid=
"authCondition"
/>
<include
refid=
"condition"
/>
UNION ALL
SELECT
<include
refid=
"column002"
/>
from ${hggpSchema}.HGSB002A A
join ${hggpSchema}.HGSB002 B on A.PARENT_ID = B.ID AND B.DELETE_FLAG = '0'
where 1 = 1
and PLAN_END_DATE
<
DATE_FORMAT(CURDATE(), '%Y%m%d')
AND B.PLAN_STATUS = '1'
AND TASK_STATUS = '0' AND B.PLAN_TYPE = '2'
<include
refid=
"authCondition"
/>
<isNotEmpty
prepend=
" AND "
property=
"companyCode"
>
B.COMPANY_CODE = #companyCode#
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"companyName"
>
B.COMPANY_NAME LIKE CONCAT('%', #companyName#, '%')
</isNotEmpty>
<isNotEmpty
prepend=
" AND "
property=
"deviceName"
>
A.DEVICE_NAME LIKE CONCAT('%', #deviceName#, '%')
</isNotEmpty>
) A
WHERE 1=1
<isEqual
prepend=
" AND "
property=
"upkeepStatus"
compareValue=
"1"
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment