Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
Y
YeeAmosFireAutoSysRoot
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
station
YeeAmosFireAutoSysRoot
Commits
2a8b4994
Commit
2a8b4994
authored
May 13, 2020
by
单奇雲
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
调试接口
parent
84e09ca1
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
73 additions
and
24 deletions
+73
-24
RiskSource.java
...main/java/com/yeejoin/amos/fas/dao/entity/RiskSource.java
+22
-0
BasePointPositionBo.java
...com/yeejoin/amos/fas/business/bo/BasePointPositionBo.java
+17
-0
View3dController.java
...eejoin/amos/fas/business/controller/View3dController.java
+2
-0
View3dMapper.java
...om/yeejoin/amos/fas/business/dao/mapper/View3dMapper.java
+2
-2
View3dServiceImpl.java
...oin/amos/fas/business/service/impl/View3dServiceImpl.java
+8
-2
dbTemplate_risk_source.xml
...t/src/main/resources/db/mapper/dbTemplate_risk_source.xml
+4
-3
dbTemplate_view3d.xml
...sStart/src/main/resources/db/mapper/dbTemplate_view3d.xml
+18
-17
No files found.
YeeAmosFireAutoSysCommon/src/main/java/com/yeejoin/amos/fas/dao/entity/RiskSource.java
View file @
2a8b4994
...
@@ -71,6 +71,12 @@ public class RiskSource extends BasicEntity {
...
@@ -71,6 +71,12 @@ public class RiskSource extends BasicEntity {
*/
*/
@Lob
@Lob
private
String
ue4Extent
;
private
String
ue4Extent
;
/**
* 区域路径
*/
@Lob
private
String
routePath
;
private
List
<
Fmea
>
fmeaList
;
private
List
<
Fmea
>
fmeaList
;
...
@@ -247,4 +253,19 @@ public class RiskSource extends BasicEntity {
...
@@ -247,4 +253,19 @@ public class RiskSource extends BasicEntity {
this
.
ue4Extent
=
ue4Extent
;
this
.
ue4Extent
=
ue4Extent
;
}
}
/**
* @return the routePath
*/
@Column
(
name
=
"route_path"
)
public
String
getRoutePath
()
{
return
routePath
;
}
/**
* @param routePath the routePath to set
*/
public
void
setRoutePath
(
String
routePath
)
{
this
.
routePath
=
routePath
;
}
}
}
\ No newline at end of file
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/bo/BasePointPositionBo.java
View file @
2a8b4994
...
@@ -29,6 +29,9 @@ public class BasePointPositionBo {
...
@@ -29,6 +29,9 @@ public class BasePointPositionBo {
*/
*/
@ApiModelProperty
(
"3d点坐标,非ue4用"
)
@ApiModelProperty
(
"3d点坐标,非ue4用"
)
private
String
position3d
;
private
String
position3d
;
@ApiModelProperty
(
"区域坐标,非ue4用"
)
private
String
routePath
;
public
String
getUe4Location
()
{
public
String
getUe4Location
()
{
return
ue4Location
;
return
ue4Location
;
...
@@ -61,4 +64,18 @@ public class BasePointPositionBo {
...
@@ -61,4 +64,18 @@ public class BasePointPositionBo {
public
void
setPosition3d
(
String
position3d
)
{
public
void
setPosition3d
(
String
position3d
)
{
this
.
position3d
=
position3d
;
this
.
position3d
=
position3d
;
}
}
/**
* @return the routePath
*/
public
String
getRoutePath
()
{
return
routePath
;
}
/**
* @param routePath the routePath to set
*/
public
void
setRoutePath
(
String
routePath
)
{
this
.
routePath
=
routePath
;
}
}
}
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/controller/View3dController.java
View file @
2a8b4994
...
@@ -150,6 +150,8 @@ public class View3dController extends BaseController {
...
@@ -150,6 +150,8 @@ public class View3dController extends BaseController {
public
CommonResponse
getStatisticsCheck
(){
public
CommonResponse
getStatisticsCheck
(){
ReginParams
reginParams
=
getSelectedOrgInfo
();
ReginParams
reginParams
=
getSelectedOrgInfo
();
String
orgCode
=
this
.
getOrgCode
(
reginParams
);
String
orgCode
=
this
.
getOrgCode
(
reginParams
);
//TODO:待删除
orgCode
=
"1*2"
;
return
CommonResponseUtil
.
success
(
view3dService
.
getStatisticsCheck
(
orgCode
));
return
CommonResponseUtil
.
success
(
view3dService
.
getStatisticsCheck
(
orgCode
));
}
}
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/dao/mapper/View3dMapper.java
View file @
2a8b4994
...
@@ -16,12 +16,12 @@ import com.yeejoin.amos.fas.core.common.response.RegionTreeResponse;
...
@@ -16,12 +16,12 @@ import com.yeejoin.amos.fas.core.common.response.RegionTreeResponse;
public
interface
View3dMapper
extends
BaseMapper
{
public
interface
View3dMapper
extends
BaseMapper
{
/**
/**
* 按类型查询
树
* 按类型查询
点
* @param type
* @param type
* @param orgCode
* @param orgCode
* @return
* @return
*/
*/
List
<
RegionTreeResponse
>
getPoint
Tree
ByType
(
@Param
(
"type"
)
String
type
,
@Param
(
"orgCode"
)
String
orgCode
,
@Param
(
"channelType"
)
String
channelType
);
List
<
RegionTreeResponse
>
getPointByType
(
@Param
(
"type"
)
String
type
,
@Param
(
"orgCode"
)
String
orgCode
,
@Param
(
"channelType"
)
String
channelType
);
/**
/**
* 获取点详情
* 获取点详情
...
...
YeeAmosFireAutoSysService/src/main/java/com/yeejoin/amos/fas/business/service/impl/View3dServiceImpl.java
View file @
2a8b4994
...
@@ -103,6 +103,8 @@ public class View3dServiceImpl implements IView3dService {
...
@@ -103,6 +103,8 @@ public class View3dServiceImpl implements IView3dService {
@Autowired
@Autowired
private
IDataRefreshService
iDataRefreshService
;
private
IDataRefreshService
iDataRefreshService
;
@Autowired
private
RiskSourceMapper
riskSourceMapper
;
@Override
@Override
@Transactional
(
rollbackFor
=
Exception
.
class
)
@Transactional
(
rollbackFor
=
Exception
.
class
)
...
@@ -244,8 +246,12 @@ public class View3dServiceImpl implements IView3dService {
...
@@ -244,8 +246,12 @@ public class View3dServiceImpl implements IView3dService {
@Override
@Override
public
List
<
RegionTreeResponse
>
getPointTreeByType
(
String
type
,
String
orgCode
,
String
channelType
)
{
public
List
<
RegionTreeResponse
>
getPointTreeByType
(
String
type
,
String
orgCode
,
String
channelType
)
{
List
<
RegionTreeResponse
>
pointTreeByType
=
view3dMapper
.
getPointTreeByType
(
type
,
orgCode
,
channelType
);
//查询点
return
convertPointTree
(
pointTreeByType
);
List
<
RegionTreeResponse
>
regionList
=
riskSourceMapper
.
getRegionList
(
channelType
,
orgCode
);
//查询区域
List
<
RegionTreeResponse
>
pointByType
=
view3dMapper
.
getPointByType
(
type
,
orgCode
,
channelType
);
pointByType
.
addAll
(
regionList
);
return
convertPointTree
(
pointByType
);
}
}
//区域列表转树
//区域列表转树
...
...
YeeAmosFireAutoSysStart/src/main/resources/db/mapper/dbTemplate_risk_source.xml
View file @
2a8b4994
...
@@ -691,7 +691,8 @@
...
@@ -691,7 +691,8 @@
IF(rs.is_region = 'TRUE',1,0) as is_region,
IF(rs.is_region = 'TRUE',1,0) as is_region,
rs.route_path,
rs.route_path,
rl.level,
rl.level,
CONCAT('level_',rl.level) as level_str
CONCAT('level_',rl.level) as level_str,
'riskSource' as type
from f_risk_source rs
from f_risk_source rs
left join f_risk_level rl ON rs.risk_level_id = rl.id
left join f_risk_level rl ON rs.risk_level_id = rl.id
where is_region = 'TRUE' AND rs.org_code like CONCAT(#{orgCode},'%')
where is_region = 'TRUE' AND rs.org_code like CONCAT(#{orgCode},'%')
...
@@ -728,8 +729,8 @@
...
@@ -728,8 +729,8 @@
<if
test=
"item.ue4Extent != null"
>
<if
test=
"item.ue4Extent != null"
>
ue4_extent = #{item.ue4Extent,jdbcType=VARCHAR},
ue4_extent = #{item.ue4Extent,jdbcType=VARCHAR},
</if>
</if>
<if
test=
"item.
position3d
!= null"
>
<if
test=
"item.
routePath
!= null"
>
route_path = #{item.
position3d
,jdbcType=VARCHAR},
route_path = #{item.
routePath
,jdbcType=VARCHAR},
</if>
</if>
</set>
</set>
where id = #{item.riskSourceId,jdbcType=BIGINT}
where id = #{item.riskSourceId,jdbcType=BIGINT}
...
...
YeeAmosFireAutoSysStart/src/main/resources/db/mapper/dbTemplate_view3d.xml
View file @
2a8b4994
...
@@ -3,7 +3,7 @@
...
@@ -3,7 +3,7 @@
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper
namespace=
"com.yeejoin.amos.fas.business.dao.mapper.View3dMapper"
>
<mapper
namespace=
"com.yeejoin.amos.fas.business.dao.mapper.View3dMapper"
>
<select
id=
"getPoint
Tree
ByType"
resultType=
"com.yeejoin.amos.fas.core.common.response.RegionTreeResponse"
>
<select
id=
"getPointByType"
resultType=
"com.yeejoin.amos.fas.core.common.response.RegionTreeResponse"
>
<choose>
<choose>
<when
test=
"type == 'riskSource'"
>
<when
test=
"type == 'riskSource'"
>
select
select
...
@@ -21,15 +21,16 @@
...
@@ -21,15 +21,16 @@
route_path,
route_path,
rl.level,
rl.level,
CONCAT('level_',rl.level) as level_str,
CONCAT('level_',rl.level) as level_str,
IF(is_region = 'TRUE',1,0)
as is_region,
0
as is_region,
R.position3d
R.position3d
from f_risk_source R
from f_risk_source R
left join f_risk_level rl on rl.id = R.risk_level_id
left join f_risk_level rl on rl.id = R.risk_level_id
where 1=1
where 1=1
AND R.is_region = 'FALSE'
</when>
</when>
<when
test=
"type == 'patrol'"
>
<when
test=
"type == 'patrol'"
>
select
select
R.id,R.
parent_id,
B.id,B.risk_source_id as
parent_id,
<choose>
<choose>
<when
test=
"channelType == '3dpage'"
>
<when
test=
"channelType == '3dpage'"
>
IF(ISNULL(B.coordinates) || LENGTH(trim(B.coordinates))
<![CDATA[ <]]>
1,0,1) as is_bind,
IF(ISNULL(B.coordinates) || LENGTH(trim(B.coordinates))
<![CDATA[ <]]>
1,0,1) as is_bind,
...
@@ -40,8 +41,8 @@
...
@@ -40,8 +41,8 @@
</otherwise>
</otherwise>
</choose>
</choose>
#{type} as type,
#{type} as type,
B.name as name,B.point_no,B.ue4_location,B.ue4_rotation,
B.name as name,B.point_no
as code
,B.ue4_location,B.ue4_rotation,
1
as is_region,
0
as is_region,
B.coordinates as position3d,
B.coordinates as position3d,
B.status as level,
B.status as level,
CONCAT('level_',B.status) as level_str
CONCAT('level_',B.status) as level_str
...
@@ -52,7 +53,7 @@
...
@@ -52,7 +53,7 @@
</when>
</when>
<when
test=
"type == 'impEquipment'"
>
<when
test=
"type == 'impEquipment'"
>
select
select
R.id,R.
parent_id,
B.id,B.risk_source_id as
parent_id,
<choose>
<choose>
<when
test=
"channelType == '3dpage'"
>
<when
test=
"channelType == '3dpage'"
>
IF(ISNULL(B.position3d) || LENGTH(trim(B.position3d))
<![CDATA[ <]]>
1,0,1) as is_bind,
IF(ISNULL(B.position3d) || LENGTH(trim(B.position3d))
<![CDATA[ <]]>
1,0,1) as is_bind,
...
@@ -64,7 +65,7 @@
...
@@ -64,7 +65,7 @@
</choose>
</choose>
#{type} as type,
#{type} as type,
B.name,B.code,B.ue4_location,B.ue4_rotation,
B.name,B.code,B.ue4_location,B.ue4_rotation,
1
as is_region,
0
as is_region,
B.position3d
B.position3d
from f_risk_source R
from f_risk_source R
left join f_equipment B on B.risk_source_id = R.id AND R.is_region='TRUE'
left join f_equipment B on B.risk_source_id = R.id AND R.is_region='TRUE'
...
@@ -73,7 +74,7 @@
...
@@ -73,7 +74,7 @@
</when>
</when>
<when
test=
"type == 'monitorEquipment'"
>
<when
test=
"type == 'monitorEquipment'"
>
select
select
R.id,R.
parent_id,
B.id,B.risk_source_id as
parent_id,
<choose>
<choose>
<when
test=
"channelType == '3dpage'"
>
<when
test=
"channelType == '3dpage'"
>
IF(ISNULL(B.position3d) || LENGTH(trim(B.position3d))
<![CDATA[ <]]>
1,0,1) as is_bind,
IF(ISNULL(B.position3d) || LENGTH(trim(B.position3d))
<![CDATA[ <]]>
1,0,1) as is_bind,
...
@@ -94,7 +95,7 @@
...
@@ -94,7 +95,7 @@
</when>
</when>
<when
test=
"type == 'video'"
>
<when
test=
"type == 'video'"
>
select
select
R.id,R.
parent_id,
B.id,B.risk_source_id as
parent_id,
<choose>
<choose>
<when
test=
"channelType == '3dpage'"
>
<when
test=
"channelType == '3dpage'"
>
IF(ISNULL(B.position3d) || LENGTH(trim(B.position3d))
<![CDATA[ <]]>
1,0,1) as is_bind,
IF(ISNULL(B.position3d) || LENGTH(trim(B.position3d))
<![CDATA[ <]]>
1,0,1) as is_bind,
...
@@ -115,7 +116,14 @@
...
@@ -115,7 +116,14 @@
</when>
</when>
<when
test=
"type == 'fireEquipment'"
>
<when
test=
"type == 'fireEquipment'"
>
select
select
R.id,R.parent_id,
<!-- R.id, -->
CASE
WHEN ISNULL(C.id) = 0 then C.id
WHEN ISNULL(E.id) = 0 then E.id
WHEN ISNULL(S.id) = 0 then S.id
WHEN ISNULL(W.id) = 0 then W.id
END as id
,R.parent_id,
<choose>
<choose>
<when
test=
"channelType == '3dpage'"
>
<when
test=
"channelType == '3dpage'"
>
CASE
CASE
...
@@ -173,13 +181,6 @@
...
@@ -173,13 +181,6 @@
END as ue4_rotation,
END as ue4_rotation,
0 as is_region,
0 as is_region,
CASE
CASE
WHEN ISNULL(C.id) = 0 then C.ue4_rotation
WHEN ISNULL(E.id) = 0 then E.ue4_rotation
WHEN ISNULL(S.id) = 0 then S.ue4_rotation
WHEN ISNULL(W.id) = 0 then W.ue4_rotation
END as ue4_rotation,
0 as is_region,
CASE
WHEN ISNULL(C.id) = 0 then C.position3d
WHEN ISNULL(C.id) = 0 then C.position3d
WHEN ISNULL(E.id) = 0 then E.position3d
WHEN ISNULL(E.id) = 0 then E.position3d
WHEN ISNULL(S.id) = 0 then S.position3d
WHEN ISNULL(S.id) = 0 then S.position3d
...
...
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