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
33462341
Commit
33462341
authored
Aug 27, 2021
by
suhuiguang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1.修改依赖 及bug
parent
dafb0d48
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
78 additions
and
78 deletions
+78
-78
CheckMapper.java
...oin/amos/maintenance/business/dao/mapper/CheckMapper.java
+1
-1
CheckServiceImpl.java
...s/maintenance/business/service/impl/CheckServiceImpl.java
+3
-3
ICheckService.java
...mos/maintenance/business/service/intfc/ICheckService.java
+1
-1
AppMessagePushService.java
...yeejoin/amos/maintenance/jpush/AppMessagePushService.java
+61
-62
dbTemplate_check.xml
...tenance/src/main/resources/db/mapper/dbTemplate_check.xml
+11
-10
pom.xml
pom.xml
+1
-1
No files found.
amos-boot-module/amos-boot-module-biz/amos-boot-module-maintenance-biz/src/main/java/com/yeejoin/amos/maintenance/business/dao/mapper/CheckMapper.java
View file @
33462341
...
...
@@ -279,7 +279,7 @@ public interface CheckMapper extends BaseMapper {
long
getCheckCount
(
HashMap
<
String
,
Object
>
params
);
List
<
Hash
Map
<
String
,
Object
>>
getChecks
(
HashMap
<
String
,
Object
>
params
);
List
<
Map
<
String
,
Object
>>
getChecks
(
HashMap
<
String
,
Object
>
params
);
Map
<
String
,
Object
>
getCheckDetail
(
@Param
(
value
=
"id"
)
String
id
);
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-maintenance-biz/src/main/java/com/yeejoin/amos/maintenance/business/service/impl/CheckServiceImpl.java
View file @
33462341
...
...
@@ -1090,8 +1090,8 @@ public class CheckServiceImpl implements ICheckService {
}
@Override
public
Page
<
Hash
Map
<
String
,
Object
>>
getCheckPage
(
HashMap
<
String
,
Object
>
params
,
CommonPageable
page
)
{
List
<
Hash
Map
<
String
,
Object
>>
content
=
Lists
.
newArrayList
();
public
Page
<
Map
<
String
,
Object
>>
getCheckPage
(
HashMap
<
String
,
Object
>
params
,
CommonPageable
page
)
{
List
<
Map
<
String
,
Object
>>
content
=
Lists
.
newArrayList
();
long
total
=
checkMapper
.
getCheckCount
(
params
);
if
(
total
==
0
)
{
return
new
PageImpl
<>(
content
,
page
,
total
);
...
...
@@ -1100,7 +1100,7 @@ public class CheckServiceImpl implements ICheckService {
params
.
put
(
"pageSize"
,
page
.
getPageSize
());
content
=
checkMapper
.
getChecks
(
params
);
if
(
0
<
content
.
size
())
{
for
(
Hash
Map
<
String
,
Object
>
map
:
content
)
{
for
(
Map
<
String
,
Object
>
map
:
content
)
{
if
(
map
.
containsKey
(
"isOk"
))
{
map
.
put
(
"status"
,
CheckStatusEnum
.
getEnum
(
String
.
valueOf
(
map
.
get
(
"isOk"
))).
getName
());
}
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-maintenance-biz/src/main/java/com/yeejoin/amos/maintenance/business/service/intfc/ICheckService.java
View file @
33462341
...
...
@@ -258,7 +258,7 @@ public interface ICheckService {
*/
Map
<
String
,
CheckRecordDto
>
obtainLastCheckRecord
(
String
[]
relationId
);
Page
<
Hash
Map
<
String
,
Object
>>
getCheckPage
(
HashMap
<
String
,
Object
>
map
,
CommonPageable
pageable
);
Page
<
Map
<
String
,
Object
>>
getCheckPage
(
HashMap
<
String
,
Object
>
map
,
CommonPageable
pageable
);
Map
<
String
,
Object
>
getCheckDetail
(
String
id
);
/**
...
...
amos-boot-module/amos-boot-module-biz/amos-boot-module-maintenance-biz/src/main/java/com/yeejoin/amos/maintenance/jpush/AppMessagePushService.java
View file @
33462341
package
com
.
yeejoin
.
amos
.
maintenance
.
jpush
;
import
cn.jpush.api.JPushClient
;
import
cn.jpush.api.push.model.PushPayload
;
import
com.yeejoin.amos.maintenance.business.constants.XJConstant
;
import
com.yeejoin.amos.maintenance.business.param.PushMsgParam
;
import
com.yeejoin.amos.maintenance.business.util.CommonResponse
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
...
...
@@ -7,23 +11,17 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.beans.factory.annotation.Value
;
import
org.springframework.stereotype.Service
;
import
com.yeejoin.amos.maintenance.business.constants.XJConstant
;
import
com.yeejoin.amos.maintenance.business.param.PushMsgParam
;
import
cn.jpush.api.JPushClient
;
import
cn.jpush.api.push.model.PushPayload
;
@Service
public
class
AppMessagePushService
{
protected
static
final
Logger
log
=
LoggerFactory
.
getLogger
(
AppMessagePushService
.
class
);
@Autowired
private
com
.
yeejoin
.
amos
.
maintenance
.
feign
.
PushFeign
PushFeign
;
protected
static
final
Logger
log
=
LoggerFactory
.
getLogger
(
AppMessagePushService
.
class
);
@Autowired
private
com
.
yeejoin
.
amos
.
maintenance
.
feign
.
PushFeign
PushFeign
;
// private static String APP_KEY;
//
// private static String MASTER_SECRET;
...
...
@@ -36,20 +34,21 @@ public class AppMessagePushService {
// public void setMasterSecret(String masterSecret) {
// this.MASTER_SECRET = masterSecret;
// }
@Value
(
"${params.isPush}"
)
private
String
isPush
;
protected
static
final
String
APP_KEY
=
"1b3f7b961200f4b236811dfe"
;
protected
static
final
String
MASTER_SECRET
=
"8b650e645fb3a43c96be02b2"
;
//
private
static
JPushClient
jpushClient
=
new
JPushClient
(
MASTER_SECRET
,
APP_KEY
);
public
static
String
buildJpushUserKey
(
String
userId
)
{
return
XJConstant
.
JPUSH_USER_KEY
+
"_"
+
userId
;
}
@Value
(
"${params.isPush}"
)
private
String
isPush
;
protected
static
final
String
APP_KEY
=
"1b3f7b961200f4b236811dfe"
;
protected
static
final
String
MASTER_SECRET
=
"8b650e645fb3a43c96be02b2"
;
//
private
static
JPushClient
jpushClient
=
new
JPushClient
(
MASTER_SECRET
,
APP_KEY
);
public
static
String
buildJpushUserKey
(
String
userId
)
{
return
XJConstant
.
JPUSH_USER_KEY
+
"_"
+
userId
;
}
// private static JPushClient jpushClient = null;
//
// public static JPushClient getJPushClient(String APP_KEY, String MASTER_SECRET) {
...
...
@@ -61,29 +60,29 @@ public class AppMessagePushService {
// }
/*public void sendMessage(List<PushMsgParam> responses)
{
PushFeign.sendMessage(responses);
try
{
if(responses!=null && "true".equals(isPush))
{
for(PushMsgParam response:responses)
{
PushPayload payload = buildPushPayload(response);
jpushClient.sendPush(payload);
}
}
}
catch (Exception e){
log.error(e.getMessage(),e);
e.printStackTrace();
}
}
/*public void sendMessage(List<PushMsgParam> responses)
{
PushFeign.sendMessage(responses);
try
{
if(responses!=null && "true".equals(isPush))
{
for(PushMsgParam response:responses)
{
PushPayload payload = buildPushPayload(response);
jpushClient.sendPush(payload);
}
}
}
catch (Exception e){
log.error(e.getMessage(),e);
e.printStackTrace();
}
}
*/
private
PushPayload
buildPushPayload
(
PushMsgParam
response
)
{
CommonResponse
commonResponse
=
PushFeign
.
buildPushPayload
(
response
);
return
(
PushPayload
)
commonResponse
.
getDataList
();
private
PushPayload
buildPushPayload
(
PushMsgParam
response
)
{
CommonResponse
commonResponse
=
PushFeign
.
buildPushPayload
(
response
);
return
(
PushPayload
)
commonResponse
.
getDataList
();
/*if(JPushTypeEnum.ALL.getCode().equals(response.getType())){
return PushPayload.newBuilder()
.setPlatform(Platform.android())
...
...
@@ -102,19 +101,19 @@ public class AppMessagePushService {
.build();
}*/
}
public
void
sendMessage
(
PushMsgParam
response
)
{
try
{
if
(
null
!=
response
&&
"true"
.
equals
(
isPush
))
{
CommonResponse
commonResponse
=
PushFeign
.
sendMessageone
(
response
);
}
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
e
.
printStackTrace
();
}
}
}
public
void
sendMessage
(
PushMsgParam
response
)
{
try
{
if
(
null
!=
response
&&
"true"
.
equals
(
isPush
))
{
CommonResponse
commonResponse
=
PushFeign
.
sendMessageone
(
response
);
}
}
catch
(
Exception
e
)
{
log
.
error
(
e
.
getMessage
(),
e
);
e
.
printStackTrace
();
}
}
}
amos-boot-system-maintenance/src/main/resources/db/mapper/dbTemplate_check.xml
View file @
33462341
...
...
@@ -1912,12 +1912,13 @@
pp.belong_system_name systemName,
pp.address address,
pp.original_id equipId,
CONCAT
(pp.address, pp.building_name
) buildingName,
CONCAT
_WS('',pp.building_name,pp.address
) buildingName,
pc.org_code AS orgCode
FROM p_check pc
LEFT JOIN p_point pp ON pp.id = pc.point_id
) a
<include
refid=
"mobile-check-record-where"
/>
order by checkDate
limit #{offset},#{pageSize}
</select>
...
...
@@ -1947,20 +1948,20 @@
<if
test=
"beginTime != null and beginTime != '' and endTime != null and endTime != '' "
>
AND (
(
a.
beginTim
e
<![CDATA[>=]]>
#{beginTime}
AND a.
endTim
e
<![CDATA[<=]]>
#{endTime}
a.
checkDat
e
<![CDATA[>=]]>
#{beginTime}
AND a.
checkDat
e
<![CDATA[<=]]>
#{endTime}
)
OR (
a.
beginTim
e
<![CDATA[<=]]>
#{endTime}
AND a.
endTim
e
<![CDATA[>=]]>
#{endTime}
a.
checkDat
e
<![CDATA[<=]]>
#{endTime}
AND a.
checkDat
e
<![CDATA[>=]]>
#{endTime}
)
OR (
a.
beginTim
e
<![CDATA[<=]]>
#{beginTime}
AND a.
endTim
e
<![CDATA[>]]>
#{beginTime}
a.
checkDat
e
<![CDATA[<=]]>
#{beginTime}
AND a.
checkDat
e
<![CDATA[>]]>
#{beginTime}
)
OR (
a.
beginTim
e
<![CDATA[<=]]>
#{beginTime}
AND a.
endTim
e
<![CDATA[>=]]>
#{endTime}
a.
checkDat
e
<![CDATA[<=]]>
#{beginTime}
AND a.
checkDat
e
<![CDATA[>=]]>
#{endTime}
)
)
</if>
...
...
@@ -2013,7 +2014,7 @@
pp.belong_system_id systemId,
pp.belong_system_name systemName,
pp.address address,
CONCAT
(pp.address, pp.building_name
) buildingName,
CONCAT
_WS('',pp.building_name,pp.address
) buildingName,
pc.org_code AS orgCode
FROM p_check pc
LEFT JOIN p_point pp ON pp.id = pc.point_id
...
...
pom.xml
View file @
33462341
...
...
@@ -26,7 +26,7 @@
<springboot.version>
2.3.11.RELEASE
</springboot.version>
<springcloud.version>
Hoxton.SR8
</springcloud.version>
<maven-jar-plugin.version>
3.1.1
</maven-jar-plugin.version>
<tyboot-version>
1.1.20
Ty-SNAPSHOT
</tyboot-version>
<tyboot-version>
1.1.20
</tyboot-version>
<amos.version>
1.6.0
</amos.version>
<itext.version>
7.1.1
</itext.version>
</properties>
...
...
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