Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
complex-platform
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
赵啸非
complex-platform
Commits
e621cf6c
Commit
e621cf6c
authored
Dec 19, 2023
by
廖旭伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改办事情形查询接口
parent
a6343c55
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
2 additions
and
41 deletions
+2
-41
complex-window-manager/src/main/java/com/mortals/xhx/busiz/web/ComplexApiController.java
.../java/com/mortals/xhx/busiz/web/ComplexApiController.java
+1
-33
complex-window-manager/src/main/java/com/mortals/xhx/thread/ImplementSituationSendTask.java
...va/com/mortals/xhx/thread/ImplementSituationSendTask.java
+1
-3
complex-window-manager/src/main/java/com/mortals/xhx/thread/SendThread.java
...ager/src/main/java/com/mortals/xhx/thread/SendThread.java
+0
-5
No files found.
complex-window-manager/src/main/java/com/mortals/xhx/busiz/web/ComplexApiController.java
View file @
e621cf6c
...
...
@@ -133,7 +133,7 @@ public class ComplexApiController {
rsp
.
setMsg
(
ApiRespCodeEnum
.
SUCCESS
.
getLabel
());
rsp
.
setCode
(
ApiRespCodeEnum
.
SUCCESS
.
getValue
());
try
{
req
.
setNonce
(
RandomUtil
.
randomNumbers
(
8
));
req
.
setNonce
(
RandomUtil
.
randomNumbers
(
6
));
cacheService
.
lpush
(
KEY_COMPLEX_REQ
,
JSONObject
.
toJSONString
(
req
));
String
rest
=
cacheService
.
blpop
(
KEY_EVENT_IMPLEMENTATION_RESP
+
req
.
getNonce
(),
HTTP_TIMEOUT
,
String
.
class
);
if
(
ObjectUtil
.
isEmpty
(
rest
))
{
...
...
@@ -345,38 +345,6 @@ public class ComplexApiController {
}
}
/**
* 查询办理事项情形
*
* @param req
* @return
*/
@PostMapping
(
"bus-situation-material/judgmentExist"
)
@UnAuth
public
String
judgmentExist
(
@RequestBody
ComplexImplementationReq
req
)
{
log
.
info
(
"【查询办理事项情形】【请求体】--> "
+
JSONObject
.
toJSONString
(
req
));
req
.
setUrlPath
(
"bus-situation-material/judgmentExist"
);
ApiResp
<
String
>
rsp
=
new
ApiResp
<>();
rsp
.
setMsg
(
ApiRespCodeEnum
.
SUCCESS
.
getLabel
());
rsp
.
setCode
(
ApiRespCodeEnum
.
SUCCESS
.
getValue
());
try
{
req
.
setNonce
(
RandomUtil
.
randomNumbers
(
6
));
cacheService
.
lpush
(
KEY_COMPLEX_REQ
,
JSONObject
.
toJSONString
(
req
));
String
rest
=
cacheService
.
blpop
(
KEY_EVENT_IMPLEMENTATION_RESP
+
req
.
getNonce
(),
HTTP_TIMEOUT
,
String
.
class
);
if
(
ObjectUtil
.
isEmpty
(
rest
))
{
throw
new
AppException
(
"请求访问超时"
);
}
Rest
<
ComplexStituationInfo
>
eventRest
=
JSON
.
parseObject
(
rest
,
new
TypeReference
<
Rest
<
ComplexStituationInfo
>>()
{
});
return
JSON
.
toJSONString
(
eventRest
);
}
catch
(
Exception
e
)
{
log
.
error
(
"接收数据失败"
,
e
);
rsp
.
setCode
(
ApiRespCodeEnum
.
FAILED
.
getValue
());
rsp
.
setMsg
(
e
.
getMessage
());
return
JSON
.
toJSONString
(
rsp
);
}
}
public
static
void
main
(
String
[]
args
)
{
File
file
=
new
File
(
"E:\\pic\\1.png"
);
...
...
complex-window-manager/src/main/java/com/mortals/xhx/thread/ImplementSituationSendTask.java
View file @
e621cf6c
...
...
@@ -4,8 +4,6 @@ import com.alibaba.fastjson.JSONObject;
import
com.mortals.framework.common.Rest
;
import
com.mortals.framework.service.ICacheService
;
import
com.mortals.xhx.protocol.complex.matter.model.req.ImplementationReq
;
import
com.mortals.xhx.protocol.complex.matter.model.rsp.implement.ImplementDetailInfo
;
import
com.mortals.xhx.protocol.complex.matter.model.rsp.material.MaterialInfo
;
import
com.mortals.xhx.protocol.complex.matter.model.rsp.matter.MatterWorkInfo
;
import
com.mortals.xhx.protocol.complex.matter.service.IComplexMatterService
;
import
com.mortals.xhx.utils.SpringUtils
;
...
...
@@ -39,7 +37,7 @@ public class ImplementSituationSendTask implements Runnable {
public
void
run
()
{
try
{
log
.
info
(
"ImplementSituationSendTask启动发送"
);
Rest
<
List
<
Mat
erialInfo
>>
rest
=
complexMatterService
.
getMaterialByEventAndSituation
(
deviceLogo
,
implementationReq
);
Rest
<
List
<
Mat
terWorkInfo
>>
rest
=
complexMatterService
.
doWorkMatterSearch
(
deviceLogo
,
implementationReq
.
getEventId
()
);
cacheService
.
lpushForTime
(
KEY_EVENT_IMPLEMENTATION_RESP
+
implementationReq
.
getNonce
(),
REDIS_RESP_TIMEOUT
,
JSONObject
.
toJSONString
(
rest
));
}
catch
(
Exception
e
)
{
...
...
complex-window-manager/src/main/java/com/mortals/xhx/thread/SendThread.java
View file @
e621cf6c
...
...
@@ -79,13 +79,8 @@ public class SendThread extends AbstractThread {
ComplexAcceptReq
complexAcceptReq
=
JSONObject
.
parseObject
(
reqStr
,
ComplexAcceptReq
.
class
);
ImplementAcceptSendTask
acceptSendTask
=
new
ImplementAcceptSendTask
(
deviceCode
,
complexAcceptReq
);
ThreadPool
.
getInstance
().
execute
(
acceptSendTask
);
}
else
if
(
"bus-situation-material/judgmentExist"
.
equals
(
urlPath
))
{
ComplexAcceptReq
complexAcceptReq
=
JSONObject
.
parseObject
(
reqStr
,
ComplexAcceptReq
.
class
);
ImplementAcceptSendTask
acceptSendTask
=
new
ImplementAcceptSendTask
(
deviceCode
,
complexAcceptReq
);
ThreadPool
.
getInstance
().
execute
(
acceptSendTask
);
}
}
}
...
...
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