Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
smart_gov_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
赵啸非
smart_gov_platform
Commits
6b1e125a
Commit
6b1e125a
authored
Dec 16, 2023
by
赵啸非
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加查询缓存
parent
e500fb9c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
base-manager/src/main/java/com/mortals/xhx/module/window/service/impl/WindowBusinessServiceImpl.java
...module/window/service/impl/WindowBusinessServiceImpl.java
+3
-3
No files found.
base-manager/src/main/java/com/mortals/xhx/module/window/service/impl/WindowBusinessServiceImpl.java
View file @
6b1e125a
...
...
@@ -73,7 +73,7 @@ public class WindowBusinessServiceImpl extends AbstractCRUDServiceImpl<WindowBus
//判断查询结果是否用缓存
if
(!
ObjectUtils
.
isEmpty
(
query
)
&&
!
ObjectUtils
.
isEmpty
(
query
.
getSearchCache
()
==
YesNoEnum
.
YES
.
getValue
()))
{
//根据查询条件 获取缓存,如果缓存有则直接取缓存,否则读数据库后 再写入缓存
if
(
ObjectUtils
.
isEmpty
(
query
.
getSiteBusinessId
()))
{
if
(
!
ObjectUtils
.
isEmpty
(
query
.
getSiteBusinessId
()))
{
Long
siteBusinessId
=
query
.
getSiteBusinessId
();
String
cacheResult
=
cacheService
.
get
(
KEY_SEARCH_SITEBUSINESSID_CACHE
+
siteBusinessId
,
String
.
class
);
if
(!
ObjectUtils
.
isEmpty
(
cacheResult
))
{
...
...
@@ -87,10 +87,10 @@ public class WindowBusinessServiceImpl extends AbstractCRUDServiceImpl<WindowBus
cacheService
.
set
(
KEY_SEARCH_SITEBUSINESSID_CACHE
+
siteBusinessId
,
JSON
.
toJSONString
(
result
),
KEY_SEARCH_TIMEOUTT_CACHE
);
return
result
;
}
}
else
if
(
ObjectUtils
.
isEmpty
(
query
.
getWindowId
()))
{
}
else
if
(
!
ObjectUtils
.
isEmpty
(
query
.
getWindowId
()))
{
//todo
return
null
;
}
else
if
(
ObjectUtils
.
isEmpty
(
query
.
getWindowIdList
()))
{
}
else
if
(
!
ObjectUtils
.
isEmpty
(
query
.
getWindowIdList
()))
{
//todo
return
null
;
}
else
{
...
...
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