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
ff9b4ff2
Commit
ff9b4ff2
authored
Oct 12, 2022
by
tianyiming
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop_dl_plan6' of
http://39.98.45.134:8090/moa/amos-boot-biz
into develop_dl_plan6
parents
5762fa7c
76422f37
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
62 additions
and
12 deletions
+62
-12
PressurePumpMessageEnum.java
...oin/equipmanage/common/enums/PressurePumpMessageEnum.java
+4
-4
DataDictionaryTypeEnum.java
.../boot/module/common/biz/enums/DataDictionaryTypeEnum.java
+30
-0
DynamicGroupCodeEnum.java
...os/boot/module/common/biz/enums/DynamicGroupCodeEnum.java
+2
-2
DutyCommonServiceImpl.java
...module/common/biz/service/impl/DutyCommonServiceImpl.java
+19
-4
PumpSendMessage.java
.../java/com/yeejoin/equipmanage/quartz/PumpSendMessage.java
+3
-1
MqttReceiveServiceImpl.java
...join/equipmanage/service/impl/MqttReceiveServiceImpl.java
+4
-1
No files found.
amos-boot-module/amos-boot-module-api/amos-boot-module-equip-api/src/main/java/com/yeejoin/equipmanage/common/enums/PressurePumpMessageEnum.java
View file @
ff9b4ff2
...
@@ -2,10 +2,10 @@ package com.yeejoin.equipmanage.common.enums;
...
@@ -2,10 +2,10 @@ package com.yeejoin.equipmanage.common.enums;
public
enum
PressurePumpMessageEnum
{
public
enum
PressurePumpMessageEnum
{
MESSAGE_LEVEL_YB
(
"YB"
,
"【%s】分钟内,启停间隔较小"
,
""
,
"
名称:稳压泵启停异常提醒;时间:%s;内容:
【%s】- 【%s】 - 【%s】分钟内,设备启停频繁,请及时查看处理"
),
MESSAGE_LEVEL_YB
(
"YB"
,
"【%s】分钟内,启停间隔较小"
,
""
,
"【%s】- 【%s】 - 【%s】分钟内,设备启停频繁,请及时查看处理"
),
MESSAGE_LEVEL_YZ
(
"YZ"
,
"【%s】分钟内,启停间隔较小"
,
""
,
"
名称:稳压泵启停异常提醒;时间:%s;内容:
【%s】- 【%s】 - 【%s】分钟内,设备启停频繁,请及时查看处理"
),
MESSAGE_LEVEL_YZ
(
"YZ"
,
"【%s】分钟内,启停间隔较小"
,
""
,
"【%s】- 【%s】 - 【%s】分钟内,设备启停频繁,请及时查看处理"
),
MESSAGE_LEVEL_QT_WJ
(
"QT_WJ"
,
"【%s】分钟内,设备启停频繁"
,
"类型:漏水提醒 ;设备位置:【稳压泵设备位置】; 设备名称:【稳压泵设备名称】 ; 时间:系统推送时间"
,
"
名称:漏水提醒; 时间:%s;内容:
【%s】- 【%s】 - 【%s】分钟内,设备启停频繁,可能存在漏水,请及时查看处理"
),
MESSAGE_LEVEL_QT_WJ
(
"QT_WJ"
,
"【%s】分钟内,设备启停频繁"
,
"类型:漏水提醒 ;设备位置:【稳压泵设备位置】; 设备名称:【稳压泵设备名称】 ; 时间:系统推送时间"
,
"【%s】- 【%s】 - 【%s】分钟内,设备启停频繁,可能存在漏水,请及时查看处理"
),
MESSAGE_LEVEL_QT_WJ_YXSC
(
"WJ_YXSC"
,
"运行时长超过【%s】分钟,存在漏水可能"
,
"类型:漏水提醒 ;设备位置:【稳压泵设备位置】; 设备名称:【稳压泵设备名称】 ; 时间:系统推送时间"
,
"
名称:漏水提醒; 时间:%s;内容:
【%s】- 【%s】 - 运行时长超过【%s】分钟,存在漏水可能,请及时查看处理"
);
MESSAGE_LEVEL_QT_WJ_YXSC
(
"WJ_YXSC"
,
"运行时长超过【%s】分钟,存在漏水可能"
,
"类型:漏水提醒 ;设备位置:【稳压泵设备位置】; 设备名称:【稳压泵设备名称】 ; 时间:系统推送时间"
,
"【%s】- 【%s】 - 运行时长超过【%s】分钟,存在漏水可能,请及时查看处理"
);
private
String
code
;
private
String
code
;
private
String
allMessage
;
private
String
allMessage
;
private
String
marqueeMessage
;
private
String
marqueeMessage
;
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/enums/DataDictionaryTypeEnum.java
0 → 100644
View file @
ff9b4ff2
package
com
.
yeejoin
.
amos
.
boot
.
module
.
common
.
biz
.
enums
;
public
enum
DataDictionaryTypeEnum
{
PERSON_TYPE
(
"人员类型"
,
"DLRYLX"
);
private
String
name
;
private
String
code
;
public
String
getName
()
{
return
name
;
}
public
void
setName
(
String
name
)
{
this
.
name
=
name
;
}
public
String
getCode
()
{
return
code
;
}
public
void
setCode
(
String
code
)
{
this
.
code
=
code
;
}
DataDictionaryTypeEnum
(
String
name
,
String
code
)
{
this
.
name
=
name
;
this
.
code
=
code
;
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/enums/DynamicGroupCode.java
→
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/enums/DynamicGroupCode
Enum
.java
View file @
ff9b4ff2
package
com
.
yeejoin
.
amos
.
boot
.
module
.
common
.
biz
.
enums
;
package
com
.
yeejoin
.
amos
.
boot
.
module
.
common
.
biz
.
enums
;
public
enum
DynamicGroupCode
{
public
enum
DynamicGroupCode
Enum
{
JCS_PERSON
(
"机场人员"
,
"246"
);
JCS_PERSON
(
"机场人员"
,
"246"
);
...
@@ -23,7 +23,7 @@ public enum DynamicGroupCode {
...
@@ -23,7 +23,7 @@ public enum DynamicGroupCode {
this
.
code
=
code
;
this
.
code
=
code
;
}
}
DynamicGroupCode
(
String
name
,
String
code
)
{
DynamicGroupCode
Enum
(
String
name
,
String
code
)
{
this
.
name
=
name
;
this
.
name
=
name
;
this
.
code
=
code
;
this
.
code
=
code
;
}
}
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-common-biz/src/main/java/com/yeejoin/amos/boot/module/common/biz/service/impl/DutyCommonServiceImpl.java
View file @
ff9b4ff2
...
@@ -19,7 +19,10 @@ import java.util.stream.Stream;
...
@@ -19,7 +19,10 @@ import java.util.stream.Stream;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletRequest
;
import
com.yeejoin.amos.boot.module.common.biz.enums.DynamicGroupCode
;
import
com.yeejoin.amos.boot.biz.common.entity.DataDictionary
;
import
com.yeejoin.amos.boot.biz.common.service.IDataDictionaryService
;
import
com.yeejoin.amos.boot.module.common.biz.enums.DataDictionaryTypeEnum
;
import
com.yeejoin.amos.boot.module.common.biz.enums.DynamicGroupCodeEnum
;
import
org.apache.commons.collections4.CollectionUtils
;
import
org.apache.commons.collections4.CollectionUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.apache.commons.lang3.StringUtils
;
import
org.joda.time.DateTime
;
import
org.joda.time.DateTime
;
...
@@ -82,6 +85,10 @@ public class DutyCommonServiceImpl implements IDutyCommonService {
...
@@ -82,6 +85,10 @@ public class DutyCommonServiceImpl implements IDutyCommonService {
@Autowired
@Autowired
DutyPersonShiftMapper
dutyPersonShiftMapper
;
DutyPersonShiftMapper
dutyPersonShiftMapper
;
@Autowired
IDataDictionaryService
dataDictionaryService
;
/**
/**
* 每天单个班次执勤人数全部小于等于3人
* 每天单个班次执勤人数全部小于等于3人
*/
*/
...
@@ -122,7 +129,7 @@ public class DutyCommonServiceImpl implements IDutyCommonService {
...
@@ -122,7 +129,7 @@ public class DutyCommonServiceImpl implements IDutyCommonService {
});
});
}
}
// 获取人员详细信息
// 获取人员详细信息
List
<
Map
<
String
,
Object
>>
personInfoList
=
dynamicFormInstanceService
.
personInfoList
(
DynamicGroupCode
.
JCS_PERSON
.
getCode
(),
userIdSet
);
List
<
Map
<
String
,
Object
>>
personInfoList
=
dynamicFormInstanceService
.
personInfoList
(
DynamicGroupCode
Enum
.
JCS_PERSON
.
getCode
(),
userIdSet
);
if
(!
CollectionUtils
.
isEmpty
(
personInfoList
))
{
if
(!
CollectionUtils
.
isEmpty
(
personInfoList
))
{
Map
<
String
,
List
<
Map
<
String
,
Object
>>>
listMap
=
personInfoList
.
stream
().
collect
(
Collectors
.
groupingBy
((
Map
m
)
->
String
.
valueOf
(
m
.
get
(
"userId"
))));
Map
<
String
,
List
<
Map
<
String
,
Object
>>>
listMap
=
personInfoList
.
stream
().
collect
(
Collectors
.
groupingBy
((
Map
m
)
->
String
.
valueOf
(
m
.
get
(
"userId"
))));
records
.
forEach
(
x
->
{
records
.
forEach
(
x
->
{
...
@@ -559,9 +566,17 @@ public class DutyCommonServiceImpl implements IDutyCommonService {
...
@@ -559,9 +566,17 @@ public class DutyCommonServiceImpl implements IDutyCommonService {
List
<
DynamicFormInstance
>
instances
=
dynamicFormInstanceService
List
<
DynamicFormInstance
>
instances
=
dynamicFormInstanceService
.
list
(
new
LambdaQueryWrapper
<
DynamicFormInstance
>().
eq
(
DynamicFormInstance:
:
getFieldCode
,
"peopleType"
)
.
list
(
new
LambdaQueryWrapper
<
DynamicFormInstance
>().
eq
(
DynamicFormInstance:
:
getFieldCode
,
"peopleType"
)
.
eq
(
DynamicFormInstance:
:
getInstanceId
,
userId
)
.
eq
(
DynamicFormInstance:
:
getInstanceId
,
userId
)
.
eq
(
DynamicFormInstance:
:
getGroupCode
,
DynamicGroupCode
.
JCS_PERSON
.
getCode
()));
.
eq
(
DynamicFormInstance:
:
getGroupCode
,
DynamicGroupCode
Enum
.
JCS_PERSON
.
getCode
()));
if
(!
CollectionUtils
.
isEmpty
(
instances
))
{
if
(!
CollectionUtils
.
isEmpty
(
instances
))
{
d
.
put
(
"personType"
,
instances
.
get
(
0
).
getFieldValue
());
String
fieldValue
=
instances
.
get
(
0
).
getFieldValue
();
List
<
DataDictionary
>
dictionaryList
=
dataDictionaryService
.
getByType
(
DataDictionaryTypeEnum
.
PERSON_TYPE
.
getCode
());
if
(
StringUtils
.
isNotBlank
(
fieldValue
)
&&
!
CollectionUtils
.
isEmpty
(
dictionaryList
))
{
Map
<
String
,
List
<
DataDictionary
>>
map
=
dictionaryList
.
stream
().
collect
(
Collectors
.
groupingBy
(
DataDictionary:
:
getCode
));
List
<
DataDictionary
>
list
=
map
.
get
(
fieldValue
);
if
(!
CollectionUtils
.
isEmpty
(
list
))
{
d
.
put
(
"personType"
,
list
.
get
(
0
).
getName
());
}
}
}
}
}
}
return
d
;
return
d
;
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/quartz/PumpSendMessage.java
View file @
ff9b4ff2
...
@@ -51,7 +51,7 @@ public class PumpSendMessage implements Job {
...
@@ -51,7 +51,7 @@ public class PumpSendMessage implements Job {
}
}
String
recordMessage
=
PressurePumpMessageEnum
.
MESSAGE_LEVEL_QT_WJ_YXSC
.
getRecordMessage
();
String
recordMessage
=
PressurePumpMessageEnum
.
MESSAGE_LEVEL_QT_WJ_YXSC
.
getRecordMessage
();
if
(
StringUtil
.
isNotEmpty
(
recordMessage
))
{
if
(
StringUtil
.
isNotEmpty
(
recordMessage
))
{
body
=
String
.
format
(
recordMessage
,
new
SimpleDateFormat
(
DateUtils
.
DATE_TIME_PATTERN
).
format
(
new
Date
()),
equipmentSpecific
.
getName
(),
equipmentSpecific
.
getPosition
(),
pressurePumpEnum
.
getRightValue
());
body
=
String
.
format
(
recordMessage
,
equipmentSpecific
.
getName
(),
equipmentSpecific
.
getPosition
(),
pressurePumpEnum
.
getRightValue
());
}
}
String
marqueeMessage
=
PressurePumpMessageEnum
.
MESSAGE_LEVEL_QT_WJ_YXSC
.
getMarqueeMessage
();
String
marqueeMessage
=
PressurePumpMessageEnum
.
MESSAGE_LEVEL_QT_WJ_YXSC
.
getMarqueeMessage
();
if
(
StringUtil
.
isNotEmpty
(
marqueeMessage
))
{
if
(
StringUtil
.
isNotEmpty
(
marqueeMessage
))
{
...
@@ -67,7 +67,9 @@ public class PumpSendMessage implements Job {
...
@@ -67,7 +67,9 @@ public class PumpSendMessage implements Job {
}
}
model
.
setBody
(
body
);
model
.
setBody
(
body
);
model
.
setTitle
(
"漏水提醒"
);
model
.
setExtras
(
map
);
model
.
setExtras
(
map
);
model
.
setRelationId
(
String
.
valueOf
(
equipmentSpecific
.
getId
()));
model
.
setMsgType
(
"pressurePump"
);
model
.
setMsgType
(
"pressurePump"
);
model
.
setIsSendApp
(
false
);
model
.
setIsSendApp
(
false
);
model
.
setTerminal
(
"WEB"
);
model
.
setTerminal
(
"WEB"
);
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-equip-biz/src/main/java/com/yeejoin/equipmanage/service/impl/MqttReceiveServiceImpl.java
View file @
ff9b4ff2
...
@@ -1474,7 +1474,7 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
...
@@ -1474,7 +1474,7 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
String
recordMessage
=
pumpMessageEnum
.
getRecordMessage
();
String
recordMessage
=
pumpMessageEnum
.
getRecordMessage
();
if
(
StringUtil
.
isNotEmpty
(
recordMessage
))
{
if
(
StringUtil
.
isNotEmpty
(
recordMessage
))
{
String
value
=
StringUtil
.
isNotEmpty
(
pressurePumpEnum
.
getLeftValue
())
?
pressurePumpEnum
.
getLeftValue
()
:
pressurePumpEnum
.
getRightValue
();
String
value
=
StringUtil
.
isNotEmpty
(
pressurePumpEnum
.
getLeftValue
())
?
pressurePumpEnum
.
getLeftValue
()
:
pressurePumpEnum
.
getRightValue
();
body
=
String
.
format
(
recordMessage
,
time
,
data
.
getEquipmentSpecificName
(),
data
.
getLocation
(),
value
);
body
=
String
.
format
(
recordMessage
,
data
.
getEquipmentSpecificName
(),
data
.
getLocation
(),
value
);
}
}
String
marqueeMessage
=
pumpMessageEnum
.
getMarqueeMessage
();
String
marqueeMessage
=
pumpMessageEnum
.
getMarqueeMessage
();
if
(
StringUtil
.
isNotEmpty
(
marqueeMessage
))
{
if
(
StringUtil
.
isNotEmpty
(
marqueeMessage
))
{
...
@@ -1493,10 +1493,12 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
...
@@ -1493,10 +1493,12 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
case
MESSAGE_LEVEL_YB:
case
MESSAGE_LEVEL_YB:
case
MESSAGE_LEVEL_YZ:
case
MESSAGE_LEVEL_YZ:
map
.
put
(
"type"
,
"稳压泵启停异常提醒"
);
map
.
put
(
"type"
,
"稳压泵启停异常提醒"
);
model
.
setTitle
(
"稳压泵启停异常提醒"
);
break
;
break
;
case
MESSAGE_LEVEL_QT_WJ:
case
MESSAGE_LEVEL_QT_WJ:
case
MESSAGE_LEVEL_QT_WJ_YXSC:
case
MESSAGE_LEVEL_QT_WJ_YXSC:
map
.
put
(
"type"
,
"漏水提醒"
);
map
.
put
(
"type"
,
"漏水提醒"
);
model
.
setTitle
(
"漏水提醒"
);
break
;
break
;
default
:
default
:
break
;
break
;
...
@@ -1512,6 +1514,7 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
...
@@ -1512,6 +1514,7 @@ public class MqttReceiveServiceImpl implements MqttReceiveService {
model
.
setCategory
(
1
);
model
.
setCategory
(
1
);
List
<
String
>
receive
=
new
ArrayList
<>();
List
<
String
>
receive
=
new
ArrayList
<>();
receive
.
add
(
"system"
);
receive
.
add
(
"system"
);
model
.
setRelationId
(
String
.
valueOf
(
data
.
getEquipmentId
()));
model
.
setRecivers
(
receive
);
model
.
setRecivers
(
receive
);
Token
token
=
remoteSecurityService
.
getServerToken
();
Token
token
=
remoteSecurityService
.
getServerToken
();
systemctlFeign
.
create
(
token
.
getAppKey
(),
token
.
getProduct
(),
token
.
getToke
(),
model
);
systemctlFeign
.
create
(
token
.
getAppKey
(),
token
.
getProduct
(),
token
.
getToke
(),
model
);
...
...
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