Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
江名洋
/
linkwe-scrm
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit c20ddfb3
authored
Nov 17, 2021
by
danmo
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
首页数据统计新增刷新接口
1 parent
c7201f24
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
2 deletions
linkwe-admin/src/main/java/com/linkwechat/web/controller/wecom/WePageDateContraller.java
linkwe-admin/src/main/java/com/linkwechat/web/controller/wecom/WePageDateContraller.java
View file @
c20ddfb
...
...
@@ -2,6 +2,7 @@ package com.linkwechat.web.controller.wecom;
import
com.linkwechat.common.core.domain.AjaxResult
;
import
com.linkwechat.common.core.redis.RedisCache
;
import
com.linkwechat.quartz.task.PageHomeDataTask
;
import
com.linkwechat.wecom.domain.dto.WePageStaticDataDto
;
import
com.linkwechat.wecom.service.IWeCorpAccountService
;
import
com.linkwechat.wecom.service.IWeUserService
;
...
...
@@ -21,13 +22,15 @@ import java.util.List;
* @description 首页统计
* @date 2021/2/23 15:30
**/
@Api
(
description
=
"首页统计contraller
"
)
@Api
(
tags
=
"首页统计
"
)
@Slf4j
@RestController
@RequestMapping
(
"wecom/page/"
)
public
class
WePageDateContraller
{
@Autowired
private
RedisCache
redisCache
;
@Autowired
private
PageHomeDataTask
pageHomeDataTask
;
/**
*
...
...
@@ -42,8 +45,15 @@ public class WePageDateContraller {
@ApiOperation
(
value
=
"实时数据controller"
,
httpMethod
=
"GET"
)
// @PreAuthorize("@ss.hasPermi('wecom:page:getCorpRealTimeData')")
@GetMapping
(
"/getCorpRealTimeData"
)
public
AjaxResult
getCorpRealTimeData
(){
public
AjaxResult
<
WePageStaticDataDto
>
getCorpRealTimeData
(){
WePageStaticDataDto
wePageStaticDataDto
=
redisCache
.
getCacheObject
(
"getCorpRealTimeData"
);
return
AjaxResult
.
success
(
wePageStaticDataDto
);
}
@ApiOperation
(
value
=
"实时数据刷新"
,
httpMethod
=
"GET"
)
@GetMapping
(
"/refresh"
)
public
AjaxResult
refresh
(){
pageHomeDataTask
.
getPageHomeDataData
();
return
AjaxResult
.
success
();
}
}
Write
Preview
Markdown
is supported
Attach a file
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 post a comment