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
6800ed31
Commit
6800ed31
authored
Dec 09, 2024
by
ZWT
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
得到的
parent
3895a61d
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
30 additions
and
3 deletions
+30
-3
C09-base/pps-core-base/src/main/java/pps/core/base/service/ExcelService.java
...ase/src/main/java/pps/core/base/service/ExcelService.java
+5
-2
C09-base/pps-core-base/src/main/resources/mybatis/mapper/pps/core/base/BasePriceStrategyDetailViewMapper.xml
...apper/pps/core/base/BasePriceStrategyDetailViewMapper.xml
+25
-1
No files found.
C09-base/pps-core-base/src/main/java/pps/core/base/service/ExcelService.java
View file @
6800ed31
...
...
@@ -593,6 +593,11 @@ public class ExcelService {
@XText
(
"市电峰谷配置导入"
)
@XApiUpload
public
XServiceResult
importPriceStrategy
(
XContext
context
,
ImportPriceStrategyExcelInput
input
)
{
//封装数据
String
strategyId
=
input
.
getStrategyId
();
if
(
CharSequenceUtil
.
isBlank
(
strategyId
)
||
CharSequenceUtil
.
equals
(
"undefined"
,
strategyId
))
{
return
XServiceResult
.
OK
;
}
List
<
ExcelPriceStrategyTemplate
>
list
=
EasyExcelUtil
.
getExcelDataAndCheck
(
input
.
getFile
(),
ExcelPriceStrategyTemplate
.
class
,
null
,
null
);
if
(
CollUtil
.
isEmpty
(
list
))
{
...
...
@@ -649,8 +654,6 @@ public class ExcelService {
if
(
stringBuilder
.
length
()
>
0
)
{
throw
new
XServiceException
(
stringBuilder
.
toString
());
}
//封装数据
String
strategyId
=
input
.
getStrategyId
();
PpsUserSession
session
=
context
.
getSession
(
PpsUserSession
.
class
);
Map
<
String
,
String
>
dictMap
=
ServiceUtil
.
getDictionaryList
(
context
,
BusinessConstant
.
TIME_FRAME
).
stream
()
.
collect
(
Collectors
.
toMap
(
GetSysDictionaryViewOutput:
:
getDicName
,
GetSysDictionaryViewOutput:
:
getDicKey
));
...
...
C09-base/pps-core-base/src/main/resources/mybatis/mapper/pps/core/base/BasePriceStrategyDetailViewMapper.xml
View file @
6800ed31
...
...
@@ -137,7 +137,7 @@
</insert>
<select
id=
"selectDetailList"
parameterType=
"pps.core.base.entity.BasePriceStrategyDetailView"
resultMap=
"BaseResultMap"
>
resultMap=
"BaseResultMap"
databaseId=
"MySQL"
>
SELECT D.STRATEGY_MONTH,
D.PERIOD_TYPE_KEY,
D.START_TIME,
...
...
@@ -158,4 +158,28 @@
ORDER BY CAST(M.STRATEGY_MONTH AS SIGNED INTEGER),
D.START_TIME
</select>
<select
id=
"selectDetailList"
parameterType=
"pps.core.base.entity.BasePriceStrategyDetailView"
resultMap=
"BaseResultMap"
databaseId=
"Oracle"
>
SELECT D.STRATEGY_MONTH,
D.PERIOD_TYPE_KEY,
D.START_TIME,
D.END_TIME,
D.ELECTROVALENCE
FROM BASE_PRICE_STRATEGY_MONTH M
LEFT JOIN BASE_PRICE_STRATEGY_DETAIL D ON M.STRATEGY_MONTH = D.STRATEGY_MONTH
AND M.STRATEGY_ID = D.STRATEGY_ID
WHERE M.IS_DELETED = 1
AND D.IS_DELETED = 1
AND M.STRATEGY_ID = #{strategyId}
<if
test=
"monthList != null and monthList.size() > 0"
>
AND M.STRATEGY_MONTH IN
<foreach
collection=
"monthList"
item=
"item"
open=
"("
close=
")"
separator=
","
>
#{item}
</foreach>
</if>
ORDER BY
TO_NUMBER( M.STRATEGY_MONTH ),
D.START_TIME
</select>
</mapper>
\ No newline at end of file
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