Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
gf_back
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
tianchao
gf_back
Commits
79854b6f
Commit
79854b6f
authored
Dec 17, 2024
by
ZWT
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
得到的
parent
7e690066
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
17 deletions
+13
-17
C11-space/pps-core-space/src/main/java/pps/core/space/service/SpaceOptimizeBaseService.java
...java/pps/core/space/service/SpaceOptimizeBaseService.java
+6
-6
C12-prediction/pps-core-prediction/src/main/resources/mybatis/mapper/pps/core/prediction/PredictedPowerViewMapper.xml
...s/mapper/pps/core/prediction/PredictedPowerViewMapper.xml
+7
-11
No files found.
C11-space/pps-core-space/src/main/java/pps/core/space/service/SpaceOptimizeBaseService.java
View file @
79854b6f
...
@@ -109,18 +109,18 @@ public class SpaceOptimizeBaseService {
...
@@ -109,18 +109,18 @@ public class SpaceOptimizeBaseService {
int
month
=
startDate
.
monthBaseOne
();
int
month
=
startDate
.
monthBaseOne
();
//查井口配置时间段
//查井口配置时间段
SpaceInstitutionDurationMapper
durationMapper
=
context
.
getBean
(
SpaceInstitutionDurationMapper
.
class
);
SpaceInstitutionDurationMapper
durationMapper
=
context
.
getBean
(
SpaceInstitutionDurationMapper
.
class
);
List
<
SpaceInstitutionDurationEnt
>
durationList
=
durationMapper
.
selectList
(
new
QueryWrapper
<
SpaceInstitutionDurationEnt
>()
List
<
SpaceInstitutionDurationEnt
>
durationList
=
durationMapper
.
selectList
(
new
LambdaQueryWrapper
<
SpaceInstitutionDurationEnt
>()
.
select
(
"*"
,
"STR_TO_DATE( CONCAT( open_well_time, ':00' ), '%H:%i:%s' ) AS openTime"
,
"STR_TO_DATE( CONCAT( close_well_time, ':00' ), '%H:%i:%s' ) AS closeTime"
)
.
lambda
()
.
eq
(
BaseModel:
:
getIsDeleted
,
BusinessConstant
.
ONE
)
.
eq
(
BaseModel:
:
getIsDeleted
,
BusinessConstant
.
ONE
)
.
in
(
SpaceInstitutionDurationEnt:
:
getWellheadId
,
spaceWellheadList
.
stream
().
map
(
SpaceInstitutionWellheadView:
:
getWellheadId
).
collect
(
Collectors
.
toList
()))
.
in
(
SpaceInstitutionDurationEnt:
:
getWellheadId
,
spaceWellheadList
.
stream
().
map
(
SpaceInstitutionWellheadView:
:
getWellheadId
).
collect
(
Collectors
.
toList
()))
.
orderByAsc
(
SpaceInstitutionDurationEnt:
:
getOpenWellTime
)
.
orderByAsc
(
SpaceInstitutionDurationEnt:
:
getOpenWellTime
)
);
);
if
(
CollUtil
.
isEmpty
(
durationList
))
{
if
(
CollUtil
.
isEmpty
(
durationList
))
{
throw
new
XServiceException
(
BusinessError
.
DidNotFindCalibration
);
throw
new
XServiceException
(
BusinessError
.
DidNotFindCalibration
);
}
else
{
for
(
SpaceInstitutionDurationEnt
ent
:
durationList
)
{
ent
.
setOpenTime
(
BaseUtils
.
strToDateTime
(
ent
.
getOpenWellTime
()));
ent
.
setCloseTime
(
BaseUtils
.
strToDateTime
(
ent
.
getCloseWellTime
()));
}
}
}
//间开制度ID/井口LIST Map
//间开制度ID/井口LIST Map
Map
<
String
,
List
<
SpaceInstitutionWellheadView
>>
wellheadMap
=
spaceWellheadList
.
stream
()
Map
<
String
,
List
<
SpaceInstitutionWellheadView
>>
wellheadMap
=
spaceWellheadList
.
stream
()
...
...
C12-prediction/pps-core-prediction/src/main/resources/mybatis/mapper/pps/core/prediction/PredictedPowerViewMapper.xml
View file @
79854b6f
...
@@ -360,11 +360,8 @@
...
@@ -360,11 +360,8 @@
</when>
</when>
<otherwise>
<otherwise>
CASE
CASE
MINUTE ( DATA_DATE )
WHEN EXTRACT( MINUTE FROM CAST( TO_DATE( DATA_DATE, 'YYYY-MM-DD HH24:MI:SS' ) AS TIMESTAMP ) ) IN ( 15, 45 ) THEN
WHEN 15 THEN
TO_DATE( DATA_DATE, 'YYYY-MM-DD HH24:MI:SS' ) - NUMTODSINTERVAL( 15, 'MINUTE' ) ELSE TO_DATE( DATA_DATE, 'YYYY-MM-DD HH24:MI:SS' )
DATE_SUB( DATA_DATE, INTERVAL 15 MINUTE )
WHEN 45 THEN
DATE_SUB( DATA_DATE, INTERVAL 15 MINUTE ) ELSE DATA_DATE
END
END
</otherwise>
</otherwise>
</choose>
</choose>
...
@@ -412,7 +409,7 @@
...
@@ -412,7 +409,7 @@
END
END
</otherwise>
</otherwise>
</choose>
</choose>
, '
%H:%i:%s
' ) AS CREATE_TIME
, '
HH24:MI:SS
' ) AS CREATE_TIME
FROM
FROM
PLANT_PREDICTED_POWER_SHORT_TERM
PLANT_PREDICTED_POWER_SHORT_TERM
WHERE
WHERE
...
@@ -448,11 +445,10 @@
...
@@ -448,11 +445,10 @@
</when>
</when>
<otherwise>
<otherwise>
CASE
CASE
MINUTE ( DATA_DATE )
WHEN EXTRACT( MINUTE FROM CAST( TO_DATE( DATA_DATE, 'YYYY-MM-DD HH24:MI:SS' ) AS TIMESTAMP ) ) IN ( 15,
WHEN 15 THEN
45 ) THEN
DATE_SUB( DATA_DATE, INTERVAL 15 MINUTE )
TO_DATE( DATA_DATE, 'YYYY-MM-DD HH24:MI:SS' ) - NUMTODSINTERVAL( 15, 'MINUTE' ) ELSE TO_DATE( DATA_DATE,
WHEN 45 THEN
'YYYY-MM-DD HH24:MI:SS' )
DATE_SUB( DATA_DATE, INTERVAL 15 MINUTE ) ELSE DATA_DATE
END
END
</otherwise>
</otherwise>
</choose>
</choose>
...
...
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