Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
H
haoban-manage3.0
Overview
Overview
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
haoban3.0
haoban-manage3.0
Commits
1dffd534
Commit
1dffd534
authored
Nov 20, 2020
by
qwmqiuwenmin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix
parent
c2cb8914
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
18 additions
and
0 deletions
+18
-0
WxEnterpriseController.java
.../haoban/manage/web/controller/WxEnterpriseController.java
+18
-0
No files found.
haoban-manage3-web/src/main/java/com/gic/haoban/manage/web/controller/WxEnterpriseController.java
View file @
1dffd534
...
@@ -518,6 +518,7 @@ public class WxEnterpriseController extends WebBaseController{
...
@@ -518,6 +518,7 @@ public class WxEnterpriseController extends WebBaseController{
String
wxEnterpriseId
=
login
.
getWxEnterpriseId
();
String
wxEnterpriseId
=
login
.
getWxEnterpriseId
();
String
dayKey
=
"haoban_fresh-wx-friend-day"
+
wxEnterpriseId
+
DateUtil
.
dateToStr
(
new
Date
(),
"yyyy-MM-dd"
);
String
dayKey
=
"haoban_fresh-wx-friend-day"
+
wxEnterpriseId
+
DateUtil
.
dateToStr
(
new
Date
(),
"yyyy-MM-dd"
);
String
monthKey
=
"haoban_fresh-wx-friend-month"
+
wxEnterpriseId
+
DateUtil
.
dateToStr
(
new
Date
(),
"yyyy-MM"
);
String
monthKey
=
"haoban_fresh-wx-friend-month"
+
wxEnterpriseId
+
DateUtil
.
dateToStr
(
new
Date
(),
"yyyy-MM"
);
String
dateKey
=
"haoban_fresh-wx-friend-date"
+
wxEnterpriseId
;
Integer
dayCount
=
RedisUtil
.
getCache
(
dayKey
)
==
null
?
0
:
Integer
.
parseInt
(
RedisUtil
.
getCache
(
dayKey
).
toString
());
Integer
dayCount
=
RedisUtil
.
getCache
(
dayKey
)
==
null
?
0
:
Integer
.
parseInt
(
RedisUtil
.
getCache
(
dayKey
).
toString
());
Integer
monthCount
=
RedisUtil
.
getCache
(
monthKey
)
==
null
?
0
:
Integer
.
parseInt
(
RedisUtil
.
getCache
(
monthKey
).
toString
());
Integer
monthCount
=
RedisUtil
.
getCache
(
monthKey
)
==
null
?
0
:
Integer
.
parseInt
(
RedisUtil
.
getCache
(
monthKey
).
toString
());
if
(
dayCount
>=
1
){
if
(
dayCount
>=
1
){
...
@@ -528,9 +529,26 @@ public class WxEnterpriseController extends WebBaseController{
...
@@ -528,9 +529,26 @@ public class WxEnterpriseController extends WebBaseController{
}
}
String
taskId
=
dealSyncOperationApiService
.
createWxFriendTask
(
wxEnterpriseId
,
"刷新企微好友"
,
login
.
getStaffDTO
().
getStaffId
(),
"刷新企微好友"
);
String
taskId
=
dealSyncOperationApiService
.
createWxFriendTask
(
wxEnterpriseId
,
"刷新企微好友"
,
login
.
getStaffDTO
().
getStaffId
(),
"刷新企微好友"
);
dealSyncOperationApiService
.
dealWxFriendClerk
(
taskId
,
wxEnterpriseId
);
dealSyncOperationApiService
.
dealWxFriendClerk
(
taskId
,
wxEnterpriseId
);
RedisUtil
.
setCache
(
dayKey
,
dayCount
+
1
);
RedisUtil
.
setCache
(
monthKey
,
monthCount
+
1
);
RedisUtil
.
setCache
(
dateKey
,
DateUtil
.
dateToStr
(
new
Date
(),
DateUtil
.
FORMAT_DATETIME_19
));
return
resultResponse
(
HaoBanErrCode
.
ERR_1
);
return
resultResponse
(
HaoBanErrCode
.
ERR_1
);
}
}
/**
* 获取企业微信好友刷新时间
* @return
*/
@RequestMapping
(
"/get-fresh-detail"
)
public
HaobanResponse
getFreshDetail
(){
LoginVO
login
=
(
LoginVO
)
AuthRequestUtil
.
getLoginUser
();
String
wxEnterpriseId
=
login
.
getWxEnterpriseId
();
String
dateKey
=
"haoban_fresh-wx-friend-date"
+
wxEnterpriseId
;
RedisUtil
.
getCache
(
dateKey
);
return
resultResponse
(
HaoBanErrCode
.
ERR_1
,
RedisUtil
.
getCache
(
dateKey
));
}
}
}
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