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
2659fb20
Commit
2659fb20
authored
Jul 19, 2022
by
tangwei
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
新增接口
parent
a7b57110
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
47 additions
and
10 deletions
+47
-10
InputItemController.java
.../amos/patrol/business/controller/InputItemController.java
+1
-1
MsgController.java
...eejoin/amos/patrol/business/controller/MsgController.java
+34
-1
MsgVo.java
.../main/java/com/yeejoin/amos/patrol/business/vo/MsgVo.java
+4
-0
msgMapper.xml
...-system-patrol/src/main/resources/db/mapper/msgMapper.xml
+8
-8
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-patrol-biz/src/main/java/com/yeejoin/amos/patrol/business/controller/InputItemController.java
View file @
2659fb20
...
...
@@ -424,5 +424,5 @@ public class InputItemController extends AbstractBaseController {
}
}
}
amos-boot-module/amos-boot-module-biz/amos-boot-module-patrol-biz/src/main/java/com/yeejoin/amos/patrol/business/controller/MsgController.java
View file @
2659fb20
...
...
@@ -98,7 +98,13 @@ public class MsgController extends AbstractBaseController {
@ApiParam
(
value
=
"查询条件"
,
required
=
false
)
@RequestBody
(
required
=
false
)
MsgInfoPageParam
param
,
@ApiParam
(
value
=
"分页参数"
,
required
=
true
,
defaultValue
=
"pageNumber=0&pageSize=10"
)
CommonPageable
commonPageable
)
{
try
{
// ReginParams reginParams = getSelectedOrgInfo();
// String loginOrgCode = getOrgCode(reginParams);
// String roleTypeName = getRoleTypeName(reginParams);
// HashMap<String, Object> paramMap = buildMybatisCriterias(loginOrgCode, roleTypeName);
// if(XJConstant.ROLE_NAME_DEPTADMIN.equals(roleTypeName)||XJConstant.ROLE_NAME_PERSON.equals(roleTypeName))
// paramMap.put("userId",getUserId());
// MsgInfoPageParam param = MsgParamUtils.fillMsgInfoParam(queryRequests, commonPageable, paramMap);
Page
<
MsgVo
>
dataList
=
iMsgService
.
queryMsgInfoList
(
param
);
return
CommonResponseUtil
.
success
(
dataList
);
}
catch
(
Exception
e
)
{
...
...
@@ -120,6 +126,9 @@ public class MsgController extends AbstractBaseController {
msg
.
setUserName
(
user
.
getRealName
());
String
loginOrgCode
=
getOrgCode
(
reginParams
);
msg
.
setOrgCode
(
loginOrgCode
);
List
<
Msg
>
msgList
=
iMsgService
.
publishNotice
(
getToken
(),
getProduct
(),
getAppKey
(),
msg
);
msgList
.
forEach
(
m
->{
jobService
.
msgAddJob
(
m
);
...
...
@@ -133,6 +142,30 @@ public class MsgController extends AbstractBaseController {
@TycloudOperation
(
ApiLevel
=
UserType
.
AGENCY
)
@ApiOperation
(
value
=
"APP获取消息类型"
,
notes
=
"APP获取消息类型"
)
@GetMapping
(
value
=
"/MsgTypeNew"
,
produces
=
"application/json;charset=UTF-8"
)
public
CommonResponse
getMsgTypeNew
()
{
try
{
List
<
Map
<
String
,
String
>>
list
=
new
ArrayList
<>();
for
(
MsgTypeEnum
e
:
MsgTypeEnum
.
values
())
{
Map
<
String
,
String
>
msgType
=
new
HashMap
<>();
msgType
.
put
(
"name"
,
e
.
getName
());
msgType
.
put
(
"value"
,
e
.
getCode
());
list
.
add
(
msgType
);
}
return
CommonResponseUtil
.
success
(
list
);
}
catch
(
Exception
e
)
{
return
CommonResponseUtil
.
failure
(
"获取消息类型失败"
);
}
}
/**
* 新接口
*
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-patrol-biz/src/main/java/com/yeejoin/amos/patrol/business/vo/MsgVo.java
View file @
2659fb20
...
...
@@ -2,6 +2,8 @@ package com.yeejoin.amos.patrol.business.vo;
import
java.util.Date
;
import
com.alibaba.fastjson.annotation.JSONField
;
import
com.fasterxml.jackson.annotation.JsonFormat
;
import
com.yeejoin.amos.patrol.common.enums.MsgTypeEnum
;
public
class
MsgVo
{
...
...
@@ -29,6 +31,7 @@ public class MsgVo {
/**
* 发送时间
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
Date
sendTime
;
/**
...
...
@@ -39,6 +42,7 @@ public class MsgVo {
/**
* 定点发送时间
*/
@JsonFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
private
Date
fixedTime
;
public
long
getId
()
{
...
...
amos-boot-system-patrol/src/main/resources/db/mapper/msgMapper.xml
View file @
2659fb20
...
...
@@ -209,11 +209,11 @@
<where>
<if
test=
"orgCode!=null"
>
and (org_Code like concat (#{orgCode},"-%")or org_Code= #{orgCode})
</if>
<if
test=
"userId != null"
>
AND m.user_id = #{userId}
</if>
<if
test=
"userName != null"
>
AND m.`reciver_name` LIKE concat('%', #{userName}, '%')
</if>
<if
test=
"userName != null
and userName != ''
"
>
AND m.`reciver_name` LIKE concat('%', #{userName}, '%')
</if>
<if
test=
"msgType != null"
>
AND m.msg_type = #{msgType}
</if>
<if
test=
"beginDate != null"
>
AND m.create_date
<![CDATA[>=]]>
#{beginDate}
</if>
<if
test=
"endDate != null"
>
AND m.create_date
<![CDATA[<=]]>
#{endDate}
</if>
<if
test=
"bizOrgCode != null"
>
AND m.biz_org_code = #{bizOrgCode}
</if>
<if
test=
"beginDate != null
and beginDate != ''
"
>
AND m.create_date
<![CDATA[>=]]>
#{beginDate}
</if>
<if
test=
"endDate != null
and endDate != ''
"
>
AND m.create_date
<![CDATA[<=]]>
#{endDate}
</if>
<if
test=
"bizOrgCode != null
and bizOrgCode != ''
"
>
AND m.biz_org_code = #{bizOrgCode}
</if>
</where>
</select>
...
...
@@ -237,11 +237,11 @@
<where>
<if
test=
"orgCode!=null"
>
and (org_Code like concat (#{orgCode},"-%")or org_Code= #{orgCode})
</if>
<if
test=
"userId != null"
>
AND m.user_id = #{userId}
</if>
<if
test=
"userName != null"
>
AND m.`reciver_name` LIKE concat('%', #{userName}, '%')
</if>
<if
test=
"userName != null
and userName != ''
"
>
AND m.`reciver_name` LIKE concat('%', #{userName}, '%')
</if>
<if
test=
"msgType != null"
>
AND m.msg_type = #{msgType}
</if>
<if
test=
"beginDate != null"
>
AND m.create_date
<![CDATA[>=]]>
#{beginDate}
</if>
<if
test=
"endDate != null"
>
AND m.create_date
<![CDATA[<=]]>
#{endDate}
</if>
<if
test=
"bizOrgCode != null"
>
AND m.biz_org_code = #{bizOrgCode}
</if>
<if
test=
"beginDate != null
and beginDate != ''
"
>
AND m.create_date
<![CDATA[>=]]>
#{beginDate}
</if>
<if
test=
"endDate != null
and endDate != ''
"
>
AND m.create_date
<![CDATA[<=]]>
#{endDate}
</if>
<if
test=
"bizOrgCode != null
and bizOrgCode != ''
"
>
AND m.biz_org_code = #{bizOrgCode}
</if>
</where>
ORDER BY m.id DESC
<choose>
...
...
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