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
fa8d7e5e
Commit
fa8d7e5e
authored
Jul 14, 2022
by
chenzhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
增加权限控制 # 故障告警/消防告警/跑马灯权限标识 true 机场 / false 电力
parent
a5a936e5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
25 additions
and
9 deletions
+25
-9
EquipmentAlarmController.java
...join/equipmanage/controller/EquipmentAlarmController.java
+23
-9
application.properties
...ot-system-equip/src/main/resources/application.properties
+2
-0
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/controller/EquipmentAlarmController.java
View file @
fa8d7e5e
...
...
@@ -10,6 +10,7 @@ import javax.servlet.http.HttpServletResponse;
import
com.yeejoin.amos.boot.biz.common.bo.ReginParams
;
import
org.apache.commons.lang3.StringUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.http.MediaType
;
import
org.springframework.util.ObjectUtils
;
import
org.springframework.web.bind.annotation.RequestMapping
;
...
...
@@ -51,8 +52,8 @@ public class EquipmentAlarmController extends AbstractBaseController {
@Autowired
IEquipmentSpecificAlarmService
iEquipmentSpecificAlarmService
;
@Value
(
"${equip.enabled}"
)
private
Boolean
equioEnabled
;
/**
* 列表列名
*
...
...
@@ -157,11 +158,17 @@ public class EquipmentAlarmController extends AbstractBaseController {
request12
.
setName
(
"isRemoveShield"
);
request12
.
setValue
(
StringUtil
.
isNotEmpty
(
isRemoveShield
)
?
StringUtils
.
trimToNull
(
isRemoveShield
)
:
null
);
queryRequests
.
add
(
request12
);
if
(!
ValidationUtil
.
isEmpty
(
reginParams
.
getPersonIdentity
())){
if
(
equioEnabled
)
{
if
(!
ValidationUtil
.
isEmpty
(
reginParams
.
getPersonIdentity
()))
{
CommonRequest
request13
=
new
CommonRequest
();
request13
.
setName
(
"bizOrgCode"
);
request13
.
setValue
(
StringUtil
.
isNotEmpty
(
reginParams
.
getPersonIdentity
().
getBizOrgCode
())
?
reginParams
.
getPersonIdentity
().
getBizOrgCode
()
:
null
);
queryRequests
.
add
(
request13
);
}
}
else
{
CommonRequest
request13
=
new
CommonRequest
();
request13
.
setName
(
"bizOrgCode"
);
request13
.
setValue
(
StringUtil
.
isNotEmpty
(
reginParams
.
getPersonIdentity
().
getBizOrgCode
())
?
reginParams
.
getPersonIdentity
().
getBizOrgCode
()
:
null
);
queryRequests
.
add
(
request13
);
request13
.
setValue
(
""
);
}
CommonPageInfoParam
param
=
CommonPageParamUtil
.
fillCommonPageInfoParam
(
queryRequests
,
commonPageable
);
Page
<
Map
<
String
,
Object
>>
list
=
iEquipmentSpecificAlarmService
.
listPage
(
param
);
...
...
@@ -279,13 +286,20 @@ public class EquipmentAlarmController extends AbstractBaseController {
request13
.
setName
(
"isRemovedFire"
);
request13
.
setValue
(
StringUtil
.
isNotEmpty
(
isRemovedFire
)
?
StringUtils
.
trimToNull
(
isRemovedFire
)
:
null
);
queryRequests
.
add
(
request13
);
if
(!
ValidationUtil
.
isEmpty
(
reginParams
.
getPersonIdentity
())){
if
(
equioEnabled
){
if
(!
ValidationUtil
.
isEmpty
(
reginParams
.
getPersonIdentity
())){
CommonRequest
request14
=
new
CommonRequest
();
request14
.
setName
(
"bizOrgCode"
);
request14
.
setValue
(
StringUtil
.
isNotEmpty
(
reginParams
.
getPersonIdentity
().
getBizOrgCode
())
?
reginParams
.
getPersonIdentity
().
getBizOrgCode
()
:
null
);
queryRequests
.
add
(
request14
);
}
}
else
{
CommonRequest
request14
=
new
CommonRequest
();
request14
.
setName
(
"bizOrgCode"
);
request14
.
setValue
(
StringUtil
.
isNotEmpty
(
reginParams
.
getPersonIdentity
().
getBizOrgCode
())
?
reginParams
.
getPersonIdentity
().
getBizOrgCode
()
:
null
);
queryRequests
.
add
(
request14
);
request14
.
setValue
(
""
);
}
CommonPageInfoParam
param
=
CommonPageParamUtil
.
fillCommonPageInfoParam
(
queryRequests
,
commonPageable
);
CommonPageInfoParam
param
=
CommonPageParamUtil
.
fillCommonPageInfoParam
(
queryRequests
,
commonPageable
);
org
.
springframework
.
data
.
domain
.
Page
<
AlarmListDataVO
>
list
=
iEquipmentSpecificAlarmService
.
listAlarmsPage
(
param
);
return
CommonResponseUtil
.
success
(
list
);
}
...
...
amos-boot-system-equip/src/main/resources/application.properties
View file @
fa8d7e5e
...
...
@@ -85,6 +85,8 @@ dcs.token-key=dcs_token_key
dcs.client.secret
=
fire_system
dcs.x.hw.id
=
NR_REST_APP
dcs.x.hw.appKey
=
s+YkvQhwilx91TRJHhNDmw==
# 故障告警/消防告警/跑马灯权限标识 true 机场 / false 电力
equip.enabled
=
true
management.endpoints.enabled-by-default
=
false
...
...
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