Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
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
项目统一框架
amos-boot-biz
Commits
0bba82c3
Commit
0bba82c3
authored
Dec 13, 2023
by
zhangsen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
数据源添加,跳转业务添加
根据热工院提供 根据kks码判断设备类型
parent
0063426a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
12 deletions
+21
-12
PointSystemServiceImpl.java
...n/amos/api/alarm/service/impl/PointSystemServiceImpl.java
+21
-12
No files found.
amos-boot-data/amos-boot-data-alarm/src/main/java/com/yeejoin/amos/api/alarm/service/impl/PointSystemServiceImpl.java
View file @
0bba82c3
...
...
@@ -5,6 +5,7 @@ import com.alibaba.fastjson.JSONArray;
import
com.alibaba.fastjson.JSONObject
;
import
com.baomidou.mybatisplus.core.conditions.query.QueryWrapper
;
import
com.baomidou.mybatisplus.extension.service.impl.ServiceImpl
;
import
com.github.xiaoymin.knife4j.core.util.StrUtil
;
import
com.yeejoin.amos.api.alarm.dto.DynamicDetails
;
import
com.yeejoin.amos.api.alarm.dto.TabContent
;
import
com.yeejoin.amos.api.alarm.dto.WarningDto
;
...
...
@@ -25,8 +26,9 @@ import org.typroject.tyboot.component.emq.EmqKeeper;
import
java.text.SimpleDateFormat
;
import
java.util.*
;
import
java.util.stream.Collectors
;
/**
/**
* @description:
* @author: tw
* @createDate: 2023/6/19
...
...
@@ -52,18 +54,25 @@ public class PointSystemServiceImpl extends ServiceImpl<PointSystemMapper, Point
@Autowired
private
JumpConfigMapper
jumpConfigMapper
;
public
String
getJumpUrlByInfo
(
String
objectName
)
{
public
String
getJumpUrlByInfo
(
String
sbbm
)
{
List
<
JumpConfig
>
jumpConfigs
=
jumpConfigMapper
.
selectList
(
null
);
String
jumpUrl
=
null
;
for
(
JumpConfig
jumpConfig
:
jumpConfigs
)
{
if
(
jumpConfig
.
getType
().
equals
(
"默认"
))
{
jumpUrl
=
jumpConfig
.
getUrl
();
}
if
(
objectName
.
contains
(
jumpConfig
.
getType
()))
{
return
jumpConfig
.
getUrl
();
}
Map
<
String
,
String
>
collect
=
jumpConfigs
.
stream
().
collect
(
Collectors
.
toMap
(
JumpConfig:
:
getType
,
JumpConfig:
:
getUrl
));
if
(
StringUtils
.
isEmpty
(
sbbm
))
{
return
""
;
}
if
(
sbbm
.
indexOf
(
"BAT"
)
!=
-
1
)
{
return
collect
.
get
(
"箱变"
);
}
else
if
(
sbbm
.
indexOf
(
"WG"
)
!=
-
1
)
{
return
collect
.
get
(
"汇流箱"
);
}
else
if
(
sbbm
.
indexOf
(
"WC"
)
!=
-
1
)
{
return
collect
.
get
(
"逆变器"
);
}
else
if
(
sbbm
.
length
()
==
12
&&
sbbm
.
indexOf
(
"MD"
)
!=
-
1
)
{
return
collect
.
get
(
"风机"
);
}
else
if
(
sbbm
.
length
()
>
12
&&
sbbm
.
indexOf
(
"MD"
)
!=
-
1
)
{
return
collect
.
get
(
"风机子系统"
);
}
else
{
return
collect
.
get
(
"默认"
);
}
return
jumpUrl
;
}
@Async
(
"equipAsyncExecutor"
)
...
...
@@ -154,7 +163,7 @@ public class PointSystemServiceImpl extends ServiceImpl<PointSystemMapper, Point
time
,
(
String
)
eqdata
.
get
(
"kksms"
),
"equip"
,
getJumpUrlByInfo
(
(
String
)
eqdata
.
get
(
"kksms"
)
)
getJumpUrlByInfo
(
warningObjectCode
)
);
return
WarningDto
;
...
...
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