Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dsk-cr20g
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
Administrator
dsk-cr20g
Commits
bfb5a9d0
Commit
bfb5a9d0
authored
Sep 13, 2023
by
Administrator
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
Signed-off-by:
Administrator
<
admin@example.com
>
parent
48eec525
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
10 deletions
+13
-10
EnterpriseService.java
.../src/main/java/com/dsk/jsk/service/EnterpriseService.java
+13
-10
No files found.
dsk-module/dsk-biz-api/src/main/java/com/dsk/jsk/service/EnterpriseService.java
View file @
bfb5a9d0
...
@@ -408,21 +408,24 @@ public class EnterpriseService {
...
@@ -408,21 +408,24 @@ public class EnterpriseService {
if
(
body
.
isValidateCid
())
{
if
(
body
.
isValidateCid
())
{
return
R
.
ok
();
return
R
.
ok
();
}
}
String
redisKey
=
CacheConstants
.
DATA_FINANCIAL
+
body
.
getCid
();
// TODO 缓存需要
List
cacheMap
=
RedisUtils
.
getCacheList
(
redisKey
);
// String redisKey = CacheConstants.DATA_FINANCIAL + body.getCid();
if
(
ObjectUtil
.
isNotEmpty
(
cacheMap
))
{
// List cacheMap = RedisUtils.getCacheList(redisKey);
return
R
.
ok
(
cacheMap
);
// if (ObjectUtil.isNotEmpty(cacheMap)) {
}
// return R.ok(cacheMap);
// }
Map
<
String
,
Object
>
map
=
dskOpenApiUtil
.
requestBody
(
"/operate/enterprise/financialData"
,
BeanUtil
.
beanToMap
(
body
,
false
,
false
));
Map
<
String
,
Object
>
map
=
dskOpenApiUtil
.
requestBody
(
"/operate/enterprise/financialData"
,
BeanUtil
.
beanToMap
(
body
,
false
,
false
));
Integer
code
=
MapUtils
.
getInteger
(
map
,
"code"
,
300
);
Integer
code
=
MapUtils
.
getInteger
(
map
,
"code"
,
300
);
if
(!
code
.
equals
(
HttpStatus
.
OK
.
value
()))
{
if
(!
code
.
equals
(
HttpStatus
.
OK
.
value
()))
{
throw
new
RuntimeException
();
throw
new
RuntimeException
();
}
}
Object
data
=
map
.
get
(
"data"
);
if
(
ObjectUtil
.
isNotEmpty
(
data
))
{
// Object data = map.get("data");
RedisUtils
.
setCacheList
(
redisKey
,
(
List
)
data
);
// if (ObjectUtil.isNotEmpty(data)) {
RedisUtils
.
expire
(
redisKey
,
Duration
.
ofHours
(
24
));
// RedisUtils.setCacheList(redisKey, (List) data);
}
// RedisUtils.expire(redisKey, Duration.ofHours(24));
// }
return
BeanUtil
.
toBean
(
map
,
R
.
class
);
return
BeanUtil
.
toBean
(
map
,
R
.
class
);
}
}
...
...
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